Jump to content

Search Box To Shorten Table


chadc1179

Recommended Posts

I need some direction/help. The website is www.millerelectricwork.com, as you will see I have built a table with lots of information. I want someone to be able to go on that site and enter a word in a "search box" and have it show only the information pertaining to the search. Is this able to be done? Thanks in advance for your time.

Link to comment
Share on other sites

I don't think it will be that easy to do that, unless all that data is stored in a database and you can use PHP/MySQL to sort through and display the correct data.

 

One option, though it isn't isn't exactly what you have in mind would be this jQuery tablesorter plugin: http://tablesorter.com/docs Basically, the user would click on the header and the table would be sorted based on that criteria.

 

Keep in mind that the user does have the ability to find items using their browser's search functionality, but I'd assume not everyone is going to think of that.

Link to comment
Share on other sites

First off let me thank you for the help. I do have this same information stored in PHP/MySQL. The point I got stuck going that direction is connecting my site and the PHP/MySQL so that it could be utilized. Maybe I could go back to going this direction, but if so will I have to re-link everything?

Link to comment
Share on other sites

Yeah, if you go back to using a database you'll need to redo all of the code that displays the data in the table. Personally, I'd suggest using the jquery plugin I suggested, and perhaps maybe making a note in the page itself that most browsers have search functionality they can use if they are looking for something specific in the table.

Link to comment
Share on other sites

Yeah, if you go back to using a database you'll need to redo all of the code that displays the data in the table. Personally, I'd suggest using the jquery plugin I suggested, and perhaps maybe making a note in the page itself that most browsers have search functionality they can use if they are looking for something specific in the table.

 

 

I do apprectiate the help and your suggestion would work as a short term solution, but I would like to get it to the point of not only being able to do a look up but change some of the fields to drop downs, be able to add and remove tools, etc. and this is just the start of the project. Could you give me a hand in connecting MySQL Database to my website so that I could get started in that direction or even point me toward tutorials or lessons of some nature that will get me started? Thanks again for all your help.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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.

Loading...
×
×
  • Create New...