Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form action='' method='get'>
- Enter the text:
- <input type='text' name='name' placeholder='name' > <br>
- Times to print:
- <input type='text' name='number'> <br>
- <input type='submit' value='Go'>
- </form>
- <?php
- if(isset($_GET['name']) AND isset($_GET['number']) )
- {
- $data = $_GET['name'];
- $num = $_GET['number'];
- echo "<br>";
- for($count=0;$count<$num;$count=$count+1)
- {
- if($count%2)
- echo "<span style='background-color:yellow;color:red'>".$data."</span> \n <br>";
- else
- echo $data."\n <br>";
- }
- }
- else
- exit;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement