This simple problem has been driving me nuts for 2 days now. I finally got the image to display where I wanted it to go but....
How come only the first pic ( <img src=../pic.gif>) shows up (in the PRES1), and the others just get the little box with the red x?
$presidents = array(
'PRES1'=>array('Name'=>'George Washington', 'Term'=>'1789-1797','Brief Description'=>'Soldier, statesman, farmer, politician, and commander and chief of the continental army during the Revolutionary War.','Photograph'=>'<img src=../pic.gif>'),
'PRES2'=>array('Name'=>'John Adams','Term'=>'1797-1801','Brief Description'=>'Farmer, lawyer, political philosopher, diplomat, and politician. He was a leader for U.S. Independence.','Photograph'=>'<img src=../pic1.gif>'),
'PRES3'=>array('Name'=>'Thomas Jefferson','Term'=>'1801-1809','Brief Description'=>'Architect, scientist, diplomat, author, and politician. He authored the Declaration of Independence.','Photograph'=>'<img src=../pic2.gif>'),
'PRES4'=>array('Name'=>'James Madison','Term'=>'1809-1817','Brief Description'=>'One of the framers of the Virginia Constitution, the U.S. Bill of Rights, the U.S. Constitution, and the Federalists Essays.','Photograph'=>'<img src=../pic3.gif>')
);
if (isset($presidents[$id])){
print '<font size="4" color="blue"> ';
print "Presidential Information Requested <br></font>";
print '<table border=1><th> ID <th> Name <th> Term <th> Brief Description <th> Photograph ';
print "<tr> <td> $id </td>";
print "<td> {$presidents[$id]['Name']} </td>";
print "<td> {$presidents[$id]['Term']} </td>";
print "<td> {$presidents[$id]['Brief Description']} </td>";
print "<td> {$presidents[$id]['Photograph']} </td></tr>";
} else {
print "$id ";
}
Any suggestions? I am at a loss to what I am doing wrong.
Thanks
Talia