You are here: Re: how to merge veriables? « PHP Programming Language « IT news, forums, messages
Re: how to merge veriables?

Posted by Krustov on 11/16/05 04:48

<comp.lang.php , Dave , ???@???.???>
<TpWdnZjPTM9lCufeRVn-ig@giganews.com>
<Tue, 15 Nov 2005 20:22:48 -0600>

> This seems relatively simple, and I'm sure I've done it in the past, but
> I can't seem to come up with a solution.
>
> the following variables are sent via form using textbox inputs:
> $var_1 = 'var1';
> $var_2 = 'var2';
> $var_3 = 'var3';
>
> I want to use the variable values to create mySQL column names like so:
>

$temp="$var_1$var_2$var_3"; can be handy at times but not what your
looking for .


$temp=1;
while ($temp<4)
{
$demo="$var_$temp";
do whatever you want with it
}

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация