Este código solo funciona en * googlechrome.Cómo crear cookies antes de abrir() en Selenium
$this->browserBot->setCommandLineFlags('commandLineFlags=--disable-web-security');
$this->browserBot->setBrowser('*googlechrome');
$this->browserBot->setHost('localhost');
$this->browserBot->setPort(4444);
$this->browserBot->setBrowserUrl('http://example.com');
$this->browserBot->start();
$this->browserBot->createCookie('foo=bar', 'path=/; domain=.example.com');
$this->browserBot->open('http://example.com/print_cookie.php');
En * * Firefox y iexplore sólo funciona esto:
$this->browserBot->start();
$this->browserBot->open('http://example.com/blank_page.html');
$this->browserBot->createCookie('foo=bar', 'path=/; domain=.example.com');
$this->browserBot->open('http://example.com/print_cookie.php');
¿Puedo crear cookies antes de open() (sin llamada redundante abierta()) en * Firefox, etc?