ajax

Postcode Search to Nearest Marker Google Maps API

Hi Guys - I am developing a map for a client which uses AJAX and PHP/MySQL to plot markers on a Google Map. I need to be able to add an input field of some sort above the map - the user searches there postcode and the map automatically zooms in to the nearest points depending on the postcode. I have searched and crawled the web for many...

PHP json_decode not supported, any alternatives?

Hi guys, as the title specifies, my hosting provider does not have support for json_decode, so I need to find a way to adapt my code to achieve the same effect, but without using JSON, here is my code, jQuery: var allLocations = []; $(".locations").each( function(i, location) { // for each location block loca...

jQuery's AJAX call to a javascript class method

Hi there, I'm a newbee about jQuery's workflow and I would like to setup a javascript class that uses an internal method to make an AJAX request. When the request returns with success, the jQuery AJAX callback should invoke a method owned by the class itself. That's the code: function IXClock() { this.m_intervalID = 0; this.sta...

jquery's ajax function does not working in android

Hi folks, I want to access open api through ajax in mobile application, its work fine in iphone but does not working in android phone-gap app, returning error->"error message-null,typeerror-Result of expression 'data'[null] is not an object and error status-parsererror" ,is there any browser setting,thanks in adavance. $.ajax({ ...

Ajax update panels and styles

I have a button styled with js and css and its inside an update panel everytime i click the button (do postback) it loses style ? pretty sure its an easy issue here , any idea ? <html xmlns="http://www.w3.org/1999/xhtml"&gt; <asp:ScriptManager ID="ScriptManager1" runat="server"> </asp:ScriptManag...

Avoiding CSRF when serving AJAX or Flash requests

I have a Flash based game for the browser which sends users' scores to a php backend script which stores the score and the user id in the database. Now I have a url like www.example.com/update.php?score=200&uid=234 The problem is that this is very much exposed to an intelligent user, and he can use this url to store whatever score he w...

phonegap: cookie based authentication (PHP) not working [webview]

I'm working on a mobile web-app using sencha touch, HTML5 and phonegap as a wrapper. I'm using PHP-Authentication (Cookie) and ajax-requests. Everything works fine on safari or chrome, but after the deployment with phonegap (webview) it does't work anymore... Any help would be appreciated :) Some more details: All data for my app is...

How to achieve this javascript effect?

On this website: when the user clicks "register now" along the top bar the screen goes dim and a box appears offering the registration form with recaptcha. I have a registration form with recaptcha working on my site and would like to copy the effect seen above. Can anyone link me to a specific tutorial offering instructions or alternat...

Ajax issue: delay in getting data from web service using innerHTML, please guide

I am working on an ajax application which will display about a million records in an html table. Web service returns records from server, I build a logn string by concatinating data and tags and than put this string using innerHTML (not using DOM for getting better performance). For testing I have put 6000 recods in database (stored pro...

Wait until all jquery ajax request are done?

How do I make a function wait until all jquery ajax requests are done inside another function? In short, I need to wait for all ajax requests to be done before i execute the next. But how? ...

PHP JSON parsing giving an error

Hi guys, I am trying to parse a JSON string using PHP, the JSON gets sent to the PHP file using jQuery $.ajax in this format, [{"value":"59"},{"value":"7"},{"value":"46"}] , but for some odd reason I keep getting this error "Invalid argument supplied for foreach()", here is my PHP and jQuery code, jQuery: $(".systems").each( funct...

AJAX vs JQuery Tooltip - UpdatePanel

I'm trying to implement flowplayer.org's JQuery tooltip http://flowplayer.org/tools/demos/tooltip/form.html into my webapplication (C#.NET). I have the following script at Master.Page: function createTooltip() { // select all desired input fields and attach tooltips to them $("#aspnetForm :input")...

jquery ajax and php validation

hi! I got this kind of form validation: php side: if ( trim($message)=="" ) { echo "lalalaal<br>lalalalala"; } then in the onsuccess ajax jquery: var error=$('div#error_contact').html() switch(error){ case "lalalaal<br>lalalalala": $("#form_contact").slideUp() } if i put a <br> the string equality is not verifie...

Injecting javascript and HTML using AJAX

Heya all, First of all I would like to say that while this is the first time i post here these boards have helped me much. With that said, I have got a strange issue regarding AJAX and scripts. You see, in my web application i used custome JS context menus. Now each of them menus is implemented with specific features depending on the ob...

Staying RESTful while performing AJAX server-side validations?

My Rails application has a number of forms. When Joe uses my app, I want each form to provide him with immediate visual feedback as to the validity of his input for each field. One field checks the format of his email address - pretty simple. But another allows him to associate the current resource with a number of other resources, and c...

Creating a array of multiple form input's ids and values using jquery

Hi guys, I have a bunch of fields that have the same class, now what I am trying to do is get the id and value of each one, create an array, and then using $.ajax send it to a PHP script, which will run through each one and enter it into the database. I tried using JSON, but my server does not have support for json_decode, which is ess...

JSF 2.0 AJAX: Call a bean method from javascript with jsf.ajax.request (or some other way)

Some background: I am building a custom JSF component. The component is basically a text editor and it should have a "Save" -button for saving the content string of the editor. As I am using the CodeMirror library, I need to fetch the content (string) from the editor with javascript and send that to the server. Therefore, in this case I ...

Dispatching in an HTML/Javascript Application

I am in the process of creating an HTML application, in the sense that there will only be one HTML page and the rest will be done as AJAX using jQuery. I will be storing context in the hash of the URL to preserve the back button and allow external deep-linking from our main site. I will use onhashchange to detect a request for new co...

How do I assign javascript variable to php variable? With out submitting the form

hi friends can some one tell me How do I assign javascript variable to php variable? I am actually getting a value through javascript and I want the javascript values to be assigned to php variables. With out submitting the form. ...

missing ) after argument list error when using Ajax.ActionLink mvc2

I've got this actionlink that is generating this error in firefox <%: Ajax.ActionLink(" ", "SelectEditProduct", new { id = item.Id }, new AjaxOptions { UpdateTargetId = "dialog", InsertionMode = InsertionMode.Replace, OnSuccess = "$(\"#dialog\").dialog(\"open\");"}, new { Class="edit"})%> It seems to be coming from the little javascri...