Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I set variable 'allow_url_fopen' in .htaccess or php file?

Tags:

php

How can I turn on allow_url_fopen in .htaccess or a PHP file?

like image 561
Jimit Avatar asked Nov 26 '09 14:11

Jimit


People also ask

How to check allow_ url_ fopen in php?

# Fix/SolutionOpen 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

You can't, it can only be set in php.ini (see the docs), unless you're using a version of PHP <= 4.3.4.

If you're using a really old version of PHP (and you shouldn't be) then you can set it in PHP using ini_set.

like image 196
Dominic Rodger Avatar answered Sep 20 '22 08:09

Dominic Rodger