How to enable javascript in asp.net webforms
<p>i am trying to use javascript events in asp.net webforms. but events for input controls like textfield, such as onClick, onFocus,onBlur, dont appear. do i need to change my directive:</p>

<pre><code>&lt;%@ Page Title="" Language="C#" MasterPageFile="~/YourGuruMaster.master" AutoEventWireup="true" CodeFile="AskQuestion.aspx.cs" Inherits="AskQuestion" %&gt;
</code></pre>

<p>i want to be able to do this:</p>

<pre><code>//code page
    protected void Page_Load(object sender, EventArgs e)
{
    QuestionTextBox1.Attributes["onfocus"] = "ClearSearchText()";

//Markup page
     function ClearSearchText() {
        var searchUserName = document.getElementById('&lt;%=QuestionTextBox1.ClientID%&gt;');

        if (searchUserName.value = searchUserName.defaultValue) {
            searchUserName.value = "";
        }


        return false;
    }

&lt;p dir="rtl" style=""&gt;
&lt;asp:TextBox ID="QuestionTextBox1" runat="server" Width="702px" 

Text="פרטים עד 5000 תווים"&gt;&lt;/asp:TextBox&gt;
</code></pre>

<p></p></p>
