You are not logged in Log in Join
You are here: Home » Zope Documentation » Books » The Zope Book Releases » The Zope Book (2.5 Edition) » Using Zope

Log in
Name

Password

 
Previous Page Up one Level Next Page Using Zope Comments On/Off Table of Contents

Chapter 2: Using Zope

This chapter gets you up and running with Zope. It guides you through installing and running Zope. This chapter covers the most important Zope concepts. By the end of this chapter you should be able to use Zope to create and manage simple yet powerful web applications.

Anonymous User - July 5, 2002 3:42 pm:
 Chapter Two consists of a number of sections ... maybe something of a ToC here would help navigate this
 rather large slab of text.
Anonymous User - July 25, 2002 8:35 pm:
I was unsure where to place this comment; and it may not be useful. I am new to Zope and have been proceeding
 through the Chapters one at a time, one thing I thought might be advantageous but a bit of an undertaking is
 to suggest that initially the user creates for themselves a 'Sanbox' folder or something similar in order to
 experiment with the given examples. I did this almost right away as soon as I discovered I was litering my
 Root or contained folders with little snippets of script or object experiments. Just a suggestion. Thank-you
 for this wonderful document.
Anonymous User - Jan. 28, 2003 3:16 pm:
 test

Downloading Zope

The first steps to using Zope are to download and install it. Zope is available for free from the Zope.org web site. The most recent stable version is always available from the Download section of Zope.org.

Zope is currently available as a binary for Windows, Linux and Solaris. This means that you can just download and install it without having to compile any programs. For other platforms you must download the source and compile Zope. Zope can be compiled and run on almost any Unix-like operating system. As a general rule of thumb, if Python is available for your operating system and you have a C compiler, then you can probably use Zope.

Anonymous User - May 8, 2002 2:54 pm:
 Also is available as a binary for MacOs X. ;-)
Anonymous User - Aug. 8, 2002 8:10 am:
 What do you recommend for people who don't have a C compiler?
Anonymous User - Aug. 18, 2002 11:25 pm:
 if you dont have C then hope you can d/load binary for your OS,,,, of course
Anonymous User - Sep. 5, 2002 10:20 am:
 or 'get one'.. not too taxing, i hope.

Installing Zope

You will install Zope differently depending on your platform. If you are running a recent version of Linux, you may already have Zope installed. You can get Zope in both binary and source forms. There are also several different binary formats available.

Anonymous User - Apr. 25, 2002 10:58 pm:
 how do I install zope on mac os x?
Anonymous User - Apr. 26, 2002 4:53 am:
 it should work with the source-distribution of zope.
 i haven't tried macosX but i installed zope on freebsd4.5 (also a bsd-kernel like macosX);
 i had to use python2.1 due to python2.2 won't work.
Anonymous User - May 1, 2002 8:21 pm:
 There is a MacOS-X How-to on the Zope.Org site (look under "Documentation")
Anonymous User - July 23, 2002 7:51 pm:
 also if you don't want to think to much you can always use fink to install zope: http://fink.sf.net/
Anonymous User - July 24, 2002 12:44 pm:
 Greetings from Toronto, Canada everyone.
I've just started using this Zope Book and will be betting the farm on a huge portal we plan on putting up in
 a few months that eventually will be IPO-ed. Qucik question: How did the author do this HTML book with
 comments in it? I think it's an excellent collaboration idea for web authors who want to put out beta copies
 of their books before sending them to the press. Don't you?
 L8tr,
 Romulus
 ==========
 email: [email protected]
mcdonc - July 25, 2002 9:39 am:
 See http://backtalk.sourceforge.net.  HTH..
Anonymous User - Nov. 28, 2002 12:46 am:
 I have successfully installed and started the zope server.
 But I have no -idea how to view the web page... I am able to open the admin page, i.e.
http://myurl:8080/manage, but how to open index.html directly without prompting for passwrd. Any suggestions.
 thanks.
Anonymous User - Dec. 10, 2002 6:49 am:
 for OS X.2 installation: http://www.zope.org/Members/jens/docs/zope_osx

 You can find Prebuild binary here: http://tony.lownds.com/macosx/ working fine with my OS X.2.2 

 Zope binaries for os X also there:  http://opensource.spvi.com/

 Enjoy! ;)
Anonymous User - Dec. 25, 2002 5:00 am:
 try the mpkg in www.versiontracker.com for osx

Installing Zope for Windows

Zope for Windows comes as a self-installing .exe file. To install Zope, double click on the installer. The installer walks you through the installation process.

Anonymous User - May 29, 2002 5:23 pm:
 What versions of Windows does Zope work on? Will it work with Win 95/98/ME, or only NT/2000? -- Oryx3
mcdonc - May 29, 2002 5:29 pm:
 It "officially" works on Windows NT/2000, although it reportedly also works fine on 95/98/ME and XP.
Anonymous User - July 24, 2002 12:47 pm:
 I'm using it on Windoze-Xp and it runs and feels like a solid app.
 Of course, I am weaning myself of M$S products in favour of Liunux, NetBSD and FreeBSD via GNOME 2 or KDE 3,
 so I hope it's just as easy to install on those platforms too.
Anonymous User - July 24, 2002 12:50 pm:
 ...and by the way, I leave my Windoze machine on 24/7 and keep Zope on just to see how it behaves with my
 other apps. It just keeps humming away using little resources hoping to get its share of requests. :-)
 Awesome product (so far!!).

 Romulus
 =========
bazzo - Aug. 4, 2002 8:28 am:
 Zope 2.5.1 does not run on my Win98. After installation I d/clicked START.BAT, after quite a while I got the
 result about mounting the database, but when I inserted http://localhost:8080/manage at the IE I got "Server
 not found"
 I would have looked into the FAQ before if I would have found...
 But everything sounds so interesting that I will carry on!
 with greetings from Germany
 bazzo
bazzo - Aug. 4, 2002 8:33 am:
 Hey, now this is funny!!
 After I clicked on that localhost-link in my own comment before that site opened, asking for my login - now
 it works......
 strange 

 bazzo (carrying on)
