i'm not sure what is the syntax error.

I try in this source code in dreamweaver, it shows line 8 is a syntax error.

$destination = realpath(‘../../app/webroot/uploads/excel/’);

App::import(‘Vendor’, ‘php-excel-reader/excel_reader2’); //import statement
class UploadsController extends RealTimeAnalysisAppController
public function upload()
{
$destination = realpath(‘../../app/webroot/uploads/excel/’); //Set your upload path here
if(isset($_FILES['Upload']['XLS_File']));
$ext = substr($_FILES['Upload']['XLS_File'], strrpos($_FILES['Upload']['XLS_File'], ‘.’) + 1);
$path = $destination.’excel.’.$ext;
move_uploaded_file($_FILES['Upload']['tmp_name'], $path);
$data = new Spreadsheet_Excel_Reader($path, true);  
$temp = $data->dumptoarray();    
if($temp)
{
foreach ($temp as $key=>$val)
{
$val['0'];
}
}
}}
Re: import excel file to sql server via cakephp 80 80

This is cool. Solved without a single response. Don't you love it when you solve your own problems? LOL.

Re: import excel file to sql server via cakephp 80 80

thanks!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.