JoeJoomla News

Joomla 1.5 and MAMPOne of the best ways to develop Joomla! websites on your personal Mac computer is using MAMP. MAMP is an application that provides all the resources needed to run a content management system. Once you download MAMP to your computer you can install as many Joomla! sites as you have hard drive space for and do all your development and experimenting in this safe environment just as if it was on a live server.

During the installation of Joomla! you are given the option of enabling the FTP layer of Joomla!. You can simply skip this step and Joomla! will run without it. If you want to enable the FTP layer it can be a little confusing what the proper settings are for it in the Joomla! configuration settings of your MAMP localmachine website.

 

So what is the FTP layer of Joomla! intended for? The FTP layer in Joomla! is there because some web hosting services don't give customers the ability to change owner permissions of files and directories when needed, and for users having the PHP safe_mode setting on. The FTP layer in Joomla! is only for sites hosted on Linux and does not apply to sites that run on Windows servers.

FTP is an acronym for File Transfer Protocol. It is one of the most popular ways to transfer files between computers on a network, such as the Internet. Since an FTP host name or number is required along with a username, password, and port number, the server permits FTP to upload folders and files to install things for your site. On your localmachine Joomla! and MAMP website you have easy access to all the directories on your computer. This makes it easy to put files and folders where you want them in the Joomla! install. It is nice, however, to have the FTP layer enabled on your localmachine Joomla! site especially when you want to run things from inside the Joomla! administrator back end the way you would on a live server.

The settings for enabling the FTP layer in a Joomla! and MAMP website are very different than the settings for a live web server. Let's look at the FTP Settings in Joomla! for the MAMP website:

Joomla FTP Settings

FTP Settings

Enable FTP No Yes - This is an easy one, just set the radio button to 'Yes'

FTP Host - This is for the IP address of your computer. It will be something like 192.168.1.4. In order to find out what your Mac OS X IP address is Open the Network settings of your System Preferences, click on the 'Advanced...' button, and then the TCP/IP tab. There you will see the 'IPv4 Address: xxx.xxx.x.x This is the number that you want to put in the FTP Host field. Another simple way to find the IP address of your computer is to click on the apple icon on the top left of your Finder bar, and go to 'About This Mac', click on the 'More Info...' button which opens the System Profiler application. In the left column click on the word 'Network' and on the right side you'll find the IPv4 Address.

FTP Port - This should be port 21. Port 21 is the standard port for FTP.

FTP Username - Here's where most people get tripped up when it comes to the Joomla! and MAMP website. In this field you are going to input the short name of the Username for your computer account. This is the name of your 'Home' folder. Open a window in the Finder. See that little house icon in the left sidebar of the window? The name beside it is your short user name. This is the name that you put in the FTP Username field. If you don't see a left bar in the Finder window, click on the button at the right top of the Finder window and it should appear. Usually when you make a new Finder window the window opens in your 'Home' directory. The short username of the account is at the top of the window beside the house icon.

FTP Password - In the Joomla! and MAMP version of your website your computer password goes in this field. This is the password that you use to login to your computer with. It needs to be the one that is used with the short username of your user account.

FTP Root - The path to your Joomla! and MAMP website will be '/Applications/MAMP/htdocs/your-website-folder-name' (without the quotes). You also need to change 'your-website-folder-name' to the name of the folder that the Joomla! website resides in. This is the Joomla! folder inside the 'htdocs' folder of MAMP.

Alternately you can also input this information directly into your 'configuration.php' file in the Joomla! install. Here's how you would do it:

Let's use some dummy information for this example. Say the following is the setting information for the FTP layer:

Enable FTP - Yes
FTP Host - 192.168.1.4
FTP Port - 21
FTP Username - joomlahottie
FTP Password - mybigfatcomplexpassword
FTP Root - /Applications/MAMP/htdocs/CoolSite

Make sure that the permissions on the file 'configuration.php' allow you to make changes to it and put the information directly into the file as follows. Remember to put your own information into it, this information is just an example.

var $ftp_enable = '1';
var $ftp_host = '192.168.1.4';
var $ftp_port = '21';
var $ftp_user = 'joomlahottie';
var $ftp_pass = 'mybigfatcomplexpassword';
var $ftp_root = '/Applications/MAMP/htdocs/CoolSite';

Now you know how to enable the FTP layer inside your Joomla! and MAMP install!