Advertisement
Guest User

Untitled

a guest
Oct 6th, 2016
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.35 KB | None | 0 0
  1. <?php
  2.  
  3. class User
  4. {
  5.     protected $login;
  6.     protected $password;
  7.     public function __construct($_POST['login'], $_POST['password'])
  8.     {
  9.         $login->login = $_POST['login'];
  10.         $password->password = $_POST['password'];
  11.     }
  12.  
  13.     public function getData()
  14.     {
  15.         return login;
  16.         return password;
  17.     }
  18.        
  19. }
  20.  
  21. $newUser = new User();
  22.  
  23. $newUser->getData();
  24. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement