RE: Posting Again
| From: | Mark Collin | Date: | Fri, 30 Jul 2004 22:01:51 +0000 |
| Subject: | RE: Posting Again | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-24300@lists.php.net to get a copy of this message | ||
Have you tried a print_r($row_ads); to check that your array is actually
populated with all the data you are expecting it to be populated with?
That being said I would expect to see the html in your source even if
those fields in the array were blank....
Mark
"schalk@volume4.co.za" <schalk@volume4.co.za> wrote in message
news:410AA07E.4060900@volume4.co.za:
> This did not seem to make the list the first time.
>
> Can someone see why the following is happening? I have the following
> code in my PHP page:
>
> <?php do { ?>
> <td> <a href="view_ad.php?id=<?php echo
> $row_ads['id']; ?>"><img src="<?php echo
> $row_ads['full_img']; ?>"
> width="87" height="120" hspace="5" vspace="5"
> border="1" /></a>
> <?php echo $row_ads['full_img']; ?><br /><?php echo
> $row_ads['campaign']; ?>
> </td>
> <?php } while (($row_ads = mysql_fetch_assoc($ads)) && ($row_ads['id']
> <= 3)); ?>
>
> After rendering the page in a browser the code produced by this block is
>
> as follows:
>
> <td> ../media/ads/001.jpg<br />Spring 2004 </td>
> <td> ../media/ads/002.jpg<br />Spring 2004 </td>
> <td> ../media/ads/003.jpg<br />Spring 2004 </td>
>
> > From this it looks like it is completely ignoring this line:
>
> <a href="view_ad.php?id=<?php echo $row_ads['id']; ?>"><img
> src="<?php
> echo $row_ads['full_img']; ?>"
> width="87" height="120" hspace="5" vspace="5"
> border="1" /></a>
>
> Any ideas why this is happening? Thanks!
>