![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
Ubuntu 9.10 is out!!!
When downloading Ubuntu 9.10 please consider using bittorrent to get your copy of Ubuntu. The Ubuntu Developers Summit for Lucid Lynx will be held the week of 16-Nov-2009 till 20-Nov-2009 in Dallas, TX USA. Visit the the Ubuntu wiki for more information about UDS and how to participate remotely. |
|
Tutorials & Tips The place to find Ubuntu related Tips & Tricks. |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
A Carafe of Ubuntu
![]() Join Date: Oct 2005
Location: Burlington, ON, Canada
Beans: 107
Ubuntu 8.10 Intrepid Ibex
|
HOWTO: Setup easy web development environment (XAMPP)
This is a how-to for setting up a web development environment easily. This guide will install the XAMPP lampp stack into /opt, setup an easy way to start it up and shut it down, and link a folder in your home directory to the webserver.
WARNING This guide is aimed at a development environment only and should not be used as a public webserver. To setup a public webserver follow the directions on the Ubuntu wiki https://help.ubuntu.com/community/ApacheMySQLPHP As this is Ubuntu, all the major parts of a typical web server are included (in the main repo, or on the Ubuntu Server CD) and this is a great way to setup a server. The ubuntu developers have prepared a great web server and have made the process as seemless as possible. But what if even the official way is still to complicated? What if you just want a quick web server for development? Fortunately there is the XAMPP project: http://www.apachefriends.org/en/xampp.html. The XAMPP project bundles Apache, PHP4 & 5, Perl, mySQL, and a bunch of other utilities/applications into an simple package for Mac OSX, Windows, Solaris, and Linux. Obviously this HOWTO only deals with the linux version. For those of you with already existing Apache/mySQL/php installations it installs everything into /opt so it doesn't conflict with any other installation, and it is completely setup and ready to run. Install XAMPP Two easy steps:
Start XAMPP To start it up, open a terminal and type this: Code:
sudo /opt/lampp/lampp start To stop it, open a terminal and type this: Code:
sudo /opt/lampp/lampp stop To see additional commands, open a terminal and type this: Code:
sudo /opt/lampp/lampp ![]() To use the sweet gtk/python control panel: Run in a terminal: Code:
gedit ~/.local/share/applications/xampp-control-panel.desktop Code:
[Desktop Entry] Comment=Start/Stop XAMPP Name=XAMPP Control Panel Exec=gksudo "python /opt/lampp/share/xampp-control-panel/xampp-control-panel.py" Icon[en_CA]=/usr/share/icons/Tango/scalable/devices/network-wired.svg Encoding=UTF-8 Terminal=false Name[en_CA]=XAMPP Control Panel Comment[en_CA]=Start/Stop XAMPP Type=Application Icon=/usr/share/icons/Tango/scalable/devices/network-wired.svg Test to see if XAMPP is running Once XAMPP is up and running open firefox and go to: http://localhost/ You should see the XAMPP test page: ![]() Location of files and uploading XAMPP by default uses /opt/lampp/htdocs as the root web directory. The easiest way to start working on files is to link a folder in your home directory into this directory. My user name is peter so I have /home/peter/public_html linked to /opt/lampp/htdocs/peter. So if I navigate to http://localhost/peter/ I get a listing of all the files/folders in that directory. (As long is there isn't a index.php/html/etc file) To set this up, run in a terminal:
Bookmark http://localhost/username to make this easy to access. WARNING - SECURITY http://www.apachefriends.org/en/xampp-linux.html#381 Open holes:
To fix most of the security weaknesses open a terminal and run: Code:
sudo /opt/lampp/lampp security Please read this post. ---- EDIT - July 28, 2006 ---- Minor Edits ---- EDIT - August 1, 2006 ---- Re-did xampp control panel shortcut to make it easier. ---- EDIT - August 16, 2006 ---- Added warning for public web servers and edited intro to make it more accurate. ---- EDIT - September 1, 2006 ---- Added sudo to security command.
__________________
Peter ** Last edited by petervk; September 1st, 2006 at 09:58 AM.. |
|
|
|
|
|
#2 |
|
Just Give Me the Beans!
![]() |
Re: HOWTO: Setup easy web development environment (XAMPP)
contained a link to my site which had this tutorial but the one i wrote.
removed because i shut down the site Last edited by gorilla_king; May 22nd, 2007 at 10:09 PM.. |
|
|
|
|
|
#3 |
|
A Carafe of Ubuntu
![]() Join Date: Oct 2005
Location: Burlington, ON, Canada
Beans: 107
Ubuntu 8.10 Intrepid Ibex
|
Re: HOWTO: Setup easy web development environment (XAMPP)
The url is broken for me. It could be the wierd port and the firewall here at school. Do you have it mirrored somewhere else?
__________________
Peter ** |
|
|
|
|
|
#4 |
|
Just Give Me the Beans!
![]() |
Re: HOWTO: Setup easy web development environment (XAMPP)
yeah if your at school then i'm about 95% sure that it's broken from the firewall, and no i don't mirroed at the moment because i'm just using it as a developement server.
|
|
|
|
|
|
#5 |
|
A Carafe of Ubuntu
![]() Join Date: Oct 2005
Location: Burlington, ON, Canada
Beans: 107
Ubuntu 8.10 Intrepid Ibex
|
Re: HOWTO: Setup easy web development environment (XAMPP)
So far this post has just under 200 views, So great. If you read this and use it could you leave a reply saying if it was useful/useless? I'd like to keep improving this how-to, so feedback would be good.
Plus, replies bump it up the list.
__________________
Peter ** |
|
|
|
|
|
#6 |
|
Way Too Much Ubuntu
![]() Join Date: Jun 2006
Location: /Earth/Asia/Vietnam
Beans: 211
Ubuntu 8.04 Hardy Heron
|
Re: HOWTO: Setup easy web development environment (XAMPP)
This is a very nice Howto for me, I was wondering how to make php5 and php4 developements working seamlessly together in a handy way, and now I find out that XAMPP will be my best shot now. Thanks so much for this, and I bet that many ppl will find this helpful also, keep up the good work, petervk
|
|
|
|
|
|
#7 |
|
First Cup of Ubuntu
![]() Join Date: Jul 2006
Beans: 8
|
Re: HOWTO: Setup easy web development environment (XAMPP)
Very useful. That link trick alone was worth it. The .tar file didn't download for me but I just went to the XAMPP website and downloaded from one of the mirrors and then followed the rest of the instructions here.
Kevin |
|
|
|
|
|
#8 |
|
First Cup of Ubuntu
![]() Join Date: Jul 2006
Beans: 8
|
Re: HOWTO: Setup easy web development environment (XAMPP)
http://localhost/soclix works great but how to make it work with my ip, for my friend to have acces to http://myip/soclix ?
|
|
|
|
|
|
#9 |
|
100% Pure Ubuntu
![]() |
Re: HOWTO: Setup easy web development environment (XAMPP)
I'm biased against XAMPP. It's too unwieldy. I will be following this thread though.
Can you advise us the version of PHP and MySQL that the latest version of XAMPP installs? PHP 5.0? MySQL 5.0? A CMS may require the use of PHP4.0 or PHP5.1 and MySQL 4.0 or MySQL 5.1. XAMPP is pretty though. Last edited by adamkane; July 31st, 2006 at 07:49 AM.. |
|
|
|
|
|
#10 | |
|
Just Give Me the Beans!
![]() |
Re: HOWTO: Setup easy web development environment (XAMPP)
Quote:
|
|
|
|
|
| Bookmarks |
| Thread Tools | |
| Display Modes | |
|
|