Advertisement
Guest User

Untitled

a guest
Oct 7th, 2015
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. <?php
  2. trait a{
  3. function ab(){
  4. echo "trait a";
  5. }
  6. }
  7. trait b{
  8. function ba(){
  9. echo "<br> trait b";
  10. }
  11. }
  12. trait c{
  13. use a,b;
  14. function abc(){
  15. $this->ab();
  16. $this->ba();
  17. }
  18. }
  19. class abx{
  20. use c;
  21. }
  22. $a=new abx;
  23. $a->abc();
  24.  
  25. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement