Skip to content

BEL Clan Portal

Sections
Personal tools
You are here: Home » Members » spacey's Home » Spacey's Latest News

Spacey's Latest News

Document Actions
There is a new web site with which we can all play.

As you may recall, I have never been quite pleased with the phpNuke package which currently handles the web site for our clan. So since I first installed it and setup the clan web site, I have been searching for something better. I think that this site, running Zope (which is written in Python with some compiled C modules) with a few add-on products might be that something.

What are the problem with phpNuke? They are numerous. The first and foremost problem is the fact that phpNuke is slow and buggy. Indeed, even for a product which had a version of 7.2, it still prints out around 500 warnings and errors per page displayed. Worse, this is even after a re-release during the one month period where paid subscribers are able to download the release! Worst of all, even after all of this, I still had to make several changes to even get things to run!!! Given that it was already supposed to have gone though alpha and beta testing before being released to subscribers, and these bugs still remain, they should be ashamed to charge folks to get what I would barely consider to be alpha quality code!!! And this has apparently not changed, as even the 7.4 version was re-released! Take a look at http://www.phpnuke.org if you want to see what I am talking about.

One more thing about phpNuke being slow and buggy. As you may have guessed, phpNuke, like postNuke and several other packages, is written in PHP. PHP is an OK language, but it has several drawbacks. First, it is an interpreted language. This means that you can quickly make changes, and do not have to rebuild an application to test it. But this means that PHP requires more resources than a program which was written in C. Secondly, is is extremely easy to write sloppy code in PHP, complete with undeclared or uninitialized variables. When combined with certain key configuration settings, this can lead to a security nightmare. You can then produce queries to a PHP script which will set or override variables and do all sorts of nasty things to your system. When combined with other stupid configuration settings, such as turning off the warnings about uninitialized variables, you are talking a potential disaster.

The next problem is that while phpNuke supposedly integrates some other products like phpBB, it does not truly do so. If you play around with skins (which change the look of things), you will notice that some areas do not change their appearance, and others change only some of their appearance. So it is perfectly possible to end up with pages where you cannot see what is on the page. This piece-meal construction only exacerbates the quality problems.

Want to work on the code? Well, it may be PHP which you can easily edit, but there is nothing which really documents the code. So, to quote the old game, "you are in a maze of twisty little passages, all alike"! Yes, they do provide minimal documentation to write a module, but I do mean minimal. It does not provide enough documentation to use to fix any bugs you find.

And for those of you who do not want to work on code, but only want to put up an article, post a message, or do something else. Well, you are stuck working through a stupid form with a narrow textarea to use to input your text. If you did not try it, you should! You will be cursing left and right. Thank goodness you can cut and paste into those text areas, or you would soon go crazy!

Another problem is that the user/group system is lacking. While phpNuke does allow for requiring new user accounts to be approved by an administrator, the groups are points based, and what little restrictions you can do based on groups are linear in nature. And remember that integration issue? Here is one area where it starts cropping up as well. Once you get within a module, they may use their own idea of groups, or not use groups at all.

Are there good things about phpNuke? Yes. Like I said, it allows an administrator to control who registers with the site. That has its advantages. But with a decent group and permission system, you can always take steps to make sure that folks who do register with the site are not automatically granted more than minimal permission. Indeed, thanks to the documentation for Zope and Plone, I know what the API is, and can even write my own user folder (the entity which stores account information). phpNuke also has a hierarchical structure for both its downloads and web links section. This is something that was lacking in postNuke and several other packages at which I looked. And there a number of other neat modules. However, I have no doubt that they can all be replaced.

Well, by now, you are wondering "What about Zope? Is it all Goodness and Light??". Well, as I have noted, Zope does not by itself have certain things which not ideal. Zope by itself does not try to be the be-all and end-all. Instead, it is a web application platform. This means that you can use it to write your own web applications, and they provide a manual which is nearly 500 pages to help you do this!! Fortunately, there are already some applications, or as they are often called, "Zope Products" which do some pretty neat things. More on this in a second.

Another downside is that Zope uses Python, combined with some C code extensions. Python, like several other languages including TCL/TK and even a few shell scripts, provides a means to compile C code to add functions through shared libraries. And Python, like Java and a few other languages, also provides a means to optionally byte-compile code to reduce the time spent parsing a file. But it is still an interpreted language, and as a result is more resource intensive than a program which is written in C and compiled to machine language. And then there is the fact that Python uses indention, rather than keywords (e.g. "BEGIN" and "END") or special characters (e.g. { and }) to indicate block structure. That is something which will trip up an old FORTRAN/C programmer like me from time to time. 8) One very unfortunate problem which will result from this: It will not be easy to take scripts/packages which used PHP and integrate them with Zope. The one which comes immediately to mind is the UT Stats Database package. SIGH!

