Giter VIP home page Giter VIP logo

jquery-lazyjson's People

Contributors

rpnzl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

jquery-lazyjson's Issues

Showing - invalid name: "invalidMainElement", type: "error", data: "The main object [object Object] does not exist.

Showing following error

name: "invalidMainElement", type: "error", data: "The main object [object Object] does not exist.

JSON API output :

[{"id":557,"data":{"li_class":"top_none ","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo3.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo3.jpg&w=300&h=250&zc=1","post_title":"Test New gallery"}},{"id":293,"data":{"li_class":"top_none ","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg&w=300&h=250&zc=1","post_title":"gallery 6"}},{"id":292,"data":{"li_class":"top_none third","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo2.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo2.jpg&w=300&h=250&zc=1","post_title":"gallery 5"}},{"id":291,"data":{"li_class":"top_none ","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo3.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo3.jpg&w=300&h=250&zc=1","post_title":"gallery 4"}},{"id":290,"data":{"li_class":"top_none ","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg&w=300&h=250&zc=1","post_title":"gallery 3"}},{"id":289,"data":{"li_class":"top_none third","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/10/gallery_thumb12.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/10/gallery_thumb12.jpg&w=300&h=250&zc=1","post_title":"gallery 2"}},{"id":18,"data":{"li_class":"top_none ","photo_image":"http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg","pimage":"http://emaratfm.wpengine.com/wp-content/themes/adrn/timthumb.php?src=http://emaratfm.wpengine.com/wp-content/uploads/2014/09/photo11.jpg&w=300&h=250&zc=1","post_title":"adrn gallery"}}]

Arrays in object

Hi, in the template, what's the syntax for accessing nested arrays in objects?

Not working in IE

I am using this feed in a dev site currently, and it works fine except on IE. It doesn't seem to be dependant on the version, it just seems to not like IE at all. Any ideas why this might be and how to fix?

Error : The event is not defined in pagination settings

Hello ,
i followed your demo , and i have the folowing issues in debug mode :
Object {name: "currEvent", type: "error", data: "The event is not defined in pagination settings."}
vendor.js:7 Object {name: "pagination", type: "notice", data: Object}
vendor.js:7 Object {name: "options", type: "notice", data: Object}

Thank you

If/Else Statements

How do you write login into the templates?

I've tried single and double brackets for an if statement.

{if (data.image !== "")}
    <div class="image">
        <a href="/events/{{data.id}}/"><img src="{{data.image}}" /></a>
    </div>
{{/if}}
{if (data.image !== "")
    <div class="image">
        <a href="/events/{{data.id}}/"><img src="{{data.image}}" /></a>
    </div>
{/if}

Any help would be appreciated.

Unknown Error = The Event is not defined in pagination settings

I followed your tutorial pretty much to a t, but couldn't get this working. I was hoping to use this library to paginate through an api that has next links, like the itunes reviews url. I now realize that I can't do that with this api, but was wondering if you could tell me why this doesn't work...

html
<div id="ratings" class="row small-up-1 medium-up-2 large-up-3">
<div class="column" id="template-ratings">
<div class="callout">
<p>{{feed.entry.title.label}}</p>
</div>
</div>
<!-- /template -->
</div>

my js file
(function($){ $( 'div#ratings' ).lazyjson({ api: { uri: 'https://itunes.apple.com/rss/customerreviews/id=284882215/json', method: "jsonp" }, debug: true }); })(jQuery);

console
And here's what I'm getting in the console...

Object {name: "currEvent", type: "error", data: "The event is not defined in pagination settings."}
Object {name: "pagination", type: "notice", data: Object}
Object {name: "options", type: "notice", data: Object}

rpnzl not working

Thank you for this plugin.
But i tried all the demos in your website, but not working. it only returns :
{{data.first_name}} {{data.last_name}}.
ID: {{id}}

Any help would be appreciable.
Thank you

Outputting code

You do not say what to do with the {{template}} as this does not render on the page.

How do you get the data object back to work with it on the page?

Load More items changes

Hi,

I's it possible to change the way of loading more items? In one of your example we can load more items by clicking "show more" button but then all current items are replaced by new one. Id like to just add let say 20 more items to existing one instead replacing them. So when page is loaded you can see 20 items, click button "show more" and then you can see 40 items, 60 items etc.

Thanks for your help!

Pass a json string

Hi, how can I pass a variable containing a json string rather than uri? Great plugin, thanks.

How to make this work with jquery mobile

This works as regular html+jQuery
<ul id="buttons">
<li id="template-buttons" style="display:none;">
<span>{{value}}</span>

</ul>

But when converted to jQuery Mobile Listview, it does not work any more:
<ul id="buttons" data-role="listview">
<li id="template-buttons" style="display:none;">
<span>{{value}}</span>
</li>
</ul>

This is the js code
$( 'ul#buttons').lazyjson({
loaderImg: 'js/libs/jquery-mobile/images/ajax-loader.gif',
effect: 'slideDown',
pagination: {
active: true,
pages: 1,
count: 10
},
api: {
uri: 'http://gd.geobytes.com/AutoCompleteCity?q=phi'
}
});

Any Ideas?

Question

It looks like this is not in development any more but I thought I would ask a question about the template. I have a structure like this:

   <ul id="imageGallery">
    <!-- template -->
    <li id="template-imageGallery" class="light" data-thumb="{{slide.thumb}}" data-iframe=" {{slide.iframe}}" data-src="{{slide.Ssrc}}" data-sub-html="{{slide.subhtml}}" data-description=" {{slide.description}}">
    <img data-thumb="{{slide.thumb}}" class="img-responsive" src="{{slide.thumb}}" alt="{{slide.label}}" /> </li>      
  <!-- /template --> 
  </ul>  

My problem is I need the 'li' to contain json data as well. Is there a way to do this or am I stuck?

Cannot set html data attribute in template

Cannot use the response in html data attribute.

For example, the {{id}} is showing literal value instead of reference value in the data-id attribute

{{data.first_name}} {{data.last_name}}

ID: {{id}}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.