Development Tools

Restoring a Backup of Your Website

A Bit about Backups

television icon 64x64pdf icon 64x64There are many reasons to take a backup of your Website. These include for data integrity, testing and much more. However, just making a backup is not enough. A backup is no backup at all unless you go through the work to make sure that the backup you have will in fact restore something back to the state in which you were backing up for to begin with.

In the last tutorial I demonstrated how to do a full backup of your Joomla website using and extension called Akeeba Backup. I also showed you where the backup files were stored in Joomla in the event you wanted to take the safe route of FTPing the file rather than taking a chance of the file being corrupted by downloading it with the browser.

At this point I assume that you have your backup and it needs to be tested. Testing the restore on you site could be a disaster if the backup was bad and you were half done with it. So to test our backups we will create an additional virtual host to test them in. Let’s get started.

Create a new virtual host.

Let’s start by opening a terminal with [CTRL][ALT][T] and changing to the directory that apache uses to hold the virtual sites. You can do this by issuing the following command.

cd /etc/apache2/sites-available

Now that we are in the folder that holds the virtual hosts, lets save a little typing by copying our virtual host to another file. We are going to call this site and remember that the file has to end with the .conf extension. You can make a copy of the file with the following command.

sudo cp ./

With the new file created, we need to edit it to reflect our new virtual host. Open the file for editing with the following command.

sudo nano

Now we need to make some changes to the file. With the nano editor, change the file so that it looks like the one below.

<VirtualHost *:80>
DocumentRoot /home/joeh/Desktop/backupdev/

<Directory /home/joeh/Desktop/backupdev/ >
Options Indexes FollowSymLinks
AllowOverride All
Require all granted

LogLevel info
CustomLog ${APACHE_LOG_DIR}/ combined

You will notice, that we changed all instances of the work joom to backup. With these changes made, we need to save the file. To do so, press [CTRL][X] to exit, [Y] to save the buffer and then the enter key to save the changes to the file.

With the virtual host file created we need to create the folder that the site will live in. Looking back up at the virtual host file, you see that we said it would be on the desktop in a folder called backupdev. Let’s create that folder now with the following command.

mkdir ~/Desktop/backupdev

That takes care of that. Next we need to enable the virtual host so that apache can find it. We can do that with the following command.

sudo a2ensite

Apache should have informed you that it is enabling the site and that the configuration needs to be reloaded before the changes can take effect. To restart apache enter the following command.

sudo service apache2 restart

Now that apache has been restarted we are almost done. Next we need to give it some means of resolving the name to the local machine. We can do this exactly the same as we did last time by making another entry in the hosts file. Open up the hosts file for editing by issuing the following command.

sudo nano /etc/hosts

With the hosts file opened up for editing, add the following line under your lien in the file.

Now we need to save the file. Do so by pressing [CTRL][X] to exit [Y] to save the buffer and the enter key to save the file.

Everything is in place for the new virtual host except for creating test index.html file to test out the virtual host with so let’s do that now. Create a index.html file in the backupdev folder by issuing the following command

touch ~/Desktop/backupdev/index.html

The touch command will create an empty file. Now let’s open the file and write a simple html webpage to test with. Open the file for editing by entering the following command.

nano ~/Desktop/backupdev/index.html

With the file opened up for editing, write the following HTML code.

<title> Test</title>
<h2>Backup Testing Site</h2>
<p>This is a test of the site for backup testing.</p>

Save the file as above by pressing [CTRL][X] to exit, [Y] to save the buffer and the enter key to save the file.

Everything should now be in place to use the new virtual host. To test our work, open your browser and point it to If all went well you should have a web page that looks something like the image below.

013 001 Virtual Host

Getting Akeeba Kickstart

In oder to do a site restore we need some more software from Akeeba called Akeeba Kickstart. Open you browser and point it to When you land on their front page you will see a box titled Akeeba Kickstart. Click this box to go to the download page.

When you arrive at the download page, you will want to download the Core software. Do so by clicking the button and saving the file to your computer. See the image below.

013 002 Akeeba Website

With the file saved we have all the tools we need to do the site restore, we have the Kickstart software and the JPA backup file we saved from Akeeba Backup.

Doing a Site Restore

To do a site restore we only need to extract the kickstart archive and copy our backup to the backupdev folder we created earlier and create a database for our backup to use, then finally run the kickstart application, so let’s get going.

Creating the database

