I have a .ini
file where I store some information outside of the directory tree of the site, it happens that in a password I have special characters.
At the moment that php gets this content it gives problem, the impression I have is that it thinks it is a variable.
Here's a hypothetical example:
In the file ini
:
[config]
pwd=123456!@#$%
In the php file after reading ini
:
...
leu o ini
$pwd = $Arquivo["config"]["pwd"];
$email_pwd = $pwd;
As the content of "pwd"
la in ini
has $
character, I imagine it to be a variable, when $
is actually part of string
.
I tried to enclose double quotation marks but it does not work:
$email_pwd = "$pwd";
If I put the literal string with single quotation marks it will accept:
$email_pwd = '123456!@#$%';
How to circumvent this situation to keep the password in the file ini
?