Hey folks, I have a question which feels stupid but I can't quite say why.
Background:
Imagine a webapp with users and tags. Users tag each other.
I've got one page in the app which displays details about a single tag in relation to a single user. Let's say user 'bob' and tag 'footag'. On this page, I'm displaying two lists: all the p...
Hello,
I've been working on this for 3 hours and have given up.
i am simply trying to send data to an asp.net web method, using jQuery.
The data is basically a bunch of key/value pairs. so i've tried to create an array and adding the pairs to that array.
My WebMethod(aspx.cs) looks like this (this may be wrong for what i'm building in ...
I want a variable of the json file to be displayed (Date) but it does not seen to work. What am I doing wrong?
<script type="text/javascript">
$(document).ready(function()
{
$.getJSON("http://json-head.appspot.com/?url=http://www.trinum.com/ibox/chatel/images/photofull.jpg&callback=?", function(data)
{
...
I'm using asp.net page that is fully ajaxified (with jquery lib) and calling another asp.net callback page to get/post data to server.
Some users of my page experiencing following error when serializing json object
there was an error deserializing the
object of the type ... object type ... contains invalid
utf8 bytes
$.ajax({
...
I've got a fairly ajax heavy site and some 3k html formatted pages are inserted into the DOM from ajax requests.
What I have been doing is taking the html responses and just inserting the whole thing using jQuery.
My other option is to output in xml (or possibly json) and then parse the document and insert it into the page.
I've not...
I am starting to delve into the world of webOS and the Mojo SDK and having a great time so far, but I find myself having to constantly take a detour and read up on different subjects such as JSON, JavaScript, etc. I realize now that instead of diving in head first I probably should have done some reading on the core technologies behind ...
Can i give unlimited length for maxJsonLength?
I am using the autocomplete feature of jquery. When i try to retrieve the list of more then 17000 records(each wont have more than 10 char length), its exceeding the length and throws the error:
Exception information:
Exception type: InvalidOperationException
Exception m...
I'm trying to create a REST web service that exposes the following Django model:
class Person(models.Model):
uid = models.AutoField(primary_key=True)
name = models.CharField(max_length=40)
latitude = models.CharField(max_length=20)
longitude = models.CharField(max_length=20)
speed = models.CharField(max_length=10)
...
I want to use the HttpPostedFile Class to upload one or more large files to an ASP.NET MVC controller from a web page. Using this class, uploaded files larger than 256 KB are buffered to disk, rather than held in server memory.
My understanding is that it can be done like this:
if (context.Request.Files.Count > 0)
{
string tempFi...
How can I de-serialize a json object sent from javascript (using jquery.ajax) to a .aspx page (not a web service)?
e.g. if I have the following json object;
var json = {"name" : "michael", "surname" : "brown", "age" : "35"}
and I use
$.post('process.aspx', json)
how do I get to deserialize the json in process.aspx code behind?
al...
Are there any security issues in using JSON for just data transfer, other than that it is plain text? Like, the eval() which poses a security issue when used in JavaScript. Are there any such issues, when JSON is just used to transfer data between computers and read by programs written in Java etc
...
i have a page performing the following ajax request when a button is pressed.
normally i get a json object back and it works fine, i have noticed on intermittent requests (usually only the first request from that page), i get back a 200 success code with a blank page.
if i reload the html page, then press the button again it works fi...
I'm trying to display text in a UITableView that's a response from a JSON containing something like "Congratulations you just won a prize!", and when I display it in a UITableView the first 9 characters are "corrupted" and display weird symbols.
When I do an NSLog("%@", jsonString); I see the text correctly.
Is there some type of UTF8...
Hi,
I'm a noob at json (know a bit of jquery)....and trying to get a tiny script to work
I want to retrieve the time at a certain lat/lng
and made up this script in bits from what I've read online:
$.getJSON("http://ws.geonames.org/timezoneJSON?lat=47.01&lng=10.2&callback=?",
{ 'uID': 1 },
function(data) {
$....
Could you please tell me, what is the use of JSON (in Javascript and PHP).
when we need a JSON method.
I read from the following link but, i didn't get any information regarding the JSON implementation on any project.
http://www.json.org/js.html
...
Well I'm having some really weird trouble, this is what happens:
This is the environment:
I have a modal panel that has to be able to hold several "steps", first you have to upload a file, then the file is processed and from this processing result, I have to generate some html to fill the next step.
This is what I do:
I'm uploading a ...
Here is my code that sends a form via AJAX and then is meant to display a message back to the user
var postValues = {
name: $($nameObject).val(),
email: $($emailObject).val(),
message: $($messageObject).val(),
form: $(this).find('input[name=form]').val()
};
...
I've been happily returning JsonResult objects or partial ASP.NET views from my controllers in ASP.NET.
I would like to return a rendered partial view as a property in a JSON object. e.g.
requesting
/post/detail/1
would return
{"PostId": 1, "Html": "<p>some markup rendered from a partial to inject</p>" }
This would allow me to...
My gut tells me that putting one format in another is wrong, but I can't seem to come up with concrete reasons.
<root>
<stuff>
thing
</stuff>
<more>
<[!CDATA[{"a":["b","c"]}]]>
</more>
</root>
versus just putting it in the xml
<root>
<stuff>
thing
</stuff>
<more>
<a>
b
</a>
<a>
c
</a>
</more>
</root>
Th...
Hi All,
I've recently been doing some Cross-domain javascript using JSONP, and ASP.NET MVC.
The particular Controller action will only respond to a POST request, this is by design.
In IE8, I can see (via Fiddler2) that the response is correct, and returning a HTTP 200 response, along with the JSONP javascript.
In Firefox, Safari and ...