Our restored site will need a database set up to restore to. We obviously do not want to use the database we created for our site, so let’s create a new one. Open phpMyAdmin in your browser and log in. Once your logged in click the database tab at the top and the screen will change and allow us to create a new database. For the backup testing, I created a database called akeeba_test, you can name yours what you want, click the create button to create the database. See the image below.

013 003 phpMyAdmin

With the database created for testing our backup we can now close phpMyAdmin down as we do not need it for anything else.

Copy the Archive Over

Now copy the backup file you created to the backupdev folder on your desktop from where ever you saved it to.

Extract Kickstart

Next we need to extract the Kickstart core file we downloaded from Akeeba to our backupdev folder on the desktop. If your file is in the Downloads folder you could use the command below to extract it from the command prompt, or you can use the archive manager if you like. Pick your poison.

unzip ~/Downloads/ -d ~/Desktop/backupdev

If you are using the command line be sure to check the name of the zip file because you may have a different version of the file than I have. When you extract the Kickstart software, you will see that quite a number of files are extracted. In reality you only need four of them. These are kickstart.php, jquery.min.js, json2.min.js and the specific language file for your language. Notice the two character prefix to all the INI files, these are the language files and for English I would need the one that starts with en-GB. These prefixes are the same as you would encounter with Joomla language files. Howver, it does not hurt to leave all the files because Kickstart will clean up after itself.

Now, before we start the restore, be sure to delete the index.html file we created for testing. If you do not, it will override Joomla’s index.php file when we go to load the web page after restoring.

Restoring from the Archive

Open your browser and go to to start the restore process. You will see the screen below.

013 004 Akeeba Kickstart

After you have read the information, either click the link or press the [ESC] key. Once you close this notice you will be presented with the first screen of Akeeba Kickstart. There are four sections to this first screen. Section 1 allows you to pick from a URL to get the archive file, but will automatically pick up the archive if it is in the same directory as the kickstart.php file we launched. In the screen shot below you will see that it has filled this in for us.

Section 2 allows you to select how you want to extract your backup. By default Akeeba Kickstart will use the Hybrid method, meaning that it will do a direct extraction if it can and if that fails will use FTP services if they are set up.

Section 3 allows you to fine tune the extraction process if you need to. In most cases you don’t need to bother with making changes here.

Finally, in section 4 we have a button that will start the extraction process.

013 005 Akeeba Kickstart

013 006 Akeeba Kickstart

After clicking the start button, Akeeba Kickstart will extract the file and then display a screen that will allow you to run the installer. See screen shots below.

013 007 Akeeba Kickstart

013 008 Akeeba Kickstart

At this point you can click the Run the Installer button. When you do, Kickstart will initalize and present you with the first screen of the installer. This screen displays the settings it has detected with your server environment and backup archive and gives you a chance to go and make changes before proceeding. You can click the next button and go to the next screen. See screen shot below.

013 009 Akeeba Kickstart

On the next screen you will need to enter in some database data to do the restore. For the database server it would be localhost, for the username and password you will need to enter in the username of root and the password you set in the LAMP tutorial for your MySQL server. Finally, you need to enter in the name of the database your created above. Mine is called akeeba_test. See screen shot below.

013 010 Akeeba Kickstart

Once the information has been entered you can click the next button. This will start the database restore process. See screen shot below.

013 011 Akeeba Kickstart

Once the database has been restored you are presented with a dialog indicating it was successful. Click the Next Step button to continue. See below.

013 012 Akeeba Kickstart

The next screen allows you to change some of the information about the site. Kickstart will have picked all the meta-data information about your site from the archive that you extracted, but you can change some of it here if you like. The important part of this screen is, you need to set the administrator password. Enter in your password and repeat it, then you can click the next button. See image below.

013 013 Akeeba Kickstart

When you click next you will be presented with a screen that says your almost done, all you need to do is clean up. You can close this tab, because if you look closely, Kickstart has another tab open. You you look at it you will see it has a button that reads Clean Up. See image below.

013 014 Akeeba Kickstart

013 015 Akeeba Kickstart

Now click the Clean up button and you will be presented with a screen with two button, one sending you to the sites front end and another that will send you to the site’s back end. See below.

013 016 Akeeba Kickstart

