Re: [PHP] Something I don't understand about PHP classes

2009-05-09 Thread chetan rane
Hi you can use the following code On Sat, May 9, 2009 at 10:16 PM, Robert Cummings wrote: > On Sat, 2009-05-09 at 18:35 +0200, Cesco wrote: > > Ok, I suppose that this should be a very simple problem and probably > > the answer is obvious, but I really can't understand how the classes > > and th

[PHP] Trying to create a colortable - what am I missing here?

2009-05-09 Thread דניאל דנון
I've tried to make a color table, but I am missing something. not in the color-table-code itself, but in somewhere else... I just can't find... error_reporting is E_ALL, running it on my local server, the script has 512MB to spend, no errors occurs - just something, is wrong. (4072 * 4072 ~= 255*

Re: [PHP] Session data files

2009-05-09 Thread phphelp -- kbk
Thanks, Tom - - On May 8, 2009, at 12:37 PM, Tom Worster wrote: On 5/8/09 11:09 AM, "phphelp -- kbk" wrote: Just something I'm curious about: When I run PHP on my development box (W2K), I just get one session file per connection which gets deleted (usually) after the session expires. When

Re: [PHP] php-general@lists.php.net, Tim-Hinnerk Heuer has invited you to open a Google mail account

2009-05-09 Thread Lenin
LOL good points indeed! But I dont use other Google products that much. But yes I'm helping google in some way. One great satisfaction I have is I use Ubuntu with FireFox. :)

Re: [PHP] php-general@lists.php.net, Tim-Hinnerk Heuer has invited you to open a Google mail account

2009-05-09 Thread דניאל דנון
That's how you help information-monster-privacy-killing-companies to gain more control... You use GMail? ever visited blogspot? search on Google? Visit half of the leading sites of the world (since they have Google Analytics) or visit the other half that have Google Adsense or both of them? Maybe

Re: [PHP] intval

2009-05-09 Thread kranthi
if that is the case & should appear before all the other variables as well and. is giving me array(5) { [0]=> int(1) [1]=> int(100) [2]=> float(100.1) [3]=> float(100.123) [4]=> string(1) "a" } ny idea y this difference arises? -- PHP General Mailing List (http://www.php.net/) To un

Re: [PHP] Something I don't understand about PHP classes

2009-05-09 Thread Robert Cummings
On Sat, 2009-05-09 at 18:35 +0200, Cesco wrote: > Ok, I suppose that this should be a very simple problem and probably > the answer is obvious, but I really can't understand how the classes > and the rest of the stuff works in PHP... > > Let's suppose that we have this piece of code: > > >

Re: [PHP] intval

2009-05-09 Thread Robert Cummings
On Sat, 2009-05-09 at 21:23 +0530, kranthi wrote: > k i ended up with this code > > > $_POST = array( '1', '100', '100.1', '100.123', 'a'); > > foreach( $_POST as &$value ) > { > if(is_numeric($value)) { > $value = $value + 0; > } > } > var_dump($_POST); > > ?> >

[PHP] Something I don't understand about PHP classes

2009-05-09 Thread Cesco
Ok, I suppose that this should be a very simple problem and probably the answer is obvious, but I really can't understand how the classes and the rest of the stuff works in PHP... Let's suppose that we have this piece of code: I have put an infinite loop in the class constructor just to

Re: [PHP] intval

2009-05-09 Thread kranthi
k i ended up with this code its giving me array(5) { [0]=> int(1) [1]=> int(100) [2]=> float(100.1) [3]=> float(100.123) [4]=> &string(1) "a" } what does &string mean ?? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] intval

2009-05-09 Thread Robert Cummings
On Sat, 2009-05-09 at 20:02 +0530, kranthi wrote: > thanks for the reply... just happened to see http://php.net/ternary > which explains the above result > > i want to explicitly type cast all the numbers passed via post (by > default they are strings) > is_numeric() is a option, but it will not b

Re: [PHP] intval

2009-05-09 Thread kranthi
thanks for the reply... just happened to see http://php.net/ternary which explains the above result i want to explicitly type cast all the numbers passed via post (by default they are strings) is_numeric() is a option, but it will not be possible to differentiate between int and float. $_POST['mo

Re: [PHP] php-general@lists.php.net, Tim-Hinnerk Heuer has invited you to open a Google mail account

2009-05-09 Thread Lenin
Hahaha quite Hilarious. le...@phpxperts.net is also hosted by Google Apps :P Its the Largest active PHP group in South Asia (originated from Bangladesh). Participated by thousands from many other countries. Keep the humor on! :D

Re: [PHP] intval

2009-05-09 Thread Robert Cummings
On Sat, 2009-05-09 at 18:22 +0530, kranthi wrote: > var_dump($_POST['month'], intval($_POST['month']), $_POST['month'] == > ((int)($_POST['month'])); > var_dump($_POST['month'], intval($_POST['month']), $_POST['month'] == > (intval($_POST['month']))); After I fixed your syntax error this worked fi

[PHP] intval

2009-05-09 Thread kranthi
Hi, var_dump($_POST['month'], intval($_POST['month']), $_POST['month'] == ((int)($_POST['month'])); var_dump($_POST['month'], intval($_POST['month']), $_POST['month'] == (intval($_POST['month']))); is giving me string(3) "Jan" int(0) bool(true) but i m expecting string(3) "Jan" int(0) bool(false)

Re: [PHP] php-general@lists.php.net, Tim-Hinnerk Heuer has invited you to open a Google mail account

2009-05-09 Thread Nathan Rixham
Lenin wrote: Yeah gmail is a nice thing :) The best ever mailing system world has ever seen until now. Because now you can get new LeninMail from phpXperts - it works offline, it works in your fridge, you car, your bath, everywhere conventional mail doesn't work. LeninMail combines all th