Hello ty for the reply You wouldn't by chance be able to help me with a patch. Your talking about the paginate.py file to patch set_links in there or with in the set_links value in my code?
Your the developer of Web2py Utils is that correct? Nice work on it :D *cheers Andrew On Wed, Nov 10, 2010 at 5:24 PM, Thadeus Burgess <thade...@thadeusb.com>wrote: > Its losing the args when it creates a new URL. It will require a patch on > set_links so you can pass custom args and vars to URL. > > -- > Thadeus > > > > > > On Wed, Nov 10, 2010 at 4:36 PM, Andrew Evans <randra...@gmail.com> wrote: > >> I just noticed the difference in URLs >> >> https://127.0.0.1:8000/Working/display/product_wall/4056 >> >> above is the comments on the product notice the id. >> >> below is the next link of the pagination >> >> https://www.127.0.0.1:8000/Working/display/product_wall?p=5 >> >> it loses the 4056 which is the id of the product >> >> I think it may have to do with response value. Any ideas? >> >> >> >> On Wed, Nov 10, 2010 at 9:04 AM, Andrew Evans <randra...@gmail.com>wrote: >> >>> Hello I am trying to create some pagination on my comments page >>> everything seems to be working, however when I click the next link it goes >>> to a page that all it says is None >>> >>> Anyone know why this is happening and how to fix it >>> >>> There are entries in the db. >>> >>> Thanks in Advance >>> >>> below is my code >>> >>> *cheers >>> >>> >>> def product_wall(): >>> this_page = request.args(0) >>> product=db(db.product.id == this_page).select(db.product.ALL) >>> for products in product: >>> #comments=db(db.comment.product == >>> this_page).select(db.comment.ALL) >>> comments=db.comment.product == this_page >>> orderby = ~db.comment.id >>> pcache = (cache.ram, 15) >>> stars = StarRatingWidget(single_vote=True) >>> db.comment.rating.widget = stars.widget >>> >>> db.comment.product.default = products.id >>> form = SQLFORM(db.comment) >>> db.comment.product.id = products.id >>> if form.accepts(request.vars,session): >>> response.flash = 'Your Comment has been submitted' >>> paginate = >>> Pagination(db,comments,orderby,display_count=2,cache=pcache,r=request,res=response) >>> rows=paginate.get_set(set_links=True) >>> return dict(comments=rows,form=form,products=products) >>> elif form.errors: >>> response.flash = 'Please correct your error' >>> paginate = >>> Pagination(db,comments,orderby,display_count=2,cache=pcache,r=request,res=response) >>> rows=paginate.get_set(set_links=True) >>> return dict(comments=rows,form=form,products=products) >>> else: >>> paginate = >>> Pagination(db,comments,orderby,display_count=2,cache=pcache,r=request,res=response) >>> rows=paginate.get_set(set_links=True) >>> return dict(comments=rows,form=form,products=products) >>> >>> >>> >> >