Jump to content

refresh problem!


champoi

Recommended Posts

the script is javascript, but i run it using php, so php might have something to do with it, i already posted this in the javascript section of this forums but as of now, no one has replied to it, i think there are more people that are willing to help in the php section, anyways, this is my problem

 

i'm doing a download page that has a link that does the following:

1. open a pop-up (well, not really a pop-up, but blank window) that has the download script, download.php, and will see if the download is valid by checking the values added in the url, like a GET (?download=sherashera),

2. has a title set to "download"

3. the link is an image; and

4. refresh the parent page after 4 seconds using javascript, cause a download counter is placed on the parent page to tell the user that he already downloaded a certain amount of downloads,

 

here's the code of the link:

 

<a href=\"download.php?i=".$row."&u=".$_SESSION['u']."&p=".$_SESSION['p']."&m=sapli\" target=\"_blank\" onclick=\"setTimeout('window.location.reload( false );', 4000)\"><img src=\"img/ics/i_d.jpg\" title=\"Download\"></a>

 

when i click the link, the blank window appears and the download works, but after it refreshes, alot of text appears and i dont know how on earth my page got those texts, and the php script on the parent page does not work, anyone have any suggestions or comments? better if it's a solution though,

Link to comment
Share on other sites

it's a mix, at the top part, some english with mixed \par or something like those, then the html codes, then near the bottom part, some alien characters are there, i think the browser misunderstands the page, instead of executing the page, it reads it, something like that i suppose,

Link to comment
Share on other sites

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.