Working on some PHP, and keep encountering the Server error 500.
Here's my code, what am I doing wrong? I've tried a lot, but I have a feeling it's to do with line 17. I'm a novice coder, so I'm probably doing something simply wrong but any help is appreciated.
$category_id = '';
if( isset( $_GET['id'])) {
$category_id = $_GET['id'];
}
for($i = 1; $i < sizeof($category_id); $i++);
include('dbconnect.php');
$title = "SELECT * FROM categories WHERE id = '$i'";
$stmt = $db->prepare($title);
$stmt->execute();
$result = $stmt->fetchAll();
$title = $result(1('name'));
include('base-template.php');