Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Dec 2007
    Posts
    9
    Thanks
    1
    Thanked 0 Times in 0 Posts

    While loop loading image

    I am try to make a script that WHILE the page is saving, it popped up with a loading image.

    I have been trying this for an hour and cant get it to work.

    Here is my base

    while (page_i <=pages)
    {

    //This is where some script should go? I have the image(cmsloading.gif) in this //folder.

    }

    Thanks for your help.

    Tyler

  • #2
    Super Moderator Inigoesdr's Avatar
    Join Date
    Mar 2007
    Location
    Florida, USA
    Posts
    3,642
    Thanks
    2
    Thanked 405 Times in 397 Posts
    You can't do that with PHP because the file is parsed, and the content is generated before it's sent to you. You should be able to accomplish that with Javascript.

  • #3
    Master Coder
    Join Date
    Jun 2003
    Location
    Cottage Grove, Minnesota
    Posts
    9,468
    Thanks
    8
    Thanked 1,085 Times in 1,076 Posts
    What do you mean by a "page saving"?

    If you mean a page loading on a user's browser,
    and they're waiting for it to load, you could use
    your animated .gif loading doo-hickey as a background
    image in a <div> section. The last thing to load on the
    page is an image that goes over the top of the <div>
    background image.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •