Quantcast
Channel: UNIX and Linux Forums
Viewing all articles
Browse latest Browse all 16232

Submit button to run sed command in html

$
0
0
Hello,
I am running a linux server and sometimes I need to check log files and create my own reports. Since I am the owner of this pc, I am able to login through ssh and run sed command to extract requested data from my log file.

But I also want to allow my friend to access to my webpage (not via ssh) and create his own reports.

What I want to do is summarized in following lines:

1) I will create a webpage folder which is closed to unauthorised access and I will give him a user&pass to open the page.. (this is no problem)

2) After his succesful login, a webpage will be displayed and he will be requested to enter a "word" to look up in log file.

3) After entering the word, user will click on "submit" button and it will run sed command in the webpage

4) When the output file is created, script will send it as email or file will be copied into /var/www/html/report****.html (this step is no problem)

Could you please give an idea about how remark 2 & 3 could be done?

PS: As I am not familiar with PHP, I afraid of working on such cases when somebody redirect me solve the puzzle by means of PHP...


thanks in advance
Boris

Viewing all articles
Browse latest Browse all 16232

Trending Articles