Switch to full style
:read: Start PHP with us. Includes topics to help you in php
Post a reply

explode CSV file

Mon Oct 27, 2008 6:35 pm

Code:
<?php
   $users
= file("./demoCSV.csv");
   foreach (
$users as $user) {
      list(
$name, $email, $phone) = explode(",", $user);
      echo
"<p>$name ($email) Tel. $phone</p>";
   }
?>
<!--
A,[email protected],11111
B,[email protected],22222


-->




Post a reply
  Related Posts  to : explode CSV file
 list and explode     -  
 explode time     -  
 Encrypt/Decrypt a file from source file to target file.     -  
 Copy file to file in java code- implementation     -  
 file descriptor vs file pointer     -  
 getting file name of html input file tag using jsp     -  
 How to convert xml file to Pdf file using C     -  
 C++ File I/O     -  
 web.xml file     -  
 JSP to Upload File     -  

Topic Tags

PHP Files and I/O