close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

multiple categories

Thread began 9/05/2014 7:39 am by Christopher West | Last modified 9/05/2014 9:59 am by Christopher West | 1149 views | 3 replies

Christopher WestCommunity Expert

multiple categories

Hi I am trying something different with creating a menu system for a new ecommerce site.

Im trying to plan to best approach for creating the menu system, database and catogories page.

But I ham having trouble in deciding the easiest/best approach and wondered if I could get you advice.


current the menu structure is as follows:
Home (dynamic drop down menu)
Living (dynamic drop down menu)
Dining (dynamic drop down menu)
Sleeping (dynamic drop down menu)
Home Accessories (dynamic drop down menu)
Decorative Items (dynamic drop down menu)
New Arrivals
Best Sellers
In Store Now

I have Products table
I have a Category table

The products table has a field "CategoryID" that links that product to what ever category record in the category table.
In the products table I have fields NEW ARRIVALS, BEST SELLERS and INSTORENOW (which stores a 1 value)

I also have a search box in the header that will search on product name.

now, my main question/concern, I would want to keep my file structure to a category.php page and a product.php page. But then I am trying to work out how the best way I can do this since for the category.php page the recordset would be pulling in a URL variable based on several conditions (since first its checking from the dropdown menus for the different categories and then their is the condition that if the page is being entered from the user selecting either, NEW ARRIVALS, BEST SELLERS or IN STORE NOW...as well as if the user have chosen to use the product name search box that would list all products via the category page.

The simplest way to solve this is to separate the conditions into separate files such as:
category.php
new-arrival.php
best-seller.php
in-store-now.php
search.php

but I feel this is a bad method of programming as its basically repeating page structure and code to some extent. so would prefer to keep it all contained in one page file.

I wonder if its a case of one big recordset or would I need several recordsets on the same page (which again is bad programming).

Any thoughts or opinions on the best approach?

Regards

Chris

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...