Click here to Skip to main content
15,850,214 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
AnswerRe: Open Suse Linux Pin
Richard MacCutchan27-Dec-16 22:00
mveRichard MacCutchan27-Dec-16 22:00 
GeneralRe: Open Suse Linux Pin
ForNow28-Dec-16 3:11
ForNow28-Dec-16 3:11 
GeneralRe: Open Suse Linux Pin
Richard MacCutchan28-Dec-16 6:45
mveRichard MacCutchan28-Dec-16 6:45 
AnswerRe: Open Suse Linux Pin
Albert Holguin9-Jan-17 8:52
professionalAlbert Holguin9-Jan-17 8:52 
QuestionWhich is the Best Laravel Admin Template with all the advanced functionalities? Pin
Rakeshroshans23-Dec-16 21:00
Rakeshroshans23-Dec-16 21:00 
AnswerRe: Which is the Best Laravel Admin Template with all the advanced functionalities? Pin
Richard MacCutchan23-Dec-16 22:55
mveRichard MacCutchan23-Dec-16 22:55 
Questionfail to run php script as shell Pin
njzt6-Dec-16 16:36
njzt6-Dec-16 16:36 
Hi all,

It's a Nginx and PHP web project, When I run a php script as shell, there shows Access Denide!

PHP
X-Powered-By: PHP/7.0.9
Content-type: text/html; charset=UTF-8

Access Denied!


The php file is like this:
PHP
#!/usr/bin/php-cgi
<?php

require_once("config.php");
require_once("util.php");

...
..
.

file_put_contents($argv[1], CJSON::encode($obj));

?>


I have try to change all the php file as 777, and try to run like this:
./list.php /home/cache.json

/usr/bin/php list.phph  /home/cache.json


Still can not work.

and then I try to make a new php script test.php:
#! /usr/local/php7/bin/php-cgi

<?php
	
	echo "php test";

?>



and then run it:
/usr/local/php7/bin/php-cgi test.php


it works:
[root@localhost ~]#  /usr/local/php7/bin/php-cgi test.php
X-Powered-By: PHP/7.0.9
Content-type: text/html; charset=UTF-8


php test


I don't now why, anyone can help? Thanks for advance.
SuggestionRe: fail to run php script as shell Pin
Richard MacCutchan6-Dec-16 23:03
mveRichard MacCutchan6-Dec-16 23:03 
QuestionDatabase connection refused. Pin
taiwokaffo6-Dec-16 5:16
taiwokaffo6-Dec-16 5:16 
QuestionRe: Database connection refused. Pin
Richard MacCutchan6-Dec-16 5:27
mveRichard MacCutchan6-Dec-16 5:27 
AnswerRe: Database connection refused. Pin
taiwokaffo6-Dec-16 5:45
taiwokaffo6-Dec-16 5:45 
GeneralRe: Database connection refused. Pin
Eddy Vluggen6-Dec-16 5:58
professionalEddy Vluggen6-Dec-16 5:58 
GeneralRe: Database connection refused. Pin
taiwokaffo7-Dec-16 0:06
taiwokaffo7-Dec-16 0:06 
QuestionPHP topic selection for Final year Project Pin
Member 1278820324-Nov-16 3:51
Member 1278820324-Nov-16 3:51 
GeneralRe: PHP topic selection for Final year Project Pin
Kornfeld Eliyahu Peter24-Nov-16 6:08
professionalKornfeld Eliyahu Peter24-Nov-16 6:08 
AnswerRe: PHP topic selection for Final year Project Pin
Richard MacCutchan24-Nov-16 7:37
mveRichard MacCutchan24-Nov-16 7:37 
GeneralRe: PHP topic selection for Final year Project Pin
Member 127882035-Dec-16 23:17
Member 127882035-Dec-16 23:17 
GeneralRe: PHP topic selection for Final year Project Pin
Member 127882036-Dec-16 23:35
Member 127882036-Dec-16 23:35 
QuestionSeveral arrays to one multidimensional Pin
Member 128309193-Nov-16 6:29
Member 128309193-Nov-16 6:29 
AnswerRe: Several arrays to one multidimensional Pin
WildDonkey11-Feb-17 4:59
WildDonkey11-Feb-17 4:59 
QuestionOOP in PHP Pin
Member 1278820328-Oct-16 5:22
Member 1278820328-Oct-16 5:22 
AnswerRe: OOP in PHP Pin
Anurag Gandhi13-Nov-16 7:09
professionalAnurag Gandhi13-Nov-16 7:09 
GeneralRe: OOP in PHP Pin
Peter_in_278013-Nov-16 14:38
professionalPeter_in_278013-Nov-16 14:38 
GeneralRe: OOP in PHP Pin
Member 1278820324-Nov-16 3:03
Member 1278820324-Nov-16 3:03 
GeneralRe: OOP in PHP Pin
Afzaal Ahmad Zeeshan24-Nov-16 3:19
professionalAfzaal Ahmad Zeeshan24-Nov-16 3:19 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.