Anonymous User - Aug. 26, 2002 3:01 am:
 running on 98se without a hitch... only stumbling block (at first) was zope's command line interface, which,
 the first time i ran start.bat, wasn't quite as, uh, blunt ;) as i may have liked - that is, it didn't
 display anything to the effect of "zope is now fully loaded and running... feel free to go test out that
 localhost:8080 link now". what can i say, i like to have my hand held ;)
 anyway, for the curious (and, like me, exceedingly dense :P), once you've run start.bat and the command-line
 window pops up, wait for a message to the effect of "ZServer HTTP server started" followed by your hostname
 and port number (this comes after the message about opening and mounting the database, and it may take quite
 a bit longer than you'd expect the first time you run it) - then you're good to go.
Anonymous User - Jan. 11, 2003 2:29 pm:
 Right. Just wait a few minutes (refreshing your browser at the ...:8080 URL) and it'll come up:
  ZServer HTTP server started at...
  ZServer FTP server started at...
  ZServer PCGI server started at...

 Just not sure how to *stop* the WIndows version cleanly. Just close/kill the DOS PYTHON window?

Since you can install more than one Zope installation on on a machine, you have to name this first Zope site. Thus, pick a name for your Zope installation and a directory to install it in. Click Next and create a new Zope user account. This account is called the initial user and is used to log into Zope for the first time. You can change this user name and password later if you wish.

Anonymous User - June 5, 2002 1:34 am:
 ... more than one Zope installation on a machine ... -- phc

If you are using Windows NT or Windows 2000, you can choose to run Zope as a service. Running Zope as a service is a good idea for a public server. If you are just running Zope for personal use don't bother running it as a service. Keep in mind that if you are running Windows 95, Windows 98, or Windows ME (Millenium Edition), you cannot run Zope as a service.

Anonymous User - May 29, 2002 5:24 pm:
 Oh...
Anonymous User - Aug. 3, 2002 4:51 am:
 What `bout XP home edt.???
Anonymous User - Aug. 5, 2002 5:14 am:
 as far as I know, 

 XP is a NT technology....so you should be able to run it as service if you wish
Anonymous User - Aug. 13, 2002 11:11 am:
 Of course, Windows XP comes from NT technology, which means you have a list of services as in Windows 2000,
 you can ask them to start manually or automatically. All NT services I've encountered so far have worked
 flawlessly with Windows XP Pro. And yes, running Zope as a service is a better idea, servers are meant to
 work this way.
Anonymous User - Jan. 26, 2003 3:34 am:
Well, not probed yet, but I think it must be really easy to simulate a windows service in Windows 9x but just
 creating an batch script to start zope&plone and then executing it automatically by adding a line (run
 regedit) to the register "folder" HK_LOCAL_MACHINE/software/Microsoft/Windows/CurrentVersion/Run

If you decide to uninstall Zope later you can use the Unwise.exe program in your Zope directory.

Anonymous User - Aug. 2, 2002 12:45 pm:
 If your Zope was installed running as service under windows uninstall will not remove the service, although
 all files are removed.

Downloading Linux and Solaris Binaries

Download the binary for your platform and extract the tarball:


$ tar xvfz Zope-2.4.0-linux2-x86.tgz
Anonymous User - May 28, 2002 9:29 pm:
The 'z' option used presumes GNU tar. A more safe example might be <TT>gunzip <
Zope-2.4.0-linux2-x86.tgz |
tar xvf -</TT>, which should work everywhere GNU zip is installed, and when it doesn't work (stock
Solaris 7
for instance) will give inexperienced UNIX people a better error to head off with ('bash: gunzip: not found')
Anonymous User - May 28, 2002 11:23 pm:
 Sadly, Zope doesn't unpack using Solaris tar anyway. It requires GNU tar because Solaris tar craps out on
 long filepaths (and probably always will).

In this example, you are downloading version 2.4.0. This may not be the most recent version of Zope when you read this, so be sure and get the latest stable version of Zope for your platform.

This will unpack Zope into a new directory. Enter the Zope directory and run the Zope installer script:


$ cd Zope-2.4.0-linux2-x86
$ ./install

The installer will print information as it installs Zope. Among other things, it will create a initial user account. You can change the initial user name and password later with the zpasswd.py script (see Chapter 7, "Users and Security").

Anonymous User - June 25, 2002 6:48 pm:
 On my manrake rpm installation it was /usr/bin/zpasswd 
 Still not sure where I should be putting the file called "access" though.
Anonymous User - Aug. 14, 2002 6:41 am:
 Should read: (see Chapter 8, "Users and Security").

The installer will configure Zope to run as your UNIX userid. If you prefer to run Zope as another userid, you can use the -u command line switch and specify the user you want to configure Zope to run as. There are many books out there with more information on userids and UNIX administration in general you should check out if you want to do anything fancy. For now things will work fine if you just install Zope to runs as your userid by not specifying any extra command line options.

For more information on installing Zope see the installation instructions in doc/INSTALL.txt and find out more about the installer script by running it with the -h help switch:


$ ./install -h
Anonymous User - June 4, 2002 7:03 am:
 jason add
Anonymous User - Jan. 20, 2003 4:06 pm:
 ./install  ran great
 ./start had a problem when the program wanted to open a file 
 PANIC (300) Z2 startup exception
 traceback(innermost last)
 file /home/xyz/zope/Zope-2.5.0-linux2-x86/Z2.py
 line 688
 IO error permission denied file /home/xyx.../var/Z2.pid

 Corrected by making a file in /home/xyz/zope/Zope-2.5.0-linux2-x86/var
 called Z2.pid and chmod to 744

Getting Zope in RPM and deb format

Zope Corporation doesn't make Zope available in RPM format, but other people do. Jeff Rush regularly packages Zope as RPMs. For more information check out his web page (http://www.taupro.com/Downloads/Zope/). Zope is also available in the Debian Linux deb package format. You can find Zope deb packages at the Debian web site site. Generally the latest Zope releases are found in the unstable distribution.

kaleissin - May 16, 2002 12:49 pm:
 FreeBSD: # cd /usr/ports/www/zope; make install
Anonymous User - May 17, 2002 8:29 pm:
 When you install zope using RedHat a rpm, where does it hide the install script?
Anonymous User - July 3, 2002 12:10 am:
The zope rpms are always out of date and even the latest of redhat does not have the required rpms to install
 nor the proper version of python. Best to install from binary.
Anonymous User - Jan. 7, 2003 5:40 am:
 FreBSD: # portinstall www/zope
Anonymous User - Jan. 26, 2003 3:44 am:
 Why not officially distributing it like an OpenPackage for Unix platforms(http://www.openpkg.org/) It's a
 very serious project and is actually supported by companies like Cable&Wireless and Sun Microsystem.

Compiling Zope from Source Code

If binaries aren't available for your platform, then chances are you can compile Zope from the source. To do this, install Python from the sources for your platform and make sure you have a C compiler. You can get Python from the Python.org web site. Although we try and use the most recent Python for Zope, often the latest Python version is more recent than the version we "officially" support for Zope. For information on which version of Python you need to compile Zope with, see the release notes on the Web page for each version. Zope 2.4 requires Python 2.1. Zope 2.3 and earlier versions used Python 1.5.2.

Anonymous User - May 9, 2002 2:27 pm:
 "officially"? Another comment alluded to having to install Python 2.1 though he already had 2.2. This is
 pretty inconvenient, especially if you aleady have Python and prefer to have (just) the latest version. Why
 must it be this way?
Anonymous User - May 9, 2002 2:29 pm:
 Because that's life.  Sorry.
Anonymous User - July 2, 2002 8:04 am:
 To expand on the previous comment, which was just as accurate and a LOT more concise...

 As a professional developer myself, I've seen plenty of instances where an application only works with an
 older rev of the base development tool the application is written in.
 That's because when the base development tool gets upgraded, they introduce new bugs, among other things.

 At the very least, you've got to have a STANDARD platform to build your application on.
Anonymous User - July 3, 2002 12:13 am:
 The problem here is that redhat has many tools that use python 1.5.? and they are hanging on to that version
 even though they include python version 2.2 zope does not support it. If using zope means I have to program
 anything in python, I'm out of here. With python programs a missing space and the sucker won't work.
Anonymous User - July 3, 2002 8:50 am:
1. If you cant be bothered to install Zope from a binary distro at http://www.zope.org/Products, you might as
 well not even try using Zope.
 2.  Spare us the threats. ;-)
Anonymous User - July 7, 2002 5:39 pm:
 1. You can install a platform-dependant Zope with its own Python 2.1 with no fuss, and keep using Python
 2.2.x or whatever you like if you do other Python programming.
 2. With C/C++/Perl/Java/etc programs, a missing semicolon and the sucker won't work. With (you name it), a
 missing ending parentheses and the sucker won't work. So, why the fuss over enforced indentation in Python?
Anonymous User - Jan. 3, 2003 6:12 am:
 If you are using RedHat 7.X you can install the Python-2.1 RPM along with python-1.5 and python-2.2 RPMS
 without any clash. You can download the python-2.1 RPM from http://www.python.org/2.1.3/rpms.html. If I were
 you, I would download the src RPM and compile it. Later you can compile the Zope source RPM without any
 issues.

Download the Zope source distribution and extract the tarball:


$ tar xvfz Zope-2.4.0-src.tgz

This unpacks Zope into a new directory. Enter the Zope directory and run the Zope installer script:


$ cd Zope-2.4.0-src
$ python wo_pcgi.py
Anonymous User - Nov. 16, 2002 11:57 am:
 You should also say how to install it, if one wants to run as another user rather than root or nobody. I've
 set the sticky bit in the var directory and changed the ownership to root, but I'm having problems when
 accessing my Zope site. Why don't you write what are the recomended ownerships of the zope files and
directories? There're two how-to's I have as a reference and both differ when talking about this subject. So,
 I guess it would be nice if there is an official version.
Anonymous User - Nov. 19, 2002 8:52 am:
 Nevermind, I solved it. The problem is that the folder where Zope is installed and its subfolders (except
 var), should also have this dedicated user as owner.
However, I still think that you should write something about it, for this how-to says that "nobody" should be
 the owner:
 http://www.zope.org/Members/mcdonc/HowTos/zopeinstall/ZOPE-INSTALL-HOWTO

 and this one, which is more actual, says that the var directory must be owned by this dedicated user:

 http://www.zope.org/Members/beacon/install_instructions

 According to SETUID.txt it should be own by root. But it doesn't talk about the other folders.

The installer compiles Zope and sets up your installation. The installer prints information as it runs, including the initial user name and password. It's important to write down that information so you can log into Zope. For more information see the installation instructions in the file doc/INSTALL.txt. You can change the initial user account later with the zpasswd.py script (see Chapter 7, "Users and Security").

keel - Dec. 8, 2002 8:50 pm:
I have to chuckle as I read this; I had to install and uninstall zope three times before I figured out what's
going on. Now that I found this great resource I'm not winging it any more. I think it'll be worth my trials.
 Can I convert my dtml to html to export to webpages for my friends? I don't think they can handle this
 technology. Takes python I suppose.

Starting Zope

Depending on your platform, you run Zope with different commands. Whatever your platform, you can either run Zope manually, or automatically. When running Zope manually, you simply tell Zope when to start and when to stop. When running Zope automatically, Zope will start and stop when your computer starts and stops.

Anonymous User - Aug. 26, 2002 7:58 pm:
I have install zope on NT4(SP 5)and win2000(SP 2) user ".exe" package. When I click the start.bat and it show
 python.exe application error. Look like I have to try on Linux first.

Starting Zope On Windows

The installer creates a Zope directory with a batch file called start.bat. Double click the start.bat icon. This will open a window that includes logging information. On this window you find out what port Zope is listening on. You can now log into Zope with a web browser.

Anonymous User - Oct. 13, 2002 5:08 am:
 nnmm
Anonymous User - Nov. 22, 2002 6:27 am:
 A mention about which versions of Windows have been tested would be nice.

If you are running Zope as a service, you can start and stop Zope via the Services control panel. Zope will write events to the event log so that you can keep track of when your service starts and stops. If you run Zope as a service you must know what port Zope is running on, since you will not have direct access to its detailed logging information.

Zope comes with its own web server. When you start Zope, its web server starts. If you wish you can connect Zope to your existing web server such as IIS, but this is beyond the scope of this book. The Zope Administrator's Guide covers this kind of material.

Anonymous User - Sep. 20, 2002 8:13 am:
 Well, <a href="http://www.zope.org/DocProjects/AdminGuide
 >Zope Administrators Guide</a> is an abandoned? Wiki;
 Still, as questions below and abt 30% of the zope mailing list traffic show,
 an AdminGuide would be badly needed.
Anonymous User - Sep. 20, 2002 8:13 am:
 Well, <a href="http://www.zope.org/DocProjects/AdminGuide"
 >Zope Administrators Guide</a> is an abandoned? Wiki;
 Still, as questions below and abt 30% of the zope mailing list traffic show,
 an AdminGuide would be badly needed.
mcdonc - Sep. 21, 2002 6:37 pm:
 Yes, the Admin Guide died on the vine.  I have removed all references to it from the 2.6 Zope Book edition.

Starting Zope on UNIX

Run the start script:


$ ./start &
Anonymous User - Apr. 30, 2002 3:39 am:
 Hi
 Where do you find the start script?? ( Same question for the bat file in Windows)

 [email protected]
Anonymous User - Apr. 30, 2002 10:10 am:
 in the "Zope-version-linux2-x86" dir
Anonymous User - May 8, 2002 10:53 am:
 start script is generated by the install script. If it is not there Zope might 
 not be installed correctly.
Anonymous User - May 16, 2002 2:45 am:
 I think the key point here is how to start zope when a Zope...rpm package is installed, instead of a tar.gz
 package.
Anonymous User - May 17, 2002 9:28 pm:
 exactly.... how do you do this? I'm looking all over and I can't seem to find a way to start zope now that
 I've installed from an RPM
Anonymous User - May 18, 2002 7:26 am:
 Here on the debian (woody) there is an *init script* on /etc/init/zope that you can start like
 '/etc/init/zope start'. The /etc/init/zope scripts then runs
 a *shell script* called 'zopectl' (in /usr/sbin/zopectl). Zopectl then essentially starts a *python script*
 '/usr/sbin/zope-z2'. You can hook in anywhere. RPM might be slightly different though.
Anonymous User - June 25, 2002 6:35 pm:
 I'm on mandrake, installed from rpm, searched /etc and /usr for *start* *zope* and only thing I've found is
 this :
 /usr/share/zope/lib/python/Zope/__init__.py

 Which says it doesn't have the right permissions running as root and it didn't put it into the start up
 process for the next reboot. Am I missing something?
 Or have I got too much already?
Anonymous User - July 10, 2002 9:33 am:
If you are using an RPM installed version of Zope you can find out where it put the start and stop scripts by
 doing 'rpm -ql | grep start' and 'rpm -ql | grep stop'
 The -ql parameters are for 'q'uery and 'l'ist (files in rpm, that is)

 The two above rpm commands should list exactly where to find the start and stop scripts...  hope that helps!
Anonymous User - Sep. 6, 2002 11:40 am:
 On SuSE, './start' (as root) works only after having set 
 $ZOPEHOME/var to world-writable.
Anonymous User - Sep. 25, 2002 5:24 pm:
 zope is awesome but too hard to install and configure on linux, it should be more like the win version
Anonymous User - Sep. 26, 2002 2:40 pm:
 well, the command properly spelled shold be 

   rpm -ql zope | grep start 

  anyway, in my suse 8.0 I get /opt/zope/ZServer/medusa/start_medusa.pyc 

 I suppose that the pyc is a python script, but I know nothing about phython. 
 Somebody knows if this is the right script?
Anonymous User - Oct. 6, 2002 3:33 pm:
 Why the heck does the book not mention anything about making zope work with the web server?
Anonymous User - Oct. 6, 2002 4:43 pm:
 in suse 8.0 the script to run is 

 /opt/zope/z2.py
Anonymous User - Oct. 6, 2002 5:42 pm:
 (sorry, to explain my comment). I mean, how to work with apache web server. I see the note below that it
 belongs in the administrator's guide. Well, guess what. That document seems to be no longer maintained and
 out of date.
Anonymous User - Nov. 8, 2002 3:12 am:
 I am on RedHat 6.2,Zope installed from rpm, 
 starting zope script

 /etc/rc.d/init.d/zope [start|stop|restart|status]
Anonymous User - Nov. 21, 2002 1:17 am:
 FreeBSD-4.6:  Start Zope using the command:

 /usr/local/etc/rc.d/zope.sh start

It's important to do it this way, as the FreeBSD port installs all the data files as owned by the user 'www',
 not 'nobody'. The zope.sh script above sets the user correctly, but the 'start' script by itself does not,
 and you'll get a cryptic error.
Anonymous User - Jan. 15, 2003 8:00 pm:
 I'm probably the only one running Zope on Debian-MIPS Linux (on an SGI Indy). In any case, the current .deb
 for my architecture seems to prefer using the command
 >zopectl start

 However, this command never returns, so my machine would hang on startup until I added an ampersand to the
 apropriate line in /etc/init.d/zope

Zope will start running and will print logging information to the console. You should see information telling you what port Zope is listening on. You can now log into Zope with a web browser.

Anonymous User - July 2, 2002 8:07 am:
 Dit is commentaar regel
Anonymous User - Aug. 8, 2002 2:24 pm:
 2002-08-08T17:58:11 INFO(0) ZODB Opening database for mounting: '140377936_1028827208.543770'
 ------
 2002-08-08T17:58:11 INFO(0) ZODB Mounted database '140377936_1028827208.543770' at /temp_folder
 ------
 2002-08-08T17:58:11 INFO(0) ZServer HTTP server started at Thu Aug  8 13:58:11 2002
         Hostname: samba
         Port: 8080
 ------
 2002-08-08T17:58:11 PANIC(300) z2 Startup exception
 Traceback (innermost last):
   File /home/dna/dope/Zope-2.5.1-linux2-x86/z2.py, line 607, in ?
   File /home/dna/dope/Zope-2.5.1-linux2-x86/ZServer/FTPServer.py, line 602, in __init__
   File /home/dna/dope/Zope-2.5.1-linux2-x86/ZServer/medusa/ftp_server.py, line 727, in __init__
   File /home/dna/dope/Zope-2.5.1-linux2-x86/ZServer/medusa/asyncore.py, line 306, in bind
 error: (98, 'Address already in use')
Anonymous User - Aug. 8, 2002 2:27 pm:
 error (98, 'Address already in use')
 any ideal
Anonymous User - Aug. 13, 2002 9:39 am:
 Check to see if you have anything running on port 8021 (such as an FTP server or somesuch...) Zope tries to
 start an additional FTP server on port 8021.
 Sean Bossinger
 [email protected]
Anonymous User - Aug. 27, 2002 12:28 pm:
 i installed the binaries of the 2.5.1 version. when i run the install script, after the ZServer PCGI Server
 started, i obtain the message
 z2 Startup exception
 File /etc/Zope-2.5.1-linux2-x86/z2.py, line 690 , in ?
 IO Error [Errno 13] Permission Denied: '/etc/Zope-2.5.1-linux2-x86/z2.pid'

 what's wrong?

 Luca Morelli
 [email protected]
Anonymous User - Aug. 27, 2002 12:30 pm:
 ... when i run the start script ...

 Luca Morelli
 [email protected]
fleximan - Sep. 13, 2002 5:47 am:
 I've got ecxactly the same problems here andt don't know how to get it running :-(
Anonymous User - Sep. 13, 2002 12:35 pm:
 Have you looked at line 690 in z2.py to see what it is trying to do? The 'permission denied' error messages
 often result from zope trying to write the .pid file as user 'nobody' to a directory that has only root
 permissions. With all the Zope's I've installed on *nix, I've had to chmod some things first.
Anonymous User - Nov. 12, 2002 1:29 pm:
 well, i've tried as 'zope' user with 2.6.0 and:

 ./start 
 ...
 2002-11-12T15:21:10 PANIC(300) z2 Startup exception
 Traceback (innermost last):
   Module __main__, line 744, in ?
   Module ZServer.PCGIServer, line 275, in __init__
   Module ZServer.medusa.asyncore, line 306, in bind
 error: (98, 'Address already in use')

 BTW, idem with ./start -P 9000 

 netstat -ntlp
 doesn't shows anything listening in 8021/8080 , etc
 I've switched down FTP server in the same machine, same results
 any clues?
 regards
 Abel

Zope comes with its own web server. When you start Zope, its web server starts. If you wish you can connect Zope to your existing web server such as Apache, but this is beyond the scope of this book. The Zope Administrator's Guide covers this kind of material.

Anonymous User - July 29, 2002 2:08 am:
 WILL cover, as I can see: The Administrator's Guide will describe how to install, update, backup, and
 generally maintain Zope. It will cover web server integration and ZEO. :(
mcdonc - Sep. 21, 2002 6:38 pm:
 The 2.6 Edition of the Zope book covers ZEO and virtual hosting setups. I has subsumed the duties of the
 admin guide to a large extent.

The start script can also be edited to start Zope with many different options. How to customize your Zope startup is also described in the Administrator's Guide.

Logging In

To log into Zope you need a web browser. Zope's interface is written entirely in HTML, therefore any browser that understands modern HTML works. Mozilla, and any 3.0+ version of Microsoft Internet Explorer or Netscape Navigator will do.

Anonymous User - Apr. 23, 2002 4:05 pm:
Remarks on the Zope site indicate that certain versions of IE do not work with the management interface; it's
 your decision as to whether those caveats should be carried into this document.
docu - May 11, 2002 11:58 am:
 I had much trouble with IE 4 and FRAMES.

 <FRAMESET>
   <FRAME SRC=some.cgi?script=with&parameters>
 ...

 This won't work on IE 4.

To log into the management interface point your web browser to Zope's management URL. The management URL for Zope is Zope's base URL with /manage appended. Assuming you have Zope installed on your local machine serving on the default port 8080, the management URL is:


http://localhost:8080/manage
Anonymous User - June 15, 2002 9:04 am:
 Doesn't standard installation use port 9673?
Anonymous User - June 15, 2002 10:24 am:
 It used to, but now the standard port is 8080.
Anonymous User - June 18, 2002 3:37 am:
 In Debian :

 http://localhost:9673/manage
Anonymous User - Aug. 12, 2002 12:31 pm:
 FYI

 Just in case anyone else runs into the same problem as I did.

 I could not log in using http://[hostname]:[port]/manage I wound up using http://[ipaddress]:[port]/manage.
 It worked and let me in.
Anonymous User - Aug. 20, 2002 5:30 pm:
 DNS GOT PROBLEM
Anonymous User - Sep. 4, 2002 8:05 am:
 right! in Debian 

 zope is installed with port 9673.
Anonymous User - Sep. 7, 2002 12:14 pm:
 How do i find the ip address
Anonymous User - Sep. 7, 2002 12:14 pm:
 How do i find the ip address
Anonymous User - Sep. 16, 2002 4:05 pm:
 On Linux machines: ifconfig; on u$oft machines: ipconfig

 It should show you a list of network card interfaces and 
 the IP address bound to the interface.

 If http://[hostname]... doesn't work, it means that your
 machine's name is not being resolved by DNS. 
 http://localhost... may work for you since it's the 
 loopback.
Anonymous User - Oct. 16, 2002 9:02 am:
 And I have another Problem:
 I have SuSE 8.0, The Zope already exist in this distribution.
 To start it I use next comand:
 /etc/init.d/zope start
 Than I try to open in my browser: http:/localhost:8080/manage
 It is opened without problems.
 Problem is next - WICH pasword used by default.
 I can't change password.
 What I should do in this case.
 Thanks.
Anonymous User - Dec. 17, 2002 4:21 am:
 why port is 8080, not 80. my webpage collect by other's now
Anonymous User - Dec. 17, 2002 4:21 am:
 why port is 8080, not 80. my webpage collected by my frients now
Anonymous User - Jan. 14, 2003 9:15 pm:
 Keep in mind that when you log in, at least in 2.6.0 your user information is CASE SENSITIVE.  :-D

This URL usually works, but you may need to login to a different machine than the one we show you here. To find out exactly which URL to use, look at the logging information Zope prints as it starts up. For example:


------
2000-08-07T23:00:53 INFO(0) ZServer Medusa (V1.18) started at Mon Aug  7 16:00:53 2000
        Hostname: peanut
        Port:8080

------
2000-08-07T23:00:53 INFO(0) ZServer FTP server started at Mon Aug  7 16:00:53 2000
        Authorizer:None
        Hostname: peanut
        Port: 8021
------
2000-08-07T23:00:53 INFO(0) ZServer Monitor Server (V1.9) started on port 8099  

The first log entry indicates Zope is running on a machine named peanut and that the web server is listening on port 8080. This means that the management URL is http://peanut:8080/manage. Later in the book we'll look at the other servers referred to in the logging information.

After you enter Zope's management URL in your browser, your browser will prompt you to log into Zope by providing a user name and password. Type in the initial user name and password created during the install process. If you don't know the initial user name and password, then shut Zope down by closing its window, and change the initial user password with the zpasswd.py script and restart Zope. See Chapter 7, "Users and Security" for more information about configuring the initial user account.

Anonymous User - July 9, 2002 2:04 am:
 I was not able to login,though I remembered the emergency passwd.Even later whne I changed to a new passwd
 refering to "chapter 8 :User SECURITY" still the sytem did not authentify me.What do I do ???
   I am not able to login.What might be the problem..???
Anonymous User - July 9, 2002 8:49 am:
 Describe your problem on the Zope maillist (see Resources link on Zope.org).
Anonymous User - July 31, 2002 9:07 am:
 Molto bello questo meccanismo. FC
Anonymous User - Aug. 1, 2002 2:36 pm:
There is something of an explanation between FAQ.txt.gz and WEBSERVER.txt.gz, which assumes you are accessing
 via cgi-bin, but this has been a chronic problem on some installations directly accessing ZServer (including
 mine). While this paragraph isn't necessarily the right place to deal with the problem, having to join a
 mailing list just to have working regular users is the sort of solution that results in people uninstalling
 the software altogether. It should really be explained in something bundled in the application
 package/tarball documentation.
Anonymous User - Aug. 1, 2002 3:27 pm:
 I told him to visit the maillist because this isn't a place for technical support.. this may be a case of
misunderstanding. I have installed Zope, literally hundreds (maybe thousands) of times, and never once have I
 had this issue. This is so basic that it's almost transparent to me. It just works. So to help, we need more
 info. What browser? What steps did you take to log in?

Controlling Zope with Management Interface

After you successfully login you see a web page of the Zope management interface, as shown in [2-1].

Anonymous User - June 4, 2002 12:12 am:
 In the above line Figure 2-1 should not be shown as link.
Anonymous User - June 23, 2002 10:45 am:
 Because the link leads to wrong position.
Anonymous User - Nov. 21, 2002 1:21 am:
This image is stale and/or not a snapshot of a fresh installation of Zope 2.5.x. This will confuse a new Zope
 user logging in for the first time.

The Zope management interface.

Figure 2-1 The Zope management interface.

Anonymous User - June 4, 2002 12:09 am:
 In the line "After you successfully login you see a web page of the Zope management interface, as shown in
 Figure 2-1"
 Figure 2-1 need not to show as an hyperlink.

The Zope management interface lets you control Zope within your web browser.

Anonymous User - Sep. 20, 2002 8:39 am:
 Maybe better: 
 Management Interface = TopFrame + LeftNavigatorFrame + RightWorkspaceFrame,
 and the TopFrame not subsumized under Workspace?

Using the Navigator

The Zope management interface is broken into three frames. With the left frame you navigate around Zope much like you would navigate around a file system with a file manager like Windows Explorer. This frame is called the Navigator, and is shown in the left frame of [2-1]. In this frame you see the root folder and all of its subfolders. The root folder is in the upper left corner of the tree. The root folder is the "top" of Zope. Everything in Zope lives inside the root folder.

Anonymous User - Sep. 20, 2002 8:48 am:
You don't navigate around "Zope", you navigate through Zopes Object DataBase (glossary: --> ZODB) made out
of
 "Objects". "Folderish" Objects may contain other Objects, while simple Objects do not contain other Objects.

Some of the folders have plus marks to the left of them. These plus marks let you expand the folders to see the sub-folders that are inside.

Anonymous User - Sep. 20, 2002 8:28 am:
 maybe a little bit overdrawn, but: differentation between "Folder" and "folderish object". The Control_Panel
 is folderish, and has an icon with a
 Folder PLUS "a little controller bloke" inside, hence expandable, hence a "+" left to it.
 Also: what is the Folder named "2" in the above image mean? maybe better call it sandbox?

Above the folder tree Zope shows you login information in a frame. In this screen shot you can see that you are currently logged in as "manager". When you log in to Zope you will use the initial user account and you will see the name of this account in place of "manager".

Anonymous User - May 29, 2002 9:37 am:
 `your login information'

To manage a folder, click on it and it will appear in the right-hand frame of the browser window. This frame is called the workspace.

Using The Workspace

The right-hand frame of the management interface shows the object you are currently managing. When you first log into Zope the current object is the root folder, as shown in the right frame of [2-1]. The workspace gives you information about the current object, and lets you change it.

Anonymous User - June 23, 2002 10:51 am:
 It looks like all links to "Figure 2-1" are wrong (sorry).
Anonymous User - Aug. 21, 2002 4:39 am:
 Links to "Figure 2-1" are working well with Netscape� Communicator 4.74.
 Maybe some browser are not interpreting this link as they should.
Anonymous User - Aug. 22, 2002 11:21 am:
 Works fine with Opera 6.04, too.
Anonymous User - Aug. 26, 2002 4:32 pm:
 And IE 5.5

Across the top of the screen are a number of tabs. The currently selected tab is highlighted in a lighter color. Each tab takes you to a different view of the current object. Each view lets you perform a different management function on that object.

In [2-1], you are looking at the Contents view of the root folder object.

Anonymous User - Sep. 20, 2002 8:53 am:
 Which is the default view (manage == manage_workspace == ???). 
 Different views have different URLs, the last path segment always starting with "manage"

At the top of the workspace, just below the tabs, is a description of the current object's type and URL. On the left is an icon representing the current object's type, and to the right of that is the object's URL.

Anonymous User - Sep. 26, 2002 11:12 am:
 questo sito parla di tramezzini
Anonymous User - Jan. 14, 2003 4:04 am:
 Che dici ? Parla di foche e pinguini.

In [2-1] "Folder at /" tells you that the current object is a folder and that its URL is /. Note that this URL is the object's URL relative to Zope's base URL. So if the URL or your Zope site was http://mysite.example.com:8080, then the URL of the "Folder at /myFolder" would be http://mysite.example.com:8080/myFolder.

As you explore different Zope objects, you find that the URLs (as displayed in the management screen), can be used to navigate between objects.

For example, if you are managing a folder at /Zoo/Reptiles/Snakes you can return to the folder at /Zoo by clicking on the word Zoo in the folder's URL.

In the frame at the top of the management interface, your current login name is displayed, along with a pull-down box that lets you select:

Preferences
Here, you can set default preferences for your Zope session, you can even set to hide the top frame.

Logout
Selecting this menu item will log you out of Zope.

Quick Start Links
These are quick links out to Zope documentation and community resources.

Anonymous User - Sep. 20, 2002 8:56 am:
 should be made a subsection of its own and placed right after Fig 2-1

Understanding Users in Zope

Zope is a multi-user system. You've already seen how you can log into Zope via the management interface with the initial user name and password. Zope supports other kinds of users:

Anonymous User - Sep. 20, 2002 9:01 am:
 1) "You've" % "You have"
