shell
running php file from linux shell vi editor and command line php for non http based files
for creating and executing a php file from ssh you need to PHP installed as binary (CGI) and add something like at top of shell script
[root:inderweb.com]!/usr/bin/php -q
.This is to tell the shell interprator(kernal) that we are using php from bin directory for executing lines of code in script.To get started with a simple php code in shell do following steps:-
- Open shell prompt and go to your directory . e.g [root:inderweb.com ~]
what is shell script and how to use it? starting commands and scripts in linux
"Shell Script is series of linux command written in plain text file . Shell script is just like batch file is MS-DOS but have more power than the MS-DOS batch file e.g it can have the fully programming functionality in it."
shell script variables linux bash shell using ssh from putty for commands
What Are Shell Script Variables?
A variable in a shellscript is a means of referencing a numeric or character value. And unlike formal programming languages, a shell script doesn't require you to declare a type for your variables.
linux mkdir command for creating directory with date which is helpful while cron scripts
mkdir `date +%b%y`
(creates a directory Jul02)
mkdir `date +%b%Y`
(creates a directory Jul2002)
mkdir `date +%m%y`
(creates a directory 0702)
mkdir `date +%m%Y`
(creates a directory 072002)
linux mkdir command for creating directory with date which is helpful while cron scripts
mkdir `date +%b%y`
(creates a directory Jul02)
mkdir `date +%b%Y`
(creates a directory Jul2002)
mkdir `date +%m%y`
(creates a directory 0702)
mkdir `date +%m%Y`
(creates a directory 072002)
![Validate my RSS feed [Valid RSS]](http://feedvalidator.org/images/valid-rss.png)