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.
Page 1 of 2 12 LastLast
Results 1 to 15 of 19
  1. #1
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Question How to make links in an Image slideshow open in another frame

    Hi everybody
    I've tried to change almost everything in this blending image slideshow script, but I can't figure out how to make it open links in the correct frame.
    Can you help me please?

    I've pasted the code at the end, the link to my page is here:
    http://husoghave.hosted4free.dk/

    With thanks in advance
    Kind regards
    GoGreen

    The code:

    <html>

    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>Ny side 2</title>
    <base target="indhold">
    <script language="JavaScript1.1">
    <!--

    //*****************************************
    // Blending Image Slide Show Script-
    // Dynamic Drive (www.dynamicdrive.com)
    // For full source code, visit http://www.dynamicdrive.com/
    //*****************************************

    //specify interval between slide (in mili seconds)
    var slidespeed=3000

    //specify images
    var slideimages=new Array("hoens.jpg","affald1.jpg","agurk.jpg")

    //specify corresponding links
    var slidelinks=new Array("hons.htm","affald.htm","indretning.htm")

    var newwindow=0 //open links in new window? 1=yes, 0=no

    var imageholder=new Array()
    var ie=document.all
    for (i=0;i<slideimages.length;i++){
    imageholder[i]=new Image()
    imageholder[i].src=slideimages[i]
    }

    function gotoshow(){
    if (newwindow)
    window.open(slidelinks[whichlink])
    else
    window.location=indhold[whichlink]
    }

    //-->
    </script>
    </head>

    <body bgcolor="#005300">


    <p align="center">


    &nbsp;


    <p align="center">


    <a href="javascript:gotoshow()"><img src="hoens.jpg" name="slide" border=0 style="filter:blendTrans(duration=3)" width=100 height=300></a>

    <script language="JavaScript1.1">
    <!--

    var whichlink=0
    var whichimage=0
    var blenddelay=(ie)? document.images.slide.filters[0].duration*5000 : 0
    function slideit(){
    if (!document.images) return
    if (ie) document.images.slide.filters[0].apply()
    document.images.slide.src=imageholder[whichimage].src
    if (ie) document.images.slide.filters[0].play()
    whichlink=whichimage
    whichimage=(whichimage<slideimages.length-1)? whichimage+1 : 0
    setTimeout("slideit()",slidespeed+blenddelay)
    }
    slideit()

    //-->
    </script>

    <p align="center">&nbsp;</p>

    </body>

    </html>

  • #2
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    In

    function gotoshow(){
    if (newwindow)
    window.open(slidelinks[whichlink])
    else
    window.location=indhold[whichlink]
    }

    Have you tried changing

    window.location=indhold[whichlink]


    for

    parent. framename.location=indhold[whichlink]

    Where framename is the name of your frame

  • #3
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    thanks for your answer, but...

    I'm very greatfull for yo9ur answer, thank you so much - but its still not working...

    I've tried your suggestion, both with and without a space between:
    parent. framename

    I don't know what to do. Something is completely wrong. I've even tried to make the code from scratch, inserting the filenames for the pictures again and so on - the new page is not working either.
    So if you have any other suggestions, I'll be very greatfull.

    I've even thought of making the links to open the site again using the link to the actual page and using the "stay in frames" code - but I keep thinking, that it shouldt be nessesary.

    Please - everybody... Any suggestions - any at all will be very very welcome.

    With many thanks in advance
    Kind regards
    GoGreen

  • #4
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    I have found three areas that need looking at:

    Delete

    <base target="indhold">


    In function gotoshow()

    Change

    window.location=indhold[whichlink]

    To

    parent.main.location=slidelinks[whichlink]

    Change main to the name of your frame

    In your link

    Change

    <a href="java script:gotoshow()">

    To

    <a href="#null" onclick="gotoshow()">


    I have had it working in a test frame in IE5.5

  • #5
    Senior Coder
    Join Date
    Jun 2002
    Location
    UK
    Posts
    1,137
    Thanks
    0
    Thanked 0 Times in 0 Posts
    <lecture type="short" author="brothercake">
    a technique is to use <a href="javascript:gotoshow">
    or use <a href="javascript://"> as the # takes you to the top of the page.
    </lecture>


    scroots
    Spammers next time you spam me consider the implications:
    (1) that you will be persuaded by me(in a legitimate mannor)
    (2)It is worthless to you, when i have finished

  • #6
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    Not when you use

    #null

  • #7
    Senior Coder
    Join Date
    Jun 2002
    Location
    UK
    Posts
    1,137
    Thanks
    0
    Thanked 0 Times in 0 Posts
    ok then, i didn't know you could use #null.

    you learn something new everyday.

    scroots
    Spammers next time you spam me consider the implications:
    (1) that you will be persuaded by me(in a legitimate mannor)
    (2)It is worthless to you, when i have finished

  • #8
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    We're almost there ...

    Hi everybody
    Thank you SO MUCH for all you help, now it's almost working - I'm very very greatfull for all your help.

    But theres still something... Cause when you click on the slideshow, the slideshow opens in the correct frame, but it should be the link associated with the slideshow that opens in the frame.
    Well, that's not a good explanation, you can see it here:
    http://husoghave.hosted4free.dk/

    I must have screwed up something in the script, but I don't know where. I thought I made all your suggested changes correct, but I don't know, where I went wrong.

    I've pasted the script down below, and hope you can help me once againg.

    I'm very greatfull for your help. With thanks in advance
    Kind regards
    GoGreen

    - the code -

    <html>

    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
    <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
    <meta name="ProgId" content="FrontPage.Editor.Document">
    <title>Ny side 2</title>
    <script language="JavaScript1.1">
    <!--

    //*****************************************
    // Blending Image Slide Show Script-
    // Dynamic Drive (www.dynamicdrive.com)
    // For full source code, visit http://www.dynamicdrive.com/
    //*****************************************

    //specify interval between slide (in mili seconds)
    var slidespeed=3000

    //specify images
    var slideimages=new Array("hoens.jpg","affald1.jpg","agurk.jpg")

    //specify corresponding links
    var slidelinks=new Array("hons.htm","affald.htm","indretning.htm")

    var newwindow=0 //open links in new window? 1=yes, 0=no

    var imageholder=new Array()
    var ie=document.all
    for (i=0;i<slideimages.length;i++){
    imageholder[i]=new Image()
    imageholder[i].src=slideimages[i]
    }

    function gotoshow(){
    if (newwindow)
    window.open(slidelinks[whichlink])
    else
    parent.hovedramme.location=slidelinks[whichlink]
    }

    //-->
    </script>
    <base target="hovedramme">
    </head>

    <body bgcolor="#005300">


    <p align="center">


    &nbsp;


    <p align="center">


    <a href="#null" onclick="gotoshow()"><img src="hoens.jpg" name="slide" border=0 style="filter:blendTrans(duration=3)" width=100 height=300></a>

    <script language="JavaScript1.1">
    <!--

    var whichlink=0
    var whichimage=0
    var blenddelay=(ie)? document.images.slide.filters[0].duration*5000 : 0
    function slideit(){
    if (!document.images) return
    if (ie) document.images.slide.filters[0].apply()
    document.images.slide.src=imageholder[whichimage].src
    if (ie) document.images.slide.filters[0].play()
    whichlink=whichimage
    whichimage=(whichimage<slideimages.length-1)? whichimage+1 : 0
    setTimeout("slideit()",slidespeed+blenddelay)
    }
    slideit()

    //-->
    </script>

    <p align="center">&nbsp;</p>

    </body>

    </html>

  • #9
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    Delete

    <base target="hovedramme">

    From your page, it is not required

  • #10
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Still not working correct

    Thanks, but it didn't change the fact, that its the slideshow that opens up in the frame, and not the link associated with the picture in the slideshow.

    Please, anyone - any suggestions of how to fix it???

    With thanks in advance,
    Kind regards
    GoGreen

  • #11
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    Are you wanting the page to load into the frame that contains the slideshow?

  • #12
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    Here are the files that I have been working with.

    It is a 3 frame frameset, header frame, left frame containing the slider, and a right frame

    When an image is clicked the corresponding page is loaded into the right frame.

    Add your images to the folder.
    Attached Files Attached Files

  • #13
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Dear Mr. J
    I'm very sorry that I havent given any response before now, but I've been on vacasion, and got home an hour ago.
    I'm very greatfull for your answer, which I'll try first thing in the morning. Right now I'm too tired to make any script work ;-)
    I would just like to thank you very much for your answer, and as Arnold says: I'll be back - with a description if I can make it work or not. It seem though, that you have made a very very good solution to what I need.
    Again, I thank you for ypur answer.
    Kind regards
    Hope you enjoy the nice summer
    GoGreen

  • #14
    Senior Coder
    Join Date
    Jul 2003
    Location
    My pimped-out igloo in Canadia
    Posts
    1,966
    Thanks
    36
    Thanked 0 Times in 0 Posts
    i cant help you with your script, but i do have a suggestion for the actual page (http://husoghave.hosted4free.dk/)

    everything is green, but the scrollbars are still gray. you can change their color easily by using this code to modify the colors (code goes in the <head>)

    <style>
    <!--
    BODY{
    scrollbar-face-color:#75EA00;
    scrollbar-arrow-color:brown;
    scrollbar-track-color:#EEEEEE;
    scrollbar-shadow-color:'';
    scrollbar-highlight-color:'';
    scrollbar-3dlight-color:'';
    scrollbar-darkshadow-Color:'';
    }
    -->
    </style>

    and just make them the appropriate colors
    Before you criticize someone, you should walk a mile in their shoes. That way, when you criticize them, you're a mile away and you have their shoes :)

  • #15
    New Coder
    Join Date
    Aug 2002
    Posts
    10
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hi everybody
    First of all I would like to thank you all for your help regarding the slideshow and the suggestions for making colors on my scrollbar.

    First regarding the links/images-script:
    Dear Mr J, when I downloaded your file it worked fine, however I can't make it work with the coding in my own frames. I don't know why...

    Dear canadianjameson, a very good sugestion, thanks. I've tried it out, however I can't seem to figure out how to place the code in my stylesheet (css). It works fine, if I put the code on each and every page, but I would like to be able to make quick changes in colors and so on at my homepage, therefore I use the stylesheet and not a code on each of my pages.
    When I figure out how to make the changes in my stylesheet, I'll make the changes on my site. Thanks for your suggestion.

    Back to the blending-image-slide-show: I've given up...
    I've use many many hours to make the links associates with each picture to open correct in the frame. And you guys/girls have been more than helpfull, even though its still not working. SO...

    Do you have any other suggestions for something nice, that could "spice up" my homepage INSTEAD of this particular slideshow, I would be very greatfull.

    For now I'll just look around for something new, which I hope, I can make work.

    Thank you all for your time and efforts.

    Kind regards
    GoGreen


  •  
    Page 1 of 2 12 LastLast

    Posting Permissions

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