Anonymous User - Sep. 20, 2002 9:08 am:
 Are "Emergency User", "Manager" and "Owner" actually "Roles" for (more than 1) users?

Emergency User
The emergency user is rarely used in Zope. This account is used for creating other user accounts and fixing things if you accidently lock yourself out.

The emergency user is both very powerful and very weak. It is not restricted by most security controls. However, the emergency user can only create one type of object: Users. Using the Emergency User to repair your Zope system in the case of accidental lock-out is discussed in the Administrator's Guide.

Anonymous User - June 24, 2002 5:55 am:
 The link to the Admin guide points to nowhere. ** This is extremly
 annoying if you really need the emergency user and are an absolute Zope
 beginner ** 
 Yours frustrated 
 Burkhard Neppert
Anonymous User - Aug. 6, 2002 12:30 pm:
 With Opera 6 The link works. The URL of the Admininstrator's Guide is:
 http://www.zope.org/DocProjects/AdminGuide
Anonymous User - Sep. 9, 2002 9:30 am:
 Fine on IE (6)
Anonymous User - Sep. 9, 2002 9:30 am:
 Fine on IE (6) (after a short wait :-)

Manager
The Manager is the Zope workhorse. You will need to log in with the Manager account to do most of the work involved with building Zope web sites. The initial user is a Manager, and you can create as many Manager accounts as you need.
Others
You can create your own kind of users that fit into groups, or are responsible for carrying out a role that you define. This is explained more in Chapter 7, "Users and Security", which discusses Zope security and users.

