Project-Id-Version: Trac 0.12
POT-Creation-Date: 2008-01-30 09:20+0100
PO-Revision-Date: 2010-07-19 23:05+0200
Last-Translator: Jeroen Ruigrok van der Werven <>
Language-Team: en_US <>
Plural-Forms: nplurals=2; plural=(n != 1)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Generated-By: Babel 0.9.6

Warning: Can't synchronize with repository "(default)" (Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? ). Look in the Trac log for more information.

Version 8 (modified by sebastian, 8 years ago) (diff)

Improve file permission command

This installation procedure describes the installation within your home directory ~/public_html on a shared LAMP system. After downloading and prepared the phTagr must be initialized which is described in SetupProcedure. Please read the SoftwareRequirements before installing!

The given installation examples are based in on Ubuntu 9.04 but works similar on other system, too.

See also:

Your database

Usually you got a database from your admin if you install phTagr in you user directory. If not, your admin should create one for you!

$ sudo mysql -u root
mysql> GRANT ALL ON phtagr.* TO 'phtagr'@'localhost' IDENTIFIED BY 'secretpassword';
mysql> quit

Download and prepare phTagr

Download the latest version of ZIP archive from SourceForge (which is around 3.2 MB). This includes the cakePHP MVC framework and phtagr.

cd ~/public_html

Now your folder structure looks like this:

    /cakephp     <-- CakePHP framework
    /config      <-- Basic configuration path
        /core.php      <-- Basic core configuration file
        /database.php  <-- Database configuration file (can be created automatically)
    /users       <-- Directory of your user's files, photos, videos, cached previews, ...
    /tmp         <-- Directory for log files, cache files, ...
    /webroot     <-- Directory of public files like javascript, css, images
       .htaccess       <-- Redirection settings for apache
    .htaccess    <-- Redirection settings for apache

Adjust Redirection

If your server supports redirection you have to add a RewriteBase directive to get the redirection working. If not, please read the subsection below.

Add the RewriteBase to ~/public_html/phtagr/.htaccess

<IfModule mod_rewrite.c>
    RewriteEngine on
    RewriteBase /~YOUR_NAME/phtagr
    RewriteRule ^$   webroot/   [L]
    RewriteRule (.*) webroot/$1 [L]

# Upload Limit of 128 MB LimitRequestBody? 134217728 }}}

Add the RewriteBase to ~/public_html/phtagr/webroot/.htaccess

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /~YOUR_NAME/phtagr/webroot
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^(.*)$ index.php?url=$1 [QSA,L]

Open now phtagr at your server http://YOUR_SERVER_URL/~YOUR_NAME/phtagr, which should open the setup page. Continue with the SetupProcedure.

No Rewrite

If you dont see anyting the modifications in the .htaccess, the redirction is disabled or your are not allowed to change settings in .htaccess. But no panic! There is a solution!

From cakePHP's book If you don't want or can't get mod_rewrite (or some other compatible module) up and running on your server, you'll need to use Cake's built in pretty URLs. In /config/core.php, uncomment the line that looks like:

Configure::write('App.baseUrl', env('SCRIPT_NAME'));

Now you should be able to open your side at your server http://YOUR_SERVER_URL/~YOUR_NAME/phtagr/webroot/index.php, which should open the setup page. Continue with the SetupProcedure.

Note: If your rewrite does not work, the files of the users are not protected and are readable by the world! You should move phtagr's files to another location, copy the webroot to your user directory and configure properly the settings in the index.php.

No suPHP

If your server does not run with suPHP (your scripts are executed with your system rights), you need to make some folders accessible for the web server. The directories (and all subdirecoties of ~/public_html/phtagr/config, ~/public_html/phtagr/tmp and ~/public_html/phtagr/users) must be writable or should be owned by the apache process.

Usually the apache runs as user www-data in Debian/Ubuntu.

$ cd && cd public_html/phtagr
$ sudo chown -R www-data tmp users config

If you cannot modify the permissions of config, tmp and users directory in phTagr make it at least readable for the world:

$ cd public_html/phtagr
$ chmod -R go+w config users tmp

Now open http://YOUR_SERVER_URL/~YOUR_NAME/phtagr, which should open the setup page. Continue with the SetupProcedure