-7
    <?php if ($usertype=='admin'){
  echo '<br> <input type="button" value="Edit Users" onclick="window.location.href='userlist.php'"><br>';
  } ?>

this is ithe code.. Works fine without the url

Johnny
  • 1
  • 2
  • 1
    Not ask syntax error related question it`s not good way to ask question try to solved by self – Reena Mori Jun 29 '17 at 13:24
  • 1
    Atleast Syntax should be solved by a developer itself. – LuFFy Jun 29 '17 at 13:34
  • 1
    Possible duplicate of [PHP Parse/Syntax Errors; and How to solve them?](https://stackoverflow.com/questions/18050071/php-parse-syntax-errors-and-how-to-solve-them) – user3942918 Jul 30 '17 at 12:13

1 Answers1

0
 <?php 
 if ($usertype =='admin' ){
  ?>

 <input type="button" value="Edit Users" onclick="window.location.href='userlist.php'">

 <?php
  } 
?>

NOTE: Please Use https://phpcodechecker.com/
For Syntax Check and For check custom common errors

RïshïKêsh Kümar
  • 4,734
  • 1
  • 24
  • 36