How to search words in text files
How to search words in text files even they are not in the same directory?
If I have a website. It has some of directories in it. How to build a search page to open every each *.htm, *.html file and search key words in it? And then response the results in HTML.
Eric and Stephen, Thanks for your comments. It seems that the only solution will be in server side solution.
What about using Text Finding? I think it is a good and easy to search word in text files.
becuase its a local application. he wants the results to run as the result of a user action on a web page.
Set up a database, far more simpler and you can have a couple of PHP scripts, one to handle the AJAX calls to it for keywords etc, another that parses a HTML page for content.
I am assuming that your content is going to be static. If it isn't then look in to a CMS system that has the search features you need already built in.
Last edited by \\.\; 09-14-2013 at 12:47 PM.
Reason: Felt like trying to edit a post after posting...
If your post falls off the page, bump it. ...
Please remember to wrap any code you have in forum tags:-
[CODE]...[/CODE] [HTML]...[/HTML] [PHP]...[/PHP]
If you can't think outside the box, you will be trapped forever with no escape...
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)