Jump to content


Photo

My code shows NOTHING, even with all error reporting on?


  • Please log in to reply
3 replies to this topic

#1 DaveLinger

DaveLinger
  • Members
  • PipPipPip
  • Advanced Member
  • 268 posts
  • LocationWV, USA

Posted 31 July 2006 - 02:31 AM

I don't understand it, its 90% HTML and everything looks fine (checked the code thrice), yet it echos nothing.

<?php
error_reporting(E_ALL);
include('includes/header.php');
?>
<table border="1" style="border-collapse: collapse" width="100%">
	<tr>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
	</tr>
	<tr>
		<td>There are 0 PS3 game reviews</td>
		<td>There are 0 Wii game reviews</td>
		<td>There are 
<?php
pid="32";
include('includes/numberofreviews.php');
?>
 Xbox 360 game reviews</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
	</tr>
	<tr>
		<td>There are 
<?php
pid="12";
include('includes/numberofreviews.php');
?>
 PS2 game reviews</td>
		<td>There are 
<?php
pid="14";
include('includes/numberofreviews.php');
?>
 GameCube game reviews</td>
		<td>There are 
<?php
pid="13";
include('includes/numberofreviews.php');
?>
 Xbox game reviews</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
	</tr>
	<tr>
		<td>PC</td>
		<td>DS</td>
		<td>PSP</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td><img src="images/reviewicons/reviews.gif"></td>
	</tr>
	<tr>
		<td>GBA</td>
		<td>Palm</td>
		<td>DVD/UMD</td>
	</tr>
	<tr>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td><img src="images/reviewicons/reviews.gif"></td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
	<tr>
		<td>N-Gage</td>
		<td>&nbsp;</td>
		<td>&nbsp;</td>
	</tr>
</table>
<?php
include('includes/footer.php');
?>

http://www.DaveLinger.com
dave at linger dot com

#2 DaveLinger

DaveLinger
  • Members
  • PipPipPip
  • Advanced Member
  • 268 posts
  • LocationWV, USA

Posted 31 July 2006 - 02:32 AM

also, header.php, footer.php, and numberofreviews.php each work fine individually.
http://www.DaveLinger.com
dave at linger dot com

#3 DaveLinger

DaveLinger
  • Members
  • PipPipPip
  • Advanced Member
  • 268 posts
  • LocationWV, USA

Posted 31 July 2006 - 02:34 AM

piece of crap. I hate it when I fumble with code for 3 hours and when I finally ask for help I see exactly what I did wrong.

I have: "pid=""", when it should be "$pid="""

mods can delete or close
http://www.DaveLinger.com
dave at linger dot com

#4 shoz

shoz
  • Staff Alumni
  • Advanced Member
  • 600 posts

Posted 31 July 2006 - 03:11 AM

You might want to add "ini_set('display_errors', 'on')" to the top of the script to ensure that errors are shown. Adding "php_flag display_errors on" to a .htaccess file will show a few more errors that won't be shown if you use ini_set() to turn the option on however.

php_flag display_errors on





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users