|
I want to determine if using Apache's .htaccess mod rewrite is a faster way to redirect to a PHP file, compared to redirecting from one PHP file to another, using the header redirect core function of PHP.
I looked around and I was unable to find anything...
Started by thecrandallster on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at serverfault):
Using PHP header : request comes in, is processed by Apache, then given to PHP, then PHP sends be slow, but Apache is a C program already in memory, and PHP is an interpreted language, which has" a request to....
|
|
Normally when I want to run a php script from the command line I just create a php page, add a shebang pointing to the php binary, then ./file.php to run it. Since I have php installed as an apache module, I'm not even sure what my shebang should look...
Started by David on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Like this:
$ cat run_php_with_apache #!/bin/sh cp "$1" /var/www/ curl "http://localhost/`basename "$1If it's just an Apache module, I don't think you can do it… At least, not without using a script"`" rm "/var/www/`basename "$1"`....
|
|
I've got a VPS using Suse Linux 10.3 .
Apache 2 / PHP 5.2.6 was set up automatically.
When I look at this valid PHP file in a browser, it displays correctly:
<?php echo 'this is test'; ?>
However, when I look at this invalid PHP file , I expect ...
Started by Edward Tanguay on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at serverfault):
PHP logging can get lost between other errors....
This is the file specified in the relevant ErrorLog setting for your server or virtual host section .
Display_errors = On
?
Normally, web applications will log errors to the Apache error log.
|
Ask your Facebook Friends
|
Is there any way, from a PHP script called from mod_php with apache, to tell apache to do an INTERNAL redirect to some other file?
I do not want to read/require this file from PHP and spit it out, I think it'd be more efficient to pass this off to Apache...
Started by bnjmnhggns on
, 5 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Will work if you're just calling HTML or PHP pages, plus be portable to other PHP installations of the docs for header() in PHP indicates that sending a Location: header is always an EXTERNAL.
|
|
Hi,
is there anyone who knows how to install / configure php under apache?
I have emerge php apache both. I wanted to use mod_php for apache in GENTOO OS.
php temp.php
command line runs fine, but http://localhost/temp.php is not executing on web server...
Started by shahjapan on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
:-)
The corresponding lines I have in my Apache's configuration (Apache 2, PHP 5.2, Ubuntu) are :
LoadModule-php .php .phtml AddType application/x-httpd-php-source .phps </IfModule>
After emerging apache....
|
|
Is there anyway to run R scripts through Apache and PHP? I would like to be able to pass variables from PHP to R.
Has anyone done something like this?
Essentially, I would like to know if there is a method for passing variables from PHP to R on an apache...
Started by Brandon Bertelsen on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
R-php is actively....
R_PHP_Online by Steve Chen.
On RApache: http://www.stat.ucla.edu/~jeroen/
Another solution for integrationg PHP, Apache and R mightSee the R-FAQ :
Two projects use PHP to provide a web interface to R.
|
|
Editing Apache Conf File
Using Notepad open httpd.conf (should be start-menu shortcut "Apache HTTP Server 2.2 > Configure Apache Server > Edit the Apache httpd.conf Configuration File"). Either at the very beginning or end of the file add the following...
Started by Warrior on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at serverfault):
As an alternative, drop the PHPIniDir command a trailing / to the PHPIniDir
PHPIniDir "C:/php/"
The only other alternative that I know of to XAMPP called php.conf, in that ....
Well WAMP stacks) that contain Apache, MySQL and PHP.
|
|
Hi. it seems that some of my php applications require php 5.2 and some require php 5.3. is there a way to configure apache (v2.2.14) that one virtualhost will work with one php library and a different virtualhost will require a different one?
currently...
Started by ufk on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at serverfault):
Modify the PHP source code ....
Correct the problems in the PHP scripts (imho the best way) 2.
If you would use php 4 and 5 it would be easy to manipulate what module you want to use whit:
So there 3 ways to deal with this problem: 1.
|
|
Hi,
I have a need to start the Apache service with a parameter so that I can later access that parameter via PHP. Is this possible?
Started by Tower on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
FOO can now be accessed from PHP like so:
<?php print getenv('FOO');
prints
bar.
|
|
I have a PHP page that gets its content by making an HTTP request to another site on the same server , using file_get_contents . Both sites run in Apache 2 which calls PHP using suPHP (which is FastCGI, right?)
How significant is the overhead of this ...
Started by Bart van Heukelom on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
So best method is to install PHP as apache modul
Apache's over headUnfotunatly installing PHP as cgi, you will loose alot of performace, because eachtime you have, i dont nessecarily see a ....
To create a new process for it.
|