List Info

Thread: Re: php5 and global variables




Re: php5 and global variables
country flaguser name
India
2008-03-25 23:09:22

Hi,

Why do you want to enable the Global variables? The reason why PHP has
turned this off, is to provide flexibility to programmers in using the
variable names. With this turned off, programmers can reuse the same
variable names by understanding the scope.

If you turn this on, you MAY accidentally overwrite the unintended
variable value. I suggest you to let it be turned off and work
accordingly.

The main problem with PHP is that, it lets you design very badly. I
believe this is why PHP programmers are not considered as "real
developers". When I see some PHP scripts by others, I feel surprised by
their variable naming and the prog. flow. No organised structure, no
variable naming conventions, no memory management, nothing. They write the
programs in a hurry. Any way, it depends on the experience and the
professionalism that is showed.

Tarun, sorry if I have said these words for your mail. Please consider
only first two paras for yourself.

Regards,
Manda Krishna Srikanth
http://www.krishnasrikanth.com

php-objects%40yahoogroups.com">php-objectsyahoogroups.com wrote on 03/25/2008 08:16:00 PM:

> hello Friends,
>
> How to set global variables " ON" in php 5 in .htaccess file.
>
> in php4 we could set it by using the following line.
>
> <IfModule mod_php4.c>
> php_value session.use_trans_sid 0
> php_value register_globals 1
> </IfModule>
&gt;
> but what to do for php5 to use global variables, and updating htaccess.
>
> Please suggest me
>
> Warm Regards,
>
> Tarun
&gt;
=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain
confidential or privileged information. If you are
not the intended recipient, any dissemination, use,
review, distribution, printing or copying of the
information contained in this e-mail message
and/or attachments to it are strictly prohibited. If
you have received this communication in error,
please notify us by reply e-mail or telephone and
immediately and permanently delete the message
and any attachments. Thank you

[Non-text portions of this message have been removed]

__._,_.___
.

__,_._,___
Re: php5 and global variables
country flaguser name
United States
2008-03-26 03:01:26

Those who study software engineering will be
professional programmers no matter what language they
use.
--- Krishna Srikanth < krishna.srikanth%40tcs.com">krishna.srikanthtcs.com&gt; wrote:

> Hi,
>
> Why do you want to enable the Global variables? The
> reason why PHP has
> turned this off, is to provide flexibility to
> programmers in using the
> variable names. With this turned off, programmers
> can reuse the same
> variable names by understanding the scope.
&gt;
> If you turn this on, you MAY accidentally overwrite
> the unintended
> variable value. I suggest you to let it be turned
&gt; off and work
> accordingly.
>
> The main problem with PHP is that, it lets you
> design very badly. I
> believe this is why PHP programmers are not
> considered as "real
> developers". When I see some PHP scripts by others,
> I feel surprised by
> their variable naming and the prog. flow. No
> organised structure, no
> variable naming conventions, no memory management,
> nothing. They write the
> programs in a hurry. Any way, it depends on the
> experience and the
> professionalism that is showed.
>
> Tarun, sorry if I have said these words for your
>; mail. Please consider
> only first two paras for yourself.
>
> Regards,
> Manda Krishna Srikanth
> http://www.krishnasrikanth.com
>
> php-objects%40yahoogroups.com">php-objectsyahoogroups.com wrote on 03/25/2008
> 08:16:00 PM:
>
> > hello Friends,
> >
> > How to set global variables " ON" in php 5 in
> .htaccess file.
&gt; >
> > in php4 we could set it by using the following
> line.
&gt; >
> > <IfModule mod_php4.c>
> > php_value session.use_trans_sid 0
> > php_value register_globals 1
> > </IfModule>
&gt; >
> > but what to do for php5 to use global variables,
> and updating htaccess.
> >
> > Please suggest me
> >
> > Warm Regards,
> >
> > Tarun
&gt; >
> =====-----=====-----=====
&gt; Notice: The information contained in this e-mail
&gt; message and/or attachments to it may contain
> confidential or privileged information. If you are
> not the intended recipient, any dissemination, use,
> review, distribution, printing or copying of the
> information contained in this e-mail message
> and/or attachments to it are strictly prohibited. If
>
> you have received this communication in error,
> please notify us by reply e-mail or telephone and
> immediately and permanently delete the message
> and any attachments. Thank you
>
>
>
>
> [Non-text portions of this message have been
>; removed]
>
>

Marc A. Hill
Software Engineer
www.radfinancial.com
http://medisynergi.proboards92.com/index.cgi

__________________________________________________________
Never miss a thing. Make Yahoo your home page.
http://www.yahoo.com/r/hs

__._,_.___
.

__,_._,___
[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )