Solved

Select Multiple Items Tables, Add to Cart, View Cart Later, Email Cart Contents

Posted on 2003-11-25
3
243 Views
Last Modified: 2013-12-24
I've developed a webpage that displays the contents of my database. The user has 4 different views to look at, (View 1, View 2, View 3 and View All). In each of these views the user can select some rows, add the rows to a cart and continue browsing.

I know how to get what the user selected , but i don't know how to get what they selected, store their selection, allow them to continue surfing, store more rows, and then finally email the administrator their selections.

This is what i don't know how to do:

1. I do not know how to allow users to Sort Columns by clicking a Column Header.

2. I do not know how to allow user to select rows (via checkbox) and send the selections to a cart (structure i am assuming), continue browsing and add more items to cart.

3. I do not know how to have all the pages display how many items they have the the cart.

4. I do not know how to have user view cart and delete selections.

5. I do not know how to have user email their selections over to an email address that is stored in the same database (different table).

6. I do not know how to send html email to administrator.

To get a more concise picture of what i am attempting, please view the following

1. My previous post: http://www.experts-exchange.com/Web/WebDevSoftware/ColdFusion/Q_20807809.html#9816347
0
Comment
Question by:zakirdavis
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
hart earned 500 total points
Comment Utility
you are asking for a whole site to be created....

1. for sorting of columns..

by default say u have a query
<cfparam name="orderbyfield" value="id"><!--- i am assuming u have unique field called id --->
<cfquery name="Qry_GetDetails" datasource="dsn name">
   select  details from table order by #orderbyfield#
</cfquery>

now after u have shown the complete table details in a tabular format..
give an image that shows asc [a arrow key that points downwards]. now on click of this image u will have a hidden field called orderbyfield in the form..

say if he clicks on first name then assign FirstName desc / asc in the hidden field using javascript...
and submit the form to the same page .

now when the query gets executed the orderbyfield varable will be found defined and ur FirstName desc / ascwill be fired..

thats it about sorting...


now the second part of adding items to cart

u will have an unique id for each row in the table.
so assign that id as the value for the check box..

now create a table that will store the id's selected by the user.
so ur table will have the logged in users id and then the selected id's in the table...

so anytime the user logs in you can query this database and show the details of his cart,
then whe he confirms the order delete that record from the this table and add it to the confirmorder table.

and using the details from the confirmorder table mail it to the administrator..


Regards
Hart
0
 

Author Comment

by:zakirdavis
Comment Utility
I think i want to use sessions for storing the information the user selected. Creating a new table could get big. Also, i want to stray away from users having to log in.
0
 
LVL 11

Expert Comment

by:hart
Comment Utility
no the tables won't become big because, once the order is confirmed, delete the particular record from the table and so the table size will remain small..

Regards
Hart
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

This is a guide to setting up a new WHM/cPanel Server to be used for web hosting accounts. It is intended for web hosting company administrators and dedicated server owners. For under $99 per month (considering normal rate of Big Data Cetnters like …
One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now