+ 2

How to run php in linux ubuntu?

i use any text editor like gedit or vim but i don't how to setup a local webserver for practice. thanx in advance.

7th Dec 2016, 5:11 AM
Raju Venkatesh
Raju Venkatesh - avatar
6 ответов
+ 1
Try to use php built-in web server: cd /html/folder/ php -S localhost:80 if you want to use Apache2 or nginx follow one of the many guides "how to create a LAMP (or LEMP) server".
7th Dec 2016, 7:35 AM
AtoMX
AtoMX - avatar
+ 1
lampp 😐
8th Dec 2016, 10:20 PM
Sepehr
Sepehr - avatar
+ 1
install apache apt-get install apache apt-get install php
26th Dec 2016, 12:56 PM
Hafid Fajar
Hafid Fajar - avatar
+ 1
Use xampp. it's free, and easy to install in Ubuntu. after installation, type this command in terminal: sudo /opt/lampp/lampp start now you can start appache and MySQL using GUI. you have to save your PHP files inside: /opt/lampp/htdocs then open your browser and enter this address: http://localhost/your_file.php enjoy it!
27th Dec 2016, 10:00 PM
Saeed Mashhadi
Saeed Mashhadi - avatar
0
install XAMPP (i dont know if it runs on linux, but search it on Google)
25th Dec 2016, 8:04 PM
JAN R.
JAN R. - avatar
0
apt-get update apt-get upgrade apt-get install curl curl --silent --location https://deb.nodesource.com/setup_0.12 | bash - apt-get install --yes nodejs apt-get install --yes build-essential apt-get install sudo sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10 echo 'deb http://downloads-distro.mongodb.org/repo/debian-sysvinit dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list sudo apt-get update apt-get install mongodb sudo apt-get install -y mongodb-org sudo touch /etc/init.d/mongodb sudo chmod 755 /etc/init.d/mongodb apt-get install apache2 apt-get install php5 php-pear php5-mysql service apache2 restart Use this commands in ubuntu
15th Jan 2017, 11:38 AM
Жадный Кот
Жадный Кот - avatar