Tag Info

New answers tagged

0

If you have already set up PHPMyAdmin, you can edit the /etc/phpmyadmin/config.inc.php file and set the $cfg['Servers'][$i]['host'] value (and friends) to the IP address or DNS name of the MySQL server you are trying to connect to. PHPMyAdmin's documentation is quite good. There's usually a block similar to: $cfg['Servers'][$i]['host'] = 'your_server'; // ...


0

To answer my own question, here's what I did to solve the issue I had: sudo chgrp -R www-data ~/public_html/ sudo chmod -R g+w ~/public_html/ Then, nginx was able to write to the public_html folder and problem solved! It might seem straightforward (and there are countless threads on StackOverflow referring to this particular solution), but somehow I ...


0

The interest of application softwares such as Bluefish, Filezilla, WinCp (on Windows) ... is to deal with a remote server. In your case, it is better to run your above command (sudo cp source destination). But in both cases, using a software or a terminal command line, your files privileges depend only on how you chmod them (they are not inherent to the ...


0

Yes, you can upload your files using SFTP (FTP over SSH). You can log in with the same credentials as you're using for SSH. But I wouldn't enable remote logins for root on your server. The root user can do anything on your server so if you get hacked while remote root logins are enabled anything can happen. I suggest you just set a password for the ...


0

I found the solved it was change my "run to software" NOT open wine appication, firefox, google, reddit. I checked my Apache is running. about time!!!


1

run xampp-linux-x64-1.8.3-4-installer.run as root user using sudo cd ~/Desktop sudo ./xampp-linux-x64-1.8.3-4-installer.run Enter your password and hit Enter. You should see the installer.


0

This very simple tutorial helped me a lot to do it. It gives quite the same info but it worked for me.


0

You can access MySQL from command line by typing in a terminal: mysql -u [username] -p [password] where [username] is the user you setup during install and [password] is the password for that user. If the password has special characters (such as $ or !) then you can leave the -p blank and it will prompt you for the password. As far as phpMyAdmin, you ...


0

I did the setup via following these steps... sudo apt-get install php5-dev libpcre3-dev gcc make php5-mysql git-core autoconf ### Do these in any folder you want git clone --depth=1 git://github.com/phalcon/cphalcon.git cd cphalcon/build sudo ./install ### Create the extension ini file in /etc/php5/mods-available echo 'extension=phalcon.so' | sudo tee ...


0

you can also use XAMPP for apache server and php. you can download XAMPP from this site https://www.apachefriends.org/index.html and after downloading right click on the downloaded file and then click on the properties and then click on the tab called permissions then tick on Allow executing file as a program" then open terminal navigate to the path where ...


0

The easiest way to obtain PHPUnit is to download a PHP Archive (PHAR) that has all required (as well as some optional) dependencies of PHPUnit bundled in a single file. Open the terminal and type: wget https://phar.phpunit.de/phpunit.phar # download the PHP Archive (PHAR) file chmod +x phpunit.phar sudo mv phpunit.phar /usr/local/bin/phpunit


1

Try this sudo apt-get install tasksel After installation invoke taskel from terminal sudo tasksel install lamp-server follow this link http://www.unixmen.com/install-lamp-with-1-command-in-ubuntu-1010-maverick-meerkat/


0

Try this on your terminal. It's a great lamp stack setup wizard provided by tasksel. sudo apt-get install taskel //then follow on screen instructions to install lamp stack


0

Typing: sudo apt-get install apache2 php5 libapache2-mod-php5 will install everything you need and will start the apache server with support for PHP. To verify that the php module is loaded, type: a2query -m php5 if not enabled, then load with: sudo a2enmod php5 and restart apache: sudo sevice apache2 restart`


2

I'm sure you have sorted this out already, so this is for anybody with similar request run the "change ownership" command on your webroot folder: sudo chown manny -R www This will make you the owner replace "manny" with your username, enabling you to write/read within www folder


0

whey don't you download php from source and compile it ? http://php.net/downloads.php


0

This link will help you. See the second method of doing this for a security concern.


0

You should edit the 000-default.conf file To edit 000-default.conf you need to run following command sudo getit /etc/apache2/site-available/000-default.conf Here you go By default DocumentRoot shows below DocumentRoot /var/www/html You need to change the DocumentRoot to DocumentRoot /var/www/ After this you must restart your Apache server by ...


0

The new default config of php5 in 14.04 seems to disable short_open_tag option (this directive determines whether or not PHP will recognize code between <? and ?> tags as PHP source which should be processed as such). So go to /etc/php5/apache2/php.ini and search for the option short_open_tag and set it to On: short_open_tag = On Save the file and ...


0

It's not clear what is not working, but you can start troubleshooting as following: 1) check that the packages are installed with the commands: dpkg -l apache2 dpkg -l php5 dpkg -l libapache2-mod-php5 Expected: you should see those packages installed (line starting with letters "ii"). 2) check if the service is up and running: service apache2 restart ...


0

try sudo apt-get install php5 apache2 doesn't come with php preinstalled. And then restart apache2 sudo service apache2 restart


0

Make sure that you have run sudo apt-get update before running sudo apt-get install php5 libapache2-mod-php5 php5-mysql because it will update the package lists so that the latest software can be installed.


0

You need a web server to view php files. Install apache2 the default webserver. sudo apt-get install apache2 then install php5 sudo apt-get install php5 then restart your apache2 server sudo service apache2 restart then just drop the php file(s) in the /var/www folder and go to http://localhost/file.php but replace file.php with the name of the ...


0

Open Terminal using Ctrl + Alt + T, now type "sudo gedit" now type your password and press enter. This would open the gEdit program, now open your .php file where it's located or just drag the file on gEdit.


0

Please check the file permissions. You might not have the permission to read the file. You can use the chmod command to change permissions. You may also check the chown command. Once you have set the permissions correctly you should be able to open files using a text editor. To open the file using localhost/worm/data.php, firstly make sure permissions are ...


-1

Using Pear Get an list of software available using pear pear remote-list Install a package pear install <package_name> List of package that already installed pear list List files belonging to an installed package pear list-files <package_name> Uninstall a PEAR package pear uninstall <package_name> Upgrade PEAR installer (needed for ...


2

It would appear that your script is not getting passed to the php interpreter, and is simply outputting the text of the file. This is a common error and is almost always due: Using a file ending other than php (e.x. htm or html) Not using php tag <?php ... ?> or as Nathan mentioned using improper tags. You may see other servers that use file ...


3

It looks like the code is using short tags <? ?> instead of the normal <?php ?>. You need to enable short tags in php.ini. Find this in php.ini: short_open_tag Set it to 1 and restart Apache.


3

By looking at your last updated edit, I see the file is not saved as index.php. You see, php scripts will not work when you save it on an .htm or .html extension. In order for the php file to take effect, you will need rename index.htm to index.php. EDIT As per my last comment with a testing php script link, it seems there's no problem with your php pack ...


1

By the look of the issue, it seems you've not installed PHP as it denies to view page, and downloads instead. As I've commented, Apache doesn't come packed with PHP as it is a separate package. Installing php package should simply fix your issue.


0

Finally, I found the solution: sudo dpkg --force-depends --purge gedit sudo dpkg --force-depends --purge gedit Followed by a quick apt-get -f install sudo dpkg --force-depends --purge gedit sudo service apache2 restart fixed it all.


1

For CURL to work, it depends on some other packages. The following packages have unmet dependencies: gedit : Breaks: gedit-plugins (< 2.91) but 2.30.0-0ubuntu1 is to be installed php5-curl : Depends: php5-common (= 5.3.10-1ubuntu3.11) but 5.3.10-1ubuntu3.10 is to be installed E: Unmet dependencies. Try 'apt-get -f install' with no packages ...


0

I don't know if my solution will work, just give it a try. Probably, your nginx version is outdated. # apt-cache policy nginx nginx: Installed: 1.4.1-3ubuntu1.3 Candidate: 1.5.12-1+saucy0 Version table: 1.5.12-1+saucy0 0 500 http://ppa.launchpad.net/nginx/development/ubuntu/ saucy/main amd64 Packages *** 1.4.1-3ubuntu1.3 0 500 ...


4

Environment variables are set in /etc/environment. You will find the $PATH variable in this file. This variable stores the path to binaries in various locations. To add /opt/lampp/bin to the location searched for binary files, just append this path preceded by a : to the path variable. For example, if the $PATH variable was: ...


0

To open an interactive php shell, just type in a terminal: php -a As for opening a file, just: php filename.php


1

As an alternative to /opt/lampp/bin/php, to run a php script from the command line, you just need to install php5-cli: sudo apt-get install php5-cli And run your script with: php myscript.php


0

Try: sudo apt-get dist-upgrade More info here: Why use apt-get upgrade instead of apt-get dist-upgrade?


0

You could try another route: Rather than installing Zend Framework system wide, you could use composer and pull ZF as your project dependency. Usually it is much cleaner way to install ZF and similar packages. Once you have composer up and running, all you need is this in your composer.json file: { "require": { "zendframework/zendframework1": ...


0

Yes. The PHP 5.4 and 5.3 tarballs are available here.


3

You don't need to add execution permission on php files, install php5-cli: sudo apt-get install php5-cli And now to run your php file, just type: php test.php Alternatively to really make it executable, add the php shebang: #!/usr/bin/php -q <?php Print "Hello, World!"; ?> And add the execution permission on your file: chmod +x ./test.php


0

Usually when make failed to build from sources, you have to install a -dev package, in your case it's php5-dev. I'm not sure if it's the only one that you'll need to install but try first to install php5-dev: sudo apt-get install php5-dev


1

What you need to do is use an SDK (Software Development Kit), from https://wiki.openstack.org/wiki/SDKs#PHP: php-opencloud is a software development kit (SDK) to help developers using PHP to work with OpenStack and other open clouds. ZendService_OpenStack is a PHP library that implements the last versions of the OpenStack API. It's 100% compliant ...


0

It appears that my files were not accessible after copying them over from a Windows system to Ubuntu. Having this said, I had to modify the permissions of my project directory to 766. I did this with the following command: chmod -R 766 /My/Directory/Path/ After this my files were showing up normally in the web browser.


0

You need to use different PPA if you want apache 2.4 and PHP. There's ppa:ondrej/php5 that contains latest apache 2.4 and PHP 5.5. PHP 5.4 and earlier is not supported with apache 2.4.


0

I've solved this sudo php5enmod mcrypt and check mcrypt using php --ini and on php console php -a execute a true: var_dump(mcrypt_create_iv())


0

I think it is built in http://php.net/manual/en/function.mssql-connect.php I haven't had to do this before but I ran into this a while back while looking for something similar for work.


1

This is a problem when your compile from source or install a package outside of apt (apt-get). Probably the easiest solution is to use checkinstall sudo apt-get install checkinstall Then make and install php make sudo checkinstall checkinstall creates a .deb from your source code, then installs a .deb, so apt will then acknowledge php is installed. ...


1

Download the .deb file of mcrypt for Xubuntu 14.04 from www.ubuntu.com at this link. The linked webpage says Ubuntu, but Xubuntu also has the Ubuntu Software Center in it, so it should be OK. Download the .deb file of php5-mcrypt (MCrypt module for php5) for Xubuntu 14.04 from www.ubuntu.com at this link. In case you want to verify these files after you ...


0

Create a php file with <?php phpinfo(); ?> and open it with your browser. Look for Loaded Configuration File (this shows the actual conf. file in use) and edit upload_max_filesize and set post_max_size to the same value (or make it 0 to disable limit) in that file in root mode. Execute: sudo service apache2 restart



Top 50 recent answers are included