Tag Info

New answers tagged

1

sudo apt-get install curl libcurl3 libcurl3-dev php5-curl After the installation has completed, restart the server sudo service apache2 restart


0

By default, after installing apache2 the website root is located under: /var/www/ or /var/www/html/ (depending on the Ubuntu version you installed). So, in order to test your php, you'll need to move them to that location and set the correct ownership. Again, with apache, the file owner should be the system user www-data. Asuming your file is called ...


1

The simplest way to install all three is to run the lamp-server task: sudo apt-get install lamp-server^ The caret at the end means that this is running a task, not installing a package. There is no lamp-server package, so if you leave off the caret, apt-get will return the error message, Unable to locate package lamp-server. The task will install ...


0

Now I found out what was the problem. It was not any configuration problem with apache or php. It seems, that the Value short_open_tag in default php.ini changed from On to Off. All my php sources starts with <? I did not come up with the idea that this could be the problem and I always tried out various configurations about apache. I could not ...


0

I would write a standard init script with php start.php as the start function. As for the stop function do something like: kill -9 `ps -ef|grep "php Scanner.php"|awk '{ print $2 }'` And you can leave the status function empty.


1

Finally we found out the reason: The problem was that on migration the file containing our DNS-SERVERS was overwritten by Wmvare. Meaning that even though the servers were duplicates the IP for our DNS-servers was changed.. We had no reason to suspect this as it should have been full copy of functioning server


0

Some time it happens that in php.ini, there is some syntax error on some line number for example error_reporting = E_ALL && ~E_DEPRECATED && ~E_STRICT In this case the apache does not load configuration after that line number. So this is bit complex to figure out syntax error in php.ini therefore you should try other ways to fix and you ...


3

You've got 2 possibilities: Restore your System Back-up (you're definitely user type 4) Reinstall and start making System Back-ups There that's it. Those are the 2 quick fixes for your system. Anything else will lead to a lot of headaches, problems cropping up in a few days, weeks, months and even years!


0

I believe i handled it myself. There were two things that i needed to change. 1. pdo_oci.so was being loaded before pdo.so. I changed the order and the error message has been modified. 2. I compiled pdo_oci directly from the source code for my version of php (I followed instructions on: ...


0

your /etc/environment is wrong, yours is: PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/u‌​sr/local/games" JAVA_HOME = ":usr/lib/jvm/java-7-oracle while it should look like: PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/u‌​sr/local/games" JAVA_HOME="/usr/lib/jvm/java-7-oracle"


1

I had the same problem. With lots of Google-ing and trying I figured it out. You need to match what you setup in your virtual host with whats configured in the fastcgi.conf (of php-fpm.conf). Furthermore its beter to use '/fpm-status' and '/fpm-ping' in the /etc/php5/fpm/pool.d/www.conf config. Then you should not have conflicts with Apache's own 'status' ...


2

From this SO answer: You can use umask() immediately before the fopen() call, but umask shouldn't be used if you're on a multi-threaded server - it'll change the mask for ALL threads (e.g. this change is at the process level), not just the one that you're about to use fopen() in. e.g. $old = umask(000); fopen('foo.txt', 'w'); // creates a ...


0

I guess you should use this ppa instead, which doesn't upgrade apache, but only upgrades php to 5.4: https://launchpad.net/~ondrej/+archive/ubuntu/php5-oldstable


0

When debugging PHP code that executes external scripts (R, bash, ...) the easiest thing to do is to install php-cli sudo apt-get install php-google-api-php-client php-cli means "PHP Command Line Interface". As the name suggests, it's is a way of using PHP from the terminal. then execute the script using /usr/bin/php -q <?php YourPHPCodeHere; ?> ...


2

Seems pretty straightforward. Are you sure you're in the correct directory? I actually installed this just the other day. This should work: tar xfz PhpStorm-*.tar.gz cd PhpStorm-139.732/bin ./phpstorm.sh Pay attention to the version in the PhpStorm folder name.


0

Perl compatible regular expressions - PCRE libraries is missing (...fatal error: pcre.h:...), because you are compiling module you should add dev packages too: sudo apt-get update sudo apt-get install libpcre3 libpcre3-dev


1

So, your Linux server has a windows share mounted on a local directory, but apparently you cannot write to it. I suppose that this share has been setup as guest access, hence the read only status. Please refer to the ubuntu documentation on mounting windows share as a starting point to fix this configuration issue. As a work around for the time being, I ...


1

apt-get install apache2* Should just be apt-get install apache2 Apt will suggest some extra packages to install at that point. Read through them and decide if want/need, but I usually only install sudo apt-get install apache2 apache2-utils


0

Solved! Solution: in the Soap Webservice we were using PHP classes, PHP casted the webservice request (stdClass Object) to our custom classes. We never thought that might be a problem, course there where no errors thrown. But anyway, after we manually converted the stdClass objects in our custom objects, everything seems to work as expected. ...


0

Apache2 is working in my system so try follow this: Please remove already you installed apache2 and php5. Now try to a fresh installation. You add source code to apt sources list. gedit /etc/apt/sources.list to add following codes: deb http://ppa.launchpad.net/ondrej/php5/ubuntu precise main deb-src http://ppa.launchpad.net/ondrej/php5/ubuntu ...


0

Open your httpd.conf file. It's usually under ~\etc\httpd.conf. There you will find a line like this DocumentRoot "/var/www/html" <Directory "/var/www/html"> Change it to your desired path and restart the server. It should solve your problem..


1

Yes, enable the userdir module for Apache (I'm unfamiliar with lamp-server, normally you just run sudo a2enmod userdir but you'll have to figure out how to enable the module). Once enabled, you can create a public_html directory inside your home, ensure your home and public_html have world read permissions, and you can put your PHP scripts in your ...


0

You should not do this from a PHP script. Shutting down your PC accessible from the web sounds like a really bad idea. I myself would make a shell script, and execute it when needed. For example this script would be saved on the desktop: #!/bin/sh shutdown -HP 1 And if you run it, this shuts down the computer in one minute.



Top 50 recent answers are included