Jump to content

PHP with MySQL or JavaScript with a text file


rahulkadukar

Recommended Posts

This is my website http://www.rahulkadukar.info/

 

As you can see I have the blue navigation bar on top and on mouse hover you can see a drop down menu. The contents of the drop down menu can change and I wanted to write a script that would populate the contents of the drop down menus.

 

Which of these is a better option

1. Use JavaScript along with a text file and use JavaScript to populate the drop down

2. Use a SELECT in PHP to populate the drop down menu

 

I am expecting that the 10 main columns would have at the most 20 entries each.

Link to comment
Share on other sites

Well I don't know why you would use javascript at all.

 

A mysql query for something as simple as a menu might slow you down 30ms...but if you are building the menu (and don't want to gow ith a database) you would be better of going with a text file with PHP than javascript.

 

 

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.