Creating Users

Managers can create Zope users in a unique kind of folder called a User Folder.

Anonymous User - May 2, 2002 7:32 pm:
 The introduction of this material is premature.
kaleissin - May 16, 2002 12:59 pm:
Not really, but since it's so early, the focus should perhaps be on making test-users in a little sub-tree of
 their own, for a safe place to experiment in so you don't mangle the root-folder. BTDT.
Anonymous User - May 24, 2002 10:38 am:
 I installed Zope < 5 minutes ago. I'm working my way through at least the first part of the book now, and
 found this appropriately placed.
Anonymous User - Sep. 11, 2002 11:54 am:
 It should move into develmpent and implementation before users
Anonymous User - Sep. 20, 2002 9:59 am:
 What is the difference between a "Manager account" and a "Manager user" (see above)?
 Also: Don't "Emergency User" create users?
 Also: Creating Users is about security. 
 Explain: "Access Control List":
 We have a conceptual 2-dimensional Matrix (ie a table), with a _row_ for each User and a _column_ for each
Object. The table cells contain *Permissions*, ie. descriptions of the operations user x is allowed on object
 y. Organizing security as attaching to each user _row_ a list of all objects and her permissions thereon is
 makes a *"capability"*; organizing security as attaching to each object _column_ a list of users and their
 permissions gives an *"Access Control List"*. This is usually large. To fold it up, users are organized as
