Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


display selected value in dropdown list through javascript
without page refresh



display selected value in dropdown list through javascript without page refresh..

Answer / rrajeswari

Try this code


<SCRIPT LANGUAGE="javascript">
<!--
function OnChange(dropdown)
{
var myindex = dropdown.selectedIndex
var SelValue = dropdown.options[myindex].value
var baseURL = <Some value based on SelValue>
top.location.href = baseURL;
return true;
}
//-->

</SCRIPT>
<select name=select1 onchange='OnChange(this.form.select1);'>
<option>Value 1</option>
<option>Value 2</option>
<option>Value 3</option>
</select>

Is This Answer Correct ?    11 Yes 6 No

Post New Answer

More PHP Interview Questions

Is the cookies are available on cross domain?

2 Answers  


What's the output of the ucwords function in this example?

0 Answers  


What's the difference between __sleep and __wakeup?

0 Answers  


What function should you use to join array elements with a glue string?

0 Answers  


Which is the latest version of php?

0 Answers  


what is the url rewriting?how to rewrite the url? give any example

1 Answers  


What is fetch array in php?

0 Answers  


what are the various PHP Script Optimization techniques?

1 Answers   IBM, Krify Software Technologies, TCL,


How can we get the browser properties using PHP?

7 Answers  


How can you retrieve data from the mysql database using php?

0 Answers  


Are objects passed by value or by reference?

0 Answers  


Explain how can we execute a php script using command line?

0 Answers  


Categories