1. Let's first start by creating the FirefoxProfile object:
FirefoxProfile fp= new FirefoxProfile();
2. Now we will set the preference by using the below method:
fp.setPreference("browser.startup.homepage","http://www.google.com");
3. To get the profile to be used, we need to pass it in to the driver. To do this, we need
to do the following:
driver = new FirefoxDriver(fp);
OR
Refer this page and create firefox profile https://support.mozilla.org/en-US/kb/profile-manager-create-and-remove-firefox-profiles then use below code in script.
I want my browser to launch without geolocation popup. I don't want to set a new firefox/chrome profile by always enabling this field and then launch that profile.Is there any way by which I can directly set some "Key" "Value" pairs of the browser using capabilities?
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-user...@googlegroups.com.
To post to this group, send email to seleniu...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/d8067ba9-0541-4592-91c7-d30b6044b8be%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.