Solved

Changing this JQuery

Posted on 2012-03-10
3
170 Views
Last Modified: 2012-03-18
If you look at this link, there's a line of code:

error: function(XMLHttpRequest, textStatus, errorThrown) {
                    alert(textStatus);

Open in new window


Is there anyway NOT to display an alert..instead i want to display the msg in the page in the page...by binding it to lblmsg.Text. How can  I do this?

http://www.dotnetcurry.com/ShowArticle.aspx?ID=515
0
Comment
Question by:Camillia
3 Comments
 
LVL 15

Accepted Solution

by:
navneethegde earned 250 total points
ID: 37706691
Hi!

Add the HTML to the page

<form id="form1" runat="server">
<div class="demo">
<div id="lblmsg">
<div class="ui-widget">
    <label for="tbAuto">Enter Email: </label>
     <asp:TextBox ID="tbAuto" class="tb" runat="server">
     </asp:TextBox>
</div>
</div>
</form>

Open in new window


And

error: function(XMLHttpRequest, textStatus, errorThrown) {
                    $("#lblmsg").val(textStatus);
}

Open in new window


Is this want you are looking for?

Thanks!
0
 
LVL 75

Assisted Solution

by:Michel Plungjan
Michel Plungjan earned 250 total points
ID: 37707500
.val?

Either use .text() or .html() for a div - it will wipe the form since you did not close it either
0
 
LVL 7

Author Comment

by:Camillia
ID: 37707970
let me try
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question