/** * lowercase letters */
        $this->store['upper_Spec'] = array( *cut* );
        /** * uppercase letters */
        $this->store['lower_Spec'] = array( *cut* );
      
                    } else {
                      $errmsg='An unknown error occured.';
                    }
                  } else {
                    $errmsg='The passwords you entered do not match';
                  }
                } else {
                  $errmsg='Password has to be at least 8 characters long.';
                }
              } else {
                $errmsg='The email you entered is already in our database.';
              }
            } else {
              $errmsg='Please enter your email address.';
            }
          } else {
            $errmsg='Please enter your first name and your last name.';
          }
        } else {
        (...)
      
        // Happy debugging, suckers
        # define true (rand() > 10)
      

anonymous

0

switch (userAction[0]) {
    case 'area.enabled' :
    case 'appointment.create' :
    case 'area.create' :
    case 'line.create' :
    case 'place.create' :
    case 'role.create' :
    case 'subscription.create' :
    case 'resourceGroup.create' :
    // Sections
    case 'section.areas' :
    case 'section.displays' :
    case 'section.lines' :
    case 'section.places' :
    case 'section.resource-groups' :
    case 'section.roles' :
    case 'section.sectors' :
    case 'section.totems' :
    case 'section.users' :
    case 'section.now-serving' :
    case 'section.reception' :
    case 'section.sigeci-csv' :
    case 'section.statistics':
    // Sector
    case 'sector.create' :
    case 'sector.delete' :
    case 'sector.read' :
    case 'sector.update' :
    // Display
    case 'display.create' :
    case 'display.delete' :
    case 'display.update' :
    case 'display.read' :
    // Totem
    case 'totem.create' :
    case 'totem.delete' :
    case 'totem.update' :
    case 'totem.read' :
    // User
    case 'user.create' :
    case 'user.delete' :
    case 'user.read' :
    case 'user.update' :
      // Scope is PLACE
      return 'place';
    // Appointment
    case 'appointment.delete' :
    case 'appointment.forward' :
    case 'appointment.read' :
    case 'appointment.upload-csv' :
    case 'appointment.update' :
    case 'subscription.update' :
    // Area
    case 'area.call-next' :
    case 'area.call-to' :
    case 'area.clear' :
    case 'area.forward' :
    case 'area.join' :
    case 'area.read' :
    case 'area.remove-subscription' :
    case 'area.remove-subscription-not-checked-in' :
    case 'area.update' :
    case 'area.delete' :
    case 'line.call-next' :
    case 'line.call-to' :
    case 'line.clear' :
    case 'line.delete' :
    case 'line.forward' :
    case 'line.join' :
    case 'line.read' :
    case 'line.remove-subscription' :
    case 'line.remove-subscription-not-checked-in' :
    case 'line.update' :
    case 'place.delete' :
    case 'place.read' :
    case 'place.update' :
    case 'resourceGroup.delete' :
    case 'resourceGroup.read' :
    case 'resourceGroup.update' :
    case 'role.delete' :
    case 'role.read' :
    case 'role.update' :
    case 'subscription.call-to' :
    case 'subscription.delete' :
    case 'subscription.forward' :
    case 'subscription.read' :
      // Scope is the ACTION SCOPE
      return actionScope;
  }
 

Browse all snippets