Results 1 to 8 of 8

Thread: AJAX ROTATING INCLUDES SCRIPT (Dec 14/05 updated)

  1. #1
    Join Date
    Oct 2004
    Location
    Montreal Canada
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question AJAX ROTATING INCLUDES SCRIPT (Dec 14/05 updated)

    Struggling to get this to work on my index page. Thought maybe conflict with other scripts on the page, so put up a page with this script only on it. GRR..still doesn’t work! If anyone could take a look at the page source for a clue, would be most appreciated. http://www.rvrg.com/Q2Q.html
    I am trying to generate random quotes. For each quote I made a separate .html file (labelled file1.html, file2.html, etc.) & put them into a folder (files_array) in the httpdocs. Big thanks in advance for any assistance!

    DD script link http://www.dynamicdrive.com/dynamici...ajaxrotate.htm
    Last edited by rvrg; 02-23-2006 at 12:10 PM.

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

    Default

    Warning: Please include a link to the DD script in question in your post. See this thread for the proper posting format for asking a question.

    I do see an error with your configuration, at the line:

    Code:
    var rootdomain="http://"rvrg.com/files_array"
    There's an extra double quotes in your URL. It should read:

    Code:
    var rootdomain="http://rvrg.com/files_array"
    I'm not sure if this is the only error, but try fixing it first.

  3. #3
    Join Date
    Oct 2004
    Location
    Montreal Canada
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thanks for taking the time to scrutinize the script. I have corrected & loaded the page up again, but no luck. I am wondering if I have incorrectly named the folder holding the files?

  4. #4
    Join Date
    Oct 2004
    Location
    Montreal Canada
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question AJAX ROTATING INCLUDES SCRIPT (Dec 14/05 updated)

    Help please!
    I am trying to generate random quotes to appear on my index page. Thought other javascript on the page might be conflicting, so have made testing page http://www.rvrg.com/Q4Q.html
    When it is working (!) will transfer the corrected code to the index page. For each quote, I created a separate .html page & these pages are within a folder, http://www.rvrg.com/ajaxfiles
    The quote pages are http://www.rvrg.com/ajaxfiles/file1.html, http://www.rvrg.com/ajaxfiles/file2.html, http://www.rvrg.com/ajaxfiles/file3.html, etc. There are 14 file pages.
    Everything has been loaded up, nothing is working, assistance would be MOST appreciated.

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

    Default

    Ok, I see a couple of ther basic errors. Firstly, inside the line:

    Code:
    var includefiles=[...."files_array/file50.html",]
    The very last entry should NOT contain an comma at the end! In other words, it should read:

    Code:
    var includefiles=[...."files_array/file50.html"]
    Then, for the line:

    Code:
    url=files_array[http:www.rvrg.com]
    It should read:

    Code:
    url=files_array[url]

  6. #6
    Join Date
    Oct 2004
    Location
    Montreal Canada
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question AJAX ROTATING INCLUDES SCRIPT (Dec 14/05 updated) Reply to Thread

    Thank you. Made the corrections, but still problems. I have TWO test pages loaded:
    #1
    http://www.rvrg.com/Q2Q.html (with files named http://www.rvrg.com/files_array/file1.html, http://www.rvrg.com/files_array/file2.html, etc. in folder http://www.rvrg.com/files_array). There are 50 files in the folder.
    #2
    http://www.rvrg.com/Q4Q.html (with files named http://www.rvrg.com/ajaxfiles/file1.html, http://www.rvrg.com/ajaxfiles/file2.html, etc. in folder http://www.rvrg.com/ajaxfiles). There are 14 files in the folder.

    I created Q4Q because I thought perhaps I had made a mistake naming the files.
    Now, Q4Q is sort of working BUT showing the same quote many, many times, and always the same quote (file6). Please take a look http://www.rvrg.com/Q4Q.html

    I have made your corrections to both Q2 and Q4 & reloaded them on my site. I have checked in different browsers, reloaded, cleared cache, etc. Also, viewed page source to make sure that I was viewing most recent upload.
    PS - Did you notice my FAVICON on the site? Thank you for providing that great little visual, although must add to other posters that it did seem to take forever for it to appear. Patience..sigh! Seems to be a key ’design skill’.
    Last edited by rvrg; 02-25-2006 at 11:13 AM.

  7. #7
    Join Date
    Oct 2004
    Location
    Montreal Canada
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Cool

    HOORAY! Finally works. The problem was in my file pages. Funny because that was my first guess. Anyway, the quotes are up & running on my index page with just a little cosmetic tweaking left to do. Anyone care to admire? http://rvrg.com

    to DDadmin:THANKS for help over the past few days

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

    Default

    Hi:
    Glad it works However, in IE, I still get a few JS errors that pop up. I'm not sure which script on your page is causing it, as there are a few of them. You may want to remove any unnecessary JavaScripts on that page.

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
  •