ajax

Microsoft JScript runtime error: 'Sys' is undefined

Hi, I am having problems with an intermitent error in an ASP.Net Ajax enabled website. The error I am receiving is the old faithful "Microsoft JScript runtime error: 'Sys' is undefined" error. Googling this error usually turns up the suggestion to add the correct "httpHandlers" and "httpModules" into the "web.Config" file. The web.confi...

Problem preventing form submission with jquery

I wish to execute a jquery based ajax form submission on pressing the enter key. Obviously this involves stopping the normal form submission process. My form consists of a single input field. Here is the code: <script type="text/javascript"> $(document).ready(function() { // add vid ajax $.ajaxSetup({ cache:false; ...

How to build a ASPX proxy page for JSONP calls

I have a page on the local intranet that provides information in JSONP format and want external users to be able to use that page for AJAX calls. For this I want to write an ASPX proxy page that passes the client request to the internal page (on another server) and then sends the unaltered response to the external client. What would be...

Descriptive error messages

I have the following jQuery which does not give the most descriptive error messsages... url: 'server_page.aspx', type: 'POST', data: { intID:$(this).attr("id"), strState:"1" }, error: function() { alert('Error'); }, success: function() { } How do I get more descriptive error messages if it is possible? EDIT: This is the full javasc...

.NET Dynamic XML reads fine in all browsers except IE

Using AJAX to pull data from a dynamically generated XML using .NET. Using simple jQuery Ajax: $.ajax({ type: "GET", url: "/test/dynamic.aspx", success: function(xml) { var itemTitleSrc = $(xml).find('ItemName').text(); alert(itemTitleSrc); } }); In Firefox, Chrome, Safari, the alert brings back all of the strings associate...

JQuery: Merge multiple JSON results

Situation: User want to import Youtube playlist in a JQuery site using Youtube's JSON API. Problem: Youtube only gives back first 50 entries, but playlists can be 100+ entries long (length is given by 'totalItems' in JSON response). All the entries need to be merged as 1 object and need to be pushed into an output function at the end. ...

ASP.NET MVC problem using image submit tag in Ajax.BeginForm

I'm developing a web app with ASP.NET MVC 2 (.NET 4.0), and I've run into a difficult problem. I've got the following code in a partial view: <% using (Ajax.BeginForm("CompleteTask", "Agenda", new AjaxOptions {HttpMethod = "POST"})) { %> <%: Html.EditorFor(x => x.Remarks) %> <%: Html.HiddenFor(x => x.TaskId) %> <%: Html.Hid...

Implementing a random chat among people

My idea is to make a website, where people could registry and search for a people to talk. They can choose people from certain country, genre, with certain age and so on. Yeah, I know there is a lot of websites like this, but I want to implement this, because it looks really challenging. Can you give me ideas how could I implement thi...

having trouble passing formbuilder using remote_function with nested_attributes_for

Hey all I am having trouble updating a partial that contains a nested_attributes_for form with AJAX. My application needs to load a new section of the form based on the event type chosen in the main form. The fields associated with each type are stored in a database table. At the moment, when I select an event type, the id of the even...

best php based chat application

sir, as i am new to php. I want to embed chat application in my website. Does anyone let me know which chat application will be best suitable for my website which will run on my intranet. The chat application must be free of cost and php based. Thank you in advance. ...

Ajax Updater in Gmaps v3 divcontrol not firing

Hi, I have moved from v2 my working solution in Gmaps v3. After add a map control using dom and divs elements i'm not able to Update my content calling one Ajax.Update method and passing the id. All elements are in Dom. regards. May be linked to :link text var idname ='s7'; //--> div id='s7' ajax = new Ajax.Updater( idn...

jQuery (cross domain) .getJSON, store response in re-usable variable

I want to get the IP from the current user and send it along with an AJAX POST to a PHP file. Which means I need to re-use the variable I get in the response from the IP .getJSON request. Script 1: I found this handy snippet on snipt: $.getJSON("http://jsonip.appspot.com?callback=?",function(data){ alert( "Your ip: " + data.ip); })...

radio button values not being submitted

I must be losing my mind... I have a form with some radio buttons, but no matter what, the POST is only including the NAME of the radios, not the value of whichever is selected: <input type="radio" name="storage" value="1" id="ds_d"> <input type="radio" name="storage" value="2" id="ds_p"> <input checked type="radio" name="s...

Is it good and safe to use Json object to submit form data? I am using MVC 2 with JQuery Post

In my ASP.Net MVC 2 application I am using a Json object to submit form data. I would like to take expert advice whether it is a safe and good practice to do it or not and why? Please note, this question is not about how to do it but rather about best practice. Appreciate your valuable suggestions. ...

Automatic web-page refresh memory leak using XMLHttpRequest

Greetings, I've been working on a web-interface for some hardware that uses an 8-bit microcontroller. The web page uses HTML, javascript, JSON and XHR (XMLHttpRequest) for its communications. What I'm trying to do is create a page that updates every 250mS with new values from the controller using setInterval so that the web page gets u...

changing the image on jquery success function?

i have this jquery voting script, everything is working fine, it just that the image at the success function of the ajax request is not changing the image? jquery: $("a.vote_down").click(function(){ //get the id the_id = $(this).attr('id'); //the main ajax request $.ajax({ type: "POST", ...

any scripting language can read AJAX/Java Script? (linux)

is there any way I can scrape web pages that uses AJAX? by using something like ruby + mechanize on linux server that doesn't have monitor attached (linode.com for example) http://watir.com/ would be a solution but I guess not applicable to linode. ...

How to increase ajax asynchronous postback speed - asp.net

Hello dear programmers. I am developing a web based mmorpg. so speed is very vital for me since people don't like slow games :) i have a map system which uses ajax and asynchronous postbacks for walking. so i want to make it faster as much as possible. if anybody can spend some time at my page and make suggestion for me i appreciate t...

How to make a jsonp POST request that specifies contentType with jQuery?

I need to make a jsonp POST request with the content type 'application/json'. I can get the POST request to the server like this: jQuery.ajax({ type: 'POST', url: url, data: data, success: success, error: error, async: true, complete: complete, timeout: TIMEOUT, ...

Getting Browser Autocomplete of Ajax Submitted Form Fields Working in IE

I have a page that is heavily managed by ajax, and used all day by my clients employees for data entry. Before a merger the client was using Firefox, but has had to change to IE8 now. Firefox would save the form inputs when the forms on this page where submitted via ajax, IE8 doesn't do this natively. Having the forms now not auto-com...