This shows you the differences between two versions of the page.
tools:joomla [2008/02/19 16:01] axelle created |
— (current) | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ====== Joomla ====== | ||
- | //This article explains how to transfer a local Joomla website onto Free.fr. Basically, it's just the same as what's already written for [[http://fr.wikipedia.org/wiki/Wikip%C3%A9dia:Installation_du_logiciel#Installation_sur_free.fr|MediaWiki]] ... except it's for Joomla :)// | ||
- | |||
- | I'm using Joomla's 1.5 beta version and PHP5. | ||
- | |||
- | ====== Transfer the Joomla database to Free ====== | ||
- | |||
- | Export your Joomla database to a gzipped filed (Free doesn't seem to recognize the zipped format): | ||
- | |||
- | * connect locally to http://localhost/phpmyadmin/ | ||
- | * on the left panel, select your Joomla database | ||
- | * on the right panel, click on Export | ||
- | * then, select all tables | ||
- | * Finally click on "Go" | ||
- | |||
- | Then, transfer this file to your own MySQL Free database: | ||
- | |||
- | * With your web browser, connect to http://sql.free.fr with your Free logon and password. You get to a simplified PhpMyAdmin web page. | ||
- | * click on your name (on Free, this actually is the name of your database) | ||
- | * click on "SQL" | ||
- | * browse to your gzipped file, and click on "Go" | ||
- | * all Joomla tables are loaded in your own Free database. | ||
- | |||
- | ===== Modify Joomla's configuration.php file ===== | ||
- | |||
- | On Free, your MySQL server is sql.free.fr. Your database name is your logon name, except dots are replaced with underscores. If your logon is "foo.bar", your database name is "foo_bar". The password to this database is the same as your Free password. | ||
- | |||
- | Consequently modify the following setting in configuration.php: | ||
- | <code> | ||
- | var $host = 'sql.free.fr'; | ||
- | var $user = 'foo.bar'; | ||
- | var $password = 'passwd'; | ||
- | var $db = 'foo_bar'; | ||
- | </code> | ||
- | You must also modify the absolute path to your website. On Free, retrieving the root of your own website is possible with the formula: $_SERVER["DOCUMENT_ROOT"]. Append to this name the subdirectories you have put your Joomla website into (or none if your Joomla website is at the root of your site). | ||
- | |||
- | <code> | ||
- | var $live_site = 'http://yourwebsite.free.fr'; | ||
- | var $absolute_path = '$_SERVER["DOCUMENT_ROOT"]'.'/your path'; | ||
- | </code> | ||
- | |||
- | ===== FTP transfer ===== | ||
- | |||
- | Transfer all your local Joomla files to your FTP account: connect to ftpperso.free.fr with your free login and password, and upload the entire Joomla directory. | ||
- | |||
- | In addition, don't forget, on Free, to create a "sessions" directory (permissions: drwx------), or you won't be able to initiate a PHP session. | ||
- | |||
- | ===== Joomla Security settings ===== | ||
- | |||
- | Well, at this stage, it's only very basic security settings... | ||
- | |||
- | In the administrator directory of Joomla (or in any directory you wish to protect), create an .htaccess file with the following: | ||
- | <code> | ||
- | PerlSetVar AuthFile yourpath/password-file | ||
- | |||
- | AuthName "Acces Restreint" | ||
- | |||
- | AuthType Basic | ||
- | |||
- | require valid-user | ||
- | </code> | ||
- | |||
- | This .htaccess requires correct user authentication to access the corresponding directory. By the way, Free's help is wrong: PerlSetVar and AuthFile MUST be on the same line or your .htaccess file won't work ! | ||
- | |||
- | If you want to restrict access to a particular user, use rather: | ||
- | <code> | ||
- | PerlSetVar AuthFile yourpath/password-file | ||
- | |||
- | AuthName "Acces Restreint" | ||
- | |||
- | AuthType Basic | ||
- | |||
- | require user martin | ||
- | </code> | ||
- | In 'your path' (the place where you've indicated the password file would be), create a password file such as: | ||
- | <code> | ||
- | martin:PasSw0rd | ||
- | jean:SecR3t | ||
- | sophie:H1dDeN | ||
- | </code> | ||
- | i.e username followed by ':' and then by a clear text password ! Yes, currently Free doesn't not support other authentication modes. | ||
- | |||
- | Finally, in that directory ('your path'), create an other .htaccess containing: | ||
- | <code> | ||
- | deny from all | ||
- | </code> | ||
- | so that nobody can move to that directory ;-) | ||
- | |||
- | ===== Joomla backup ===== | ||
- | |||
- | <code> | ||
- | mysqldump -u <username> -p <database> > blah.sql | ||
- | |||
- | mysql -u USER -p <database> < dumpfilename.sql | ||
- | </code> | ||
- | |||
- | With Free.fr, MySQL tables can be backuped using [[http://sql.free.fr/backup.php|this URL]]. |