-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Getting data from service #10
Comments
As long as your service returns JSON it should not matter how the service is written (asp.net, php etc.). jQuerys getJSON() is used, or as an option jquery.post(). It would be easy to add an option for other stuff as well if jQuery supports it. |
$(".Reviews").autobrowse({
// var a = $.getJSON("Services/AjaxRequestHandler.aspx?clientUserId="+id+"&count=10&page="+offset+"&callback=?".replace(/OFFSET/, 1+Math.round(offset/10)))
my service is returning Json correctly but still nothing happened template never gets fired. :( |
plese help i dont know whats wrong this now. i have copied the json of twitter paris hilltion in variable like this
Again its not workign :( and i wonder why there is no blog posts related to this jQuery plugin on the whole google :( |
Hi man, this is a rather simple plugin for infinite scrolling, there's not much docs.. We are able to help you if you have the time, otherwise it would be wise perhaps to use another plugin. As @msjolund said, there's no reason why this plugin wouldn't be suitable for you. What is the problem you are having? What errors are you getting? What are you attempting to do? Can you paste some code in pastie.org? ** ps ** can i correct your code tags? |
Hi droope thanks for your reply but i want to use this plugin at any cost its amazing the only problem am having is when i got the json frm a Web Service its not being rendered on the page even i just copied the json of "paris hiltion" in a local variable in scirpt and tries something like this var json = "My JSON Rerturned by Web Service" the json is not being rendered on the page because template: function (response) Although the twitter sample stated above works fine. P.S: yes sure you can modify tags to whatever you want. |
there is no script error but nothing rendered on page |
@naveedrafi Please create a reproduction at http://jsfiddle.net/, or at least provide some of your code that you use for calling the plugin (html elements, js line). Seems like there is some problem with how you have called the plugin, i.e. what Dom elements you are using for filling with content etc. |
kindly view it on fiddle i have included jquery.esn.autobrowse.js but not caching js. Thanks for your support. |
jQuery and autobowse was not added in the fiddle linked to. But I see the problem. Your "url" function does not return a url for the plugin to use. It acutally makes it's own ajax request. The "url" argument should be a string url, or a function returning a string url. |
can you please more elaborate it or provide a sample code with ajax call to web service just like i did. Thanks. |
I think it would be possible for you to just return the url in the url function, and use the postData option (see the source code) to set your post data, and use POST. |
Hey I get: divToBeWorkedOn is not defined when trying to run your code, and it loops indefinitely. Might be because it's getting a 404
|
hey @naveedrafi hows everything going? |
hi. this is kind of an old thread but i am trying to do the same thing. and i can't find much information anywhere else. i have an asp.net webservice that returns json. all of the examples i found on the web has .ajax call to the service itself. so i am not sure how to use the plugin to work with this service. |
url: function (offset) { return "http://twitter.com/status/user_timeline/ParisHilton.json?count=10&page=OFFSET&callback=?".replace(/OFFSET/, 1+Math.round(offset/10)); }
there is no as such source available for this plugin. kindly provide a good example how can we pull data from a service in asp.net. it will be highly appreciated. Thanks.
The text was updated successfully, but these errors were encountered: