Jump to content

Recommended Posts

Hey this has got to be an easy solution, but i can't find it

i have this:

<?php
$id = $_GET['id'];
$file = "xml/".$id.".xml";
$xml = simplexml_load_file($file) or die ("Unable to load XML file!");

if ($id == NULL){
echo "you fucked up!";
}
else {
echo '<h2 class="newstitle">'.$xml->title.'</h2>
<span class="news"> </span>

<table cellpadding="6" cellspacing="6" border="0" align="right">
<tr><td>
<table cellpadding="4" cellspacing="4" border="1">
  <tr> 
    <td valign="top" width="200" align="center" class="news"> <img src="'.$xml->photo.'" alt="gamephoto" /><br />
      <span class="news"><strong class="red"><br>
      Release Date:</strong><br />
            '.$xml->rdate.'<br />
      <br />
      <strong class="red">Publisher: '.$xml->developer.'<br />Platform(s): '.$xml->platforms.'</strong> <br />
      </span> </td>
  </tr>
</table>
</td></tr></table>';
echo nl2br('<span class="news">'.$xml->info.'<br /><br></span>');
echo '<table width="100%" cellpadding="2" cellspacing="3">
<tr>
<td width="14%" valign="top">
Put reviewer photo here
</td>
<td width="86%" valign="top" class="news">
reviewer write up goes here...along with link to their profile
</td>
</tr>
</table>';
}
?>

 

i type in the review.php?id=8

the 8.xml is in xml/ and it doesn't load

additionally i have something else that does basically the same thing referring to the same folder and that one works

when i load the page though i just get a blank screen. i look at the source... nothing. what gives?

Link to comment
https://forums.phpfreaks.com/topic/119839-solved-file-showing-blank-page/
Share on other sites

wow i found the problem

my ftp client was uploading versions of the files that were from 1969

so everytime it uploaded a file it'd upload it blank... even though the files i had were populated

i restarted the client and it fixed it... weiiiird

sorry for wasting your time.

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.