thanx buddy. it worked, but i again have a small problem. when i pass single word string, it works. but when i passes string with more than one word then it gives error. my code is.....
<?php
/ Get the posted value of the form if there is one /
$p = empty($POST['p']) ? null : $POST['p'];
?>
<html>
<head><title>Hash testing</title></head>
<style type="text/css">
table {border-collapse: collapse;}
table, td, th {border: solid 1px #ccc;}
th {background: #e1e1e1;border-color: #999;}
td, th {padding: 0.25em;}
td.algo {font-weight: bold;}
tr.on td {background: #f0f0f0;}
</style>
<body>
<h1>String hashing</h1>
<form method="post" action="<?php echo basename(FILE) ?>">
<p><label for="p">Enter a string to hash:</label><br /><input id="p" type="text" name="p" value="<?php echo $p ?>" /></p>
<p><input type="submit" name="submit" value="Hash It" /></p>
</form>
<?php / If there is a posted value use it / ?>
<?php if ($p): ?>
<hr />
<h2>Your hash chain for <em><?php echo $p ?></em> is</h2>
<?php
echo passthru("/usr//bin/php/hashargu $p"); //hashargu is exe to which i am passing variable p
?>
<?php endif; ?>
</body>
</html>