*roles*. Furthermore, objects are organized treelike the access control list factored out into an *acl_users*
object, such that a user role may *aquire* a permission for the *current object* from acl_users higher up the
 tree.
 Correct me if i am imprecise, but the whole security terminology here is a bit foggy and premature. At least
 a forward ref to a later/deeper chapter? How about a (hyperlinked) glossary?

User folder icons look like folders with a person on them. User folders always have the name acl_users, as shown in [2-1]. The acronym acl stands for "Access Control List".

Anonymous User - July 25, 2002 8:11 am:
 If I have different managers in charge of creating users for a few different divisions within the company,
 can I create different acl_users folder inside different division folders?
Anonymous User - July 25, 2002 9:32 am:
 Yes.  That's the intent.

Click on the acl_users folder in the root folder to enter it. User folders contain User objects. You can create new users and edit existing users. Click the Add button to create a new user, as shown in [2-2].

Anonymous User - Sep. 20, 2002 9:05 am:
 Whats the difference between a "user" and a "role",
 and why are "Manager" and "Owner" introduced in the prose text above as "user"s, when the picture shows the
 as "Roles"?

Adding a new user.

Figure 2-2 Adding a new user.

Anonymous User - June 19, 2002 6:00 pm:
 What is the purpose of the Owner?  It is confusing that only the Manager is mentioned here.

Fill out the form to create a new user. In the Name field put your chosen user name. Choose a password and enter it in the Password and (Confirm) fields. Leave the Domains field blank. This an advanced feature and is discussed in Chapter 7, "Users and Security". Select the Manager role from the Roles select list. Then click the Add button.

Anonymous User - Aug. 26, 2002 3:33 pm:
I agree, I'm a new Zope user, A brief explanation of the owner role or at the very least a reference to where
 I can find info on it would help a lot.

Congratulations, you've just created a manager account. Zope will show you this new manager account inside the user folder. Later you can change or delete this user if you wish.

Changing Logins

To change your login select Logout from the top frame of the management interface. You will be prompted to login again. To change logins, enter a new user name and password.

Anonymous User - May 19, 2002 1:25 pm:
 I selected logout and 3 times it asked for a login username and password. I had previously added a test user
 named bob, password bob. I entered this and the login appeared 3 times and in the end it didn't log me in. I
 have to close my browser and restart to get back in, and only then would it automatically log me in as my
 manager account, without prompting me for a password. I still cannot log in as bob.
Anonymous User - June 12, 2002 10:49 pm:
 The same appears to be happening for me. The client side script that brings up the login window is doing so
 before a refresh has gone through to perform the logout operation (at least that seems to be what's going
 on).
Anonymous User - June 12, 2002 10:50 pm:
 I just posted that I'm having the same problem. I should note that I'm using the latest version of IE6 on
 windows xp.
Anonymous User - June 15, 2002 10:16 am:
 Same here, but it seems to help to cancel the re-login first.
 Furthermore after a successfull re-login the old user is mentioned in the upper frame.
Anonymous User - June 19, 2002 11:25 am:
 Im also using windows xp, i canceled the first re-login and the closed the explorer instance, then i had to
delete the historial and temporary internet files (menu tools->internet options) to log as a different
user.
 Seems this has to do with windows xp dealing by its own with the "user cache".
Anonymous User - July 3, 2002 1:06 am:
All you have to do is logout, then put the cursor in the location bar and hit enter on the /manage url - when
 the box pops up asking for a login and password, type in the new ones.
Anonymous User - July 10, 2002 1:00 pm:
 I have been stepping through this tutorial using Mozilla and Opera running on my linux box  (Mandrake 8.2).
 I experienced exactly the same behavior that is described in the messages above.
 As an experiment, I created a new user in Mozilla and then went over to Opera
to try to login as the new user. When I typed in the /manage URL and pressed <enter> I found myself
logged in
 as the new user with no prompt for a password.
mcdonc - July 10, 2002 2:01 pm:
 I highly doubt that this happened exactly as you describe.

 Try this:

 close mozilla (all windows)
 close opera (all windows)

 1. open mozilla and visit /manage
 2. log in as an existing manager user
 3. create a new account
 4. open opera and visit /manage
 5. log in as the newly created user.

 If at step 4 you are logged in as the user that you created in step 3, the world has finally ended, the
 milennium has come, and we've got larger things to worry about. ;-)
Anonymous User - Aug. 1, 2002 3:07 pm:
 I'd note that if I've logged in as Emergency User in a browser, my experience has been that I cannot log in
 on that browser as a regular user - whether I touch any of the acl_user entries or not. This distinction is
