Advertisement
Sdelkadrom

Untitled

Jun 4th, 2019
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. const USE_VKONTAKTE_YES = 1;
  2. const USE_VKONTAKTE_NO = 0;
  3. const USE_TWITTER_YES = 1;
  4. const USE_TWITTER_NO = 0;
  5.  
  6.  
  7. public static function getUseVkontakteOptions($selected = null)
  8. {
  9. $return[self::USE_VKONTAKTE_YES] = tc('Yes');
  10. $return[self::USE_VKONTAKTE_NO] = tc('No');
  11.  
  12. if ($selected !== null) {
  13. if (isset($return[$selected]))
  14. return $return[$selected];
  15.  
  16. return '-';
  17. }
  18.  
  19. return $return;
  20. }
  21.  
  22. public static function getUseTwitterOptions($selected = null)
  23. {
  24. $return[self::USE_TWITTER_YES] = tc('Yes');
  25. $return[self::USE_TWITTER_NO] = tc('No');
  26.  
  27. if ($selected !== null) {
  28. if (isset($return[$selected]))
  29. return $return[$selected];
  30.  
  31. return '-';
  32. }
  33.  
  34. return $return;
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement