Can anyone help me to fix the error I'm getting in my codes.
Issue: Parse error: syntax error, unexpected T_STRING in
The function of this script is to get Title and URL of all my Website Post and Save then in to a .CSV file. Right now I'm able to get full URL in the .CSV file, but the code is not getting the Title.
This is my code:
<?php
//Vital file include
require_once("load file");
include("Config File");
$useCategory=1; //0 for yes , 1 for no
$table='videos2_videos';
$fnamee='csvdata';
$list = array
(
"Title_-Url"
);
if($useCategory===1)
{
$data=mysql_query("SELECT * from $table where pub='1'");
}
else
{
$data=mysql_query("SELECT * from $table where pub='1' and categories='$category'");
}
while($adata=mysql_fetch_assoc($data))
{
        $url='http://www.domain.com/video/'.$adata['id'].'/';
        $Title= html_entity_decode(str_replace('Á','A',
        str_replace('&Eacut;e','E',
        str_replace('Í','I',
        str_replace('Ó','O',
        str_replace('Ñ','N',
        str_replace('&Ñtilde;','Ñ'
        str_replace('Ú','U',
        str_replace('Ü','U',
        str_replace('¡','!',
        str_replace('¿','?',
        str_replace('á','a',
        str_replace('é','e',
        str_replace('í','i',
        str_replace('ó','o',
        str_replace('ñ','n',
        str_replace('ú','u',
        str_replace('ü','u',
        str_replace('ª','a',
        str_replace('º','o',$adata['title'])))))))))))))))))),ENT_QUOTES,"ISO-8859-1");        
$list[].=$title.'_-'.$url;
}
$file = fopen("$fnamee.csv","w");
foreach ($list as $line)
  {
  fputcsv($file,explode('_-',$line),',');
  }
fclose($file); 
?>
<a href="csvdata.csv">Right click and save</a>
 
    