Please Wait message while PHP loops

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Re: Please Wait message while PHP loops

Post by Chris Corbyn »

Typo:

windows.onload

Should be:

window.onload
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

thanks chris.
kdidymus
Forum Contributor
Posts: 196
Joined: Tue May 13, 2008 3:37 am

Re: Please Wait message while PHP loops

Post by kdidymus »

Okay. I changed the typo. At first I was getting a "Not Implemented" error (yellow triangle kept coming up) but now when I refresh there are no errors.

But the loading message still isn't disappearing!

Hmm. I'm stumped. Mainly because I know nothing about Javascript!!

KD.
kdidymus
Forum Contributor
Posts: 196
Joined: Tue May 13, 2008 3:37 am

Re: Please Wait message while PHP loops

Post by kdidymus »

Just realised that the Javascript makes a call to "myclass" but I don't know what "myclass" should be defined as in my CSS. Have tried defining it as:

myclass {display: none;}

but this isn't working.

KD.
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

have no clue what you are on about. it works from my end ! ? :)
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

kdidymus wrote:Just realised that the Javascript makes a call to "myclass" but I don't know what "myclass" should be defined as in my CSS. Have tried defining it as:

myclass {display: none;}

but this isn't working.

KD.
no, myclass should be whatever style you want for the div, but don't assign any value to the display attribute, as that is handled by the javascript.
Last edited by php_east on Sat Mar 21, 2009 10:50 am, edited 1 time in total.
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

i see the problem.
there seems to be a redirect to another page, and that page has not the javascript you entered.

the redirected page is
http://www.didymus.org.uk/tree/a-zfn.php

so this is where you will need the javascript, and the div, not on the page where the user clicks the links.

Code: Select all

<head>
<meta http-equiv='Content-Type' content='text/html; charset=windows-1252'/>
<title>A-Z by Forename | Didymus.org.uk | Family Tree</title>
<meta name='author' content='Kris Didymus'/>
<meta name='keywords' content='family,tree,genealogy,didymus,oliver,bending,nettleton'/>
<meta name='description' content='On-line family tree of the Didymus and Oliver families...'/>
<link rel='stylesheet' href='../css/lytebox.css' type='text/css' media='screen' />
</head>
 
 
kdidymus
Forum Contributor
Posts: 196
Joined: Tue May 13, 2008 3:37 am

Re: Please Wait message while PHP loops

Post by kdidymus »

Ah. No. I THINK I can see where this confusion came in.

On the actual site, if you click A-Z by Forename or A-Z by Surname it loads a page which meta-refreshes.

The link you should be clicking on to test your code is: http://www.didymus.org.uk/tree/a-zfn2.php

Once I get it working I'll rename this page a-zfn.php and remove the link to the meta-refreshing page.

Hope that's clear!

KD.
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

ah, i see. :) ok, nice.
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

could you please change this line
window.onload=remove_loading_div();

to this...
window.onload=remove_loading_div;

as that is what java wants to see. i have tested it a moment ago.
kdidymus
Forum Contributor
Posts: 196
Joined: Tue May 13, 2008 3:37 am

Re: Please Wait message while PHP loops

Post by kdidymus »

PHP_East

Some might say you're good. Some might say you're the best.

I'd go one stage further. Yes, it works fine now. Absolutely superb. I will work on the <div> element over the weekend and hope to have the whole thing up and running next week.

Thank you so, so much again for your help.

KD.
User avatar
php_east
Forum Contributor
Posts: 453
Joined: Sun Feb 22, 2009 1:31 pm
Location: Far Far East.

Re: Please Wait message while PHP loops

Post by php_east »

thanks for the compliments. this is only a little help.
if it works fine, then good for you, hope you find this method useful for many other things.
cheers.
Post Reply