@stetim94 , It was really a task from the assignment, but it is ok now. I have another queston. How can I replace the the defined string value “None” to another value? Yes, the question looks silly probably, but all the samples I tried to use did not work. I even tried to replace it using built-in function str_replace(), still not working.
For example:
some !DOCTYPE html code
<p>
<?php
$text = "None" ;
$test = FALSE;
if (isset($_POST['user']) {
$ticking = microtime(true);
$input = $_POST['user'];
$create_phrase = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; # It is iterated and concatenated
$show_pos_phrase = 10;
if (show_pos _phrase> 0) {
show_pos _phrase-= 1;
}
print "Time: " $ticking;
?>
</p>
# Here I tried this line code to replace None, but it did not work.
<?php
echo $text; #prints None
if (!$text == $input ){
$test = TRUE;
$input = $text;
echo $input;
}
<p> I would like to replace defined value None for users input<?=htmlspecialchars($tinput);?></p>
<form>
<input type="text" name="user" size="40" />
<input type="submit" value=""User_Input "/>
</form>
I would be glad to know what I’m doing wrong?