<script type="text/javascript" src="http://www.google.com/jsapi"></script>
<script type="text/javascript">
google.load("elements", "1", { packages: "transliteration" });
</script>
<script>
function OnLoad() {
var varComment = $("input: radio[name='rblLanguage']:checked").val(); //not able to find value
if (varComment == "Hindi") {
{
var optionshindi = {
sourceLanguage:
google.elements.transliteration.LanguageCode.ENGLISH,
destinationLanguage:
[google.elements.transliteration.LanguageCode.HINDI],
shortcutKey: 'ctrl+g',
transliterationEnabled: true
};
var control = new google.elements.transliteration.TransliterationControl(optionshindi);
}
}
} //end onLoad function
google.setOnLoadCallback(OnLoad);
</script>
@using (Html.BeginForm())
{
@Html.AntiForgeryToken()
<div class="content-wrapper">
<section class="content-header">
<h1>
Edit News
<small>@*Preview*@</small>
</h1>
<ol class="breadcrumb">
<li><a href="#"><i class="fa fa-dashboard"></i> Admin</a></li>
<li class="active">Edit News</li>
</ol>
</section>
<section class="content">
<div class="box box-default">
<div class="box-body">
<div class="col-sm-12">
<table id="rblLanguage1">
<tr>
<td>
<input id="rblLanguage_0" type="radio" name="rblLanguage" value="English" /><label for="rblLanguage_0">English</label>
</td>
</tr>
<tr>
<td>
<input id="rblLanguage_1" type="radio" name="rblLanguage" value="Hindi" /><label for="rblLanguage_1">Hindi</label>
</td>
</tr>
</table>
<span><small>(for type in hindi, please type in this textbox,if want to write in english, please copy english text and paste to News Textbox )</small></span>
@Html.TextBox("txtEnglish", "", new { @class = "form-control" })
</div>
<hr />
<div class="row">
<div class="form-horizontal">
<h4></h4>
<hr />
@Html.ValidationSummary(true, "", new { @class = "text-danger" })
@Html.HiddenFor(model => model.ID)
<div class="col-sm-7">
<div class="form-group">
<div class="col-sm-3">News:</div>
@*@Html.LabelFor(model => model.Description, htmlAttributes: new { @class = "control-label col-md-3" })*@
<div id="descr" class="col-md-9">
@Html.TextAreaFor(m => m.Description, new { @class = "form-control required", @rows = "6" })
@Html.ValidationMessageFor(model => model.Description, "", new { @class = "text-danger" })
</div>
</div>
i am not able to find radio button value. Pls help