https://bugzilla.wikimedia.org/show_bug.cgi?id=22561
--- Comment #3 from Erel Segal <erel...@gmail.com> 2010-02-22 20:49:14 UTC --- Thank you, it works only servers where ini_set is enabled. I found a solution that works on all servers, including shared hosting, where ini_set is usually disabled: function get_url_with_agent($url) { $ch = curl_init($url); curl_setopt($ch, CURLOPT_HTTPGET, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_USERAGENT, 'Erel Bot'); $result = curl_exec($ch); curl_close($ch); return $result; } Hope it helps someone. -- Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug. _______________________________________________ Wikibugs-l mailing list Wikibugs-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikibugs-l