Expand|Select|Wrap|Line Numbers
- 14 "var vSearch = document.getElementById("txtSearch").value;"
But whenever i put anything into a contentplaceholder it bugs out like crazy. Does anyone know why this happens or if there is a solution that isn't not using master pages as that's not a option i have.
[HTML]
<%@ Page Language="C#" MasterPageFile="~/MasterPages/CallCenterMaster.master" AutoEventWireup="true" CodeFile="NewSearch.aspx.cs" Inherits="Call_Center_NewSearch" Title="Ticket Search" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server" >
<script language="javascript" type="text/javascript">
function validate()
{
submitOk = "true";
var vNoData = "No data entered.";
var vSearch = document.getElementById("txtSearch").value;
if (vSearch == "")
{
document.getElementById("txtError").value = vNoData;
submitOk = "false";
}
if (submitOk == "false")
{
return false;
}
}
</script>
<table class="Backround" id="tMainSearch" style="width: 461px">
<tr>
<td style="width: 106px; height: 196px">
<table style="position: relative; left: 0px; top: 0px; width: 417px;" id="tSearch" class="Table">
<tr>
<td style="width: 162px">
</td>
<td style="width: 87px">
</td>
<td style="width: 100px">
<asp:TextBox ID="txtSearchOption" runat="server" Style="position: relative"></asp:TextBox></td>
</tr>
<tr>
<td style="width: 162px">
<asp:Label ID="lblSearch" runat="server" Style="position: relative" Text="Search"></asp:Label></td>
<td style="width: 87px">
<asp:TextBox ID="txtSearch" runat="server" Style="position: relative"></asp:TextBox></td>
<td style="width: 100px">
</td>
</tr>
<tr>
<td style="width: 162px">
</td>
<td style="width: 87px">
<asp:Button ID="btnSearch" OnClientClick = "return validate()" runat="server" Style="position: relative" Text="Search" /></td>
<td style="width: 100px">
<asp:TextBox ID="txtError" runat="server" Style="position: relative"></asp:TextBox></td>
</tr>
</table>
</td>
</tr>
</table>
</asp:Content>
[/HTML]