--enable-force-cgi-redirect

ix

Новичок
--enable-force-cgi-redirect

что это за опция?? кто-нибудь может подробно на русском, желательно, языке мне объяснить?
есть некий скрипт на рнр, который запускается на сервере из шедулера таки образом:
php /path/to/script/name.php par1=val1 par2=val2>res.html & вот результат его работы(res.html):
Content-type: text/html

Security Alert The PHP CGI cannot be accessed directly.

This PHP CGI binary was compiled with force-cgi-redirect enabled. This means that a page will only be served up if the REDIRECT_STATUS CGI variable is
set, e.g. via an Apache Action directive.
For more information as to why this behaviour exists, see the manual page for CGI security.
For more information about changing this behaviour or re-enabling this webserver, consult the installation file that came with this distribution, or visit
the manual page.
воть... когда вызываю этот же скрипт, но из другого скрипта system("php /path/to/script/name.php par1=val1 par2=val2>res.html &") то все: работает...
рнр скомпайлен с этой опцией (см. тему).
может ее: можно как-то "обойти"?
 

ix

Новичок
не-а:( то же самое...
но идею понял, буду пробовать:)
 

fixxxer

К.О.
Партнер клуба
как вариант

#!/bin/sh
REDIRECT_STATUS=blablabla
export REDIRECT_STATUS
php script.php

вот только вопрос что писать вместо blablabla :)
 

ix

Новичок
fixxxer, спасибо, вариант тоже понятен.
насче:т ключа -d : он же только те диррективы меняет, которые в пхп.ини, а насче:т force-cgi-redirect там ничего не сказано.
 
Сверху