<?php <form action="ScoreCardAlpha.php" method="post"> A: <input type="text" name="$X" /> B: <input type="text" name="$Z" /> C: <input type="text" name="$W" /> // read input data on $W , $X or $Z has http// if so save after // if(!filter_has_var(INPUT_post, "$X")) { // if true **** deleate all char upto and including // then post to "$X" **** echo("Input has been adapted and saved"); } else { // if false **** post to "$X" **** echo("Input did not need adapting and has been saved"); } <input type="submit" /> ?>
Maybe I am missing something, but I don't see how the code you provided can even execute. You should get a parse error as soon as it gets to the "<" in <form action="ScoreCardAlpha.php" method="post">