backtick operator (``)
this probably isnt so much a question about backticks as it is a question about linux.
im trying to retrieve whois information from my php script.
something like this:
<?php
echo \"<pre>\";
echo `whois somedomain.com 2>&1`;
echo \"</pre>\";
?>
prints out "sh: whois: command not found"
although whois is installed and works from a prompt.
why am i able to use whois through telnet but not from my php scripts? other commands, such as ls, work fine from my script...
Mark Hensler posted this at 02:19 — 11th August 2001.
He has: 4,048 posts
Joined: Aug 2000
well, I'm not a linux expert...
but I think whois is a daemon, right? So wouldn't it have a different permission set than ls?
mairving posted this at 15:15 — 11th August 2001.
They have: 2,256 posts
Joined: Feb 2001
You might try using the full path to whois, usually /usr/bin/whois
Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.