At this point the site restore is complete. Click the buttons to see the site’s front and back end and verify that all is working as expected. It took much longer to explain how to restore your site than it does in practice. I encourage you to go through the process a few times and get comfortable with it. You should always test any backup you make to a site, because if you assume it is good and some emergency comes up where you do need to restore and you find that your backup is bad, well… I dare not think of the consequences.

In my test backup site, when I want to reuse it, I simply delete all the folders from the web root of the backup test site and drop all the tables from the akeeba_test database and reuse it over and over.

I hope this tutorial has been a help to you and that the mystery, if any, is washed away when it comes to disaster recovery and your websites. If you have any questions, please contact me by going to and using the contact us menu at the top of the page. Thank you for your support.


Joomla Updates, Upgrades and Extensions ... Oh My!

A little background to the issue

television icon 64x64pdf icon 64x64Every time I begin a new tutorial, I am in the habit of checking for, and doing updates to the Ubuntu 16.04 machine I am working on. This is easily done with the following commands in a terminal. (The terminal can be opened with [CTRL][ALT][T] from the keyboard or from the Unity Dash.)

sudo apt update
sudo apt upgrade

Well, after doing the updates, I logged into the back end of my Joomla development install and got the ugly error messages you see below:

012 001 Joomla

Well, I thought I did see something about a PHP update while I was doing the Ubuntu updates, but how do I fix this? If you are versed with PHP and programming I am sure that you could fix this in a short order. However, if you are new and using this as a platform to learn, you may be lost as a ball in the tall weeds. Well it turns out that it is fairly simple to fix, so let’s work through this and then talk about an extension that, in my humble opinion, will make developing a tad better.

In looking at the errors above, we see that they are notice errors. A notice error according to the PHP manual is defined as follows. “Run-time notices. Indicate that the script encountered something that could indicate an error, but could also happen in the normal course of running a script.” What this means is that your application should still run but what your doing either looks like an error or may be okay. That sounds a little circular to me. Regardless of the exact meaning of the error, it prevents us from accessing the administrator application of Joomla and we need to fix it.

We can remove the notice errors from being reported by turning them off in the php.ini file. Remember when we set up the LAMP server way back in Episode 1? While we were doing that we turned on the error warnings for all errors by using E_ALL for the error_reporting variable in the file. To turn off the notice warnings, first open a terminal by pressing the [CTRL][ALT][T] keys and then enter the command sudo nano /etc/php/7.0/apache2/php.ini to open the file for editing. With the file open press [CTRL][W] to do a search on the file. In the search box type error_reporting = and press the enter key. This should take you to the line that reads the following:

error_reporting = E_ALL

This is the line that turns on the level of error reporting that PHP will use. So right now, it will report all errors to you no matter how minor. Change the line to read like the following:

error_reporting = E_ALL & ~E_NOTICE

This change will tell PHP to report all errors except for notice errors. In case it is hard to read, that is a tilde character (~) in front of the E_NOTICE. Doing this should let us use the back end of Joomla. Save the file by pressing [CTRL][X] to exit, then press [Y] to save the modified buffer, then press the enter key to write the buffer to the php.ini file. That is all that we need to change in the php.ini file, but for the changes to take effect, we will need to restart the apache server. You will do that by typing the following line in the terminal.

sudo service apache2 restart

Now to test our changes, open your browser and navigate to Joomla’s Administrator application by going to Log in and things should look normal again. See the screen shot below.

012 002 Joomla

That has taken care of the problem of getting into the administrator application of Joomla, but unfortunately, we are no longer getting the notice errors reported to us, and really, we probably do want them. So what to do?

Notice that in the screen shot above, there is an update to Joomla. Recall that when we started this adventure that we installed Joomla 3.5.1 and now Joomla 3.6.0 is available.

Upgrading Joomla

The changes in php 7 are causing the notice error to show up for some of the core modules in Joomla. Fortunately, Joomla fixed these in the 3.6.0 release. Upgrading Joomla to this release is easy, just click the Update Now button at the top of the screen in the Joomla back end. After clicking this button you will be presented with the screen below.

012 003 Joomla

From here click the Install the Update button and Joomla will update itself to version 3.6.0. When it is complete you will get a notification that the site has been successfully updated. See the screen shot below.

012 004 Joomla

By upgrading Joomla to the newest version we get any bug fixes, security enhancements and new features that Joomla has to offer. You should always try to stay up to date with your software, especially if your site faces the outside world.

With Joomla updated we can now turn the error level back up to maximum in php. In the terminal type the following command to open the php.ini file for editing:

