Extend Image Selector to also display different href?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Guest's Avatar

    Extend Image Selector to also display different href?

    Could someone help extend this ChangeImage function to also display a
    different hyperlink underneath the newly selected image?:

    <script language="javas cript">
    <!--

    /*Combo Box Image Selector:
    By JavaScript Kit (www.javascriptkit.com)
    Over 200+ free JavaScript here!
    */

    function showimage()

    {
    if (!document.imag es)
    return
    document.images .pictures.src=
    document.userna me.u_BrokerID.o ptions[document.userna me.u_BrokerID.s electedIn
    dex].value
    }
    //-->
    </script>



    <form name="username" method=post action="join_st ep4.asp" onSubmit="retur n
    CheckForm();">
    <SELECT NAME='u_BrokerI D' size='1' onChange='showi mage()'><OPTION
    VALUE='0'>--Select a Broker--</OPTION><option
    value="/catamaranco/images/brokers/john_2.jpg">Joh n Anderson</option><option
    value="http://www.catamaranco .com/images/brokers/staley_2.jpg">S taley
    Weidman </option>
    <input type=submit value=submit>
    </form>

    <br><br>

    <a href="Site1.asp ">Change this url depending on the value of the image
    selected in the dropdown?</a>


  • Ray Costanzo [MVP]

    #2
    Re: Extend Image Selector to also display different href?

    You may want to try asking in a client-side scripting group such as
    microsoft.publi c.scripting.jsc ript, as this group only focuses on
    server-side ASP programming.

    Ray at work

    <jason@catamara nco.com> wrote in message
    news:uZlHw8EkEH A.2664@TK2MSFTN GP11.phx.gbl...[color=blue]
    > Could someone help extend this ChangeImage function to also display a
    > different hyperlink underneath the newly selected image?:
    >
    > <script language="javas cript">
    > <!--
    >
    > /*Combo Box Image Selector:
    > By JavaScript Kit (www.javascriptkit.com)
    > Over 200+ free JavaScript here!
    > */
    >
    > function showimage()
    >
    > {
    > if (!document.imag es)
    > return
    > document.images .pictures.src=
    > document.userna me.u_BrokerID.o ptions[document.userna me.u_BrokerID.s electedIn
    > dex].value
    > }
    > //-->
    > </script>
    >
    >
    >
    > <form name="username" method=post action="join_st ep4.asp" onSubmit="retur n
    > CheckForm();">
    > <SELECT NAME='u_BrokerI D' size='1' onChange='showi mage()'><OPTION
    > VALUE='0'>--Select a Broker--</OPTION><option
    > value="/catamaranco/images/brokers/john_2.jpg">Joh n
    > Anderson</option><option
    > value="http://www.catamaranco .com/images/brokers/staley_2.jpg">S taley
    > Weidman </option>
    > <input type=submit value=submit>
    > </form>
    >
    > <br><br>
    >
    > <a href="Site1.asp ">Change this url depending on the value of the image
    > selected in the dropdown?</a>
    >
    >[/color]


    Comment

    • Guest's Avatar

      #3
      Re: Extend Image Selector to also display different href?

      Apologies...tha t was my intention!
      "Ray Costanzo [MVP]" <my first name at lane 34 dot commercial> wrote in
      message news:%235AYrBFk EHA.3140@TK2MSF TNGP15.phx.gbl. ..[color=blue]
      > You may want to try asking in a client-side scripting group such as
      > microsoft.publi c.scripting.jsc ript, as this group only focuses on
      > server-side ASP programming.
      >
      > Ray at work
      >
      > <jason@catamara nco.com> wrote in message
      > news:uZlHw8EkEH A.2664@TK2MSFTN GP11.phx.gbl...[color=green]
      > > Could someone help extend this ChangeImage function to also display a
      > > different hyperlink underneath the newly selected image?:
      > >
      > > <script language="javas cript">
      > > <!--
      > >
      > > /*Combo Box Image Selector:
      > > By JavaScript Kit (www.javascriptkit.com)
      > > Over 200+ free JavaScript here!
      > > */
      > >
      > > function showimage()
      > >
      > > {
      > > if (!document.imag es)
      > > return
      > > document.images .pictures.src=
      > >[/color][/color]
      document.userna me.u_BrokerID.o ptions[document.userna me.u_BrokerID.s electedIn[color=blue][color=green]
      > > dex].value
      > > }
      > > //-->
      > > </script>
      > >
      > >
      > >
      > > <form name="username" method=post action="join_st ep4.asp"[/color][/color]
      onSubmit="retur n[color=blue][color=green]
      > > CheckForm();">
      > > <SELECT NAME='u_BrokerI D' size='1' onChange='showi mage()'><OPTION
      > > VALUE='0'>--Select a Broker--</OPTION><option
      > > value="/catamaranco/images/brokers/john_2.jpg">Joh n
      > > Anderson</option><option
      > > value="http://www.catamaranco .com/images/brokers/staley_2.jpg">S taley
      > > Weidman </option>
      > > <input type=submit value=submit>
      > > </form>
      > >
      > > <br><br>
      > >
      > > <a href="Site1.asp ">Change this url depending on the value of the image
      > > selected in the dropdown?</a>
      > >
      > >[/color]
      >
      >[/color]


      Comment

      Working...