Solved

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

Posted on 2003-11-25
3
259 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
hart earned 500 total points
ID: 9822797
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
ID: 9833672
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
ID: 9855878
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

Turn Insights Into Action

You’ve already invested in ITSM tools, chat applications, automation utilities, and more. Fortify these solutions with intelligent communications so you can drive business processes forward.

With xMatters, you'll never miss a beat.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A web service (http://en.wikipedia.org/wiki/Web_service) is a software related technology that facilitates machine-to-machine interaction over a network. This article helps beginners in creating and consuming a web service using the ColdFusion Ma…
In our day to day coding, how many times have we come across a necessity to check whether a URL is a broken link or not? For those of you that answered countless and are using ColdFusion like myself, then this article is for you.  It will show yo…
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

696 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