sudo nano /etc/php/7.0/apache2/php.ini

With the file open for editing, press [CTRL][W] to open the search box. Enter in error_reporting = in the box a press enter. Change the error_reporting variable to read:

error_reporting = E_ALL

With the line changed, press [CTRL][X] to exit, press [Y] to save the buffer and then the enter key to save the file. Now restart apache for the changes to take effect by typing the following command in the terminal.

sudo service apache2 restart

Now that apache has been restarted, go to the back end of Joomla and log in. You should see the normal back end of Joomla with no error messages. Great, our problem is fixed now let’s explore an extension that will make like a little easier for us in the future.

Back It Up Baby

The ability to back up and restore your Joomla site or sites is important for a number of reasons. You can recover from a hacker, recover from a hard disk crash, or even like myself, recover from screwing something up with the Joomla Core files while I was rooting around and mucking with something I should not have been. Regardless, we need an easy way to do a backup and restore for our Joomla CMS software. Fortunately for us, someone has thought about that and created an awesome extension that will do just the thing we want. The extension is called Akeeba Backup and is available for free from Below is a screen shot at the time of this writing of their home page.

012 005 Akeeba

To get the extension, click the Akeeba Backup for Joomla icon at the top left of the main screen. When you click this you will be taken to the Akeeba Backup page where you can download the extension. See the screen shot below.

012 006 Akeeba

Click the Download Core 5.1.2 button, (Or whatever newer version is being offered), and save the file to your computer. Now we need to install this extension into our Joomla site. Log into the back end of Joomla and go to Extensions | Manage | Install from the menu. Browse to the package you downloaded and select it, then click the Upload and Install button. See the image below.

012 007 Joomla

If you get an error about Maximum PHP file upload size is too small, then we will need to make changes to the php.ini file to fix them. See the image below:

012 008 Joomla

By default, when we installed PHP, the settings for upload_max_filesize was set to 2 megabytes and the extension we are trying to install is larger than this allowed size. Additionally, there is another setting in the php.ini file that can affect us as well. The post_max_size setting determines the largest size of post data that can be accepted. For a default install of PHP this is set to 8 megabytes. This setting, however is large enough for us to upload the extension to Joomla so this one can be left alone. To fix our problem we need to update the php.ini file and make the upload_max_filesize variable large enough to allow us to install the extension.

Open a terminal with [CTRL][ALT][T] and type the following command to open the php.ini file for editing.

sudo nano /etc/php/7.0/apache2/php.ini

With the file open for editing press [CTRL][W] to search and enter upload_max_filesize = in the search box and press the enter key. Change the line to read the following.

upload_max_filesize = 8M

Here we are increasing the size to allow up to an eight megabyte file to be uploaded. This is more than we need and I arbitrarily selected this value to match that of the post_max_size variable in the file. The point is, it needs to be bigger than the file size you plan to upload using PHP.

Now, press [CTRL][X] to exit [Y] to save the buffer and then the enter key to save the file. Remember, whenever we make changes to PHP or Apache, we need to restart the service for them to take effect. Restart apache by entering the following line.

sudo service apache2 restart

With apache restarted, let’s try installing the extension again. This time you should be met with a message that says the install was successful. See the image below.

012 009 Joomla

To use the extension to make a backup, click Components | Akeeba Backup from the menu. If this is the first time you tried to use the extension it will ask you to run the configuration wizard. Click the Configuration Wizard button to get started. See the image below.

012 010 Akeeba Extension

When you click this button, Akeeba Backup will start benchmarking and checking out your site and setup. See the image below.

012 011 Akeeba Extension

When it has finished, you will be presented with a screen that reads Finished Benchmarking and will offer you some buttons to backup, edit the configuration and to schedule automatic backups. This is all we need to get started using Akeeba Backup. Click the blue Backup Now button. See the screen below.

012 012 Akeeba Extension

When you click this button, Akeeba Backup will give you a form where you can add a short description and a comment for the backup. Enter in the information you want and click the Backup Now button. See image below.

012 013 Akeeba Extension

I left the Short description to the default and added a backup comment of “First backup of the Joomla Development Website”. After clicking the Backup Now button you will see a screen of the backup progress. Do not navigate away from this screen until the backup has completed. See the screen shot below.

012 014 Akeeba Extension

