Jump to content

Php Csv Files And Mysql


Orionsbelter

Recommended Posts

I'm currently trying to use the following code:

 


$arrResult = array();
$arrLines = file('ProductAll.csv');
foreach($arrLines as $line) {
$arrResult[] = explode( ',', $line);
$name=$arrResult[0];
$description=$arrResult[1];
$brand=$arrResult[2];
$price=$arrResult[3];
$RRP=$arrResult[4];
$hidden=$arrResult[5];
$Image1Address=$arrResult[6];
$Image2Address=$arrResult[7];
$Image3Address=$arrResult[8];
$Image4Address=$arrResult[9];
$Image5Address=$arrResult[10];

 

However i just get the result "Array"

 

where am i going wrong?

Link to comment
https://forums.phpfreaks.com/topic/272452-php-csv-files-and-mysql/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.