There is another downside to Zope, but one which has an advantage as well. It wants to store EVERYTHING in a proprietary database, called ZODB. We are not talking about a relational database such as Oracle, MySQL, or others. Instead, we are talking about a database which mearly stores chunks of data and provides a very basic index to those chunks. So if you want to put a 100KB image up on your site, your database will grow by 100KB. And when you replace it with a different image which is 250KB, the database will grow by another 250KB. This means that it stores multiple versions of the same "file". This means that you can undo your changes. But you are probably wondering about those 200MB map packs and such we want to put up on our site. Certainly we do not want to store them in the database as well! Well, you are right, and fortunately, there is a way for us to avoid this. One of those "Zope Products" permits us to store objects in the filesystem itself. And others permit us to access things through a database.

One item which is both a downside and an upside is the documentation. Unlike phpNuke with its gloss-over-things documentation, or postNuke with its "Documentation? We don't need no stinking documentation!" ideas, Zope and Plone provide very extensive manuals. Zope itself has a 495 page, fully indexed manual which covers all aspects of Zope 2.6 (it has not yet been updated for Zope 2.7.2, which this site is running, but it should be close), and Plone has a similar manual of around 100 pages! The downside? There is a bit of a learning curve! Even after three months, I am still have quite a bit to learn. But I am the admin!

Now, for an upside! Remember that crap about editing items? Well, while by default you do edit content via a web form, you don't have to do so. With the proper configuration and helper function on your machine, you can use your favorite text editor. All you need to make sure of is that it is stored as text. I am editing this item using a package called zopeedit, which knows to bring up the file using emacs. This way, I can do things like spell checking, inserting other files, and all the other things I normally do when I edit a file. Or, if you so desire, you can upload files, images, etc. Pretty neat, huh?

Another nice thing is that there are lots of Zope products out there which add functionality to Zope, as well as building off of what other Zope products provide. If you go out to the Zope web site at http://www.zope.org and click on "Zope Products" on the left side of the page, you will see a list of around 200 products. Some are in the earliest stages of development, and some appeared to have died in that state years ago. But there are numerous others which are out there for the using. Each of these products is written using a combination of Python, DTML, HTML or other languages.

While I am on the subject of Zope Products, here is how things currently stack up. This site currently runs on a foundation consisting of Python 2.3.3 and Zope 2.7.2. To this, I have added a Zope Product called CMF, which stands for "Content Management Framework". CMF provides extensions which among other things makes it possible for individuals to contribute to the site, and provides for things such as "workflow", which I will discuss in a moment. On top of CMF is another product called Plone. Plone took many of the ideas of CMF and ran the ball completely outside of the stadium! Now, these are just two product packages (which contain several other products), and they provide so much. There are other products which permit discussion forums, photo albums, file system stores, and numerous other facilities.

Well, I mentioned it a moment ago, and the time has come to speak of other things. Of documents and publishers, managers and reviewers, and viewers who read these things! Yep, I am feeling a bit silly, but after all, it is after 2AM as I write this (listening to music on Yahoo! Launch as I do so). One of the other neat things about Zope include the ability to induce a workflow, so that a document must be reviewed before it is published. I do not know quite how this will work out for us, but it could prove very useful. Then again, it may be that we will have to grant a reviewer role to some degree to all members. Or, I know it is possible to define new workflows. But the facility exists, and we will have to see how it works for us.

Wait! The neat things do not stop there. Zope is object oriented, and each object can inherit properties/attributes from its parent, or even an object several levels up. So you can set up pages which require a certain role to access, or setup a page template which is used by all descendent pages unless otherwise overridden. This could prove rather interesting.

Well, I could go on and on. But instead, I will leave you with a few suggestions, and a site with which we can play before we do the real thing. My suggestions are as follows (in no particular order):

0) Think about what you want to see in a Clan Web site. In the past I have mentioned things like a page describing our favorite games, game types, weapons, and even telling things like any instant messaging IDs we might have, or what our timezone is. And we will want downloads, web links, and other things which currently exist in a form over on the current clan site or on sites like Fileplanet. But ideas like this will help you find information which will prove to be useful.

1) Look at the main entry page. There are all sorts of links there to sites running Zope, CMF, and Plone. Take a look at things you see on those sites, and post a message to the belwww mailing list to let us know what you have found.

2) Want to see a list of some of the Zope products with better descriptions for them than what is likely to exist for some of them on the various Zope sites? There are a number of Zope products in the NetBSD packages collection (which also works on Linux and other OSes as well). They are listed on the following page, but unfortunately many of these products are not the latest versions. Most start with the word "zope". Here is the page at which to look.

ftp://ftp.netbsd.org/pub/NetBSD/packages/pkgsrc/www/README.html

If you see a package which you would like to investigate, please let me know. I am spending some time updating these packages, and your input will help me decide what order in which I should update these packages. High on the list are currently Confera, LocalFS, Squishdot, and something like JPicture or Photo.

3) Read the documentation. "The Zoppe Book" and "The Plone Book" are both available on their respective sites. But if I get enough call for them, I can put them up for download off the site.

4) Remember those sites for Zope and Plone? There are all sorts of other things up there, like information on how to do certain things.

5) Ask questions. Post a message to the mailing list. Perhaps somebody else has done something you are trying to do, if they have not, it might be that they can figure it out much faster than you.

Created by spacey
Contributors :
Last modified 2004-07-28 02:37 AM
 

Powered by Plone

This site conforms to the following standards: