Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

add allow_url_fopen to my php.ini using .htaccess [closed]

Tags:

php

I want to allow allow_url_fopen on my server . I have asked my host and they said it can be done with a .htaccess file. Can anyone tell me how to go about this ?

like image 763
Mick Avatar asked Sep 12 '10 08:09

Mick


People also ask

Where is Allow_url_fopen?

Open the php. ini file and search allow_url_fopen . If you find it then change allow_url_fopen=Off with allow_url_fopen=On . If you have not found the allow_url_fopen then simply add the allow_url_fopen=On .


1 Answers

Try this, but I don't think it will work because you're not supposed to be able to change this

Put this line in an htaccess file in the directory you want the setting to be enabled:

php_value allow_url_fopen On 

Note that this setting will only apply to PHP file's in the same directory as the htaccess file.

As an alternative to using url_fopen, try using curl.

like image 154
Kranu Avatar answered Oct 10 '22 09:10

Kranu