You do not need to access $DB as a global variable
Since $db_database is a property of search_helper, you can initialize it by
passing a value via the constructor like this
class search_helper extends AjaxACApplication
{
protected $db_database;
public function __construct($database_nam
On Sun, Nov 1, 2009 at 6:46 PM, Larry Garfield wrote:
> On Sunday 01 November 2009 2:50:55 pm Daniel Kolbo wrote:
> > Hello,
> >
> > Is there a way to see what objects and functions a script
> > loaded/required/used?
> >
> > I could recursively loop through the globals, but if objects were unset,
On Sunday 01 November 2009 2:50:55 pm Daniel Kolbo wrote:
> Hello,
>
> Is there a way to see what objects and functions a script
> loaded/required/used?
>
> I could recursively loop through the globals, but if objects were unset,
> then i may miss some.
>
> I could make a 'tracking' object and ever
On Sun, Nov 1, 2009 at 9:50 PM, Daniel Kolbo wrote:
> Hello,
>
> Is there a way to see what objects and functions a script
> loaded/required/used?
>
I don't think it's possible to that in PHP code.
>
> I could recursively loop through the globals, but if objects were unset,
> then i may miss som
On Mon, February 18, 2008 2:25 pm, nihilism machine wrote:
> if i declare an instance of a class in the top of my php file, then
> have html, then later on user $myClassInstance->myMethod(); --
> myMethod() does not execute, only when i have the instantiation of the
> class right before the call to
Nick Stinemates wrote:
> Shawn McKenzie wrote:
>>> What part of my example was unclear?
>>>
>>>
>> All of it, since I posted just a couple minutes after you and I hadn't
>> seen your post yet.
>>
>>
> I'm sorry, I thought were were responding WHAT?!? to me.
>
> I'm going to blame thunderbi
Shawn McKenzie wrote:
>> What part of my example was unclear?
>>
>>
> All of it, since I posted just a couple minutes after you and I hadn't
> seen your post yet.
>
>
I'm sorry, I thought were were responding WHAT?!? to me.
I'm going to blame thunderbird for looking like you responded to m
Nick Stinemates wrote:
> Shawn McKenzie wrote:
>> Jay Blanchard wrote:
>>
>>> [snip]
>>> if i declare an instance of a class in the top of my php file, then
>>> have html, then later on user $myClassInstance->myMethod(); --
>>> myMethod() does not execute, only when i have the instantiation
[snip]
> http://www.php.net/flush
Huh, what?!?! to both of you:
[/snip]
My bad...I had a total brain fart and 'combined' some concepts that I
was speaking to someone about off-list.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Shawn McKenzie wrote:
> Jay Blanchard wrote:
>
>> [snip]
>> if i declare an instance of a class in the top of my php file, then
>> have html, then later on user $myClassInstance->myMethod(); --
>> myMethod() does not execute, only when i have the instantiation of the
>> class right before
Jay Blanchard wrote:
> [snip]
> if i declare an instance of a class in the top of my php file, then
> have html, then later on user $myClassInstance->myMethod(); --
> myMethod() does not execute, only when i have the instantiation of the
> class right before the call to the method does it wor
nihilism machine wrote:
if i declare an instance of a class in the top of my php file, then have
html, then later on user $myClassInstance->myMethod(); -- myMethod()
does not execute, only when i have the instantiation of the class right
before the call to the method does it work. any ideas?
Jay Blanchard wrote:
> [snip]
> if i declare an instance of a class in the top of my php file, then
> have html, then later on user $myClassInstance->myMethod(); --
> myMethod() does not execute, only when i have the instantiation of the
> class right before the call to the method does it wor
[snip]
if i declare an instance of a class in the top of my php file, then
have html, then later on user $myClassInstance->myMethod(); --
myMethod() does not execute, only when i have the instantiation of the
class right before the call to the method does it work. any ideas?
[/snip]
You are
On 10/15/07, Larry Garfield <[EMAIL PROTECTED]> wrote:
>
> On Monday 15 October 2007, Nathan Nobbe wrote:
> > On 10/15/07, tedd <[EMAIL PROTECTED]> wrote:
> > > I understand the class concept. But, I am not familiar with autoload.
> > >
> > > Stut also made mention of that, so I shall investigate p
On Monday 15 October 2007, Nathan Nobbe wrote:
> On 10/15/07, tedd <[EMAIL PROTECTED]> wrote:
> > I understand the class concept. But, I am not familiar with autoload.
> >
> > Stut also made mention of that, so I shall investigate post haste.
>
> __autoload is pretty tight; but if you dont want to
On 10/15/07, tedd <[EMAIL PROTECTED]> wrote:
>
> I understand the class concept. But, I am not familiar with autoload.
>
> Stut also made mention of that, so I shall investigate post haste.
__autoload is pretty tight; but if you dont want to have all your class
files in the same
directory, i sugg
At 5:42 AM -0500 10/15/07, Jay Blanchard wrote:
[snip]
With a class you can inherit all of the base class functionality
into a new customer type. You do not have to break open the base
class to add a case, you just have to create an extension class.
Documentation is unique to each class.
No ma
On 10/15/07, Jay Blanchard <[EMAIL PROTECTED]> wrote:
>
> [snip]
> >With a class you can inherit all of the base class functionality
> >into a new customer type. You do not have to break open the base
> >class to add a case, you just have to create an extension class.
> >Documentation is unique to
[snip]
>With a class you can inherit all of the base class functionality
>into a new customer type. You do not have to break open the base
>class to add a case, you just have to create an extension class.
>Documentation is unique to each class.
No matter what, you have to break something open t
""Jay Blanchard"" <[EMAIL PROTECTED]> schrieb im Newsbeitrag
news:[EMAIL PROTECTED]
[snip]
First of all what you call "normal" is procedural or functional
programming. There is nothing wrong with doing things this way and may
be
especially quick and efficient when doing basic web sites and
At 9:03 AM -0500 10/12/07, Jay Blanchard wrote:
tedd said:
In either case, I still have to write more code to accommodate
scaling. And, if I have more customer types, then it's a simple
matter to add more customer functions and addition case statements to
the initial customer function. I don't s
At 2:44 PM +0100 10/12/07, Stut wrote:
You can limit the need to add more code like so...
function customer($whatWas, $customertype, $whatAdditional)
{
/* do "what was" (i.e., common to all) */
/* then do what's additional unique to type */
$func = strtolower($customertype).'Customer
[snip]
> First of all what you call "normal" is procedural or functional
> programming. There is nothing wrong with doing things this way and may
be
> especially quick and efficient when doing basic web sites and
applications.
> Document well and you will have no problem maintaining your code.
One
On 10/12/07, Jay Blanchard <[EMAIL PROTECTED]> wrote:
>
> No doubt. (are you by chance continuing the other argument, re:
> interfaces?), but you have to break open the original tested function, add
> code to it, test it, etc. Every time you add a new case you have to break
> open the existing func
[snip]
Yes, but I could do that procedurally from within the customer
function by simply adding a customer type (needed regardless) and
using a switch to direct and collect the additional data needed.
In either case, I still have to write more code to accommodate
scaling. And, if I have
tedd wrote:
function customer($whatWas, $customertype, $whatAdditional)
{
/* do "what was" (i.e., common to all) */
/* then do what's additional unique to type */
switch(1)
{
case $customertype =='Commercial':
commercialCustomer($whatAdditional);
break;
..
At 7:36 AM -0500 10/11/07, Jay Blanchard wrote:
[snip]
okay, this is really (!) embarassing, but I have to ask:
Why would I want to use classes in PHP?
I have been using PHP for years now and writing the "normal" functions all
the time. I have never even bothered working with classes, but now I
On 10/12/07, Larry Garfield <[EMAIL PROTECTED]> wrote:
>
> On Thursday 11 October 2007, Jay Blanchard wrote:
> > [snip]
> > okay, this is really (!) embarassing, but I have to ask:
> >
> > Why would I want to use classes in PHP?
> >
> > I have been using PHP for years now and writing the "normal" f
On Thursday 11 October 2007, Jay Blanchard wrote:
> [snip]
> okay, this is really (!) embarassing, but I have to ask:
>
> Why would I want to use classes in PHP?
>
> I have been using PHP for years now and writing the "normal" functions all
> the time. I have never even bothered working with classe
[snip]
Not trying to hijack the thread... Hopefully this is related enough,
if not I apologize. Would a good use of a class be to write a generic
database connection script? and then feed in the different variables,
such as customer login, database, stuff like that?
something like class DBCo
On Thu, 2007-10-11 at 07:36 -0500, Jay Blanchard wrote:
> [snip]
> okay, this is really (!) embarassing, but I have to ask:
>
> Why would I want to use classes in PHP?
>
> I have been using PHP for years now and writing the "normal" functions all
> the time. I have never even bothered working wi
On Oct 11, 2007, at 8:36 AM, Jay Blanchard wrote:
[snip]
okay, this is really (!) embarassing, but I have to ask:
Why would I want to use classes in PHP?
I have been using PHP for years now and writing the "normal"
functions all
the time. I have never even bothered working with classes, but
[snip]
okay, this is really (!) embarassing, but I have to ask:
Why would I want to use classes in PHP?
I have been using PHP for years now and writing the "normal" functions all
the time. I have never even bothered working with classes, but now I would
love to know what makes the classes so sp
On 10/1/07, Merlin <[EMAIL PROTECTED]> wrote:
>
> Hello everybody,
>
> thank you for all your answers. I am sorry but I just realized that
> there is an huge difference between PHP5 and PHP4 considering OOP.
> Unfortunatelly I am still running PHP4.x and cant change this over
> night. However I sti
That's incorrectly syntactically. Won't run.
Ok, let's write some code to show how this can be done:
class SearchHelper extends AjaxACApplication {
private $dbh;
public function __construct() {
$this->dbh = $GLOBALS['dbh'];
}
}
Better yet, pass the database host in the cons
On 9/30/07, 潘志彬 <[EMAIL PROTECTED]> wrote:
>
> $dbh = 'test';
>
> class search_helper extends AjaxACApplication
> {
> /**
> * Database connection details
> */
>
>// announce global variable before use it
>global $dbh;
>
> $db_hostname = $dbh;
$dbh = 'test';
class search_helper extends AjaxACApplication
{
/**
* Database connection details
*/
// announce global variable before use it
global $dbh;
$db_hostname = $dbh;
...
Regards,
Ryu
2007/9/29, Merlin <[EMAIL PROTECTED]>:
Merlin,
if you are using php5 the var keyword is no longer valid; that was used in
classes in php4.
if you want to structure your classes properly you need to study PPP
(public, private, protected) access modifiers.
typically member variables are declared to be private or protected, if there
will
Refer to the global on the constructor.
Anyway, using a global like that is not a good practice. Just pass the
variable to the constructor.
2007/9/29, Merlin <[EMAIL PROTECTED]>:
>
> Hi there,
>
> I am new to PHP classes and I do want to access a variable outside the
> class, but somehow that doe
Martin Alterisio wrote:
> Forgot to mention that calling a non-static function this way should
> generate an E_STRICT warning.
and IIRC it will eventually be made a fatal error in php6, somebody
please correct me if I'm wrong!
>
> 2007/1/16, Martin Alterisio <[EMAIL PROTECTED]>:
>>
>> Backward c
Forgot to mention that calling a non-statical function this way should
generate an E_STRICT warning.
2007/1/16, Martin Alterisio <[EMAIL PROTECTED]>:
Backward compatibility with PHP4, where member functions couldn't be
declared as static. Any member function could be called statically providing
Backward compatibility with PHP4, where member functions couldn't be
declared as static. Any member function could be called statically providing
a static context instead of an object instance.
2007/1/16, Cheseldine, D. L. <[EMAIL PROTECTED]>:
Hi
I'm stuck on The Basics page of the php5 Object
[snip]
http://uk.php.net/manual/en/language.oop5.basic.php
The top example has the code:
A::foo();
even though foo is not declared static in its class. How does it get
called statically without being declared static?
[/snip]
foo() is a function and would not be static, it can be public (defau
On 3/7/06, Wolf <[EMAIL PROTECTED]> wrote:
> I'm looking for a couple of good books or online sources where I can get
> a lot better grasp of Classes and OOP programming in general. Mostly I
> use PHP so that is the best option.
>
> Thanks,
> Robert
>
PHP5 - Objects, Patterns, and Best Practices
PHP5 Objects, Patterns and Practice
1590593804 - Matt Zandstra - Apress
This is a good way to get a good grasp of object-oriented programming
covers the basics of uml as well as using decent examples to explain
the use of objective programming (unlike all the web sites out there
that i tried to
Jason Gerfen wrote:
I am attempting to work up a class and because I am unfamiliar with some
of the code flow I am only able to get a return value of 'object'. How
can I pull the data out of a class?
which data? It doesn't seem as if anyone knows what your trying to do.
(try to explain it aga
I took a look at a lot of books at Barnes and Noble and this I thought was
the best intro to classes. I think it does a good job of letting you know
both how to do things in HP4 and 5.
Professional PHP 5
Publisher: Wrox
-Original Message-
From: Michael Hulse [mailto:[EMAIL PROTECTED]
Se
On Dec 6, 2005, at 6:39 PM, Chris Shiflett wrote:
Adam Trachtenberg's Upgrading to PHP 5 (O'Reilly) is a good book. It
covers all of the new features in PHP 5 (so it's not just OOP, sorry),
but the chapter on objects is excellent.
Hi Chris, thanks for the quick response. :) That book sounds g
Michael Hulse wrote:
Any books that you could suggest that specifically address just
classes/objects?
Adam Trachtenberg's Upgrading to PHP 5 (O'Reilly) is a good book. It
covers all of the new features in PHP 5 (so it's not just OOP, sorry),
but the chapter on objects is excellent.
Chris
-
On 11/4/05, Unknown Unknown <[EMAIL PROTECTED]> wrote:
> Hi everyone, i have some code that proccesses a login form. i have an object
> $DB which works only in SOME areas, this is the code:
>
[...]
> $DB="membersp";
> $SQL="SELECT ID FROM membersonline WHERE ID='$ID' ";
> $DB->Query($SQL);
[...]
>
On Thu, 2005-11-03 at 18:37 -0500, Unknown Unknown wrote:
> Hi everyone, i have some code that proccesses a login form. i have an object
> $DB which works only in SOME areas, this is the code:
>
> require_once("Include.php");
> global $DB;
There is no need to global $DB here. You are already in
STFW
>-Original Message-
>From: Unknown Unknown [mailto:[EMAIL PROTECTED]
>Sent: 03 November 2005 00:05
>To: Jasper Bryant-Greene
>Cc: php-general@lists.php.net
>Subject: Re: [PHP] Classes and Functions
>
>
>Oh thanks agai
Robert Cummings wrote:
On Thu, 2005-11-03 at 12:15, Jasper Bryant-Greene wrote:
On Wed, 2005-11-02 at 19:05 -0500, Unknown Unknown wrote:
Oh thanks again
and what does RTFM mean?
Read The [insert your favourite word beginning with F here] Manual.
"Fondu"?? *licks lips*
you missed an '
On Thu, 2005-11-03 at 12:15, Jasper Bryant-Greene wrote:
> On Wed, 2005-11-02 at 19:05 -0500, Unknown Unknown wrote:
> > Oh thanks again
> > and what does RTFM mean?
>
> Read The [insert your favourite word beginning with F here] Manual.
"Fondu"?? *licks lips*
Cheers,
Rob.
--
.
On Wed, 2005-11-02 at 19:05 -0500, Unknown Unknown wrote:
> Oh thanks again
> and what does RTFM mean?
Read The [insert your favourite word beginning with F here] Manual.
--
Jasper Bryant-Greene
General Manager
Album Limited
e: [EMAIL PROTECTED]
w: http://www.album.co.nz/
b: http://jbg.name/
p:
Oh thanks again
and what does RTFM mean?
A thanks, i tried that before didn't seem to work, now it works
Thanks again!
On 11/2/05, Unknown Unknown <[EMAIL PROTECTED]> wrote:
>
> Hi everybody i have a class that i reference with:
> $DB= new DBInterface;
> outside a function it works fine, but using $DB inside a function changes
> the data type i think... i get an error saying i'm using a method on a
> non-object...
On Wed, 2005-11-02 at 18:56 -0500, Unknown Unknown wrote:
> Hi everybody i have a class that i reference with:
> $DB= new DBInterface;
> outside a function it works fine, but using $DB inside a function changes
> the data type i think... i get an error saying i'm using a method on a
> non-object...
It's really a matter of comfort level and opinion. There can be
strong arguments either way. Using just functions will be faster,
although the speed difference may be minimal and not noticeable.
Using just functions can be easier and quicker to develop, especially
for small projects.
But,
Jochem Maas wrote:
also I believe print_r() and var_dump() have a few odditities regarding
display of recursion with regard to objects... internals mailinglist
archive
might tell you more on that.
I think I have the answer, when I pass a var to print_r it isn't passed
by reference, so there will
Evert|Rooftop Solutions wrote:
Hi,
I have this piece of code:
class test1 {
var
$data = 'hi',
$node = false;
function test1() {
$this->node =& new test2($this);
}
}
class test2 {
var
$data = 'yoyo',
You know... we talked about this several times before. Please search
the archives for the PHP list's answers.
Hint: STFA tutorial class object
--
Teach a man to fish...
NEW? | http://www.catb.org/~esr/faqs/smart-questions.html
STFA | http://marc.theaimsgroup.com/?l=php-general&w=2
STFM | http:/
On Mon, 14 Mar 2005 23:30:51 +, Alister Bulman <[EMAIL PROTECTED]> wrote:
> On Mon, 14 Mar 2005 19:14:37 +0530, Zareef Ahmed <[EMAIL PROTECTED]> wrote:
> > Hi All,
> >
> > I have a function to load the classes and return the object.
> >
> > function LoadClass($ClassName)
> > {
> > require_once
On Mon, 14 Mar 2005 09:03:00 -0800 (PST), Richard Lynch <[EMAIL PROTECTED]>
wrote:
>
> > Hi All,
> >
> > I have a function to load the classes and return the object.
> >
> > function LoadClass($ClassName)
> > {
> > require_once("Class.$ClassName.inc");
> > return new $ClassName();
> > }
> >
> >
> Hi All,
>
> I have a function to load the classes and return the object.
>
> function LoadClass($ClassName)
> {
> require_once("Class.$ClassName.inc");
> return new $ClassName();
> }
>
> Its working fine.
>
> But Zend Studio's Code completion is not working for this type of
> object, Any hints?
Dmitry wrote:
> Greetings.
>
> If i run this code (php5):
> --
> class a {
> function say() { echo "A"; }
> function run() { $this->say(); }
> }
> class b extends a {
//> function say() { echo "B"; }
function say() { parent::say(); echo "B";}
> func
had to better myself...
Jochem Maas wrote:
Dmitry wrote:
Greetings.
If i run this code (php5):
--
class a {
function say() { echo "A"; }
function run() { $this->say(); }
}
class b extends a {
function say() { echo "B"; }
function run() { parent::run(); }
Dmitry wrote:
Greetings.
If i run this code (php5):
--
class a {
function say() { echo "A"; }
function run() { $this->say(); }
}
class b extends a {
function say() { echo "B"; }
function run() { parent::run(); }
}
$obj = new b;
$obj->run();
--
the run function in b overrides the run function in a, thats why it
echo's "B"
On Fri, 2005-01-21 at 18:37, Dmitry wrote:
> Greetings.
>
> If i run this code (php5):
> --
> class a {
> function say() { echo "A"; }
> function run() { $this->say(); }
> }
>
your question is hard to answer. The difference between classes and
functions is like the difference between a toolbox, and a spanner. A
class is a container, that contains functions, and variables, or as
they are called in Object-Oriented-Speak(methods, and properties).
A method is a function tha
On Sat, 2004-12-11 at 13:03 -0500, R. Van Tassel wrote:
> Can someone give me a distinction between the two and when to use / not use
> them?
>
>
>
> I want to thank everyone who replied about my"For" loop question. All the
> answers were VERY helpful! Thanks very much.
You might want to pick
Josh Howe wrote:
>
> Hi all,
>
> If I have the following code:
>
> $some_global_variable;
>
> Class foo {
>
> Function test() {
> set_global();
> echo $some_global_variable;
> }
>
> Function set_global () {
> $some_global_variable = "abcd";
> echo $some_g
Thank you all for your responses. It was indeed an error elsewhere in my
code.
Daniel Watrous
- Original Message -
From: "Matthew Fonda" <[EMAIL PROTECTED]>
To: "Curt Zirzow" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Tuesday, Septem
Works fine for me. It still works if you add methods or properties to
Foo as well, I'm not sure why it wouldn't work for you, possibly you
have another error along the lines somewhere. I am on PHP 5.0.1 BTW
On Tue, 2004-09-28 at 19:42, Curt Zirzow wrote:
> * Thus wrote Daniel Watrous:
> > Hello
* Thus wrote Daniel Watrous:
> Hello all,
>
> I have a class Foo. In PHP4 I could create an instance of Foo in the following
> manner:
> $className = "Foo";
> $fooInstance = new $className;
>
> This would yield the same result as:
> $fooInstance = new Foo;
Can you provide the definition of you
* Thus wrote Maciek Ruckgaber Bielecki:
> you are just missing the (); it wont work either in php4 or php5 that
> way.
>
>
> $className = "Foo";
> $fooInstance = new $className();
$a = new Foo;
Is perfectly valid.
Curt
--
The above comments may offend you. flame at will.
--
PHP General
you are just missing the (); it wont work either in php4 or php5 that
way.
$className = "Foo";
$fooInstance = new $className();
Cheers
On Tue, Sep 28, 2004 at 01:46:27PM -0600, Daniel Watrous wrote:
> Hello all,
>
> I have a class Foo. In PHP4 I could create an instance of Foo in the follow
On Tue, 28 Sep 2004 13:46:27 -0600, Daniel Watrous
<[EMAIL PROTECTED]> wrote:
> In my efforts to port this over to PHP5 I am having trouble. Not only do I not get
> back an
> instance of my Foo class, but the script execution stops entirely without so much as
> a
> warning.
My first suggesti
On Thu, 29 Jul 2004 14:41:57 +0200, Oliver Hitz <[EMAIL PROTECTED]> wrote:
> Hi all,
>
> I have stumbled across something odd related to classes, instances and
> NULL in PHP 4. Apparently, an instance of a class that doesn't contain
> any variables is always equal to NULL.
>
> class MyClass {
>
Hi,
Friday, April 23, 2004, 1:00:34 PM, you wrote:
DN> I'm having a problem using classes. The problem stemed from
DN> using arrays to store a bunch of users and their usage times.
DN> I have an object with two members, $name and $onlineSecs. No
DN> matter how hard I try...$name always gets mod
Hi
Am So, 2004-03-14 um 03.55 schrieb Elliot J. Balanza:
> Anybody knows a good on line tutorial for objects & classes on PHP.
Sure! Google is your friend or
http://www.phppatterns.com/index.php/link/category/1/ for example.
--
Regards
Marco
--
PHP General Mailing List (http://www.php.net/)
<[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> Although i dont code for pear standards, i must recommend learning the
pear
> code, its how i taught myself classes.
I concur.
It is how I am learning this stuff.
That and my stupid questions to this list (see previous posts just
yes
Although i dont code for pear standards, i must recommend learning the pear
code, its how i taught myself classes.
> Hi,
>
> I'm want to master the art of programming in Classes and worked through
> some elementary tutorials.
>
> Are there perhaps a bit more advanced tutorials than Devshed?
>
> Th
> Hi,
>
> am Wednesday 23 July 2003 11:48 schrieb Joel Rees:
>
> > (You know that $accesses->count and $accesses->resetCounter() are at
> > least declared in the same class declaration. $accesses_count and
> > accesses_resetCounter() could be declared in entirely unrelated include
> > files for e
>> Execution speed isn't all that matters. In fact, speed is not the point
>> at all.
>
>Then you must be an PHPNuke or Typo3-programmer, beeing lucky to get at
>least 1 request per second ;). Don't take it hard, but If you had ever
>been in computer-science [school|college|...] you would know tha
Hi,
am Wednesday 23 July 2003 11:48 schrieb Joel Rees:
> (You know that $accesses->count and $accesses->resetCounter() are at
> least declared in the same class declaration. $accesses_count and
> accesses_resetCounter() could be declared in entirely unrelated include
> files for entirely differen
> Say I have a database class with all kinds of functions for connection,
> data manipulation, errors, etc:
>
> $db = new db_sql;
> $db->connect();
> $db->do_this();
> $db->do_that();
>
> How would that be different from an include file with a bunch of functions
> doing the same thing?
As far
Whether it's the right move or not, I've put off my learning of PHP
classes and OOP methods until PHP5.x, so I guess the time in near :)
However, *especially* if you're the only programmer on a project, you
can take the ideas & benefits behind OOP (for me, having clear, clean
code that can be r
Thanks to all for your input.
Regards, Andu Novac
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Hi,
Saturday, July 19, 2003, 7:08:55 AM, you wrote:
A> This may show my ignorance or my refusal to take for granted something I
A> don't fully understand but I have a hard time figuring out the advantage of
A> using classes as opposed to just functions. I am certainly new to php and
A> at first
Andu <[EMAIL PROTECTED]> wrote:
>
>
> --On Friday, July 18, 2003 14:28:02 -0700 Chris Shiflett <[EMAIL PROTECTED]>
> wrote:
>
> >--- Andu <[EMAIL PROTECTED]> wrote:
> >>This may show my ignorance or my refusal to take for granted
> >>something I don't fully understand but I have a hard time
> >
On Fri, 2003-07-18 at 18:19, Andu wrote:
>
> Say I have a database class with all kinds of functions for connection,
> data manipulation, errors, etc:
>
> $db = new db_sql;
> $db->connect();
> $db->do_this();
> $db->do_that();
>
> How would that be different from an include file with a bunch of
--On Friday, July 18, 2003 14:28:02 -0700 Chris Shiflett <[EMAIL PROTECTED]>
wrote:
--- Andu <[EMAIL PROTECTED]> wrote:
This may show my ignorance or my refusal to take for granted
something I don't fully understand but I have a hard time
figuring out the advantage of using classes as opposed t
Chris Shiflett wrote:
> --- Andu <[EMAIL PROTECTED]> wrote:
> > This may show my ignorance or my refusal to take for granted
> > something I don't fully understand but I have a hard time
> > figuring out the advantage of using classes as opposed to just
> > functions.
>
> They are entirely diffe
--- Andu <[EMAIL PROTECTED]> wrote:
> This may show my ignorance or my refusal to take for granted
> something I don't fully understand but I have a hard time
> figuring out the advantage of using classes as opposed to just
> functions.
They are entirely different. While OO fans will find my over-
On Fri, 2003-06-27 at 03:09, Dave Alger wrote:
> Hiya,
>
> It would be useful for me to be able to use a class within another class and
> I don't know if that's permissable in PHP.
Hi there!
It is indeed possible. However, that's not the problem here. The problem
is that class attribute initiali
Don,
Are you using phpmailer of http://phpmailer.sourceforge.net/ ???
Looks like:
require("class.phpmailer.php");
this is not properly configured! Please check if the path is going alright..
Regards,
Frank
- Original Message -
From: "Don" <[EMAIL PROTECTED]>
To: "php list" <[EMAIL PR
Here is an excellent article describing
classes/objects - what they are and are not.
http://phpmag.net/itr/online_artikel/psecom,id,284,nodeid,114.html
olinux
> > Can someone please explain to me when is a class
> useful over a set of
> > functions?
__
Do you Y
1 - 100 of 157 matches
Mail list logo