otherwise undocumented, and for new users is a sufficient show-stopper to lead many to uninstall Zope if they
 can't find a clear answer.
A quick observation - the answers given in the June 15 and July 3 messages don't work with my system - I need
 another browser to actually log in as a regular user. From my perspective, if the solutions are this
 inconsistent, then Zope itself needs design work on this point - urgently.
Anonymous User - Aug. 13, 2002 2:36 am:
 Windows 2000 user, Netscape 4.7. I hit the Logout button, and Netscape popped an "authenticate" box. I tried
logging in here, since that seemed like the obvious thing to do, but received "Authentication Failure".
Finally
 I hit cancel, and Zope gave me the message "You have Logged out". I was then able to log in with the new
 user.
Anonymous User - Aug. 26, 2002 3:37 pm:
 "Changing Logins" isn't explicit enough could be interpreted either as "Changing Login Details" or "Login to
 Another Account" perhaps the latter would be a better title
Anonymous User - Nov. 18, 2002 6:39 pm:
 >Anonymous User - May 19, 2002 1:25 pm:
> I selected logout and 3 times it asked for a login username and password. I >had previously added a
test
 user
> named bob, password bob. I entered this and the login appeared 3 times and >in the end it didn't log
me in.
 After login appears I close and click on the browser reload icon (Opera 6.03).
 Bob appers as the login.

To logout select Logout from the top frame of the management interface and cancel the new login. You should see a message telling you that you are logged out. If you try to access the Zope management interface after you are logged out, you'll be prompted to log in again. You can also logout of Zope by quitting your web browser.

Anonymous User - Apr. 23, 2002 1:50 am:
 If you press reload button of the browser, you will find yourself still remain logged in... Is this the same
 to all of you?
Anonymous User - Apr. 26, 2002 4:02 pm:
 I am getting logged out properly using IE 5 for the mac
Anonymous User - May 9, 2002 6:05 pm:
 I'm still logged in if i press reaload or back button.
 Using konqueror.
Anonymous User - May 14, 2002 7:47 am:
 For me it's the same (ie6).

 But: as it was written in an erlier version of this book "to change your login [or log out properly -
 anonymous user = me:)] you must completely exit all instances of your web browser, and then restart your
 browser and login with the new authentification information. [...]since most browsers cache
 authentification."
kaleissin - May 16, 2002 1:19 pm:
 This is because it is not a cookie-login, but the same kind of login you get with ssl and friends. Kinda
annoying if you want to test a weaker-than-Manager user: 1) login as user, test, 2) kill all browser windows,
open new browser, 3) login as powerful-as-a-Manager user, change security-settings and roles on weak user, 4)
 kill all browser windows, open new browser, go to 1)...
Anonymous User - May 24, 2002 10:48 am:
 Fortunately, galeon allows you to kill it, and restore all 
 instances where they were when it was killed, reprompting 
 for a new user and password, making (2) and (4) above 
 rather painless.  :)
Anonymous User - Nov. 25, 2002 7:29 am:
 Some of us just use more than one browser to test with - check security and cross-browser compatability in
 one easy step... (athough I must say, Galeon is one of the best browsers I've used for a while)
 Is there a way to logout via a dtml method or python script? I need to be able to log users out, without
 having to (a) close browsers or (b) use the ZMI. A method containing <dtml-call
expr="AUTHENTICATED_USER.logout()"> doesn't work. I know browsers cache authentication, but I can log out
of
 other session-based secure areas on other sites, so I don't see why Zope can't, in theory, do it.
Anonymous User - Nov. 29, 2002 4:45 am:
 I'm using Zope 2.5.1 (source release, python 2.1, linux2), python 2.1.3, linux2, 2.1.3 (#1, Sep 7 2002,
 15:29:56) [GCC 2.95.4 20011002 (Debian prerelease)] and I still can't login under any of the accounts I have
 created. No matter how many times I halt my browser.

Creating Objects

The Zope management interface represents everything in terms of objects and folders. When you build web applications with Zope, you spend most of your time creating and managing objects in folders. For example, to make a new manager account you create a user object in a user folder.

Anonymous User - Oct. 7, 2002 2:26 pm:
 Hallo

Return to the root folder by clicking on the top left folder in the Navigator frame.

To add a new object to the current folder select an object from the pull-down menu in the right frame labeled "Select type to add...". This pull-down menu is called the product add list.

For example, to create a folder, select Folder from the product add list. At this point, you'll be taken to an add form that collects information about the new folder, as shown in [2-3].

Folder add form.

Figure 2-3 Folder add form.

Type "zoo" in the Id field, and "Zope Zoo" in the Title field. Then click the Add button.

Anonymous User - Jan. 16, 2003 7:19 am:
 It was unclear to me that it was necessary to log out and log in as the user you just created above. Without
 doing so, you won't be able to add a folder. It will give you the error "EmergencyUserCannotOwn". I found an
 examplanation at http://lists.zope.org/pipermail/zope/2001-August/096695.html.

Zope will create a new folder in the current folder. You can verify this by noting that there is now a new folder named zoo inside the root folder.

Click on

zoo

to enter it. Notice that the URL of the folder is based on the folder's id. You can create more folders inside your new folder if you wish. For example, create a folder inside the

zoo

folder with an id of

arctic

. Go to the

zoo

folder and choose

Folder

from the pull-down menu. Then type in "arctic" for the folder id, and "Arctic Exhibit" for the title. Now click the

Add

button. You always create new objects in the same way:

  1. Go to the folder where you want to add a new object.
  2. Choose the type of object you want to add from the pull-down menu.
  3. Fill out an add form and submit it.
  4. Zope will create a new object in the current folder.

Notice that every Zope object has an id that you need to specify in the add form when you create the object. The id is how Zope names objects. Objects also use their ids for their URLs.

Anonymous User - Sep. 5, 2002 4:55 pm:
 Are there any naming restrictions for ids?
Anonymous User - Nov. 20, 2002 2:53 pm:
 See below, under fig 2-4. I agree, it should be moved up here - first instance of it, so get it right the
 first time. -JB

Chapter 3, "Using Basic Zope Objects", covers all of the basic Zope objects and what they can do for you.

Moving Objects

Most computer systems let you move files around in directories with cut, copy and paste. The Zope management interface has a similar system that lets you move objects around in folders by cutting or copying them, and then pasting them to a new location.

To experiment with copy and paste, create a new folder in the root folder with an id of bears. Then select bears by checking the check box just to the left of the folder. Then click the Cut button. Cut removes the selected objects from the folder and places them on a clipboard. The object will not, however, disappear from its location until it is pasted somewhere else.

Anonymous User - June 24, 2002 9:53 am:
 in my case, the folder wasn't removed from the root folder after using 'cut'. it was just removed from the
 root folder after i had pasted it into the subfolder.
 (IE 5.1 for Mac)
Anonymous User - Aug. 8, 2002 10:01 am:
 Can I use a keyboard shortcut like Ctrl-X instead of having to scroll down to the bottom of the screen to
 click on the Cut button?
Anonymous User - Jan. 23, 2003 8:10 am:
 It would be helpful if a folder or object that has been "cut" but not yet "pasted" were shown with some kind
 of modified icon. Right now, you click "cut" and it looks as if you've done nothing.

Now enter the zoo folder by clicking on it, and then enter the arctic folder by clicking on it. You could also have used the Navigator to get to the same place. Now, click the Paste button to paste cut object(s) into the current folder. You should see the bears folder appear in its new location. You can verify that the folder has been moved by going to the root folder and noting that bears is no longer there.

Anonymous User - July 11, 2002 10:48 pm:
 Using Mozilla 1.0, there is no paste button.  Using Konqueror - no problem.  Ugh!
Anonymous User - Aug. 13, 2002 5:33 pm:
 I'm using Mozilla 1.0 Release Candidate 3 on freeBSD and paste butten is there.
Anonymous User - Dec. 10, 2002 7:02 am:
 No prob with chimera under os X.2.2

Copy works similarly to cut. When you paste copied objects, the original objects are not changed. Select the object(s) you want to copy and click the Copy button. Then navigate to another folder and click the Paste button.

You can cut and copy folders that contain other objects and move many objects at one time with a single cut and paste. For example, go to the zoo folder and copy the arctic folder. Now paste it into the zoo folder. You will now have two folders inside the zoo folder, arctic and copy of arctic. If you paste an object into the same folder where you copied it, Zope will change the id of the pasted object. This is a necessary step, as you cannot have two objects with the same id in the same folder.

To rename the copy of arctic folder, select the folder by checking the check box to the left of the folder. Then click the Rename button. This will take you to the rename form as shown in [2-4].

Renaming an Object

Figure 2-4 Renaming an Object

Type in a new id "mountains" and click OK. Zope ids can consist of letters, numbers, spaces, dashes underscores and periods, and are case-sensitive. Here are some legal Zope ids: index.html, 42, and Snake-Pit.

Anonymous User - Jan. 23, 2003 8:14 am:
 Say this above, when you first ask the reader to enter an id ("zoo").

Now your zoo folder contains an arctic and a mountains folder. Each of these folders contains a bears folder. This is because when we made a copy of the arctic folder it also copied the bears folder that it contained.

