Advertisement
sanjiisan

Untitled

Apr 5th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. plik1:
  2.  
  3. <?php
  4.  
  5. if ($_SERVER['REQUEST_METHOD'] === 'GET') {
  6. if (isset($_GET['start']) && isset($_GET['end'])) {
  7.  
  8. $start = trim($_GET['start']);
  9. $end = trim($_GET['end']);
  10.  
  11. for ($i = $start; $i <= $end; $i++) {
  12. echo $i . '<br>';
  13. }
  14. } else {
  15. echo 'Nie ma wszystkich danych';
  16. }
  17. }
  18.  
  19.  
  20. plik2:
  21.  
  22. <?php
  23.  
  24. for ($i = 0; $i < 99; $i++) {
  25.  
  26. $start = $i * 2;
  27. $end = $i * 3;
  28.  
  29. echo "<a href='zadanie2.php?start=$start&end=$end'>Link $start do $end</a><br>";
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement