Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to create a link with <a href..."

Status
Not open for further replies.

Saiman70

Technical User
Mar 5, 2009
10
IT
Hello everybody
I need to make a link on a php page using php
I have this code

$result = mysql_query ($sql);

while ($row = mysql_fetch_row($result))
{
if ( $item == 0 ) { $_firstext = $row[1]; }
if ( $item == 0 ) { $_primafoto = $row[0]; }
if ( $item == 0 ) { $_primolink = $row[0]; }
echo "photos[".$item."]=\"provalink/".$row[0].".jpg\";";

echo "text[".$item."]=\"".$row[1]."\";";

echo "link[".$item."]=\"<a href='[0].".jpg'\";</a>";



$item=$item+1;
}
}
?>

Unfortunately it doesn't work. Does anybody knows if the line

echo "link[".$item."]=\"<a href='[0].".jpg'\";</a>";


...is correctly coded? Cause the error is there,
bye ;)
 
Thanks Very much!!! Now it works! Really, Thank you! ciao :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top