If you want to delete an object, select it and then click the Delete button. Unlike cut objects, deleted objects are not placed on the clipboard and cannot be pasted. In the next section we'll see how we can retrieve deleted objects.

Zope will not let you cut, delete, or rename a few particular objects in the root folder. These objects include Control_Panel, standard_html_header, standard_html_footer, and standard_error_message. These important objects are necessary for Zope's operation. Also, these operations don't work in some cases. For instance, you can't paste a user object into a regular folder.

Anonymous User - June 15, 2002 10:11 am:
 I'm using Zope version 2.5.1 and I am allowed to delete the mentioned objects.
Anonymous User - Aug. 17, 2002 10:51 pm:
 Well don't, then.
Anonymous User - Oct. 18, 2002 4:07 am:
 LOL

If you are having problems with copy and paste, make sure that you have enabled cookies in your browser. Zope uses cookies to keep track of the objects that you cut and copy.

Anonymous User - Sep. 4, 2002 12:16 am:
 Maybe mention this at the start of the whole section ... I scratched my head for a minute or two before I
 figured out (on my own) what the problem was. This comment would have nudged me in the right direction
 quicker.

Undoing Mistakes

Any action in Zope that causes objects to change can be undone, via the Undo tab. You can recover from mistakes by undoing them.

Anonymous User - Jan. 23, 2003 8:24 am:
 This is a very helpful feature, and it's interesting that the undo list depends on the folder structure. At
 the root folder, I could undo anything. Within new folders, I could only undo actions taken there. You might
 explain this.

Select the zoo folder that we created earlier and click Delete. The folder disappears. You can get it back by undoing the delete action.

Click the Undo tab, as shown in [2-5].

The Undo view.

Figure 2-5 The Undo view.

Anonymous User - Sep. 1, 2002 2:03 pm:
 Ok. I'm using freezope. Using the tutorial. Browsing with Mozilla 1.1. 

 Why don't I have an undo tab?

Select the first transaction labeled /manage_delObjects, and click the Undo button.

Anonymous User - Sep. 24, 2002 5:59 am:
 Because it's disabled at freezope - the undo implementation is very inefficient and hugely degrades the
 performance of the freezope server

This action tells Zope to undo the last transaction. You can verify that the task has been completed by making sure that the Zoo folder has returned.

Anonymous User - May 24, 2002 11:00 am:
 Add:
 Click refresh in the folder navigation menu, or click on the
 root folder to see the effects of the undo operation.

Undo Details and Gotchas

Undo works on the object database that Zope uses to store all Zope objects. Changes to the object database happen in transactions. You can think of a transaction as any change you make to Zope, such as creating a folder or pasting a bunch of objects to a new place. Each transaction describes all of the changes that happen in the course of performing the action.

You cannot undo a transaction that a later transaction depends upon. For example, if you paste an object into a folder and then delete an object in the same folder you might wonder whether or not you can undo the earlier paste. Both transactions change the same folder so you can not simply undo the earlier transaction. The solution is to undo both transactions. You can undo more than one transaction at a time by selecting multiple transactions on the Undo tab and then clicking Undo.

Another problem to be aware of is that you cannot undo an undo. Therefore if you add a folder and then undo that particular action, you cannot get the new folder back by undoing the undo.

Anonymous User - May 14, 2002 4:44 pm:
Actually, this is not true. You can undo undos, though to what extent I am not sure. As a test, I did exactly
 what this point talks about and added a folder. I was able to undo the addition (removing the folder), undo
 the undoing of the addition (restoring the folder), and then further undo that undoing (removing the folder
 once again). The only limit with simple operations like this would appear to be the disk space required for
 archiving the transactions.
mcdonc - May 23, 2002 8:14 am:
 Right.  This is actually incorrect.  In Zope 2.5+, undos are undoable.
Anonymous User - June 19, 2002 4:28 pm:
 which is basically Redo

One last note on undo. Only changes to objects stored in Zope's object database can be undone. If you have integrated data in a relational database server such as Oracle or MySQL (as discussed in Chapter 12, "Relational Database Connectivity") changes to data stored there cannot be undone.

Administering and Monitoring Zope

The Control Panel is an object in the root folder that controls various aspects of Zope's operation.

Click on the Control_Panel object in the root folder, as shown in [2-6].

Anonymous User - May 19, 2002 1:35 pm:
 I don't have a control panel in my root folder!!!! Only acl_users and general!!! wtf??
Anonymous User - May 19, 2002 1:55 pm:
 You are probably using Zope on a site like Freezope or another hosting provider. You do not have a
Control_Panel in this case because you have a view of only a part of the Zope object hierarchy, which doesn't
 include the real root folder.

The Control Panel

Figure 2-6 The Control Panel

To shutdown Zope, click the Shutdown button. Shutting down Zope will cause the server to stop handling requests and completely exit from memory. You will have to manually start Zope to continue using it. Only shutdown Zope if you are finished using it, and have the ability to access the server on which Zope is running, so that you can manually restart it later.

Anonymous User - May 30, 2002 5:44 pm:
 I have installed Zope 2.5 on a WinNT4 and Win2000. On both machines I get the tracebacks further down below.
Today I downloaded Zope 2.5.1 and installed it on my Laptop with Win2000. The same error appears again. Is it
 only me having this problem? Is this the usual message, when the server shuts down?
 On one hand it says: An error was encountered
 and on the other hand: Zope has exited normally.
 What is true now? If it is a "normal" behaviour - a remark would be fine.

 An error was encountered while publishing this resource. 

 exceptions.SystemExit

 Zope has exited normally.

 Traceback (innermost last):
   File C:\PROGRA~1\ZOPEWE~1\lib\python\ZPublisher\Publish.py, line 150, in publish_module
   File C:\PROGRA~1\ZOPEWE~1\lib\python\ZPublisher\Publish.py, line 114, in publish
   File C:\PROGRA~1\ZOPEWE~1\lib\python\ZPublisher\Publish.py, line 98, in publish
   File C:\PROGRA~1\ZOPEWE~1\lib\python\ZPublisher\mapply.py, line 88, in mapply
     (Object: manage_shutdown)
   File C:\PROGRA~1\ZOPEWE~1\lib\python\ZPublisher\Publish.py, line 39, in call_object
     (Object: manage_shutdown)
   File C:\PROGRA~1\ZOPEWE~1\lib\python\App\ApplicationManager.py, line 342, in manage_shutdown
     (Object: Control_Panel)
 SystemExit: 0

 Troubleshooting Suggestions

 The URL may be incorrect. 
 The parameters passed to this resource may be incorrect. 
 A resource that this resource relies on may be encountering an error. 
 For more detailed information about the error, please refer to the HTML source for this page. 

 If the error persists please contact the site maintainer. Thank you for your patience.
Anonymous User - May 30, 2002 7:29 pm:
 This is normal. Zope exits by raising an exception. This is propagated to the browser. Nothing to be scared
 of. ;-)
Anonymous User - May 31, 2002 2:36 am:
 But this behaviour should be pointed out in the text... tracebacks make you feel uncomfortable. Please add a
 sentence or a paragraph on this - it made me so insecure that I installed Zope on three different system.
Anonymous User - Aug. 22, 2002 4:23 am:
 I second this
Anonymous User - Sep. 12, 2002 4:58 am:
 I third it. So *that* was the problem....

If you are running Zope on UNIX under daemon control or as a service on Windows, you can restart Zope from the control panel folder. Clicking the Restart button will shut down Zope and then immediately start up a new instance of the Zope server. It may take Zope a few seconds to come back up and start handling requests.

On the control panel you will also see several links at the bottom of the screen, one of which is Database Managment, which controls Zope's object database.

Anonymous User - Sep. 5, 2002 5:17 pm:
 Misspelled "Database Managment".

Transactions don't go away until you pack the Zope database. This means that you can undo all transactions except ones that have been removed by packing the database. When you choose to pack the database you can specify which transactions to remove so that you can for example only remove transactions older than a week.

Using the Help System

Zope has a built in help system. Every management screen has a help button in the upper right-hand corner. This button launches another browser window and takes you to the Zope Help System.

Anonymous User - Jan. 23, 2003 8:27 am:
 "built-in"

Go to the root folder. Click the Help button, and you should see what is shown in [2-7].

Anonymous User - June 23, 2002 11:29 am:
 The links to Figure 2-7 are incorrect (just like Figure 2-1).

The Help System.

Figure 2-7 The Help System.

The help system has an organization similiar to the two primary panes of the Zope management interface, it has one frame for navigation and one for displaying the current topic.

Whenever you click the help button from the Zope management screen, the right frame of the help system displays the help topic for the current management screen. In this case, you see information about the Contents view of a folder.

Browsing and Searching Help

Normally you use the help system to get help on a specific topic. However, you can browse through all of the help content if you are curious, or simply want to find out about things besides the management screen you are currently viewing.

The help system lets you browse all of the help topics in the Contents tab of the left-hand help frame, as shown in [2-7]. You can expand and collapse help topics. To view a help topic in the right frame, click on it.

