Results 1 to 8 of 8

Thread: How to put two same scripts in one BODY?

  1. #1
    Join Date
    Apr 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default How to put two same scripts in one BODY?

    1) Script Title: Translucent Slide Show Script

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



    -->

    I want to use this translucent slide show script. but i wan to put two of them in the <body> but there will be error on page if i put two of them.

    So how do i modify it so the body can contain two of the same script?

  2. #2
    Join Date
    Jul 2006
    Location
    Canada
    Posts
    2,581
    Thanks
    13
    Thanked 28 Times in 28 Posts

    Default

    Put the script in the <head> and seperate each instance with a semicolon:
    Code:
    window.onload=startit;startit
    - Mike

  3. #3
    Join Date
    Sep 2005
    Location
    India
    Posts
    1,627
    Thanks
    6
    Thanked 107 Times in 107 Posts

    Default

    A simple solution for having two Translucent slideshow Script based slideshows in a single page is using IFrame.

    The way this script is designed this requires more work on it to make this script a more reusable one but without wasting the time if you want to display two slideshows in a single page you can go for an IFrame in which you can load your second slideshow.

    Code:
    <iframe frameborder="0" height="225" src="3.htm" width="100%" scrolling="no"></iframe>
    You can place the above kind of code in your page where you have the first slideshow already.

    3.htm is the page where you have placed the second slideshow which you want. This slideshows will be displayed as if they are a part of single page.

    The height and width of the IFrame can be altered based on the image height width of your second slideshow.

    Quote Originally Posted by mburt
    window.onload=startit;startit
    I wonder how this is going to start two different slideshows in the same page?

  4. #4
    Join Date
    Apr 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Hmmm

    er.. thanks for the help..

    but, to use the iframe, for the 2nd slideshow to be loaded..

    i don't have another page where by i put my that slideshow inside.

    I'm doing the coding inside blogspot... therefore.. there is only one template where by i do all the coding inside.

    so the two translucent slide shows will be in the same page of coding.

  5. #5
    Join Date
    Sep 2005
    Location
    India
    Posts
    1,627
    Thanks
    6
    Thanked 107 Times in 107 Posts

    Default

    In that case have to redesign the script in such a way that it will work with more than one slideshows.

  6. #6
    Join Date
    Apr 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Haa... thats why i'm asking here how to redesign it... so that it can work together...

    i know there is something i have to change inside the coding.. but i do not know which value i have to change..

  7. #7
    Join Date
    Sep 2005
    Location
    India
    Posts
    1,627
    Thanks
    6
    Thanked 107 Times in 107 Posts

    Default

    It is not like changing a single value and suddenly the script start to work with multiple slideshows. You have to completely redesign the way the script developed at the moment.

    A complete redesign will take some time.

    Another solution is if you have a site you can create a page in that site and using IFrame from your blog page access them and it will display the second slidshow perfectly.

    If you don't have a site then you can try a free hosting provider who hosts page without any ad and that will do your goal.

  8. #8
    Join Date
    Apr 2006
    Posts
    4
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    ok. thanks for the replies.. i'll think about doing the coding. =)

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
  •