When the backup has completed you will be given a screen informing you that the backup has completed successfully. At this point you will want to copy your backup to a safe location. To do so, click the Manage Backups button. See screen below.

012 015 Akeeba Extension

When you click this button for the first time, you will get a notification on how to restore backups. I will cover this in detail in another tutorial, so click the Got It! Button to close the dialog. Finally, you will be presented with a screen listing all the backups you have made. To download the backup click the green Download button. See image below.

012 016 Akeeba Extension

Clicking the download button will issue a warning that downloading through your browser can corrupt the file. Since the server and browser are on the same machine, we will most likely be safe in doing so anyway. Click the download button in the warning dialog. And you will get a second warning. Click the OK button on the second warning dialog to continue. Then the browser should prompt you to save the file. If you have not changed any of the defaults on your browser it should be in your downloads folder. See image below.

012 017 Nautilus

You should see a file with a jpa extension. Save this file in a place that is safe. If you ever need to restore your website, you will need this file and Akeeba Bootstrap to do a restore. I will cover a website restore in another tutorial.

If you feel that it would be safer to directly copy the backup file, you can copy the file from your Joomla install to somewhere safe. If you have not changed the default configuration for Akeeba Backup, you will find your backup files located in the administrator/components/com_akeeba/backup/ folder of your Joomla install. The backup will have a jpa extension and the filename will be made up of site-<site name>-<date>-<time>.jpa. You can copy this file directly to a thumb drive or other safe location without the worry of the browser corrupting it.

Although we went through the effort to do a backup of our website using Akeeba Backup, this does not mean we are in the clear. Having a backup means nothing unless the backup is tested and good. I will cover restoring backups in another tutorial using Akeeba’s other product called Akeeba Kickstart.

Moving Forward

Sometimes as developers, we run into issues along the way. For example, the PHP update in Ubuntu seemed to have broke Joomla because of the error level setting we used in the INI file. It is good to know how to tackle these problems and I hope this tutorial gleaned some light on how you may go about solving these issues. Remember, knowledge is a journey and sometimes we stop off at unexpected places. Thanks you for your support and patronage to my videos and tutorials. If you have any questions please contact me.


Installing Joomla 3.x to your Ubuntu 16.04 development server.

Watch the video on how to intsall Joomla into your Ubuntu 12.04 virtual host. Download the PDF file explaining how to install Joomla into your Ubuntu 12.04 virtual host. I don't think you can technically call Joomla! a development tool, but I am putting it in this section nonetheless. After all, you cannot develop Joomla! extensions without it.

Step 1 – Downloading the Joomla! 3.x CMS

Point your browser to At the very top right of the page is a Download button. Click this button to get to the main download page for Joomla. At the time of this writing you have the option of downloading either the full version of Joomla or an upgrade version of Joomla. Since we will be doing a full new install we want to click the full version on Joomla. At the time of this writing it is version 3.5.1. This could be a newer version by the time you read this. If so, just download the newest full package version. Click the button and save the file, keeping a note of where you save the file to. If you have not changed the default behavior of Firefox, this will be in the Downloads folder under your home directory.

Step 2 – Extracting the Joomla 3.x CMS files

When the file has finished downloading, open a terminal with [CTRL][ALT][T] and navigate to the folder in which you saved the Joomla! 3.x zip file. To extract the archive we will be using a program called unzip. You can check to see if you have unzip installed by issuing the command which unzip. This command will either return the path to the unzip program or nothing at all, meaning it just give you a command prompt. If this is the case you can install unzip from the command prompt with sudo apt install unzip. However, unzip should be installed by default on an Ubuntu 16.04 installation.

If you are following this series, recall that we created a folder on our desktop called joomdev. This folder is being pointed to by apache and is used using a virtual host called In this way, if we open the browser and type, Apache will look in this folder for the request. If your document root folder is different, make note of where you have it located and the name of the folder itself. It is required for the next task. The general form of the unzip program when you wish to extract to a specific folder is unzip -d /destination/directory. With the preliminary stuff out of the way, we extract the file to our document root folder with the command unzip -d ~/Desktop/joomdev and press the [ENTER] key. At the time of this tutorial, Joomla! 3.5.1 was available, your file that you downloaded may be different. Keep that in mind when you extract. The easiest and fastest way to enter the filename is to type the first few letters and press the [TAB] key. This will use command completion to finish the filename for you. With the files extracted to our virtual host's document root, we can move on.

Step 3 – Creating a database for Joomla!

