The line $str= buffer[$i];

Should probably read:

$str .= buffer[$i];


-----Original Message-----
From: roslyn jose [mailto:[EMAIL PROTECTED]] 
Sent: 23 September 2002 11:39
Subject: [PHP-DB] string concatenattion


i have an array of strings and would like to create a single string from the
array but starting somewhere in the middle of the array index and not from
the start, is there any function for me to do a string concatenation. ive
gone thro the manula and didnt find any, but if u have any bright ideas how
this can be achieved, pls help.


$conn=pg_connect("host=abcd.... dbname=ucs user=roslyn password=roslyn");
$filename="note.txt"; $fp = fopen ($filename,"r"); $cnt=3;
$buffer=file($filename); //pg_exec ($conn, "insert into
books(name,sequenceno,chapters,lang) values('$buffer[0]',1,$buffer[1],1)");
while($i <= $cnt)
$str = buffer[$i];
echo $str;
fclose ($fp);   

this string only prints the last element in the buffer, and no concat is
done. pls help

Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!

PHP Database Mailing List (
To unsubscribe, visit:

Reply via email to