Pass a url variable to javascript for drop down menu

Hello,
I'm in over my head as far as javascript goes. This is what I
am trying to do. I have this URL...
http://www.grasshorse.com/prod2.cfm?SortBy=all&ProdAbbr=shm
I want to take the variable for ProdAbbr which in this case
is "shm" and make that a variable in javascript. So that I can add
the variable to a dynamic link I'm using for a drop down menu.
mm_menu_0520211545_0.addMenuItem("All Departments","location='prod.cfm?SortBy=all&ProdAbb r=eval(ProdAbbr)'");
I really have no clue what to do. I haven't hardly used
javascript at all and I'm looking for some charity. Does anyone
have any ideas on how I can do this?
Thanks
Steve
Any insight is greatly appreciated.

jawwinker wrote:
> Hello,
> I'm in over my head as far as javascript goes. This is
what I am trying to
> do. I have this URL...
>
> <a target=_blank class=ftalternatingbarlinklarge
> href="
http://www.grasshorse.com/prod2.cfm?SortBy=all&ProdAbbr=shm
>
> I">
http://www.grasshorse.com/prod2.cfm?SortBy=all&ProdAbbr=shm
>
> I</a> want to take the variable for ProdAbbr which
in this case is "shm" and
> make that a variable in javascript. So that I can add
the variable to a
> dynamic link I'm using for a drop down menu.
>
>
mm_menu_0520211545_0.addMenuItem("All Departments","location='prod.cfm?Sort
> By=all&ProdAbbr=eval(ProdAbbr)'");
mm_menu_0520211545_0.addMenuItem("All Departments","location='prod.cfm?Sort
By=all&ProdAbbr='"+ProdAbbr+"'");
Mick

Similar Messages

  • Code placement for drop down menu within an animated button

    I have a main menu comprised of 7 buttons; 6 of which are all
    straight forward with an animation. (The animation is that when the
    buttons are rolled over the button extends itself out to the right.
    On the rollout the button returns to its original state.) The 6 all
    function fine.
    The 7th menu button is the same idea but with the edition of
    a two button drop down menu that appears when the main button is
    rolled over. The roll over part is fine. My problem is moving the
    cursor off the main button to get to the sub-menu items without
    having them disappear once the cursor if off the main 7th button.
    Within the time line of the 7th button (all of the buttons
    are movie clip buttons) I put an invisible button, removing the
    sections over both the main button and the sub buttons. I have
    tried the following:
    (I should point out that the labels within the button for the
    animation are an _up, _over and _out states...the buttons animate
    out in the _over label and animate back to the original position in
    the _out label,)
    The code and where I have (unsuccessfully) tried placing it
    are as follows:
    1.) On the invisible button itself (within the main button):
    on (rollOver) {
    gotoAndPlay("_out");
    2.) On the Actions layer (within the main button):
    invisible_btn.onRollOver = function () {
    gotoAndPlay("_out");
    3.) On the Actions layer (on the main timeline...which is
    where the code for the other 6 buttons is and running as should):
    btnMusic_mc.invisible_btn.onRollOver = function () {
    btnMusic_mc.gotoAndPlay("_out");
    4.) Just a slight variation of #3 (still on the Actions layer
    of the main timeline):
    btnMusic_mc.invisible_btn.onRollOver = function () {
    brnMusic_mc.invisible_btn.gotoAndPlay("_out");
    The result for all four of these options has been the same.
    In rolling over the main button (btnMusic_mc) it does animate out
    as it should, exposing the two sub buttons. But moving the cursor
    off the btnMusic_mc neither allows me to reach the sub buttons nor
    does the btnMusic_mc animate back to its first position (as it
    should). It just snaps back into that position.
    Clearly I am missing something here. Any thoughts would be
    appreciated.

    Here is what it should read, and does on Safari:
    Rates and Hours
    FAQ - Yoga
    FAQ - Reiki
    FAQ - Massage
    No, it shouldn't and it doesn't. It should look like :
    Rates, Hours, Reservations
    Rates and Hours
    FAQ - Yoga
    FAQ - Reiki
    FAQ - Massage
    FAQ and Reserve - Training
    Here's the correct part :
    <select>
              <option value="">Rates, Hours, Reservations</option>
              <option value="http://yogareikimassage.com/MG/Rates.html*_top">Rates and Hours</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Yoga.html*_top">FAQ and Reserve - Yoga</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Reiki.html*_top">FAQ and Reserve - Reiki</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Massage.html*_top">FAQ and Reserve - Massage</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Personal_Training.html*_top">FAQ and Reserve - Training</option>
    </select>
    The <select> item was missing. And if you don't want the first line in the menu (Rates, Hours, Reservations) then don't enter it in the first place.
    BTW, it's not a dropdown menu. It's a selection list in a form.

  • Creating of a badi for drop down menu in ADobe form

    Hi ,
    Can you let me know what FM ( Function module ) should i use
    for creating a  drop down menu for a field in the Adobe form in the
    Badi ..
    This Badi is attached to the field in the smart form..
    Or a F4 help created  in the Badi  will serve the purpose...( it will act
    as a drop down menu for the field.. )..
    Let me know as soon as possible ..
    Thanks .
    Om

    Drop down menus, loke some other festures, aren’t available at that time.
    But there is a fine widget to achieve that:
    Forms+ Bundle Widget – Widgets.Mu

  • Auto-fill for drop down menu

    I fill a drop-down menu with 200+ part numbers. How can i implement the capability
    to type the first few numbers/letters to jump to the nearest part number
    beginning with my input?

    nathan wrote:
    > I can key focus the control and it opens when i hit the space bar. I type
    > the complete part number i can see on the list and hit enter. It picks the
    > first selection on the list. I doesn't select the one i type. Does it work
    > for anyone else?
    >
    > Ernie Howard wrote:
    > >Try: Key focus the control, hit the space bar, start typing, hit return.>>nathan
    > wrote> >> Greg McKaskle wrote> >> I fill a
    > drop-down menu with 200+ part numbers. How can i implement the>> capability>>
    > to type the first few numbers/letters to jump to the nearest>> part number>>
    > beginning with my input?>>Any ring or menubar menu should support>> type
    > ahead when it gets key f
    ocus.>The menu will of course work better if>> it
    > is sorted.>>Greg McKaskle>> I'm using Labview 5.0 with the menu ring. It
    > is not supporting type ahead.>> It gets the focus and the only helpful function
    > is the 'page down' key. Any>> ideas?
    I think the problem may be with the speed that the comparisons are made.
    If I type as fast as I can, I can get to the correct Number. If I pause for
    very long (1/2 sec ??? ) during the typing it will stall out at the last match.
    I am not sure if there are any settings for the keyboard (like typematic rate)
    that would help any. Since most part numbers (at least the ones I use) are
    in sequence this may be a real problem.
    Ex.
    323-1234-001
    323-1234-002
    It would be very difficult for me to get to the -002
    I can type 30 wpm but the words are gibberish !!
    Kevin Kent
    Attachments:
    Kevin.Kent.vcf ‏1 KB

  • JavaScript and Drop down menu help?

    Hi,
    I'm having trouble trying to get options in my drop down menu to update in another section. I have the below script in a hidden field and everything seems to be working but it keeps picking up the last line only when doing calculations (i.e 48) when I change it in the drop down menu to say "HBZ-200" which has the value of 200 it is still only picking up the last line and value of 48.
    So to put a little perspective on things the below script is in a hidden field called stndwatt, I then want to calculate that in another hidden field called calc which has the following calculations - (Qty3+ballconsump)-stndwatt, this should then update my visible field called ElectYear1 which then has the calculations of - (Qty1+Qty2)*(Qty4*Qty5*Qtycost*calcs*weeksinyear)/1000, as far as I can work out my stndwatt field is only picking up the last line below which is 48.
    I'm sorry if this is vague I'm not very familar with JavaScript or PDF forms and have been scratching my head all day with this.
    var v = this.getField("ProductLineOne").value;
    if (v=="T101221W-30 (3000K T10 LED Tube)") event.value = "21";
    else if (v=="T101221W-40 (4000K T10 LED Tube)") event.value = "21";
    else if (v=="T101221W-50 (5000K T10 LED Tube)") event.value = "21";
    else if (v=="T101221W-60 (6000K T10 LED Tube)") event.value = "21";
    else if (v=="HBZ-100 (100W LED High Bay)") event.value = "100";
    else if (v=="HBZ-150 (150W LED High Bay)") event.value = "150";
    else if (v=="HBZ-200 (200W LED High Bay)") event.value = "200";
    else if (v=="ZSL-48W (48W LED Shop Light)") event.value = "48";

    Are you sure the code you posted here is EXACTLY the same as the code in
    your file? Did you copy&paste it?
    If so, can you share the file in question?

  • Trouble with iWeb code snippet for drop down menu

    Hello,
    So, I'm having a bit of trouble figuring this out and it goes beyond my knowledge, to be honest. I'm working on a website for someone and when viewed in Safari for Mac or iPad or even iPhone, it all works out great. But, when viewed in any other browser for Mac or Windows, the drop down doesn't display the "menu heading," only what should be the first drop down selection. Not only that, that page now becomes "unselectable" and more or less dead.
    Here is what it should read, and does on Safari:
    Rates and Hours
    FAQ - Yoga
    FAQ - Reiki
    FAQ - Massage
    On all other browsers, it displays the FAQ - Yoga option as the "title" and only displays the other two options. So, is this something that can be fixed in the code snippet or is what I'm seeing a more involved HTML issue that would require actual skills to fix? Any help or direction would be greatly appreciated because I'd love to get this knocked out and also pick something up in addition. If I have to edit the actual HTML pages themselves I could do that as well; I've got an editor and have done that for my own site when needed. Anyway, thank you very much in advance!
    Her
    <html>
    <title></title>
    <head>
    <script>
    <!--
    function land(ref, target)
    lowtarget=target.toLowerCase();
    if (lowtarget=="_self") {window.location=loc;}
    else {if (lowtarget=="_top") {top.location=loc;}
    else {if (lowtarget=="_blank") {window.open(loc);}
    else {if (lowtarget=="_parent") {parent.location=loc;}
    else {parent.frames[target].location=loc;};
    function jump(menu)
    ref=menu.choice.options[menu.choice.selectedIndex].value;
    splitc=ref.lastIndexOf("*");
    target="";
    if (splitc!=-1)
    {loc=ref.substring(0,splitc);
    target=ref.substring(splitc+1,1000);}
    else {loc=ref; target="_self";};
    if (ref != "") {land(loc,target);}
    //-->
    </script>
    </head>
    <body>
    <style type="text/css">
    <!--
    .combobox {
    background-color: #fef3e2;
    color: #463c3c;
    font-size: 13pt;
    font-family: optima;
    font-weight: normal;
    font-style: none;
    -->
    </style>
    <form action="dummy" method="post"><select name="choice" size="1" class="combobox" onChange="jump(this.form)"
    <option value="">Rates, Hours, Reservations</option>
    <option value="http://yogareikimassage.com/MG/Rates.html*_top">Rates and Hours</option>
    <option value="http://yogareikimassage.com/MG/FAQ_-_Yoga.html*_top">FAQ and Reserve - Yoga</option>
    <option value="http://yogareikimassage.com/MG/FAQ_-_Reiki.html*_top">FAQ and Reserve - Reiki</option>
    <option value="http://yogareikimassage.com/MG/FAQ_-_Massage.html*_top">FAQ and Reserve - Massage</option>
    <option value="http://yogareikimassage.com/MG/FAQ_-_Personal_Training.html*_top">FAQ and Reserve - Training</option>
    </select>
    </form>
    </body>
    </html>

    Here is what it should read, and does on Safari:
    Rates and Hours
    FAQ - Yoga
    FAQ - Reiki
    FAQ - Massage
    No, it shouldn't and it doesn't. It should look like :
    Rates, Hours, Reservations
    Rates and Hours
    FAQ - Yoga
    FAQ - Reiki
    FAQ - Massage
    FAQ and Reserve - Training
    Here's the correct part :
    <select>
              <option value="">Rates, Hours, Reservations</option>
              <option value="http://yogareikimassage.com/MG/Rates.html*_top">Rates and Hours</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Yoga.html*_top">FAQ and Reserve - Yoga</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Reiki.html*_top">FAQ and Reserve - Reiki</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Massage.html*_top">FAQ and Reserve - Massage</option>
              <option value="http://yogareikimassage.com/MG/FAQ_-_Personal_Training.html*_top">FAQ and Reserve - Training</option>
    </select>
    The <select> item was missing. And if you don't want the first line in the menu (Rates, Hours, Reservations) then don't enter it in the first place.
    BTW, it's not a dropdown menu. It's a selection list in a form.

  • - Looking for Drop Down menu script w/ semi-transparent backgrounds...

    Looking for a dropdown menu script that will allow
    semi-transparent
    backgrounds (so we can partly see what the list is displaying
    over).
    I've Googled this to death using all the obvious keywords,
    but have yet to
    find what I'm looking for.
    Thanks.

    Yes. I understand and agree. Good point.
    Thanks.
    Al Sparber - PVII
    http://www.projectseven.com
    Extending Dreamweaver - Nav Systems | Galleries | Widgets
    Authors: "42nd Street: Mastering the Art of CSS Design"
    "T.Pastrana - 4Level" <[email protected]> wrote in message
    news:[email protected]...
    >I posted mainly for the benefit of Reese, I know you know
    this.
    >
    >
    > --
    > Best Regards,
    > ..Trent Pastrana
    > www.fourlevel.com
    >
    >
    >
    >
    >
    >
    > "Al Sparber- PVII" <[email protected]>
    wrote in message
    > news:[email protected]...
    >> Actually, it's not an error. But we do happen to
    have it in a CC on
    >> that page because the last time I posted that page
    on this forum it
    >> was criticized for "failing" the W3C CSS validator.
    >>
    >>
    http://www.projectseven.com/foxy.gif
    >>
    >> The Firefox console simply would report it as a
    warning - not an
    >> error. It would have no affect on the page. But
    thanks for pointing
    >> that out.
    >>
    >> --
    >> Al Sparber - PVII
    >>
    http://www.projectseven.com
    >> Extending Dreamweaver - Nav Systems | Galleries |
    Widgets
    >> Authors: "42nd Street: Mastering the Art of CSS
    Design"
    >>
    >>
    >>
    >>
    >> "T.Pastrana - 4Level" <[email protected]> wrote in
    message
    >> news:[email protected]...
    >>> If you want your page to validate you might want
    to separate the
    >>> properties. Some modern browsers like Firefox
    will throw an error
    >>> with the filter property.
    >>>
    >>> #menu li {
    >>> opacity: 0.85;
    >>> }
    >>>
    >>> <!--[if IE]><style
    type="text/css">#menu li {filter:
    >>>
    alpha(opacity=85);}</style><![endif]-->
    >>>
    >>>
    >>> --
    >>> Best Regards,
    >>> ..Trent Pastrana
    >>> www.fourlevel.com
    >>>
    >>>
    >>>
    >>>
    >>> "Al Sparber- PVII"
    <[email protected]> wrote in message
    >>> news:[email protected]...
    >>>> If, for example, you are using an unordered
    list for your menu, set
    >>>> opacity on the LI, like so:
    >>>>
    >>>> #menu li {
    >>>> opacity: 0.85;
    >>>> filter: alpha(opacity=85);
    >>>> }
    >>>>
    >>>> As far as I know, there are no
    "off-the-shelf" menu tools of worth
    >>>> that offer this as an automatic option. You
    should pick yourself a
    >>>> good menu system then set opacity on the
    relevant element. The
    >>>> menu "script" or "system" really has nothing
    to do with it.
    >>>>
    >>>> If you need a good base menu system, you can
    find free ones and
    >>>> commercial ones on our site. Here is an
    example of one with
    >>>> transparency:
    >>>>
    >>>>
    http://www.projectseven.com/products/menusystems/pmm/css_tweaks/opacity/
    >>>>
    >>>>
    >>>>
    >>>> --
    >>>> Al Sparber - PVII
    >>>>
    http://www.projectseven.com
    >>>> Extending Dreamweaver - Nav Systems |
    Galleries | Widgets
    >>>> Authors: "42nd Street: Mastering the Art of
    CSS Design"
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> "Reese" <[email protected]> wrote in message
    >>>> news:[email protected]...
    >>>>> Looking for a dropdown menu script that
    will allow
    >>>>> semi-transparent backgrounds (so we can
    partly see what the list
    >>>>> is displaying over).
    >>>>>
    >>>>> I've Googled this to death using all the
    obvious keywords, but
    >>>>> have yet to find what I'm looking for.
    >>>>>
    >>>>> Thanks.
    >>>>>
    >>>>
    >>>
    >>>
    >>
    >
    >

  • CSS Drop down menu; how to align the right edge of drop down and parent menu?

    Hello everyone,
    I have a drop-down menu that is currently working well.
    The only change I need to make is to have the right edge of the  drop-down menu to align with the right edge of the parent menu. When you  hover over the menu, it currently "drops" down and to the right, with  the left edges aligned.
    I want the menu to "drop" down and to the left, so the right edges are aligned.
    I have tried fiddling with floats and absolute/relative positioning. I'm not sure what needs to be changed.
    Any help you can provide is greatly appreciated! I'm learning via "cut and paste", so please go easy on any terminology you may use.
    Thank you!
    Here is my code:
    .chromestyle{
         width: 100%;
         font-weight: bold;
         float: left;
         height: 29px;
    .chromestyle:after{ /*Add margin between menu and rest of content in Firefox*/
    content: ".";
    display: block;
    height: 0;
    clear: both;
    visibility: hidden;
    .chromestyle ul{
    border: 0px solid #BBB;
    width: 100%;
    background: url(chromebg.gif) center center repeat-x; /*THEME CHANGE HERE*/
    padding: 4px 0;
    margin: 0;
    text-align: right; /*set value to "left", "center", or "right"*/
    .chromestyle ul li{
    display: inline;
    .chromestyle ul li a{
    color: #000000;
    padding: 4px 7px;
    margin: 0;
    text-decoration: none;
    border-left: 1px solid #DADADA;
    .chromestyle ul li a:hover, .chromestyle ul li a.selected{ /*script dynamically adds a class of "selected" to the current active menu item*/
    background: url(chromebg-over.gif) center center repeat-x; /*THEME CHANGE HERE*/
    /* ######### Style for Drop Down Menu ######### */
    .dropmenudiv{
    position:absolute;
    top: 0;
    border: 1px solid #BBB; /*THEME CHANGE HERE*/
    border-bottom-width: 0;
    font:normal 12px Verdana;
    line-height:18px;
    z-index:100;
    background-color: white;
    width: 200px;
    visibility: hidden;
    .dropmenudiv a{
    width: auto;
    display: block;
    text-indent: 3px;
    border-bottom: 1px solid #BBB; /*THEME CHANGE HERE*/
    padding: 2px 5px;
    text-decoration: none;
    font-weight: bold;
    color: black;
    * html .dropmenudiv a{ /*IE only hack*/
    width: 100%;
    .dropmenudiv a:hover{ /*THEME CHANGE HERE*/
    background-color: #0000ff;
    color: #fff200;

    Try this:
    .chromestyle{
         font-weight: bold;
         height: 29px;
    .chromestyle:after{ /*Add margin between menu and rest of content in Firefox*/
    content: ".";
    display: block;
    height: 0;
    clear: both;
    visibility: hidden;
    .chromestyle ul{
    border: 0px solid #BBB;
    width:100%;
    background: url(chromebg.gif) center center repeat-x; /*THEME CHANGE HERE*/
    padding: 4px 0;
    margin: 0;
    text-align: left; /*set value to "left", "center", or "right"*/
    .chromestyle ul li{
    display: inline;
    .chromestyle ul li a{
    color: #000000;
    padding: 4px 7px;
    margin: 0;
    text-decoration: none;
    border-left: 1px solid #DADADA;
    .chromestyle ul li a:hover, .chromestyle ul li a.selected{ /*script dynamically adds a class of "selected" to the current active menu item*/
    background: url(chromebg-over.gif) center center repeat-x; /*THEME CHANGE HERE*/
    /* ######### Style for Drop Down Menu ######### */
    .dropmenudiv{
    position:absolute;
    top: 0;
    border: 1px solid #BBB; /*THEME CHANGE HERE*/
    border-bottom-width: 0;
    font:normal 12px Verdana;
    line-height:18px;
    z-index:100;
    background-color: white;
    visibility: hidden;
    text-align:left;
    .dropmenudiv a{
    width: auto;
    display: block;
    border-bottom: 1px solid #BBB; /*THEME CHANGE HERE*/
    padding: 3px;
    text-decoration: none;
    font-weight: bold;
    color: black;
    * html .dropmenudiv a{ /*IE only hack*/
    width: 100%;
    .dropmenudiv a:hover{ /*THEME CHANGE HERE*/
    background-color: #0000ff;
    color: #fff200;
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    http://alt-web.com/
    http://twitter.com/altweb

  • How to pass a jsp variable into javascript??

    <p><%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c" %>
    <p><%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn" %>
    <p><html>
    <p><c:set var="binrmapi" value="http://localhost/paas-api/bingorooms.action;jsessionid=XXXXXX?userId=TEST2&sessionId=1&key=1" />
    <p><c:import var="testbinrm" url="${fn:replace(binrmapi, 'XXXXXX', jsessionid)}"/>
    <p><c:set var="tuples" value="${fn:split(testbinrm, '><')}" />
    <p>Time until next game
    <p><c:forEach var="tuple" items="${tuples}">
    <p><c:if test="${fn:contains(tuple, 'row ')}">
    <p> <p><code>
    <p> <c:set var="values" value="${fn:split(tuple, '=\"')}" />
    <p> <font color="blue">
    <p> <c:out value="${values[17]}" />
    <p><c:set var="remainingtime" value="${values[17]}" />
    <p> </font>
    <p> </code>
    <p></c:if>
    <p></c:forEach>
    <p><form name="counter"><input type="text" size="8" name="d2"></form>
    <p><script>
    <p>var milisec=0
    <p>var seconds=eval("document.myForm.remaining").value;
    <p>function display(){
    <p> if (milisec<=0){
    <p> milisec=9
    <p> seconds-=1
    <p>}
    <p>if (seconds<=-1){
    <p> milisec=0
    <p> seconds+=1
    <p> }
    <br>else
    <p> milisec-=1
    <p> document.counter.d2.value=seconds+"."+milisec
    setTimeout("display()",100)
    <p>}
    <p>display()
    <p></script>
    <p></body>
    <p></html>
    <p>This is my code that i was working on, in the jsp part of the script, i get a api call and save a value of time in the variable remainingtime.. and in the javascript, i try to have a countdown clock counting down the remaining time.. but i guess it doesnt work.. how can i get that working? thanks alot
    Message was edited by:
    hamham3001
    Message was edited by:
    hamham3001
    Message was edited by:
    hamham3001
    Message was edited by:
    hamham3001

    Re: How to pass a jsp variable into javascript??Here is the sameple one, hope it will solves your problem.
    <html>
    <body>
    <form name=f>
    <%!
    String str = "A String"
    %>
    <script>
    var avariable = <%=str%>
    <script>
    </form>
    </body>
    </html>
    Let me know if you face any problem

  • Drop-down Menu to Open URL for File Download

    I am using Adobe Captivate 5.5 and was wondering if it is possible to create a drop-down menu that can be used to open different URLs for file downloads, kind of like the Attachments button Presenter has. Captivate seems to have a dropdown widget available but I can't tell if this would work for this purpose.

    Hi Theo
    You can use any composition to create a menu with setting for show target on rollover and then link targets to specific pages.
    Adobe Muse CC 7.0 Tutorial | Beautiful Graphic Navigation - YouTube
    Thanks,
    Sanjit

  • What is the URL for Firefox start page, need to put it into drop down menu.

    unable to locate the url address for Mozilla Firefox Start Page to add to my drop down menu of homepage choices, I also called customer service 2x and hung up on me both times.
    I am attempting to make Firefox my home page as well as default browser, the browser was easy but finding the https www address is not. please advise. I was using Chrome as browser but am in the process of deleting all previous due to malware.

    hello, the default homepage in firefox is '''about:home'''.
    since you have one adrware addon present in firefox as well, i'd recommend to run a full scan of your system with different security tools like the [http://www.malwarebytes.org/products/malwarebytes_free free version of malwarebytes] & [http://www.bleepingcomputer.com/download/adwcleaner/ adwcleaner], which are specialised in adware and browser hijackers.

  • The javascript for a drop down menu

    I have a problem. I am new in pdf
    javascripting. What i want to do is to make a drop down menu with multiple items, clicking any of each items will take me to a bookmark or a web addess. I can make the drop menu (this is wuite easy, however without adding java script the drop down menu will be dead. Can someone help me with this script, i will be much obliged if some one has an actual pdf file with that drop down menu and the script. That will be much appreciated my email address is monaahmad at yahoo dot com
    Regrads
    Mona ahmad

    You could  try something like this in your "onchange" event of the drop down.
    var  sSelectedItem = xfa.event.newText; // get the item from the drop down
         switch (sSelectedItem) {
            case "Item 1":
                 window.location = "http://www.website1.com"
                break;
             case "Item 2":
                window.location =  "http://www.website2.com"
                break;

  • How to store session variables in drop down menu (and radiobutton/checkbox)

    How am I going to store session variables in the drop down menu, radio button, checkbox.
    In text area, I do like below:
    <input type="text" name="membershipno" size="5" maxlength="50" value="<%=((session.getValue("Smembershipno")!=null)?session.getValue("Smembershipno"):"") %>">
    Any idea?

    Hi jeffkyt79, I could have answered this on Expert's Exchange. But I suppose it would be hard as the site is down right now :-(
    Here is sample code for the form:
    <form action="" name="form1">
    <input type="text" name="field1" value="<%
    if (session.getAttribute("field1")!=null) {
    out.println(session.getAttribute("field1"));
    } %>"><br>
    <input type="text" name="field2" value="<%
    if (session.getAttribute("field2")!=null) {
    out.println(session.getAttribute("field2"));
    } %>"><br>
    <input type="text" name="field3" value="<%
    if (session.getAttribute("field3")!=null) {
    out.println(session.getAttribute("field3"));
    } %>"><br>
    <input type="checkbox" name="check1" value="tick"<% if (session.getAttribute("check1")!=null) out.println(" checked"); %>><br>
    <% String selRadio=(session.getAttribute("r1")!=null)?(String)session.getAttribute("r1"):""; %>
    <input type="radio" name="r1" value="yesdot"<% if (selRadio.equals("yesdot")) {out.println(" checked");} %>>
    <input type="radio" name="r1" value="nodot"<% if (selRadio.equals("nodot")) {out.println(" checked");} %>><br>
    <select name="sel">
    <% String selOption=(session.getAttribute("sel")!=null)?(String)session.getAttribute("sel"):""; %>
    <option value="option1"<% if (selOption.equals("option1")) {out.println(" selected");} %>>OPTION 1
    <option value="option2"<% if (selOption.equals("option2")) {out.println(" selected");} %>>OPTION 2
         <option value="option3"<% if (selOption.equals("option3")) {out.println(" selected");} %>>OPTION 3
    </select>
    </form>
    And here's the revised javascript function to put in form1.jsp:
    function newWin() {
    f=document.form1.elements;
    str="?";
    mypage="test2.jsp"; // I've hardcoded the url for testing but you can fix this
    for (i=0;i<f.length;i++) {
    if (f.type=="text") {
    if (f[i].value!="") {
    str=str+f[i].name+"="+f[i].value+"&";
              continue;
         if (f[i].type=="checkbox"||f[i].type=="radio") {
         if (f[i].checked) {
         str=str+f[i].name+"="+f[i].value+"&";
         if (f[i].type=="select-one") {
         str=str+f[i].name+"="+f[i].options[f[i].selectedIndex].value+"&";
    str=str.substr(0,str.length-1);
    // now open the popup
    mypage+=str;
    win=window.open(mypage, 'myname'); // I've left out the winprops but you can fix this
    If you can ask any more questions, could you do it on EE (if possible!!). I know this works because I've tested it.

  • How can i create a drop down menu for set qty in my store?

    I'm wondering how i can create a drop down menu for the qty module that sits on the individual product page. My client sells in quantities of 6 packs. I currently have the minimum order at 6 but i would like to give consumers the option for 6,12,18...and so forth. I was told that it could be accomplished? Hopefully someone can help me.

    Hi Chris -
    Thank you for your reply! I had seen your article before, and just now again attempted to follow it, but I get stuck. There are two things that I'm confused by.
    First off, toward the top, referring to the initial button, you say to add this interaction:
    ON CLICK; Play Transition to comboBox: selected
    ON ROLL OUT; Play Transition to comboBox normal if comboBox is in over state
    ON ROLL OVER; Play Transition to comboBox over if comboBox is in normal
    However, I do not see these transition options. When I select the button, the only interactions I have are to Play transistion to state, Play action sequence, Go to URL, and two for videos. So that's the first roadblock for me.
    But, trying to get passed that, I went down to the portion of the article that refers to adding interaction to the dataset items. Again, I don't get it, as I see no way to add interaction to a dataset item. When I open my design-time data menu, I do see the items, and am able to rename each item, add additional rows, and change the shape of the datalist layout. However, I see no way to add an interaction to a dataset item. I must be missing a step ... Can you help with this?
    Again, thank you!
    Amy

  • Making drop down menu for entry fields in database

    <%@ page language="java" contentType="text/html" %>
    <%@ page import="java.io.*" %>
    <%@ page import="java.math.*" %>
    <%@ page import="java.util.*" %>
    <%@ include file="/global/util.inc" %>
    <%@ include file="/global/user_session.jsp" %>
    <%@ include file="/global/connection_prepare_marketing.jsp" %>
    <html>
    <head>
    <title>Marketing Data Entry</title>
    <LINK REL=STYLESHEET HREF="/global/app_main.css">
    <BODY bgcolor=#FEFFE8>
    <%
    int     CID = 0;     
         CID = Integer.parseInt(request.getParameter("cid"));
    if (request.getParameter("delete") != null) {
         // Do the delete via a PreparedStatement
            java.sql.PreparedStatement ps = null;
         ps = db.prepareStatement("delete from hit_or_miss where hom_ID = ?");
         ps.setInt(1, CID);
         ps.executeUpdate();
         CID = 0;
         out.print ("<font color=darkblue>The record has been deleted successfully</font>");
    if (request.getParameter("update") != null) {
           // Set inputs in order to evaluate
            String          DE = request.getParameter("date_entered");
                   DE = DE.replaceAll("[a-zA-Z]","");             // Get rid of letters
         String          SI = request.getParameter("summit_ID");
                   SI = SI.replaceAll(",","");                 //Get rid of commas
         String          TT = request.getParameter("transaction_type");    //No change needed
           String            NL = request.getParameter("notional");
                     NL = NL.replaceAll("[a-zA-Z]","");               // Get rid of letters
                     NL = NL.replaceAll(",","");                  // Get rid of commas
           BigDecimal      NTL = new BigDecimal(NL);
         String          ST = request.getParameter("structure");
         String          CP = request.getParameter("counterparty");
         String          ED = request.getParameter("expiry_date");
                   ED = ED.replaceAll("[a-zA-Z]","");                // Get rid of letters
         String          SD = request.getParameter("start_date");
                   SD = SD.replaceAll("[a-zA-Z]","");                // Get rid of letters
         String          MD = request.getParameter("maturity_date");
                   MD = MD.replaceAll("[a-zA-Z]","");                // Get rid of letters
         String          CT = request.getParameter("currency_type");
         String          MRKTR = request.getParameter("marketer");
           String            SSC = request.getParameter("sales_credit");
                     SSC = SSC.replaceAll("[a-zA-Z]","");         // Get rid of letters
                     SSC = SSC.replaceAll(",","");                 // Get rid of commas
           BigDecimal      SC = new BigDecimal(SSC);
         String          MRKP = request.getParameter("markup");
                   MRKP = MRKP.replaceAll("[a-zA-Z]","");    // Get rid of letters
                   MRKP = MRKP.replaceAll(",","");           // Get rid of commas
         BigDecimal     MP = new BigDecimal(MRKP);
         String          CC = request.getParameter("comments_color");
      if (     SD != null && MD != null && ED != null ) {
         // First get the ID to use     
            String sql = " "+
              "begin "+
                "declare @new_id int "+
                 "if (select count(*) from hit_or_miss ) = 0 "+
                 "       begin "+
                 "       select @new_id = 1 "+
                 "       end   "+
                 "else "+
                 "       begin "+
                "       select @new_id = max(hom_ID) + 1 from hit_or_miss "+
                 "       end "+
              "select newID=@new_id "+
           "end";
         int nID = 0;
         rs = st.executeQuery(" "+ sql + " ");
         while (rs.next()) {
              nID = rs.getInt("newID");
         // Get timestamp for insert
         java.util.Date curr_dt = new java.util.Date();
            java.sql.Timestamp dt = new java.sql.Timestamp(curr_dt.getTime());
         // Now we check if it is an insert or update based on the passed ID
         if (CID == 0) {
              // Do the insert via a PreparedStatement
              java.sql.PreparedStatement ps = null;
              ps = db.prepareStatement("insert into hit_or_miss values(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
              ps.setInt(1, nID);
              ps.setString(2, DE);
              ps.setString(3, SI);
              ps.setString(4, TT);
              ps.setBigDecimal(5, NTL);
              ps.setString(6, ST);
              ps.setString(7, CP);
              ps.setString(8, ED);
              ps.setString(9, SD);
              ps.setString(10, MD);
              ps.setString(11, CT);
              ps.setString(12, MRKTR);
              ps.setBigDecimal(13, SC);
              ps.setBigDecimal(14, MP);
              ps.setString(15, CC);
              ps.executeUpdate();
              out.print("<font color=darkblue>The new record has been inserted into the database successfully</font>");
         } else {
              // Do the update via a PreparedStatement
              // First we insert a row into the archive table
                 java.sql.PreparedStatement ps = null;
                    ps = db.prepareStatement("update hit_or_miss set date_entered = getdate(), summit_ID = ?, transaction_type = ?, notional = ?, structure = ?, counterparty = ?, expiry_date = ?, start_date = ?, maturity_date = ?, currency_type = ?, marketer = ?, sales_credit = ?, markup = ?, comments_color = ? where hom_ID ="+CID+" ");
              ps.setString(1, DE);
              ps.setString(2, SI);
              ps.setString(3, TT);
              ps.setBigDecimal(4, NTL);
              ps.setString(5, ST);
              ps.setString(6, CP);
              ps.setString(7, ED);
              ps.setString(8, SD);
              ps.setString(9, MD);
              ps.setString(10, CT);
              ps.setString(11, MRKTR);
              ps.setBigDecimal(12, SC);
              ps.setBigDecimal(13, MP);
              ps.setString(14, CC);
              ps.executeUpdate();
              out.print("<font color=darkblue>This record has been updated successfully</font>");
      } else {
         out.print("<font color=red>You must fill in the date and amount sections of this form in order the write to the database to occur - please try again</font>");
         String DateEntered_text = null;
         String SummitID_text = null;
         String TransactionType_text = null;
         String Amount_text = "0000000.00";
         String Structure_text = null;
         String Counterparty_text = null;
         String ExpiryDate_text = null;
         String StartDate_text = null;
         String MaturityDate_text = null;
         String CurrencyType_text = null;
         String Marketer_text = null;
         BigDecimal SalesCredit_text = new BigDecimal(0.0);
         BigDecimal Markup_text = new BigDecimal(0.0);
         String CommentsColor_text = null;
         String Notional_text = null;
    if (CID == 0) {
         String Expiry_Date_text = "";
            String Start_Date_text = "";
            String Maturity_Date_text = "";
    } else {
         rs = st.executeQuery("select o.hom_ID, DateEntered=convert(varchar(10),o.date_entered,101), o.summit_ID, o.transaction_type, Notional=convert(varchar(100),convert(money,o.notional),1), o.structure, o.counterparty, ExpiryDate=convert(varchar(10),o.expiry_date,101), StartDate=convert(varchar(10),o.start_date,101), MaturityDate=convert(varchar(10),o.maturity_date,101), o.currency_type, o.marketer, o.sales_credit, o.markup, o.comments_color from hit_or_miss o where o.hom_ID =  "+CID+ " ");
         while (rs.next()) {
              DateEntered_text = rs.getString("DateEntered");
              SummitID_text = rs.getString("summit_ID");
              TransactionType_text = rs.getString("transaction_type");          
              Amount_text = rs.getString("Notional");
              Structure_text = rs.getString("structure");
              Counterparty_text = rs.getString("counterparty");
              ExpiryDate_text = rs.getString("ExpiryDate");
              StartDate_text = rs.getString("StartDate");
              MaturityDate_text = rs.getString("MaturityDate");
              CurrencyType_text = rs.getString("currency_type");
              Marketer_text = rs.getString("marketer");
              SalesCredit_text = rs.getBigDecimal("sales_credit",8);
              Markup_text = rs.getBigDecimal("markup",5);
              CommentsColor_text = rs.getString("comments_color");
    %>
    <table id="main" border=0 cellspacing="4" cellpadding=3 bgcolor="buttonface">
         <tr><td ><form name="myform" method="post" action="/applications/marketing/hit_or_miss.jsp">
    <table  border="0" cellspacing="4" cellpadding="3">
         <tr class=tableHeader>
              <td valign=top colspan=2 >Marketing Form</td>
         </tr>
         <tr>
              <td valign=top><font size="-1"><b>Date Entered:</b></font></td>
              <td>     
                   <input type=text name=date_entered size=8 value='<%=DateEntered_text%>'>
                   <a href="javascript: void(0);"
                   onmouseover="if (timeoutId) clearTimeout(timeoutId); window.status='Show Calendar'; return true;"
                   onmouseout="if (timeoutDelay) calendarTimeout(); window.status='';"
                   onclick="g_Calendar.show(event, 'myform.date_entered', false, 'mm/dd/yyyy'); return false;">
                   <img src='/images/calendar.gif' name='imgCalendar' width=20 height=10 border=0 alt=''></a>
              </td>
         </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Summit ID:</b> </font></td>
                    <td><input type=text name=summit_ID size=25 value='<%=SummitID_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Transaction Type:</b> </font></td>
                    <td><input type=text name=transaction_type size=25 value='<%=TransactionType_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Notional:</b> </font></td>
                    <td><input type=text name=notional size=25 value='<%=Notional_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Structure:</b> </font></td>
                    <td><input type=text name=structure size=25 value='<%=Structure_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Counterparty:</b> </font></td>
                    <td><input type=text name=counterparty size=25 value='<%=Counterparty_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Expiry Date:</b></font></td>
                    <td>   
                            <input type=text name=expiry_date size=8 value='<%=ExpiryDate_text%>'>
                            <a href="javascript: void(0);"
                            onmouseover="if (timeoutId) clearTimeout(timeoutId); window.status='Show Calendar'; return true;"
                            onmouseout="if (timeoutDelay) calendarTimeout(); window.status='';"
                            onclick="g_Calendar.show(event, 'myform.expiry_date', false, 'mm/dd/yyyy'); return false;">
                            <img src='/images/calendar.gif' name='imgCalendar' width=20 height=10 border=0 alt=''></a>
                    </td>  
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Start Date:</b></font></td>
                    <td>   
                            <input type=text name=start_date size=8 value='<%=StartDate_text%>'>
                            <a href="javascript: void(0);"
                            onmouseover="if (timeoutId) clearTimeout(timeoutId); window.status='Show Calendar'; return true;"
                            onmouseout="if (timeoutDelay) calendarTimeout(); window.status='';"
                            onclick="g_Calendar.show(event, 'myform.start_date', false, 'mm/dd/yyyy'); return false;">
                            <img src='/images/calendar.gif' name='imgCalendar' width=20 height=10 border=0 alt=''></a>
                    </td>  
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Maturity Date:</b></font></td>
                    <td>   
                            <input type=text name=maturity_date size=8 value='<%=MaturityDate_text%>'>
                            <a href="javascript: void(0);"
                            onmouseover="if (timeoutId) clearTimeout(timeoutId); window.status='Show Calendar'; return true;"
                            onmouseout="if (timeoutDelay) calendarTimeout(); window.status='';"
                            onclick="g_Calendar.show(event, 'myform.maturity_date', false, 'mm/dd/yyyy'); return false;">
                            <img src='/images/calendar.gif' name='imgCalendar' width=20 height=10 border=0 alt=''></a>
                    </td>  
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Currency Type:</b> </font></td>
                    <td><input type=text name=currency_type size=25 value='<%=CurrencyType_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Marketer:</b> </font></td>
                    <td><input type=text name=marketer size=25 value='<%=Marketer_text%>'></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Sales Credit:</b> </font></td>
                    <td><input type=text name=sales_credit size=8 value='<%=SalesCredit_text%>'><b>%</b></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Markup:</b> </font></td>
                    <td><input type=text name=markup size=8 value='<%=Markup_text%>'><b>%</b></td>
            </tr>
         <tr>
                    <td valign=top><font size="-1"><b>Comments/Color:</b> </font></td>
                    <td><input type=text name=comments_color size=8 value='<%=CommentsColor_text%>'><b>%</b></td>
            </tr>
         <tr>
              <td colspan=2><hr width=100%></td>
         </tr>
         <tr>
              <td colspan=2>     <input type="submit" name="update" value="Update Record"
                        style='width:100px;font:9px verdana;'>
         <% if (CID != 0) { %>
                            <input type="submit" name="delete" value="Delete Record"
                                    onclick="return confirm('Are you sure you want to delete this record?');"
                                    style='width:100px;font:9px verdana;'>
            <% } %>
                   <input type="button" name="close" value="Close Window"
                        style='width:100px;font:9px verdana;'
                   onclick='javascript:window.close();'>
              </td>
         </tr>
    </table>
    </td>
    </tr>
    </table>
    <input type=hidden name=login_id value=<%= request.getParameter("login_id") %>>
    <input type=hidden name=cid value=<%=CID%>>
    <SCRIPT LANGUAGE="JavaScript">
    opener.myform.submit();
    </SCRIPT>
    </form>
    </body>
    </html>thats my code for part of database, in the parts that go "if CID = 0", thats the new record field, in there right now i just have users put in info into blank input fields, however, i would like to know if i can make certain fields, like Mraketer, and Counterparty fields to have drop down menus, Anyone know??

    So basically the main focus of what I was askin is in this block of code below:
    if (CID == 0) {
              // Do the insert via a PreparedStatement
              java.sql.PreparedStatement ps = null;
              ps = db.prepareStatement("insert into hit_or_miss values(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)");
              ps.setInt(1, nID);
              ps.setString(2, DE);
              ps.setString(3, SI);
              ps.setString(4, TT);
              ps.setBigDecimal(5, NTL);
              ps.setString(6, ST);
              ps.setString(7, CP);
              ps.setString(8, ED);
              ps.setString(9, SD);
              ps.setString(10, MD);
              ps.setString(11, CT);
              ps.setString(12, MRKTR);
              ps.setBigDecimal(13, SC);
              ps.setBigDecimal(14, MP);
              ps.setString(15, CC);
              ps.executeUpdate();
              out.print("<font color=darkblue>The new record has been inserted into the database successfully</font>");
         } else {
              // Do the update via a PreparedStatement
              // First we insert a row into the archive table
                 java.sql.PreparedStatement ps = null;
                    ps = db.prepareStatement("update hit_or_miss set date_entered = getdate(), summit_ID = ?, transaction_type = ?, notional = ?, structure = ?, counterparty = ?, expiry_date = ?, start_date = ?, maturity_date = ?, currency_type = ?, marketer = ?, sales_credit = ?, markup = ?, comments_color = ? where hom_ID ="+CID+" ");
              ps.setString(1, DE);
              ps.setString(2, SI);
              ps.setString(3, TT);
              ps.setBigDecimal(4, NTL);
              ps.setString(5, ST);
              ps.setString(6, CP);
              ps.setString(7, ED);
              ps.setString(8, SD);
              ps.setString(9, MD);
              ps.setString(10, CT);
              ps.setString(11, MRKTR);
              ps.setBigDecimal(12, SC);
              ps.setBigDecimal(13, MP);
              ps.setString(14, CC);
              ps.executeUpdate();
              out.print("<font color=darkblue>This record has been updated successfully</font>");
         }     when CID = 0, what it does is it pops up a new window called "New Record" and in this new window, there are boxes where inputs can be made, so that when u hit submit, it submits into the database.
    What I want to do is, for example, there is a input field called "Marketer" where one can type in his own name as the Marketer, I want make this into a drop down box, where you can pick the marketer, and not have to type it in.
    You know how websies have New User, where you create a new user that is added to their database, and usually the COUNTRY field is a drop down menu where you pick the country from. I would like to do that to my database, and this is the area, or the code, that deal w/ new record "IF CID =0" and edit record "ELSE"
    Is this possible?
    Thanks in Advance

Maybe you are looking for

  • How do I change permissions on many files at once?

    Hello! I recently had a large hard drive crash, and, long story short, I got all my data back but now have a different user account on a new hard drive.  The permissions on all the files on the computer are fine. However, I am a recently graduated fi

  • User exit/Badi in MIGO after save

    hi all I am trying to find a user-exit/BAdi in tcode MIGO. This one should be called after saving the MIGO document. Using this i want to put control over auto TO creation for some specific plants and storage locations. Important thing is I am using

  • Problem in Servlet Clustering !

    Hi,           I have configured the WebLogic Server for Servlet Clustering. But how do I know that the servlet configuration is working?           I am using WebLogic 6.1 (sp2), I am using two different machines (NT WorkStations) as members of a clus

  • How I can watch in apple tv a movie buy in Itune

    how I can watch in apple tv a movie buy in Itune

  • Problem in calling dynamic actions in BDC

    Dear All, I have created a subroutine which is called when an entry is made in IT0015 for a particular wagetype. So I have used dynamic actions to serve the purpose. But the entries in IT0015 are made through a BDC, and I am facing in calling dynamic