Subject: How do I add keyword to the javascripted url?
Posted By: gilgalbiblewheel Post Date: 1/5/2006 8:49:29 PM
How do I add keyword to the javascripted url?
It's for the onchange and the iFrame. Once the dropdown is selected then the iFrame would show the verse.
I have an old code that looked like this:
location = "kjvresplistboxshowversea.id.options[document.myForm.id.selectedIndex].value + "&Keyword=" + document.myForm.Keyword.value + "&Keywordb=" + document.myForm.Keywordb.value + "&Keywordc=" + document.myForm.Keywordc.value + "&Keywordd=" + document.myForm.Keywordd.value + "&Keyworde=" + document.myForm.Keyworde.value + "&Keywordf=" + document.myForm.Keywordf.value + "#bcv

    <script language="JavaScript" type="text/javascript">
    <!--
        function go1()
        {
        booksa.action = "showversea.asp?id=";
        booksa.submit();
        }
    //-->
    </script>
    
        <form name="booksa" action="showversea.asp" method="get" target="ifrVerse">
        <select name="id" size="10" style="width:200;" onchange="go1();">
            
                <option  value="5276">Deuteronomy&nbsp;13:3</option>
                
                <option  value="8319">2 Samuel&nbsp;13:1</option>

                
                <option  value="8322">2 Samuel&nbsp;13:4</option>
                
                <option  value="8333">2 Samuel&nbsp;13:15</option>
                
                <option  value="12698">Nehemiah&nbsp;13:26</option>
                
                <option  value="16341">Psalms&nbsp;145:20</option>
                
                <option  value="16772">Proverbs&nbsp;13:24</option>

                
                <option  value="18774">Isaiah&nbsp;57:8</option>
                
                <option  value="26632">John&nbsp;13:1</option>
                
                <option  value="26654">John&nbsp;13:23</option>
                
                <option  value="26665">John&nbsp;13:34</option>
                
                <option  value="26666">John&nbsp;13:35</option>

                
                <option  value="28275">Romans&nbsp;13:8</option>
                
                <option  value="28276">Romans&nbsp;13:9</option>
                
                <option  value="28277">Romans&nbsp;13:10</option>
                
                <option  value="29055">2 Corinthians&nbsp;13:11</option>
                
                <option  value="29058">2 Corinthians&nbsp;13:14</option>

                
                <option  value="30243">Hebrews&nbsp;13:1</option>
                
        </select>


Martial Law 9/11 Rise of the Police State is now available! Visit our Martial Law movie section for complete info (click here), or order now by clicking the button below or by calling 888-253-3139
http://www.infowars.com/martial_law_911.htm
Reply By: joefawcett Reply Date: 1/6/2006 4:14:09 AM
I don't quite understand your first line of code but if you add:
onchange="go1(this.options[this.selectedIndex].value);"
to your select and then have something like:

function go1(id)
{
  booksa.action = "showversea.asp?id=" + id;
  booksa.submit();

}

Are you sure you want to submit rather than just redirect?

function go1(id)
{
  window.location.href = "showversea.asp?id=" + id;
}



--

Joe (Microsoft MVP - XML)
Reply By: gilgalbiblewheel Reply Date: 1/6/2006 11:13:19 AM
I want to add keyword as in:
&keyword=
in the url with the keyword searched.

Martial Law 9/11 Rise of the Police State is now available! Visit our Martial Law movie section for complete info (click here), or order now by clicking the button below or by calling 888-253-3139
http://www.infowars.com/martial_law_911.htm

Go to topic 38397

Return to index page 401
Return to index page 400
Return to index page 399
Return to index page 398
Return to index page 397
Return to index page 396
Return to index page 395
Return to index page 394
Return to index page 393
Return to index page 392