Tag : Reading ASP.NET drop down values using JQuery

Home » Posts tagged Reading ASP.NET drop down values using JQuery"

Reading ASP.NET drop down values using JQuery <%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %> <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title> </title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js" ></script> <script type="text/javascript"> $(document).ready(function () { $('#txtLanguage').hide(); $('#ddlTeste').change(function () { var txtLanguage = $('#txtLanguage'); var testvalues = $("#ddlTeste option:selected").text(); if (testvalues) { txtLanguage.show(); txtLanguage.val(testvalues); } else txtLanguage.hide(); }); }); </script> ..

Read more