At this point we need to create a database for Joomla! to use. Open your web browser and point it to You should be presented with the phpMyAdmin login screen. If this link does not work, try http://localhost/phpmyadmin. If phpMyAdmin opens with some errors about deprecated Methods and other Warnings, don’t worry. If you recall, we turned on all the error reporting we could and because phpMyAdmin is using some methods that will be deprecated in future releases it is giving us a warning. So for phpMyAdmin we can ignore this. Scroll to the bottom of the screen and click the Ignore All button. Then refresh your browser by hitting the F5 key. Remember when you set up your LAMP server, you had to supply the MySQL server a password. Enter root in for the username and the password you created for MySQL in the password field and click the go button. Now that you are logged into phpMyAdmin, look at the menu at the top of the screen. The first entry is Databases. Click this entry to open the Databases screen. Very near the top of the screen you will see a box where you may enter the name of a database to create. Enter joomla3 in the box. Leave the collation drop down as it is to accept the default collation for the server. Finally click the create button. If all went well you should get a dialog pop up that tells you that the database was created, and you should see joomla3 database listed on the left side of the screen with the other databases that exist.

A note on security. If you are setting up a Web Server, MySQL and Joomla! on a public facing address, You would ALWAYS want to create a specific user and password for the Joomla! database, granting that user the permissions needed to get the job done. Again, I will reiterate the point that it is assumed that the development environment is not connected to the Internet and used in a local context only.

Step 4 – Running the Joomla! Installer

We are now ready to run the Joomla! Installer. Point your browser to You will be presented with the first setup screen for Joomla! The very first thing is to select your language. I will be using the default “English (United States)” for mine. Below that is a header that read Main Configuration, Here you will fill in the site name, I am using “Joom 3.x Dev” for this field, you can use whatever you like. You can place any description of the site you like in the Description box below the site name. Next are Admin Email, Username and password. Fill these out as appropriate. Last is a toggle button to allow you to set the initial state of the website to offline. The default is no. If you turn this on, you will be required to enter your username and password to see the frontend of the site. I will leave this option set to no. Finally click the NEXT button at the top right of the screen.

Now you are presented with the Database configuration screen. For database type, leave it set to MySQLi. The hostname will be localhost. The username will be root. The password will be whatever you set it as when you installed MySQL when installing LAMP. Enter that password here. Below that you enter the name of the database we created in step 3 above, I will enter joomla3 in this box. Lastly, it asks about a database table prefix. What is listed there will be 5 random character with an underscore '_' character. Feel free to change this if you like, but the default will probably be just fine. The last option about backing up the database does not matter to us. We created a new database and there isn't anything to backup. Finally click the next button again.

We are at the last configuration screen. At this point you need only decide if you want sample data to be installed. If you have never used Joomla! Before, you probably should install some sample data so you can get an idea of what things look like on the front and back ends of the CMS. Perhaps the Learn Joomla English sample data. If you mouse over the text, you will be given a description of the data it will install. If you decide you don't like it, you can drop the database, empty the folder and install it all again. Finally click the install button at the top right of the screen.

When the installer finishes, you will need to remove the installation folder. You can easily do this by clicking the yellow [Remove Installation Folder] button. Finally, you can visit the front or back end of your newly installed site by clicking the [Site] or [Administrator] buttons on the screen.

To access the front-end of your site, just enter in the address bar of your browser. To access the administrative back-end enter in your browsers address bar.

That's it!!! Joomla is now installed and ready to go!!!

Importing Joomla in NetBeans as a Project

Watch the video on how to add Joomla as a NetBeans project. Download the PDF on how to add Joomla to NetBeans as a Project. Joomla! is a great CMS and the code is pretty well documented. At least as far as the code that I have read. To get the most from the documentation and classes in Joomla!, you should have it as a project in an IDE. The IDE will give you tools that allow you to explore the source code more fully.

Now, there are two ways of going about getting Joomla! in your NetBeans IDE. The first way, is you pull the project from the git repository as a project and start coding. Now you can do that, but there are a couple of drawback to doing so. First, you have to do something with the installation folder to make Joomla! run, and second, you have to be careful not to push your changes up stream. Now if you are intending on modifying the Joomla! code base, then maybe that is okay. The second way is to add Joomla! to your project as existing code. Since we have no desire to modify the actual Joomla! Code base, this works well for us. We just want the ability to work on our extension and be able to use some of the features of the IDE to look around the Joomla! code base and get some code completion. So let's get started.

