Jump to content

Products Menu with database


webvidhya1

Recommended Posts

Hi all,

 

I am new to PHP,  I am doing a website in PHP for one of my client, here I need sub menus(second child also in some cases) in Products.

I created a database with all products, via Column ( category, Sub-category, Product Name, image, Description etc) here I want to show products depending  on category and Sub-category.

 

I want to get your valuable thoughts to do this efficiently. I thought if all the Sub-menus (Sub-category) loads while page starting it may simply waste of bandwidth and reduce speed, so thought to load the Sub-category only when the particular sub-menu is clicked. and disconnect after leaving that particular page.

 

Please correct me if i am wrong. Please let me know how to do this, if possible please share the code/link.

 

Thanks in advance your valuable time.

 

Thanks,

webvidhya

Link to comment
Share on other sites

So you are looking to dynamically generate the sub-categories based on whatever category is selected, correct? I assume that you are looking to do this without the page reloading, correct? If so, you will need to look into a solution, such as AJAX, that connects the front end (HTML) to the back end (PHP).

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.