Welcome Guest, Not a member yet? Register   Sign In
how to add more value in one variable?
#1

[eluser]674DBK[/eluser]
hi..

how to add more value in one variable?

example:
Code:
<?
for($i=0;$i<5;$i++)
{
$myvariable .= $currentvariable ."^";
}
?&gt;
#2

[eluser]xzela[/eluser]
I think you may want to look into named/associative array.

Are you interesting in something like this:
Code:
$a = array();
$a['var01'] = 'foo';
$a['var02'] = 'bar';

echo($a['var02']); //will print bar;

more information about arrays can be found here:
http://php.net/manual/en/language.types.array.php




Theme © iAndrew 2016 - Forum software by © MyBB