Step 1 – Create a new project in NetBeans and add Joomla!

Open NetBeans and click File | New Project or press [CTRL][SHIFT][N] on your keyboard. When the New Project dialog opens select PHP from the categories list and then select PHP Application with Existing Sources from the Projects list. Click the next button. Now for the sources folder click the Browse button and navigate to your joomdev folder on your desktop (or where ever you created your document root folder). With the joomdev folder selected click the OK button. Joomla 3.x requires php version 5.3.10 or higher to work. In the php version box, select version 5.4. Next, check the box that reads “Put NetBeans metadata into a separate directory”. Click the Browse button and select the NetBeansProjects folder in your home directory and click OK. Now click the Finish button on the dialog.

That's it!! Now you can explore the Joomla! Source code from within the NetBeans IDE!!

Installing NetBeans on Ubuntu 16.04

Watch the video on how to install NetBeans to Ubuntu 12.04. Download the PDF for how to install NetBeans onto Ubuntu 12.04. This document will guide you through the process of installing the NetBeans IDE onto your Ubuntu 16.04 computer.  An IDE will greatly enhance your ability to write extensions for the Joomla 3.x framework.  An IDE gives you the ability to look at parent classes and explore the code and it's documentation.  Additionally, IDE's allow you to use version control systems like git, and auto build features.  These topics will be covered in future tutorials.  Let's get started!

Step 1 - Installing Java JDK

NetBeans 8.1 requires the Java SDK version 8 to run. There are a couple of ways that you can install this. The first is search on Java in the software center or synaptic package manager. But I think it is just as easy installing it from the command line. Press [CRTL][ALT][T] to open a terminal. When the terminal comes up, install the JDK by entering the following command: sudo apt install default-jdk

The default JDK for Ubuntu 16.04 is version 8.

Step 2 - Download the NetBeans IDE

Download the NetBeans IDE. Open your browser and go to On the NetBeans homepage, click the download button on the upper right section of the screen. The downloads screen shows several different versions of NetBeans you can download. You can select whatever will suit your needs but for this tutorial, we are only interested in the PHP version of NetBeans. This version has support for both HTML and PHP which is what we need to write Joomla extensions. You will see a download button at the bottom of the PHP column. Click the button and download the software.

Step 3 - Making the NetBeans file and executable

In order to run the installer program we just downloaded, open the terminal if it isn't already open and navigate to where you saved the file. If you have not changed Firefox's default settings, you will find it in the Download folder of your Home Folder. Open a terminal with [CTRL][ALT][T] and navigate to your Downloads folder by issuing the command cd ~/Downloads. Once you navigate to this folder, issue the command chmod +x Pay attention to the name of the file. You may have a newer version of the program than was available at the time of this tutorial. Perhaps use command completion with the tab key.

Step 4 - Installing the NetBeans Application

Now that we have marked the program as executable, we can run the installer with the following command: ./ NetBeans will make a check to see if the Java JDK has been installed and then will start the install process. When the dialog comes up click the next button to start the installation process. Next you will be presented with the license agreement. Check the box and click the next button. Next, it asks for the directory to install the program to. Unless you have a need to specify different directory for this, leave it as default and click next. Lastly, decide if you want NetBeans to check for any available update and check or uncheck the box as desired. I choose to let it check for any updates. Finally, click the install button. When the program has finished installing you will be presented with a dialog asking if you want to contribute to the NetBeans project by providing anonymous usage data. Either check or uncheck the box as you see fit and click the finish button.

Step 5 - Running NetBeans

All that is left to do is run NetBeans. The installer places a link on your desktop to run the program. Double click this link and start NetBeans. NetBeans opens to a splash screen where you can start creating projects and coding. When running NetBeans for the first time it would be a good idea to go ahead and install any updates to the IDE that are available. To do this, click the HELP | Check for Updates menu item. NetBeans will display a list of updates that are available (if any). Click the Next button to begin the installation of the updates. NetBeans will ask you to agree to any needed license agreements at this time. Once you agree, click the Update button and the updates will start installing. Once the installation starts for any updates, it will be minimized to the status bar at the bottom of the screen. Once the updates are installed, you may need to restart the NetBeans IDE for some of them to take effect. One last suggestion I would make is while NetBeans is running, right click its icon on the unity bar and click the lock to launcher link.