I am trying to pass the argument to my bash script through my cgi script. This may sound a little bit confusing, so here is the explanation,
I have bash script called
bash script.sh myName
`/bin/echo "bash script.sh myName"`;
In the comments to the question you wrote that the CGI script was written in CSH.
Then it's as simple as the following.
#!/bin/csh ./script.sh argX
#!/bin/bash echo 'hello,' $1
./script.csh hello, argX
It it isn't what you are looking for, please clarify.