Hey,
I just switched this page from asp to php.. In it's conversion it seems to have created some errors.. I was hoping that someone could maybe look it over and give me some insight into what could be some poblems with the code, as I am not that up on PHP.. thanks in advance..

<!--#include file="dim.asp"-->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Rafaels Fishing Fleet | Pictures</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
img.pinkborder {border-color:#A667A5; color:#A667A5;}
img.greyborder {border-color:#C5C5C5; color:#C5C5C5;}
</style>
</head>

<body>

<div align="top">
<div align="center">
<center>
<form action="confirm_testimonial.asp" method="post" name="FORM1" onSubmit="return VerifyData()">
<table width="800" height="162" border="0" >
<tr>
<td align="center"><a href="#" onclick="window.open('pic_login.asp','',
',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=no,left=200,top=0,height=450,width=400');"
ONMOUSEOVER="window.status='Log in'; return true;"
ONMOUSEOUT="window.status=''; return true;"><img src="admin_images/logo.gif" border="0" height="162" width="590"></a>
<!--<a href="#" onclick="window.open('pics.php','',
',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=no,left=200,top=0,height=600,width=800');"
ONMOUSEOVER="window.status='Log in'; return true;"
ONMOUSEOUT="window.status=''; return true;"><img src="admin_images/logo.gif" border="0" height="162" width="590"></a>--></td>
</tr>
</table>
<div align="center">
<center>
<table border="0" cellpadding="0" cellspacing="0" width="750" height="438" >
<tr>
<td width="15" height="5"></td>
<td align="left" width="100%"></td>
<td width="15" height="5"></td>
</tr>
<?
$sqlQuery = "SELECT picture_tbl.* FROM picture_tbl WHERE display = true ORDER BY ID";
$rs.$open $sqlQuery, $DataConn, $adOpenStatic, $adLockReadOnly, $adCmdText;
?>
<?if ($rs.$eof != true) { ?>
<tr>
<td width="100%" height="1" valign="top"><span class="bodyblack">
<table border="0" cellspacing="0" cellpadding="0" width="100%">

    <tr>
    	<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
    </tr>
    <tr>
    	<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1">&nbsp;</td>
		<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
    </tr>
    <?do until $rs.$eof = true?> 
     <tr>
        <td width="22%" align="center" valign="top"><span class="bodygrey">      
	        <a href="#" onclick="window.open('viewPic.asp?pic_id=<?=$rs["ID"]?>','',
				',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=yes,left=0,top=0,height=600,width=800');"	
				ONMOUSEOVER="window.status='View full size picture';  return true;"
				ONMOUSEOUT="window.status='';  return true;">		
   			<img border="2" class="greyborder" ALT="Click to enlarge" src="images/thumbs/<?=$rs["picName"]?>" width="<?=$rs["thumbWidth"]?>" height="<?=$rs["thumbHeight"]?>"></a></span></td>
         <td width="4%">&nbsp;</td>
         <?$rs.$movenext?>
         <?if ($rs.$eof != true) { ?>
         <td width="22%" align="center" valign="top"><span class="bodygrey">        
	        <a href="#" onclick="window.open('viewPic.asp?pic_id=<?=$rs["ID"]?>','',
				',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=yes,left=0,top=0,height=600,width=800');"	
				ONMOUSEOVER="window.status='View full size picture';  return true;"
				ONMOUSEOUT="window.status='';  return true;">		
   			<img border="2" class="greyborder" ALT="Click to enlarge" src="images/thumbs/<?=$rs["picName"]?>" width="<?=$rs["thumbWidth"]?>" height="<?=$rs["thumbHeight"]?>"></a></span></td>
   	  <td width="4%">&nbsp;</td>
   	  <?}?>
   	  <?if ($rs.$eof != true) { ?>
         <?$rs.$movenext?>
         <?}?>
         <?if ($rs.$eof != true) { ?>
         <td width="22%" align="center" valign="top"><span class="bodygrey">        
	        <a href="#" onclick="window.open('viewPic.asp?pic_id=<?=$rs["ID"]?>','',
				',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=yes,left=0,top=0,height=600,width=800');"	
				ONMOUSEOVER="window.status='View full size picture';  return true;"
				ONMOUSEOUT="window.status='';  return true;">		
   			<img border="2" class="greyborder" ALT="Click to enlarge" src="images/thumbs/<?=$rs["picName"]?>" width="<?=$rs["thumbWidth"]?>" height="<?=$rs["thumbHeight"]?>"></a></span></td>
		  <td width="4%">&nbsp;</td>
         <?}?>
   	  <?if ($rs.$eof != true) { ?>
         <?$rs.$movenext?>
         <?}?>
         <?if ($rs.$eof != true) { ?>
         <td width="22%" align="center" valign="top"><span class="bodygrey">        
	     	 <a href="#" onclick="window.open('viewPic.asp?pic_id=<?=$rs["ID"]?>','',
				',,location=no,toolbar=no,menubar=no,scrollbars=yes,resizable=yes,left=0,top=0,height=600,width=800');"	
				ONMOUSEOVER="window.status='View full size picture';  return true;"
				ONMOUSEOUT="window.status='';  return true;">		
   			<img border="2" class="greyborder" ALT="Click to enlarge" src="images/thumbs/<?=$rs["picName"]?>" width="<?=$rs["thumbWidth"]?>" height="<?=$rs["thumbHeight"]?>"></a></span></td>
   	  <?}?>
    </tr>
    <tr>
    	<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1">&nbsp;</td>
		<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
    </tr>
    <tr>
    	<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
    </tr>
    <tr>
    	<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1">&nbsp;</td>
		<td width="22%" height="1">&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
		<td width="4%" height="1" >&nbsp;</td>
		<td width="22%" height="1" >&nbsp;</td>
    </tr>
    	<?if ($rs.$eof != true) { ?>
    	<?$rs.$movenext?>
    	<?}?>
    <?loop?>
    <tr>
    	<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
		<td width="4%">&nbsp;</td>
		<td width="22%">&nbsp;</td>
    </tr>
    </table>
    <?} else {?>
</span>
    	<tr>
		<td width="15" height="5"></td>
		  	<td align="center" width="100%"><center><h3>Currently no pictures are available at this time, please check back soon.</h3></center></td>
		  	<td width="15" height="5"></td>
	  </tr>
    <?}?>   

