Why does this not work. I'm trying to set $showpage to = a dynamic table. then later if conditions are right, echo it on the screen.
Assuming that all my variable are set, why won't this work. I thought as long as I escape my " (\") I should be able to just copy and paste this from another page where my form is showing up and working fine.
here is the code.
<?php
if ($_GET['page_name'] != ""){
$showpage = $row_htmlcontent['page_content'];
} else {
if ($_GET['photo_category'] != "")
This should be building a dynamic 3 column table with a radiobutton, thumb name, and photo description in each coloumn as long as the array exists. It works until I try to load this into a variable.
$showpage ="<form name=\"form1\" method=\"post\" action=\"\">
<table width=\"547\" border=\"0\">
<?php do { ?> <tr>
<td width=\"36\"><input name=\"thumbselect\" type=\"radio\" value=\"<?php echo $row_thumbscontent['photo_category']; ?>\" onClick=\"document.forms['form1'].submit();\"/>
</td>
<td width=\"209\"><?php echo $row_thumbscontent['photo_thumb_name']; ?></td>
<td width=\"226\"><?php echo $row_thumbscontent['photo_desc']; ?></td>
</tr>
<?php } while ($row_thumbscontent = mysql_fetch_assoc($thumbscontent)); ?>
</table>
</form>";
}
?>
TIA.
Assuming that all my variable are set, why won't this work. I thought as long as I escape my " (\") I should be able to just copy and paste this from another page where my form is showing up and working fine.
here is the code.
<?php
if ($_GET['page_name'] != ""){
$showpage = $row_htmlcontent['page_content'];
} else {
if ($_GET['photo_category'] != "")
This should be building a dynamic 3 column table with a radiobutton, thumb name, and photo description in each coloumn as long as the array exists. It works until I try to load this into a variable.
$showpage ="<form name=\"form1\" method=\"post\" action=\"\">
<table width=\"547\" border=\"0\">
<?php do { ?> <tr>
<td width=\"36\"><input name=\"thumbselect\" type=\"radio\" value=\"<?php echo $row_thumbscontent['photo_category']; ?>\" onClick=\"document.forms['form1'].submit();\"/>
</td>
<td width=\"209\"><?php echo $row_thumbscontent['photo_thumb_name']; ?></td>
<td width=\"226\"><?php echo $row_thumbscontent['photo_desc']; ?></td>
</tr>
<?php } while ($row_thumbscontent = mysql_fetch_assoc($thumbscontent)); ?>
</table>
</form>";
}
?>
TIA.