Problem with system('start http://...') in callbacks of buttons when using Firefox?

From: Date: Tue, 01 Mar 2005 20:40:33 +0000
Subject: Problem with system('start http://...') in callbacks of buttons when using Firefox?
Groups: php.gtk.dev 
Request: Send a blank email to php-gtk-dev+get-944@lists.php.net to get a copy of this message
Hi! For some days I noticed that the gtk widgets hangs when opening a webiste in a browser by using system() and START under windows. It just hangs when there is still a browser window opened. If no window is opened it will work fine. The problem definitfly isn't because of system(), pipes and shell executes are producing the same error, but in batch-files, with c shell execute or using the command.com it works. After aborting the execution of php the links gone to be opened in webbrowser. I think it isn't a gernal problem with callbacks, because by testing this with a gtk timeout it works fine. It only happens on callbacks of buttons and similar widgets. I'm using windows 2000 and the Firefox webbrowser. The settings of Firefox when getting in this trouble are simply "Open new links in a new tab". A friend of mine confirmed the error. Here is some code producing this error (In combination with described webbrowser settings) <?php dl('php_gtk'); //Creating a button with calback to "website".. $button = &new GtkButton('Google'); $button->connect('clicked', 'website'); //Creating a window.. $box = &new GtkHBox(); $box->add($button); $window = &new GtkWindow(); $window->connect_object('destroy', array('gtk','main_quit')); $window->add($box); $window->show_all(); //The website function which starts google.com in default webbrowser.. function website() { system('start http://www.google.com'); return TRUE; } //Starting main loop.. gtk::main(); ?> I didn't test it using Opera with tabbed browsing yet, but this might interesting. Any ideas? _________________ Mit freundlichen Grüßen, Florian Breit PHPWS Projektleitung - Webmaster Mail: florian@phpws.org Web: http://www.phpws.org

« previous php.gtk.dev (#944) next »