<?$rs.close?>
</table>
</center>
</div>
</body>
</html>

    I found the problem: You never told us what the errors are.

      This tag is throwing a parse error-
      <?
      $sqlQuery = "SELECT picture_tbl.* FROM picture_tbl WHERE display = true ORDER BY ID";
      $rs.$open $sqlQuery, $DataConn, $adOpenStatic, $adLockReadOnly, $adCmdText;
      ?>

      Parse error: parse error, unexpected T_VARIABLE in pics2.php on line 66
      - which is refering to this line -

      <?do until $rs.$eof = true?>

        Originally posted by evok
        This tag is throwing a parse error-
        <?
        $sqlQuery = "SELECT picture_tbl.* FROM picture_tbl WHERE display = true ORDER BY ID";
        $rs.$open $sqlQuery, $DataConn, $adOpenStatic, $adLockReadOnly, $adCmdText;
        ?>


        Parse error: parse error, unexpected T_VARIABLE in pics2.php on line 66
        - which is refering to this line -

        <?do until $rs.$eof = true?>
        [/QUOTE

        Umm....
        The line "$rs.$open $sqlQuery..." I've never seen its like in php.
        You want to run the sqlquery on the dataconn etc thing 🙂

        first: What Database?
        Mysql would look like this:

        $query=mysql_query($sqlQuery); //Feel free to add in Connection and else things you might need.

        And the second part:
        "do until..." should be along thoose lines...
        while($rs=mysql_fetch_array($query))
        {

        }

          Write a Reply...