我的PHP代码中出现了一些语法错误,我无法解决

I am getting some syntax error in my PHP code, which I am unable to solve. Please have a look at this and help me to solve this. Here Is The Screenshot.

I have attached the screenshot of the error which I am getting on line 14.

<?php
    $link = mysqli_connect('localhost','root','','satyam');
    if(isset($_POST['name']))
    {
        $name = $_POST['name'];
        $sql = "SELECT * FROM students WHERE name='".$name."'";
        $sql_run = mysqli_query($link,$sql);
        if($row=mysqli_fetch_array($sql_run))
        {
            $name = $row["name"];
            $roll = $row["roll"];
            $branch = $row["branch"];
            $address = $row["address"];
            echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address';
        } else {
            echo "No Record Found";
        }
    }
?>

You added an extra unnecessary single quote (') end of the following line

echo 'Name: ' . $name . ' Roll: ' . $roll . ' Branch: ' . $branch . ' Address: ' . $address;

This code works fine.

$link = mysqli_connect('localhost','root','','satyam');
if(isset($_POST['name'])) {
    $name    = $_POST['name'];
    $sql     = "SELECT * FROM students WHERE name='" . $name."'";
    $sql_run = mysqli_query($link,$sql);
    if($row = mysqli_fetch_array($sql_run)) {
        $name    = $row["name"];
        $roll    = $row["roll"];
        $branch  = $row["branch"];
        $address = $row["address"];
        echo 'Name: ' . $name . ' Roll: ' . $roll . ' Branch: ' . $branch . ' Address: ' . $address;
    } else {
        echo "No Record Found";
    }
}

You have an extra ' at the end of :

echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address';

after $address

Please check this :

<?php
$link = mysqli_connect('localhost','root','','satyam');
if(isset($_POST['name']))
{
    $name = $_POST['name'];
    $sql = "SELECT * FROM students WHERE name='".$name."'";
    $sql_run = mysqli_query($link,$sql);
    if($row=mysqli_fetch_array($sql_run))
    {
        $name = $row["name"];
        $roll = $row["roll"];
        $branch = $row["branch"];
        $address = $row["address"];
        echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address;
    } else {
        echo "No Record Found";
    }
}
?>

You added a extra ' on this line :

echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address;

This line:

echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address';

Should be:

echo 'Name: '.$name.' Roll: '.$roll.' Branch: '.$branch.' Address: '.$address;

remove the quotation mark (') at the end of line 14 (the one next to the semicolon).