Advertisement
Guest User

Untitled

a guest
Feb 25th, 2020
107
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.65 KB | None | 0 0
  1. <?php
  2. function ChangeStyle($rcaw, $things, $voice) {
  3.     if($rcaw == 't' && $things == 't' && $voice == 't') {
  4.         return 'rcaw-banner-full-mode ';
  5.     }
  6.  
  7.     if($rcaw == 'f' && $things == 'f' && $voice == 'f') {
  8.         return 'all-in-none-mode ';
  9.     }
  10.  
  11.     $key = 0;
  12.  
  13.     $classMap = [
  14.         1 => 'rcaw-banner-none-mode',
  15.         3 => 'things-banner-none-mode',
  16.         4 => 'classA classB',
  17.         5 => 'voice-banner-none-mode',
  18.         6 => 'classC classB',
  19.         8 => 'class dayoos'
  20.     ];
  21.  
  22.     $key += $rcaw == 't' ? 1 : 0;
  23.     $key += $things == 't' ?  3 : 0;
  24.     $key += $voice == 't' ? 5 : 0;
  25.  
  26.     return $classMap[$key];
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement