Summary | Wrong Path from lib/Horde.php - selfUrl with FastCGI |
Queue | Horde Framework Packages |
Queue Version | FRAMEWORK_3 |
Type | Bug |
State | Not A Bug |
Priority | 1. Low |
Owners | |
Requester | eric (at) wwwx (dot) de |
Created | 07/09/2006 (6952 days ago) |
Due | |
Updated | 08/04/2006 (6926 days ago) |
Assigned | 07/10/2006 (6951 days ago) |
Resolved | 08/04/2006 (6926 days ago) |
Github Issue Link | |
Github Pull Request | |
Milestone | |
Patch | No |
State ⇒ Not A Bug
State ⇒ Feedback
a unified diff. Thanks!
Priority ⇒ 1. Low
Type ⇒ Bug
Summary ⇒ Wrong Path from inc/Horde.lib - selfUrl with FastCGI
Queue ⇒ Horde Framework Packages
State ⇒ Unconfirmed
Bugfix :
Change selfUrl to :
function selfUrl($script_params = false, $nocache = true, $full = false,
$force_ssl = false)
{
if (substr(php_sapi_name(), 0, 3) == 'cgi') {
// When using CGI PHP, SCRIPT_NAME may contain the path to
// the PHP binary instead of the script being run; use
// PHP_SELF instead.
$url = $_SERVER['PHP_SELF'];
} else {
$url = isset($_SERVER['SCRIPT_NAME']) ?
$_SERVER['SCRIPT_NAME'] :
$_SERVER['PHP_SELF'];
}
if ($script_params) {
if (substr(php_sapi_name(), 0, 7) == 'cgi-fcgi') {
if (!empty($_SERVER['PATH_INFO'])) {
$url .= $_SERVER['PATH_INFO'];
}
};
if (!empty($_SERVER['QUERY_STRING'])) {
$url .= '?' . $_SERVER['QUERY_STRING'];
}
...
My PHP Compile Options :
./configure' '--with-config-file-path=/etc/httpd' '--with-gd=yes'
'--with-freetype-dir=/usr' '--with-jpeg-dir=/usr'
'--with-png-dir=/usr' '--with-zlib-dir=/usr' '--with-mysql=/usr'
'--with-gd=/usr' '--enable-memory-limit' '--enable-force-cgi-redirect'
'--enable-track-vars' '--with-openssl=/usr' '--without-mm'
'--enable-fastcgi' '--prefix=/usr/local/phpfcgi' '--with-gettext'
'--with-dom' '--with-imap' '--with-ldap' '--with-kerberos'
'--with-imap-ssl'