Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. Linux, Apache, MySQL, PHP
  4. need help with php parse error

need help with php parse error

Scheduled Pinned Locked Moved Linux, Apache, MySQL, PHP
javascriptdatabasehelpphphtml
2 Posts 2 Posters 3 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    Izu Great
    wrote on last edited by
    #1

    i am working on a project and on a page i get this error. Parse error: parse error in C:\wamp\www\RMS\comresult.php on line 143 line 143 is the last line of my code. Please i need help. Here is my code:

    <?php
    include("conn.php");
    session_start();
    ?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>Welcome :: Result Portal</title>
    <link href="style.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
    body {
    background-color: #FFF;
    }
    </style>
    <!--[if IE]>
    <script src="ie/dist/html5shiv.js"></script>
    <script src="ie/dist/html5shiv-printshiv.js"></script>
    <![endif-->
    <script type="text/javascript">
    function bk(){
    location.assign(document.referrer);
    }
    var state = true;

    function getstate(){
    return state;
    }
    </script>
    </head>

    <body onload="print()">
    <?php
    if(isset($_GET['lev'],$_GET['sem'],$_GET['prog'],$_GET['sess'])){
    $level = $mysqli->real_escape_string(trim($_GET['lev']));
    $sem = $mysqli->real_escape_string(trim($_GET['sem']));
    $prog = $mysqli->real_escape_string(trim($_GET['prog']));
    $sess = $mysqli->real_escape_string(trim($_GET['sess']));

    $sql = "SELECT \* FROM course\_tb WHERE level LIKE '".$level."' AND semester LIKE '".$sem."'";
    if($result = $mysqli->query($sql)){
        if($result->num\_rows > 0){
    
        $sel = "SELECT DISTINCT regno FROM st\_result\_data WHERE level LIKE '".$level."' AND semester LIKE '".$sem."' AND programme LIKE '".$prog."'";
    
        if($res = $mysqli->query($sel)){
            if($res->num\_rows > 0){
    
                //$sel2 = "SELECT \* FROM st\_result\_data WHERE regno LIKE '".$row\['regno'\]."' AND level LIKE '".$level."' AND semester LIKE '".$sem."' AND programme LIKE '".$row\['programme'\].&
    
    L 1 Reply Last reply
    0
    • I Izu Great

      i am working on a project and on a page i get this error. Parse error: parse error in C:\wamp\www\RMS\comresult.php on line 143 line 143 is the last line of my code. Please i need help. Here is my code:

      <?php
      include("conn.php");
      session_start();
      ?>
      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml">
      <head>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
      <title>Welcome :: Result Portal</title>
      <link href="style.css" rel="stylesheet" type="text/css" />
      <style type="text/css">
      body {
      background-color: #FFF;
      }
      </style>
      <!--[if IE]>
      <script src="ie/dist/html5shiv.js"></script>
      <script src="ie/dist/html5shiv-printshiv.js"></script>
      <![endif-->
      <script type="text/javascript">
      function bk(){
      location.assign(document.referrer);
      }
      var state = true;

      function getstate(){
      return state;
      }
      </script>
      </head>

      <body onload="print()">
      <?php
      if(isset($_GET['lev'],$_GET['sem'],$_GET['prog'],$_GET['sess'])){
      $level = $mysqli->real_escape_string(trim($_GET['lev']));
      $sem = $mysqli->real_escape_string(trim($_GET['sem']));
      $prog = $mysqli->real_escape_string(trim($_GET['prog']));
      $sess = $mysqli->real_escape_string(trim($_GET['sess']));

      $sql = "SELECT \* FROM course\_tb WHERE level LIKE '".$level."' AND semester LIKE '".$sem."'";
      if($result = $mysqli->query($sql)){
          if($result->num\_rows > 0){
      
          $sel = "SELECT DISTINCT regno FROM st\_result\_data WHERE level LIKE '".$level."' AND semester LIKE '".$sem."' AND programme LIKE '".$prog."'";
      
          if($res = $mysqli->query($sel)){
              if($res->num\_rows > 0){
      
                  //$sel2 = "SELECT \* FROM st\_result\_data WHERE regno LIKE '".$row\['regno'\]."' AND level LIKE '".$level."' AND semester LIKE '".$sem."' AND programme LIKE '".$row\['programme'\].&
      
      L Offline
      L Offline
      Lost User
      wrote on last edited by
      #2

      You already posted this question at http://www.codeproject.com/Messages/4803483/need-help-with-php-parse-error.aspx[^]; please do not repost.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups