RE: [PHP] advise on simplfying session usage

2012-01-12 Thread mail.pmpa
When I have many calls to $_SESSION I do: $s = &$_SESSION; $s['foo'] = 'bar'; echo $s['foo']; //bar -Original Message- From: Haluk Karamete [mailto:halukkaram...@gmail.com] Sent: sexta-feira, 13 de Janeiro de 2012 01:17 To: php-general@lists.php.net Subject: [PHP] advise on simplfying

Re: [PHP] advise on simplfying session usage

2012-01-12 Thread tamouse mailing lists
On Thu, Jan 12, 2012 at 8:52 PM, tamouse mailing lists wrote: > On Thu, Jan 12, 2012 at 8:45 PM, Haluk Karamete > wrote: >> I agree... that was just a wild idea! :) >> Let's forget about it! >> >> What's a good PHP programming editor you'd recommend on a mac for starters? > > (Remember to bottom

Re: [PHP] advise on simplfying session usage

2012-01-12 Thread tamouse mailing lists
On Thu, Jan 12, 2012 at 8:45 PM, Haluk Karamete wrote: > I agree... that was just a wild idea! :) > Let's forget about it! > > What's a good PHP programming editor you'd recommend on a mac for starters? (Remember to bottom post.) My favourite on the Mac is TextMate, but it's not $free. (It's als

Re: [PHP] advise on simplfying session usage

2012-01-12 Thread Haluk Karamete
I agree... that was just a wild idea! :) Let's forget about it! What's a good PHP programming editor you'd recommend on a mac for starters? On Thu, Jan 12, 2012 at 6:39 PM, tamouse mailing lists wrote: > On Thu, Jan 12, 2012 at 7:16 PM, Haluk Karamete > wrote: >> Again, coming from ASP back

Re: [PHP] advise on simplfying session usage

2012-01-12 Thread tamouse mailing lists
On Thu, Jan 12, 2012 at 7:16 PM, Haluk Karamete wrote: > Again, coming from ASP background, I'm trying to minimize the typing > for most needed functionalities.. > > in asp, to set a session var, you go <%session("age")=90%> and to > output it, you just go <%=session("age")%> > > in php, you've go

[PHP] Re: advise on simplfying session usage

2012-01-12 Thread Jim Giner
You're kidding us aren't you? session("age") =90 versus $_SESSION['age']=90 (btw you left out a keystroke) That's a difference of 2 keystrokes. And you're looking to save keystrokes? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] advise on simplfying session usage

2012-01-12 Thread Haluk Karamete
Again, coming from ASP background, I'm trying to minimize the typing for most needed functionalities.. in asp, to set a session var, you go <%session("age")=90%> and to output it, you just go <%=session("age")%> in php, you've got to _SESSION['age']=90. that's a lot of keyboarding, lots of double

Re: RE: [PHP] passing variables to php script

2012-01-12 Thread Tim Streater
On 12 Jan 2012 at 18:51, David Savage wrote: > Installed apache onto a win2K server, and have the html file & php file in the > same folder (Q:\ASTERISK\) on the Q: drive (which is just another drive in > this same server). I opened the html file using IE 6.0. What I'm thinking > is there may

[PHP] Re: srand questions

2012-01-12 Thread Jim Giner
The manual notes some of your concerns - especially the lack of a need to do a 'seeding' and (since 5.2.1) the presence of a new algorithm that generates a unique sequence regardless if the 'seed' is repeated. Furthermore, since there is no need to do a seed, I would guess that each call to the

Re: [PHP] passing variables to php script

2012-01-12 Thread Matijn Woudt
On Thu, Jan 12, 2012 at 7:51 PM, David Savage wrote: > Installed apache onto a win2K server, and have the html file & php file in > the same folder (Q:\ASTERISK\) on the Q: drive (which is just another drive > in this same server).  I opened the html file using IE 6.0.   What I'm > thinking is

RE: [PHP] passing variables to php script

2012-01-12 Thread David Savage
Installed apache onto a win2K server, and have the html file & php file in the same folder (Q:\ASTERISK\) on the Q: drive (which is just another drive in this same server). I opened the html file using IE 6.0. What I'm thinking is there may be an issue with some setting on the web server. Th

[PHP] srand questions

2012-01-12 Thread Matthew D. Pagel
Hi all, I have a few questions about the srand (or mt_) function for directed seeding. I'm assuming if I do a targeting seeding with a particular value, I'll get the same sequence of values no matter how many times I run the page (assuming it's on the same OS and php version). Of course, if

Re: [PHP] Re: http_referer. what's wrong with that?

2012-01-12 Thread Stuart Dallas
On 12 Jan 2012, at 14:10, Jonesy wrote: > On Thu, 12 Jan 2012 17:11:25 +1100, Ross McKay wrote: >> On Wed, 11 Jan 2012 21:27:58 -0800, Haluk Karamete wrote: >> >>> [...] >>> Notice: Undefined index: HTTP_REFERER in >>> D:\Hosting\5291100\html\blueprint\bp_library.php on line 16 >>> die; >>> [...]

[PHP] Re: http_referer. what's wrong with that?

2012-01-12 Thread Jonesy
On Thu, 12 Jan 2012 17:11:25 +1100, Ross McKay wrote: > On Wed, 11 Jan 2012 21:27:58 -0800, Haluk Karamete wrote: > >>[...] >>Notice: Undefined index: HTTP_REFERER in >>D:\Hosting\5291100\html\blueprint\bp_library.php on line 16 >>die; >>[...] >>But I'm still curious, what configuration am I missin

Re: [PHP] reporting errors when $ sign is missing in front of a variable

2012-01-12 Thread Mihai Anghel
Also, you get the output "my_var" because if you say echo my_var PHP looks for a constant my_var and if it doesn't find one it just assumes you want the name of the constant.Look in the manual page for constants for more details about how they work http://php.net/manual/en/language.constants.php O