Jump to content

*SOLVED* ini_set?


Guest askjames01

Recommended Posts

Guest askjames01
ok, i was reading and trying to decode and understand a photogallery php script.
and suddenly i was stumbled with this code...

[code]
//PHPSESSION &AMP FIX
ini_set('arg_separator.output','&');
[/code]

can you guys please explain this code to me further?
what this code do and mean?

and may be this --> &amp code is familiar to me and may be i also forgot the meaning? so what that code do too?

thanks n advance.

-/james/
Link to comment
https://forums.phpfreaks.com/topic/8683-solved-ini_set/
Share on other sites

Let the manual be your friend:

[a href=\"http://us2.php.net/manual/en/function.ini-set.php\" target=\"_blank\"]http://us2.php.net/manual/en/function.ini-set.php[/a]

[a href=\"http://us2.php.net/manual/en/ini.core.php#ini.arg-separator.output\" target=\"_blank\"]http://us2.php.net/manual/en/ini.core.php#...eparator.output[/a]

[a href=\"http://www.w3schools.com/tags/ref_entities.asp\" target=\"_blank\"]http://www.w3schools.com/tags/ref_entities.asp[/a]
Link to comment
https://forums.phpfreaks.com/topic/8683-solved-ini_set/#findComment-31884
Share on other sites

Guest askjames01
ok, thanks for the manual URLs [b]TOPLAY[/b]

I now recall the meaning of this --> & it is just an ampersand.
and i review the manual with ini_set and still don't get it...

because when you look at this -->
[a href=\"http://www.artscraftworks.com/phpinfo.php\" target=\"_blank\"]phpinfo[/a]
the "arg_separator.output" is already set i think?

and why they still declare this? if the php.ini is already set to the right configuration i think?

//PHPSESSION &AMP FIX
ini_set('arg_separator.output','&');

any bright answer PHP GURUS?
I hope you get what i mean brothers?


Link to comment
https://forums.phpfreaks.com/topic/8683-solved-ini_set/#findComment-31894
Share on other sites

ini_set allows you to temporarly change PHPs setting. Some developers do the following:
[code]ini_set('arg_separator.output','&');[/code] so that when they validate their code with the W3C's HTML Validator it doesn't break their xHTML validation. As the validator will won't class your HTML as valid xHTML if your links has an & in them. Instead developers use the HTML entities version (&) of the ampersand.
Link to comment
https://forums.phpfreaks.com/topic/8683-solved-ini_set/#findComment-31955
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.