PHP is a scripting language, often used for websites.

learn more… | top users | synonyms (2)

124
votes
2answers
133k views

How do I install latest PHP in supported Ubuntu versions (like 5.4.x in Ubuntu 12.04)?

I am trying to update to php 5.4 in Ubuntu 12.04, and I can only get 5.3.6 using official repositories (using apt-get). I'm not really sure how to do a manual update – I'm sorta new to ubuntu, but I ...
2
votes
9answers
11k views

How to downgrade PHP from 5.3.x to 5.2.x

I need to downgrade my PHP to 5.2.x from 5.3.x Certain software I currently use requires it. I found all these link explaining how to do it but they no longer work because they show you how to use ...
22
votes
4answers
47k views

How to have my PHP Send mail?

I installed Ubuntu 11.04, LAMP using tasksel. I find that PHP mail() does not work. I suppose I need to enable it or something? How do I do that?
10
votes
4answers
6k views

Install Apache, Php, Mysql latest versions not available via apt

I need to install the latest versions of apache, php and mysql that are available on their websites, but the problem is that apt repositories don't have these updates versions yet. Versions that I ...
12
votes
10answers
13k views

What are some good PHP editors? [closed]

I'm currently using PhpStorm by Idea JetBrains, but its buggy and I'm really looking for something that will allow me to get work done without too much hassle. Please limit one IDE/Editor an answer.
4
votes
2answers
23k views

Default file permissions for php user www-data

I have a php installed on my ubuntu machine. The web root is /var/www I set the permissions for this folder like so: sudo chown -R ftpuser:www-data /var/www ftpuser is the user I set up so I ...
5
votes
3answers
7k views

Downgrade PHP to PHP5.2?

I want to install PHP 5.2 in Ubuntu 11.04 , I had some script that did that thing good but only on Ubuntu 9, anyone has a script / instructions how to do it?
1
vote
1answer
1k views

Apache / MySql is not running. What is wrong?

I installed lampp / xampp on my Ubuntu 12.04. After installing, Apache and MySQL were running properly. Now, they're not. Here's what I get when I try to run apache: Command: /etc/init.d/apache2 ...
0
votes
2answers
2k views

PHP5.4 Unable to load dynamic library gd.so undefined symbol: gdGetC

I installed PHP5.4 from PPA ppa:ondrej/php5-oldstable in my Ubuntu 12.04.2. Then all of my image processing scripts got broken. Turns out the php5-gd library isn't loaded. $ php -a PHP Warning: PHP ...
10
votes
2answers
12k views

Can't use PHP extension Mcrypt in Ubuntu 13.10 (Nginx, PHP-FPM) [duplicate]

I installed a fresh Ubuntu 13.10 on my laptop. Like I usually do, I install the packages I need for Web development, which are nginx, php5-fpm, mysql, php5-mysql, php5-mcrypt and a few others. After ...
15
votes
5answers
12k views

How to have two version of PHP installed and switch easily?

I want to have both PHP 5.2.17 and PHP 5.3.5 installed on my Ubuntu machine and switch as per my necessity. How can I achieve this?
11
votes
5answers
20k views

php is not working well on ubuntu 13.10 and mcrypt is missing in phpmyadmin

I've upgraded from UBUNTU 13.04 to 13.10 but I can not work with php pages or phpmyadmin . I've tried this way to install lamp on ubuntu sudo apt-get install lamp-server^ phpmyadmin and I've done all ...
20
votes
3answers
51k views

Where are the Apache and PHP log files?

I've installed Apache, PHP, and MySQL on Ubuntu 10.10 desktop edition, and it's working fine. Except I have no clue where to look for Apache or PHP log files.
15
votes
1answer
25k views

Update server php version to 5.4.10 via the command line

Im setting up a vps for the first time from scratch, the host has a one click LAMP installer which took out allot of the leg work, but running phpinfo(); i found im running 5.3.10. So id like to ...
8
votes
4answers
2k views

Ubuntu One Oauth login from PHP