All help on the Zope management screens is located in the Zope help folder. Inside you'll find many help topics. You'll also find a help folder called API Reference. This folder contains help on scripting Zope, which is explained further in Chapter 9, "Advanced Zope Scripting".

When you install third-party components they also include help that you can browse. Each installed component has its own help folder.

hansa - Sep. 20, 2002 10:21 am:
 well, in the rare instance when the product writer took care to provide help

Search the help system by clicking on the Search tab and entering one or more search terms. For example, to find all of the help topics that mention folders, type "folder" into the search form.

Starting with the Zope Tutorial

Zope comes with a built-in tutorial. The tutorial guides you through all the basics of creating and managing Zope objects. To launch the tutorial, add a Zope Tutorial to the current folder by selecting Zope Tutorial from the Product add list. Give it an id which is unique in the current folder, such as tutorial. The tutorial comes with several examples that you can change and copy for your own use.

Anonymous User - May 19, 2002 1:45 pm:
 ps - Guess I've discovered a need to re-install the tutorial....
Anonymous User - May 19, 2002 1:49 pm:
 How do I start the tutorial exactly?? All I see is a bunch of tutorial examples in folders. What button are
 they referring to to start the tutorial?
Anonymous User - May 23, 2002 6:16 am:
 You can click on the 'help!' link when you're in the root folder. From there you 
 can follow the Tutorial link, in the navigation window. 

 A problem I have actually, is that it's complaining it can not find the Tutorial 
 Examples. But I did install/import them, and I see the examples residing in 
 the help folder and the tutorial is working as far as I can concern. 

 Greetings Blurg
Anonymous User - May 24, 2002 8:29 am:
 I had that same problem with the tutorial examples. I noticed that if I reinstalled the tutorial with an id
 not containing white spaces, everything was ok.
 To start the tutorial, you can also open file index_html from the tutorial folder and click on the "view"
 tab.
Anonymous User - May 30, 2002 6:13 pm:
 What I don�t understand and you might clarify this point: Why do I have to "add" tutorial to some folder...
 Why not use the one in the cont... Wait, I think I get it:
 Folder: /Control Panel/Products

 Hosts the "templates/products" which appear afterwards (some magic included) in the "Product add list". Eg.
 The product/template "MailHost (Installed product MailHost (MailHost-1-2-0))" in /Control Panel/Products
 corresponds to the "Product add list"-entry: Mail Host.
 Same applies to the template/product: ZopeTutorial (Installed product ZopeTutorial (Zope Tutorial 1.0)) - It
 can be put into action when inserted via the "product add list". Okay, finally I understand the mechanism...
 I think...
Anonymous User - May 31, 2002 6:04 am:
 Why not explaining the products/templates in the section
 - Administering and Monitoring Zope + Fig. 2.6
 And show the connection between the "Product Folder" and the "Product Add List".
Anonymous User - June 20, 2002 10:26 am:
 Tutorials are working fine for me... except for #11. The database connection is closed... When I click to
 connect, I get:
 "Invalid connection string: Demo"

 How do I fix this?
Anonymous User - Aug. 8, 2002 5:49 am:
 I cannot get the tutorial to work, tried all the above but I keep getting a
 message telling me to install the examples.
 I tried to run the tutorial fron the help folder but I get an error message when creating the first Elvis
 Lives page
 Error Type: KeyError
 Error Value: header.gif
RhoXS - Aug. 18, 2002 9:27 am:
 I'm a total Zope Newbie...

 I'm trying to run the tutorials as instructed, but am getting this message:

 Site Error

 An error was encountered while publishing this resource. 

 Error Type: Bad Request
 Error Value: File does not exist: ZopeTutorialExamples.zexp

 I installed using a package for Mac OS X. Where can I get these files and how do I install them?

If you start the tutorial and want to stop using it before you have completed all the lessons, you can later return to the tutorial. Just go to the help system and find the lesson you'd like to continue with by browsing the Zope Tutorial help folder. There is no need to re-install the tutorial.

Anonymous User - May 19, 2002 1:44 pm:
This is driving me F&*King NUTS! So I go to the tutorial/examples folder (there's nothing in tutorial
except
 examples). It shows me a window with what appears to be the code for the intro... it says "click on the
button below". All I see is Save Changes, Taller, Shorter, Narrower, Wider and Upload File. I clicked on Save
 Changes, nothing happened. The 4 size buttons just resized the window. Finally I clicked on upload file and
 the text disappeared. Unbelievable. So in the previous section I learned about Undo... except there's no
 F&*King UNDO!!!!!!!!!!!!!!!!!!!!!!!
Anonymous User - May 23, 2002 6:10 am:
 Keep your head cool. and don't mess up this book with screaming.
 Try IIS or something, Zope's probably not for you, or go to bed, lots of people 
 don't get the picture anymore when it's 1:44pm, that's quite normal.
Anonymous User - May 23, 2002 6:20 am:
 Also,
 In addition to my answer, I want to say, if you're asking for help and like to 
 have an answer, do not irritate people, and try to read again and stop when you 
 understood the things explained.
 Anyway, you can start the tutorial from the 'help!' link in the root folder level.

 Greetings Blurg
Anonymous User - June 20, 2002 4:09 pm:
 It is easy to boot the tutorial.

 1) Go to Tutorial:examples from within the management interface
 2) Click the View tab.  You will see a welcome page with a "Begin Tutorial" button.
3) Click the "Begin Tutorial" button. A help page will pop up from which you can proceed with the tutorial.
Links
 in that help page pull tutorial content into the page you just came from.
RhoXS - Aug. 18, 2002 9:32 am:
 The crux of many of our problems is that we don't have have these examples installed. How do we get them?

 Tx, Rho
Anonymous User - Aug. 19, 2002 12:32 am:
In the management interface, left hand pane, click 'Root Folder'. Now in the right hand pane select, from the
'Select type to add' dropdown, 'Zope Tutorial'. The tutorials will now install. Go back to 'Help' and you can
 now run through the tutorials.
Anonymous User - Aug. 28, 2002 3:56 pm:
 I just plain can't get this to work. Is it because I'm using a free zope server (nipltd.net)? I get the same
 problem that many others are having. I can install the tutorial and read the tutorial launch page. It
 launches the help system, but every time I click on a lesson it says it can't find the tutorial:
 "
 Lesson 1. "Elvis Lives" Home Page

 Zope cannot find the tutorial examples. You should install the tutorial examples before continuing. Choose
 "Zope Tutorial" from the product add list in the Zope management screen to install the examples.
 If you have already installed the tutorial, you can either follow along manually, or reinstall the tutorial
 examples. Note: make sure that you have cookies turned on in your browser.
 "
 I've deleted and reinstalled this and still the same. I think it's because the tutorial in my case is
 installed into something other than the root folder. Somehow the tutorial is looking for things in the root
 folder and doesn't know where it is installed. This is a show stopping-error which seems really silly.
Anonymous User - Oct. 23, 2002 6:43 pm:
 You can re-install the Zope Tutorial Product until doomsday...and the Help Instructions will not link to
 it...you can navigate manually to the Examples to do them, but the Help system is typically flawed...this is
 one of the mysteries of Zope that the Zope upper elite like to dis Newbies with, to make them feel
 incompetent and to inexplicably give Open Source support a bad name.
Anonymous User - Dec. 31, 2002 7:18 pm:
 I am not sure if it was the space, but I installed the Zope Tutorial once with an ID of 'Zope Tutorial', and
 the tutorial failed (it said that I needed to get the zope examples). I removed the tutorial and added it
 again with the ID of 'zopeTutorial', and then the tutorial worked, where I was presented with a 'next'
 button.
Anonymous User - Jan. 4, 2003 7:37 pm:
 Hi,
 I am also getting the message "File does not exist: ZopeTutorialExamples.zexp"
 I installed zope as part of a plone install for Windows platform - I cannot find the zexp file anywhere on
 this disc.install.
 I have fixed this by downloading the zope src (2.6.0), unzipping/tarring and extracting the
 ZopeTutorialExamples.zexp file from it.
 Then, having created a subdirectory in windows called import, below my zope directory I copied te file to
 there.
 Now when I "Add" a tutorial object, it works ok.
 Hope this helps
 AJM

If you are having problems with the tutorial, make sure to enable cookies in your browser. The tutorial uses cookies to keep track of where your example objects are. Also, if you enable Javascript in your browser, the tutorial will make sure that the Zope management interface stays in sync with your tutorial lesson.

Now that you have Zope running, it's time to explore the system more thoroughly. You've seen how to manage Zope through the web and have learned a little about Zope objects. In the next chapter you'll meet many different Zope objects and find out how to build simple applications with them.

Anonymous User - Aug. 7, 2003 8:05 am:
 Just to inform.
 I have just succeded in compile and install python 2.1 and Zope 2.6.1
 in a zLinux Red Hat 7.2.
 This is an IBM mainframe running Red Hat for S390 under VM.
 Pretty stright forward, no problems so far, besides the normal messing
 around with secirity, sticky bit and the like.
 I will now start to use it, which first includes some manualreading.
 /Tore Agblad  Sweden

Previous Page Up one Level Next Page Using Zope Comments On/Off Table of Contents