Results 1 to 5 of 5

Thread: Help with Window Widget

  1. #1
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question Help with Window Widget

    ) Script Title: DHTML Window widget (v1.01)

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...ndow/index.htm

    3) Describe problem:

    Hi All,

    This might be a bit of a left field question, but I am currently utilising the window widget dhtml script to inform customers of our current specials via loading a graphic internally in the window.

    What I would like to do if possible would have a directory of files and have the widget randomly pick a graphic too display for months where we run multiple specials.

    I also want to build in the ability to "see other specials" by clicking a link and it loading the next image in order... but I think I can manage that one myself.

    any ideas to the random problem?

    oh, if required this is my site currently with the widget in action: http://www.gcphotography.com.au if that helps any...

    I can also post code or any more information.

    Kind Regards,

    Matt

  2. #2
    Join Date
    Aug 2004
    Posts
    10,140
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Well, a random image JavaScript may do the trick depending on your needs. If you want something that automatically scans a directory of files to pick one from, you'll need a server side script for that, such as PHP. Since you're using the iframe option to load a DHTML window, the page to load can in fact be a .php page itself that does what you want.

  3. #3
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I think the random image javascript should do the job.

    Any tips on implementing it into the window widget code?

  4. #4
    Join Date
    Aug 2004
    Posts
    10,140
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Basically all you're doing is inserting the desired script inside the page that's being shown in the iframe. There's no extra step involved because of the DHTML widget script per say.

  5. #5
    Join Date
    Mar 2007
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I put in the randomiser code... worked a treat...

    I also put in a java code to refresh the page every 15 seconds:

    <META HTTP-EQUIV="refresh" CONTENT="15">

    I'm wondering because I used that is there another peice of code I can use to act as a pause button for this peice of code, or do I need a whole packaged developed accordingly for that?

    Cheers,

    Matt

Bookmarks

Posting Permissions

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