This is topic Web Site Architecture Pondering in forum Books, Films, Food and Culture at Hatrack River Forum.


To visit this topic, use this URL:
http://www.hatrack.com/ubb/main/ultimatebb.php?ubb=get_topic;f=2;t=028672

Posted by Dagonee (Member # 5818) on :
 
I have a web site I'm setting up. I plan to use Mambo for the content manager, and add some gallery and forum software.

When I set up the site, I chose Windows hosting because my ASP experience is considerable, and I needed to write the wedding RSVP application quickly. The same company offers a Linux/Apache hosting service, and for the price difference I can expand my mailboxes' capacity from 10 MB to 100 MB each. Plus, they'll give me access to 10 subdomains, which may be pretty sweet if I ever expand this thing.

So I'm considereing the move. It's not that I hate Microsoft (I made all my money before Law School from using their products), but that the tools I'm using are all PHP based, so they'll work on either platform.

The question I need to know is, how much trouble is it to learn PHP for someone who is very capable in VB/VBA/ASP/.NET web development, and moderately proficient in Java. The DB platform is MYSQL, which I know well, so the only real difference is the PHP language itself.

Is there a good book about the primary differences? Or will I be cursing for months trying to figure out stupid little things?

Thanks,

Rob
 
Posted by kaioshin00 (Member # 3740) on :
 
I'm no expert, but I do know that the php online documentation is excellent.

You can take a look at http://www.php.net/docs.php

[ October 29, 2004, 10:26 AM: Message edited by: kaioshin00 ]
 
Posted by Jutsa Notha Name (Member # 4485) on :
 
You should find the transition rather pleasant, if all the experience I've had with both languages holds true. I would suggest checking out one of the OReilly books on PHP.
 
Posted by Dagonee (Member # 5818) on :
 
OK. Good to hear about O'Reilly. They have some of the very best and very worst books on development - I won't buy them anymore without a recomendation or reading half the thing in the bookstore.

Thanks for the link to the documentation, too.

Dagonee
 
Posted by TomDavidson (Member # 124) on :
 
I started with VB/ASP, myself, and picked up PHP later. In my experience, the two languages are in fact very different, and you shouldn't expect any of your ASP experience to help you much.

That said, PHP is practically designed to integrate with MySQL, so I think you'll find that it is in many respects even easier for the kind of work you'd be doing.

[ October 29, 2004, 10:31 AM: Message edited by: TomDavidson ]
 
Posted by fugu13 (Member # 2859) on :
 
The php language is very well documented. However, it is definitely a worse platform (excepting the tools built for it) than ASP.NET (which is pretty decent, though far from one of the best).

PHP has certain particularly annoying limitations: no namespaces.

Lots of builtin functions, many of which accomplish the same things, yet none of which do exactly what you want (try running a sort with an anonymous function sometime; none of the 10+ sorting functions can do it).

Bad OOP support (unless you're using PHP5, which many hosts haven't upgraded to yet).

It has some very security hazardous settings that some web hosts like to use for compatibility reasons, and which can be hard to override without adding a few lines at the top of all your source files (or at least an include to a tiny script that resets them to what you want, which is a pain).

There are no really good templating systems for it (judged by their adherence to semantic separation), even though there are tons of templating systems for it (though often if you're writing modules for existing php software, such as drupal, this won't matter to you, and there are a couple pretty good templating systems).

For many things the php implementation has one built in (and overly simple) way to do it -- which leads many people to use this inadequate way to do it and tack on hacks to cover inadequacies.

Horrible, incomplete unicode support (and thus, even in PHP5, bad XML support), which makes i18n and such painful. I didn't use to think this was important to me, but unicode is a very powerful tool if you know how to use it.

It encourages using builtin database functionality and the ability to embed itself in html code to create some really awful pages. The PHP programmer has to enforce strict guidelines on himself such that he does not do things like put raw database queries in business logic (they should be abstracted to a library), or put business logic in html pages (*shudders at the lack of maintainability*), or have includes that display stuff when included (they should at most set up some variable and such for the functions therein to use, which should then be called to generate information). These all make maintaining PHP websites quite painful.

These said, PHP has some good points, primarily related to its uniquity and high adoption rate. There is some very good software written in PHP simply because PHP was all people felt they could be guaranteed would be available. Plus, PHP is remarkably fast for a language of its class. However, I generally recommend against PHP unless portability is of prime importance, or learning curve is an issue (either due to time or experience), since PHP's other advantage is that it is very quick to learn how to write badly but workably.
 
Posted by fugu13 (Member # 2859) on :
 
Out of curiousity, how much are you spending/planning to spend on hosting?
 
Posted by Hobbes (Member # 433) on :
 
I'd just like to take this opporunity to say that Unicode is a spawn of the Devil, even if it is integrating other languages and cultures, it's not worth switching to a two-byte charecter!

Hobbes [Smile]
 
Posted by Dagonee (Member # 5818) on :
 
$7.95 a month if paid a year in advance, otherwise $9.95. The email upgrade is $6.95 a month, which gives me 100 100MB email addresses. That's the price difference between the Linux hosting and the Windows hosting. This is at doteasy.com.

Thanks for the detailed info. If ASP.Net was available, I wouldn't be moving, but, alas, it's just ASP.

I'm pretty good about the abstractions stuff, so I'm not too worried there.

I don't intend to do too much programming, actually, but I know I'm going to want to do some. I wanted to make sure it was something I could pick up when that happens.

Ideally, I'll be writing modules for Mambo, which should help enforce a lot of abstraction.

Dagonee
 
Posted by fugu13 (Member # 2859) on :
 
I'd just like to say that anybody who says that obviously writes in a far too low level style [Razz] . We're talking about web programming, and the web is many things. One is international, and another thing is very complex, yet very layered. By writing in higher level languages and styles (in languages which accomodate many levels) we allow ourselves to develop code significantly more quickly, particularly when it comes to the web where most of the lifting is just that, lifting. Dealing with unicode and other strings at a byte level is like dealing with mime encoded documents as a binary stream rather than using a library to automatically break them up as appropriate.

[ October 29, 2004, 11:03 AM: Message edited by: fugu13 ]
 
Posted by saxon75 (Member # 4589) on :
 
I picked up the basics of PHP in a couple of weeks. I'm still working on some of the finer points, although I think that, for me, the "finer points" are really more questions of good software practices than language details. I keep meaning to pick up Python, but I haven't gotten around to it yet, and the fact that my hosting service doesn't support the mod_python for Apache makes it less attractive to me.

Hey, let me know how well you like your new hosting service, should you decide to switch. I'm always shopping around, and my current one sucks.
 
Posted by Hobbes (Member # 433) on :
 
"We're talking about web programming"

I'm not. [Razz]

Hobbes [Smile]
 
Posted by Dagonee (Member # 5818) on :
 
It's the same hosting service. They've been great on Windows - no down time to speak of (a couple incidents of a couple hours), good response time on technical questions, decent speed.

Of course, they may not be as good with Linux, but I'd be surprised. I'll let you know how the switch goes if I proceed.

Dagonee
 
Posted by fugu13 (Member # 2859) on :
 
Eh, it applies to most GUI programming as well. I'm just happy to know that the most powerful software company on the planet agrees with me that higher level languages and abstractions allow for more rapid, more secure, better development of userland applications [Razz] .
 
Posted by Hobbes (Member # 433) on :
 
You've sold your soul to Microsoft, you're dead to me Fugu.

Hobbes [Smile]
 
Posted by fugu13 (Member # 2859) on :
 
*snort*

Who's the one who develops on windows again?
 
Posted by Mike (Member # 55) on :
 
Fugu, what would you use over PHP? What do web hosting services usually have available?
 
Posted by saxon75 (Member # 4589) on :
 
Fugu is a total Pythonhead.
 
Posted by fugu13 (Member # 2859) on :
 
Usually have? PHP and MySQL. But there are plenty of places serving up nigh every possible combination of services at pretty reasonable prices, so if you're not locked into your hosting provider pretty much anything is possible.

For database, I'm all about PostgreSQL. It has far more advanced capabilities than MySQL.

For language/platform, that all depends on the intended application. If its document centric I would definitely recommend Apache Cocoon (which can use Java, but you'd mostly be writing in XSLT for many use cases), its a wonderful platform for developing many types of apps, and is pretty much unmatched for its document centric capabilities.

If we're just talking programming language, I'm partisan to Python (especially when one can use Twisted), though Java can be quite nice (with a variety of frameworks), and so can Ruby when using Ruby On Rails. C# and ASP.NET are also excellent choices for certain sorts of projects.

Also, a lot of times applications are best developed on a platform that is higher level than the level of "computer languages". For instance, wikis are often used as "application platforms", and come in many languages (Perl, PHP, and Python being some particularly big players in the wiki world). What primarily matters there is how it is extensible, not which language the extending is done in.

Also, I don't necessarily advocate one platform. Cocoon, for instance, is noted as a service integrator for existing web applications. One can tie together widely disparate components to create a better whole than if one created the entire system on one platform/in one language.

Ultimately, it all comes down to what the problem is. There are problems where the proper response is "write your new application in PHP" (though these often have "using the web hosting I already have" as part of the requirements). Without a proper understanding of the problem one can't make a proper determination of the solution (or the tool that is used to create the solution, in this case).

[ October 29, 2004, 01:55 PM: Message edited by: fugu13 ]
 
Posted by Dagonee (Member # 5818) on :
 
Yeah, I'd far prefer to be using PostgreSQL, because I'm automatically suspicious of the lack of ACID transactions. Plus, it has built in GIS functions that I always wanted to play with to make a world builder application. But, I don't actually need any more than MYSQL for what I'm doing, the price is right, and I know it very well.

I'm thinking I'm going to make the leap. What I wanted to be sure of is that when I want to modify things, I'll be able to pick it up fast enough.

On the Linux platform, I can use friendly URLs for Mambo content - this feature doesn't work on IIS.

Plus, if I ever do any of this in house it's going to have to be open source just from a budget standpoint.

Thanks for all the input, and when I realize what a huge mistake I've made I'll cry for your help again. [Smile]

Dagonee
 
Posted by fugu13 (Member # 2859) on :
 
*bump because I want to derail this thread into general discussion on web architecture, dangit*
 
Posted by Dagonee (Member # 5818) on :
 
fugu, I ran screaming from this industry for a reason. [Smile]
 
Posted by fugu13 (Member # 2859) on :
 
Web architecture is fascinating [Razz]

<--- reads RFCs and other technical documentation for fun.
 
Posted by TomDavidson (Member # 124) on :
 
I'm so sorry, Russell.
[Frown]
 
Posted by fugu13 (Member # 2859) on :
 
*pies Tom*

Seriously, there's a lot of fascinating stuff out there. Its certainly not any worse than reading scientific papers for fun, or Foreign Affairs for fun (well, I do those too, but yeah . . .).
 
Posted by Dagonee (Member # 5818) on :
 
OK, I've requested the move to Linux. I have left behind the comforts of 10 years of web development experience and am venturing into the unknown. No more ASP, no more IIS. [Smile]

Dagonee
 
Posted by fugu13 (Member # 2859) on :
 
Don't worry, you'll get used to the advanced configurability and customizability soon enough [Razz] .
 
Posted by Dagonee (Member # 5818) on :
 
OK, fugu, you've championed div-based layout as superior to table-based layout and I'd like to give it a try. Know any good tutorials, online or otherwise, for someone to get up to speed on it?

Dagonee
 
Posted by fugu13 (Member # 2859) on :
 
A List Apart is an excellent resource: http://alistapart.com/

This column is about moving their own site from tables to CSS based design: http://alistapart.com/articles/journey/

Here's a good set of tips and tricks: http://alistapart.com/articles/practicalcss/

Better rollovers with CSS: http://alistapart.com/articles/rollovers/

A bit on a very important, if small, part of a document: http://alistapart.com/articles/doctype/

The ever important list (your menu should be a list): http://alistapart.com/articles/taminglists/ (you may notice one of the examples here as the working beginning for the menu on http://consulting.fugu13.com ).

Some stuff on positioning/layout: http://alistapart.com/articles/flexiblelayouts/

Some advanced technique for fancy designs: http://alistapart.com/articles/slidingdoors/ http://alistapart.com/articles/slidingdoors2/

More on positioning/layout: http://alistapart.com/articles/elastic/

Useful trick with columns: http://alistapart.com/articles/fauxcolumns/

Some information on footers: http://alistapart.com/articles/footers/

There are dozens more articles of interest, most being added all the time.
 
Posted by Dagonee (Member # 5818) on :
 
Cool - thanks for the info. I know from my prior career that there's a LOT of bad development advice out there, so I always prefer to get reccomendations from good developers on new topics.

My goal is to create a Mambo template. This requires me to work with three new (to me) technologies: CSS layout, PHP, and Mambo.

Should be fun and frustrating.

Dagonee
 


Copyright © 2008 Hatrack River Enterprises Inc. All rights reserved.
Reproduction in whole or in part without permission is prohibited.


Powered by Infopop Corporation
UBB.classic™ 6.7.2