Contact Us Forum Rules Search Archive
WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Web Programming Discussion Forum Working with an API? Developing a plugin? Writing a Mod or script for your favorite blog, Web 2.0 site or Forum? Welcome.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 09-08-2006, 03:13 PM
WebProWorld New Member
 

Join Date: May 2006
Posts: 5
lejonesboy RepRank 0
Default my favorites / shortlist with php mysql

hi, i'm trying to create a section similar to a shopping cart but to use it as a 'my favorties' page. ie. for a holiday rental site where you can add your favorite houses to a short list.. here is a perfect example www.holidayhouses.co.nz (see short list section) of what i'm trying to do in php / mysql...the data base is all set..just need to activate this part with an add to favorites button which essentially stores the rental advert in the cart / favorites / short list page...any help would be great..cheers
Reply With Quote
  #2 (permalink)  
Old 09-09-2006, 11:43 AM
arvana's Avatar
WebProWorld Pro
 

Join Date: Jul 2003
Location: Guelph, Ontario, Canada
Posts: 157
arvana RepRank 0
Default

Are your users logged in to an account when they store their favorites? If so, just store their faves in a table against their username. Then the favorites page can query that table and display the relevant houses.

If you want to let anybody store favorites without having to create an account first, then you'll likely have to do it with cookies instead.

Or maybe you could do a combination of both, so if an anonymous user with favorites stored in a cookie then creates an account, their info gets stored in the table for anywhere access.

Does that help?
__________________
Arvana
arvanadesign.com
Reply With Quote
  #3 (permalink)  
Old 09-09-2006, 02:04 PM
WebProWorld New Member
 

Join Date: May 2006
Posts: 5
lejonesboy RepRank 0
Default

thanks for the reply, the users will not be logged on, i'm trying to do it as simple as possible by just using sessions, once the session is ended all information will be deleted, as i'm a novice i am trying to adapt a simple shopping cart to do the job

am currently trying using this tutorial as a guide

http://www.thewatchmakerproject.com/...-shopping-cart

if you know of any better ones please could you post the link.... thanks v much
Reply With Quote
  #4 (permalink)  
Old 09-09-2006, 02:51 PM
arvana's Avatar
WebProWorld Pro
 

Join Date: Jul 2003
Location: Guelph, Ontario, Canada
Posts: 157
arvana RepRank 0
Default

There's this one:

http://www.zend.com/zend/spotlight/sessionauth7may.php

and I also recommend:

http://www.paulspages.co.uk/pcp/cookielib/

For the best user experience, it would probably be best if their favorites were saved until next time, and it's quite easy to do, especially if you use the paulspages libraries.

Good luck!
__________________
Arvana
arvanadesign.com
Reply With Quote
  #5 (permalink)  
Old 09-10-2006, 08:35 AM
WebProWorld New Member
 

Join Date: May 2006
Posts: 5
lejonesboy RepRank 0
Default

thanks for the help...will give them both a try..cheers
Reply With Quote
Reply

  WebProWorld > Webmaster, IT and Security Discussion > Web Programming Discussion Forum
Tags: , , ,



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Search Engine Optimization by vBSEO 3.2.0