Guest User

Untitled

a guest
Jul 21st, 2018
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.70 KB | None | 0 0
  1. <?php
  2. /** The class is defined for all data base related functions
  3. */
  4. class Users extends Zend_Db_Table_Abstract
  5. {
  6. protected $db;
  7. public function __construct() {
  8. $this->db = Zend_Registry::get('db');
  9. }
  10.  
  11. public function findCredentials($username, $pwd) {
  12. $this->db->setFetchMode(Zend_Db::FETCH_OBJ);
  13. $select = "select * from ourbank_userloginupdates where Username = '".$username."' && Password ='".$pwd."'";
  14. $row = $this->fetchRow($select);
  15. if($row) { /*
  16. * If success return the row
  17. */
  18. return $row;
  19. }
  20. return false;
  21. }
  22.  
  23.  
  24.  
  25.  
  26. }
Add Comment
Please, Sign In to add comment