php - Make pagination work -


Hi I am trying to render Laravel endorsement through Ajax I am getting the data in JSON format

Ajax code

  function pinlist () {$ .ajax ({url: 'pinlist', type: 'post', datatype: 'JSON', success: function (data) {$ ('#pincode-tablebobs') .html (data .tb); $ ('datatabs_pagnet') .html (data.paginate);}}); }  

Administrator

  public function getPinCodeList () {$ pincode = pincode :: whereRaw (not like "pin_delete 1" ") - & gt; Pagination (2); $ Tie = ""; $ I = 1; Foreach ($ pincode-> getCollection () - & gt; all () as the $ PINDATA) {$ tbody. = "& Lt; tr & gt; & lt; td & gt; $ I. "& Lt; / td> & lt; td & gt; . $ PinData- & gt; Pin Code. "& Lt; / td> & lt; td & gt; $ PinData- & gt; Pin_postoffice "& Lt; / td> & lt; td & gt; $ PinData- & gt; Pin_distique_id "& Lt; / td> gt; & lt; td & gt; $ PinData- & gt; Pin_zone_id. "& Lt; / td> "; $ I ++; } $ Paged = $ zipcode- & gt; Link (); Return Feedback: JSON (Array ('TDI = & gt; $ T,' PageNet => $ Pager)); }  

When I try to link to Revolution-> Variables and pass it in json format .. This is showing me an empty string .. But when I echo it Links are being displayed .. I realized that pagination is displayed in the form of link view. How can I pass a paging link through a variable?

You must present it before sending it to a JSON response.

$ paginate = $ pincode-> Link () - & gt; Render ();

Comments

Popular posts from this blog

ios - How do I use CFArrayRef in Swift? -

eclipse plugin - Run java code error: Workspace is closed -

c - Error on building source code in VC 6 -