title: Implement different user level views in php
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/8896835/implementing-user-authorization-in-php-and-javascript">Implementing User Authorization in PHP and Javascript</a>  </p>
  </blockquote>
  
  
  
  <p>I have a basic accounting system with the following users and user levels,</p>
  
  <p><strong>(User Name, Password, User Level)</strong></p>
  
  <p><strong>A</strong>, 123, <em>Admin</em></p>
  
  <p><strong>B</strong>, 456, <em>Accountant</em></p>
  
  <p><strong>C</strong>, 789, <em>Staff Member</em></p>
  
  <p><strong>D</strong>, 999, <em>Manager</em></p>
  
  <p>I need to provide them with different selected information based on their user level. For example, </p>
  
  <p>-only <strong>admins</strong> have privileges of creation and deletion of user accounts</p>
  
  <p>-<strong>staff</strong> only has privileges to view sales and purchasing information</p>
  
  <p>-only <strong>accountants</strong> have privileges to record accounting entries</p>
  
  <p>-only <strong>managers</strong> and <strong>accountants</strong> have privileges to view management reports</p>
  
  <p>How can i implement this using PHP(OOP)?</p>
  
  <p>Thank you.</p>