Oh my god, i got it working :) Looks so cool ! Of course the ajaxaction url has to point to the code where the ajax is called from. So in my case this was in a "execute" webskin of ruleShopproducts, so:
<cfset ajaxactionurl = application.fapi.getlink (typename="ruleShopproducts", objectid="#stobj.objectid#", view="execute") /> Thanks... On Jul 9, 1:50 am, MJB <[email protected]> wrote: > Hey Marco, > > What is the name of the webskin that your code is located in? Lets > pretend its called "displayProducts". > > -------- > <cfset ajaxactionurl = application.fapi.getlink > (typename="shopproducts", objectid="#stobj.objectid#", > view="displayProducts") /> > <ft:form name="displayProducts" bajaxsubmission="true" > action="#ajaxactionurl#"> > ----------- > > Notice I have changed the view attribute of the getLink() to the > webskin we are trying to refresh. > > I have also given the form a name (displayProducts) so that when the > view is refreshed the id of the form will remain the same. > > Let me know how you get on. > > -- Mat. > > On Jul 9, 8:41 am, Marco van den Oever <[email protected]> > wrote: > > > Now only the ajax functionality, using the following code i get a > > blank page when clicking next, i am not sure how to handle the view > > attribute, when filling in displayTeaserStandard as view (which i > > thought was logical) that doesn't work: > > > <cfset ajaxactionurl = application.fapi.getlink > > (typename="shopproducts", objectid="#stobj.objectid#", > > view="#stObj.displaymethod#") /> > > > <ft:form bajaxsubmission="true" action="#ajaxactionurl#"> > > > <!--- THIS MEANS PAGINATE ---> > > > <skin:pagination > > query="#q#" > > typename="shopproducts" > > pageLinks="10" > > recordsPerPage="#stobj.numitems#" > > submissiontype="form"> > > > <skin:view objectid="#stobject.objectid#" typename="shopproducts" > > webskin="#stObj.displaymethod#" /> > > > </skin:pagination> > > > </ft:form> > > > Any light in the darkness??? > > > On Jul 8, 5:16 pm, Marco van den Oever <[email protected]> > > wrote: > > > > Yes that helped, added some code and your explanation to: > > > >http://docs.farcrycms.org/display/FCDEV50/Pagination > > > > Might be also easy to copy paste for jump start guide. > > > > On Jul 8, 9:01 am, modius <[email protected]> wrote: > > > > > You're almost there... sorry the doco is appalling without looking > > > > inside the tag for what is going on. Been meaning to add to this to > > > > the Jump Start guide in more detail. > > > > > You are referencing q.objectid but you should be referencing > > > > stobject.objectid (ie. actually request.stobject.objectid) within your > > > > skin:view call instead. > > > > > Basically the skin:pagination tag manages the loop, and provides you > > > > with a new #request.stobject# variable with the contents of the > > > > current row each loop. You can rename this variable using the > > > > r_stobject="myVar" attribute. > > > > > Hope that helps, > > > > > -- gb > > > > > On Jul 8, 1:58 pm, Marco van den Oever <[email protected]> > > > > wrote: > > > > > > Ok i'm a bit further now, only problem i have now is that the cfloop > > > > > gives me the same articles instead of all different ones in a row, > > > > > what am i missing? > > > > > > <skin:pagination > > > > > query="#q#" > > > > > typename="shopproducts" > > > > > pageLinks="10" > > > > > recordsPerPage="#stobj.numitems#" > > > > > submissiontype="form"> > > > > > > <skin:view objectid="#q.objectid#" typename="shopproducts" > > > > > webskin="#stObj.displaymethod#" /> > > > > > > </skin:pagination> > > --~--~---------~--~----~------------~-------~--~----~ You received this message cos you are subscribed to "farcry-dev" Google group. To post, email: [email protected] To unsubscribe, email: [email protected] For more options: http://groups.google.com/group/farcry-dev -------------------------------- Follow us on Twitter: http://twitter.com/farcry -~----------~----~----~----~------~----~------~--~---
