php-general Digest 4 Sep 2013 09:21:22 -0000 Issue 8355

2013-09-04 Thread php-general-digest-help
php-general Digest 4 Sep 2013 09:21:22 - Issue 8355 Topics (messages 322028 through 322033): Re: refernces, arrays, and why does it take up so much memory? [SOLVED] 322028 by: Daevid Vincent 322029 by: Stuart Dallas 322030 by: Daevid Vincent 322031 by: Daevid

php-general Digest 4 Sep 2013 22:25:25 -0000 Issue 8356

2013-09-04 Thread php-general-digest-help
php-general Digest 4 Sep 2013 22:25:25 - Issue 8356 Topics (messages 322034 through 322038): Static utility class? 322034 by: Micky Hulse 322035 by: Stephen 322036 by: David Harkness 322037 by: Micky Hulse message to user after complete POST 322038

Re: [PHP] refernces, arrays, and why does it take up so much memory? [SOLVED]

2013-09-04 Thread Stuart Dallas
On 4 Sep 2013, at 00:03, Daevid Vincent dae...@daevid.com wrote: -Original Message- From: Stuart Dallas [mailto:stu...@3ft9.com] Sent: Tuesday, September 03, 2013 2:37 PM To: Daevid Vincent Cc: php-general@lists.php.net; 'Jim Giner' Subject: Re: [PHP] refernces, arrays, and why does

[PHP] Static utility class?

2013-09-04 Thread Micky Hulse
Hi all! Example code: https://gist.github.com/mhulse/6441525 Goal: I want to have a utility class that contain utility methods which should have the option of being called multiple times on a page. I think my main goal is to avoid having to new things ... I don't really need to create an

Re: [PHP] Static utility class?

2013-09-04 Thread Stephen
On 13-09-04 03:25 PM, Micky Hulse wrote: I want to have a utility class that contain utility methods which should have the option of being called multiple times on a page. This sounds simply like a library of functions that are implemented using objects. You can use the standard require_once

Re: [PHP] Static utility class?

2013-09-04 Thread David Harkness
On Wed, Sep 4, 2013 at 12:25 PM, Micky Hulse mickyhulse.li...@gmail.comwrote: I want to have a utility class that contain utility methods which should have the option of being called multiple times on a page. ... To put it another way, is there any reason why I would not want to use the

Re: [PHP] Static utility class?

2013-09-04 Thread Micky Hulse
Thank you so much for the quick and very informative/educational replies Stephen and David, I really appreciate it! :) On Wed, Sep 4, 2013 at 12:36 PM, Stephen stephe...@rogers.com wrote: This sounds simply like a library of functions that are implemented using objects. Instantiate your static

[PHP] message to user after complete POST

2013-09-04 Thread iccsi
I have a POST form and action itself like following form name=MyForm id=MyForm method=POST action=index.php /form I want to show success message when POST complete or error message if there is any. I would like to know are there any property or global variable I can check to show message to

Re: [PHP] Static utility class?

2013-09-04 Thread Stephen
On 13-09-04 05:09 PM, Micky Hulse wrote: Thank you so much for the quick and very informative/educational replies Stephen and David, I really appreciate it! :) On Wed, Sep 4, 2013 at 12:36 PM, Stephen stephe...@rogers.com wrote: This sounds simply like a library of functions that are

Re: [PHP] Static utility class?

2013-09-04 Thread Micky Hulse
Thanks Stephen! I really appreciate the help! :) In my PHP ventures over the years, I haven't made much use of static variables/methods/properties ... I was thinking they might be useful for this one bit of code, but based on your feedback (and David's) I think I'll be heading down a different

Re: [PHP] message to user after complete POST

2013-09-04 Thread Rodrigo Santos
hey, if you are just trying to give the user a feedback about the information sent, there is a Global variable for this, and it's the $_POST. When you receive the information on the script you called on the Action atribute of the form, via the $_POST global variable, you will test the information

Re: [PHP] message to user after complete POST

2013-09-04 Thread iccsi
Thanks a million for the information and help, yes, I will use jQuery to have my success function call in jQuery.ajax. Thanks again, Regards, Iccsi, Rodrigo Santos wrote in message news:caombckqonakxoc4tnhcpn2ycdpy8503xttc7sosjywhtd5x...@mail.gmail.com... hey, if you are just trying to

Re: [PHP] Static utility class?

2013-09-04 Thread Rodrigo Santos
Hi, first, sorry for the bad English. Yes, at least, as far as I know, this is the perfect way to do what you want to do. Think like this: when you instanciate a class, you are allocating memory. If you don't need any information stored, then you don't need to allocate memory, right? So, it's is

Re: [PHP] Static utility class?

2013-09-04 Thread Micky Hulse
Hi Rodrigo, thanks for the help, I really appreciate it! On Wed, Sep 4, 2013 at 5:55 PM, Rodrigo Santos rodrigos.santo...@gmail.com wrote: Hi, first, sorry for the bad English. Not bad at all! Very clear and well written reply (heck, it's better than my native English writing), so thank you! :)