I use the default search engine in Windows XP. It’s not great, but it works. It saves the hassle of deciding whether to use Google, Copernic or MSN and the overhead of having another program installed. It’s also more logical to use – I don’t need to open up my web browser to search the contents of my PHP files.
Windows Search, by default, does not allow you to search PHP. This is because PHP files are a unknown file type. I searched and found the solution.
- Click Start, and then click Search (or point to Search, and then click For Files or Folders).
- Click Change preferences, and then click With Indexing Service (for faster local searches).
- Click Change Indexing Service Settings (Advanced). Note that you do not have to turn on the Index service.
- On the toolbar, click Show/Hide Console Tree.
- In the left pane, right-click Indexing Service on Local Machine, and then click Properties.
- On the Generation tab, click to select the Index files with unknown extensions check box, and then click OK.
- Close the Indexing Service console.
Great, always wondered why you weren’t able to search through your PHP pages.
Thanks cow ^_^
Thanks a lot. You saved me a ton of time at a very late hour of the day.
Thankyou.
Sincerely,
Paul
Extremely useful – been wonderong why windows was doing that – you’re a star!
Many thanks – I couldn’t figure out for the life of me why all my searches on PHP files failed!
Simply awesome. Thanks.
Perfect. Thanks for this, it was slightly driving me mad 🙂
Thank you very much,
You’re solution has been very helpful.
you rock.
i wonder who’s the kickin brain-dead mamagüevo engineer that decided that setting would be off by default.
Help..!! I can’t find “For Files or Folders” button…
I also cn’t find “Change Preference” button..
Please, help me… Thx
Very Helpful for my same problem!
Thanks – this was driving me crazy.
I knew it had something to do with file type association as my co-worker had PHP files associated with Dreamweaver on his PC and I had no PHP application association.
He could search PHP files, I couldn’t.
Great tip – worked exactly as you stated.
Anyone know how to do this in Windows 7?
thnaks!
Thanks so much!
these steps did nothing… the settins were already as described. Still can't search php files.
Thanks, Ken!! 🙂 I keep an old copy of dreamweaver just for being able to search in php files but it’s hit or miss whether it can find the right file before coming across something that offends its sensibilities and brings on a collapse.
A gem! 🙂
tags: FIND STRING PHP FILES WINDOWS
12 years later and this is still a helpful post!
Anyone know how to do this in Windows 7?
In window 7 it is basically the same. Change the file settings in Indexing Options – Advanced – File Types.
Window will have to recompile after you change the settings which can take a while depending on how many file you have.