Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 8 years ago.
Improve this question
How can I divide a md5 function with a colon?
Currently I have this:
$ms = md5($transactionid:$secretkey);
But that code is invalid.
I can divide it with a "." but not a ":"?
$ms = md5($transactionid.':'.$secretkey);
You need to concatenate with .
Related
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 1 year ago.
Improve this question
str_replace("~","af53261f02cbb39d10c6bb0e53d180da5fee7d3c4c784f632e35abcf33b08fdc","$encode");
How can we put the output of the str_replace() function into a variable?
you can try this:
$variable = str_replace("~","af53261f02cbb39d10c6bb0e53d180da5fee7d3c4c784f632e35abcf33b08fdc", "$encode");
Was that your question?
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 3 years ago.
Improve this question
How can i echo PHP Get request with []?
example: value=ok¶ms[account]=123456
There is no problem with:
echo $value = $_GET["value"];
Not working with:
echo $account = $_GET["params[account]"];
echo $account = $_GET["params"]["account"];
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 6 years ago.
Improve this question
So basically I am trying to save something on my root folder:
$xml->save('../datas/' + $randomString + '.xml');
But it doesn't work. however, when I do
$xml->save('../datas/hi.xml');
it does. so I figured, it must be a problem with my var, randomString:
$randomString = substr(str_shuffle("0123456789"), 0, $length);
So, what am i doing wrong?
You want string concatenation. In PHP the operator for it is ., not +.
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 7 years ago.
Improve this question
I'm pretty new to php and I have problem with 2 dimentional array. When I try to do this:
$tab[0][0] = "dupa0";
$tab[0][1] = "dupa1";
echo("$tab[0][0]");
It doesn't work. How can I print a single element from this array?
you have to remove the quotes:
echo($tab[0][0]);
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 7 years ago.
Improve this question
I have this pattern:
preg_replace_callback('##abc\((.*?)\)(.*?)#end.#is', ..
My template string:
$test = "#abc('test')<h1>test</h1>#end"; // not working
$test2 = "#abc('test')<h1>test</h1>#end "; // working
Why it doesn't work if there's no space after #end?
As #Rizier123 pointed out, this is the correct regex:
preg_replace_callback('##abc\((.*?)\)(.*?)#end#is', ..