Are you a regular stikked user? Signup so you can keep track of your pastes!

RE: RE: Untitled

By Corrupt Treeshrew, 1 Year ago, written in PHP. This paste is a reply to RE: Untitled by Sludgy Kitten
URL http://stikked.com/view/43745894
  1.         function get_id($logindata)
  2.         {
  3.  
  4.                 $this->db->select('id')->from('users')->where('username', $logindata['username']);     
  5.                 $id=$this->db->get();
  6.  
  7.                 return $id;
  8.         }
  9.  
  10. /* ERRORS
  11.  
  12. A PHP Error was encountered
  13.  
  14. Severity: 4096
  15.  
  16. Message: Object of class CI_DB_mysql_result could not be converted to string
  17.  
  18. Filename: libraries/Session.php
  19.  
  20. Line Number: 683
  21.  
  22.  
  23. A PHP Error was encountered
  24.  
  25. Severity: Notice
  26.  
  27. Message: Object of class CI_DB_mysql_result to string conversion
  28.  
  29. Filename: libraries/Session.php
  30.  
  31. Line Number: 683
  32.  
  33.  
  34. A PHP Error was encountered
  35.  
  36. Severity: Warning
  37.  
  38. Message: Cannot modify header information - headers already sent by (output started at C:\xampp\htdocs\site\system\libraries\Exceptions.php:164)
  39.  
  40. Filename: libraries/Session.php
  41.  
  42. Line Number: 662
  43.  
  44.  
  45.  
  46. /*SECOND VERSION */
  47.  
  48.         function get_id($logindata)
  49.         {
  50.                 $this->db->select('id')->from('users')->where('username', $logindata['username']);     
  51.                 $id=$this->db->get();
  52.                 foreach($id->result() as $row)
  53.                 {
  54.                         $guh=$row['id'];
  55.                 }
  56.                 return $guh;
  57.         }
  58.  
  59. /* ERORR
  60.  
  61. Fatal error: Cannot use object of type stdClass as array in C:\xampp\htdocs\site\frontend\models\login_model.php on line 24

Replies to RE: RE: Untitled

Title Name When
RE: RE: RE: Untitled Crippled Gibbon 1 Year ago.

Reply to "RE: RE: Untitled"

Here you can reply to the paste above

Create a snipurl

Make Private

Feeling clever? Set some advanced options.