[Solved] if statement with $_GET[‘part’]


Wouldn’t this be easier?

<?php
switch ($_GET['part'])) {
    case '1':
       ## part 1
       ## Some content
       break;
    case '2':
       ## part 2
       ## Some content
       break;
    case '3':
       ## Part 3
       ## Some content
       break;
    default:
       header('Location: index.php?part=1');
}
?>

2

solved if statement with $_GET[‘part’]