I have searched the whole internet trying to find a simple example that could point me in the right direction, but no luck, so here comes my questions: I want to log into Ubuntu One and sync (or ...
11
votes
4answers
20k views

How to update to PHP 5.3.10 in 10.04?

I'm new to Linux and have only the basic experience with Ubuntu and installing LAMP Server. I've successfully installed all using the "apt-get install" method. My problem is I want to update PHP 5.3.2 ...
4
votes
1answer
12k views

Easiest way to upgrade php to latest version? [duplicate]

I'm seeing info on how to upgrade from a specific version to another, and that is what I want to do (currently 3.3.6), but is there a simple command to do this? I'm a complete ubuntu/linux noob so I ...
1
vote
0answers
636 views

Problems starting Apache2 on Ubuntu 12.04.1 LTS

I recently installed Ubuntu 12.04.1 on my EC2 Micro instance and then installed Apache2 and PHP5. I am now having trouble starting Apache2, I've checked the error logs and here's the result: [Sun Oct ...
0
votes
2answers
294 views

Php broken, “held broken packages” error on install [duplicate]

I've completely destroyed everything and now php wont install. I had php5.4 and everything was great. I then needed to run Magento locally which wasnt working. I saw one of the requirements was ...
4
votes
1answer
10k views

How can I configure Postfix to send all email through my Gmail account?

I'm trying to send an email through Google from my localhost. (via PHP5.3) But Google keeps on blocking my requests. I tried to follow the solutions given to a few similar questions, but for some ...
3
votes
2answers
8k views

Ubuntu 13.10 gives “Package 'libapache2-mod-auth-mysql' has no installation candidate” error [closed]

UPDATE: Because Apache 2.4 is the default version (instead of the previous 2.2) this error occurs. However as can be seen here all future versions of Ubuntu 13.10 and above will not support this ...
3
votes
4answers
15k views

Upgrade PHP version to 5.3 on Ubuntu

How can I do a version upgrade from 5.2 to 5.3? php update/upgrade is saying I'm using the latest version. I'm using Ubuntu Server 9.04
1
vote
3answers
6k views

phpmyadmin throws a 404 on opening

I have installed php5 and phpMyAdmin from the Ubuntu Software Centre on a fresh install of Ubuntu 13.04. when I enter localhost in my browser the following is displayed: It works! This is the ...
1
vote
2answers
911 views

500 Error on index.php file

I have found a question very similar to this, which I thought would solve my problem. However, after changing my .htaccess file, with index.php on the end of the list, and then index.php as the only ...
0
votes
4answers
13k views

Install php 5.3 on ubuntu 13.04

How I could install old PHP version on Ubuntu 13.04 (prefer verson 5.3.3)? I appreciate any help.
0
votes
3answers
4k views

phpMyAdmin login problem:

I use Ubuntu 12.04. Recently I have installed XAMPP 1.8.1 in my system. I set password to: XAMPP pages, MySQL/phpMyAdmin, MySQL root and FTP. But after that when I try to login to phpMyAdmin page ...
0
votes
3answers
639 views

Shell Scripting for Linux Server Administration

I recently started learning Linux(Ubuntu), and i'm aware that Linux has it's own form of language i.e Shell Scripting. What i'll like to know is that is this language enough to administer a Linux ...
30
votes
2answers
35k views

What is the easiest way to enable PHP on nginx?

What is the easiest way to enable PHP on nginx on Ubuntu 12.04? Best solution is the one that request minimal work, ideally just a package installation :)
17
votes
2answers
11k views

what happened to json_encode in 13.10 php?

Just updated to saucy 13.10 and json_encode is missing from the bundled php. json doesn't appear in the phpinfo() output and i'm getting this error in my app: PHP Fatal error: Call to undefined ...
12
votes
5answers
39k views

How to downgrade from PHP 5.4 to 5.3

Recently I upgraded PHP to 5.4, but it seems to be failing on me because APC isn't working with it, however this gave me no choice but to downgrade to 5.3, how can I do this? I executed apt-get ...
9
votes
4answers
4k views

How to rollback to PHP 5.2?

I have just installed a 10.04 LTS on my development server but the system that I need to run on it (Magento ecommerce) is not compatible with PHP 5.3 which ships with the newest version of Ubuntu. Is ...
10
votes
2answers
835 views

Can a server handle simultaneous shell commands?

I'm writing a very simple browser based MP3 player in PHP. Part of this project requires that every MP3 file is converted to a WAV file. There's a function in PHP called shell_exec that allows you to ...
4
votes
4answers
7k views

downgrade php5 5.5.3 to php5 5.3 in ubuntu 13.10

I just upgraded to ubuntu 13.10.. I was working on a project that uses php 5.3 and now phpmyadmin is not working and when i try to open a page i see a ton of warning and the sign in page doesnt sign ...
5
votes
3answers
2k views

How to create a new file with content using Ubuntu One API and PHP

I'm having some problems when i try to create a new file with some content (or overwrite the content of an existing one) using Ubuntu One API and PHP. I can easily create and empty file or folder ...
4
votes
2answers
9k views

Sending mails with PHP, LAMPP and PostFix

I've been trying for 2 whole days now, and I just can't get the most simple thing to work. The problem: Sending eMails from PHP to my eMail address does not work I've been working with Windows and ...
3
votes
2answers
1k views

phpMyAdmin “More Settings” Option Generates Blank Page

phpMyAdmin works well except for a couple of links on the Home Page. There are two links to More Settings, however they both take me to a blank page. Am I missing a module, or does it need ...
3
votes
2answers
726 views

How do i create my own php 5.3.3 package/ppa?

I really would like to create a package for php 5.3.3 and then make a ppa for it (I would like the php-fpm support but inside the newest release), however this question goes further than this. I ...
2
votes
2answers
1k views

How to install older version on PostgreSQL and PHP5?

Because of differencies in package versions between my development machine and my provider's server, I have to downgrade packages installed on my computer. In Ubuntu 10.04 LTS default PostgreSQL ...
2
votes
3answers
2k views

What PHP & Xdebug based Editors do people use other than Eclipse, Netbeans (anything java based) or VIM

What editor do people here use in linux? I want Xdebug support but I don't want something java based (eclipse, netbeans, etc) nor do I really want to use VIM. Any native GTK based editor/sdk that ...
1
vote
1answer
4k views

How to configure Apache to run PHP as FastCGI on Ubuntu 12.04 via terminal?

I'm relatively new to the world of unix command line web server management/administration. Many hosts with control panel administration options allow you to change how PHP is run with a simple ...
0
votes
1answer
1k views

.php files are downloaded instead of being parsed by Apache

I have Xampp on Ubuntu 11.04. .php files are downloaded instead of parsed by Apache! How do I get Apache to parse them?
4
votes
1answer
2k views

How to setup sudoers for Apache web service?

# User privilege specification root ALL=(ALL:ALL) NOPASSWD: ALL apache ALL=(ALL:ALL) NOPASSWD: ALL me ALL=(ALL:ALL) NOPASSWD: ALL In Fedora both works: http://localhost/test echo ...
3
votes
2answers
241 views

How often is php updated?

I am using ubuntu 10.04. I had installed php with the following command if that makes a difference: sudo apt-get install php5 libapache2-mod-php5 The PHP version on my computer is 5.3.2-1. Will ...
3
votes
5answers
3k views

Install php 5 on a fresh installation

I have a fresh installation of Ubuntu 10.10 and I'd like to get PHP to work. I've tried sudo apt-get install apache2 sudo apt-get install php5 sudo apt-get install libapache2-mod-php5 sudo ...
2
votes
1answer
377 views

Upgrade php5-gd on 12.04?

I'm working with the GD library for image manipulation, to which I need to create some transparent PNGs. Instead, I'm getting a black background. I've looked everywhere on how to generate a blank, ...
2
votes
3answers
1k views

After upgrading to 12.04 from 10.04, can't login to PHPMYADMIN

I just can't login to PhpMyAdmin anymore, it says bad logins. PHP works perfectly. Please help. Thank you. 2002 Cannot log in to the MySQL server Language Log in Username: Password: Connection for ...
1
vote
1answer
73 views

I can send mails from shell with PHP, but I can't send from the PHP web page

I'm trying to send mails from a contact form in a page on my server. I followed this post. My PHP file /var/www/my_project/test.php is this: <?php $myemail = "my_mail@gmail.com"; $subject = "my ...
0
votes
3answers
73 views

Php doesn't work on Apache server

I installed LAMP sudo tasksel install lamp-server I can run my site, but the php code is just displayed as text. I have tried this solution, but it didn't help me. When I try to run php script ...
0
votes
1answer
640 views

The following packages have unmet dependencies. I can't find solution [duplicate]

I try to install php5-fpm package but I have this information: The following packages have unmet dependencies: php5-fpm : Depends: php5-common (= 5.5.7+dfsg-1+sury.org~quantal+1) but ...
0
votes
2answers
523 views

cannot access copied folder in htdocs of lampp in ubuntu?

I want to move my web content from window 7 to ubuntu 12.04. So I copy my web content and move it to my /opt/lampp/htdocs folder, then I have change the folder permission using :: 1) sudo -s 2) ...