I am trying to get the jquery getJSON function to work. The following seems very simple yet it doesn't work.
$("#edit-item-btn").live('click', function() {
var name = this.id;
$.getJSON("InfoRetrieve",
{ theName : name },
function(data) {
alert(name);
});
});
...
Hi there,
I'm trying to pass a value to an input box via json. I've been using:
$.getJSON(('somedata.json', function(json){
$('#myinput').val(json.values);
});
Works fine. But I needed it to look as if someone focused the input box, typed the json.values inside and then blurred it, because my input box does all sorts of stuff ...
i have the following code where i getJSON after i click on a select box. Sometimes it takes a long time and the users are clicking on the dropdown again during the server side processing.
Is there anyway to disable the dropdown during the server side call and reenabled it after the processing is complete.
here is my code
<script typ...
i have a number of dropdown controls and on the change event it kicks off ajax getJSON() calls. I have a div next to each dropdown with a spinner image as i want to display "loading . . " as some of the ajax calls are expensive.
Is there anyway i can just have one spinner div on the page and have the spinner move right next to the drop...
i'm trying to make a script using Yahoo's YQL in a web applicaion. The script looks over a text paragraph and then it finds some references and appends on the text as a popup. It all goes fine until I have to loop through each reference with class "verso", after getting my response it appends all the references in the last element of the...
I'm a little confused as to what exactly is going on here. For instance...
http://bidstick.com/latest/21249%7C21250%7C21252.js&localtime=1263468042061/
Is pulling down some JSON information, and the numbers being passed are specifying which auctions need information, but what is processing these variables. Is there some server side...
IN json object if we can found if data exist by jsonobj.has("element_name") by how can we check that data is jsonarray or json object, follow error gives error if only one events element found and throws JSONexception.
JsonObject jObj;
if (json.has("Events")) {
try {
JSONArray eventsArray = json.getJSONObject("Events");
...
This is driving me nuts! What the easiest way to wrap an anchor with the img src as the href in this code?:
$(function(){
$.getJSON("http://api.flickr.com/services/feeds/photos_public.gne?tags=tree&tagmode=any&format=json&jsoncallback=?",
function(data){
$.each(data.items, function(i, item){
$("<img...
I have to do something very simple, but there doesn't seem to be an easy way to do this, as far as I can tell. I just want to load JSON data from a remote source and store it in a global Javascript variable using jQuery. Here's what I have:
var my_json;
$.getJSON(my_url, function(json) {
var my_json = json;
});
The my_json variable ...
function addSearchPattern(file, aStatus, aRule, aExpression, aCategory)
{
$.getJSON(file, {
status: aStatus,
rule: aRule,
expression: aExpression,
categoryID: aCategory
}, function(data){
if(data.errors.length > 0)
{
var errorText = '';
$.each(data.errors, fu...
Hi,
I am using a JSON object to create graphs with Google visualization. I am trying to design the data source. For this i am creating a JSON object on my browser.
var JSONObject = {
cols: [{id: 'date', label: 'Date', type: 'date'},
{id: 'soldpencils', label: 'Sold Pencils', type: 'number'},
{id: 'soldpens', label: 'Sold ...
I checked this in firebug lite, and it's loading everything into the DOM properly, but immediately hangs on the second image. When I try visiting the images individually they don't load either. Any ideas?
I should also point out that this script works fine in: IE7, IE8, Firefox 2,3, and Safari.
$(document).ready(function() {
var reg...
I'm having an issue with a callback. I'm not even getting an error in Firebug. If I alert before and after the getjson call both alerts show but the getjson call doesn't fire.
public ActionResult TestPage()
{
return View();
}
public ActionResult LoadMapLonLats(int mapId)
{
//some code
return Json...
Plugin: jQuery lazy()
I ask here because the project page itself seems to be dead.
What steps will reproduce the problem?
1. embed two jQuery-Plugins that are both using the $.getJSON function
results in a "too much recursion error" in firefox. If the same scripts are
referenced with lazy it works fine. Problem only persits in firefox...
Hi -
I need to access data on a subdomain I've been trying to use JSONP which jQuery has support for. The data that I'm accessing on the subdomain is a static (regenerated) .json file (http://www.example.com/data.json)
I was running into "Invalid Label Error" errors and realized the data needed to be wrapped in parenthesis and use ?ca...
I have no problems getting the Json to work and parse the json return. I was just wondering how I could build a dynamic "whatever data is" and stick it into [data] to pass my parameters from there and not manually append them to the url.
From jquery website example:
$.getJSON("test.js", { name: "John", time: "2pm" }, function(json){
...
I'm trying to grab some JSON from Apple's iTunes JSON service. The request is simple:
http://ax.phobos.apple.com.edgesuite.net/WebObjects/MZStoreServices.woa/wa/wsSearch?term=jac&limit=25
If you visit the URL in your browser you will see some well-formed (backed up by jsonlint.com) JSON. When I use the following jQuery to make the...
Hi everyone,
I'm using jquery $.getJSON to retrieve list of cities.
Everything works fine, but I'm from Estonia (probably most of you don't know much about this country =D) and we are using some characters like õ, ü. ä, ö.
When I pass letters like this to callback function, I keep getting empty strings. I've tried to base64 encode(serv...
Hi there,
im trying since a long term to use events on elements in my dom which has been added asynchronus.
I´ve read something about bind but is there a different Way to etablish something like this?
For Example I have this situation.
$.getJQUERY(myUrl, {var:value}, function(i, data){
$.each(data.values, function(value){
$("b...
This is my first question on stackoverflow. I just wonder why my getJSON code doesn't work with jQuery 1.4.2, it worked smoothly with jQuery 1.3.2 though
So here is my code
$(document).ready(function(){
$('td.hps_ajax a').click(function() {
id = this.id.replace(/.*hps_ajax/,'');
if(confirm('Anda yakin mau menghapus ...