Page 2 of 2

Posted: Wed Aug 18, 2004 4:37 pm
by pickle
McGruff wrote:avoid PEAR like the plague
I couldn't agree more. I'm currently using their class to make Excel spreadsheets and it suddenly just stopped. No error or anthing. Heed those words!!!

Posted: Wed Aug 18, 2004 4:48 pm
by andre_c
Just my experience:
every site ( that requires at least some maintenance ) that I wrote without OOP, I have ended up rewriting it using OOP.

Posted: Wed Aug 18, 2004 5:28 pm
by pìsterman
Very usefull response McGruff.

Do you know any good guide about PHP OOP design aspects?

I'm just starting with PHP OOP and need to have this site finished at the end of this year. Do you think that I will be able to do it with basic knowledge about the subject? (at least the basic functions)

Thanks

Posted: Wed Aug 18, 2004 7:44 pm
by McGruff
The phppatterns.com link is a great place to start for design patterns commonly used in php web apps.

Also see http://www.sitepoint.com/forums/showthread.php?t=78687 for a large range of links about advanced php-ing.

Four months is a tight schedule to learn OOP and build a fully-functional site (even assuming you are working full-time on the project). With a deadline to work to I guess you've just got to get something written any way you can and possibly refactor it later.

Posted: Sat Aug 21, 2004 10:18 am
by lazy_yogi
pickle wrote:1) PHP.
   It's got a much wider support base. If you have any problems, it's much easier to get help (just look at this forum).
   It's open source - cheaper to run/upgrade
   I'm not sure, but I think it's more powerful in that it has more built-in, useful functions. It has many tie-ins with other libraries as well.
(Honestly, I don't think anyone here will recommend ASP over PHP - this is a PHP forum after all :) ).
PHP does have a massive user base, unmatched for simple web dev. However, it is just a language, and for speedy development, you would want a framework to go with the language. It takes alot of time to make one yourself - so the advantage of ASP.NET over PHP is that it has the huge framework for rapid development, whereas php has none. The disadvantage of ASP.NET is you have to spend some time learning the framework, whereas you can use php for simple things almost immediately - hence its unmatched popularity.
pickle wrote:5) UML is the devil*.
You make a compelling point.
pickle wrote:6) MySQL is certainly one of the easiest DB's to administer, from what I've worked on.
   Postgres is much more difficult, though that may just be because I don't have as much experience with Postgres.
   I'f you've got the resources for Oracle, I'd be tempted to use it. At the very least, you can put on your resume that you've worked with Oracle. However, I don't really think the power of Oracle is needed for a website - really only for organizational intranets and online stores and the ilk. Regardless of which one you pick, I strongly recommend creating a DB abstraction layer so if you decide to change your mind later, you only have to change one class, not every file that accesses the DB.
MySql is a piece of crap. Only use it if you are making something simple. And even then, use anything else if you have the option. It doesn't support much in terms of functionality. Most obviously it doesnt support foreign keys, and I think it only recently built support for views. It is very much feature-deficient. And on top of that, it's not even free for commercial use. The only advantage I can see for mysql is that if youv'e used it before, you don't have to spend time messing around learning some extra things by switching dbms's. Whether this is reason enough to stick with mysql is questionable.

Postgres is an excellent, very high quality product - and it's completely free, even for commercial use. It's not hard to use, and has alot of support.

MS SQL is also very good, but generally only a windows based product. And it's not cheap.

Oracle is *the* standard for enterprise applications. Though I wouldn't recommend it unless you have used it before - or have someone on board who has.

I would draw a parallel between a lot of common points here. The easy way is not always the best. ASP.NET has many many more features than php, but you must spend more time learning the framework in the beginning. Similarly, OOP saves an emourmous amount of time for maintenance and upgrading of software over proceedural development, but OOP takes ALOT of work to get proficient at it. Similarly again, mysql is very easy to use initially, but is feature deficient. if you take time to learn another db, you will get more functionality and performance out of it. php/mysql/proceedural programming go together, simply because it's easy. However, if you want to develop enterprise applications, you have to make some decisions about how powerful and easy to maintain you want your systems to be. If you are sticking with simple sites, then php/mysql/proceedural is definitley the way to go. But for larger systems, be careful as it just doesnt scale.

Regards,
Eli

Posted: Sat Aug 21, 2004 10:32 am
by feyd
mysql has foreign keys, with an innodb engine'd table..

Posted: Sat Aug 21, 2004 11:37 am
by lazy_yogi
Just checked it out. Looks good. Any idea why that's not the default rather than myisam?
Or even why they bothered having myisam at all?

Posted: Sat Aug 21, 2004 11:43 am
by markl999
InnoDB is slower than MyISAM for small tables, but the speed difference is noticeable only at around 100 queries per second.
MyISAM is also good for tables with vastly more queries than updates.

Posted: Sat Aug 21, 2004 11:43 am
by feyd
no clue... may be able to change it with a global variable setting.. or compiling with a different option than the defaults..