I need a script that does the following:
1. Detects if a visitor to a webpage is running Firefox.
2. If Firefox is detected show a "Add to Firefox Search Bar" link. If firefox is not detected don't show anything.
3. When the user clicks on the link a standard "Add TestSearch to the list of engines available in the search bar?" dialog is shown. (see mockup)
4. When the user clicks on the Add button, the TestSearch engine is added to the dropdown list on the Firefox search bar. An icon must be added as well.
5. The testsearch engine simply posts the TEXTBOX VALUE from the user to http://www.testsearch.com/search/TEXTBOX+VALUE
Please provide detailed instructions on how to install this in an existing html page.