hi, i wanted to put my php code in a content is it possible?

here's the scenario, i wanted to fetch a list of data form my db and i wanted to display it in a content of my page,
**here's my query

$sql="select * from table";

**here's the form display i wanted to display

<TABLE WIDTH="578" HEIGHT="20" BORDER="0" CELLPADDING="0" CELLSPACING="0">
<TR>
<TD>&nbsp;</TD>
<TD>&nbsp;</TD>
</TR>
<TR> 
<TD><IMG SRC="images/partners_30.gif" WIDTH="79" HEIGHT="21"></TD>
<TD><IMG SRC="images/associates_32.gif" WIDTH="106" HEIGHT="21"></TD>
</TR>
<TR> 
<TD VALIGN="TOP">&nbsp;</TD>
<TD VALIGN="TOP">&nbsp;</TD>
</TR>
<TR> 
<TD WIDTH="289" VALIGN="TOP"><TABLE WIDTH="296" BORDER="0" CELLPADDING="1" CELLSPACING="1" BORDERCOLOR="#999999" CLASS="bodyText">
<? 
	while($row2 = mysql_fetch_row($ResultSet2)){
	$criteria2 =  $row2[0]; 
?>
<TR> 
<TD WIDTH="42"> 
<?

			$img_criteria2="where PARTNERS_ID=".$criteria2;
 			echo ("<img src=\"CMS/get_imagePartners.php?tName=TBL_PARTNERS&fName=PARTNERS_IMAGE&criteria=".$img_criteria2."\"><br><br>");

	  ?>
</TD>
<TD WIDTH="247"><SPAN CLASS="txtBrown"><B><A HREF="ourteam-partners.php?partnerID=<? echo $row2[0]; ?>" CLASS="txtLinkBrown"><? echo  $row2[1]; ?></A></B></SPAN></TD>
</TR>
<?
 }
?>
</TABLE></TD>
<TD WIDTH="289" VALIGN="TOP"><TABLE WIDTH="296" BORDER="0" CELLPADDING="1" CELLSPACING="1" BORDERCOLOR="#999999" CLASS="bodyText">
<? 
	while($row = mysql_fetch_row($ResultSet)){
	$criteria =  $row[0]; 
?>
<TR> 
<TD WIDTH="43"> 
<?

			$img_criteria="where LAWYERS_ID=".$criteria;
 			echo ("<img src=\"CMS/get_imageLawyers.php?tName=TBL_LAWYERS&fName=LAWYERS_IMAGE&criteria=".$img_criteria."\"><br><br>");

	  ?>
</TD>
<TD WIDTH="246"><SPAN CLASS="txtBrown"><B><A HREF="ourteam-associates.php?lawyerID=<? echo  $row[0]; ?>" CLASS="txtLinkBrown"><? echo  $row[1]; ?></A></B></SPAN></TD>
</TR>
<?
 }
?>
</TABLE> </TD>
</TR>
</TABLE>

***please help,tnx

[Edited to add <code> and </code> tags; nevets]

Comments

vm’s picture

insure the php filter is enabled in administer -> modules
switch your input format to php before submitting the node.

_____________________________________________________________________
My posts & comments are usually dripping with sarcasm.
If you ask nicely I'll give you a towel : )

jeannea08’s picture

tnx.