text stringlengths 29 2.99M |
|---|
<?php
use App\Http\Controllers\Admin\MenuController;
use App\Http\Controllers\Admin\OrderController;
use App\Http\Controllers\Admin\ProductController;
use App\Http\Controllers\Admin\SliderController;
use App\Http\Controllers\Admin\UploadController;
use App\Http\Controllers\Admin\Users\LoginController;
use App\Http\Controllers\CartController;
//use App\Http\Controllers\Admin\Users\MainController;
use App\Http\Controllers\MainController;
use App\Http\Controllers\MenuController as ControllersMenuController;
use App\Http\Controllers\ProductController as ControllersProductController;
use Illuminate\Support\Facades\Route;
Route::get('/Admin/users/login',[LoginController::class,'index'])->name('login');
Route::post('/admin/users/login/store',[LoginController::class,'store']);
Route::middleware(['auth'])->group(function () {
Route::prefix('admin')->group(function () {
Route::get('main',[MainController::class,'index'])->name('admin.main');
//Menus
Route::prefix('menus')->group(function() {
Route::get('/add',[MenuController::class,'create'])->name('admin.menu.add');
Route::post('/add',[MenuController::class,'store']);
Route::get('/list',[MenuController::class,'index'])->name('admin.menu.list');
Route::delete('/destroy',[MenuController::class,'destroy']);
Route::get('/edit/{menu}',[MenuController::class,'show']);
Route::post('/edit/{menu}',[MenuController::class,'update']);
});
Route::prefix('products')->group(function() {
Route::get('list',[ProductController::class,'index'])->name('admin.product.list');
Route::get('add',[ProductController::class,'add']);
Route::post('add',[ProductController::class,'store']);
Route::get('/edit/{product}',[ProductController::class,'show']);
Route::post('edit/{product}',[ProductController::class,'update']);
Route::delete('/destroy',[ProductController::class,'destroy']);
});
//Slider
Route::prefix('slider')->group(function() {
Route::get('list',[SliderController::class,'index'])->name('admin.slide.list');
Route::get('add',[SliderController::class,'add']);
Route::post('add',[SliderController::class,'store']);
Route::get('/edit/{slider}',[SliderController::class,'show']);
Route::post('edit/{slider}',[SliderController::class,'update']);
Route::delete('/destroy',[SliderController::class,'destroy']);
});
Route::prefix('orders')->group(function() {
Route::get('list',[OrderController::class,'list']);
Route::get('view/{id}',[OrderController::class,'view']);
});
//upload
Route::post('upload/service',[UploadController::class,'upload']);
});
});
Route::get('/',[MainController::class,'index']);
Route::post('/loadProduct',[MainController::class,'loadProduct']);
Route::get('/danh-muc/{id}-{slug}',[ControllersMenuController::class,'index']);
Route::get('/san-pham/{id}/{slug}',[ControllersProductController::class,'index']);
Route::get('/service/product/Preview',[MainController::class,'productPreview']);
//Cart
Route::post('add-cart',[CartController::class,'index']);
Route::get('/cart',[CartController::class,'show']);
Route::post('/update-cart',[cartController::class,'update']);
Route::get('/carts/delete/{id}',[CartController::class,'delete']);
Route::post('/cart',[CartController::class,'add']);
|
<?php
//============================================================+
// File name : example_018.php
// Begin : 2008-03-06
// Last Update : 2011-10-01
//
// Description : Example 018 for TCPDF class
// RTL document with Persian language
//
// Author: Nicola Asuni
//
// (c) Copyright:
// Nicola Asuni
// Tecnick.com s.r.l.
// Via Della Pace, 11
// 09044 Quartucciu (CA)
// ITALY
// www.tecnick.com
// info@tecnick.com
//============================================================+
/**
* Creates an example PDF TEST document using TCPDF
* @package com.tecnick.tcpdf
* @abstract TCPDF - Example: RTL document with Persian language
* @author Nicola Asuni
* @since 2008-03-06
*/
require_once('tcpdf/config/lang/eng.php');
require_once('tcpdf/tcpdf.php');
include("../Model/connection.php");
include("../Model/CustomerClass.php");
include("Customers/CustomerView.php");
// create new PDF document
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
//set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
$pdf->SetHeaderMargin(PDF_MARGIN_HEADER);
$pdf->SetFooterMargin(PDF_MARGIN_FOOTER);
//set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
//set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
// set some language dependent data:
$lg = Array();
$lg['a_meta_charset'] = 'UTF-8';
$lg['a_meta_dir'] = 'rtl';
$lg['a_meta_language'] = 'fa';
$lg['w_page'] = 'page';
//set some language-dependent strings
$pdf->setLanguageArray($lg);
// ---------------------------------------------------------
// set font
$pdf->SetFont('dejavusans', '', 12);
// add a page
$pdf->AddPage();
// Restore RTL direction
$pdf->setRTL(true);
// set font
$pdf->SetFont('aefurat', '', 18);
// print newline
$pdf->Ln();
// Arabic and English content
$pdf->Cell(0, 12, 'المعالجات',0,1,'C');
$htmlcontent = 'كتير منيح';
$pdf->WriteHTML($htmlcontent, true, 0, true, 0);
//.................................................................................................................
//...................................................................................medicine
$pdf->AddPage();
$pdf->Cell(0, 12, 'المداواة',0,1,'C');
$htmlcontent1 = 'كتير منيح';
$pdf->WriteHTML($htmlcontent1, true, 0, true, 0);
//.................................................................................................................
//...................................................................................operation
$pdf->AddPage();
$pdf->Cell(0, 12, 'العمليات',0,1,'C');
$htmlcontent2 = 'كتير منيح';
$pdf->WriteHTML($htmlcontent2, true, 0, true, 0);
// ---------------------------------------------------------
//Close and output PDF document
$pdf->Output('example_018.pdf', 'I');
//============================================================+
// END OF FILE
//============================================================+
|
<?php
/**
* Created by PhpStorm.
* User: wu
* Date: 2020/3/16
* Time: 14:05
*/
namespace App\Http\Common;
class Common
{
/**
* 时间搜索插件封装
* @param $timeset
* @return array
*/
function get_time_search($timeset)
{
switch ($timeset) {
case 1;//昨天
$stime = strtotime('-1 day' . ' 0:0:0');
$etime = strtotime('-1 day' . ' 23:59:59');
break;
case 2;//今天
$stime = strtotime(date('Y-m-d', time()) . ' 0:0:0');
$etime = strtotime(date('Y-m-d', time()) . ' 23:59:59');
break;
case 3;//上周
$stime = mktime(0, 0, 0, date('m'), date('d') - date('w') + 1 - 7, date('Y'));
$etime = mktime(23, 59, 59, date('m'), date('d') - date('w') + 7 - 7, date('Y'));
break;
case 4;//上月
$stime = strtotime(date('Y-m-01 00:00:00', strtotime('-1 month')));
$etime = strtotime(date("Y-m-d 23:59:59", strtotime(-date('d') . 'day')));
break;
case 5;//本月
$stime = mktime(0, 0, 0, date('m'), 1, date('Y'));
$etime = mktime(23, 59, 59, date('m'), date('t'), date('Y'));
break;
case 6;//所有时间
$stime = strtotime('2020-3-10' . ' 0:0:0');
$etime = strtotime('2030-3-10' . ' 23:59:59');
break;
}
return ['stime'=>$stime,'etime'=>$etime];
}
} |
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateRatesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('rates', function (Blueprint $table) {
$table->bigIncrements('id');
$table->string('dia');
$table->integer('tarifa');
$table->timestamps();
});
DB::table('rates')->insert(array('dia'=>'Lunes', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Martes', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Miercoles', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Jueves', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Viernes', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Sabado', 'tarifa'=>'0'));
DB::table('rates')->insert(array('dia'=>'Domingo','tarifa'=>'0'));
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('rates');
}
}
|
<?php
namespace App\Http\Controllers;
use App\Department;
use App\RoleUser;
use Illuminate\Http\Request;
use App\User;
use App\DepartmentUser;
use App\Role;
use Illuminate\Support\Facades\Session;
use Illuminate\Support\Facades\Storage;
use Illuminate\Support\Facades\Auth;
class UsersController extends Controller
{
public function getAllUsers()
{
return User::all();
}
public function getAllUsersWithDepartments()
{
$users = User::with(['departments','roles'])->paginate(10);//
return($users);
}
public function anyData()
{
$users=$this->getAllUsersWithDepartments();
if(Auth::user()->hasRole('administrator')){
return view('users.index',compact('users'));
}
else{
return view('users.indexEmp',compact('users'));
}
//return(compact('users'));
}
public function getAllUserInfo($id){
//$user=User::find($id)->with(['departments','userRole'])->first();
$user=User::where('id', $id)
->with(['departments','userRole'])->first();
return($user);
}
public function show($id)
{
$user=$this->getAllUserInfo($id);
$departments=Department::all();
$roles=Role::all();
return view('users.show',compact('user','departments','roles'));
//return(dd($user));
}
public function info($id){
$user=$this->getAllUserInfo($id);
$img = Storage::url($user->image_path);
if($img=="/storage/"){
$img=Storage::url('default_avatar.jpg');}
return view('users.info',compact('user','img'));
//return(dd($img));
}
public function update(Request $request){
//return dd($request);
if ($request->hasFile('image_path')) {
if (!is_dir(public_path(). '/storage/users')) {
mkdir(public_path(). '/storage/users', 0777, true);
}
$file = $request->file('image_path');
$destinationPath = public_path(). '/storage/users/'.$request->id;
$filename = str_random(8) . '_' . $file->getClientOriginalName() ;
$file->move($destinationPath, $filename);
}
$user=User::where('id', $request->id)
->with(['departments','userRole'])->first();
$user->name=$request->name;
$user->email=$request->email;
$user->password=bcrypt($request->password);
$user->work_number=$request->work_number;
$user->personal_number=$request->personal_number;
if($request->hasFile('image_path')){
$user->image_path=$filename;
}
$user->save();
//$depuser='';
//$depuser=DepartmentUser::where('user_id', '=', $request->id)->first();;
foreach ($user->departments as $dep) {
if ($dep->id != $request->department) {
$depuser=DepartmentUser::where('user_id', '=', $request->id)->first();
// DepartmentUser::where('user_id', $request->id)
// ->where('department_id', $dep->id)
// ->update(['department_id' => $request->department]);
$depuser->department_id=$request->department;
$depuser->save();
}
}
foreach ($user->roles as $role) {
if ($role != $request->role) {
// RoleUser::where('user_id', $request->id)
// ->where('role_id', $role->id)
// ->update(['role_id' => $request->role]);
$roleuser=RoleUser::where([['user_id', $request->id],['role_id', $role->id]])->first();
$roleuser->role_id=$request->role;
$roleuser->save();
// $user=RoleUser::where([['user_id',$request->id],['role_id',$role->id]])->first();
// $user->role_id=$request->role;
// $user->save();
}
}
//return(dd($request->file('image_path')));
return redirect(route('users.data'));
//return(dd($user1->departments));
}
public function addForm(){
$departments=Department::all();
$roles=Role::all();
return view('users.add',compact('departments','roles'));
}
public function create(Request $request){
Session::flash('flash', 'Пользователь успешно добавлен');
$user=new User();
$user->name=$request->name;
$user->email=$request->email;
$user->password=bcrypt($request->password);
$user->work_number=$request->work_number;
$user->personal_number=$request->personal_number;
$user->save();
if ($request->hasFile('image_path')) {
if (!is_dir(public_path(). '/storage/users')) {
mkdir(public_path(). '/storage/users', 0777, true);
}
$file = $request->file('image_path');
$destinationPath = public_path(). '/storage/users/'.$user->id;
$filename = str_random(8) . '_' . $file->getClientOriginalName() ;
$file->move($destinationPath, $filename);
//Storage::disk('rackspace')->put($destinationPath,$filename);
}
else{
$filename='default_avatar.jpg';
}
$user->image_path=$filename;
$user->save();
$user1=$this->getAllUserInfo($request->id);
$depuser = new DepartmentUser();
$depuser->insert([
'department_id' => $request->department,
'user_id' => $user->id
]);
$role=Role::find($request->role);
$user->attachRole($role);
return redirect(route('users.data'));
//return (dd(realpath($file)));
}
public function destroy($id){
$user=User::find($id);
try{$user->delete();} catch (\Illuminate\Database\QueryException $e){Session()->flash('flash_message_warning', 'Не вышло');}
return redirect(route('users.data'));
}
}
|
<?php
namespace App\Http\Controllers;
use App\Bank;
use App\Country;
use App\GradeRank;
use App\Major;
use App\Person;
use App\PersonTitles;
use App\SceMembershipType;
use Illuminate\Support\Facades\Auth;
use Illuminate\Http\Request;
use App\Rules\ValidDate;
use App\Rules\ValidHijriDate;
use App\Rules\ValidGregorianDate;
use Illuminate\Support\Facades\Redirect;
class PersonController extends Controller
{
// -----------------------------------------------------------------------------------------------------------------
/**
* Create a new controller instance.
*
* @return void
*/
public function __construct()
{
$this->middleware('auth');
// $this->authorizeResource(Person::class, 'person');
// $this->middleware('signed')->only('verify');
// $this->middleware('throttle:6,1')->only('verify', 'resend');
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function index(Person $person)
{
$this->authorize('viewAny', $person);
$allPersons = Person::all()->reverse();
return view('person.index')->with('persons', $allPersons);
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function create(Request $request, Person $person)
{
$national_id = $request->input('national_id');
$formsData = array_merge($this->formsData(), [
'national_id' => $national_id,
'person' => $person,
]);
// dd($formsData);
return view('person.create')->with($formsData);
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Store a newly created resource in storage.
*
* @param \Illuminate\Http\Request $request
* @return \Illuminate\Http\Response
*/
public function store(Request $request)
{
$validatedData = $this->validatePerson($request);
$nationality = Country::where('code_2chracters', $validatedData['nationality_code'])->first();
if ($nationality) {
$validatedData['nationality_ar'] = $nationality->ar_name;
$validatedData['nationality_en'] = $nationality->en_name;
}
$validatedData['created_by_id'] = auth()->user()->id;
$validatedData['created_by_name'] = auth()->user()->user_name;
if ($request->form_action == 'create_new_custorm') {
$validatedData['is_customer'] = true;
}
$found_person = Person::where('national_id', $validatedData['national_id'])->first();
if ($found_person) {
if ($request->coming_from == 'create_new_project') {
return $found_person;
}
return redirect()->route('person.show', $found_person);
}
$person = Person::create($validatedData);
$person->save();
// -----------------------------------------------------------------
// add record to db_log
$db_record_data = [
'table' => 'people',
'model' => 'Person',
'model_id' => $person->id,
'action' => 'create',
'description' => 'new person as customer created national_id =>' . $person->national_id,
];
DbLogController::add_record($db_record_data);
// -----------------------------------------------------------------
if ($request->coming_from == 'create_new_project') {
return $person;
}
return redirect()->action('PersonController@index');
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Display the specified resource.
*
* @param \App\Person $person
* @return \Illuminate\Http\Response
*/
public function show(Request $request, Person $person)
{
// if person not found laravel (route model binding) will send us 404 page
$this->authorize('viewAny', $person);
return view('person.show')->with('person', $person);
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Show the form for editing the specified resource.
*
* @param \App\Person $person
* @return \Illuminate\Http\Response
*/
public function edit(Person $person)
{
$formsData = array_merge($this->formsData(), [
'person' => $person,
]);
return view('person.edit')->with($formsData);
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Update the specified resource in storage.
*
* @param \Illuminate\Http\Request $request
* @param \App\Person $person
* @return \Illuminate\Http\Response
*/
public function update(Request $request, Person $person)
{
$validatedData = collect($this->validatePerson($request));
$nationality = Country::where('code_2chracters', $validatedData['nationality_code'])->first();
if ($nationality) {
$validatedData->put('nationality_ar', $nationality->ar_name);
$validatedData->put('nationality_en', $nationality->en_name);
}
// -------------------
$last_edit_by_id = auth()->user()->id;
$last_edit_by_name = auth()->user()->user_name;
if (!$last_edit_by_id and !$last_edit_by_name) {
return abort(403);
}
$validatedData->put('last_edit_by_id', $last_edit_by_id);
$validatedData->put('last_edit_by_name', $last_edit_by_name);
// -------------------
$person->update($validatedData->all());
$person->save();
return redirect()->action('PersonController@show', $person->id);
}
// -----------------------------------------------------------------------------------------------------------------
/**
* Remove the specified resource from storage.
*
* @param \App\Person $person
* @return \Illuminate\Http\Response
*/
public function destroy(Person $person)
{
$person->delete();
return redirect()->action('PersonController@index');
}
// -----------------------------------------------------------------------------------------------------------------
public function check(Request $request, Person $person)
{
if ($request->method() === "GET") {
return view('person.check');
}
$validatedData = $request->validate([
'national_id' => 'required|numeric|starts_with:1,2|digits:10',
// 'body' => 'required',
]);
// return $request->all();
$found_person = $person->where('national_id', $request->national_id)->first();
// return $found_person;
if ($found_person) {
return redirect()->action('PersonController@show', $found_person->id);
// return redirect()->action('PersonController@show', ['id' => $found_person->id]);
} else {
return redirect()->action('PersonController@create', $request);
}
}
// -----------------------------------------------------------------------------------------------------------------
public function formsData()
{
$countries = Country::all();
$majors = Major::all();
$gread_ranks = GradeRank::all();
$SCE_membership_types = SceMembershipType::all();
$person_titles = PersonTitles::all();
$banks = Bank::all();
return [
'countries' => $countries,
'majors' => $majors,
'gread_ranks' => $gread_ranks,
'gread_ranks' => $gread_ranks,
'SCE_membership_types' => $SCE_membership_types,
'person_titles' => $person_titles,
'banks' => $banks,
];
}
// -----------------------------------------------------------------------------------------------------------------
public static function validatePerson($request)
{
return $request->validate([
'national_id' => 'required|numeric|starts_with:1,2|digits:10',
'is_employee' => 'boolean|nullable',
'is_customer' => 'boolean|nullable',
// ----------------------------------------------------
'ar_name1' => 'required|string|min:2',
'ar_name2' => 'string|nullable',
'ar_name3' => 'string|nullable',
'ar_name4' => 'string|nullable',
'ar_name5' => "required|string|min:2",
'en_name1' => 'string|nullable|regex:/[A-Za-z]/',
'en_name2' => 'string|nullable|regex:/[A-Za-z]/',
'en_name3' => 'string|nullable|regex:/[A-Za-z]/',
'en_name4' => 'string|nullable|regex:/[A-Za-z]/',
'en_name5' => 'string|nullable|regex:/[A-Za-z]/',
// ----------------------------------------------------
'gender' => 'string|nullable',
'relational_status' => 'string|nullable',
'religion' => 'string|nullable',
'prefer_language' => 'string|nullable',
// ----------------------------------------------------
'nationality_code' => "required",
'nationality_ar' => "nullable",
'nationality_en' => "nullable",
// ----------------------------------------------------
'hafizah_no' => 'numeric|nullable',
'national_id_issue_date' => ['nullable', 'string', new ValidHijriDate],
'national_id_expire_date' => ['nullable', 'string', new ValidHijriDate],
'national_id_issue_place' => 'string|nullable',
// ----------------------------------------------------
'pasport_no' => 'nullable',
'pasport_issue_date' => ['nullable', 'string', new ValidGregorianDate],
'pasport_expire_date' => ['nullable', 'string', new ValidGregorianDate],
'pasport_issue_place' => 'nullable',
// ----------------------------------------------------
'ah_birth_date' => ['nullable', 'string', new ValidHijriDate],
'ad_birth_date' => ['nullable', 'string', new ValidGregorianDate],
'birth_place' => 'string|nullable',
'birth_city' => 'string|nullable',
// ----------------------------------------------------
'ah_hiring_date' => ['nullable', 'string', new ValidHijriDate],
'ad_hiring_date' => ['nullable', 'string', new ValidGregorianDate],
'hiring_day' => 'string|nullable',
// ----------------------------------------------------
'employment_no' => 'numeric|nullable',
'fingerprint_no' => 'numeric|nullable',
// ----------------------------------------------------
'degree' => 'string|nullable',
'major_id' => 'numeric|nullable',
'graduated_from' => 'string|nullable',
'college_name' => 'string|nullable',
'graduation_year' => 'numeric|nullable',
'graduation_points' => 'numeric|nullable',
'graduation_points_of' => 'numeric|nullable',
'graduation_grade_rank_id' => 'numeric|nullable',
// ----------------------------------------------------
'id_job_title' => 'string|nullable',
'job_title' => 'string|nullable',
'job_division' => 'string|nullable',
'job_position' => 'string|nullable',
'current_project' => 'string|nullable',
// ----------------------------------------------------
'SCE_membership_no' => 'numeric|nullable',
'SCE_membership_type_id' => 'numeric|nullable',
'SCE_membership_expire_date' => ['nullable', 'string', new ValidGregorianDate],
'SCE_classification_expire_date' => ['nullable', 'string', new ValidGregorianDate],
// ----------------------------------------------------
'mobile' => 'required|numeric|starts_with:0,9|digits:10,12,14',
'phone' => 'nullable',
'phone_extension' => 'nullable',
'email' => 'nullable|email',
'personal_email' => 'email|nullable',
'mobile2' => 'string|nullable',
'mobile3' => 'string|nullable',
// ----------------------------------------------------
'foreign_phone1' => 'string|nullable',
'foreign_phone2' => 'string|nullable',
'foreign_address1' => 'string|nullable',
'foreign_address2' => 'string|nullable',
// ----------------------------------------------------
'SNA_application_no' => 'numeric|nullable',
'SNA_service_no' => 'numeric|nullable',
'SNA_account_no' => 'numeric|nullable',
'SNA_building_no' => 'numeric|nullable',
'SNA_street_name' => 'string|nullable',
'SNA_district_name' => 'string|nullable',
'SNA_city_name' => 'string|nullable',
'SNA_zip_code' => 'numeric|nullable',
'SNA_additional_no' => 'numeric|nullable',
'SNA_unit_no' => 'numeric|nullable',
'SNA_residence_type' => 'string|nullable',
'SNA_residence_ownership' => 'string|nullable',
// ----------------------------------------------------
'bank_id' => 'numeric|nullable',
'bank_account_no' => 'numeric|nullable',
'bank_IBAN_no' => 'numeric|nullable',
// ----------------------------------------------------
'emergency_contact_name1' => 'string|nullable',
'emergency_contact_mobile1' => 'string|nullable',
'emergency_contact_relationship1' => 'string|nullable',
'emergency_contact_name2' => 'string|nullable',
'emergency_contact_mobile2' => 'string|nullable',
'emergency_contact_relationship2' => 'string|nullable',
// ----------------------------------------------------
'notes' => 'string|nullable',
'private_notes' => 'string|nullable',
]);
}
// -----------------------------------------------------------------------------------------------------------------
}
|
<?php
namespace FirePHP\Exception;
/**
* UploadFileNotFoundException est l'exception à l'upload lors que le fichier n'est pas trouvé.
* @author Yoann Chaumin <yoann.chaumin@gmail.com>
*/
class UploadFileNotFoundException extends Exception
{
}
?> |
<?php
namespace DevGroup\Users\actions;
use DevGroup\Users\models\User;
use DevGroup\Users\models\UserService;
use yii\base\Action;
use Yii;
use yii\web\NotFoundHttpException;
use yii\web\ServerErrorHttpException;
/**
* Class DeleteSocial
*
* @package DevGroup\Users\actions
*/
class DeleteSocial extends Action
{
/**
* @param $service_id
* @return \yii\web\Response
* @throws NotFoundHttpException
* @throws ServerErrorHttpException
*/
public function run($service_id)
{
/** @var User $user */
$user = Yii::$app->user->identity;
if ($user === null) {
throw new NotFoundHttpException(Yii::t('users', 'No user identity found'));
}
$userService = UserService::findOne(['social_service_id' => $service_id, 'user_id' => $user->id]);
if ($userService === null) {
throw new NotFoundHttpException(Yii::t(
'users',
'Service with id \'{serviceId}\' not found!',
['serviceId' => $service_id]
));
}
if ($userService->delete()) {
Yii::$app->session->addFlash('success', Yii::t('users', 'Service has been deleted'));
} else {
Yii::$app->session->addFlash('error', Yii::t('users', 'Service has not been deleted'));
}
return $this->controller->redirect(['@manage-social']);
}
}
|
<?php
namespace app\wxpay\controller;
use think\Loader;
use think\Controller;
class Index extends Controller
{
public function index()
{
return $this->fetch();
}
public function native()
{
Loader::import('wxpay.WxPayNativePay', EXTEND_PATH);
//Loader::import('wxpay.lib.WxPayApi', EXTEND_PATH);
Loader::import('wxpay.log', EXTEND_PATH);
//require_once "../lib/WxPay.Api.php";
//require_once "WxPay.NativePay.php";
//require_once 'log.php';
//模式一
/**
* 流程:
* 1、组装包含支付信息的url,生成二维码
* 2、用户扫描二维码,进行支付
* 3、确定支付之后,微信服务器会回调预先配置的回调地址,在【微信开放平台-微信支付-支付配置】中进行配置
* 4、在接到回调通知之后,用户进行统一下单支付,并返回支付信息以完成支付(见:native_notify.php)
* 5、支付完成之后,微信服务器会通知支付成功
* 6、在支付成功通知中需要查单确认是否真正支付成功(见:notify.php)
*/
$notify = new \NativePay();
$url1 = $notify->GetPrePayUrl("123456789");
//模式二
/**
* 流程:
* 1、调用统一下单,取得code_url,生成二维码
* 2、用户扫描二维码,进行支付
* 3、支付完成之后,微信服务器会通知支付成功
* 4、在支付成功通知中需要查单确认是否真正支付成功(见:notify.php)
*/
$wxPayConfig = new \WxPayConfig();
$out_trade_no = $wxPayConfig::MCHID.date("YmdHis");
$input = new \WxPayUnifiedOrder();
$input->SetBody("公房管理系统");
$input->SetAttach("two");
$input->SetOut_trade_no($out_trade_no);
$input->SetTotal_fee("1"); //以1分钱为单位
$input->SetTime_start(date("YmdHis"));
$input->SetTime_expire(date("YmdHis", time() + 600)); //设置二维码过期时间10分钟
$input->SetGoods_tag("goods_tag"); //设置商品标识
$input->SetNotify_url("https://ph.ctnmit.com/wxpay/Notify/orderQuery"); //设置回调地址
$input->SetTrade_type("NATIVE");
$input->SetProduct_id("123456789");
$result = $notify->GetPayUrl($input);
//halt($result);
$url2 = $result["code_url"];
$this->assign([
'out_trade_no'=> $out_trade_no,
'url1' => $url1,
'url2' => $url2,
]);
return $this->fetch();
}
public function nativeapi()
{
Loader::import('wxpay.WxPayNativePay', EXTEND_PATH);
//Loader::import('wxpay.lib.WxPayApi', EXTEND_PATH);
Loader::import('wxpay.log', EXTEND_PATH);
//require_once "../lib/WxPay.Api.php";
//require_once "WxPay.NativePay.php";
//require_once 'log.php';
//模式一
/**
* 流程:
* 1、组装包含支付信息的url,生成二维码
* 2、用户扫描二维码,进行支付
* 3、确定支付之后,微信服务器会回调预先配置的回调地址,在【微信开放平台-微信支付-支付配置】中进行配置
* 4、在接到回调通知之后,用户进行统一下单支付,并返回支付信息以完成支付(见:native_notify.php)
* 5、支付完成之后,微信服务器会通知支付成功
* 6、在支付成功通知中需要查单确认是否真正支付成功(见:notify.php)
*/
$notify = new \NativePay();
$url1 = $notify->GetPrePayUrl("123456789");
//模式二
/**
* 流程:
* 1、调用统一下单,取得code_url,生成二维码
* 2、用户扫描二维码,进行支付
* 3、支付完成之后,微信服务器会通知支付成功
* 4、在支付成功通知中需要查单确认是否真正支付成功(见:notify.php)
*/
$wxPayConfig = new \WxPayConfig();
$out_trade_no = $wxPayConfig::MCHID.date("YmdHis");
$input = new \WxPayUnifiedOrder();
$input->SetBody("公房管理系统");
$input->SetAttach("two");
$input->SetOut_trade_no($out_trade_no);
$input->SetTotal_fee("1"); //以1分钱为单位
$input->SetTime_start(date("YmdHis"));
$input->SetTime_expire(date("YmdHis", time() + 600)); //设置二维码过期时间10分钟
$input->SetGoods_tag("goods_tag"); //设置商品标识
$input->SetNotify_url("https://ph.ctnmit.com/wxpay/Notify/orderQuery"); //设置回调地址
$input->SetTrade_type("NATIVE");
$input->SetProduct_id("123456789");
$result = $notify->GetPayUrl($input);
if (isset($result["code_url"])) {
jsons('2000','获取成功',['url'=>$result["code_url"],'out_trade_no'=>$out_trade_no]);
}else{
jsons('4000','获取失败');
}
}
public function notify()
{
Loader::import('wxpay.notify', EXTEND_PATH);
$wxPayConfig = new \PayNotifyCallBack();
}
public function qrcode()
{
error_reporting(E_ERROR);
Loader::import('wxpay.phpqrcode', EXTEND_PATH);
//require_once 'phpqrcode/phpqrcode.php';
$url = urldecode($_GET["data"]);
$QRcode = new \QRcode();
$QRcode::png($url);
}
} |
Laravel provides an expressive, minimal API arround the Guzzle HTTP client, allowing you to quickly make outgoing HTTP requests to communicate with other web apps.
Laravel's wrapper around Guzzle is focused on its most common use cases and a wonderful dev experience.
Before getting started, insure you have the Guzzle package installed as a dependency of your app. Laravel automatically includes it, but if you need to install it:
<? composer require guzzlehttp/guzzle ?>
Making requests
================
To make requests, use the <? get, post, put, patch, delete ?> methods provided by the Http facade.
<?
use Illuminate\Support\Facades\Http;
// basic get request
$response = Http::get('http://example.com');
?>
The get method returns an instance of Illuminate\Http\Client\Response, which provides a variety of methods that can be used to inspect the response:
<?
$response->body() : string;
$response->json() : array|mixed;
$response->status() : int;
$response->ok() : bool;
$response->successful() : bool;
$response->failed() : bool;
$response->serverError() : bool;
$response->clientError() : bool;
$response->header($header) : string;
$response->headers() : array;
?>
The Illuminate\Http\Client\Response object also implements the PHP ArrayAccess interface, allowing you access to JSON response data directly on the response:
<?
return Http::get('http://example.com/users/1')['name'];
?>
Request Data
===============
Post, put, and patch requests requires additional data with your request so those methods accept an array of data as their 2nd argument.
By default, this data will be sent using to application/json content type.
<?
$response = Http::post('http://example.com/users', [
'name' => 'Steve',
'role' => 'Network Administrator',
]);
?>
Get requests also have this option:
<?
$response = Http::get('http://example.com/users', [
'name' => 'Taylor',
'page' => 1,
]);
?>
To send form URL encoded requests, call the asForm method to utilize the application/x-www-form-urlencoded content type.
<?
$response = Http::asForm()->post('http://example.com/users', [
'name' => 'Sara',
'role' => 'Privacy Consultant',
]);
?>
Use the withBody method to provide a raw request body when making a request. The content type can be provided via the method's 2nd argument:
<?
$response = Http::withBody(
base64_encode($photo), 'image/jpeg'
)->post('http://example.com/photo');
?>
If you need to send files a multi-part requests, call the attach method before making your request. This method accepts the name of the file and its contents. If needed, provide a 3rd argument which will be considered the file's filename:
<?
$response = Http::attach(
'attachment', file_get_contents('photo.jpg'), 'photo.jpg'
)->post('http://example.com/attachments');
?>
Headers
=============
Headers can be added to requests using the withHeaders method. This method accepts an array of key/value pairs:
<?
$response = Http::withHeaders([
'X-First' => 'foo',
'X-Second' => 'bar'
])->post('http://example.com/users', [
'name' => 'Taylor',
]);
?>
Authentication
================
You can specify basic and digest authentication credentials using the withBasicAuth or withDigestAuth methods:
<?
// Basic authentication...
$response = Http::withBasicAuth('taylor@laravel.com', 'secret')->post(...);
// Digest authentication...
$response = Http::withDigestAuth('taylor@laravel.com', 'secret')->post(...);
// To quickly add bearer token to request's Authorization header...
$response = Http::withToken('token')->post(...);
?>
Timeout
===========
The timeout method can be used to specify the max number of seconds to wait for a response:
<?
// If given timeout exceeded, instance of Illuminate\Http\Client\ConnectionException thrown
$response = Http::timeout(3)->get(...);
?>
Retries
===========
If you need the HTTP client to automatically retry the request if a client or server error occurs, you can use the retry method.
This method accept the max number of attempts as the 1st argument and the number of milliseconds to wait between attempts as the 2nd argument:
<?
// If given timeout exceeded, instance of Illuminate\Http\Client\ConnectionException thrown
$response = Http::retry(3, 100)->post(...);
?>
Error Handling
===============
Unlike Guzzle's default behavior, Laravel's HTTP client wrapper doesn't throw exceptions on client or server errors (400 & 500 level responses).
You can determine if one of these errors was returned using the successful, clientError, or serverError methods:
<?
// Determine if the status code is >= 200 and < 300...
$response->successful();
// Determine if the status code is >= 400...
$response->failed();
// Determine if the response has a 400 level status code...
$response->clientError();
// Determine if the response has a 500 level status code...
$response->serverError();
?>
If you have a response instance and want to throw an error instance of Illuminate\Http\Client\RequestException indicates a client or server error, use the throw method:
<?
$response = Http::post(...);
// Throw an exception if a client or server error occurred...
$response->throw();
return $response['user']['id'];
?>
The Illuminate\Http\Client\RequestException instance has a public $response property that will allow you to inspect the returned response:
The throw method returns the response instance if no error occurred, allowing you to chain other operations onto the throw method.
<? return Http::post(...)->throw()->json(); ?>
If you need to perform additional logic before the exception is thrown, pass a closure to the throw mehod.
The exception will be thrown automatically after the closure is invoked so you don't need to re-throw the exception from within the closure:
<?
return Http::post(...)->throw(function ($response, $e) {
//
})->json();
?>
Guzzle Options
================
You can specify additional Guzzle request options using the withOptions method. It accepts an array of key/value pairs:
<?
$response = Http::withOptions([
'debug' => true,
])->get('http://example.com/users');
?>
|
<?php
/*
Helper File for Plugin: Filedownload
Plugin URI: http://www.worldweb-innovation.de/
Description: Database functions
Author: Peter Gross
Author URI: http://www.worldweb-innovation.de/
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* Tabellen erstellen wenn nicht vorhanden
*/
function filedownload_CreateTables() {
require_once(ABSPATH . 'wp-admin/includes/upgrade.php');
global $wpdb;
// Counter-Tabelle existieren nicht - anlegen
$sql ="CREATE TABLE IF NOT EXISTS ".$wpdb->prefix."filedownload"." (
id INT(10) NOT NULL AUTO_INCREMENT,
filename VARCHAR(512) NOT NULL,
count INT(10) NOT NULL,
PRIMARY KEY (id)
);";
dbDelta($sql);
//echo $sql; exit();
}
function filedownload_Write($filename)
{
global $wpdb;
$query = 'SELECT * FROM '.$wpdb->prefix.'filedownload WHERE filename = \''.$filename.'\'';
//print $query;
$result=$wpdb->get_row($query, ARRAY_A);
//print_r($result);exit();
if (count($result) == 0)
{
$wpdb->insert( $wpdb->prefix.'filedownload', array( 'filename' => $filename, 'count' => 1 ), array( '%s', '%d' ));
}
else // iserip does not yet exist
{
$count = $result['count'] + 1;
$wpdb->update( $wpdb->prefix.'filedownload', array( 'filename' => $filename, 'count' => $count ), array( 'filename' => $filename), array( '%s', '%d' ), array( '%s' ) );
}
}
function filedownload_Reset($filename)
{
global $wpdb;
$query = 'SELECT * FROM '.$wpdb->prefix.'filedownload WHERE filename = \''.$filename.'\'';
//print $query;
$result=$wpdb->get_row($query, ARRAY_A);
//print_r($result);exit();
if (count($result) == 0)
{
$wpdb->insert( $wpdb->prefix.'filedownload', array( 'filename' => $filename, 'count' => 0 ), array( '%s', '%d' ));
}
else // iserip does not yet exist
{
$wpdb->update( $wpdb->prefix.'filedownload', array( 'filename' => $filename, 'count' => 0 ), array( 'filename' => $filename), array( '%s', '%d' ), array( '%s' ) );
}
}
function filedownload_Delete($filename)
{
global $wpdb;
$query = 'DELETE FROM '.$wpdb->prefix.'filedownload WHERE filename = \''.$filename.'\'';
//print $query;
$result = $wpdb->query($query);
}
function filedownload_Read($filename)
{
global $wpdb;
$query = 'SELECT * FROM '.$wpdb->prefix.'filedownload WHERE filename = \''.$filename.'\'';
//print $query;
$result=$wpdb->get_row($query, ARRAY_A);
//print_r($result);
if (count($result) == 0) return "0";
return strval($result[count]);
}
function filedownload_ReadAll()
{
global $wpdb;
$query = 'SELECT * FROM '.$wpdb->prefix.'filedownload';
//print $query;
$result=$wpdb->get_results($query, ARRAY_A);
//print_r($result);exit();
return $result;
}
?>
|
<?php
return [
'test-00036-00405' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; XT890 Build/KIA20.74) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00406' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; TAB744 Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00407' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.9.0.10) Gecko/2009042316 Firefox/3.0.10 ( .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00408' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; A1-840 Build/KTU84P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00409' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; Venue 8 7840 Build/KTU84P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00410' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00411' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; SM-G800F Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Mobile Safari/537.36 [FB_IAB/FB4A;FBAV/32.0.0.23.15;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S5 Mini (Europe)',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-G800F',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00412' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0; SM-G900F Build/LRX21T; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/42.0.2311.137 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Android WebView',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S5 LTE',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-G900F',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00413' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; Nexus 7 Build/KTU84P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Nexus 7',
'Device_Maker' => 'Asus',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Nexus 7',
'Device_Brand_Name' => 'Google',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00414' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.1.2; de-de; LT22i Build/6.2.A.1.100) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30 [FB_IAB/FB4A;FBAV/31.0.0.20.13;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '31.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia P',
'Device_Maker' => 'SonyEricsson',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'LT22i',
'Device_Brand_Name' => 'SonyEricsson',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00415' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; BTRS124342; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; (gmx/1.0.0.8))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00416' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; GT-N8010 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Note 10.1 WiFi',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-N8010',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00417' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; A3-A20FHD Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00418' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; rv:37.0.2) Gecko/20100101 Firefox/37.0.2 anonymized by Abelssoft 385993085',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00419' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.3; C6603 Build/10.4.1.B.0.101) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia Z',
'Device_Maker' => 'Sony',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'C6603',
'Device_Brand_Name' => 'Sony',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00420' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; GTB7.5; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30618; .NET4.0C; AskTbORJ/5.15.15.36191)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00421' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36 PTST/209',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00422' => [
'ua' => 'Mozilla/5.0 (iPhone; CPU iPhone OS 7_1_2 like Mac OS X) AppleWebKit/537.51.2 (KHTML, like Gecko) Mobile/11D257 [FBAN/FBIOS;FBAV/29.0.0.9.13;FBBV/9374459;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/7.1.2;FBSS/2; FBCR/Vodafone.de;FBID/phone;FBLC/de_DE;FBOP/5]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '29.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '7.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPhone',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPhone',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00423' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.2.2; de-de; U30GT 2 Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00424' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2389.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00425' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; SM-N915FY Build/KTU84P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Note Edge 4 LTE (Europe)',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-N915FY',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00426' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; tb-gmx/1.7.2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00427' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; rv:37.0.2) Gecko/20100101 Firefox/37.0.2 anonymized by Abelssoft 1625649229',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00428' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.1.2; HUAWEI G525-U00 Build/HuaweiG525-U00) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Ascend G525',
'Device_Maker' => 'Huawei',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'G525-U00',
'Device_Brand_Name' => 'Huawei',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00429' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.3; Archos 45b Platinum Build/JLS36C) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00430' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; GTB7.5; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30618; .NET4.0C; BRI/2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00431' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; Archos 50b Neon Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00432' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.1; GT-I9505 Build/LRX22C) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/40.0.0.0 Mobile Safari/537.36 [FB_IAB/FB4A;FBAV/31.0.0.20.13;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '31.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S4',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I9505',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00433' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; ro-ro; SAMSUNG GT-I9301I/I9301IXXUANI1 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/1.5 Chrome/28.0.1500.94 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Android WebView',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '1.5',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S3 Neo Plus',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I9301I',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00434' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; rv:37.0.2) Gecko/20100101 Firefox/37.0.2 anonymized by Abelssoft 673210219',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00435' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.2.25) Gecko/20111212 YFF35 Firefox/3.6.25 BLNGBAR',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.6',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00436' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; Archos 101 Neon Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => '101 Neon',
'Device_Maker' => 'Archos',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => '101 Neon',
'Device_Brand_Name' => 'Archos',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00437' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; YOGA Tablet 2-1050L Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Yoga Tablet 2 10.1 LTE',
'Device_Maker' => 'Lenovo',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => '1050L',
'Device_Brand_Name' => 'Lenovo',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00438' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; de; rv:1.9.2.6) Gecko/20100625 Firefox/37.0.1 (x86 de) Anonymisiert durch AlMiSoft Browser-Anonymisierer 77205140',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00439' => [
'ua' => 'Mozilla/5.0 (Windows NT 5.1; WOW64; rv:34.0) Gecko/20100101 Firefox/34.0 DT-Browser/DTB7.34.0.19_06',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '34.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00440' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.2.2; de-de; GT-P5200 Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30 [Pinterest/Android]',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 3 10.1 3G',
'Device_Maker' => 'Samsung',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-P5200',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00441' => [
'ua' => 'yacybot (/global; x86 Windows 7 6.1; java 1.8.0_45; Europe/de) http://yacy.net/bot.html',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00442' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.1; Nexus 5 Build/LMY47I) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2389.0 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.1.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Nexus 5',
'Device_Maker' => 'LG',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Nexus 5',
'Device_Brand_Name' => 'Google',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00443' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.2.2; en-US; A1-810 Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 UCBrowser/10.4.1.565 U3/0.8.0 Mobile Safari/534.30',
'properties' => [
'Browser_Name' => 'UC Browser',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'UC Web',
'Browser_Modus' => 'unknown',
'Browser_Version' => '10.4',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'U3',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'UC Web',
],
],
'test-00036-00444' => [
'ua' => 'Mozilla/4.0 (Windows; U; Windows NT 6.0; en-GB; rv:7.4.3) Gecko/20100824 Firefox/7.1',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.1',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00445' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB7.5; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0E; .NET4.0C; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00446' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; breeze 10.1 quad Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00447' => [
'ua' => 'com.apple.WebKit.WebContent/10600.5.17 CFNetwork/720.4 Darwin/14.4.0 (x86_64)',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 64,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00448' => [
'ua' => 'Mozilla/5.0 ;Windows NT 6.4; rv:35.0; Gecko/20100101 Firefox/35.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.4',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00449' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; SM-A500FU Build/KTU84P) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy A5 (Europe)',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-A500FU',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00450' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; rv:37.0.2) Gecko/20100101 Firefox/37.0.2 anonymized by Abelssoft 689290896',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00451' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.3; de-de; W858 Build/JLS36C) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00452' => [
'ua' => 'Mozilla/5.0 (iPhone; CPU iPhone OS 7_1_2 like Mac OS X) AppleWebKit/537.51.2 (KHTML, like Gecko) Mobile/11D257 [FBAN/FBIOS;FBAV/29.0.0.9.13;FBBV/9374459;FBDV/iPhone3,1;FBMD/iPhone;FBSN/iPhone OS;FBSV/7.1.2;FBSS/2; FBCR/Carrier;FBID/phone;FBLC/de_DE;FBOP/5]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '29.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '7.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPhone',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPhone',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00453' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB7.5; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; BRI/2; .NET4.0C; .NET4.0E; tb-webde/2.6.0; (webde/1.4.0.0))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00454' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; LG-V700 Build/KOT49I.A1403851714) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00455' => [
'ua' => 'Dalvik/2.1.0 (Linux; U; Android 5.1.1; A0001 Build/LMY47V)',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.1.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00456' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; S50 Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.135 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '36.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00457' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.22 anonymized by Abelssoft 179179333',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00458' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; Sky Broadband; SV1; .NET4.0C; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 2.0.40607)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00459' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; Trident/7.0; tb-gmx/2.6.2; (gmx/1.4.0.0); rv:11.0) like Gecko',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00460' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.1; GT-I9506 Build/LRX22C) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S4 LTE+',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I9506',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00461' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0;WUID=CC1F93AB28E6430CA1399B24DA09D35D;WTB=3772) like Gecko',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00462' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.2; XT1068 Build/LXB22.46-28.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Moto G Dual SIM (2nd gen)',
'Device_Maker' => 'Motorola',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'XT1068',
'Device_Brand_Name' => 'Motorola',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00463' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; BTRS101478; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET4.0C; InfoPath.2; .NET4.0E; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET CLR 3.0.30618)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00464' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; LIFETAB_S785X Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Safari/537.36 [FB_IAB/FB4A;FBAV/32.0.0.23.15;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'LifeTab S785X',
'Device_Maker' => 'Lenovo',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'LifeTab S785X',
'Device_Brand_Name' => 'Lenovo',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00465' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; K00Z Build/KVT49L) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00466' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.1; Nexus 6 Build/LMY47D) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.1.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Nexus 6',
'Device_Maker' => 'Motorola',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Nexus 6',
'Device_Brand_Name' => 'Google',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00467' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; MEDION E4502 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Life E4502',
'Device_Maker' => 'Medion',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Life E4502',
'Device_Brand_Name' => 'Medion',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00468' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.0.3; de-ch; GT-P5100 Build/IML74K) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.0.3',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 2 10.1',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-P5100',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00469' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; de) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/41.0.2272.118 Chrome anonymized by Abelssoft 141657755',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00470' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; HIGHWAY SIGNS Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00471' => [
'ua' => 'Opera%20Coast/4.21.91399 CFNetwork/711.3.18 Darwin/14.0.0',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '8.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'general Apple Device',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Mobile Device',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'general Apple Device',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00472' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; WOW64; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 3.0.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00473' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; VT10416-2 Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00474' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062.124 Safari/537.36,gzip(gfe)',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00475' => [
'ua' => 'Mozilla/5.0 (X11; CrOS i686 6812.83.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.134 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'ChromeOS',
'Platform_Marketingname' => 'ChromeOS',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00476' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64; rv:2.0) Gecko/20110321 Firefox/4.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00477' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.552.237 Safari/534.10,gzip(gfe) (via translate.google.com)',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00478' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.1.1) Gecko/20090715 Firefox/3.5.1 (.NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.5',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00479' => [
'ua' => 'Mozilla/5.0 (X11; U; Linux i686; de; rv:1.9.0.1) Gecko/2008070400 Firefox/3.0.1',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00480' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.1.2; GT-P3110 Build/JZO54K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 2 7.0',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-P3110',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00481' => [
'ua' => 'Mozilla/5.0 (iPad; CPU OS 7_1_2 like Mac OS X) AppleWebKit/537.51.2 (KHTML, like Gecko) Mobile/11D257 [FBAN/FBIOS;FBAV/29.0.0.9.13;FBBV/9374459;FBDV/iPad3,6;FBMD/iPad;FBSN/iPhone OS;FBSV/7.1.2;FBSS/2; FBCR/Carrier;FBID/tablet;FBLC/de_DE;FBOP/1]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '29.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '7.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPad',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPad',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00482' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.2.2; de-de; GT-P5200 Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30 [FB_IAB/FB4A;FBAV/31.0.0.20.13;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '31.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 3 10.1 3G',
'Device_Maker' => 'Samsung',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-P5200',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00483' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; InfoPath.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00484' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; InfoPath.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00485' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; GT-I9195 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Mobile Safari/537.36 [FB_IAB/FB4A;FBAV/32.0.0.23.15;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S4 Mini',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I9195',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00486' => [
'ua' => 'yacybot (/global; amd64 Linux 3.2.0-4-amd64; java 1.7.0_79; Europe/en) http://yacy.net/bot.html',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00487' => [
'ua' => 'Opera/9.80 (J2ME/MIDP; Opera Mini/5.351/25.729; U; en) Presto/2.5.25 Version/10.54',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '10.54',
'Platform_Codename' => 'Java',
'Platform_Marketingname' => 'Java',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Oracle',
'Platform_Brand_Name' => 'Oracle',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Presto',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Opera Software ASA',
],
],
'test-00036-00488' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.0; de; rv:1.9.2.3) Gecko/20100401 Firefox/3.6 (de) ( .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.6',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00489' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.10 (KHTML, like Gecko) Chrome/8.0.549.0 Safari/534.10',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00490' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.2 (KHTML, like Gecko) Chrome/15.0.861.0 Safari/535.2',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '15.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00491' => [
'ua' => 'Mozilla/5.0 (X11; U; Linux i686; de; rv:1.9.0.8) Gecko/2009042111 Gentoo Firefox/3.0.8',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.0',
'Platform_Codename' => 'Gentoo Linux',
'Platform_Marketingname' => 'Gentoo Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Gentoo Foundation Inc',
'Platform_Brand_Name' => 'Gentoo',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00492' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.1.16) Gecko/20101130 AlexaToolbar/alxf-2.01 Firefox/3.5.16',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.5',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00493' => [
'ua' => 'Mozilla/5.0 (compatible; Konqueror/3.4; Linux 2.6.14-kanotix-9; X11)',
'properties' => [
'Browser_Name' => 'Konqueror',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.4',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00494' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.4 (KHTML, like Gecko) Chrome/16.0.890.0 Safari/535.4',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '16.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00036-00495' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 5.0; de; rv:1.9.0.7) Gecko/2009021910 Firefox/3.0.7',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.0',
'Platform_Codename' => 'Windows NT 5.0',
'Platform_Marketingname' => 'Windows 2000',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00496' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686; rv:5.0a2) Gecko/20110423 Firefox/5.0a2',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '5.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00036-00497' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; America Online Browser 1.1; rev1.5; Windows NT 5.1; .NET CLR 2.0.50727; ZangoToolbar 4.8.2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00036-00498' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; b1-721 Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00499' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.3; ME302C Build/JSS15Q) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Memo Pad FHD 10',
'Device_Maker' => 'Asus',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'ME302C',
'Device_Brand_Name' => 'Asus',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00500' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; Archos 101 Oxygen Build/KTU84Q) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/33.0.0.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Android WebView',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00501' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; Archos 101 Oxygen Build/KTU84Q) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/33.0.0.0 Safari/537.36 [FB_IAB/FB4A;FBAV/32.0.0.23.15;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00502' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; AOL 9.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; InfoPath.2; .NET CLR 3.5.30729; .NET CLR 3.0.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET4.0E)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00036-00503' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; tolino tab 8.9 Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Tab 8.9',
'Device_Maker' => 'Tolino',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Tab 8.9',
'Device_Brand_Name' => 'Tolino',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00036-00504' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.111 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
];
|
<?php
namespace App\Http\Livewire;
use App\Models\Site;
use App\Valet\Valet;
use Livewire\Component;
use Livewire\WithPagination;
class Sites extends Component
{
use WithPagination;
protected $paginationTheme = 'bootstrap';
public $project_path;
public $project_name;
public $onLatestVerision;
public $logs = [];
public $logFileLines;
private $logFilePath;
public $logPerNum = 5;
public $info = [];
public $valetSites = [];
public function render()
{
return view('livewire.sites', [
'sites' => Site::paginate(10)
]);
}
public function toggleSecure($id)
{
$site = Site::find($id);
if ($site) {
$valet = new Valet();
$site->secured ? $valet->unSecure($site->name) : $valet->secure($site->name);
$site->update(['secured' => !$site->secured]);
}
}
public function unlink($id)
{
$site = Site::find($id);
if ($site) {
$valet = new Valet();
$valet->unlink($site->name);
}
}
public function link()
{
if (empty($this->project_name)) {
$this->project_name = null;
}
(new Valet())->link($this->project_path, $this->project_name)->save();
}
public function checkForUpdate()
{
$this->onLatestVerision = (new Valet())->onLatestVerision();
}
public function sync()
{
Site::refreshAll();
}
public function clear()
{
Site::truncate();
}
public function showLogs()
{
if ($this->logs) {
$this->logs = [];
return;
}
$this->logs = (new Valet())->logs();
}
public function showLog($path, $skip = 0)
{
$this->logFilePath = $path;
$this->logFileLines = (new Valet())->loadLogFile($this->logFilePath, $this->logPerNum, $skip)->toArray();
}
public function run()
{
if ($this->info) {
$this->info = [];
return;
}
$this->info = (new Valet())->run();
}
public function showValetsites()
{
if ($this->valetSites) {
$this->valetSites = [];
return;
}
$this->valetSites = (new Valet())->allSites();
}
}
|
<?php
namespace App\Models;
use Illuminate\Notifications\Notifiable;
use Illuminate\Foundation\Auth\User as Authenticatable;
class Pasien extends Authenticatable
{
use Notifiable;
protected $fillable = [
'nomor','nama','username','password','lp','kota','foto','alamat_pasien','gol_darah','hp_pasien','pekerjaan','agama','nama_wali','hp_wali','alamat_wali'
];
protected $hidden = [
'password', 'remember_token',
];
protected $casts = [
];
public function daftarperiksa()
{
return $this->hasMany(DaftarPeriksa::class, 'pasien_id', 'id');
}
public function riwayatpasien()
{
return $this->hasMany(RiwayatPasien::class, 'pasien_id', 'id');
}
public function alatterpasang()
{
return $this->hasMany(AlatTerpasang::class, 'pasien_id', 'id');
}
public function observasilanjutan()
{
return $this->hasMany(ObservasiLanjutan::class, 'pasien_id', 'id');
}
public function pemberianobat()
{
return $this->hasMany(PemberianObat::class, 'pasien_id', 'id');
}
public function tindakankeperawatan()
{
return $this->hasMany(TindakanKeperawatan::class, 'pasien_id', 'id');
}
}
|
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use Illuminate\Validation\Rule;
use Illuminate\Support\Facades\DB;
use Carbon\Carbon;
use App\Http\Requests;
use App\Http\Controllers\Controller;
use App\weapon;
class WeaponController extends Controller
{
/**
* Display a listing of the resource.
*
* @return \Illuminate\Http\Response
*/
public function __construct()
{
$this->middleware('creator', ['except' => ['index','indexPublic','show','showPublic']]);
$this->middleware('admin', ['except' => ['indexPublic','showPublic']]);
}
public function index()
{
$weapons = DB::table('weapons')->orderBy('created_at', 'desc')->get();
return view('pages.weapons.list')->withList($weapons);
}
public function set_public($id)
{
$weapon = weapon::find($id);
$weapon->public = 1;
$weapon->save();
return redirect()->route('weapons.index');
}
public function set_not_public($id)
{
$weapon = weapon::find($id);
$weapon->public = 0;
$weapon->save();
return redirect()->route('weapons.index');
}
public function indexPublic()
{
$now = Carbon::now();
$weapons = DB::table('weapons')->orderBy('created_at', 'desc')->get();
return view('pages.weapons.listPublic')->withList($weapons)->withNow($now);
}
/**
* Show the form for creating a new resource.
*
* @return \Illuminate\Http\Response
*/
public function create()
{
$types = DB::table('weapon_types')->get();
return view('pages.weapons.create')->with(array('types'=>$types));
}
/**
* Store a newly created resource in storage.
*
* @param \Illuminate\Http\Request $request
* @return \Illuminate\Http\Response
*/
public function store(Request $request)
{
$types = DB::table('weapon_types')->get();
$types_name = [];
foreach ($types as $type) {
array_push($types_name, $type->name);
}
$this->validate($request, array(
'name' => 'required|max:40|min:2',
'type' => ['required',Rule::in($types_name)],
));
$weapon = new weapon;
switch ($request->submitbutton) {
case 'another':
$weapon->name = $request->name;
$weapon->type = $request->type;
$weapon->descriptionInicial = $request->desc_1;
$weapon->save();
return redirect()->route('weapons.create');
break;
case 'list':
$weapon->name = $request->name;
$weapon->type = $request->type;
$weapon->descriptionInicial = $request->desc_1;
$weapon->save();
return redirect()->route('weapons.index');
break;
}
}
/**
* Display the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function show($id)
{
$weapon = weapon::find($id);
return view('pages.weapons.item')->withItem($weapon);
}
public function showPublic($id)
{
$weapon = weapon::find($id);
return view('pages.weapons.itemPublic')->withItem($weapon);
}
/**
* Show the form for editing the specified resource.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function edit($id)
{
$item = weapon::find($id);
$types = DB::table('weapon_types')->get();
return view('pages.weapons.edit')->with(array('types'=>$types, 'item' => $item));
}
/**
* Update the specified resource in storage.
*
* @param \Illuminate\Http\Request $request
* @param int $id
* @return \Illuminate\Http\Response
*/
public function update(Request $request, $id)
{
$types = DB::table('weapon_types')->get();
$types_name = [];
foreach ($types as $type) {
array_push($types_name, $type->name);
}
$this->validate($request, array(
'name' => 'required|max:40|min:2',
'type' => ['required',Rule::in($types_name)],
));
$weapon = weapon::find($id);
$weapon->name = $request->name;
$weapon->type = $request->type;
$weapon->descriptionInicial = $request->desc_1;
$weapon->save();
switch ($request->submitbutton) {
case 'another':
return redirect()->route('weapons.show', $id);
break;
case 'list':
return redirect()->route('weapons.index');
break;
}
}
/**
* Remove the specified resource from storage.
*
* @param int $id
* @return \Illuminate\Http\Response
*/
public function destroy($id)
{
$item = weapon::find($id);
$item->delete();
return redirect()->route('weapons.index');
}
}
|
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
/**
* The "apps" collection of methods.
* Typical usage is:
* <code>
* $appengineService = new Google_Service_Appengine(...);
* $apps = $appengineService->apps;
* </code>
*/
class Google_Service_Appengine_Resource_Apps extends Google_Service_Resource
{
/**
* Creates an App Engine application for a Google Cloud Platform project.
* Required fields: id - The ID of the target Cloud Platform project. location -
* The region (https://cloud.google.com/appengine/docs/locations) where you want
* the App Engine application located.For more information about App Engine
* applications, see Managing Projects, Applications, and Billing
* (https://cloud.google.com/appengine/docs/standard/python/console/).
* (apps.create)
*
* @param Google_Service_Appengine_Application $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Appengine_Operation
*/
public function create(Google_Service_Appengine_Application $postBody, $optParams = array())
{
$params = array('postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('create', array($params), "Google_Service_Appengine_Operation");
}
/**
* Gets information about an application. (apps.get)
*
* @param string $appsId Part of `name`. Name of the Application resource to
* get. Example: apps/myapp.
* @param array $optParams Optional parameters.
* @return Google_Service_Appengine_Application
*/
public function get($appsId, $optParams = array())
{
$params = array('appsId' => $appsId);
$params = array_merge($params, $optParams);
return $this->call('get', array($params), "Google_Service_Appengine_Application");
}
/**
* Updates the specified Application resource. You can update the following
* fields: auth_domain - Google authentication domain for controlling user
* access to the application. default_cookie_expiration - Cookie expiration
* policy for the application. (apps.patch)
*
* @param string $appsId Part of `name`. Name of the Application resource to
* update. Example: apps/myapp.
* @param Google_Service_Appengine_Application $postBody
* @param array $optParams Optional parameters.
*
* @opt_param string updateMask Standard field mask for the set of fields to be
* updated.
* @return Google_Service_Appengine_Operation
*/
public function patch($appsId, Google_Service_Appengine_Application $postBody, $optParams = array())
{
$params = array('appsId' => $appsId, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('patch', array($params), "Google_Service_Appengine_Operation");
}
/**
* Recreates the required App Engine features for the specified App Engine
* application, for example a Cloud Storage bucket or App Engine service
* account. Use this method if you receive an error message about a missing
* feature, for example, Error retrieving the App Engine service account. If you
* have deleted your App Engine service account, this will not be able to
* recreate it. Instead, you should attempt to use the IAM undelete API if
* possible at https://cloud.google.com/iam/reference/rest/v1/projects.serviceAc
* counts/undelete?apix_params=%7B"name"%3A"projects%2F-%2FserviceAccounts%2Funi
* que_id"%2C"resource"%3A%7B%7D%7D . If the deletion was recent, the numeric ID
* can be found in the Cloud Console Activity Log. (apps.repair)
*
* @param string $appsId Part of `name`. Name of the application to repair.
* Example: apps/myapp
* @param Google_Service_Appengine_RepairApplicationRequest $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Appengine_Operation
*/
public function repair($appsId, Google_Service_Appengine_RepairApplicationRequest $postBody, $optParams = array())
{
$params = array('appsId' => $appsId, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('repair', array($params), "Google_Service_Appengine_Operation");
}
}
|
<?php
/**
* This file is part of the ValueObjects package.
*
* (c) Lorenzo Marzullo <marzullo.lorenzo@gmail.com>
*/
namespace ValueObjects\Common;
/**
* Interface QuantityInterface.
* A quantity is class composed by an amount and a unit.
* Eg: moneys , physics measures, ...
* See http://martinfowler.com/eaaDev/quantity.html for an in depth explanation
*
* @package ValueObjects
* @author Lorenzo Marzullo <marzullo.lorenzo@gmail.com>
* @link https://github.com/valueobjects
*/
interface QuantityInterface
{
/**
* amount.
*
* @return AmountInterface
*/
public function amount();
/**
* unit.
*
* @return UnitInterface
*/
public function unit();
} |
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
/**
* The "snapshots" collection of methods.
* Typical usage is:
* <code>
* $pubsubService = new Google_Service_Pubsub(...);
* $snapshots = $pubsubService->snapshots;
* </code>
*/
class Google_Service_Pubsub_Resource_ProjectsSnapshots extends Google_Service_Resource
{
/**
* Creates a snapshot from the requested subscription. Snapshots are used in
* Seek operations, which allow you to manage message acknowledgments in bulk.
* That is, you can set the acknowledgment state of messages in an existing
* subscription to the state captured by a snapshot. If the snapshot already
* exists, returns `ALREADY_EXISTS`. If the requested subscription doesn't
* exist, returns `NOT_FOUND`. If the backlog in the subscription is too old --
* and the resulting snapshot would expire in less than 1 hour -- then
* `FAILED_PRECONDITION` is returned. See also the `Snapshot.expire_time` field.
* If the name is not provided in the request, the server will assign a random
* name for this snapshot on the same project as the subscription, conforming to
* the [resource name
* format](https://cloud.google.com/pubsub/docs/admin#resource_names). The
* generated name is populated in the returned Snapshot object. Note that for
* REST API requests, you must specify a name in the request. (snapshots.create)
*
* @param string $name Optional user-provided name for this snapshot. If the
* name is not provided in the request, the server will assign a random name for
* this snapshot on the same project as the subscription. Note that for REST API
* requests, you must specify a name. See the
*
* resource name rules. Format is `projects/{project}/snapshots/{snap}`.
* @param Google_Service_Pubsub_CreateSnapshotRequest $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_Snapshot
*/
public function create($name, Google_Service_Pubsub_CreateSnapshotRequest $postBody, $optParams = array())
{
$params = array('name' => $name, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('create', array($params), "Google_Service_Pubsub_Snapshot");
}
/**
* Removes an existing snapshot. Snapshots are used in Seek operations, which
* allow you to manage message acknowledgments in bulk. That is, you can set the
* acknowledgment state of messages in an existing subscription to the state
* captured by a snapshot. When the snapshot is deleted, all messages retained
* in the snapshot are immediately dropped. After a snapshot is deleted, a new
* one may be created with the same name, but the new one has no association
* with the old snapshot or its subscription, unless the same subscription is
* specified. (snapshots.delete)
*
* @param string $snapshot The name of the snapshot to delete. Format is
* `projects/{project}/snapshots/{snap}`.
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_PubsubEmpty
*/
public function delete($snapshot, $optParams = array())
{
$params = array('snapshot' => $snapshot);
$params = array_merge($params, $optParams);
return $this->call('delete', array($params), "Google_Service_Pubsub_PubsubEmpty");
}
/**
* Gets the configuration details of a snapshot. Snapshots are used in Seek
* operations, which allow you to manage message acknowledgments in bulk. That
* is, you can set the acknowledgment state of messages in an existing
* subscription to the state captured by a snapshot. (snapshots.get)
*
* @param string $snapshot The name of the snapshot to get. Format is
* `projects/{project}/snapshots/{snap}`.
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_Snapshot
*/
public function get($snapshot, $optParams = array())
{
$params = array('snapshot' => $snapshot);
$params = array_merge($params, $optParams);
return $this->call('get', array($params), "Google_Service_Pubsub_Snapshot");
}
/**
* Gets the access control policy for a resource. Returns an empty policy if the
* resource exists and does not have a policy set. (snapshots.getIamPolicy)
*
* @param string $resource REQUIRED: The resource for which the policy is being
* requested. See the operation documentation for the appropriate value for this
* field.
* @param array $optParams Optional parameters.
*
* @opt_param int options.requestedPolicyVersion Optional. The policy format
* version to be returned.
*
* Valid values are 0, 1, and 3. Requests specifying an invalid value will be
* rejected.
*
* Requests for policies with any conditional bindings must specify version 3.
* Policies without any conditional bindings may specify any valid value or
* leave the field unset.
* @return Google_Service_Pubsub_Policy
*/
public function getIamPolicy($resource, $optParams = array())
{
$params = array('resource' => $resource);
$params = array_merge($params, $optParams);
return $this->call('getIamPolicy', array($params), "Google_Service_Pubsub_Policy");
}
/**
* Lists the existing snapshots. Snapshots are used in Seek operations, which
* allow you to manage message acknowledgments in bulk. That is, you can set the
* acknowledgment state of messages in an existing subscription to the state
* captured by a snapshot. (snapshots.listProjectsSnapshots)
*
* @param string $project The name of the project in which to list snapshots.
* Format is `projects/{project-id}`.
* @param array $optParams Optional parameters.
*
* @opt_param string pageToken The value returned by the last
* `ListSnapshotsResponse`; indicates that this is a continuation of a prior
* `ListSnapshots` call, and that the system should return the next page of
* data.
* @opt_param int pageSize Maximum number of snapshots to return.
* @return Google_Service_Pubsub_ListSnapshotsResponse
*/
public function listProjectsSnapshots($project, $optParams = array())
{
$params = array('project' => $project);
$params = array_merge($params, $optParams);
return $this->call('list', array($params), "Google_Service_Pubsub_ListSnapshotsResponse");
}
/**
* Updates an existing snapshot. Snapshots are used in Seek operations, which
* allow you to manage message acknowledgments in bulk. That is, you can set the
* acknowledgment state of messages in an existing subscription to the state
* captured by a snapshot. (snapshots.patch)
*
* @param string $name The name of the snapshot.
* @param Google_Service_Pubsub_UpdateSnapshotRequest $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_Snapshot
*/
public function patch($name, Google_Service_Pubsub_UpdateSnapshotRequest $postBody, $optParams = array())
{
$params = array('name' => $name, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('patch', array($params), "Google_Service_Pubsub_Snapshot");
}
/**
* Sets the access control policy on the specified resource. Replaces any
* existing policy. (snapshots.setIamPolicy)
*
* @param string $resource REQUIRED: The resource for which the policy is being
* specified. See the operation documentation for the appropriate value for this
* field.
* @param Google_Service_Pubsub_SetIamPolicyRequest $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_Policy
*/
public function setIamPolicy($resource, Google_Service_Pubsub_SetIamPolicyRequest $postBody, $optParams = array())
{
$params = array('resource' => $resource, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('setIamPolicy', array($params), "Google_Service_Pubsub_Policy");
}
/**
* Returns permissions that a caller has on the specified resource. If the
* resource does not exist, this will return an empty set of permissions, not a
* NOT_FOUND error.
*
* Note: This operation is designed to be used for building permission-aware UIs
* and command-line tools, not for authorization checking. This operation may
* "fail open" without warning. (snapshots.testIamPermissions)
*
* @param string $resource REQUIRED: The resource for which the policy detail is
* being requested. See the operation documentation for the appropriate value
* for this field.
* @param Google_Service_Pubsub_TestIamPermissionsRequest $postBody
* @param array $optParams Optional parameters.
* @return Google_Service_Pubsub_TestIamPermissionsResponse
*/
public function testIamPermissions($resource, Google_Service_Pubsub_TestIamPermissionsRequest $postBody, $optParams = array())
{
$params = array('resource' => $resource, 'postBody' => $postBody);
$params = array_merge($params, $optParams);
return $this->call('testIamPermissions', array($params), "Google_Service_Pubsub_TestIamPermissionsResponse");
}
}
|
<?php
/**
* Shipping zone admin
*
* @package WooCommerce/Admin/Shipping
*/
if ( ! defined( 'ABSPATH' ) ) {
exit;
}
?>
<h2>
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wc-settings&tab=easy_shipping' ) ); ?>"><?php esc_html_e( 'Shipping zones', 'woocommerce' ); ?></a> >
<span class="wc-shipping-zone-name"><?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->delivery_area:''; ?></span>
</h2>
<?php do_action( 'woocommerce_shipping_zone_before_methods_table' ); ?>
<table class="form-table wc-shipping-zone-settings">
<tbody>
<?php //if ( 0 !== $zone->get_id() ) : ?>
<tr valign="top" class="">
<th></th>
<td>
<label for="isexpress">
<span><?php esc_html_e( 'Click checkbox from right if allow Express Delivery', 'easy' ); ?></span>
</label>
</td>
</tr>
<tr valign="top" class="">
<th scope="row" class="titledesc">
<label for="zone_name">
<?php esc_html_e( 'Country Name', 'woocommerce' ); ?>
<?php echo wc_help_tip( __( 'This is the name of the country for your reference.', 'woocommerce' ) ); // @codingStandardsIgnoreLine ?>
</label>
</th>
<td class="forminp easyShipping">
<select name="country_name" data-attribute="zone_name" id="zone_name" data-placeholder="<?php esc_html_e( 'Select country within this zone', 'woocommerce' ); ?>" class="wc-shipping-zone-region-select chosen_select">
<?php
foreach($allowed_countries as $k => $sCntry){
$selected = ($_REQUEST['zone_id'] != 'new' && $k == $exstZone->country_name || $k == 'US')?'selected':'';
echo '<option '.$selected.' value="'.$k.'" >'.$sCntry.'</option>';
}
?>
</select>
</td>
</tr>
<tr valign="top" class="">
<th scope="row" class="titledesc">
<label for="zone_locations">
<?php esc_html_e( 'State', 'woocommerce' ); ?>
<?php echo wc_help_tip( __( 'These are regions inside this zone. Customers will be matched against these regions.', 'woocommerce' ) ); // @codingStandardsIgnoreLine ?>
</label>
</th>
<td class="forminp">
<select data-attribute="zone_locations" id="zone_locations" name="zone_locations" data-placeholder="<?php esc_html_e( 'Select regions within this zone', 'woocommerce' ); ?>" class="wc-shipping-zone-region-select chosen_select">
<?php
foreach($states as $k => $sStt){
$stctd = ($_REQUEST['zone_id'] != 'new' && $k == $exstZone->state)?'selected':'';
echo '<option '.$stctd.' value="'.$k.'">'.$sStt.'</option>';
}
?>
</select>
</td>
</tr>
<tr valign="top" class="">
<th scope="row" class="titledesc">
<label for="zone_city">
<?php esc_html_e( 'City', 'woocommerce' ); ?>
<?php echo wc_help_tip( __( 'These are regions inside this zone. Customers will be matched against these regions.', 'woocommerce' ) ); // @codingStandardsIgnoreLine ?>
</label>
</th>
<td class="forminp">
<input type="text" data-attribute="zone_city" id="zone_city" name="city" placeholder="City Name" data-placeholder="<?php esc_html_e( 'Select regions within this zone', 'easy' ); ?>" value="<?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->city:''; ?>" class="wc-shipping-zone-region-select" />
</td>
</tr>
<!-- Delivery Area -->
<tr valign="top" class="">
<th scope="row" class="titledesc">
<label for="delivery_area">
<?php esc_html_e( 'Delivery Area', 'easy' ); ?>
<?php echo wc_help_tip( __( 'Use (,) comma for seperate each zipcode.', 'easy' ) ); // @codingStandardsIgnoreLine ?>
</label>
</th>
<td class="forminp">
<div class="singleDeliverArea">
<input type="text" data-attribute="delivery_area" id="delivery_area" name="delivery_area" placeholder="Neighborhood..." value="<?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->delivery_area:''; ?>" class="wc-shipping-zone-region-select" />
<input type="text" data-attribute="delivery_zipcode" id="delivery_zipcode" name="zipcode" placeholder="000000, 000000" value="<?php echo ($_REQUEST['zone_id'] != 'new')?implode(', ', $zipcodes):''; ?>" class="wc-shipping-zone-region-select" />
<input type="number" data-attribute="min_amount" step="0.01" id="min_amount" name="min_amount" placeholder="Min Amount " value="<?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->min_amount:''; ?>" class="wc-shipping-zone-region-select" />
<input type="number" data-attribute="max_amount" step="0.01" id="max_amount" name="max_amount" placeholder="Max Amount " value="<?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->max_amount:''; ?>" class="wc-shipping-zone-region-select" />
<input type="number" data-attribute="delivery_charge" id="delivery_charge" step="0.01" name="delivery_charge" placeholder="Delivery Charge" value="<?php echo ($_REQUEST['zone_id'] != 'new')?$exstZone->charge:''; ?>" class="wc-shipping-zone-region-select" />
<input type="checkbox" name="isexpress" id="isexpress" class="checkbox">
</div>
<div class="addbuttons mt-1">
<?php if($_REQUEST['zone_id']): ?>
<button type="button" class="button button-primary addmorearea"><?php _e('Add Delivery Area', 'easy'); ?></button>
<?php endif; ?>
</div>
</td>
</tr>
<?php if(isset($_REQUEST['zone_id']) && $_REQUEST['zone_id'] != 'new'): ?>
<tr>
<th>
<?php echo _e('Permalink', 'easy'); ?>
</th>
<td class="forminp">
<?php echo get_home_url() . '/?cid=' . $exstZone->id; ?>
</td>
</tr>
<?php endif; ?>
</tbody>
</table>
<?php do_action( 'woocommerce_shipping_zone_after_methods_table' ); ?>
<p class="submit">
<button type="submit" name="submit" id="<?php echo ($_REQUEST['zone_id'] == 'new')?'easy_submit':'easy_update'; ?>" class="button button-primary button-large wc-shipping-zone-method-save" value="<?php esc_attr_e( 'Save changes', 'woocommerce' ); ?>" <?php echo ($_REQUEST['zone_id'] == 'new')?'disabled':'data-upid="'.$exstZone->id.'"'; ?>><?php ($_REQUEST['zone_id'] == 'new')?esc_html_e( 'Save changes', 'woocommerce' ):esc_html_e( 'Update changes', 'woocommerce' ); ?></button>
</p>
|
<?php
namespace Kirby\Http;
/**
* A set of methods that make it more convenient to get variables
* from the global server array
*
* @package Kirby Http
* @author Bastian Allgeier <bastian@getkirby.com>
* @link https://getkirby.com
* @copyright Bastian Allgeier GmbH
* @license https://opensource.org/licenses/MIT
*/
class Server
{
/**
* Cache for the cli status
*
* @var bool|null
*/
public static $cli;
/**
* Returns the server's IP address
*
* @return string
*/
public static function address(): string
{
return static::get('SERVER_ADDR');
}
/**
* Checks if the request is being served by the CLI
*
* @return bool
*/
public static function cli(): bool
{
if (static::$cli !== null) {
return static::$cli;
}
if (defined('STDIN') === true) {
return static::$cli = true;
}
$term = getenv('TERM');
if (substr(PHP_SAPI, 0, 3) === 'cgi' && $term && $term !== 'unknown') {
return static::$cli = true;
}
return static::$cli = false;
}
/**
* Gets a value from the _SERVER array
*
* <code>
* Server::get('document_root');
* // sample output: /var/www/kirby
*
* Server::get();
* // returns the whole server array
* </code>
*
* @param mixed $key The key to look for. Pass false or null to
* return the entire server array.
* @param mixed $default Optional default value, which should be
* returned if no element has been found
* @return mixed
*/
public static function get($key = null, $default = null)
{
if ($key === null) {
return $_SERVER;
}
$key = strtoupper($key);
$value = $_SERVER[$key] ?? $default;
return static::sanitize($key, $value);
}
/**
* Help to sanitize some _SERVER keys
*
* @param string $key
* @param mixed $value
* @return mixed
*/
public static function sanitize(string $key, $value)
{
switch ($key) {
case 'SERVER_ADDR':
case 'SERVER_NAME':
case 'HTTP_HOST':
case 'HTTP_X_FORWARDED_HOST':
$value = strip_tags($value);
$value = preg_replace('![^\w.:-]+!iu', '', $value);
$value = trim($value, '-');
$value = htmlspecialchars($value);
break;
case 'SERVER_PORT':
case 'HTTP_X_FORWARDED_PORT':
$value = (int)(preg_replace('![^0-9]+!', '', $value));
break;
}
return $value;
}
/**
* Returns the correct port number
*
* @param bool $forwarded
* @return int
*/
public static function port(bool $forwarded = false): int
{
$port = $forwarded === true ? static::get('HTTP_X_FORWARDED_PORT') : null;
if (empty($port) === true) {
$port = static::get('SERVER_PORT');
}
return $port;
}
/**
* Checks for a https request
*
* @return bool
*/
public static function https(): bool
{
if (isset($_SERVER['HTTPS']) && !empty($_SERVER['HTTPS']) && strtolower($_SERVER['HTTPS']) !== 'off') {
return true;
} elseif (static::port() === 443) {
return true;
} elseif (in_array(static::get('HTTP_X_FORWARDED_PROTO'), ['https', 'https, http'])) {
return true;
} else {
return false;
}
}
/**
* Returns the correct host
*
* @param bool $forwarded
* @return string
*/
public static function host(bool $forwarded = false): string
{
$host = $forwarded === true ? static::get('HTTP_X_FORWARDED_HOST') : null;
if (empty($host) === true) {
$host = static::get('SERVER_NAME');
}
if (empty($host) === true) {
$host = static::get('SERVER_ADDR');
}
return explode(':', $host)[0];
}
}
|
<?php
namespace Gomee\Repositories;
trait CacheAction
{
/**
* các phương thúc lấy dữ liệu
*
* @var array
*/
protected $getDataMethods = [];
/**
* đẩy repository vào một cache task
*
* @param string $key
* @param integer $time
* @param array $params
* @return CacheTask
*/
public function cache($key = null, $time = 0, $params = [])
{
if($time <= 0) $time = 0;
if($time <= 0) return $this; // nếu timw truyền vào nhỏ hơn hoặc = 0 thì ko cần làm gì cả
$repository = clone $this;
$this->resetActionParams();
return (new CacheTask($repository, $key, $time, $params));
}
/**
* dăng ký các phương thức lấy dữ liệu sau khi gôi phương thức cache
*
* @param string[] ...$methods
* @return void
*/
public function registerCacheMethods(...$methods)
{
if(count($methods)){
foreach ($methods as $method) {
$this->registerCacheMethod($method);
}
}
}
/**
* thêm phương thức cache
*
* @param string|array $methods
* @return void
*/
public function registerCacheMethod($methods)
{
if(!is_array($methods)){
$this->getDataMethods[] = $methods;
}else{
foreach ($methods as $alias => $method) {
if(is_numeric($alias)){
$this->getDataMethods[] = $method;
}else{
$this->getDataMethods[strtolower($alias)] = $method;
}
}
}
}
/**
* lấy danh sách các phương thức lấy dữ liệu đã khai báo
*
* @return array
*/
public function getCacheMethods()
{
return $this->getDataMethods;
}
}
|
<?php
/**
* Fired when the plugin is uninstalled. Deletes options and slider posts.
*
* @package Lucid\Slider
*/
// Exit if the uninstall is not called from WordPress
if ( ! defined( 'WP_UNINSTALL_PLUGIN' ) )
die();
require 'inc/core.php';
/**
* Delete all slider posts.
*/
function lucid_slider_delete_all_posts() {
$posts = get_posts( array(
'numberposts' => -1,
'post_type' => Lucid_Slider_Core::get_post_type_name(),
'post_status' => 'any'
) );
if ( is_array( $posts ) ) :
foreach ( $posts as $post )
wp_delete_post( $post->ID, true );
endif;
}
// Delete options
delete_option( 'lsjl_general_settings' );
delete_option( 'lsjl_slider_settings' );
// Delete slider posts
lucid_slider_delete_all_posts(); |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/**
*
*
* 基于Codeigniter的
*
* @package ZhenGoo
* @author Ghostdom.wj <ghostdom.wj@gmail.com>
* @copyright Copyright (c) 20011 - 2012, pintutu.com.
* @link http://www.pintutu.com
* @version 0.1.0
*/
// --------------------------------------------------------------------
/**
* Zhengoo Pin Model
*
* Zhengoo pin图(app相关图片) 模型
*
* @package ZhenGoo
* @subpackage Model
* @category Model
* @author Ghostdom.wj <ghostdom.wj@gmail.com>
* @link http://www.pintutu.com
*/
define('PIN_STATUS_AUDITED', 0); //已审核
define('PIN_STATUS_UNAUDITED', 1); //未审核
define('PIN_STATUS_AUDIT', 2); //审核中
define('PIN_STATUS_ILLEGAL', 3); //不合法
define('PIN_TYPE_MAST', 0); //截屏类型: 普通
define('PIN_TYPE_UI', 1); //截屏类型: 界面
define('PIN_TYPE_SHOW_OFF', 2); //截屏类型: 炫耀
define('PIN_SOURCE_OFFICIAL', 0); //截图来源: 官方
class Pin_Model extends ZG_Model {
} |
<?php
namespace Core\AttributeBundle\Entity;
use Doctrine\ORM\EntityRepository;
class AttributeValueRepository extends EntityRepository
{
public function getValuesByNameQueryBuilder($name = null, $all = false, $value = null)
{
$queryBuilder = $this->getEntityManager()->createQueryBuilder()
->select("av, an")
->from("CoreAttributeBundle:AttributeValue", "av")
->leftJoin("av.name", "an");
;
if ($name != null) {
$queryBuilder->andWhere("av.name = :name")
->setParameter("name", $name);
}
if (!$all) {
$queryBuilder->andWhere("av.serialized = :serialized")
->setParameter("serialized", false);
}
if ($value !== null) {
$queryBuilder->andWhere("av.value = :value")
->setParameter("value", $value);
}
$queryBuilder
->addOrderBy("an.name");
return $queryBuilder;
}
public function getValuesByNameQuery($name = null, $all = false, $value = null)
{
$query = $this->getValuesByNameQueryBuilder($name, $all, $value)->getQuery();
$query = $query->setHint(\Doctrine\ORM\Query::HINT_CUSTOM_OUTPUT_WALKER, 'Gedmo\\Translatable\\Query\\TreeWalker\\TranslationWalker');
return $query;
}
public function getValuesByName($name = null, $all = false, $value = null)
{
return $this->getValuesByNameQuery($name, $all, $value)->getResult();
}
public function createAttributeValue(AttributeName $name, $value)
{
$attributeValue = ($name->getId()) ? $this->getValuesByNameQuery($name->getId(), true, $value)->getOneOrNullResult() : null;
if (!$attributeValue) {
$attributeValue = new AttributeValue();
$attributeValue->setName($name);
$attributeValue->setValue($value);
}
return $attributeValue;
}
}
|
<?php
spl_autoload_register(function($class) use ($basedir) {
$parts = explode('\\', $class);
$path = __DIR__ . '/lib/' . implode('/', $parts) . '.php';
if (!file_exists($path))
return false;
require $path;
}); |
#if !defined(UM_JULES)
! *****************************COPYRIGHT**************************************
! (C) Crown copyright Met Office. All rights reserved.
! For further details please refer to the file COPYRIGHT.txt
! which you should have received as part of this distribution.
! *****************************COPYRIGHT**************************************
!!****************************************************************************
!! Version control information:
!!
!! $HeadURL: svn://fcm2/JULES_svn/JULES/trunk/src/io/file_handling/core/drivers/ascii/file_ascii_fill_buffer.inc $
!! $Author: hadmq $
!!
!! $LastChangedDate: 2012-08-10 12:50:04 +0100 (Fri, 10 Aug 2012) $
!! $LastChangedRevision: 486 $
!!
!!****************************************************************************
SUBROUTINE file_ascii_fill_buffer(file)
USE io_constants, ONLY : MODE_READ
USE string_utils_mod, ONLY : str_starts_with
IMPLICIT NONE
!-----------------------------------------------------------------------------
! Description:
! INTERNAL PROCEDURE - reads the next data from file, skipping any comment
! lines, and fills the buffer with it
!
! Current Code Owner: Matt Pryor
!
! Code Description:
! Language: Fortran 90.
! This code is written to JULES coding standards v1.
!-----------------------------------------------------------------------------
! Argument types
TYPE(file_ascii), INTENT(INOUT) :: file
! Work variables
CHARACTER(len=file%record_len) :: line
LOGICAL :: is_comment ! Indicates if the current line is a comment line
INTEGER :: i ! Loop counter
INTEGER :: error ! Error indicator
!-----------------------------------------------------------------------------
! We can't fill the buffer until enddef has been called
IF ( file%define_mode ) &
CALL log_fatal("file_ascii_fill_buffer", &
"Cannot fill buffer - file is still in define mode")
IF ( file%mode /= MODE_READ ) &
CALL log_fatal("file_ascii_fill_buffer", &
"Cannot read from file - file is not in read mode")
! Read lines from the file until we get a non-comment line
DO
READ(file%unit, "(A)", IOSTAT=error) line
IF ( error /= 0 ) &
CALL log_fatal("file_ascii_fill_buffer", &
"Error reading from file " // &
"(IOSTAT=" // TRIM(to_string(error)) // ")")
! Remove any leading spaces
line = ADJUSTL(line)
! We skip over empty lines
IF ( LEN_TRIM(line) == 0 ) CYCLE
! If the line does not start with a comment char, we have found a line of data
! and can exit the loop
is_comment = .FALSE.
DO i = 1,SIZE(COMMENT_CHARS)
IF ( str_starts_with(line, COMMENT_CHARS(i)) ) THEN
is_comment = .TRUE.
EXIT
END IF
END DO
IF ( .NOT. is_comment ) EXIT
END DO
! Fill the buffer from the line of data
READ(line, *) file%buffer(:)
RETURN
END SUBROUTINE file_ascii_fill_buffer
#endif
|
<?php
namespace Site\ShopBundle\Form;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
use Doctrine\ORM\EntityRepository;
/**
* Description of CartPaymentShippingType
*
* @author Birko
*/
class CartPaymentShippingType extends AbstractType
{
public function __construct()
{
}
public function buildForm(FormBuilderInterface $builder, array $options)
{
$state = $options['paymentState'];
if ($options['payment']) {
$builder->add("payment", 'entity', array(
'class' => 'CoreShopBundle:Payment',
'expanded' => true,
'multiple' => false,
'query_builder' => function (EntityRepository $er) use ($state) {
$qb = $er->getPaymentQueryBuilder(true);
return $qb;
},
));
}
$state = $options['shippingState'];
if ($options['shipping']) {
$builder->add("shipping", 'entity', array(
'class' => 'CoreShopBundle:Shipping',
'expanded' => true,
'multiple' => false,
'query_builder' => function (EntityRepository $er) use ($state) {
$qb = $er->getShippingQueryBuilder($state, true);
return $qb;
},
));
}
}
public function getName()
{
return "nws_shop_paymentshipping";
}
public function setDefaultOptions(OptionsResolverInterface $resolver)
{
$resolver->setDefaults(array(
'data_class' => 'Site\ShopBundle\Entity\Cart',
'payment' => true,
'shipping' => true,
'paymentState' => null,
'shippingState' => null
));
}
}
|
<?php
/**
* Content Areas Plugin, Furasta.Org
*
* @author Conor Mac Aoidh <conormacaoidh@gmail.com>
* @licence http://furasta.org/licence.txt The BSD Licence
* @version 1
*/
if( $widget_id == 0 ){ // add new widget to database and return id
$defaults = json_encode( array(
) );
query( 'insert into ' . DB_PREFIX . 'widgets values( "", "textarea", "' . $area_name . '", "", "' . $defaults . '" )' );
echo mysql_insert_id( );
exit;
}
/**
* information is being posted
*/
if( is_array( $postdata ) ){
$content = addslashes( $postdata[ 'widget_textarea_content' ] );
query( 'update ' . DB_PREFIX . 'widgets set content="' . $content . '" where id=' . $widget_id );
exit;
}
require HOME . '_inc/function/admin.php';
$Template = Template::getInstance( );
$widget = row( 'select * from ' . DB_PREFIX . 'widgets where id=' . $widget_id );
$content = '<h2>Textarea</h2>';
$content .= tinymce( 'widget_textarea_content', @$widget[ 'content' ], 'Normal' );
$Template->add( 'content', $content );
?>
|
<?php
class NegociacaoParcelaModel {
private $id;
private $negociacao;
private $cobranca;
function getId() {
return $this->id;
}
function getNegociacao() {
return $this->negociacao;
}
function getCobranca() {
return $this->cobranca;
}
function setId($id) {
$this->id = $id;
}
function setNegociacao(NegociacaoModel $negociacao) {
$this->negociacao = $negociacao;
}
function setCobranca(CobrancaModel $cobranca) {
$this->cobranca = $cobranca;
}
} |
<?php
/*
* This file is part of the Stinger Media Parser package.
*
* (c) Oliver Kotte <oliver.kotte@stinger-soft.net>
* (c) Florian Meyer <florian.meyer@stinger-soft.net>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace StingerSoft\MediaParsingBundle\Parser\Information;
use StingerSoft\MediaParsingBundle\Parser\MediaInformationInterface;
abstract class AbstractMediaInformation implements MediaInformationInterface {
protected $title;
protected $mimeType;
protected $filePath;
protected $fileSize;
protected $lastModified;
public function getTitle(){
return $this->title;
}
public function setTitle($title){
$this->title = $title;
return $this;
}
public function getMimeType(){
return $this->mimeType;
}
public function setMimeType($mimeType){
$this->mimeType = $mimeType;
return $this;
}
public function getFilePath(){
return $this->filePath;
}
public function setFilePath($filePath){
$this->filePath = $filePath;
return $this;
}
public function getFileSize(){
return $this->fileSize;
}
public function setFileSize($fileSize){
$this->fileSize = $fileSize;
return $this;
}
public function getLastModified(){
return $this->lastModified;
}
public function setLastModified(\DateTime $lastModified){
$this->lastModified = $lastModified;
return $this;
}
}
|
<?php
namespace Philcross\GetAddress\Tests\Responses;
use PHPUnit\Framework\TestCase;
use Philcross\GetAddress\Responses\Ip;
use Philcross\GetAddress\Responses\Domain;
use Philcross\GetAddress\Responses\AbstractWhitelist;
class WhitelistTest extends TestCase
{
public function test_i_can_use_the_getters_to_retrieve_domain_info()
{
$domain = new Domain('abc', 'phil-cross.co.uk');
$this->assertEquals('abc', $domain->getObjectId());
$this->assertEquals('phil-cross.co.uk', $domain->getDomain());
}
public function test_i_can_use_the_getters_to_retrieve_the_ip_info()
{
$ip = new Ip('abc', '127.0.0.1');
$this->assertEquals('abc', $ip->getObjectId());
$this->assertEquals('127.0.0.1', $ip->getIp());
}
}
|
<?php
return [
'test-00061-02510' => [
'ua' => 'Firefox/35.0.1 (x86 de); anonymized by Abelssoft 147017980',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows',
'Platform_Marketingname' => 'Windows',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02511' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.91 Safari/537.36 OPR/27.0.1689.54 (Edition Yx 01)',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '27.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02512' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.0.4; ru-ru; 10BPE0 Build/MystiQ970-20121121) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.0.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02513' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; A3-A11 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.89 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Iconia Tab A3',
'Device_Maker' => 'Acer',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'A3-A11',
'Device_Brand_Name' => 'Acer',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02514' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; L200G Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Android WebView',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02515' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; SaveWealth; .NET CLR 2.0.50727; .NET4.0C)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02516' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; Nexus 10 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/30.0.1599.105 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '30.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Nexus 10',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'Nexus 10',
'Device_Brand_Name' => 'Google',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02517' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; lt; rv:1.9.2.27) Gecko/20120216 Firefox/3.6.27',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.6',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02518' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.3; ru-ru; ME302C Build/JSS15Q) AppleWebKit/537.16 (KHTML, like Gecko) Version/4.0 Safari/537.16',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Memo Pad FHD 10',
'Device_Maker' => 'Asus',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'ME302C',
'Device_Brand_Name' => 'Asus',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02519' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.0; Trident/5.0; msn OptimizedIE8;PTPT)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02520' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; WOW64; SLCC1; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30618; .NET4.0C)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02521' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; de; rv:1.9.2.8) Gecko/20100722 AskTbORJ/3.15.25.36191 Firefox/3.6.8',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.6',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02522' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.3; AT10LE-A Build/JSS15Q) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.109 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.3.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02523' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; SM-T530 Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.89 Safari/537.36 OPR/27.0.1698.88647',
'properties' => [
'Browser_Name' => 'Opera Mobile',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '27.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 4 10.1 WiFi',
'Device_Maker' => 'Samsung',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-T530',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02524' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; Trident/7.0; MAMD; EIE10;NLNLMSN; rv:11.0) like Gecko',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '11.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02525' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Trident/5.0; BOIE9;RURU)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02526' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; BTRS99921; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02527' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; Trident/7.0; rv:11.0; MSIE; Maxthon/4.2.1.1000)',
'properties' => [
'Browser_Name' => 'Maxthon',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02528' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; Mozilla/4.0 (compatible; MSIE 7.0; Win32; 1&1); Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1) ; TuneUp HTML Client Embedded Web Browser from: http://bsalsa.com/; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; (1und1/1.4.0.0))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02529' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; eSobiSubscriber 2.0.4.16; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; tb-gmx/2.6.0)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02530' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; rv:35.0; WUID=4c89796bbb8e09faafb466a00d32f8cd; WTB=3869; WUID=fb121903f27fbf85747e54176d1bd1da; WTB=4028) Gecko/20100101 Firefox/35.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02531' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.2; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.2',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02532' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/40.0.2214.111 Safari/537.22 anonymized by Abelssoft 578624977',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02533' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; BRI/1; MASM; InfoPath.2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02534' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; Win64; x64; Trident/6.0; tb-webde/2.6.0; MASEJS)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '10.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02535' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; .NET4.0C; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; Tablet PC 2.0; .NET4.0E; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02536' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.94 Safari/537.36 OPR/27.0.1689.66 (Edition Campaign 16)',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '27.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02537' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; anonymized by Abelssoft 680301149; anonymized by Abelssoft 680301149)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02538' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; MAAU; (gmx/1.4.0.0); rv:11.0) like Gecko',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '11.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02539' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; D5103 Build/18.1.A.1.23) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/30.0.0.0 Mobile Safari/537.36 [FB_IAB/FB4A;FBAV/26.0.0.22.16;]',
'properties' => [
'Browser_Name' => 'Facebook App',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Facebook',
'Browser_Modus' => 'unknown',
'Browser_Version' => '26.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia Style T3',
'Device_Maker' => 'Sony',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'D5103',
'Device_Brand_Name' => 'Sony',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02540' => [
'ua' => 'Mozilla/5.0 (iPad; CPU OS 8_0_2 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) CriOS/30.0.1599.16 Mobile/12A405 Safari/8536.25',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '30.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '8.0.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPad',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPad',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02541' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; rv:35.0) Gecko/20100101 Firefox/35.0 anonymized by Abelssoft 1120897893',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02542' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.4; C6902 Build/14.4.A.0.157) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.109 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.4',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia Z1',
'Device_Maker' => 'Sony',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'C6902',
'Device_Brand_Name' => 'Sony',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02543' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.0; rv:35.0) Gecko/20100101 Firefox/35.0 anonymized by Abelssoft 764165940',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02544' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; CMDTDFJS; F9J; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02545' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; GTB7.5; .NET CLR 1.1.4322; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 2.0.50727)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02546' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.0; WOW64; Trident/5.0; tb-webde/2.3.0)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02547' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E; BRI/2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02548' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; GTB7.5; SLCC1; .NET CLR 2.0.50727; .NET CLR 1.1.4322; .NET CLR 3.0.30618; .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02549' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0E; .NET4.0C; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02550' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64; rv:27.0; WUID=411ca8981ee2635e3e2fab54824dccc6; WTB=8086) Gecko/20100101 Firefox/27.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '27.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02551' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; Mozilla/4.0 (compatible; MSIE 7.0; Win32; 1&1); BTRS100278; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET4.0C; .NET4.0E; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02552' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; AskTbAVR-4/5.15.31.57710; .NET4.0E; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02553' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.1.2; ro-ro; POV_TAB-P629(v1.0) Build/JZO54K) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02554' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.1.2; GT-I9100 Build/JZO54K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.109 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy S II',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I9100',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02555' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; WOW64; Trident/5.0; NP06; tb-gmx/2.6.0)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02556' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2272.43 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02557' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.0; rv:35.0.1) Gecko/20100101 Firefox/35.0.1 anonymized by Abelssoft 334289647',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02558' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; FBUnified; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; .NET4.0C; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02559' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.2; LG-D855 Build/LRX22G) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/37.0.0.0 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Android WebView',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'G2',
'Device_Maker' => 'LG',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'D855',
'Device_Brand_Name' => 'LG',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02560' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; LIFETAB_E10316 Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.109 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'LifeTab E10316',
'Device_Maker' => 'Medion',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'LifeTab E10316',
'Device_Brand_Name' => 'Medion',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02561' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.4.2; fi-fi; GT-P5200 Build/KOT49H) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Tab 3 10.1 3G',
'Device_Maker' => 'Samsung',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-P5200',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02562' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.0; Trident/5.0; BOIE9;DECH)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '9.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02563' => [
'ua' => 'Mozilla/5.0 (X11; U; Linux i686; de; rv:1.9.0.10) Gecko/2009042523 Ubuntu/9.04 (jaunty) Firefox/3.0.10',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '3.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '9.04.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02564' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30729; .NET4.0C; AlexaToolbar/amzni-3.0; .NET4.0E; AskTbALSV5/5.15.25.44892; (webde/1.0.0.8); Avant Browser)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02565' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; WOW64; Trident/4.0; chromeframe/32.0.1700.107; EasyBits GO v1.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; .NET4.0C; BRI/2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02566' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; rv:35.0.1) Gecko/20100101 Firefox/35.0.1 anonymized by Abelssoft 949706902',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02567' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; GTB7.5; .NET CLR 1.1.4322; AskTbAVR-4/5.15.20.37949; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02568' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.0; rv:35.0) Gecko/20100101 Firefox/35.0 anonymized by Abelssoft 1097726286',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02569' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; .NET4.0C; .NET4.0E; Tablet PC 2.0; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02570' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET4.0E)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02571' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; InfoPath.2; OfficeLiveConnector.1.4; OfficeLivePatch.1.3; .NET CLR 2.0.50727; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E; Zune 4.7; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02572' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; IE of ITRM)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02573' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB7.5; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; CMDTDF; AskTbORJ/5.15.15.36191)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02574' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; WOW64; Trident/7.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729; McAfee; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; MAARJS; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02575' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.3; WOW64; Trident/7.0; .NET4.0E; .NET4.0C; Tablet PC 2.0; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; tb-gmx/2.6.0; (gmx/1.4.0.0))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02576' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; WOW64; rv:29.0; WUID=fb5abd63cafe6fd08db87dd56fa3029c; WTB=23890) Gecko/20100101 Firefox/29.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '29.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02577' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686; rv:29.0) Gecko/20100101 Firefox/29.0 SeaMonkey/2.26.1',
'properties' => [
'Browser_Name' => 'SeaMonkey',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '2.26',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02578' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0E; tb-gmx/2.5.1)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02579' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; bmw-gcframe/15.0.874.120; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 1.1.4322; .NET4.0C; .NET4.0E; InfoPath.2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02580' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; Media Center PC 6.0; .NET4.0C; InfoPath.3; .NET CLR 1.1.4322; .NET CLR 3.5.30729; .NET CLR 3.0.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02581' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; Win64; x64; Trident/7.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729; InfoPath.3; MASEJS; Microsoft Outlook 15.0.4667; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02582' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 1.1.4322; .NET4.0C; .NET4.0E; Microsoft Outlook 14.0.7113; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02583' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Win64; x64; Trident/6.0; .NET CLR 2.0.50727; SLCC2; .NET4.0C; .NET4.0E; .NET CLR 3.5.30729; .NET CLR 3.0.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02584' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; AskTbFXTV5/5.15.1.22229)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02585' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; TOB 6.13; Windows NT 6.0; Trident/4.0; GTB7.5; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.0.30729; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02586' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.2; SV1; .NET CLR 1.1.4322; (webde/1.0.0.8))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '6.0',
'Platform_Codename' => 'Windows NT 5.2',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02587' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; rv:35.0) Gecko/20100101 Firefox/35.0 anonymized by Abelssoft 935356930',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02588' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.0.3705; .NET CLR 1.1.4322; Media Center PC 4.0; Media Center PC 3.0; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02589' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; WOW64; Trident/6.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729; Tablet PC 2.0; tb-webde/2.6.0; ASU2JS)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02590' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; BTRS99216; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET CLR 1.1.4322; InfoPath.1)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02591' => [
'ua' => 'Mozilla/5.0 (Windows; U; Windows NT 6.1; de; rv:1.9.2.6) Gecko/20100625 Firefox/12.0 (de) Anonymisiert durch AlMiSoft Browser-Anonymisierer 58170019',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '12.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02592' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; AlexaToolbar/amzni-3.0; GTB7.5; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET CLR 2.0.50727; AlexaToolbar/amzni-3.0; BRI/2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02593' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; rv:35.0) Gecko/20100101 Firefox/35.0 anonymized by Abelssoft 1584666243',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00061-02594' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1) ; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02595' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.3; InfoPath.2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02596' => [
'ua' => 'Mozilla/5.0 (compatible; MSIE 10.0; TOB 6.11; Windows NT 6.1; WOW64; Trident/6.0; tb-webde/2.6.0)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '10.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02597' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.0.04506; InfoPath.1; .NET4.0C)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00061-02598' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; GTB7.5; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; .NET CLR 3.0.30618; InfoPath.2; .NET4.0C)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02599' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET4.0C; .NET4.0E; tb-webde/2.1.0)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02600' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; eSobiSubscriber 2.0.4.16; InfoPath.2; .NET4.0C; .NET4.0E; AskTbMGX/5.14.1.20007; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02601' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.1.2; el-gr; GT-I8260 Build/JZO54K) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.1.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Core',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'GT-I8260',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02602' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; SM-G310HN Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.109 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Core Plus',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-G310HN',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00061-02603' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET CLR 3.0.30729; .NET4.0C; AskTbORJ/5.15.23.36191; .NET4.0E; BRI/2; MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02604' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; BTRS99483; GTB7.5; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; AskTbORJ/5.15.23.36191)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02605' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; BTRS100200; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; .NET4.0C; .NET4.0E)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02606' => [
'ua' => 'Outlook-Express/7.0 (MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; MAMD; Media Center PC 5.0; SLCC1; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET4.0E; TmstmpExt)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02607' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; InfoPath.2; .NET CLR 3.5.30729; .NET CLR 3.0.30729; .NET4.0C; .NET4.0E)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00061-02608' => [
'ua' => 'Mozilla/5.0 (Linux; U; Android 4.2.2; de-de; MT-703G Build/JDQ39) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30',
'properties' => [
'Browser_Name' => 'Android',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '4.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00061-02609' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; GTB7.5; .NET CLR 2.0.50727; .NET4.0C; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; InfoPath.1; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; tb-webde/2.6.0; (webde/1.4.0.0))',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
];
|
<?php
@require_once '../github_secret.php';
if (!defined('GITHUB_SECRET')) {
http_response_code(500);
die();
}
$post_data = file_get_contents('php://input');
$signature = hash_hmac('sha1', $post_data, GITHUB_SECRET);
header("Content-Type: text/plain");
if ($_SERVER['REQUEST_METHOD'] != 'POST'
|| !isset($_SERVER['HTTP_X_GITHUB_EVENT'])
|| !fnmatch('GitHub-Hookshot/*', $_SERVER['HTTP_USER_AGENT'])
|| $_SERVER['HTTP_X_HUB_SIGNATURE'] != "sha1=$signature"
) {
http_response_code(403);
die("Forbidden\n");
}
$data = json_decode($post_data, true);
require_once 'github/hook_executor.php';
execute_hook($data, $_SERVER['HTTP_X_GITHUB_EVENT']);
|
<?php
namespace BromineMai\CorYar;
use BromineMai\CorYar\Packager\Json;
use BromineMai\CorYar\Packager\Msgpack;
use BromineMai\CorYar\Packager\Packager;
use BromineMai\CorYar\Exception\ExceptionHelper;
use BromineMai\CorYar\Packager\Php;
/**
* Class Yar
* @package BromineMai\CorYar
*/
class Yar{
private static $supportCor;
/**
* 获取传输器
* @param string $name
* @return Packager
* @throws \Yar_Client_Packager_Exception
* @author Jiankang maijiankang@foxmail.com
*/
public static function getPackager($name='default'){
if('default'==$name){
return new Php();
}
if(0===strpos($name,Msgpack::PACKAGER_NAME)){
return new Msgpack();
}
if(0===strpos($name,Php::PACKAGER_NAME)){
return new Php();
}
if(0===strpos($name,Json::PACKAGER_NAME)){
return new Json();
}
ExceptionHelper::throwYarException(ExceptionHelper::YAR_ERR_PACKAGER,'UNKONW PACKAGER'.$name);
}
/**
* 判断是否是swoole协程中
* @return bool
* @author Jiankang maijiankang@foxmail.com
*/
public static function isCoroutine(){
return self::getCid()>0;
}
/**
* 获取协程编号
* @return bool|int -1主协程 false不支持协程 其他为进程内唯一的协程编号
* @author Jiankang maijiankang@foxmail.com
*/
public static function getCid(){
if(!isset(self::$supportCor)){
self::$supportCor=extension_loaded('swoole');
}
if(!self::$supportCor){
return false;
}
return \Swoole\Coroutine::getCid();
}
} |
<?php
/**
* Template for the Admin header/footer picker settings screen.
*
* @package EightshiftBoilerplate
*/
use EightshiftBoilerplate\AdminMenus\ReusableBlocksHeaderFooter;
use EightshiftBoilerplateVendor\EightshiftLibs\Helpers\Components;
$globalManifest = Components::getManifest(dirname(__DIR__, 2));
$manifest = Components::getManifest(__DIR__);
?>
<div class="wrap">
<?php
// Show admin messages.
if (isset($_GET['settings-updated'])) { // phpcs:ignore
add_settings_error(ReusableBlocksHeaderFooter::ADMIN_MESSAGE_SLUG, 'save_success', __('Settings saved', 'eightshift-frontend-libs'), 'updated');
}
// Render update messages.
settings_errors(ReusableBlocksHeaderFooter::ADMIN_MESSAGE_SLUG);
?>
<div class="wrap">
<h1><?php echo esc_html(get_admin_page_title()); ?></h1>
<form action="options.php" method="post">
<?php
// Output settings fields.
settings_fields(ReusableBlocksHeaderFooter::ADMIN_MENU_SLUG);
// Output settings sections.
do_settings_sections(ReusableBlocksHeaderFooter::ADMIN_MENU_SLUG);
// Render save button.
submit_button(__('Save', 'eightshift-frontend-libs'));
?>
</form>
</div>
</div>
|
<?php
/**
* Created by solly [06.04.17 3:23]
*/
namespace insolita\opcache\contracts;
use yii\data\ArrayDataProvider;
/**
* Class IOpcachePresenter
*
* @package backend\modules\opcache\services
*/
interface IOpcachePresenter
{
/**
* @return mixed
*/
public function setUpFormat();
/**
* @param array $directives
*
* @return mixed
*/
public function configDirectivesProvider(array &$directives);
/**
* @param array $files
*
* @return \insolita\opcache\contracts\IFileFilterModel|\yii\base\Model
*/
public function createFileFilterModel(array &$files);
/**
* @param $value
* @param $key
*
* @return string
*/
public function formatStatistic($value, $key);
/**
* @param $value
* @param $key
*
* @return string
*/
public function formatMemory($value, $key);
/**
* @param $value
*
* @return string
*/
public function formatBool($value);
} |
<?php defined('BASEPATH') OR exit('No direct script access allowed');
/**
* CodeIgniter MathCaptcha
*
* @category Libraries
* @license MIT License (http://opensource.org/licenses/MIT)
* @author steven kamanu
* @version 1.0
*/
class Mathcaptcha
{
private $addNum1;
private $addNum2;
public function __construct($captchaID = 0 ) {
$this->ci =& get_instance();
$this->ci->load->config('auth', TRUE);
$this->ci->load->helper(['url','date','language']);
$this->ci->load->library(['session','form_validation']);
$this->ci->lang->load('auth');
$this->image_garbage_collector();
}
/** generate recapta image
*
* @access public
* @return image png or jpg format
*/
public function create_captcha()
{
$this->addNum1 = rand(0, 10) * rand(1, 3);
$this->addNum2 = rand(0, 10) * rand(1, 3);
// Set the captcha result for current captcha and set it to the session for later check
// $_SESSION[$this->captchaID] = $this->answer = $this->addNum1 + $this->addNum2;
$this->ci->session->set_flashdata([
'captcha_word' => ($this->addNum1 + $this->addNum2),
'captcha_time' => now()
]);
$word = $this->addNum1 . ' + ' . $this->addNum2 . ' = ';
$img_width = $this->ci->config->item('captcha_width', 'auth');
$img_height = $this->ci->config->item('captcha_height', 'auth');
$cap = $this->create_image($word ,$img_width,$img_height);
return $cap['img'];
}
/** create image with captcha info
*
* @access public
* @param string $word
* @param int $width
* @param int $height
* @return image
*/
public function create_image($word,$width=null,$height=null)
{
$fontsize = $this->ci->config->item('captcha_font_size', 'auth');
$width = is_null($width) ? 150 : $width;
$height = is_null($height) ? 30 : $height ;
$img = imagecreatetruecolor($width, $height);
$now = microtime(TRUE);
$black = imagecolorallocate($img ,0,0,0);
$white = imagecolorallocate($img ,255,255,255);
$red = imagecolorallocate($img ,255,0,0);
imagefilledrectangle($img, 0, 0, $width, $height, $white);
imagestring($img,$fontsize,2,2,$word,$red);
imagepng($img, "assets/captcha/".$now.".png");
imagedestroy($img);
$img_url = base_url("assets/captcha/".$now.".png");
$img = '<img src="'.$img_url.'" style="width: '.$width.'; height: '.$height .'; border: 0;" alt=" " />';
return [ "img" => $img ];
}
/** check capta exist on session
*
* @access public
* @return bool
*/
public function _check_captcha($code)
{
$time = $this->ci->session->flashdata('captcha_time');
$word = $this->ci->session->flashdata('captcha_word');
list($usec, $sec) = explode(" ", microtime());
$now = ((float)$usec + (float)$sec);
if ($now - $time > $this->ci->config->item('captcha_expire', 'auth')) {
$this->ci->form_validation->set_message('_check_captcha', $this->ci->lang->line('auth_captcha_expired'));
return FALSE;
} elseif (($this->ci->config->item('captcha_case_sensitive', 'auth') AND
$code != $word) OR
strtolower($code) != strtolower($word)) {
$this->ci->form_validation->set_message('_check_captcha', $this->ci->lang->line('auth_incorrect_captcha'));
return FALSE;
}
return TRUE;
}
public function image_garbage_collector()
{
$now = microtime(TRUE);
$img_path = 'assets/captcha/';
$current_dir = @opendir($img_path);
while ($filename = @readdir($current_dir))
{
if (in_array(substr($filename, -4), array('.jpg', '.png'))
&& (str_replace(array('.jpg', '.png'), '', $filename) + 7200) < $now)
{
@unlink($img_path.$filename);
}
}
}
}
|
<?php
namespace AbstractFactory\Service;
use AbstractFactory\Contract\DBFactoryInterface;
use AbstractFactory\Contract\RepositoryFactoryInterface;
use AbstractFactory\Entity\DBQueryBuilder;
use AbstractFactory\Entity\DBRecord;
use AbstractFactory\Entity\RecordDb;
use AbstractFactory\Repository\MySqlBuilder;
class Service
{
private $record;
private $queryBuilderRepository;
public function __construct(RepositoryFactoryInterface $DBFactory)
{
$this->record = $DBFactory->createRecord();
$this->queryBuilderRepository = $DBFactory->createQuery();
}
public function addRecord(): void
{
$record = new RecordDb();
$this->record->add($record);
}
public function addQueryBuilder(): void
{
$queryBuilderRepository = new DBQueryBuilder();
$this->queryBuilderRepository->insert($queryBuilderRepository);
}
} |
<?php
namespace App\Helper;
use Illuminate\Support\Facades\Auth;
class AuthHelper
{
public static function showUsername()
{
$user = Auth::user();
$name = "";
if (!empty($user->first_name)) {
$name .= $user->first_name . " ";
}
if (!empty($user->last_name)) {
$name .= $user->last_name;
}
return $name;
}
}
|
<?php
// command line php xx.php
/*
* quickselect leetcode https://leetcode.com/problemset/all/?page=1&topicSlugs=quickselect
*/
$arr = array( 6,1,3,7,5,2,3,4,45,5,4,75,8,6,78,7980890,2,4,2,432,5,34,5634,34,5);
echo "\n input array: ".implode(',',$arr)."\n";
echo "\n == testing sort algo == \n";
$solution = new Solution();
$result1 = $solution->findKthLargest($arr, 5); //use pointer, which will change the origional array
echo "sort result:".$result1."\n";
$arr2= [1,0];
echo "\n input array: ".implode(',',$arr2)."\n";
$result2 = $solution->findKthLargest($arr2, 5);
echo "sort color result:".$result2."\n";
/*
* https://leetcode.com/problems/kth-largest-element-in-an-array/
* 215. Kth Largest Element in an Array
* CN (having solution): https://leetcode.cn/problems/kth-largest-element-in-an-array/
*/
class Solution {
/**
* @param Integer[] $nums
* @return NULL
*/
function findKthLargest($nums, $k) {
/*
* do a quick sort/selection, check pivot index, process left or right
*/
return $this->quickSelection($nums, $k-1, 0, count($nums)-1); //kth largest, index is k-1
}
function quickSelection (&$nums, $kIndex, $startIndex, $endIndex) {
if ($startIndex > $endIndex) {
return -1;
}
else if ($startIndex == $endIndex) {
return $startIndex == $kIndex ? $nums[$kIndex] : -1;
}
/*
* taking first item as pivot, from big to small, left side all values bigger
* swap value
*/
$leftWallIndex = $startIndex;
$pivotValue = $nums[$startIndex];
for ($i=$leftWallIndex+1; $i<=$endIndex; $i++) {
if ($nums[$i] >= $pivotValue) { //1st part is biggest number (from big to small)
//swap $i to leftwallIndex
$leftWallIndex ++;
$temp = $nums[$leftWallIndex];
$nums[$leftWallIndex] = $nums[$i];
$nums[$i] = $temp;
}
}
//at last do a swap with $startIndex and $leftWallIndex
$nums[$startIndex] = $nums[$leftWallIndex];
$nums[$leftWallIndex] = $pivotValue;
if ($leftWallIndex == $kIndex) {
return $nums[$leftWallIndex];
}
else if ($leftWallIndex > $kIndex) {
//process left side
return $this->quickSelection ($nums, $kIndex, $startIndex, $leftWallIndex-1);
}
else {
//process right side
return $this->quickSelection ($nums, $kIndex, $leftWallIndex+1, $endIndex);
}
}
} |
<?php
namespace SafeBox\Infrastructure\Repository\SafeBox;
use SafeBox\Application\Service\SafeBox\CommonPasswordRepositoryInterface;
class FileCommonPasswordRepository implements CommonPasswordRepositoryInterface
{
function all(): array
{
return [
'123456',
'123456789',
'111111',
'password',
'qwerty',
'abc123',
'12345678',
'password1',
'1234567',
'123123',
'1234567890',
'000000',
'12345',
'iloveyou',
'1q2w3e4r5t',
'1234',
'123456a',
'qwertyuiop',
'monkey',
'123321',
'dragon',
'654321',
'666666',
'123',
'myspace1',
'a123456',
'121212',
'1qaz2wsx',
'123qwe',
'123abc',
'tinkle',
'target123',
'gwerty',
'1g2w3e4r',
'gwerty123',
'zag12wsx',
];
}
} |
<?php
namespace Tests\Feature;
use Tests\TestCase;
use Illuminate\Foundation\Testing\WithFaker;
use Illuminate\Foundation\Testing\RefreshDatabase;
class ChequeTest extends TestCase
{
/**
* Get all the cheques
*
* @return void
*/
public function testListOfAllCheques()
{
$response = $this->get('/cheques');
$response->assertStatus(200);
}
/**
* Get all the cheques
*
* @return void
*/
public function testFilteredListOfChequesByRecipientNameOK()
{
$response = $this->get('/cheques?filter[recipientName_eq]=JohnDoe');
$response->assertStatus(200);
}
/**
* Get all the cheques
*
* @return void
*/
public function testFilteredListOfChequesByAmountReject()
{
$response = $this->get('/cheques?filter[amount_eq]=5000');
$response->assertStatus(200);
}
}
|
<?php
namespace Hue\Helpers;
require_once 'vendor/autoload.php';
class Config
{
public function __construct(){
foreach (parse_ini_file($_SERVER['HOME'].'/.hue') as $key => $value) {
$this->$key = $value;
}
}
public function get($property){
if(isset($this->$property)){
return $this->$property;
}
}
} |
<?php //Etiqueta php
class Bd{
private static $conexion = NULL; //Variable conexion para la cadena
private function __construc() {} //Precargar información para el uso de la conexión
public static function conectar(){
$pdo_option[PDO::ATTR_ERRMODE]=PDO::ERRMODE_EXCEPTION; //Cachar la excepcion si existe un error
self::$conexion = new PDO('mysql:host=localhost;dbname=biblioteca','root','',$pdo_option); //Cadena de conexion con PDO
return self::$conexion;
}
}
?> |
<?php
/**
* Created by PhpStorm.
* User: EVER
* Date: 24/06/2016
* Time: 11:37
*/
namespace CrudBundle\DataFixtures\ORM;
use Doctrine\Common\DataFixtures\AbstractFixture;
use Doctrine\Common\DataFixtures\OrderedFixtureInterface;
use Doctrine\Common\Persistence\ObjectManager;
use app\CrudBundle\Entity\Invoice;
class LoadInvoiceData extends AbstractFixture implements OrderedFixtureInterface
{
public function load(ObjectManager $em){
for($i = 1; $i <= 10; $i++) {
$invoice = new Invoice();
$invoice->setRef('Invoice n' . $i);
$invoice->setDateInvoice(new \DateTime());
$this->setReference('Invoice n' . $i, $invoice);
$em->persist($invoice);
}
$em->flush($invoice);
}
public function getOrder()
{
return 3; // the order in which fixtures will be loaded
}
} |
<?php
namespace App\Http\Controllers;
use App\User;
use Illuminate\Http\Request;
use App\Http\Requests;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\DB;
use Illuminate\Support\Facades\Hash;
use Illuminate\Support\Facades\Mail;
use Illuminate\Support\Facades\Validator;
class ResetPasswordController extends Controller
{
//修改密码
public function Resetpassword(Request $request){
$validator = Validator::make($request->all(),[
'oldPassword' => 'required',
'newPassword' => 'required'
]);
if ($validator->fails()){
return[
'error' => -1,
'des' => $validator->errors()
];
}
$stuId = Auth::user()->stuId;
$password = DB::table('students')
->where('stuId',$stuId)
->select('password')
->first();
// return $password->password;
if (!Hash::check($request->oldPassword,$password->password)){
return[
'error' => -3,
'des' => '输入的原密码错误'
];
}
$res = DB::table('students')
->where('stuId',$stuId)
->update([
'password' => bcrypt($request->newPassword)
]);
return[
'error' => (!$res? -2 : 0),
];
}
}
|
<?php
require_once "ControllerInterface.php";
require_once "../model/Orders/OrderClass.php";
require_once "../model/persist/OrderADO.php";
require_once "../model/persist/Users/UserADO.php";
require_once "../model/persist/TablesADO/TableADO.php";
class OrderControllerClass implements ControllerInterface {
private $action;
private $jsonData;
private $data = [];
private $orderADO;
private $userADO;
private $tableADO;
function __construct($action, $jsonData) {
$this->orderADO = new OrderADO();
$this->userADO = new UserADO();
$this->tableADO = new TableADO();
$this->setAction($action);
$this->setJsonData($jsonData);
}
public function getAction() {
return $this->action;
}
public function getJsonData() {
return $this->jsonData;
}
public function setAction($action) {
$this->action = $action;
}
public function setJsonData($jsonData) {
$this->jsonData = $jsonData;
}
public function doAction() {
switch ($this->getAction()) {
case 1:
$this->newClientOrder();
break;
case 2:
$this->getOrdersChef();
break;
case 3:
$this->setOrderPrepared();
break;
case 4:
$this->getAllOrders();
break;
default:
$errors = array();
$this->data [] = false;
$errors[] = "Sorry, there has been an error. Try later";
$this->data[] = $errors;
error_log("Action not correct in MealController, value: " . $this->getAction());
break;
}
return $this->data;
}
public function getAllOrders() {
$result = $this->orderADO->findAll()->fetchAll(PDO::FETCH_OBJ);
if ($result != null && is_array($result)) {
$this->data[] = true;
$this->data[] = $result;
} else {
$this->data[] = false;
$this->errors[] = "Sorry there has been an error in the server, try again later or in a few minuts.";
$this->data[] = $this->errors;
}
}
public function setOrderPrepared() {
$json = json_decode(stripslashes($this->jsonData));
$result = $this->orderADO->updateOrderStatus($json->orderId, 3)->rowCount();
if ($result > 0) {
$this->data[] = true;
} else {
$this->data[] = false;
$this->errors[] = "There has been an error in the server while processing the orders of the chef, try again later.";
$this->data[] = $this->errors;
}
}
public function getOrdersChef() {
$json = json_decode(stripslashes($this->jsonData));
//1.Get the chef of the database
$resultChef = $this->userADO->selectChefId($_SESSION['connectedUser'])->fetchAll(PDO::FETCH_OBJ);
if (count($resultChef) > 0) {
$chefId = $resultChef[0]->chef_id;
$result = $this->orderADO->findChefOrders($chefId)->fetchAll(PDO::FETCH_OBJ);
if (count($result) > 0) {
$this->data[] = true;
$this->data[] = $result;
} else {
$this->data[] = true;
$this->data[] = [];
}
} else {
$this->data[] = false;
$this->errors[] = "There has been an error in the server while processing the orders of the chef, try again later.";
$this->data[] = $this->errors;
}
//var_dump($json);
}
public function newClientOrder() {
$json = json_decode(stripslashes($this->jsonData));
//1. Check what Chef is preparing less menus
$resultChef = $this->orderADO->findChefDisponible()->fetchAll(PDO::FETCH_OBJ);
if (count($resultChef) == 0) {
$chefId = 1;
} else {
$chefId = $resultChef[0]->chef_id;
}
//2. Check what waiter has less menus assigned
$resultWaiter = $this->orderADO->findWaiterAvailable()->fetchAll(PDO::FETCH_OBJ);
if (count($resultWaiter) == 0) {
$waiterId = 1;
} else {
$waiterId = $resultWaiter[0]->waiter_id;
}
//3. Select the client in the table clients
$resultClientId = $this->userADO->selectClientId($json->client->userId)->fetchAll(PDO::FETCH_OBJ);
$clientId = $resultClientId[0]->client_id;
if ($clientId == null) {
$this->data[] = false;
$this->errors[] = "There has been an error in the server while processing your order, try again later.";
$this->data[] = $this->errors;
} else {
$order = new OrderClass(0, 1, $json->table->tableId, $chefId, $waiterId, $clientId, $json->menu->menuId, "", $json->totalPrice);
$result = $this->orderADO->create($order);
if ($result > 0) {
$resultUpdate = $this->tableADO->updateStatus($json->table->tableId, 1)->rowCount();
if ($resultUpdate > 0) {
$order->setOrderId($result);
$this->data[] = true;
$this->data[] = $order->getAll();
} else {
$this->data[] = false;
$this->errors[] = "There has been an error in the server while processing your order, try again later.";
$this->data[] = $this->errors;
}
} else {
$this->data[] = false;
$this->errors[] = "There has been an error in the server while processing your order, try again later.";
$this->data[] = $this->errors;
}
}
}
}
|
<?php
/*
* This file is part of SplashSync Project.
*
* Copyright (C) Splash Sync <www.splashsync.com>
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Splash\Tasking\Services;
use DateTime;
use Doctrine\Persistence\ManagerRegistry as Registry;
use Exception;
use Psr\Log\LoggerInterface;
use Sentry;
use Splash\Tasking\Entity\Task;
use Splash\Tasking\Handler\TaskHandler;
use Splash\Tasking\Model\AbstractBatchJob;
use Splash\Tasking\Model\AbstractJob;
use Splash\Tasking\Model\AbstractMassJob;
use Splash\Tasking\Tools\Status;
use Splash\Tasking\Tools\Timer;
use Symfony\Bridge\Monolog\Logger;
/**
* Tasks Runner
*
* Load Available Tasks from database, Acquire Token & Execute
* Look so simple... but!
*
* @SuppressWarnings(PHPMD.CouplingBetweenObjects)
*/
class Runner
{
/**
* @var TaskHandler
*/
protected TaskHandler $taskHandler;
/**
* Current Task Class to Execute
*
* @var null|Task
*/
private ?Task $task = null;
/**
* @var AbstractJob
*/
private AbstractJob $job;
/**
* Service Constructor
*/
public function __construct(
private JobsManager $jobs,
private LoggerInterface $logger,
private Registry $registry,
private TokenManager $token
) {
//====================================================================//
// Setup Tasks Logger
$this->taskHandler = new TaskHandler();
if ($this->logger instanceof Logger) {
$this->logger->pushHandler($this->taskHandler);
}
}
//==============================================================================
// PUBLIC - Task Execution Management
//==============================================================================
/**
* Ask Runner to Execute Next Available Task
*
* @throws Exception
*
* @return bool True if A Task was Executed
*/
public function run(): bool
{
//====================================================================//
// Store Task Startup Time
Timer::start();
//==============================================================================
// Clear Current Entity Manager
Configuration::getTasksRepository()->clear();
//==============================================================================
// Clear Global Entity Manager
$this->registry->getManager()->clear();
//====================================================================//
// Run Next Normal Tasks
if ($this->runNextTask(false)) {
//====================================================================//
// A Task was Executed
Timer::wipStandBy();
return true;
}
//====================================================================//
// Run Next Static Tasks
if ($this->runNextTask(true)) {
//====================================================================//
// A Task was Executed
Timer::wipStandBy();
return true;
}
//====================================================================//
// Wait
Timer::idleStandBy();
return false;
}
/**
* Ensure We released The Current Token
*
* @throws Exception
*
* @return bool
*/
public function ensureTokenRelease(): bool
{
return $this->token->release();
}
//==============================================================================
// PRIVATE - Task Execution Management
//==============================================================================
/**
* Execute Next Available Task
*
* @param bool $staticMode Execute Static Tasks
*
* @throws Exception
*
* @return boolean
*/
private function runNextTask(bool $staticMode) : bool
{
//====================================================================//
// Load Next Task To Run with Current Token
$this->loadNextTask($staticMode);
//====================================================================//
// No Tasks To Execute
if (is_null($this->task)) {
//====================================================================//
// Release Token (Return True only if An Active Token was released)
return $this->token->release();
}
//====================================================================//
// Acquire or Verify Token For this Task
if (!$this->token->acquire($this->task)) {
//====================================================================//
// Token Acquire Refused
// => This Should Never Happen
// => If Rejected Process will Die
return false;
}
//==============================================================================
// Validate & Prepare User Job Execution
//==============================================================================
if (!$this->validateJob($this->task) || !$this->prepareJob($this->task)) {
$this->task->setTry($this->task->getTry() + 1);
//==============================================================================
// Save Status in Db
Configuration::getTasksRepository()->flush();
return true;
}
//==============================================================================
// Save Status in Db
Configuration::getTasksRepository()->flush();
//====================================================================//
// Execute Task
//====================================================================//
$this->executeJob($this->task);
if (isset($this->task)) {
//==============================================================================
// Do Post Execution Actions
$this->closeJob($this->task, Configuration::getTasksMaxRetry());
$this->clearEntityManagers();
//==============================================================================
// Save Status in Db
Configuration::getTasksRepository()->flush();
}
//====================================================================//
// Exit & Ask for a Next Round
return true;
}
/**
* Load Next Available Tasks with Potential Existing Token
*
* @param bool $staticMode Execute Static Tasks
*
* @throws Exception
*/
private function loadNextTask(bool $staticMode) : void
{
//====================================================================//
// Use Current Task Token or Null
$currentToken = isset($this->task) && (Status::getTokenLifetime() >= Configuration::getWorkerWatchdogDelay())
? $this->task->getJobToken()
: null
;
//====================================================================//
// Load Next Task To Run with Current Token
$this->task = Configuration::getTasksRepository()->getNextTask(
Configuration::getTasksConfiguration(),
$currentToken,
$staticMode
);
}
//==============================================================================
// PRIVATE - Job Execution Management
//==============================================================================
/**
* Validate Job Before Execution
*
* @param Task $task
*
* @return bool
*/
private function validateJob(Task $task): bool
{
//==============================================================================
// Load Requested Job Service
try {
$this->job = $this->jobs->get($task->getJobClass());
} catch (Exception $e) {
$task->setFaultStr($e->getMessage());
return false;
}
//==============================================================================
// Verify Requested Method Exists
$jobAction = $task->getJobAction();
if (!method_exists($this->job, $jobAction)) {
$task->setFaultStr("Unable to find Requested Job Function");
return false;
}
return true;
}
/**
* Prepare Job For Execution
*
* @param Task $task
*
* @throws Exception
*
* @return bool
*/
private function prepareJob(Task $task): bool
{
//====================================================================//
// Init Task
$task->setRunning(true);
$task->setFinished(false);
$task->setStartedAt();
$task->setStartedBy($task->getCurrentServer());
$task->setTry($task->getTry() + 1);
$task->clearOutputs();
$task->setFaultStr(null);
//====================================================================//
// Reset Tasks Log Handler
$this->taskHandler->reset();
//====================================================================//
// Safety Check
if ($task->isFinished() && !$task->isStaticJob()) {
$task->setFaultStr("Your try to Start an Already Finished Task!!");
return false;
}
//====================================================================//
// Init Task Status Manager
Status::setJobStarted();
//====================================================================//
// Init User Job
$this->job->__set("inputs", $task->getJobInputs());
//====================================================================//
// User Information
$this->logger->info('Execute : '.$task->getJobClass()." -> ".$task->getJobAction().' ('.$task->getId().')');
$this->logger->info('Parameters : '.print_r($task->getJobInputs(), true));
return true;
}
/**
* Main Function for Job Execution
*
* @param Task $task
*
* @return void
*/
private function executeJob(Task $task): void
{
//==============================================================================
// Turn On Output Buffering to Get Task Outputs Captured
ob_start();
//==============================================================================
// Execute Requested Operation
//==============================================================================
try {
$result = $this->executeJobAction($task);
} catch (Exception $exception) {
//==============================================================================
// Catch Any Exceptions that may occur during task execution
$result = false;
$task->setFaultStr($exception->getMessage().PHP_EOL.$exception->getFile()." Line ".$exception->getLine());
$task->setFaultTrace($exception->getTraceAsString());
//==============================================================================
// Push Exception to Sentry if Installed
if (function_exists('Sentry\captureException')) {
Sentry\captureException($exception);
}
//====================================================================//
// User Information
$this->logger->error('Runner: Task Fail: '.$exception->getMessage());
}
//==============================================================================
// Flush Output Buffer
$task->appendOutputs((string) ob_get_contents());
ob_end_clean();
//==============================================================================
// If Job is Successful => Store Status
if ($result) {
$task->setFinished(true);
}
}
/**
* Main Function for Job Execution
*
* @param Task $task
*
* @return bool
*/
private function executeJobAction(Task $task): bool
{
//==============================================================================
// Execute Job Self Validate & Prepare Methods
if (!$this->job->validate() || !$this->job->prepare()) {
if (null == $task->getFaultStr()) {
$task->setFaultStr("Unable to initiate this Job.");
}
return false;
}
//==============================================================================
// Execute Job Action
$result = (bool) $this->job->{$task->getJobAction()}();
if ((false === $result) && (null == $task->getFaultStr())) {
$task->setFaultStr("An error occurred when executing this Job.");
}
//==============================================================================
// Execute Job Self Finalize & Close Methods
if (!$this->job->finalize() || !$this->job->close()) {
if (null == $task->getFaultStr()) {
$task->setFaultStr("An error occurred when closing this Job.");
}
}
return $result;
}
/**
* End Task on Scheduler
*
* @param Task $task
* @param int $maxTry Max number of retry. Once reached, task is forced to finished.
*
* @throws Exception
*/
private function closeJob(Task $task, int $maxTry): void
{
//====================================================================//
// Init Task Status Manager
Status::setJobFinished();
//==============================================================================
// End of Task Execution
$task->setRunning(false);
$task->setFinishedAt();
//==============================================================================
// If Static Task => Set Next Planned Execution Date
if ($task->isStaticJob()) {
$task->setTry(0);
$task->setPlannedAt(
new DateTime("+".$task->getJobFrequency()."Minutes ")
);
}
//==============================================================================
// Failed More than maxTry => Set Task as Finished
if ($task->getTry() > $maxTry) {
$task->setFinished(true);
return;
}
//==============================================================================
// IF Batch Job or Mass Job
$job = $this->getBatchOrMassJob();
if ($job) {
//==============================================================================
// If Batch Task Not Completed => Setup For Next Execution
if (!$job->getStateItem("isCompleted")) {
$task->setTry(0);
$task->setFinished(false);
}
//==============================================================================
// Backup Inputs Parameters For Next Actions
$task->setJobInputs($job->getRawInputs());
}
//====================================================================//
// User Information
$this->logger->info('Runner: Task Delay = '.$task->getDuration()." Milliseconds </info>");
//====================================================================//
// Import Tasks Log Handler
$task->appendOutputs($this->taskHandler->getLogAsString());
$this->taskHandler->reset();
}
/**
* Clear All Entity Managers, Except Tasking Manager
*
* @return void
*/
private function clearEntityManagers(): void
{
foreach (array_keys($this->registry->getManagerNames()) as $managerName) {
if ($managerName != Configuration::getEntityManagerName()) {
$this->registry->getManager($managerName)->clear();
}
}
}
/**
* Check if Batch or Mass Job
*
* @return null|AbstractBatchJob|AbstractMassJob
*/
private function getBatchOrMassJob(): ?AbstractJob
{
if (!isset($this->job)) {
return null;
}
if (is_a($this->job, AbstractBatchJob::class) || is_a($this->job, AbstractMassJob::class)) {
return $this->job;
}
return null;
}
}
|
<?php
declare(strict_types=1);
namespace voku\SimplePhpParser\Parsers;
use Roave\BetterReflection\Reflection\ReflectionClass;
final class PhpCodeChecker
{
public static function checkFromString(
string $code,
array $access = ['public', 'protected', 'private'],
bool $skipMixedTypesAsError = false,
bool $skipDeprecatedMethods = false,
bool $skipFunctionsWithLeadingUnderscore = false,
bool $skipParseErrorsAsError = true
): array {
return self::checkPhpFiles(
$code,
$access,
$skipMixedTypesAsError,
$skipDeprecatedMethods,
$skipFunctionsWithLeadingUnderscore,
$skipParseErrorsAsError
);
}
/**
* @param string $path
* @param bool $skipMixedTypesAsError
* @param string[] $access
* @param bool $skipDeprecatedFunctions
* @param bool $skipFunctionsWithLeadingUnderscore
* @param bool $skipParseErrorsAsError
* @param string[] $autoloaderProjectPaths
* @param string[] $pathExcludeRegex
*
* @return string[][]
*/
public static function checkPhpFiles(
string $path,
array $access = ['public', 'protected', 'private'],
bool $skipMixedTypesAsError = false,
bool $skipDeprecatedFunctions = false,
bool $skipFunctionsWithLeadingUnderscore = false,
bool $skipParseErrorsAsError = true,
array $autoloaderProjectPaths = [],
array $pathExcludeRegex = []
): array {
$phpInfo = PhpCodeParser::getPhpFiles(
$path,
$autoloaderProjectPaths,
$pathExcludeRegex
);
$errors = $phpInfo->getParseErrors();
$errors = self::checkFunctions(
$phpInfo,
$skipDeprecatedFunctions,
$skipFunctionsWithLeadingUnderscore,
$skipMixedTypesAsError,
$skipParseErrorsAsError,
$errors
);
return self::checkClasses(
$phpInfo,
$access,
$skipDeprecatedFunctions,
$skipFunctionsWithLeadingUnderscore,
$skipMixedTypesAsError,
$skipParseErrorsAsError,
$errors
);
}
/**
* @param \voku\SimplePhpParser\Parsers\Helper\ParserContainer $phpInfo
* @param string[] $access
* @param bool $skipDeprecatedMethods
* @param bool $skipMethodsWithLeadingUnderscore
* @param bool $skipMixedTypesAsError
* @param bool $skipParseErrorsAsError
* @param array $error
*
* @return array
*/
private static function checkClasses(
Helper\ParserContainer $phpInfo,
array $access,
bool $skipDeprecatedMethods,
bool $skipMethodsWithLeadingUnderscore,
bool $skipMixedTypesAsError,
bool $skipParseErrorsAsError,
array $error
): array {
foreach ($phpInfo->getClasses() as $class) {
foreach ($class->getPropertiesInfo(
$access,
$skipMethodsWithLeadingUnderscore
) as $propertyName => $propertyTypes) {
$typeFound = false;
foreach ($propertyTypes as $key => $type) {
if ($key === 'typeFromPhpDocMaybeWithComment' || $key === 'typeFromDefaultValue') {
continue;
}
if (
$type
&&
($skipMixedTypesAsError || $type !== 'mixed')
) {
$typeFound = true;
}
}
if ($typeFound) {
if ($propertyTypes['typeFromPhpDocSimple'] && $propertyTypes['type']) {
$error = self::checkPhpDocType(
$propertyTypes,
['file' => $class->file, 'line' => $class->line ?? null],
($class->name ?? '?'),
$error,
($class->name ?? null),
null,
$propertyName
);
}
} else {
$error[$class->file ?? ''][] = '[' . ($class->line ?? '?') . ']: missing property type for ' . ($class->name ?? '?') . '->$' . $propertyName;
}
}
foreach ($class->getMethodsInfo(
$access,
$skipDeprecatedMethods,
$skipMethodsWithLeadingUnderscore
) as $methodName => $methodInfo) {
foreach ($methodInfo['paramsTypes'] as $paramName => $paramTypes) {
$typeFound = false;
foreach ($paramTypes as $key => $type) {
if ($key === 'typeFromPhpDocMaybeWithComment' || $key === 'typeFromDefaultValue') {
continue;
}
if (
$type
&&
($skipMixedTypesAsError || $type !== 'mixed')
) {
$typeFound = true;
}
}
if ($typeFound) {
if ($paramTypes['typeFromPhpDocSimple'] && $paramTypes['type']) {
$error = self::checkPhpDocType(
$paramTypes,
$methodInfo,
($class->name ?? '?') . ($methodInfo['is_static'] ? '::' : '->') . $methodName . '()',
$error,
($class->name ?? null),
$paramName
);
}
} else {
$error[$methodInfo['file'] ?? ''][] = '[' . ($methodInfo['line'] ?? '?') . ']: missing parameter type for ' . ($class->name ?? '?') . ($methodInfo['is_static'] ? '::' : '->') . $methodName . '() | parameter:' . $paramName;
}
}
/** @noinspection InArrayCanBeUsedInspection */
if (
$methodName !== '__construct'
&&
$methodName !== '__destruct'
&&
$methodName !== '__unset'
&&
$methodName !== '__wakeup'
&&
$methodName !== '__clone'
) {
$typeFound = false;
foreach ($methodInfo['returnTypes'] as $key => $type) {
if ($key === 'typeFromPhpDocMaybeWithComment') {
continue;
}
if (
$type
&&
($skipMixedTypesAsError || $type !== 'mixed')
) {
$typeFound = true;
}
}
if ($typeFound) {
if ($methodInfo['returnTypes']['typeFromPhpDocSimple'] && $methodInfo['returnTypes']['type']) {
/** @noinspection ArgumentEqualsDefaultValueInspection */
$error = self::checkPhpDocType(
$methodInfo['returnTypes'],
$methodInfo,
($class->name ?? '?') . ($methodInfo['is_static'] ? '::' : '->') . $methodName . '()',
$error,
$class->name ?? null,
null
);
}
} else {
$error[$methodInfo['file'] ?? ''][] = '[' . ($methodInfo['line'] ?? '?') . ']: missing return type for ' . ($class->name ?? '?') . ($methodInfo['is_static'] ? '::' : '->') . $methodName . '()';
}
if (!$skipParseErrorsAsError && $methodInfo['error']) {
$error[$methodInfo['file'] ?? ''][] = '[' . ($methodInfo['line'] ?? '?') . ']: ' . $methodInfo['error'];
}
}
}
}
return $error;
}
/**
* @param \voku\SimplePhpParser\Parsers\Helper\ParserContainer $phpInfo
* @param bool $skipDeprecatedFunctions
* @param bool $skipFunctionsWithLeadingUnderscore
* @param bool $skipMixedTypesAsError
* @param bool $skipParseErrorsAsError
* @param array $error
*
* @return string[][]
*/
private static function checkFunctions(
Helper\ParserContainer $phpInfo,
bool $skipDeprecatedFunctions,
bool $skipFunctionsWithLeadingUnderscore,
bool $skipMixedTypesAsError,
bool $skipParseErrorsAsError,
array $error
): array {
foreach ($phpInfo->getFunctionsInfo(
$skipDeprecatedFunctions,
$skipFunctionsWithLeadingUnderscore
) as $functionName => $functionInfo) {
foreach ($functionInfo['paramsTypes'] as $paramName => $paramTypes) {
$typeFound = false;
foreach ($paramTypes as $key => $type) {
if ($key === 'typeFromPhpDocMaybeWithComment' || $key === 'typeFromDefaultValue') {
continue;
}
if (
$type
&&
($skipMixedTypesAsError || $type !== 'mixed')
) {
$typeFound = true;
}
}
if ($typeFound) {
if ($paramTypes['typeFromPhpDocSimple'] && $paramTypes['type']) {
$error = self::checkPhpDocType(
$paramTypes,
$functionInfo,
$functionName . '()',
$error,
null,
$paramName
);
}
} else {
$error[$functionInfo['file'] ?? ''][] = '[' . ($functionInfo['line'] ?? '?') . ']: missing parameter type for ' . $functionName . '() | parameter:' . $paramName;
}
}
$typeFound = false;
foreach ($functionInfo['returnTypes'] as $key => $type) {
if ($key === 'typeFromPhpDocMaybeWithComment') {
continue;
}
if (
$type
&&
($skipMixedTypesAsError || $type !== 'mixed')
) {
$typeFound = true;
}
}
if ($typeFound) {
if ($functionInfo['returnTypes']['typeFromPhpDocSimple'] && $functionInfo['returnTypes']['type']) {
/** @noinspection ArgumentEqualsDefaultValueInspection */
$error = self::checkPhpDocType(
$functionInfo['returnTypes'],
$functionInfo,
$functionName . '()',
$error,
null,
null
);
}
} else {
$error[$functionInfo['file'] ?? ''][] = '[' . ($functionInfo['line'] ?? '?') . ']: missing return type for ' . $functionName . '()';
}
if (!$skipParseErrorsAsError && $functionInfo['error']) {
$error[$functionInfo['file'] ?? ''][] = '[' . ($functionInfo['line'] ?? '?') . ']: ' . $functionInfo['error'];
}
}
return $error;
}
/**
* @param array $types
* @param array $fileInfo
* @param string[][] $error
* @param string $name
* @param string|null $className
* @param string|null $paramName
* @param string|null $propertyName
*
* @psalm-param array{type: null|string, typeFromPhpDoc: null|string, typeFromPhpDocPslam: null|string, typeFromPhpDocSimple: null|string, typeFromPhpDocMaybeWithComment: null|string, typeFromDefaultValue?: null|string} $types
* @psalm-param array{file: null|string, line: null|int} $fileInfo
*
* @return array
*/
private static function checkPhpDocType(
array $types,
array $fileInfo,
string $name,
array $error,
string $className = null,
string $paramName = null,
string $propertyName = null
): array {
// init
$typeFromPhpWithoutNull = null;
$typeFromPhpDocInput = $types['typeFromPhpDocSimple'];
$typeFromPhpInput = $types['type'];
$removeEmptyStringFunc = static function (?string $tmp): bool {
return $tmp !== '';
};
$typeFromPhpDoc = \array_filter(
\explode('|', $typeFromPhpDocInput ?? ''),
$removeEmptyStringFunc
);
/** @noinspection AlterInForeachInspection */
foreach ($typeFromPhpDoc as $keyTmp => $typeFromPhpDocSingle) {
/** @noinspection InArrayCanBeUsedInspection */
if (
$typeFromPhpDocSingle === '$this'
||
$typeFromPhpDocSingle === 'static'
||
$typeFromPhpDocSingle === 'self'
) {
$typeFromPhpDoc[$keyTmp] = $className;
}
if (\is_string($typeFromPhpDoc[$keyTmp])) {
$typeFromPhpDoc[$keyTmp] = \ltrim($typeFromPhpDoc[$keyTmp], '\\');
}
}
$typeFromPhp = \array_filter(
\explode('|', $typeFromPhpInput ?? ''),
$removeEmptyStringFunc
);
/** @noinspection AlterInForeachInspection */
foreach ($typeFromPhp as $keyTmp => $typeFromPhpSingle) {
/** @noinspection InArrayCanBeUsedInspection */
if (
$typeFromPhpSingle === '$this'
||
$typeFromPhpSingle === 'static'
||
$typeFromPhpSingle === 'self'
) {
$typeFromPhp[$keyTmp] = $className;
}
if (\is_string($typeFromPhp[$keyTmp])) {
$typeFromPhp[$keyTmp] = \ltrim($typeFromPhp[$keyTmp], '\\');
}
if ($typeFromPhpSingle && \strtolower($typeFromPhpSingle) !== 'null') {
$typeFromPhpWithoutNull = $typeFromPhp[$keyTmp];
}
}
if (
\count($typeFromPhpDoc) > 0
&&
\count($typeFromPhp) > 0
) {
foreach ($typeFromPhp as $typeFromPhpSingle) {
// reset
$checked = null;
/** @noinspection SuspiciousBinaryOperationInspection */
if (
$typeFromPhpSingle
&&
$typeFromPhpDocInput
&&
!\in_array($typeFromPhpSingle, $typeFromPhpDoc, true)
&&
(
$typeFromPhpSingle === 'array' && \strpos($typeFromPhpDocInput, '[]') === false
||
$typeFromPhpSingle !== 'array'
)
) {
$checked = false;
/** @noinspection ArgumentEqualsDefaultValueInspection */
if (
(
\class_exists($typeFromPhpSingle, true)
||
\interface_exists($typeFromPhpSingle, true)
)
) {
foreach ($typeFromPhpDoc as $typeFromPhpDocTmp) {
/** @noinspection ArgumentEqualsDefaultValueInspection */
if (
$typeFromPhpDocTmp
&&
(
\class_exists($typeFromPhpDocTmp, true)
||
\interface_exists($typeFromPhpDocTmp, true)
)
&&
(
/** @phpstan-ignore-next-line */
($typeFromPhpDocReflectionClass = ReflectionClass::createFromName($typeFromPhpDocTmp))
&&
(
$typeFromPhpDocReflectionClass->isSubclassOf($typeFromPhpSingle)
||
$typeFromPhpDocReflectionClass->implementsInterface($typeFromPhpSingle)
)
)
) {
$checked = true;
break;
}
}
}
if (!$checked) {
if ($propertyName) {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: missing property type "' . $typeFromPhpSingle . '" in phpdoc from ' . $name . ' | property:' . $propertyName;
} elseif ($paramName) {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: missing parameter type "' . $typeFromPhpSingle . '" in phpdoc from ' . $name . ' | parameter:' . $paramName;
} else {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: missing return type "' . $typeFromPhpSingle . '" in phpdoc from ' . $name;
}
}
}
}
foreach ($typeFromPhpDoc as $typeFromPhpDocSingle) {
// reset
/** @noinspection SuspiciousBinaryOperationInspection */
/** @noinspection NotOptimalIfConditionsInspection */
if (
(
$typeFromPhpDocSingle === 'null'
&&
!\in_array($typeFromPhpDocSingle, $typeFromPhp, true)
)
||
(
$typeFromPhpDocSingle !== 'null'
&&
$typeFromPhpWithoutNull
&&
$typeFromPhpDocSingle !== $typeFromPhpWithoutNull
)
) {
// reset
$checked = null;
if (
$typeFromPhpWithoutNull === 'bool'
&&
(
$typeFromPhpDocSingle === 'true'
||
$typeFromPhpDocSingle === 'false'
)
) {
$checked = true;
}
if (
$typeFromPhpDocSingle
&&
$typeFromPhpWithoutNull
&&
(
$typeFromPhpWithoutNull === 'array'
||
\ltrim($typeFromPhpWithoutNull, '\\') === 'Generator'
)
&&
\strpos($typeFromPhpDocSingle, '[]') !== false
) {
$checked = true;
}
if (
!$checked
&&
$typeFromPhpWithoutNull
) {
$checked = false;
/** @noinspection ArgumentEqualsDefaultValueInspection */
if (
$typeFromPhpDocSingle
&&
(
\class_exists($typeFromPhpWithoutNull, true)
||
\interface_exists($typeFromPhpWithoutNull, true)
)
&&
(
\class_exists($typeFromPhpDocSingle, true)
||
\interface_exists($typeFromPhpDocSingle, true)
)
) {
$typeFromPhpDocReflectionClass = ReflectionClass::createFromName($typeFromPhpDocSingle);
if (
$typeFromPhpDocReflectionClass->isSubclassOf($typeFromPhpWithoutNull)
||
$typeFromPhpDocReflectionClass->implementsInterface($typeFromPhpWithoutNull)
) {
$checked = true;
}
}
}
if (!$checked) {
if ($propertyName) {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: wrong property type "' . ($typeFromPhpDocSingle ?? '?') . '" in phpdoc from ' . $name . ' | property:' . $propertyName;
} elseif ($paramName) {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: wrong parameter type "' . ($typeFromPhpDocSingle ?? '?') . '" in phpdoc from ' . $name . ' | parameter:' . $paramName;
} else {
$error[$fileInfo['file'] ?? ''][] = '[' . ($fileInfo['line'] ?? '?') . ']: wrong return type "' . ($typeFromPhpDocSingle ?? '?') . '" in phpdoc from ' . $name;
}
}
}
}
}
return $error;
}
}
|
<?php
return [
'test-00135-03707' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; rv:47.0.1) Gecko/20100101 Firefox/47.0.1 anonymized by Abelssoft 676839740',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '47.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00135-03710' => [
'ua' => 'Mozilla/5.0 (Linux; Android 6.0.1; GCE x86 phone Build/MMB30K.MZD68) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2867.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '55',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '6.0.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'One',
'Device_Maker' => 'HTC',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'M7',
'Device_Brand_Name' => 'HTC',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03711' => [
'ua' => 'Mozilla/5.0 (iPad; CPU OS 9_3_1 like Mac OS X) AppleWebKit/601.1 (KHTML, like Gecko) CriOS/53.0.2785.109 Mobile/13E238 Safari/601.1.46',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '53.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '9.3.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPad',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Tablet',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPad',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00135-03712' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.22 (KHTML, like Gecko) Chrome/53.0.2785.116 Safari/537.22 anonymized by Abelssoft 1720234471',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '53',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03713' => [
'ua' => 'Mozilla/5.0 (X11; CrOS x86_64 14.4.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2867.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '55',
'Platform_Codename' => 'ChromeOS',
'Platform_Marketingname' => 'ChromeOS',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03719' => [
'ua' => 'Opera/9.80 (BlackBerry; Opera Mini/8.0.35667/37.8923; U; en) Presto/2.12.423 Version/12.16',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '12.16',
'Platform_Codename' => 'unknown',
'Platform_Marketingname' => 'unknown',
'Platform_Version' => 'unknown',
'Platform_Bits' => 32,
'Platform_Maker' => 'unknown',
'Platform_Brand_Name' => 'unknown',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Presto',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Opera Software ASA',
],
],
'test-00135-03736' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; SBC; .NET CLR 1.1.4322)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00135-03740' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.2; SM-G530FZ Build/LRX22G; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/51.0.2704.81 Mobile Safari/537.36 ACHEETAHI/2100502063',
'properties' => [
'Browser_Name' => 'CM Browser',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Cheetah Mobile',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Galaxy Grand Prime 4G LTE',
'Device_Maker' => 'Samsung',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SM-G530FZ',
'Device_Brand_Name' => 'Samsung',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03746' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2866.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '55',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03750' => [
'ua' => 'Mozilla/5.0 CommonCrawler Node WJBAHEPMEKIL5M5JRBYVVFGTHCYDYFZJU6D7COPX4TX7YGH7SQYZF4UH7LUIN2T.7.UIHL3V3XP6UFCEO3FLIMHCWFW3NKJ6PX24KQ5JYEIUPRGDCX.cdn0.common.crawl.zone',
'properties' => [
'Browser_Name' => 'CommonCrawler Node',
'Browser_Type' => 'Bot/Crawler',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'One',
'Device_Maker' => 'HTC',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'M7',
'Device_Brand_Name' => 'HTC',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00135-03754' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.2.2; Archos 35 Titanium Build/JDQ39) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.89 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '50',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.2.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00135-03756' => [
'ua' => 'Mozilla/5.0 CommonCrawler Node UIQJWZ25UQNIJOTMOU5OXSFZXQEONZDHLTDZKBCRZQ3FYUMJLA74JNOW7S3LMPV.Z.DX52JNI5K6YMAKJHYW7QIRV4H43QU6KJ53V44M2UZWQ4HUV5.cdn0.common.crawl.zone',
'properties' => [
'Browser_Name' => 'CommonCrawler Node',
'Browser_Type' => 'Bot/Crawler',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'One',
'Device_Maker' => 'HTC',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'M7',
'Device_Brand_Name' => 'HTC',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00135-03767' => [
'ua' => 'Mozilla/5.0 (iPhone; CPU iPhone OS 9_3_5 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13G36; DDG-iOS-784',
'properties' => [
'Browser_Name' => 'Default Browser',
'Browser_Type' => 'unknown',
'Browser_Bits' => 32,
'Browser_Maker' => 'unknown',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'iOS',
'Platform_Marketingname' => 'iOS',
'Platform_Version' => '9.3.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'iPhone',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'iPhone',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'WebKit',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Apple Inc',
],
],
'test-00135-03769' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2867.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '55',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
];
|
<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Welcome extends CI_Controller {
/**
* Index Page for this controller.
*
* Maps to the following URL
* http://example.com/index.php/welcome
* - or -
* http://example.com/index.php/welcome/index
* - or -
* Since this controller is set as the default controller in
* config/routes.php, it's displayed at http://example.com/
*
* So any other public methods not prefixed with an underscore will
* map to /index.php/welcome/<method_name>
* @see https://codeigniter.com/user_guide/general/urls.html
*/
public function index(){
$this->load->model('my_model');
$this->load->library('ci_pagination');
$data_per_page = 5;
$current_key = 0;
if(isset($_POST['ci_pagination_key'])){
$current_key = $_POST['ci_pagination_key'];
}
if(isset($_COOKIE['row_per_page'])){
$data['data_per_page'] = $data_per_page = $_COOKIE['row_per_page'];
}
$data['count_total'] = $count_total = $this->my_model->aggregate_data('pagination_country' , 'country_id' , 'COUNT');
$data['pagination_data'] = $this->ci_pagination->pagination_data($count_total, $current_key , $data_per_page);
$data['country_data'] = $this->my_model->select_data('*' , 'pagination_country' , '' , array($data_per_page,$current_key));
$data['current_key'] = $current_key;
$this->load->view('pagination',$data);
}
}
|
<html>
<head>
<meta charset="UTF-8">
<title>Common Problems</title>
</head>
<body>
<?php
phpinfo(); // makes simple php page confirms its working and more details
/*
# E_STRICT is available, with the value 2048. When enabled, messages will be issued to warn you about code usage which is deprecated or which may not be future-proof.
# http://php.net/manual/en/errorfunc.constants.php
# Warning and Errors
Make sure display errors is on and configured.
//In the php.ini file
display_errors = On
error_reporting = E_ALL
//In PHP code
ini_set('display_errors', 'On');
error_reporting(E_All);
//E_STRICT
error_reporting (E_ALL | E_STRICT);
// Use ~ for omit
error_reporting (E_ALL & ~E_DEPRECATED);
// return the current level
error_reporting();
-------------------------------------------------------------
# Fatal Errors
- PHP understood the code but could not execute it. (ex: calling a function that hasnt been defined)
# Syntax Errors
- PHP could not understand or process the code
# Warnings
- PHP found a problem, but was able to recover (ex: Dividing by 0)
# Notices
- PHP is offering advice
-------------------------------------------------------------
#Logs
- C:/wamp/logs/php_error.log
-------------------------------------------------------------
echo $variable; // variable value
print_r($array); // Use <pre> tags with this. Prints readable array
gettype($variable); // variable type
var_dump($variable); // variable type and value
get_defined_vars(); // array of defined variables
debug_backtrace(); // show backtrace
*/
?>
</body>
</html> |
<?php
use Illuminate\Support\Facades\Route;
use App\Models\User;
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/
Route::group([
'middleware' => 'App\Http\Middleware\Auth',
], function () {
Route::post('/password_modification', 'App\Http\Controllers\UserAccountController@password_modification');
Route::get('/password_modification', 'App\Http\Controllers\UserAccountController@form_password_modification');
Route::get('/profil', function(){
return view('profil');
});
Route::post('/livre/ajouter', 'App\Http\Controllers\livreController@ajouter');
Route::get('/deconnexion', 'App\Http\Controllers\UserController@deconnexion');
});
Route::get('/inscription', '\App\Http\Controllers\inscriptionController@inscription');
Route::post('/inscription', '\App\Http\Controllers\inscriptionController@formulaire');
Route::get('/connexion', '\App\Http\Controllers\connexionController@connexion');
Route::post('/connexion', '\App\Http\Controllers\connexionController@formulaire');
Route::get('/livre/{id}', [
'as' => 'livre',
'uses' => '\App\Http\Controllers\livreController@livre'
] );
Route::get('/catalogue', '\App\Http\Controllers\catalogueController@catalogue');
route::get('/', '\App\Http\Controllers\catalogueController@catalogue');
route::post('/livre/{id}/possede', '\App\Http\Controllers\UserController@possede');
Route::delete('/livre/{id}/possede', '\App\Http\Controllers\UserController@depossede'); |
<?php
namespace App\Repositories\Contracts;
use Illuminate\Database\Eloquent\Collection;
interface CategoryInterface
{
/**
* @param $type
* @return Collection
*/
public function getAll($type);
}
|
<?php
/**
* WP Settings - A set of classes to create a WordPress settings page for a Theme or a plugin.
* @author David Mårtensson <david.martensson@gmail.com>
* @version 1.9.1
* @package FeedMeAStrayCat
* @subpackage WPSettings
* @license MIT http://en.wikipedia.org/wiki/MIT_License
*/
// Set namespace
namespace FeedMeAStrayCat\WPSettings_1_9_1;
/*************************************
FEED ME A STRAY CAT
Flattr me here:
http://www.feedmeastraycat.net/projects/wordpress-snippets/wpsettings/
See more WP Snippets by me here:
http://www.feedmeastraycat.net/projects/wordpress-snippets/
I do more WP stuff together with Odd Alice:
http://oddalice.com/
HOW TO
Important note about namespaces:
----------------------------------
To enable WPSettings to work on a WordPress site, where multiple plugins or themes uses WPSettings (even though it might not be that common),
a namespace has been added to WPSettings.
The namespace will always look like this: \FeedMeAStrayCat\WPSettings_1_7_0 (for that specific version).
Use it together with if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings')) to only include your WPSettings file with the correct
version if it hasn't already been included.
In you code you can use the namespace to call the function/class directly:
$wp_settings_page = new \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage(...)
Or you use the "use" statement:
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings'))
require_once('/path/to/wpsettings.php');
}
$wp_settings_page = new WPSettingsPage(...)
Just remember to add use statements to all classes that you call directly.
----------------------------------
A simple example:
----------------------------------
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings')) {
require_once('/path/to/wpsettings.php');
}
add_action('admin_menu', 'my_admin_menu');
// This will contain the global WPSettingsPage object
global $wp_settings_page;
$wp_settings_page = null;
function my_admin_menu() {
global $wp_settings_page;
// Create a settings page
$wp_settings_page = new WPSettingsPage('My page title', 'Subtitle', 'My Menu Title', 'manage_options', 'my_unique_slug', 'my_admin_page_output', 'icon-url.png', $position=100);
// Set a id and add a css class so we can change the icon
$wp_settings_page->setIcon('my-icon-id', array('my-icon-class'));
// Adds a config section
$section = $wp_settings_page->addSettingsSection('first_section', 'The first section', 'This is the first section');
// Adds a text input
$section->addField('test_value', 'Test value', 'text', 'my_options[test]', 'Default value', 'Prefixed help text');
// Adds a textarea
$field = $section->addField('textarea_value', 'Textarea', 'textarea', 'my_options[textarea]', 'Default textarea value', 'Prefixed help text');
$field->setSize(200, 80);
// Adds a wysiwyg
$wysiwyg = $section->addField('wysiwyg_value', 'Test wysiwyg', 'wysiwyg', 'my_options[wysiwyg]', 'my_options[wysiwyg]', 'Wysiwyg help text');
$wysiwyg->setSettings(array('textarea_rows' => 5));
// Adds three checkboxes
$section->addField('test_checkboxes', 'Select cake', 'checkbox', array('my_options[cake_1]', 'my_options[cake_2]', 'my_options[cake_3]'), array(false, false, false), array('Cake 1', 'Cake 2', 'Cake 3'));
// Adds a dropdown without a option group
$dropdown = $section->addField('test_select', 'Select day', 'dropdown', 'my_options[day]', 'mon');
$dropdown->addOption('mon', 'Monday');
$dropdown->addOption('tues', 'Tuesday');
// Adds a dropdown with two groups
$dropdown = $section->addField('test_select2', 'Select day again', 'dropdown', 'my_options[day2]', 6);
// Uncomment this option to get a groupless option in the beginning
//$dropdown->addOption(0, 'Choose a Day');
$optgroup = $dropdown->addOptionGroup('Weekday');
$dropdown->addOption(1, 'Monday', $optgroup);
$dropdown->addOption(2, 'Tuesday', $optgroup);
$optgroup = $dropdown->addOptionGroup('Weekend');
$dropdown->addOption(6, 'Saturday', $optgroup);
$dropdown->addOption(7, 'Sunday', $optgroup);
// Adds three "radio" options
$radio = $section->addField('test_radio', 'Select month', 'radio', 'my_options[month]', 'jan');
$radio->addOption('jan', 'January');
$radio->addOption('feb', 'February');
$radio->addOption('mar', 'March');
// Activate settings
$wp_settings_page->activateSettings();
}
function my_admin_page_output() {
global $wp_settings_page;
$wp_settings_page->output();
}
----------------------------------
Subpages:
You can add subpages by calling the function addSubPage() on a WPSettingsPage object.
All the regular WPSettings features works on a sub page. The sub page is put as a sub menu
page link in the WP menu.
----------------------------------
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings')) {
require_once('/path/to/wpsettings.php');
}
add_action('admin_menu', 'my_admin_menu');
// This will contain the global WPSettingsPage object
global $wp_settings_page, $wp_settings_sub_page;
$wp_settings_page = null;
$wp_settings_sub_page = null;
function my_admin_menu() {
global $wp_settings_page, $wp_settings_sub_page;
// Create a settings page
$wp_settings_page = new WPSettingsPage('My page title', 'Subtitle', 'My menu title', 'manage_options', 'my_unique_slug', 'my_admin_page_output', 'icon-url.png', $position=100);
// Create a sub page
$wp_settings_sub_page = $wp_settings_page->addSubPage('My subpage', 'Subtitle', 'My menu subtitle', 'manage_options', 'my_unique_subpage_slug', 'my_admin_subpage_output');
// Create sections and so on ...
}
function my_admin_page_output() {
global $wp_settings_page;
$wp_settings_page->output();
}
function my_admin_subpage_output() {
global $wp_settings_page, $wp_settings_sub_page;
// You can do
$wp_settings_page->output('my_unique_subpage_slug');
// Or you can do
// $wp_settings_sub_page->output();
}
----------------------------------
Filters:
Through WPSettingsField->addFilter() you can add filters that uses the built in WP filters api. Send in which type of filter
you want to use, which must be one of the WPSettingsField::FILTER_ constants, the callback function and a priority integer.
----------------------------------
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage;
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsField;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings')) {
require_once('/path/to/wpsettings.php');
}
add_action('admin_menu', 'my_admin_menu');
// This will contain the global WPSettingsPage object
global $wp_settings_page;
$wp_settings_page = null;
function my_admin_menu() {
global $wp_settings_page;
// Create a settings page
$wp_settings_page = new WPSettingsPage('My page title', 'Subtitle', 'My menu title', 'manage_options', 'my_unique_slug', 'my_admin_page_output', 'icon-url.png', $position=100);
// Adds a config section
$section = $wp_settings_page->addSettingsSection('first_section', 'The first section', 'This is the first section');
// Adds a text input
$field = $section->addField('test_value', 'Test value', 'text', 'my_options[test]', 'Default value', 'Prefixed help text');
// Add a filter for when the text input is updated (1 is it's priority)
// The filters are called using WP built in filter API
$field->addFilter(WPSettingsField::FILTER_UPDATE, 'update_text_value', 1);
// Activate settings
$wp_settings_page->activateSettings();
}
function my_admin_page_output() {
global $wp_settings_page;
$wp_settings_page->output();
}
function update_text_value($field_obj, $input_value) {
// Do stuff or things...
// Optional, return altered input value.
// Return null to leave it as it is
return $input_value;
}
----------------------------------
Output Sections:
Output sections can be used to output custom HTML in the end of a settings page. Each output section is a callback function
that will be called after the settings sections in the order they where added. If you want to input custom form elements, you
need to store them by your self using the "wps_before_update" action.
----------------------------------
use \FeedMeAStrayCat\WPSettings_1_7_0\WPSettingsPage;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_7_0\WPSettings')) {
require_once('/path/to/wpsettings.php');
}
add_action('admin_menu', 'my_admin_menu');
// This will contain the global WPSettingsPage object
global $wp_settings_page;
$wp_settings_page = null;
function my_admin_menu() {
global $wp_settings_page;
// Create a settings page
$wp_settings_page = new WPSettingsPage('My page title', 'Subtitle', 'My menu title', 'manage_options', 'my_unique_slug', 'my_admin_page_output', 'icon-url.png', $position=100);
// Adds a config section
$section = $wp_settings_page->addSettingsSection('first_section', 'The first section', 'This is the first section');
// Adds a text input
$field = $section->addField('test_value', 'Test value', 'text', 'my_options[test]', 'Default value', 'Prefixed help text');
// Adds custom html in a output sections
$section = $wp_settings_page->addOutputSection('html_section', 'output_my_html_section', 'Optional Headline');
// Activate settings
$wp_settings_page->activateSettings();
}
function my_admin_page_output() {
global $wp_settings_page;
$wp_settings_page->output();
}
function output_my_html_section() {
?>
<p>Some custom HTML here...</p>
<?php
}
----------------------------------
Adding custom style and attributes:
You can set custom style and attribute using $field->setAttribute() and $field->setStyle(). The value you set should be an
array of associative arrays. Even if you only have one don't add multiple fields in one go as in the example below.
It can also be done one attribute or style at a time using $field->addAttribute() or $field->addStyle() where the first two
parameters are the attribute/style name and value and the third parameter is the index for which field to set it to.
Attributes can also be set directly into $section->addField() as the 9th parameter and styles as the 10th.
----------------------------------
use \FeedMeAStrayCat\WPSettings_1_9_1\WPSettingsPage;
if (!class_exists('\FeedMeAStrayCat\WPSettings_1_9_1\WPSettings')) {
require_once('/path/to/wpsettings.php');
}
add_action('admin_menu', 'my_admin_menu');
// This will contain the global WPSettingsPage object
global $wp_settings_page;
$wp_settings_page = null;
function my_admin_menu() {
global $wp_settings_page;
// Create a settings page
$wp_settings_page = new WPSettingsPage('My page title', 'Subtitle', 'My menu title', 'manage_options', 'my_unique_slug', 'my_admin_page_output', 'icon-url.png', $position=100);
// Adds a config section
$section = $wp_settings_page->addSettingsSection('first_section', 'The first section', 'This is the first section');
// Adds a text input
$field = $section->addField('test_value', 'Test', 'text', array('my_options[test]', 'my_options[test2]'));
$field->setAttributes(array(array('readonly' => 'readonly'), array('maxlength' => 10));
$field->setStyle(array(array('wifth' => '200px'), array('width' => '300px'));
// Can also be done like this:
$field = $section->addField('test_value2', 'Test 2', 'text', array('my_options[test3]', 'my_options[test4]'));
$field->addAttribute('readonly', 'readonly', 0);
$field->addAttribute('maxlength', '10', 1);
$field->addStyle('width', '200px', 0);
$field->addStyle('width', '300px', 1);
// Or for only one value
$field = $section->addField('test_value3', 'Test ', 'text', 'my_options[test5]');
$field->addAttribute('readonly', 'readonly');
$field->addAttribute('maxlength', '10');
$field->addStyle('width', '200px');
$field->addStyle('border', '1px solid red');
// Activate settings
$wp_settings_page->activateSettings();
}
function my_admin_page_output() {
global $wp_settings_page;
$wp_settings_page->output();
}
----------------------------------
FIELD TYPES
These are the types that can be used in addField() (the third parameter)
"text"
A standard text input type. Unsanitized.
"textarea"
A textarea input type. Unsanitized. Set size with $field->setSize(int $width, int $height)
"wysiwyg"
A What You See Is What You Get editor using the built in wp_editor() function. Unsanitized. Set settings args with $field->setSettings()
"url"
A URL text. Sanitized with esc_url()
"int"
A integer. Sanitized with (int)
"checkbox"
A checkbox, sanitizes to save 1 or 0
"dropdown"
A select type dropdown. Unsanitized.
"radio"
A set of radio options. Unsanitized.
"hex_color"
A HTML hex color value. Sanitize with allowed hex valued colors.
PAGE TYPES
Stand alone - Using $page = new WPSettingsPage() you can create a stand alone page that can contains sub pages
using $page->addSubPage().
Sub page to Theme section - Use WPSettingsThemePage.
Sub page to Dashboard page - Use WPSettingsDashboardPage.
Sub page to Posts page - Use WPSettingsPostsPage.
Sub page to Media page - Use WPSettingsMediaPage.
Sub page to Links page - Use WPSettingsLinksPage.
Sub page to Pages page - Use WPSettingsPagesPage.
Sub page to Comments page - Use WPSettingsCommentsPage.
Sub page to Plugins page - Use WPSettingsPluginsPage.
Sub page to Users page - Use WPSettingsUsersPage.
Sub page to Management page - Use WPSettingsManagementPage.
Sub page to Options page - Use WPSettingsOptionsPage.
Note that using $page->addSubPage() on any other page then the stand alone WPSettingsPage() object will throw
an exception.
NETWORK ADMIN
From version 1.9.0 there should be no issues creating a network admin settings page. Settings are stored using
update_site_option() and must therefor be fetched using get_site_option() instead of get_option().
http://codex.wordpress.org/Function_Reference/update_site_option
http://codex.wordpress.org/Function_Reference/get_site_option
FILTERS
These filters are available
FILTER_UPDATE
Parameters: 2
Parameter 1: WPSettingsField object
Parameter 2: Input value
Runs after sanitize, before value is stored in DB. The $field_id is the first parameter sent into addField(). This
parameter must be 1 to 50 characters, a-z (case insensitive), 0-9 or "-" and "_".
Note that this filter runs on all inputs in that field. If you send in multiple fields in an array (like in the
example "Adds three checkboxes") the same filter will run on all.
ACTIONS
These are the custom actions that are thrown by WPSettings which can be used to hook in custom features.
wps_before_update
Parameters: 0
Called after validation. Before update. Note that this action is triggered once for each field.
SETTINGS
WPSettings::$no_footer_text = true/false;
To display, or not display, footer information text on WPSettings created pages.
REQUIREMENTS
1) PHP 5.3 (changed from 5.0 to 5.3 in WPSettings 1.6.4)
2) WordPress 3.x (Tested in 3.2.1 and up, but will most likely work in 3.0 or even 2.7 when the Settings API was added)
TODOS
1) Add more types :)
2) Add html5 style input boxes (as well as some setting to create html or xhtml type inputs)
3) Add more filters and actions
IMPORTANT NOTES
1.9.0 - 2013-11-06
I've noticed that the wps_before_update action was only activated when input names existed, and when it was an
array, because the action was just triggered from WPSettingsPage->sanitize().
The action has been moved to WPSettingsField->sanitize() so it will get triggered on regular input names as well.
This means that it will be triggered once for each added input.
I've also noticed that there is no way to only use output settings and store stuff using the regular WPSettings
form. You have to do a output setting that contains the form it self. Or just add some setting through WPSetting
and the specials through a output section.
WPSettings can now also create network admin pages. Fields are stored using update_site_option().
1.7.0 - 2013-01-01
In WordPress 3.5 it seams like a change was made on ajax calls where the admin_menu action isn't triggered which
would cause problems with media upload if you follow the old examples using admin_menu to setup the WPSettingsPage
object and admin_init to register the settings page fields.
The easiest solution is to only use the admin_menu action and setup everything on that action. Another way would
be to make sure that your $wp_settings_page variable is an object before moving on in admin_init.
The examples have been updated to reflect this in 1.7.0.
VERSION HISTORY
1.9.1
Fixed dropdown to work with multiple attribute set (uses in_array() to test value instead of string == compare)
Removed esc_sql() sanitization. Both update_option() and update_site_option() expect unsanitized data and esc_sql() can cause issues.
1.9.0
Changes to wps_before_update action, will now trigger once on each added field
Settings pages are now also functional on network admin pages
Added action to correctly enqueue jquery on admin pages
Replaced deprecated $wpdb->escape() with esc_sql()
Added $field->setCurrentValue()
Added $field->setHelpText()
Added $field->setPlaceholder()
Added $field->setDescription()
Added $field->setAttributes()
Added $field->addAttribute()
Added $field->setStyle()
Added $field->addStyle()
Input fields (not checkbox, radio buttons or the wysiwyg) can have added attributes and custom style
1.8.1
Removed &$this pass by reference (deprecated)
Bugfix. Couldn't use only output sections.
Only output form if there are any settings sections.
1.8.0
Added the possibility to create subpages to the available sections using the objects WPSettingsThemePage,
WPSettingsDashboardPage, WPSettingsPostsPage, WPSettingsMediaPage, WPSettingsLinksPage, WPSettingsPagesPage,
WPSettingsCommentsPage, WPSettingsPluginsPage, WPSettingsUsersPage, WPSettingsManagementPage and
WPSettingsOptionsPage.
1.7.0
Fixed div container width on output regular text field
Added "textare" as field type. Set size using $field->setSize(int $width, int $height).
Added "wysiwyg" as field type. Set settings using $field->setSettings(array $settings)
Changed examples due to changes in WP 3.5 where admin_menu action isn't triggered (I think) on ajax calls which
created an error with media uploads site wide.
1.6.11
Bugfix. Had two places with short php open tags (just <? without "php") as well as missing the "echo".
1.6.10
Added $description as 8th parameter in $field = $section->addField(). Will output a <p class="description"> tag below
the field HTML. (Can, like Headline, Type, InputName, CurrentValue, HelpText and Placeholder be set using
$field->Description = "Foo Bar" because of the magic __set() funciton).
Updated the magic __set() function to always call setX() functions, if they exists, before just setting the value.
Bugfix in activateSettings() which caused subpage forms not submit correctly.
Changed some bas usages of esc_attr_e() to esc_attr()
Added text domain
1.6.9
Removed redundant class_exist check. You should do a class exist like in the examples. :)
Changed bad nameing habit of mine where i use double underscore ("__") as a prefix to private methods/vars. Changed
to single underscore ("_").
1.6.8
Added $placeholder as 7th optional parameter in $section->addField() which is used as placeholder-attribute in
text fields (for example "text" and "url" field type).
1.6.7
Changed how "checkbox" is output by adding a hidden field that is changed to "1" or "0" depending on the checkbox.
It's changed using jQuery (which is required and enqueued when a WPSettingsPage is constructed) and the .change()
event. This way a checkbox is stored as "1" or "0". Not just "1" when it's clicked and not at all when it's "0".
1.6.6
Moved Field sanitize from WPSettingsPage->sanitize() to WPSettingsField->sanitize() and fixed how
register_setting() is called in WPSettingsPage->activateSettings(). This fixes a bug that prevented settings name,
that wasn't part of an array (ex my_settings[name]), to be stored correctly. Settings now registers ones per
name (which must be unique) as well as one per "array name" ("my_settings" from example my_settings[name]).
Array names registers with WPSettingsPage->sanitize() which loops through and calles WPSettingsField->sanitize()
once per field. On the fields that has that specific array name.
Throws an exception when adding fields without a unique name.
Fixed namespace error when throwing Exceptions.
1.6.5
Removed width on container divs for output of dropdowns
1.6.4
Now requires PHP 5.3
WPSettings now is available from namespace FeedMeAStrayCat\WPSettings_X_X_X\ (see first note about namespaces).
Added footer text "Created with WPSettings X.X.X" to admin footer (on pages created with WPSettings). Can be
disabled by setting WPSettings::$no_footer_text to true.
Removed WP_SETTINGS_VERSION (added in 1.6.2) since it's not needed now with the namespace.
1.6.3
New type: "hex_color"
1.6.2
WPSettings now make sure a constant exists called WP_SETTINGS_VERSION. This will contain the version number
of the current loaded WPSettings. If two versions are loaded. The first loaded version number will be in the
const. If WPSettings is loaded, but no WP_SETTINGS_VERSION is found, it is set as 1.0. With this you can
make sure that the latest is loaded, and output an error message if it's not. If multiple WPSettings are
loaded it can still cause some problem, since you need to make sure that the first one loaded is the version
you need. Not sure how to fix that. Now you can see which version is loaded anyway. :)
1.6.1
Added Output Sections (see how to).
Fixed a small error in the how to examples.
Added action "wps_before_update".
Bug fix on FILTER_UPDATE.
1.6
Added validations of the id and field id in addSettingsSection() and addField(). These ids must be 1 to 50
characters, a-z (case insensitive), 0-9 or "-" and "_". The functions will throw an exception if the id
fails the validation.
Added filters function (see how to).
Added filter FILTER_UPDATE.
Had misspelled activateSettings() as activeteSettings() ... Since start. :-| Both works now. Misspelled is
deprecated and might be removed in future releases.
1.5.2
Wrap eeeverything within a class_exists() check to make sure the code isn't included twice through
different files, and by that causes trouble.
1.5.1
Bugfix set default position to null instead of 100. If there is two pages on 100 only one will show. But if
you just use null they will show in the bottom. After each other.
1.5
Added $wp_settings_page->setIcon($icon_id, $add_classes) which can be used to change the HTML id and class
of the settings page icon. Togheter with some css it can be used to change the icon. (WPSettings currently
doesn't create the css required). See the simple example.
1.4.1
Bugfix for subpage settings not beeing saved correct.
1.4
Added the possibility to add subpages to a settings page using $wp_settings_page->addSubPage(). See how to.
Changed a bit on page title and subtitle. On setting page it writes it "Title" if only title is given and
"Title — Subtitle" if both is given.
Changed so a settings form is only outputed if at least one section has been added via addSettingsSection().
This way a settings page can be created and default content can be put into it.
1.3
Added type: radio (see how to)
Added update message to settings page
1.2
Added type: selectbox (see how to)
1.1
Added types: url, int, checkbox
1.0
A first simple version to handle just text values.
LICENSE - MIT
http://en.wikipedia.org/wiki/MIT_License
Copyright (C) 2011 by David Mårtensson <david.martensson@gmail.com>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*************************************/
// Add action to enqueue jQuery
add_action('admin_enqueue_scripts', array('\FeedMeAStrayCat\WPSettings_1_9_1\WPSettingsPage', 'admin_enqueue_scripts'));
// Add action for Network Admin page edits
add_action('network_admin_edit_wps', array('\FeedMeAStrayCat\WPSettings_1_9_1\WPSettingsPage', 'network_admin_edit'));
/**
* WP Settings base class - Extended by WPSettingsPage, WPSettingsSection and WPSettingsField
*/
class WPSettings {
// Version constant
const VERSION = "1.9.1";
/**
* Keeps all input names to make sure that they are unique
* Access is protected because it's only used internally by WPSettingsField->addField()
* @var array
* @static
* @access protected
*/
protected static $_input_names = array();
/**
* Override to true to remove footer text
* @var bool
*/
public static $no_footer_text = false;
/**
* Magic get function, gets method first if exists, or property
* @param string $name
* @return mixed
* @throws Exception
*/
public function __get($name) {
if (method_exists($this, $name)) {
return $this->$name();
}
elseIf (isset($this->$name)) {
return $this->$name;
}
else {
// isset is false on null parameters, this "fixes" that checking if tha parameter truely doesn't exist
$props = get_object_vars($this);
if (array_key_exists($name, $props)) {
return $this->$name;
}
else {
throw new \Exception("Undefined method or property ".$name);
}
}
}
/**
* Magic set function
* @param string $name
* @param mixed $value
* @return void
*/
public function __set($name, $value) {
$method = "set{$name}";
if (method_exists($this, $method)) {
$this->$method($value);
}
elseIf (isset($this->$name)) {
$this->$name = $value;
}
else {
// isset is false on null parameters, this "fixes" that checking if tha parameter truely doesn't exist
$props = get_object_vars($this);
if (array_key_exists($name, $props)) {
$this->$name = $value;
}
else {
throw new \Exception("Failed to set \"".$name."\".");
}
}
}
}
/**
* WP Settings Page class
* @see WPSettings
*/
class WPSettingsPage extends WPSettings {
public $Id;
public $IsStandalonePage = true;
protected $Title;
protected $Subtitle;
protected $SettingsPageDescription;
protected $Sections = array();
protected $OutputSections = array();
protected $MenuSlug;
private $_subpages = array();
private $_pageIconClass = array();
private $_pageIconId;
protected static $RegisteredInputNames = array();
/**
* Create a WP Settings Page
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, $icon_url='', $position=null) {
$this->Id = $menu_slug;
$this->Title = $page_title;
$this->Subtitle = $page_subtitle;
$this->MenuSlug = $menu_slug;
if ($this->IsStandalonePage) {
add_menu_page($page_title, $menu_title, $capability, $menu_slug, $function, $icon_url, $position);
}
return $this;
}
/**
* Add a sub page
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @return WPSettingsPage
*/
public function addSubPage($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Don't allow on anything but stand alone pages
if (!$this->IsStandalonePage) {
throw new \Exception("Sub pages can not be added to this page type.");
}
// Create sub page as.
$subpage = new WPSettingsSubPage($this, $page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function);
// Store in this (parent) page array
$this->_subpages[$subpage->Id] = &$subpage;
return $subpage;
}
/**
* Activate settings. Is required to be run after all sections and fields has been added to register the settings so that
* WordPress saves the data
*/
public function activateSettings() {
// Store all registered input names (used by network admin page save)
$registered_input_names = array();
// Start looping through all pages
$pages = array_merge(array($this), $this->_subpages);
foreach ($pages AS $index => $page) {
// Get all uniques post names on array type names (ex my_setting[name])
$array_post_names = array();
// - Start looping through section
foreach ($page->Sections AS $index => $section) {
// - Start looping through each field in section
foreach ($section->Fields AS $index2 => $field) {
// - Start looping through each input name in this field (most often only 1)
foreach ($field->InputName AS $index3 => $input_name) {
// Part of an array name, ex: my_settings[name]
// These registers as one setting for "my_settings", even if there exist my_settings[name]
// and my_settings[name2]. Registers once per $page (in first loop here).
if (strpos($input_name, "[") !== false) {
$temp = explode("[", $input_name);
$name = $temp[0];
$array_post_names[] = $name;
}
// Is it's own name, can only work when the name is unique, registers the setting directly
// with sanitize on the $field object
else {
$registered_input_names[] = $input_name;
register_setting($page->Id, $input_name);
}
}
}
}
// Got any array post names?
if (count($array_post_names) > 0) {
// Get unique names
$array_post_names = array_unique($array_post_names);
// Register them for sanitize on the $page object
foreach ($array_post_names AS $index => $name) {
$registered_input_names[] = $name;
register_setting($page->Id, $name, array($page, 'sanitize'));
}
}
}
self::$RegisteredInputNames[$this->Id] = $registered_input_names;
}
/**
* Had misspelled activate as activete from beta to 1.5.2... :-|
* @deprecated
* @see WPSettingsPage::activateSettings()
*/
public function activeteSettings() {
$this->activateSettings();
}
/**
* Output the settings page
* @param string $subpage
*/
public function output($subpage='') {
// Output a subpage (call that objects output() function)
if ($subpage && isset($this->_subpages[$subpage]) && is_object($this->_subpages[$subpage])) {
$this->_subpages[$subpage]->output();
}
// Output this object page
else {
$this->_output();
}
}
/**
* Output settings page footer (added through action: admin_footer_text)
* Enter description here ...
* @param unknown_type $footer_text
*/
public function outputFooterText($footer_text) {
// Remove action
remove_action('admin_footer_text', array($this, 'outputFooterText'));
// Append and return footer text
$footer_text .= " | ".sprintf(__('Settings page created with <a href="%s">WPSettings %s</a>', 'wpsettings'), 'https://github.com/feedmeastraycat/WPSettings', WPSettings::VERSION);
return $footer_text;
}
/**
* The actual output of this objects page
*/
private function _output() {
// Add action for footer text
if (!$this::$no_footer_text) {
add_action('admin_footer_text', array($this, 'outputFooterText'), 50, 1);
}
// Form action url depending on network or regular admin page
$screen = get_current_screen();
$form_action = ($screen->is_network ? add_query_arg(array('action' => 'wps', 'id' => $this->Id), network_admin_url('edit.php')):admin_url('options.php'));
// Output page
?>
<div class="wrap">
<?php $this->_getIcon(); ?>
<h2><?php echo $this->Title ?><?php echo ($this->Title && $this->Subtitle ? " — ".$this->Subtitle:"") ?></h2>
<?php if( isset($_GET['settings-updated']) ) : ?>
<div id="message" class="updated">
<p><strong><?php _e('Settings saved.', 'wpsettings') ?></strong></p>
</div>
<?php endif; ?>
<?php if ($this->SettingsPageDescription) : ?>
<p><?php echo $this->SettingsPageDescription ?></p>
<?php endif; ?>
<?php if ( !empty($this->Sections) || count($this->OutputSections) > 0 ): ?>
<?php if ( !empty($this->Sections) ) : ?>
<form action="<?php echo $form_action ?>" method="post">
<?php settings_fields($this->Id); ?>
<?php do_settings_sections($this->Id); ?>
<?php endif; ?>
<?php
if (count($this->OutputSections) > 0) {
foreach ($this->OutputSections AS $index => $section) {
if (!empty($section['headline'])) {
?>
<h3><?php echo $section['headline'] ?></h3>
<?php
}
call_user_func($section['callback']);
}
}
if ( !empty($this->Sections) ) :
?>
<p class="submit">
<input name="Submit" type="submit" class="button-primary" value="<?php esc_attr_e('Save Changes', 'wpsettings'); ?>" >
</p>
</form>
<?php
endif;
?>
<?php endif; ?>
</div>
<?php
}
/**
* Sanitize data before it's stored in the databse. This sanitize function is registered when there are array post
* names. For example if the names on three fields are my_settings[name1], my_settings[name2] and other_setting.
* This function will be used to sanitize "my_settings" and $input will be an array containing the values.
* But "other_setting" will be santized directly by the field object sanitize() function (which gets called
* by this function, in the loop, as well).
* @param array $input
*/
public function sanitize($input) {
// Create new input
$new_input = array();
// Loop through sections
foreach ($this->Sections AS $section_index => $section) {
// Loop through fields in section
foreach ($section->Fields AS $field_index => $field) {
// Input name is a loop as well. Even though they all are the same type
foreach ($field->InputName AS $input_index => $input_name) {
// Get name
if (strpos($input_name, "[") !== false) {
// Get name from input name
$temp = explode("[", $input_name);
$name = str_replace("]", "", $temp[1]);
// Isn't a part of this input
if (!isset($input[$name])) {
continue;
}
// Get input
$_input = $input[$name];
}
// Has nothing to do here
else {
continue;
}
// Sanitize on the field
$new_input[$name] = $field->sanitize($_input);
}
}
}
return $new_input;
}
/**
* Add a new section
* @param string $id
* @param string $headline
* @param string $description Optional
* @return WPSettingsSection
* @throws Exception
*/
public function addSettingsSection($id, $headline, $description='') {
if (!preg_match("/^[a-z0-9\-\_]{1,50}$/i", $id)) {
throw new \Exception("Section id failed to validate");
}
$section = new WPSettingsSection($this, $id, $headline, $description);
$this->Sections[] = &$section;
return $section;
}
/**
* Add output section
* @param string $id
* @param mixed $callback
* @param string $headline Optional
* @return bool
* @throws Exception
*/
public function addOutputSection($id, $callback, $headline='') {
// Validate id
if (!preg_match("/^[a-z0-9\-\_]{1,50}$/i", $id)) {
throw new \Exception("Section id failed to validate");
}
// Make sure class and metod exists if array
if (is_array($callback)) {
if (is_string($callback[0]) && !class_exists($callback[0], true)) {
return false;
}
if (!method_exists($callback[0], $callback[1])) {
return false;
}
}
// Make sure function exists if string
if (is_string($callback)) {
if (!function_exists($callback)) {
return false;
}
}
// Store output section
$this->OutputSections[] = array('callback' => $callback, 'headline' => $headline);
}
/**
* Set page icon
* @param string $icon_id
* @param array $add_classes Optional
*/
public function setIcon($icon_id, $add_classes=array()) {
$this->_pageIconId = $icon_id;
$this->_pageIconClass = $add_classes;
}
/**
* Get page icon
*/
private function _getIcon() {
$class = array("icon32");
if (!empty($this->_pageIconClass)) {
$class = array_merge($class, $this->_pageIconClass);
}
$id = ($this->_pageIconId ? $this->_pageIconId:"icon-options-general");
?>
<div class="<?php echo implode(" ", $class)?>" id="<?php echo $id ?>"><br></div>
<?php
}
/**
* Action: admin_enqueue_scripts
*/
public static function admin_enqueue_scripts() {
wp_enqueue_script("jquery");
}
/**
* Action: network_admin_edit_wps
*/
public static function network_admin_edit() {
if (isset($_POST['_wpnonce']) && isset($_GET['id']) && wp_verify_nonce($_POST['_wpnonce'], $_GET['id'].'-options')) {
$id = $_GET['id'];
if (isset(self::$RegisteredInputNames[$id]) && !empty(self::$RegisteredInputNames[$id])) {
foreach (self::$RegisteredInputNames[$id] AS $index) {
if (isset($_POST[$index])) {
update_site_option($index, $_POST[$index]);
}
}
}
}
$redirect_url = (isset($_POST['_wp_http_referer']) ? $_POST['_wp_http_referer']:network_admin_url());
$redirect_url = add_query_arg(array('settings-updated' => 'true'), $redirect_url);
wp_redirect($redirect_url);
die;
}
}
/**
* WPSettings Theme Page class
* @see WPSettingsPage
*/
class WPSettingsThemePage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Theme section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add theme page
add_theme_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Dashboard Page class
* @see WPSettingsPage
*/
class WPSettingsDashboardPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Dashboard section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add dashboard page
add_dashboard_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Posts Page class
* @see WPSettingsPage
*/
class WPSettingsPostsPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Posts section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add posts page
add_posts_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Media Page class
* @see WPSettingsPage
*/
class WPSettingsMediaPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Media section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add media page
add_media_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Links Page class
* @see WPSettingsPage
*/
class WPSettingsLinksPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Links section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add links page
add_links_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Pages Page class
* @see WPSettingsPage
*/
class WPSettingsPagesPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Pages section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add pages page
add_pages_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Comments Page class
* @see WPSettingsPage
*/
class WPSettingsCommentsPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Comments section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add comments page
add_comments_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Plugins Page class
* @see WPSettingsPage
*/
class WPSettingsPluginsPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Plugins section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add plugins page
add_plugins_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Users Page class
* @see WPSettingsPage
*/
class WPSettingsUsersPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Users section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add users page
add_users_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Management Page class
* @see WPSettingsPage
*/
class WPSettingsManagementPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Page in the Management section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add management page
add_management_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WPSettings Options Page class
* @see WPSettingsPage
*/
class WPSettingsOptionsPage extends WPSettingsPage {
public $IsStandalonePage = false;
/**
* Create a WP Settings Options in the Management section
* @todo Allow both menu page and options page?
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array $function
* @param string $icon_url Optional
* @param int|null $position Optional
* @return WPSettingsPage
*/
public function __construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
// Call parent constructor to setup everything
parent::__construct($page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function, null, null);
// Add options page
add_options_page($page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WP Settings Sub Page class
* @see WPSettingsPage
*/
class WPSettingsSubPage extends WPSettingsPage {
public $Id;
protected $Title;
protected $Subtitle;
protected $MenuSlug;
/**
* Create a WP Settings Sub Page
* @todo Allow both menu page and options page?
* @param WPSettingsPage $WPSettingsPage
* @param string $page_title
* @param string $page_subtitle
* @param string $menu_title
* @param string $capability
* @param string $menu_slug
* @param string|array|bool $function
* @return WPSettingsPage
*/
public function __construct(WPSettingsPage &$WPSettingsPage, $page_title, $page_subtitle, $menu_title, $capability, $menu_slug, $function) {
$this->Id = $menu_slug;
$this->Title = $page_title;
$this->Subtitle = $page_subtitle;
$this->MenuSlug = $menu_slug;
add_submenu_page($WPSettingsPage->MenuSlug, $page_title, $menu_title, $capability, $menu_slug, $function);
return $this;
}
}
/**
* WP Settings Section class
* @see WPSettings
*/
class WPSettingsSection extends WPSettings {
public $Id;
public $SectionId;
protected $Headline;
protected $Description;
protected $Fields = array();
/**
* Create a WP Settings Section (called by WPSettingsPage->addSettingsSection()
* @see WPSettingsPage->addSettingsSection
* @param WPSettingsPage $WPSettingsPage
* @param string $section_id
* @param string $headline
* @param string $description Optional
* @return WPSettingsSection
*/
function __construct(WPSettingsPage &$WPSettingsPage, $section_id, $headline, $description='') {
$this->Id = $WPSettingsPage->Id;
$this->SectionId = $this->Id."_".$section_id;
$this->Headline = $headline;
$this->Description = $description;
add_settings_section($this->SectionId,
$this->Headline,
array($this, 'outputDescription'),
$this->Id
);
return $this;
}
/**
* Output description
*/
public function outputDescription() {
if ($this->Description) {
?><p><?php echo $this->Description ?></p><?php
}
}
/**
* Add a WP Settings Field
* @param string $field_id
* @param string $headline
* @param string|array $input_name
* @param string|array $current_value
* @param string|array $help_text
* @param string|array $placeholder
* @param string|array $description
* @param array $attributes
* @param array $style
* @return WPSettingsField
* @throws Exception
*/
public function addField($field_id, $headline, $type, $input_name, $current_value='', $help_text='', $placeholder='', $description='', $attributes=array(), $style=array()) {
// Validate id
if (!preg_match("/^[a-z0-9\-\_]{1,50}$/i", $field_id)) {
throw new \Exception("Section id failed to validate");
}
// Make sure field name is unique
if (in_array($input_name, self::$_input_names)) {
throw new \Exception("Input name is not unique.");
}
// Store input name to make sure they are unique
self::$_input_names[] = $input_name;
// Create dropdown
if ($type == "dropdown") {
$field = new WPSettingsFieldDropDown($this, $field_id, $headline, $type, $input_name, $current_value, $help_text, $placeholder, $description, $attributes, $style);
}
// Create a radio
elseIf ($type == "radio") {
$field = new WPSettingsFieldRadio($this, $field_id, $headline, $type, $input_name, $current_value, $help_text, $placeholder, $description, $attributes, $style);
}
// Create textarea
elseIf ($type == "textarea") {
$field = new WPSettingsFieldTextArea($this, $field_id, $headline, $type, $input_name, $current_value, $help_text, $placeholder, $description, $attributes, $style);
}
// Create WYSIWYG
elseIf ($type == "wysiwyg") {
$field = new WPSettingsFieldWYSIWYG($this, $field_id, $headline, $type, $input_name, $current_value, $help_text, $placeholder, $description, $attributes, $style);
}
// Create any other type
else {
$field = new WPSettingsField($this, $field_id, $headline, $type, $input_name, $current_value, $help_text, $placeholder, $description, $attributes, $style);
}
$this->Fields[] = &$field;
return $field;
}
}
/**
* WP Settings Field class
* @see WPSettingsSection
*/
class WPSettingsField extends WPSettingsSection {
public $Id;
public $SectionId;
public $FieldId;
protected $Headline;
protected $Type;
protected $InputName;
protected $CurrentValue;
protected $HelpText;
protected $Placeholder;
protected $Description;
protected $Events = array();
protected $Attributes;
protected $Style;
const FILTER_UPDATE = "upd";
private $_filterParameters = array(
'upd' => 2
);
/**
* Creates a WP Settings Field (called by WPSettingsSection->addField).
* Possible values for $type is:
* - text (regular text field)
* @see WPSettingsSection->addField
* @param WPSettingsSection $WPSettingsSection
* @param string $field_id
* @param string $headline
* @param string $type
* @param string|array $input_name
* @param string[array $current_value
* @param string|array $help_text
* @param string|array $placeholder
* @param string|array $description
* @param array $attributes
* @param array $style
* @return WPSettingsField
*/
function __construct(WPSettingsSection &$WPSettingsSection, $field_id, $headline, $type, $input_name, $current_value='', $help_text='', $placeholder='', $description='', $attributes='', $style='') {
$this->Id = $WPSettingsSection->Id;
$this->SectionId = $WPSettingsSection->SectionId;
$this->FieldId = $this->SectionId."_".$field_id;
$this->Headline = $headline;
$this->Type = $type;
// Always store them as array, multiple elements can be added foreach field
$this->InputName = (is_array($input_name) ? $input_name:array($input_name));
$this->setCurrentValue($current_value);
$this->setHelpText($help_text);
$this->setPlaceholder($placeholder);
$this->setDescription($description);
$this->setAttributes($attributes);
$this->setStyle($style);
add_settings_field($this->FieldId,
$this->Headline,
array($this, 'outputField'),
$this->Id,
$this->SectionId
);
return $this;
}
/**
* Output field (calls private functions by type)
*/
public function outputField() {
switch ($this->Type) {
// Drop down
case "dropdown":
$this->_outputDropDownField();
break;
// Radio
case "radio":
$this->_outputRadioField();
break;
// Checbox
case "checkbox":
$this->_outputCheckboxField();
break;
// Int
case "int":
$this->_outputTextField();
break;
// Hex color
case "hex_color":
$this->_outputHexColorField();
break;
// Textarea
case "textarea":
$this->_outputTextArea();
break;
// WYSIWYG
case "wysiwyg":
$this->_outputWYSIWYG();
break;
// URL
case "url":
// Regular text field
case "text":
default:
$this->_outputTextField();
break;
}
}
/**
* Add filter to this field
* @param int $event Must be one of the FILTER_ constants of this class
* @param string|array $callback A function to call on the event
* @param int $priority Forwarded into the add_filter() function
*/
public function addFilter($filter, $callback, $priority=10) {
// Make sure class and metod exists if array
if (is_array($callback)) {
if (is_string($callback[0]) && !class_exists($callback[0], true)) {
return false;
}
if (!method_exists($callback[0], $callback[1])) {
return false;
}
}
// Make sure function exists if string
if (is_string($callback)) {
if (!function_exists($callback)) {
return false;
}
}
// Add filter
add_filter('wps_'.$filter.'_'.$this->FieldId, $callback, $priority, $this->_filterParameters[$filter]);
}
/**
* Set current value
* @param string|array $placeholder
*/
public function setCurrentValue($current_value) {
$this->CurrentValue = (is_array($current_value) ? $current_value:array($current_value));
}
/**
* Set help text
* @param string|array $help_text
*/
public function setHelpText($help_text) {
$this->HelpText = (is_array($help_text) ? $help_text:array($help_text));
}
/**
* Set placeholder
* @param string|array $placeholder
*/
public function setPlaceholder($placeholder) {
$this->Placeholder = (is_array($placeholder) ? $placeholder:array($placeholder));
}
/**
* Set description
* @param string|array $description
*/
public function setDescription($description) {
$this->Description = (is_array($description) ? $description:array($description));
}
/**
* Set attributes - Should be an array of arrays. An array for each field, and an associative array for each attribute
* and it's value. For example: array( array( 'readonly' => 'readonly' ), array( 'maxlength' => 10 ) )
* @param array $attributes
*/
public function setAttributes($attributes) {
$this->Attributes = $attributes;
}
/**
* Add attribute
* @param string $name Attribute name
* @param string $value Attribute value
* @param int $index Optional. Set the index for which field the attribute should be added to
*/
public function addAttribute($name, $value, $index=0) {
$index = (int)$index;
if (!isset($this->Attributes[$index])) {
$this->Attributes[$index] = array();
}
$this->Attributes[$index][$name] = $value;
}
/**
* Set style - Should be an array of arrays. An array for each field, and an associative array for each attribute
* and it's value. For example: array( array( 'readonly' => 'readonly' ), array( 'maxlength' => 10 ) )
* @param array $style
*/
public function setStyle($style) {
$this->Style = $style;
}
/**
* Add style
* @param string $name Style name
* @param string $value Style value
* @param int $index Optional. Set the index for which field the style should be added to.
*/
public function addStyle($name, $value, $index=0) {
$index = (int)$index;
if (!isset($this->Style[$index])) {
$this->Style[$index] = array();
}
$this->Style[$index][$name] = $value;
}
/**
* Sanitize
* @param mixed $value
* @return $value Returnes sanitized value
*/
public function sanitize($value) {
// Sanitize by type
switch ($this->Type) {
case "checkbox":
$new_value = $this->_sanitizeCheckbox($value);
break;
case "int":
$new_value = $this->_sanitizeInt($value);
break;
case "url":
$new_value = $this->_sanitizeURL($value);
break;
case "hex_color":
$new_value = $this->_sanitizeHexColor($value);
break;
case "textarea":
case "wysiwyg":
case "dropdown":
case "radio":
case "text":
default:
$new_value = $this->_sanitizeText($value);
break;
}
// Do filter
if ( has_filter('wps_'.WPSettingsField::FILTER_UPDATE.'_'.$this->FieldId) ) {
$return_value = apply_filters('wps_'.WPSettingsField::FILTER_UPDATE.'_'.$this->FieldId, $this, $new_value);
if (!is_null($return_value)) {
$new_value = $return_value;
}
}
// Do update action
do_action('wps_before_update');
// Return
return $new_value;
}
/**
* Get attributes
* @param int $index
* @return string
*/
protected function getAttributes($index=0) {
if (isset($this->Attributes[$index]) && is_array($this->Attributes[$index]) && !empty($this->Attributes[$index])) {
$temp = array();
foreach ($this->Attributes[$index] AS $key => $value) {
$temp[] = $key."=\"".esc_attr($value)."\"";
}
return implode(" ", $temp);
}
}
/**
* Get style
* @param int $index
* @return string
*/
protected function getStyle($index=0) {
if (isset($this->Style[$index]) && is_array($this->Style[$index]) && !empty($this->Style[$index])) {
$temp = array();
foreach ($this->Style[$index] AS $key => $value) {
$temp[] = $key.": ".$value;
}
return "style=\"".implode("; ", $temp)."\"";
}
}
/**
* Sanitize plain text
* @param string $text
* @return string
*/
private function _sanitizeText($text) {
global $wpdb;
return $text;
}
/**
* Sanitize url
* @param string $text
* @return string
*/
private function _sanitizeURL($text) {
return esc_url($text);
}
/**
* Sanitize hex color
* @param string $text
*/
private function _sanitizeHexColor($text) {
$text = str_replace("#", "", $text);
if (preg_match('/^[a-f0-9]{6}$/i', $text)) {
return $text;
}
else {
return "";
}
}
/**
* Sanitize int
* @param mixed $text
* @return int
*/
private function _sanitizeInt($text) {
return (int)($text);
}
/**
* Sanitize checkbox
* @param mixed $checked
* @return int
*/
private function _sanitizeCheckbox($checked) {
return ($checked ? 1:0);
}
/**
* Output field - Type "text" (regular text field)
*/
private function _outputTextField() {
foreach ($this->InputName AS $index => $input_name) {
$width = 300;
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
$width -= 150;
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
$this->addStyle('width', $width.'px', $index);
?>
<div style="width: <?php echo $width ?>px; float: left;">
<input type="text" name="<?php echo esc_attr( $this->InputName[$index] ) ?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" value="<?php echo esc_attr( $this->CurrentValue[$index] ) ?>" <?php if ($this->Placeholder[$index]): ?>placeholder="<?php echo esc_attr($this->Placeholder[$index]) ?>"<?php endif; ?> <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output field - Type "textarea"
*/
private function _outputTextArea() {
foreach ($this->InputName AS $index => $input_name) {
$width = (int)($this->Width ? $this->Width:300);
$height = (int)($this->Height ? $this->Height:150);
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
$this->addStyle('width', $width.'px', $index);
$this->addStyle('height', $height.'px', $index);
?>
<div style="width: <?php echo $width ?>px; float: left;">
<textarea name="<?php echo esc_attr( $this->InputName[$index] ) ?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>><?php echo esc_html( $this->CurrentValue[$index] ) ?></textarea>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output field - Type "wysiwyg"
*/
private function _outputWYSIWYG() {
foreach ($this->InputName AS $index => $input_name) {
?>
<div id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>">
<?php wp_editor( stripslashes($this->CurrentValue[$index]), esc_attr( $this->InputName[$index] ), $this->Settings ) ?>
</div>
<?php
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
?>
<p><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></p>
<?php
}
$this->_outputDescription($index);
}
}
/**
* Output field - Type "hex_color"
*/
private function _outputHexColorField() {
foreach ($this->InputName AS $index => $input_name) {
$width = 60;
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
$this->addStyle('width', $width.'px', $index);
?>
<div style="width: 150px; float: left;">
# <input type="text" name="<?php echo esc_attr( $this->InputName[$index] ) ?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" value="<?php echo esc_attr( $this->CurrentValue[$index] ) ?>" <?php if ($this->Placeholder[$index]): ?> placeholder="<?php echo esc_attr($this->Placeholder[$index]) ?>"<?php endif; ?> <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output field - Type "checkbox"
*/
private function _outputCheckboxField() {
foreach ($this->InputName AS $index => $input_name) {
$width = 300;
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
$width -= 150;
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
?>
<div style="width: 150px; float: left;">
<script language="javascript" type="text/javascript">
jQuery(document).ready(function() {
jQuery('#cb_<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>').change(function() {
var value = (jQuery('#cb_<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>').is(':checked') ? 1:0);
jQuery('#<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>').val(value);
});
});
</script>
<input type="hidden" name="<?php echo esc_attr( $this->InputName[$index] ) ?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" value="<?php echo ($this->CurrentValue[$index] ? "1":"0") ?>" >
<input type="checkbox" name="cb_<?php echo esc_attr( $this->InputName[$index] ) ?>" id="cb_<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" value="1" <?php checked($this->CurrentValue[$index], 1) ?> <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output field - Type "dropdown"
*/
private function _outputDropDownField() {
foreach ($this->InputName AS $index => $input_name) {
$width = 300;
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
$width -= 150;
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
?>
<div style="float: left;">
<select name="<?php echo esc_attr( $this->InputName[$index] ) ?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index ) ?>" <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>>
<?php
// Loop options through option groups
if ($this->OptionGroups) {
// First get options with specifically no group (default value most likely)
$this->_outputDropDownOptions($index, false);
// Then loop through the option groups
foreach ($this->OptionGroups AS $optgroup_index => $optgroup) {
?>
<optgroup label="<?php echo esc_attr( $optgroup->Name )?>">
<?php
$this->_outputDropDownOptions($index, $optgroup);
?>
</optgroup>
<?php
}
}
// Loop all options without groups
else {
$this->_outputDropDownOptions($index);
}
?>
</select>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output dropdown options. All or for a specific option group. If $optgroup is null, all options will be
* shown. If it's false, only options without group will be shown. If it's set only options of that group
* will be shown.
* @param int $field_index The current fields index
* @param WPSettingsDropDownOptionGroup|null|false $optgroup Optional
*/
private function _outputDropDownOptions($field_index, $optgroup=null) {
foreach ($this->Options AS $option_index => $option) {
// Skip if
// Trying to get option group only (not null and not false)
// And this option isn't part of that option group
// Or this option has no option group at all
if ( !is_null($optgroup) && $optgroup !== false && ( (!is_null($option->OptionGroup) && $option->OptionGroup->Name !== $optgroup->Name) || (is_null($option->OptionGroup)) ) ) {
continue;
}
// Skip if
// Optgroup is set to false, and this option has a optgroup
if ($optgroup === false && !is_null($option->OptionGroup)) {
continue;
}
// Current value is an array, prob multisilect, do in_array check
if (is_array($this->CurrentValue[$field_index])) {
$checked = (in_array($option->Value, $this->CurrentValue[$field_index]) ? true:false);
}
else {
$checked = ($option->Value == $this->CurrentValue[$field_index] ? true:false);
}
?>
<option value="<?php echo esc_attr( $option->Value )?>" id="<?php echo esc_attr( $this->FieldId .'_'.$field_index.'_'.$option_index ) ?>" <?php selected($checked, true) ?>><?php echo esc_attr( $option->Name ) ?></option>
<?php
}
}
/**
* Output field - Type "radio"
*/
private function _outputRadioField() {
foreach ($this->InputName AS $index => $input_name) {
$width = 300;
if (isset($this->HelpText[$index]) && $this->HelpText[$index]) {
$width -= 150;
?>
<div style="width: 150px; float: left; padding-top: 2px;"><em><?php echo esc_html( $this->HelpText[$index] ) ?></em></div>
<?php
}
?>
<div style="width: 150px; float: left;">
<?php
foreach ($this->Options AS $option_index => $option) {
?>
<p>
<input type="radio" name="<?php echo esc_attr( $this->InputName[$index] ) ?>" value="<?php echo esc_attr( $option->Value )?>" id="<?php echo esc_attr( $this->FieldId .'_'.$index.'_'.$option_index ) ?>" <?php checked($this->CurrentValue[$index], $option->Value) ?> <?php echo $this->getStyle($index) ?> <?php echo $this->getAttributes($index) ?>>
<label for="<?php echo esc_attr( $this->FieldId .'_'.$index.'_'.$option_index ) ?>"><?php echo esc_attr( $option->Name ) ?></label>
</p>
<?php
}
?>
</div>
<div style="clear: both;"></div>
<?php
$this->_outputDescription($index);
}
}
/**
* Output descreiption for a specific field index
* @param int $field_index
*/
private function _outputDescription($field_index) {
if (isset($this->Description[$field_index]) && !empty($this->Description[$field_index])) {
?>
<p class="description"><?php echo $this->Description[$field_index]; ?></p>
<?php
}
}
}
/**
* WP Settings Field Drop Down class
* @see WPSettingsField
*/
class WPSettingsFieldDropDown extends WPSettingsField {
public $Options = array();
public $OptionGroups = array();
/**
* Add an option to the drop down
* @param string|int $value
* @param string $name Optional
* @param WPSettingsDropDownOptionGroup|null $optgroup Optional
* @return WPSettingsDropDownOption
*/
public function addOption($value, $name='', $optgroup=null) {
$name = ($name ? $name:$value);
$option = new WPSettingsDropDownOption($value, $name, $optgroup);
$this->Options[] = $option;
return $option;
}
/**
* Add an option group
* @param string $name
*/
public function addOptionGroup($name) {
$optgroup = new WPSettingsDropDownOptionGroup($name);
$this->OptionGroups[] = $optgroup;
return $optgroup;
}
}
/**
* WP Settings Field Drop Down Option class
* @see WPSettings
*/
class WPSettingsDropDownOption extends WPSettings {
protected $Value;
protected $Name;
protected $OptionGroup = null;
/**
* Creates a drop down option
* @param string|int $value
* @param string $name
* @param WPSettingsDropDownOptionGroup|null $optgroup Optional option group
* @return WPSettingsDropDownOption
*/
function __construct($value, $name, $optgroup=null) {
$this->Value = $value;
$this->Name = $name;
$this->OptionGroup = $optgroup;
return $this;
}
}
/**
* WP Settings Field Drop Down Option Group class
* @see WPSettings
*/
class WPSettingsDropDownOptionGroup extends WPSettings {
protected $Name;
/**
* Creates a drop down option group
* @param string|int $value
* @param string $name
* @return WPSettingsDropDownOptionGroup
*/
function __construct($name) {
$this->Name = $name;
return $this;
}
}
/**
* WP Settings Field Radio class
* @see WPSettingsField
*/
class WPSettingsFieldRadio extends WPSettingsField {
public $Options = array();
/**
* Add an option to the drop down
* @param string|int $value
* @param string $name Optional
* @return WPSettingsRadioOption
*/
public function addOption($value, $name='') {
$name = ($name ? $name:$value);
$option = new WPSettingsRadioOption($value, $name);
$this->Options[] = $option;
return $option;
}
}
/**
* WP Settings Field Radio Option class
* @see WPSettings
*/
class WPSettingsRadioOption extends WPSettings {
protected $Value;
protected $Name;
/**
* Creates a radio option
* @param string|int $value
* @param string $name
* @return WPSettingsRadioOption
*/
function __construct($value, $name) {
$this->Value = $value;
$this->Name = $name;
return $this;
}
}
/**
* WP Settings Field Text Area class
* @see WPSettingsField
*/
class WPSettingsFieldTextArea extends WPSettingsField {
public $Width;
public $Height;
/**
* Set size in pixels
* @param int $width
* @param int $height
*/
public function setSize($width, $height) {
$this->Width = $width;
$this->Height = $height;
}
}
/**
* WP Settings Field WYSIWYG class
* @see WPSettingsField
*/
class WPSettingsFieldWYSIWYG extends WPSettingsField {
public $Settings = array();
/**
* Set wp_editor $settings array
* @param array $settings
*/
public function setSettings($settings) {
$this->Settings = $settings;
}
} |
<?php
namespace App\Factory;
use App\Entity\People;
use App\Repository\PeopleRepository;
use Zenstruck\Foundry\RepositoryProxy;
use Zenstruck\Foundry\ModelFactory;
use Zenstruck\Foundry\Proxy;
/**
* @method static People|Proxy findOrCreate(array $attributes)
* @method static People|Proxy random()
* @method static People[]|Proxy[] randomSet(int $number)
* @method static People[]|Proxy[] randomRange(int $min, int $max)
* @method static PeopleRepository|RepositoryProxy repository()
* @method People|Proxy create($attributes = [])
* @method People[]|Proxy[] createMany(int $number, $attributes = [])
*/
final class PeopleFactory extends ModelFactory
{
public function __construct()
{
parent::__construct();
// TODO inject services if required (https://github.com/zenstruck/foundry#factories-as-services)
}
protected function getDefaults(): array
{
return [
'title' => self::faker()->title,
'first_name' => self::faker()->firstName,
'last_name' => self::faker()->lastName,
'age' => self::faker()->numberBetween(0, 122),
'email' => self::faker()->email,
'password' => self::faker()->password(6, 20),
];
}
protected function initialize(): self
{
// see https://github.com/zenstruck/foundry#initialization
return $this// ->afterInstantiate(function(People $people) {})
;
}
protected static function getClass(): string
{
return People::class;
}
}
|
<?php
declare(strict_types=1);
namespace YapepBase\Test\Unit\Storage;
use Mockery\MockInterface;
use YapepBase\Debug\DataHandlerRegistry;
use YapepBase\Debug\ICanReturnItems;
use YapepBase\Debug\Item\Storage;
use YapepBase\Helper\DateHelper;
abstract class TestAbstract extends \YapepBase\Test\Unit\TestAbstract
{
/** @var ICanReturnItems|MockInterface */
protected $debugDataHandler;
/** @var DateHelper|MockInterface */
protected $dateHelper;
/** @var float */
protected $debugStartedAt = 1.0;
/** @var float */
protected $debugFinishedAt = 2.0;
protected function setUp(): void
{
parent::setUp();
$this->dateHelper = \Mockery::mock(DateHelper::class);
}
protected function initDebugDataHandler()
{
$this->debugDataHandler = \Mockery::mock(ICanReturnItems::class);
$debugDataHandlerRegistry = new DataHandlerRegistry(new DateHelper());
$debugDataHandlerRegistry->register('first', $this->debugDataHandler);
$this->pimpleContainer->setDebugDataHandlerRegistry($debugDataHandlerRegistry);
}
protected function expectDebugTimesRetrieved()
{
$this->dateHelper
->shouldReceive('getCurrentTimestampUs')
->andReturn($this->debugStartedAt, $this->debugFinishedAt)
->getMock();
}
protected function expectAddStorageDebug(
string $method,
?string $key,
$data = null,
?float $startedAt = null,
?float $finishedAt = null
) {
$this->debugDataHandler
->shouldReceive('addStorage')
->once()
->with(\Mockery::on(function (Storage $item) use ($method, $key, $data, $startedAt, $finishedAt) {
return $item->getMethod() == $method
&& $item->getKey() == $key
&& $item->getData() == $data
&& $item->getStartTime() === $startedAt
&& $item->getFinishTime() === $finishedAt;
}));
}
}
|
<?php
namespace Backend\Controller;
use Zend\Mvc\Controller\AbstractActionController;
use Zend\View\Model\ViewModel;
use Zend\View\Model\JsonModel;
use Zend\Db\Sql\Expression;
use Mynamespace\SimpleImage;
class BankAccountController extends AbstractActionController
{
public function indexAction() {
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$loans = $application_model_bank_account_package->fetchAll(array("status" => array(0,1,2,3)));
return array("loans" => $loans);
}
public function addAction() {
$request = $this->getRequest();
if ($request->isPost()) {
$post = $request->getPost();
$messages = array();
$translator = $this->getServiceLocator()->get('translator');
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$loan = new \Application\Entity\BankAccountPackage;
$loan->setBankId($post['bank_id']);
$loan->setCategoryId($post['category_id']);
$loan->setLoanTitle($post['loan_title']);
if($post['promotions']) $loan->setPromotions($this->clearHtml($post['promotions']));
$loan->setLink($post['link']);
$loan->setTenor($post['tenor']);
$loan->setDateAdded(new Expression('NOW()'));
$loan->setIntRate($post['int_rate']);
$loan->setInitialDepositAmount($post['initial_deposit_amount']);
$loan->setMinimumBalance($post['minimum_balance']);
$loan->setChequeBookFees($post['cheque_book_fees']);
$loan->setInternetBankingFees($post['internet_banking_fees']);
$loan->setAnnualFee($post['annual_fee']);
$loan->setServiceFee($post['service_fee']);
$loan->setHighlight($post['highlight']);
$loan->setCitizenship($post['citizenship']);
$loan->setAge($post['age']);
$loan->setStatus($post['status']);
// Calculate
$interest_rate = $post['interest-rate'];
if(count($interest_rate) > 0) {
$loan_tenure = array();
foreach ($interest_rate as $key => $value) {
$tier = $value['tier'];
$percentage = $value['percentage'];
$loan_tenure[] = array(
'tier' => $tier,
'percentage' => $percentage
);
}
$loan->setInterestRate(\Zend\Json\Json::encode($loan_tenure));
}
$added = $application_model_bank_account_package->insert($loan);
if($added) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully added");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
$response = $this->getResponse();
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
}
public function editAction() {
$id = $this->params()->fromRoute('id');
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$loan = $application_model_bank_account_package->fetchRow(array('id' => $id));
if($loan) {
$translator = $this->getServiceLocator()->get('translator');
$request = $this->getRequest();
$response = $this->getResponse();
$messages = array();
if ($request->isPost()) {
$post = $request->getPost();
$error = 0;
if(!$error) {
$loan->setId($id);
$loan->setBankId($post['bank_id']);
$loan->setCategoryId($post['category_id']);
$loan->setLoanTitle($post['loan_title']);
if($post['promotions']) $loan->setPromotions($this->clearHtml($post['promotions']));
$loan->setLink($post['link']);
$loan->setTenor($post['tenor']);
$loan->setIntRate($post['int_rate']);
$loan->setInitialDepositAmount($post['initial_deposit_amount']);
$loan->setMinimumBalance($post['minimum_balance']);
$loan->setChequeBookFees($post['cheque_book_fees']);
$loan->setInternetBankingFees($post['internet_banking_fees']);
$loan->setAnnualFee($post['annual_fee']);
$loan->setServiceFee($post['service_fee']);
$loan->setHighlight($post['highlight']);
$loan->setCitizenship($post['citizenship']);
$loan->setAge($post['age']);
$loan->setDateModified(new Expression('NOW()'));
$loan->setStatus($post['status']);
// Calculate
$interest_rate = $post['interest-rate'];
if(count($interest_rate) > 0) {
$loan_tenure = array();
foreach ($interest_rate as $key => $value) {
$tier = $value['tier'];
$percentage = $value['percentage'];
$loan_tenure[] = array(
'tier' => $tier,
'percentage' => $percentage
);
}
$loan->setInterestRate(\Zend\Json\Json::encode($loan_tenure));
}
$edited = $application_model_bank_account_package->update($loan);
if($edited) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully updated");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
return array('loan' => $loan);
} else {
return $this->redirect()->toRoute("admin/view-business-loan");
}
}
public function faqAction() {
$application_model_faq = $this->getServiceLocator()->get('application_model_faq');
$faq = $application_model_faq->fetchRow(array('type' => 'bank_account'));
if($faq) {
$translator = $this->getServiceLocator()->get('translator');
$request = $this->getRequest();
$response = $this->getResponse();
$messages = array();
if ($request->isPost()) {
$id = $faq->getId();
$post = $request->getPost();
$error = 0;
if(!$error) {
$faq->setId($id);
$_faq = $post['faq'];
if(count($_faq) > 0) {
$loan_tenure = array();
foreach ($_faq as $key => $value) {
$question = $value['question'];
$answer = $value['answer'];
$loan_tenure[] = array(
'question' => $question,
'answer' => $answer
);
}
$faq->setQuestion(\Zend\Json\Json::encode($loan_tenure));
$faq->setAnswer(\Zend\Json\Json::encode($loan_tenure));
}
$edited = $application_model_faq->update($faq);
if($edited) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully updated");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
return array('faq' => $faq);
}
}
public function statusAction() {
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$action = $this->params()->fromPost('action');
switch ($action) {
case 'active':
$status = 1;
break;
case 'trash':
$status = 4;
break;
case 'deactive':
$status = 0;
break;
}
$ids = $this->params()->fromPost('ids');
$error = 0;
$result = array();
foreach ($ids as $id) {
$user = $application_model_bank_account_package->fetchRow(array('id' => $id));
$user->setId($id);
$user->setStatus($status);
$user->setDateModified(new Expression('NOW()'));
$updated = $application_model_bank_account_package->update($user);
if(!$updated) $error = $error + 1;
}
if(!$error) {
$result['success'] = true;
$result['msg'] = $translator->translate("Successfully updated");
} else {
$result['success'] = false;
$result['msg'] = $translator->translate("Something error. Please check");
}
}
return new JsonModel($result);
}
public function businessTermLoanAction() {
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$loans = $application_model_bank_account_package->fetchAll(array("type" => "business_term_loan"));
return array("loans" => $loans);
}
public function individualAction() {
$id = $this->params()->fromRoute('id');
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$loan = $application_model_bank_account_package->fetchRow(array('id' => $id));
return array('loan' => $loan);
}
public function setStatusAction() {
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_bank_account_package = $this->getServiceLocator()->get('application_model_bank_account_package');
$action = $this->params()->fromPost('action');
switch ($action) {
case 'approved':
$status = 1;
break;
case 'cancelled':
$status = 2;
break;
case 'rejected':
$status = 3;
break;
case 'pending':
$status = 0;
break;
}
$id = $this->params()->fromPost('id');
$credit = $this->params()->fromPost('credit');
$result = array();
$bank_account = $application_model_bank_account_package->fetchRow(array('id' => $id));
$bank_account->setId($id);
$bank_account->setStatus($status);
$bank_account->setDateModified(new Expression('NOW()'));
$updated = $application_model_bank_account_package->update($bank_account);
if($updated) {
if($action === 'approved') {
$application_model_referral = $this->getServiceLocator()->get('application_model_referral');
$referral = $application_model_referral->fetchRow(array("type" => "bank_account", "application" => $id));
if($referral && $referral->getStatus() == 0) {
$referral->setId($referral->getId());
$referral->setStatus($status);
if($credit > 0) $referral->setCredit($credit);
$referral->setDateAdded(new Expression('NOW()'));
$application_model_referral->update($referral);
}
}
$result['success'] = true;
$result['msg'] = $translator->translate("Successfully updated");
} else {
$result['success'] = false;
$result['msg'] = $translator->translate("Something error. Please check");
}
}
return new JsonModel($result);
}
/**
* Category
*/
public function categoryAction() {
$application_model_category = $this->getServiceLocator()->get('application_model_category');
//Load model menu
$application_model_menu = $this->getServiceLocator()->get('application_model_menu');
$response = $this->getResponse();
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$source = $this->params()->fromPost('source');
$destination = $this->params()->fromPost('destination', 0);
$category = $application_model_category->fetchRow(array('id' => $source));
$category->setId($source);
$category->setParentId($destination);
$application_model_category->update($category);
$ordering = \Zend\Json\Json::decode($this->params()->fromPost('order'));
$rootOrdering = \Zend\Json\Json::decode($this->params()->fromPost('rootOrder'));
if($ordering) {
foreach ($ordering as $order => $item_id) {
$order = $order + 1;
$itemToOrder = $application_model_category->fetchRow(array('id' => $item_id));
if($itemToOrder) {
$itemToOrder->setId($item_id);
$itemToOrder->setSortOrder($order);
$application_model_category->update($itemToOrder);
}
}
} else {
foreach($rootOrdering as $order => $item_id){
$itemToOrder = $application_model_category->fetchRow(array('id' => $item_id));
//Get name
$nameMenu=$itemToOrder->getName();
$itemToOrderMenu=$application_model_menu->fetchRow(array('name'=>$nameMenu));
if($itemToOrder){
$itemToOrder->setId($item_id);
$itemToOrder->setSortOrder($order);
$application_model_category->update($itemToOrder);
//Update sort order in table menu
$cond=array('name'=>$nameMenu);
$itemToOrderMenu->setSortOrder($order);
$application_model_menu->update($itemToOrderMenu,$cond);
}
}
}
return $response->setContent ( \Zend\Json\Json::encode ( array("success" => true, "msg" => $translator->translate("Successfully update")) ) );
}
$categories = $application_model_category->fetchAllOrder(array("type" => "bank_account"))->toArray();
$category_html = $this->buildCategory($categories);
return array("category_html" => $category_html);
}
public function buildCategory($categories, $id_parent = 0) {
$html = "";
$translator = $this->getServiceLocator()->get('translator');
$category_tmp = array();
$categories = $categories;
foreach ($categories as $key => $item) {
if ((int) $item['parent_id'] == (int) $id_parent) {
$category_tmp[] = $item;
unset($categories[$key]);
}
}
if ($category_tmp)
{
$html .= '<ol class="dd-list" id="accordion">';
foreach ($category_tmp as $item)
{
$id = $item['id'];
$label = $item['name'];
$sort_order = $item['sort_order'];
$html .= "<li class='dd-item nested-list-item panel' style='border: 0;' data-order='{$sort_order}' data-id='{$id}'>";
$html .= "<div class='dd-handle nested-list-handle'><span class='glyphicon glyphicon-move'></span></div>";
$html .= "<div class='nested-list-content'>{$label}<div class='pull-right'><a href='#collapse_{$id}' class='accordion-toggle accordion-toggle-styled collapsed' data-toggle='collapse' data-parent='#accordion'><i class='fa fa-edit'></i></a></div></div>";
$html .= "<div id='collapse_{$id}' class='panel-collapse collapse'>";
$html .= "<div class='panel-body'>";
$html .= "<div class='row'><div class='col-md-12'><label class='control-label'>Navigation Label</label>";
$html .= "<input type='text' class='form-control' name='label_title' value='{$label}'></div></div>";
$html .= "<div class='row' style='margin-top: 15px;'><div class='col-md-6 text-left'><button type='button' class='btn red-thunderbird ladda-button' onclick='edit_category(this, {$id})' data-style='expand-left'><i class='fa fa-check'></i> ".$translator->translate("Update")."</button></div><div class='col-md-6 text-right'><button type='button' class='btn purple ladda-button' onclick='remove_category(this, {$id})' data-style='expand-left'><i class='fa fa-trash'></i> ".$translator->translate("Remove")."</button></div></div>";
$html .= "</div></div>";
$html .= $this->buildCategory($categories, $id);
$html .= "</li>";
}
$html .= '</ol>';
}
return $html;
}
public function createCategoryAction() {
$messages = array();
$response = $this->getResponse();
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_category_group = $this->getServiceLocator()->get('application_model_category_group');
$name = $this->params()->fromPost('name');
$category_group = $application_model_category_group->fetchRow(array('name' => $name));
if($category_group) {
$messages['success'] = false;
$messages['msg'] = $translator->translate("The category name $name conflicts with another category name. Please try another");
} else {
$category_group = new \Application\Entity\CategoryGroup;
$category_group->setName($name);
$category_group->setIsDefault(0);
$category_group->setSortOrder(2);
$category_group->setDateModified(new Expression('NOW()'));
$category_group->setStatus(1);
$added = $application_model_category_group->insert($category_group);
if($added) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully added");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
public function addCategoryAction() {
$messages = array();
$response = $this->getResponse();
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_category = $this->getServiceLocator()->get('application_model_category');
$name = $this->params()->fromPost('name');
$category = new \Application\Entity\Category;
$category->setName($name);
$category->setSeo($this->makeSeo($name));
$category->setSortOrder(0);
$category->setType("bank_account");
$category->setDateAdded(new Expression('NOW()'));
$category->setParentId(0);
$category->setStatus(1);
$added = $application_model_category->insert($category);
//Get parent_id
$application_model_menu = $this->getServiceLocator()->get('application_model_menu');
$parentMenu=$application_model_menu->fetchRow(array('action'=>'bank-account','parent'=>0));
$id_parentMenu=$parentMenu->getId();
//Insert table menu
$menu = new \Application\Entity\Menu;
$menu->setGroupId(1);
$menu->setTitle($name);
$menu->setParent($id_parentMenu);
$menu->setName($name);
$menu->setRoute("loan_application");
$menu->setAction("bank-account");
$menu->setValue($this->makeSeo($name));
$menu->setSortOrder(0);
$menu->setDateAdded(new Expression('NOW()'));
$menu->setDateModified(NULL);
$added = $application_model_menu->insert($menu);
if($added) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully added");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
public function editCategoryAction() {
$messages = array();
$response = $this->getResponse();
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_category = $this->getServiceLocator()->get('application_model_category');
$category_id = $this->params()->fromPost('category_id');
$category_name = $this->params()->fromPost('category_name');
$category = $application_model_category->fetchRow(array('id' => $category_id));
if($category) {
$category->setId($category_id);
$category->setName($category_name);
$category->setSeo($this->makeSeo($category_name));
$category->setDateModified(new Expression('NOW()'));
$updated = $application_model_category->update($category);
if($updated) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully updated");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
} else {
$messages['success'] = false;
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
public function removeCategoryAction() {
$messages = array();
$response = $this->getResponse();
$request = $this->getRequest();
if ($request->isPost()) {
$translator = $this->getServiceLocator()->get('translator');
$application_model_category = $this->getServiceLocator()->get('application_model_category');
$category_id = $this->params()->fromPost('category_id');
$deleted = $application_model_category->delete(array('id' => $category_id));
if($deleted) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully removed");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
function clearHtml($html) {
$html = preg_replace("/<([a-z][a-z0-9]*)[^>]*?(\/?)>/i",'<$1$2>', $html);
$html = preg_replace("/<div>(.*?)<\/div>/", "$1", $html);
return $html;
}
function makeSeo($text, $limit=75)
{
// replace non letter or digits by -
$text = preg_replace('~[^\\pL\d]+~u', '-', $text);
// trim
$text = trim($text, '-');
// lowercase
$text = strtolower($text);
// remove unwanted characters
$text = preg_replace('~[^-\w]+~', '', $text);
if(strlen($text) > 70) {
$text = substr($text, 0, 70);
}
if (empty($text))
{
//return 'n-a';
return time();
}
return $text;
}
public function interestRateAction()
{
$application_model_bank_interest_rate = $this->getServiceLocator()->get('application_model_bank_interest_rate');
$loans = $application_model_bank_interest_rate->fetchAllSort();
return array("loans" => $loans);
}
public function AddinterestRateAction()
{
$request = $this->getRequest();
if ($request->isPost()) {
$post = $request->getPost();
$messages = array();
$translator = $this->getServiceLocator()->get('translator');
$application_model_bank_interest_rate= $this->getServiceLocator()->get('application_model_bank_interest_rate');
$loan = new \Application\Entity\BankInterestRate;
$loan->setBankId($post['bank_id']);
$loan->setName($post['name']);
$loan->setRate($post['rate']);
$loan->setType($post['type']);
$loan->setSort($post['sort']);
$loan->setStatus(1);
$added = $application_model_bank_interest_rate->insert($loan);
if($added) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully added");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
$response = $this->getResponse();
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
}
public function EditinterestRateAction()
{
$id = $this->params()->fromRoute('id');
$application_model_bank_interest_rate = $this->getServiceLocator()->get('application_model_bank_interest_rate');
$loan = $application_model_bank_interest_rate->fetchRow(array('id' => $id));
if($loan) {
$translator = $this->getServiceLocator()->get('translator');
$request = $this->getRequest();
$response = $this->getResponse();
$messages = array();
if ($request->isPost()) {
$post = $request->getPost();
$error = 0;
if(!$error) {
$loan->setBankId($post['bank_id']);
$loan->setName($post['name']);
$loan->setRate($post['rate']);
$loan->setType($post['type']);
$loan->setSort($post['sort']);
$loan->setStatus($post['status']);
$edited = $application_model_bank_interest_rate->update($loan);
if($edited) {
$messages['success'] = true;
$messages['msg'] = $translator->translate("Successfully updated");
} else {
$messages['success'] = false;
$messages['msg'] = $translator->translate("Something error. Please check");
}
}
$response->setContent ( \Zend\Json\Json::encode ( $messages ) );
return $response;
}
return array('loan' => $loan);
} else {
return $this->redirect()->toRoute("admin/view-business-loan");
}
}
} |
<?php
return[
"login" => "Please sign in",
"password" => "Password",
"btnlogin" => "Sign in",
"menuhome" => "Home",
"menucompany" => "Companies",
"menuemployee" => "Employees",
"logout" => "Logout",
"indexh1" => "Home Page",
"companyh1" => "Companie List",
"companyadd" => "Add to new companie",
"companyname" => "Companie Name",
"companywebsite" => "Website address",
"companybtnedit" => "Update",
"companybtndelete" => "Delete",
"companywork" => "Works",
"dtafter" => "Next",
"dtbefore" => "Previous",
"dtempyt" => "No data available in table",
"dtprocessing" => "Loading Data...",
"dtdatashow" => "Data from",
"dtdatashowlength" => "the data between are displayed",
"dtfiltered" => "found in the data",
"dtpage" => "Display",
"dtlengthmenu" => "records per page",
"dtloading" => "Loading...",
"dtsearch" => "Search:",
"dtrecords" => "No data available in table",
//Company ADD page
"companyaddh3" => "Companies Addition Form",
"companyaddname" => "Companie Name",
"companyaddnameph" => "Entered Companie name...",
"companyaddemail" => "Email address of the company",
"companyaddemailph" => "Enter the company's email address...",
"companyaddfile" => "Select the company logo",
"companyaddfileph" => "Select the company logo",
"companyaddwebsite" => "Company Website address",
"companyaddwebsiteph" => "Enter the company's Website address...",
"companyaddbtn" => "Add new Companie",
//Comapany Edit Page
"companyedith3" => "Company Data Update Form",
"companyeditname" => "Companie Name",
"companyeditemail" => "Email address of the company",
"companyeditfile" => "Current Company Logo",
"companyeditfileph" => "Choos a new logo",
"companyeditwebsite" => "Company Website address",
"companyeditbtn" => "Update",
//Employee Page
"employeeh3" => "List of Employee",
"employeebtnadd" => "Add new Employee",
"employeefname" => "First Name",
"employeelname" => "Last Name",
"employeecname" => "Companie Name",
"employeephone" => "Phone",
"employeework" => "Works",
"employeeupdate" => "Update",
"employeedelete" => "Delete",
//Employee Add Page
"employeeaddh3" => "Employee Addition Form",
"employeeaddfname" => "Employee's First Name",
"employeeaddfnameph" => "Enter the employee's first name ...",
"employeeaddlname" => "Employee's Last Name",
"employeeaddlnameph" => "Enter the employee's last name ...",
"employeeaddcname" => "Company Name",
"employeeaddcnameph" => "Choose a company name ...",
"employeeaddemail" => "Employee's email address",
"employeeaddemailph" => "Enter the Employee's Email address",
"employeeaddphone" => "Employee Contact Number",
"employeeaddphoneph" => "Enter the Employee Contact Number ...",
"employeeaddphonesm" => "Example:",
"employeeaddbtn" => "Add new employee",
//Employee Edit Page
"employeeupdateh3" => "Employee's Data Update Form",
"employeeupdatefname" => "Employee's First Name",
"employeeupdatelname" => "Employee's Last Name",
"employeeupdatecname" => "Companie Name",
"employeeupdatecnameph" => "Choose a company name ...",
"employeeupdateemail" => "Employee's email address",
"employeeupdatephone" => "Employee's contanct phone",
"employeeupdatephonesm" => "Example:",
"employeeupdatebtn" => "Update",
];
?> |
<?php
/*-----------------------------------------------------------------------------------*/
/* Button Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['button'] = array(
'no_preview' => true,
'params' => array(
'url' => array(
'std' => '',
'type' => 'text',
'label' => __('Button URL', 'gwtheme'),
'desc' => __('Add the button\'s url eg http://example.com', 'gwtheme')
),
'style' => array(
'type' => 'select',
'label' => __('Button Style', 'gwtheme'),
'desc' => __('Select the button\'s style, ie the button\'s colour', 'gwtheme'),
'options' => array(
'grey' => 'Grey',
'black' => 'Black',
'green' => 'Green',
'light-blue' => 'Light Blue',
'blue' => 'Blue',
'red' => 'Red',
'orange' => 'Orange',
'purple' => 'Purple'
)
),
'size' => array(
'type' => 'select',
'label' => __('Button Size', 'gwtheme'),
'desc' => __('Select the button\'s size', 'gwtheme'),
'options' => array(
'small' => 'Small',
'medium' => 'Medium',
'large' => 'Large'
)
),
'type' => array(
'type' => 'select',
'label' => __('Button Type', 'gwtheme'),
'desc' => __('Select the button\'s type', 'gwtheme'),
'options' => array(
'round' => 'Round',
'square' => 'Square'
)
),
'target' => array(
'type' => 'select',
'label' => __('Button Target', 'gwtheme'),
'desc' => __('_self = open in same window. _blank = open in new window', 'gwtheme'),
'options' => array(
'_self' => '_self',
'_blank' => '_blank'
)
),
'content' => array(
'std' => 'Button Text',
'type' => 'text',
'label' => __('Button\'s Text', 'gwtheme'),
'desc' => __('Add the button\'s text', 'gwtheme'),
)
),
'shortcode' => '[gw_button url="{{url}}" style="{{style}}" size="{{size}}" type="{{type}}" target="{{target}}"] {{content}} [/gw_button]',
'popup_title' => __('Insert Button Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* gwrt Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['gwrt'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('gwrt Style', 'gwtheme'),
'desc' => __('Select the gwrt\'s style, ie the gwrt colour', 'gwtheme'),
'options' => array(
'white' => 'White',
'grey' => 'Grey',
'red' => 'Red',
'yellow' => 'Yellow',
'green' => 'Green'
)
),
'content' => array(
'std' => 'Your gwrt!',
'type' => 'textarea',
'label' => __('gwrt Text', 'gwtheme'),
'desc' => __('Add the gwrt\'s text', 'gwtheme'),
)
),
'shortcode' => '[gw_gwrt style="{{style}}"] {{content}} [/gw_gwrt]',
'popup_title' => __('Insert gwrt Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Toggle Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['toggle'] = array(
'no_preview' => true,
'params' => array(
'title' => array(
'type' => 'text',
'label' => __('Toggle Content Title', 'gwtheme'),
'desc' => __('Add the title that will go above the toggle content', 'gwtheme'),
'std' => 'Title'
),
'content' => array(
'std' => 'Content',
'type' => 'textarea',
'label' => __('Toggle Content', 'gwtheme'),
'desc' => __('Add the toggle content. Will accept HTML', 'gwtheme'),
),
'state' => array(
'type' => 'select',
'label' => __('Toggle State', 'gwtheme'),
'desc' => __('Select the state of the toggle on page load', 'gwtheme'),
'options' => array(
'open' => 'Open',
'closed' => 'Closed'
)
),
),
'shortcode' => '[gw_toggle title="{{title}}" state="{{state}}"] {{content}} [/gw_toggle]',
'popup_title' => __('Insert Toggle Content Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Tabs Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['tabs'] = array(
'params' => array(),
'no_preview' => true,
'shortcode' => '[gw_tabs] {{child_shortcode}} [/gw_tabs]',
'popup_title' => __('Insert Tab Shortcode', 'gwtheme'),
'child_shortcode' => array(
'params' => array(
'title' => array(
'std' => 'Title',
'type' => 'text',
'label' => __('Tab Title', 'gwtheme'),
'desc' => __('Title of the tab', 'gwtheme'),
),
'content' => array(
'std' => 'Tab Content',
'type' => 'textarea',
'label' => __('Tab Content', 'gwtheme'),
'desc' => __('Add the tabs content', 'gwtheme')
)
),
'shortcode' => '[gw_tab title="{{title}}"] {{content}} [/gw_tab]',
'clone_button' => __('Add Tab', 'gwtheme')
)
);
/*-----------------------------------------------------------------------------------*/
/* Columns Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['columns'] = array(
'params' => array(),
'shortcode' => ' {{child_shortcode}} ', // as there is no wrapper shortcode
'popup_title' => __('Insert Columns Shortcode', 'gwtheme'),
'no_preview' => true,
// child shortcode is clonable & sortable
'child_shortcode' => array(
'params' => array(
'column' => array(
'type' => 'select',
'label' => __('Column Type', 'gwtheme'),
'desc' => __('Select the type, ie width of the column.', 'gwtheme'),
'options' => array(
'gw_two_third' => 'Two Pictures'
/*'gw_one_third_last' => 'One Third Last',
'gw_two_third' => 'Two Thirds',
'gw_two_third_last' => 'Two Thirds Last',
'gw_one_half' => 'One Half',
'gw_one_half_last' => 'One Half Last',
'gw_one_fourth' => 'One Fourth',
'gw_one_fourth_last' => 'One Fourth Last',
'gw_three_fourth' => 'Three Fourth',
'gw_three_fourth_last' => 'Three Fourth Last',
'gw_one_fifth' => 'One Fifth',
'gw_one_fifth_last' => 'One Fifth Last',
'gw_two_fifth' => 'Two Fifth',
'gw_two_fifth_last' => 'Two Fifth Last',
'gw_three_fifth' => 'Three Fifth',
'gw_three_fifth_last' => 'Three Fifth Last',
'gw_four_fifth' => 'Four Fifth',
'gw_four_fifth_last' => 'Four Fifth Last',
'gw_one_sixth' => 'One Sixth',
'gw_one_sixth_last' => 'One Sixth Last',
'gw_five_sixth' => 'Five Sixth',
'gw_five_sixth_last' => 'Five Sixth Last'*/
)
),
'content' => array(
'std' => '',
'type' => 'textarea',
'label' => __('Column Content', 'gwtheme'),
'desc' => __('Add the column content.', 'gwtheme'),
)
),
'shortcode' => '[{{column}}] {{content}} [/{{column}}] ',
'clone_button' => __('Add Column', 'gwtheme')
)
);
/*-----------------------------------------------------------------------------------*/
/* Divider Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['divider'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('Divider Style', 'gwtheme'),
'desc' => __('Select the divider\'s style', 'gwtheme'),
'options' => array(
'bold' => 'Bold Line',
'thin' => 'Thin Line',
'medium' => 'Medium Line',
'dashed' => 'Dashed Line',
'dark' => 'Dark Line',
'light' => 'Light Line'
)
),
'text' => array(
'type' => 'select',
'label' => __('Divider Text', 'gwtheme'),
'desc' => __('Select the divider\'s text option', 'gwtheme'),
'options' => array(
'notext' => 'No Text',
'textleft' => 'Text Left',
'textright' => 'Text Right',
'textcenter' => 'Text Center'
)
),
'content' => array(
'std' => 'Divider Text',
'type' => 'text',
'label' => __('Divider Text', 'gwtheme'),
'desc' => __('Add the divider\'s text', 'gwtheme'),
)
),
'shortcode' => '[gw_divider style="{{style}}" text="{{text}}"] {{content}} [/gw_divider]',
'popup_title' => __('Insert Divider Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Testimonial Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['testimonial'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('Testimonial Style', 'gwtheme'),
'desc' => __('Select the testimonial\'s style', 'gwtheme'),
'options' => array(
'dark' => 'Dark Style',
'light' => 'Light Style'
)
),
'avatar' => array(
'std' => '',
'type' => 'text',
'label' => __('Testimonial Author photo link', 'gwtheme'),
'desc' => __('Add the testimonial\'s author photo link.', 'gwtheme'),
),
'name' => array(
'std' => 'Testimonial Author',
'type' => 'text',
'label' => __('Testimonial Author', 'gwtheme'),
'desc' => __('Add the testimonial\'s author', 'gwtheme'),
),
'link' => array(
'std' => '',
'type' => 'text',
'label' => __('Testimonial Link', 'gwtheme'),
'desc' => __('Add the testimonial\'s link', 'gwtheme'),
),
'content' => array(
'std' => 'Testimonial Text',
'type' => 'textarea',
'label' => __('Testimonial Text', 'gwtheme'),
'desc' => __('Add the testimonial\'s text', 'gwtheme'),
)
),
'shortcode' => '[gw_testimonial link="{{link}}" style="{{style}}" avatar="{{avatar}}" name="{{name}}"] {{content}} [/gw_testimonial]',
'popup_title' => __('Insert Testimonial Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Team Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['team'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('Team box Style', 'gwtheme'),
'desc' => __('Select the team box\'s style', 'gwtheme'),
'options' => array(
'dark' => 'Dark Style',
'light' => 'Light Style'
)
),
'avatar' => array(
'std' => '',
'type' => 'text',
'label' => __('Team Author photo link', 'gwtheme'),
'desc' => __('Add the team\'s author photo link.', 'gwtheme'),
),
'name' => array(
'std' => '',
'type' => 'text',
'label' => __('Team Author', 'gwtheme'),
'desc' => __('Add the team\'s author', 'gwtheme'),
),
'prof' => array(
'std' => 'Designer',
'type' => 'text',
'label' => __('Team Prof', 'gwtheme'),
'desc' => __('Add the prof. team\'s author', 'gwtheme'),
),
'fblink' => array(
'std' => '',
'type' => 'text',
'label' => __('Facebook Link', 'gwtheme'),
'desc' => __('Add the facebook link', 'gwtheme'),
),
'twilink' => array(
'std' => '',
'type' => 'text',
'label' => __('Twitter Link', 'gwtheme'),
'desc' => __('Add the twitter link', 'gwtheme'),
),
'glink' => array(
'std' => '',
'type' => 'text',
'label' => __('Google+ Link', 'gwtheme'),
'desc' => __('Add the google+ link', 'gwtheme'),
),
'content' => array(
'std' => 'Testimonial Text',
'type' => 'textarea',
'label' => __('Testimonial Text', 'gwtheme'),
'desc' => __('Add the testimonial\'s text', 'gwtheme'),
)
),
'shortcode' => '[gw_team style="{{style}}" avatar="{{avatar}}" name="{{name}}" prof="{{prof}}" fblink="{{fblink}}" twilink="{{twilink}}" glink="{{glink}}"] {{content}} [/gw_team]',
'popup_title' => __('Insert Team Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Partner Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['partner'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('Partner box Style', 'gwtheme'),
'desc' => __('Select the partner box\'s style', 'gwtheme'),
'options' => array(
'dark' => 'Dark Style',
'light' => 'Light Style'
)
),
'logo' => array(
'std' => '',
'type' => 'text',
'label' => __('Partner logo link', 'gwtheme'),
'desc' => __('Add the partner\'s logo link.', 'gwtheme'),
),
'content' => array(
'std' => '',
'type' => 'text',
'label' => __('Partner Title', 'gwtheme'),
'desc' => __('Add the partner\'s title', 'gwtheme'),
),
'link' => array(
'std' => '',
'type' => 'text',
'label' => __('Partner Link', 'gwtheme'),
'desc' => __('Add the partner link', 'gwtheme'),
),
),
'shortcode' => '[gw_partner style="{{style}}" logo="{{logo}}" link="{{link}}"]{{content}}[/gw_partner]',
'popup_title' => __('Insert Partner Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Service Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['service'] = array(
'no_preview' => true,
'params' => array(
'style' => array(
'type' => 'select',
'label' => __('Partner box Style', 'gwtheme'),
'desc' => __('Select the partner box\'s style', 'gwtheme'),
'options' => array(
'dark' => 'Dark Style',
'light' => 'Light Style'
)
),
'icon' => array(
'std' => '',
'type' => 'text',
'label' => __('Service icon link', 'gwtheme'),
'desc' => __('Add the service\'s icon link.', 'gwtheme'),
),
'name' => array(
'std' => '',
'type' => 'text',
'label' => __('Service Title', 'gwtheme'),
'desc' => __('Add the service title', 'gwtheme'),
),
'content' => array(
'std' => '',
'type' => 'textarea',
'label' => __('Short Description', 'gwtheme'),
'desc' => __('Add the service\'s description', 'gwtheme'),
),
),
'shortcode' => '[gw_service style="{{style}}" icon="{{icon}}" name="{{name}}"]{{content}}[/gw_service]',
'popup_title' => __('Insert Service Shortcode', 'gwtheme')
);
/*-----------------------------------------------------------------------------------*/
/* Map Config
/*-----------------------------------------------------------------------------------*/
$gw_shortcodes['map'] = array(
'no_preview' => true,
'params' => array(
'address' => array(
'std' => 'Chisinau',
'type' => 'text',
'label' => __('Add the Address', 'gwtheme'),
'desc' => __('Add the address', 'gwtheme'),
),
'width' => array(
'std' => '100%',
'type' => 'text',
'label' => __('Map width', 'gwtheme'),
'desc' => __('Add the width', 'gwtheme'),
),
'height' => array(
'std' => '400px',
'type' => 'text',
'label' => __('Map height', 'gwtheme'),
'desc' => __('Add the map height', 'gwtheme'),
),
),
'shortcode' => '[gw_map address="{{address}}" width="{{width}}" height="{{height}}"]',
'popup_title' => __('Insert Map Shortcode', 'gwtheme')
);
?> |
<?php
namespace App;
use App\Models\Element;
use App\Models\ElementCollection;
use App\Models\Messages;
use App\Models\Player;
class Game
{
private ElementCollection $gameElements;
private Player $player;
private Element $computerChoice;
private Messages $message;
private array $gameCombination = [];
private array $winCombination = [
['rock', 'scissors'],
['scissors', 'paper'],
['paper', 'rock']
];
public function __construct()
{
$this->gameElements = new ElementCollection();
$this->gameElements->addElement(new Element('rock'));
$this->gameElements->addElement(new Element('paper'));
$this->gameElements->addElement(new Element('scissors'));
$this->player = new Player();
$this->message = new Messages();
}
public function getGameElements(): ElementCollection
{
return $this->gameElements;
}
public function makeComputerChoice(): void
{
$this->computerChoice = $this->getGameElements()->getRandom();
}
public function getGameCombination(): array
{
return $this->gameCombination;
}
public function getComputerChoice(): Element
{
return $this->computerChoice;
}
public function getWinCombination(): array
{
return $this->winCombination;
}
public function getPlayerChoice(): Element
{
return $this->player->getChoice();
}
public function checkResult(): string
{
if ($this->getPlayerChoice()->getName() === $this->getComputerChoice()->getName()) {
return $this->message->printTieMessage();
} elseif (in_array($this->getGameCombination(), $this->getWinCombination())) {
return $this->message->printPlayerWinMessage();
} else {
return $this->message->printComputerWinMessage();
}
}
public function play($playerChoice): void
{
foreach ($this->getGameElements()->getAll() as $element) {
if ($playerChoice === $element->getName()) {
$this->player->makeChoice($element);
}
}
$this->makeComputerChoice();
$this->gameCombination = [$this->getPlayerChoice()->getName(), $this->getComputerChoice()->getName()];
}
} |
<?php
/**
* Created by PhpStorm.
* User: mirza
* Date: 7/17/18
* Time: 12:56 PM
*/
namespace Model\Service;
use Exception;
use Model\Entity\ResponseBootstrap;
use Model\Mapper\NotificationMapper;
class NotificationService
{
private $notificationMapper;
private $configuration;
private $response;
public function __construct(NotificationMapper $notificationMapper)
{
$this->notificationMapper = $notificationMapper;
$this->configuration = $notificationMapper->getConfiguration();
$this->response = new ResponseBootstrap();
}
/**
* Send notification
*
* @param array $to
* @param array $message
* @param array $data
* @return ResponseBootstrap
*/
public function sendPushNotification(string $fcm, array $message, array $data):ResponseBootstrap {
try {
$serverKey = $this->configuration['server_key'];
$url = $this->configuration['fcm_url'];
// handle if android
if(strpos( $fcm, 'android' ) !== false){
$fcm = str_replace("android","",$fcm);
$fields = [
'registration_ids' => [$fcm],
'content_available' => true,
'mutable_content' => true,
//'notification' => $message,
'data' => $data,
'priority' => 'high'
];
}else{
$fields = [
'registration_ids' => [$fcm],
'content_available' => true,
'mutable_content' => true,
'notification' => $message,
'data' => $data,
'priority' => 'high'
];
}
$fields = json_encode ( $fields );
$headers = array (
'Authorization: key=' . $serverKey,
'Content-Type: application/json'
);
$ch = curl_init ();
curl_setopt ( $ch, CURLOPT_URL, $url );
curl_setopt ( $ch, CURLOPT_POST, true );
curl_setopt ( $ch, CURLOPT_HTTPHEADER, $headers );
curl_setopt ( $ch, CURLOPT_RETURNTRANSFER, true );
curl_setopt ( $ch, CURLOPT_POSTFIELDS, $fields );
$result = curl_exec ($ch);
curl_close ($ch);
$result = json_decode($result, true);
}catch (Exception $e){
die(print_r($e->getMessage()));
$result = [];
}
$this->response->setStatus(200);
$this->response->setMessage('Notification was sent');
$this->response->setData($result);
return $this->response;
}
} |
<?php
return [
'test-00101-11508' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.2000.38 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '36.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11509' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2086.75 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11510' => [
'ua' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2202.61 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11511' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2188.26 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11512' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2165.55 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '38.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.8',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11513' => [
'ua' => 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2167.5 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '38.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11514' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2237.89 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11515' => [
'ua' => 'Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2407.49 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11516' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2289.82 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11517' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1871.86 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '34.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11518' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2489.54 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.9.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11519' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1731.5 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11520' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2266.88 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11521' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2068.40 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11522' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2427.7 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11523' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2087.1 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.8',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11524' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2379.80 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '43.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11525' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2463.85 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11526' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2217.49 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11527' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2451.74 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11528' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2194.83 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.9.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11529' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2073.46 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11530' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2340.14 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11531' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2274.7 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11532' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.2061.16 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '36.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11533' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1762.69 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11534' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2291.68 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11535' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2138.0 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '38.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11536' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1876.68 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '34.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.9.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11537' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1705.85 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11538' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1721.50 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11539' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2299.81 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11540' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2467.25 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11541' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2381.95 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '43.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11542' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1725.36 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11543' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1753.87 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11544' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1842.36 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11545' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/34.0.1862.55 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '34.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11546' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1924.12 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11547' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2282.98 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11548' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1938.10 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11549' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1702.77 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11550' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2251.29 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11551' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2303.86 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11552' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2461.37 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11553' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2308.63 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11554' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2444.30 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11555' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1956.88 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11556' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2094.29 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11557' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.2; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1776.47 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11558' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2200.33 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11559' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2225.94 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.9.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11560' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2193.28 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11561' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1956.45 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11562' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2077.52 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11563' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2470.61 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11564' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2333.85 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11565' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1751.87 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11566' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2457.52 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '45.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11567' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2271.46 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '40.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11568' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2346.1 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11569' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1943.41 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11570' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2322.26 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11571' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/33.0.1756.58 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '33.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.9.5',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11572' => [
'ua' => 'Mozilla/5.0 (X11; Linux i686 on x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/32.0.1707.42 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '32.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11573' => [
'ua' => 'Mozilla/5.0 (Windows NT 5.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/41.0.2286.73 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '41.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11574' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2394.50 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '43.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11575' => [
'ua' => 'Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2082.22 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Linux',
'Platform_Marketingname' => 'Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Linux Foundation',
'Platform_Brand_Name' => 'Linux Foundation',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11576' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2112.83 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '37.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11577' => [
'ua' => 'Mozilla/5.0 (X11; Ubuntu; Linux i686) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2449.47 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Ubuntu',
'Platform_Marketingname' => 'Ubuntu',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Canonical Foundation',
'Platform_Brand_Name' => 'Canonical',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11578' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2339.40 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '42.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.10.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11579' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2439.26 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.11.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11580' => [
'ua' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_8) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2210.37 Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '39.0',
'Platform_Codename' => 'Mac OS X',
'Platform_Marketingname' => 'Mac OS X',
'Platform_Version' => '10.8.8',
'Platform_Bits' => 32,
'Platform_Maker' => 'Apple Inc',
'Platform_Brand_Name' => 'Apple',
'Device_Name' => 'Macintosh',
'Device_Maker' => 'Apple Inc',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Macintosh',
'Device_Brand_Name' => 'Apple',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11581' => [
'ua' => 'Mozilla/5.0 (Linux; Android 4.4.2; thl T6 pro Build/KOT49H) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.78 Mobile Safari/537.36 OPR/30.0.1856.95530',
'properties' => [
'Browser_Name' => 'Opera Mobile',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '30.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '4.4.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'unknown',
'Device_Maker' => 'unknown',
'Device_Type' => 'unknown',
'Device_Pointing_Method' => 'unknown',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'unknown',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11582' => [
'ua' => 'Mozilla/5.0 (Linux; Android 5.0.2; D6503 Build/23.1.A.0.690) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.95 Mobile Safari/537.36',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '48.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.0.2',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia Z2 LTE',
'Device_Maker' => 'Sony',
'Device_Type' => 'Mobile Phone',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'D6503',
'Device_Brand_Name' => 'Sony',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11583' => [
'ua' => 'Mozilla/5.0 (X11; Fedora; Linux i686; rv:44.0) Gecko/20100101 Firefox/44.0',
'properties' => [
'Browser_Name' => 'Firefox',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Mozilla Foundation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '44.0',
'Platform_Codename' => 'Fedora Linux',
'Platform_Marketingname' => 'Fedora Linux',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Red Hat Inc',
'Platform_Brand_Name' => 'Redhat',
'Device_Name' => 'Linux Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Linux Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Gecko',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Mozilla Foundation',
],
],
'test-00101-11584' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.82 Safari/537.36 OPR/35.0.2066.37,gzip(gfe)',
'properties' => [
'Browser_Name' => 'Opera',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Opera Software ASA',
'Browser_Modus' => 'unknown',
'Browser_Version' => '35.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11585' => [
'ua' => 'Dalvik/2.1.0 (Linux; U; Android 5.1.1; SGP521 Build/23.4.A.1.264)',
'properties' => [
'Browser_Name' => 'Dalvik',
'Browser_Type' => 'Application',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '0.0',
'Platform_Codename' => 'Android',
'Platform_Marketingname' => 'Android',
'Platform_Version' => '5.1.1',
'Platform_Bits' => 32,
'Platform_Maker' => 'Google Inc',
'Platform_Brand_Name' => 'Google',
'Device_Name' => 'Xperia Tablet Z2 LTE',
'Device_Maker' => 'Sony',
'Device_Type' => 'FonePad',
'Device_Pointing_Method' => 'touchscreen',
'Device_Dual_Orientation' => true,
'Device_Code_Name' => 'SGP521',
'Device_Brand_Name' => 'Sony',
'RenderingEngine_Name' => 'unknown',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'unknown',
],
],
'test-00101-11586' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; .NET4.0C; .NET4.0E; MS-RTC LM 8; InfoPath.3; Microsoft Outlook 15.0.4783; Microsoft Outlook 15.0.4783; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11587' => [
'ua' => 'Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2564.82 Safari/537.36 ASW/1.48.2066.44',
'properties' => [
'Browser_Name' => 'Chrome',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Google Inc',
'Browser_Modus' => 'unknown',
'Browser_Version' => '48.0',
'Platform_Codename' => 'Windows NT 6.3',
'Platform_Marketingname' => 'Windows 8.1',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Blink',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Google Inc',
],
],
'test-00101-11588' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; eSobiSubscriber 1.0.0.40; .NET4.0C; .NET4.0E; MAAR; GWX:QUALIFIED; Microsoft Outlook 14.0.7166; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11589' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; Win64; x64; Trident/7.0; .NET4.0C; .NET4.0E; InfoPath.3; Microsoft Outlook 15.0.4797; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11590' => [
'ua' => 'Outlook-Express/7.0 (MSIE 7.0; Windows NT 6.2; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; Tablet PC 2.0; anonymized by Abelssoft 929996704; TmstmpExt)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11591' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; Tablet PC 2.0; .NET CLR 1.1.4322; .NET4.0C; Zune 4.7; .NET4.0E; GWX:QUALIFIED; MALC; MSN OptimizedIE8;DEDE; Microsoft Outlook 14.0.7166; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11592' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; BTRS103944; GTB7.5; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 1.1.4322; .NET CLR 3.5.30729; .NET CLR 3.0.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET4.0E; BRI/2)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '8.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11593' => [
'ua' => 'Outlook-Express/7.0 (MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET CLR 1.1.4322; .NET4.0E; BRI/2; GWX:RESERVED; TmstmpExt)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11594' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; MALNJS)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11595' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; eSobiSubscriber 1.0.0.40; MAAR; .NET4.0C; .NET4.0E; tb-webde/2.6.6; Microsoft Outlook 15.0.4783; Microsoft Outlook 15.0.4783; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11596' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; (webde/1.0.0.8); MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11597' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; Win64; x64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; InfoPath.3; Microsoft Outlook 15.0.4797; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11598' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.0; Trident/5.0; SLCC1; .NET CLR 2.0.50727; Media Center PC 5.0; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET CLR 3.0.30729; BRI/2; InfoPath.3; .NET4.0E; Microsoft Outlook 14.0.7166; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.0',
'Platform_Marketingname' => 'Windows Vista',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11599' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; WWTClient2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 5.1',
'Platform_Marketingname' => 'Windows XP',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11600' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; GWX:DOWNLOADED; InfoPath.3; Microsoft Outlook 15.0.4605; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11601' => [
'ua' => 'Outlook-Express/7.0 (MSIE 7.0; Windows NT 6.2; WOW64; Trident/7.0; .NET4.0C; .NET4.0E; InfoPath.1; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; TmstmpExt)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.2',
'Platform_Marketingname' => 'Windows 8',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11602' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0C; .NET4.0E; GWX:QUALIFIED; Microsoft Outlook 15.0.4797; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11603' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Win64; x64; Trident/7.0; .NET CLR 2.0.50727; SLCC2; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; Tablet PC 2.0; InfoPath.3; .NET4.0E; GWX:QUALIFIED; Microsoft Outlook 15.0.4783; ms-office; MSOffice 15)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11604' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; InfoPath.3; GWX:QUALIFIED; Microsoft Outlook 14.0.7147; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11605' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 10.0; Win64; x64; Trident/7.0; .NET4.0C; .NET4.0E; .NET CLR 2.0.50727; .NET CLR 3.0.30729; .NET CLR 3.5.30729; SLCC2; Media Center PC 6.0; Microsoft Outlook 16.0.4266; ms-office; MSOffice 16)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 64,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 10.0',
'Platform_Marketingname' => 'Windows 10',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11606' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; InfoPath.2; .NET4.0C; OfficeLiveConnector.1.5; OfficeLivePatch.1.3; .NET4.0E; GWX:QUALIFIED; (1und1/1.3.0.0); MSOffice 12)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 64,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
'test-00101-11607' => [
'ua' => 'Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; Tablet PC 2.0; .NET4.0E; .NET4.0C; Microsoft Outlook 14.0.7165; ms-office; MSOffice 14)',
'properties' => [
'Browser_Name' => 'Internet Explorer',
'Browser_Type' => 'Browser',
'Browser_Bits' => 32,
'Browser_Maker' => 'Microsoft Corporation',
'Browser_Modus' => 'unknown',
'Browser_Version' => '7.0',
'Platform_Codename' => 'Windows NT 6.1',
'Platform_Marketingname' => 'Windows 7',
'Platform_Version' => '0.0.0',
'Platform_Bits' => 32,
'Platform_Maker' => 'Microsoft Corporation',
'Platform_Brand_Name' => 'Microsoft',
'Device_Name' => 'Windows Desktop',
'Device_Maker' => 'unknown',
'Device_Type' => 'Desktop',
'Device_Pointing_Method' => 'mouse',
'Device_Dual_Orientation' => false,
'Device_Code_Name' => 'Windows Desktop',
'Device_Brand_Name' => 'unknown',
'RenderingEngine_Name' => 'Trident',
'RenderingEngine_Version' => 'unknown',
'RenderingEngine_Maker' => 'Microsoft Corporation',
],
],
];
|
<?php
/**
* Created by PhpStorm.
* Author: ZhiPeng
* Date: 2017/2/13
* Project: Cat Visual
*/
namespace console\controllers;
use Yii;
use yii\console\Controller;
class BaseController extends Controller {
public function actions() {
return [
'error' => [
'class' => 'yii\web\ErrorAction'
]
];
}
public function init() {
ini_set("memory_limit", "1024M");
set_time_limit(0);
}
} |
<?php
/**
* Class Cookies
*/
class Cookies
{
/**
* @param $key
* @return string Cookie
*/
public static function get($key)
{
if (isset($_COOKIE[$key])) {
return $_COOKIE[$key];
} else {
return "La cookie $key n'existe pas";
}
}
/**
* @param $key
* @param $value
* @param null set Cookie
*/
public static function set($key, $value, $time = null)
{
if ($time != null) {
setcookie($key, $value, time() + ($time * 24 * 3600));
} else {
setcookie($key, $value);
}
}
/**
* @param $key Destoy Cookie
*/
public static function destroy($key)
{
setcookie($key, '', time() - 3600);
}
} |
<?php
use Faker\Generator as Faker;
$factory->define(\App\Models\Task::class, function (Faker $faker) {
return [
'name'=>$faker->streetName,
'priority'=>$faker->randomElement(['not_defined','low','medium','high','urgent']),
'billable'=>$faker->numberBetween(0,1),
'price_per_hour'=>$faker->numberBetween(5,50)
];
});
|
<?php namespace App;
class Address extends Elegant
{
protected $table = 'Addresses';
public static $rules = [
'street'=> 'required|alphanumeric',
'number'=> 'required|alphanumeric',
'inner_number' => 'alphanumeric',
'postal_code' => 'required|numeric|size:5',
'colony'=> 'required|alphanumeric',
'city'=> 'required|alphanumeric',
'estate' => 'required|alphanumeric',
'additional_info' => 'required|alphanumeric'
];
} |
<?php
/**
* Created by PhpStorm.
* User: alvin
* Date: 21/12/2017
* Time: 12:18 PM
*/
namespace AltheaTech\Talkable\Helper;
use Magento\Customer\Model\Session;
use Magento\Directory\Model\CountryFactory;
use Magento\Framework\App\Helper\AbstractHelper;
use Magento\Framework\App\Helper\Context;
use Magento\Sales\Model\Order;
class Data extends AbstractHelper {
protected $_countryFactory;
protected $_customerSession;
/**
* @inheritDoc
*/
public function __construct(
CountryFactory $countryFactory,
Session $customerSession,
Context $context
)
{
$this->_countryFactory = $countryFactory;
$this->_customerSession = $customerSession;
parent::__construct($context);
}
public function getPurchaseData(Order $order)
{
$shippingInfo = [];
$shippingAddress = $order->getShippingAddress();
if ($shippingAddress) {
$countryName = $this->_countryFactory->create()
->loadByCode($shippingAddress->getCountryId())
->getName();
$shippingFields = array_filter([
implode(", ", $shippingAddress->getStreet()),
$shippingAddress->getCity(),
$shippingAddress->getRegion(),
$shippingAddress->getPostcode(),
$countryName,
]);
$shippingInfo = [
"shipping_zip" => $shippingAddress->getPostcode(),
"shipping_address" => implode(", ", $shippingFields),
];
}
$subtotal = (float)$order->getSubtotal();
if ($order->getDiscountAmount() < 0) {
// getDiscountAmount() returns negative number formatted as string, e.g. "-10.0000"
// That's why we add it instead of subtracting.
$subtotal += (float)$order->getDiscountAmount();
}
$retval = [
"customer" => [
"email" => $order->getCustomerEmail(),
"first_name" => $order->getCustomerFirstname(),
"last_name" => $order->getCustomerLastname(),
"customer_id" => $order->getCustomerId(),
],
"purchase" => array_merge($shippingInfo, [
"order_number" => $order->getIncrementId(),
"order_date" => $order->getCreatedAt(),
"subtotal" => $this->_normalizeAmount($subtotal),
"coupon_code" => $order->getCouponCode(),
"items" => [],
]),
];
/* @var Order\Item $product */
foreach ($order->getAllVisibleItems() as $product) {
$retval["purchase"]["items"][] = [
"product_id" => $product->getSku(),
"price" => $this->_normalizeAmount($product->getPrice()),
"quantity" => strval(round($product->getQtyOrdered())),
"title" => $product->getName(),
];
}
return $retval;
}
public function getCustomerData()
{
if ($this->_customerSession->isLoggedIn()) {
$customer = $this->_customerSession->getCustomer();
$dataModel = $customer->getDataModel();
return [
"email" => $dataModel->getEmail(),
"first_name" => $dataModel->getFirstname(),
"last_name" => $dataModel->getLastname(),
"customer_id" => $customer->getEntityId(),
];
} else {
return new \stdClass();
}
}
protected function _normalizeAmount($value)
{
return number_format((float)$value, 2, ".", "");
}
} |
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('users', function (Blueprint $table) {
$table->increments('id');
$table->string('firstname')->comment = "The user's first name.";
$table->string('lastname')->comment = "The user's last name";
$table->string('phone',15)->unique()->comment = "The user's phone number";
$table->string('email')->unique()->comment = "The user's email.";
$table->string('role')->comment = "The user's role, student or superadmin or admin.";
$table->string('type')->default('default')->comment = "Tell whether the admin account has been validated by superadmin or not";
$table->string('password')->comment = "The user's password.";
$table->string('is_admin')->default('invalid')->comment = "Tell whether the admin account has been validated by superadmin or not";
$table->rememberToken();
$table->softDeletes();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('users');
}
}
|
<?php
/**
* Contao Open Source CMS
*
* Copyright (c) 2005-2013 Leo Feyer
*
* @package Core
* @link https://contao.org
* @license http://www.gnu.org/licenses/lgpl-3.0.html LGPL
*/
/**
* Table tl_forum_threads
*/
$GLOBALS['TL_DCA']['tl_forum_threads'] = array
(
// Config
'config' => array
(
'dataContainer' => 'Table',
'switchToEdit' => true,
'ptable' => 'tl_forum',
'ctable' => array('tl_forum_topics'),
'enableVersioning' => true,
'onsubmit_callback' => array
(
array('tl_forum_threads', 'saveRecord')
),
'sql' => array
(
'keys' => array
(
'id' => 'primary',
'pid' => 'index',
'title' => 'index',
'responsedate' => 'index'
)
),
),
// List
'list' => array
(
'sorting' => array
(
'mode' => 4,
'fields' => array('responsedate DESC'),
'headerFields' => array('title'),
'panelLayout' => 'search,limit',
'disableGrouping' => true,
'child_record_callback' => array('tl_forum_threads', 'listRecords'),
'child_record_class' => 'no_padding',
//'rootPaste' => false
),
'global_operations' => array
(
'all' => array
(
'label' => &$GLOBALS['TL_LANG']['MSC']['all'],
'href' => 'act=select',
'class' => 'header_edit_all',
'attributes' => 'onclick="Backend.getScrollOffset()" accesskey="e"'
),
),
'operations' => array
(
'edit' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['edit'],
'href' => 'table=tl_forum_topics',
'icon' => 'edit.gif',
),
'editheader' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['editheader'],
'href' => 'act=edit',
'icon' => 'header.gif',
),
//'copy' => array
//(
// 'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['copy'],
// 'href' => 'act=paste&mode=copy',
// 'icon' => 'copy.gif'
//),
'cut' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['cut'],
'href' => 'act=paste&mode=cut',
'icon' => 'cut.gif'
),
'delete' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['delete'],
'href' => 'act=delete',
'icon' => 'delete.gif',
'attributes' => 'onclick="if(!confirm(\'' . $GLOBALS['TL_LANG']['MSC']['deleteConfirm'] . '\'))return false;Backend.getScrollOffset()"'
),
'toggle' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['toggle'],
'icon' => 'visible.gif',
'attributes' => 'onclick="Backend.getScrollOffset();return AjaxRequest.toggleVisibility(this,%s)"',
'button_callback' => array('tl_forum_threads', 'toggleIcon')
),
'show' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['show'],
'href' => 'act=show',
'icon' => 'show.gif'
)
)
),
// Palettes
'palettes' => array
(
'__selector__' => array('protected'),
'default' => '{title_legend},title;{author_legend},name,email;{text_legend},text;{publish_legend},published'
),
// Fields
'fields' => array
(
'id' => array
(
'sql' => "int(10) unsigned NOT NULL auto_increment"
),
'pid' => array
(
'sql' => "int(10) unsigned NOT NULL default '0'"
),
'tstamp' => array
(
'sql' => "int(10) unsigned NOT NULL default '0'"
),
// Erstellungsdatum, wird beim Anlegen des Themas gesetzt
'initdate' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['initdate'],
'flag' => 5,
'sql' => "int(10) unsigned NOT NULL default '0'"
),
// Aktualisierungsdatum, wird bei einer Antwort gesetzt
'responsedate' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['responsedate'],
'flag' => 5,
'sql' => "int(10) unsigned NOT NULL default '0'"
),
// ID des Mitglieds mit der letzten Antwort
'actname' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['actname'],
'exclude' => true,
'inputType' => 'select',
'foreignKey' => 'tl_member.username',
'eval' => array('mandatory'=>true, 'tl_class'=>'w50', 'choosen'=>true),
'sql' => "int(10) unsigned NOT NULL default '0'"
),
'title' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['title'],
'exclude' => true,
'search' => true,
'sorting' => true,
'flag' => 1,
'inputType' => 'text',
'eval' => array('mandatory'=>true, 'maxlength'=>128, 'tl_class'=>'long'),
'sql' => "varchar(128) NOT NULL default ''"
),
// Name des Threaderstellers (Falls leer, dann Gast)
'name' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['name'],
'exclude' => true,
'inputType' => 'select',
'foreignKey' => 'tl_member.username',
'eval' => array
(
'mandatory' => false,
'tl_class' => 'w50',
'choosen' => true,
'includeBlankOption' => true,
),
'sql' => "int(10) unsigned NOT NULL default '0'"
),
// Email des Threaderstellers
'email' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['email'],
'inputType' => 'text',
'eval' => array
(
'mandatory' => false,
'rgxp' => 'emails',
'decodeEntities' => true,
'tl_class' => 'w50'
),
'sql' => "varchar(128) NOT NULL default ''"
),
'text' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_thread']['text'],
'exclude' => true,
'search' => true,
'inputType' => 'textarea',
'eval' => array('rte'=>'tinyMCE', 'tl_class'=>'clr'),
'sql' => "mediumtext NULL"
),
// Anzahl der Zugriffe
'hits' => array
(
'exclude' => true,
'inputType' => 'text',
'sql' => "int(10) unsigned NOT NULL default '0'"
),
'published' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_forum_threads']['published'],
'exclude' => true,
'inputType' => 'checkbox',
'default' => 1,
'eval' => array('doNotCopy'=>true),
'sql' => "char(1) NOT NULL default ''"
),
)
);
/**
* Provide miscellaneous methods that are used by the data configuration array
*/
class tl_forum_threads extends Backend
{
/**
* Funktion saveRecord (onsubmit_callback: Wird beim Abschicken des Backend-Formulars ausgeführt)
* Beim Speichern eines Datensatzes zusätzliche Änderungen vornehmen
* @param DataContainer
* @return -
*/
public function saveRecord(DataContainer $dc)
{
// Frontend-Aufruf
if(!$dc instanceof DataContainer)
{
return;
}
// Zurück, wenn kein aktiver Datensatz vorhanden ist
if(!$dc->activeRecord)
{
return;
}
if(!$dc->activeRecord->initdate)
{
// Eröffnungszeitpunkt im Thema speichern
$zeit = time();
$set = array
(
'initdate' => $zeit,
'responsedate' => $zeit
);
$this->Database->prepare("UPDATE tl_forum_threads %s WHERE id=?")
->set($set)
->execute($dc->id);
return;
}
}
/**
* Generiere eine Zeile als HTML
* @param array
* @return string
*/
public function listRecords($arrRow)
{
static $class;
$class == 'odd' ? 'even' : 'odd';
$line = '';
$line .= '<div class="tl_content_left '.$class.'">';
$line .= '<b>'.date('d.m.Y H:i', $arrRow['responsedate']).'</b> ';
$line .= '<b>'.$arrRow['title'].'</b>';
$line .= "</div>";
return $line;
}
/**
* Return the "toggle visibility" button
* @param array
* @param string
* @param string
* @param string
* @param string
* @param string
* @return string
*/
public function toggleIcon($row, $href, $label, $title, $icon, $attributes)
{
$this->import('BackendUser', 'User');
if (strlen($this->Input->get('tid')))
{
$this->toggleVisibility($this->Input->get('tid'), ($this->Input->get('state') == 0));
$this->redirect($this->getReferer());
}
// Check permissions AFTER checking the tid, so hacking attempts are logged
if (!$this->User->isAdmin && !$this->User->hasAccess('tl_forum_threads::published', 'alexf'))
{
return '';
}
$href .= '&id='.$this->Input->get('id').'&tid='.$row['id'].'&state='.$row[''];
if (!$row['published'])
{
$icon = 'invisible.gif';
}
return '<a href="'.$this->addToUrl($href).'" title="'.specialchars($title).'"'.$attributes.'>'.$this->generateImage($icon, $label).'</a> ';
}
/**
* Disable/enable a user group
* @param integer
* @param boolean
*/
public function toggleVisibility($intId, $blnPublished)
{
// Check permissions to publish
if (!$this->User->isAdmin && !$this->User->hasAccess('tl_forum_threads::published', 'alexf'))
{
$this->log('Not enough permissions to show/hide record ID "'.$intId.'"', 'tl_forum_threads toggleVisibility', TL_ERROR);
$this->redirect('contao/main.php?act=error');
}
$this->createInitialVersion('tl_forum_threads', $intId);
// Trigger the save_callback
if (is_array($GLOBALS['TL_DCA']['tl_forum_threads']['fields']['published']['save_callback']))
{
foreach ($GLOBALS['TL_DCA']['tl_forum_threads']['fields']['published']['save_callback'] as $callback)
{
$this->import($callback[0]);
$blnPublished = $this->$callback[0]->$callback[1]($blnPublished, $this);
}
}
// Update the database
$this->Database->prepare("UPDATE tl_forum_threads SET tstamp=". time() .", published='" . ($blnPublished ? '' : '1') . "' WHERE id=?")
->execute($intId);
$this->createNewVersion('tl_forum_threads', $intId);
}
}
|
<?php
return [
'Userid' => '用户id',
'Tid' => '任务id',
'Create_time' => '完成时间'
];
|
<?php
if (!isset($oreon)) {
exit();
}
function nagvisInstall($dir) {
if (is_dir($dir)) {
return true;
}
return false;
}
$path = './modules/centreon-nagvis/';
$attrsTextLong = array("size" => "50");
$form = new HTML_QuickFormCustom('Form', 'post', '?p=' . $p);
$form->addElement('header', 'title', _('Centreon Nagvis configuration'));
$form->addElement('header', 'information', _('Nagvis information'));
$form->addElement('header', 'information2', _('Nagvis authentication'));
$form->addElement('text', 'centreon_nagvis_uri', _('Nagvis URI'), $attrsTextLong);
$form->addElement('text', 'centreon_nagvis_path', _('Nagvis Path'), $attrsTextLong);
$form->addElement('select', 'centreon_nagvis_auth', _("Single NagVis user auth or Centreon user auth ? "), array("single" => "Single User", "centreon" => "Centreon User"));
$form->addElement('text', 'centreon_nagvis_single_user', _('Nagvis user name'), $attrsTextLong);
$form->addRule('centreon_nagvis_uri', _('Compulsory field'), 'required');
$form->addRule('centreon_nagvis_path', _('Compulsory field'), 'required');
$form->addRule('centreon_nagvis_auth', _('Compulsory field'), 'required');
$form->addRule('centreon_nagvis_single_user', _('Compulsory field'), 'required');
$form->registerRule('exist', 'callback', 'nagvisInstall');
$form->addRule('centreon_nagvis_path', _('Directory does not exist'), 'exist');
$form->setRequiredNote("<font style='color: red;'>*</font>" . _(" Required fields"));
$form->addElement('submit', 'submitC', _("Save"));
$form->addElement('reset', 'reset', _("Reset"));
if ($form->validate()) {
$values = $form->getSubmitValues();
$queryInsert = 'UPDATE `options` SET `value` = "%s" WHERE `key` = "%s"';
$pearDB->query(sprintf($queryInsert, $pearDB->escape($values['centreon_nagvis_uri']), 'centreon_nagvis_uri'));
$pearDB->query(sprintf($queryInsert, $pearDB->escape($values['centreon_nagvis_path']), 'centreon_nagvis_path'));
$pearDB->query(sprintf($queryInsert, $pearDB->escape($values['centreon_nagvis_auth']), 'centreon_nagvis_auth'));
$pearDB->query(sprintf($queryInsert, $pearDB->escape($values['centreon_nagvis_single_user']), 'centreon_nagvis_single_user'));
}
/*
* Get options
*/
if (!isset($values)) {
$values = array();
$query = 'SELECT `key`, `value` FROM `options` '
. 'WHERE `key` IN '
. '("centreon_nagvis_uri", "centreon_nagvis_path", "centreon_nagvis_auth", "centreon_nagvis_single_user")';
try {
$res = $pearDB->query($query);
} catch (\PDOException $e) {
// do nothing to keep same behaviour as previous version
}
while ($row = $res->fetch()) {
$values[$row['key']] = $row['value'];
}
}
$form->setDefaults($values);
/*
*
* Smarty template Init
*
*/
$tpl = new Smarty();
$tpl = initSmartyTpl($path, $tpl);
$tpl->assign('p', $p);
$renderer = new HTML_QuickForm_Renderer_ArraySmarty($tpl, true);
$renderer->setRequiredTemplate('{$label} <font color="red" size="1">*</font>');
$renderer->setErrorTemplate('<font color="red">{$error}</font><br />{$html}');
$form->accept($renderer);
$tpl->assign('form', $renderer->toArray());
$tpl->display("nagvis-config.ihtml");
?>
|
<?php
/**
* Kima Status Code
* @author Steve Vega
*/
namespace Kima\Http;
use Kima\Error;
/**
* Status Code
* Handles the status codes
*/
class StatusCode
{
/**
* Error messages
*/
const ERROR_UNKNOWN_STATUS_CODE = 'Unknown status code "%d"';
/**
* Status codes messages
* @var array $status_code_messages
*/
public static $status_code_messages = [
// Informational
100 => 'Continue',
101 => 'Switching Protocols',
// Success
200 => 'OK',
201 => 'Created',
202 => 'Accepted',
203 => 'Non-Authoritative Information',
204 => 'No Content',
205 => 'Reset Content',
206 => 'Partial Content',
// Redirection
300 => 'Multiple Choices',
301 => 'Moved Permanently',
302 => 'Moved Temporarily',
303 => 'See Other',
304 => 'Not Modified',
305 => 'Use Proxy',
307 => 'Temporary Redirect',
// Client Error
400 => 'Bad Request',
401 => 'Unauthorized',
402 => 'Payment Required',
403 => 'Forbidden',
404 => 'Not Found',
405 => 'Method Not Allowed',
406 => 'Not Acceptable',
407 => 'Proxy Authentication Required',
408 => 'Request Time-out',
409 => 'Conflict',
410 => 'Gone',
411 => 'Length Required',
412 => 'Precondition Failed',
413 => 'Request Entity Too Large',
414 => 'Request-URI Too Large',
415 => 'Unsupported Media Type',
416 => 'Requested Range Not Satisfiable',
417 => 'Expectation Failed',
// Server Error
500 => 'Internal Server Error',
501 => 'Not Implemented',
502 => 'Bad Gateway',
503 => 'Service Unavailable',
504 => 'Gateway Time-out',
505 => 'HTTP Version not supported',
509 => 'Bandwidth Limit Exceeded',
];
/**
* Get the message of a status code
* @param string $code The status code
* @return string
*/
public static function get_message($code)
{
$code = (int) $code;
if (array_key_exists($code, self::$status_code_messages)) {
$message = self::$status_code_messages[$code];
} else {
$message = sprintf(self::ERROR_UNKNOWN_STATUS_CODE, $code);
Error::set($message, false);
}
return $message;
}
}
|
<?php
namespace chly19\Dice;
use PHPUnit\Framework\TestCase;
/**
* Test cases for class Robot.
*/
class RobotTest extends TestCase
{
/**
* Create new instance of Robot class with random number of dice per roll.
*/
public function setUp(): void
{
$this->number = rand(1, 4);
$this->robot = new Robot($this->number);
$this->rollsPerRound = rand(1, 3);
$this->roundSum = 0;
$this->totalSum = 0;
for ($i = 0; $i < $this->rollsPerRound; $i++) {
$this->robot->roll();
$this->values = $this->robot->values();
$this->robot->calcRoundGraphic();
$this->robot->calcRoundSum();
for ($j = 0; $j < $this->number; $j++) {
$this->roundSum += $this->values[$j];
}
}
$this->robot->calcTotalSum();
$this->totalSum += $this->roundSum;
}
/**
* Test that robot object is an instance of Robot class.
*/
public function testObjectIsInstanceOfRobot()
{
$this->assertInstanceOf("\chly19\Dice\Robot", $this->robot);
}
/**
* Check that the number of dice per roll is correct.
*/
public function testNumberOfDices()
{
$this->assertEquals($this->number, count($this->values));
$this->assertEquals($this->number, count($this->robot->graphic));
}
/**
* Test if one of the rolled dice in current roll is 1.
*/
public function testValueIsOne()
{
$valueIsOne = null;
for ($i = 0; $i < $this->number; $i++) {
if ($this->values[$i] == 1) {
$valueIsOne = true;
}
}
$this->assertEquals($this->robot->valueIsOne(), $valueIsOne);
}
/**
* Test that number of rolls for current round is correct.
*/
public function testNumberOfRollsPerRound()
{
$this->assertEquals($this->rollsPerRound, $this->robot->rollsPerRound());
$this->assertEquals($this->rollsPerRound, count($this->robot->getRoundGraphic()));
}
/**
* Test that the determination is correct for if the robot will roll the
* dice again based on probability.
*/
public function testIsThrowingDiceAgain()
{
$min = 1;
$level = 12;
$this->robot->calcIfThrowingDiceAgain($min, $level);
$isThrowingDiceAgain = (pow(5, $this->number * ($this->rollsPerRound + 1)) /
pow(6, $this->number * ($this->rollsPerRound + 1))) >
(pow(5, $this->number * $this->robot->randomRollsPerRound) /
pow(6, $this->number * $this->robot->randomRollsPerRound));
$this->assertEquals($isThrowingDiceAgain, $this->robot->isThrowingDiceAgain());
}
/**
* Test that the round sum is correct.
*/
public function testRoundSum()
{
$this->assertEquals($this->robot->getRoundSum(), $this->roundSum);
}
/**
* Test that the total sum is correct.
*/
public function testTotalSum()
{
$this->assertEquals($this->robot->getTotalSum(), $this->totalSum);
}
}
|
<?php
/**
* 角色模型
* buzhidao
* 2015-7-30
*/
namespace Admin\Model;
class RoleModel extends CommonModel
{
public function __construct()
{
parent::__construct();
}
//获取角色信息
public function getRole($roleid=null, $rolename=null, $start=0, $length=0)
{
$where = array();
if ($roleid) $where['roleid'] = is_array($roleid) ? array('in', $roleid) : $roleid;
if ($rolename) $where['rolename'] = array('like', '%'.$rolename.'%');
//获取角色信息
$total = M('role')->where($where)->count();
$DBObj = M('role')->where($where);
if ($length) $DBObj = $DBObj->limit($start, $length);
$result = $DBObj->select();
$data = is_array($result) ? $result : array();
return array('total'=>$total, 'data'=>$data);
}
//获取角色信息 通过roleid
public function getRoleByID($roleid=null)
{
if (!$roleid) return false;
$roleinfo = $this->getRole($roleid);
return is_array($roleinfo) ? current($roleinfo['data']) : array();
}
//获取角色关联的菜单信息
public function getRoleNode($roleid=null)
{
if (!$roleid) return false;
$result = M('role_node')->where(array('roleid'=>$roleid))->select();
return is_array($result)&&!empty($result) ? $result : array();
}
} |
<?php namespace App\Console\Commands;
use Illuminate\Console\Command;
use Symfony\Component\Console\Input\InputOption;
use Symfony\Component\Console\Input\InputArgument;
use App\Models\StockMetrics;
use App\Models\Stock;
use App\Models\Historicals;
use Carbon\Carbon;
class UpdateStockMetricsCommand extends Command {
/**
* The console command name.
*
* @var string
*/
protected $name = 'stocks:updateStockMetrics';
/**
* The console command description.
*
* @var string
*/
protected $description = "Updates stock metrics from Yahoo finance data.";
/**
* Create a new command instance.
*
* @return void
*/
public function __construct()
{
parent::__construct();
}
/**
* Execute the console command.
*
* @return mixed
*/
public function fire()
{
$this->info('Updating stock metrics... This may take several minutes...');
$iterationNumber = 1;
$maxIterations = ceil(Stock::count()/100);
if($this->option('testMode')){
$maxIterations = 1;
$this->info("[Test Mode]");
}
UpdateStockMetricsCommand::insertMetricRowsForNewStocks();
while($iterationNumber <= $maxIterations){
$stockCodeParameter = UpdateStockMetricsCommand::getStockCodeParameter($this->option('testMode'));
$stockURL = "http://finance.yahoo.com/d/quotes.csv?s=".$stockCodeParameter."&f=sl1p2c1ohgvf6j4ee8p5rp6r5kjj1y";
$metrics = explode("\n", @file_get_contents($stockURL));
foreach($metrics as $metric){
if($metric != null){
$individualMetric = explode(',', $metric);
$stockCode = substr(explode('.', $individualMetric[0])[0], 1);
$numberOfShares = UpdateStockMetricsCommand::correctNumberOfShares($stockCode, $individualMetric[8]);
if($individualMetric[1]){
StockMetrics::updateOrCreate(['stock_code' => $stockCode], [
"stock_code" => $stockCode,
"last_trade" => $individualMetric[1],
"percent_change" => UpdateStockMetricsCommand::correctPercentChange($individualMetric[1], substr($individualMetric[2], 1, -2), $stockCode),
'day_change' => $individualMetric[3],
"open" => $individualMetric[4],
"high" => $individualMetric[5],
"low" => $individualMetric[6],
"close" => $individualMetric[1], //Last Trade after closing time
"adj_close" => 0.000, //No Data Available
"volume" => UpdateStockMetricsCommand::correctVolume($individualMetric[7], $stockCode),
"shares" => $numberOfShares,
"EBITDA" => UpdateStockMetricsCommand::formatEBITDA($individualMetric[9]),
"earnings_per_share_current" => $individualMetric[10],
"earnings_per_share_next_year" => $individualMetric[11],
"price_to_sales" => $individualMetric[12],
"price_to_earnings" => $individualMetric[13],
"price_to_book" => $individualMetric[14],
"peg_ratio" => $individualMetric[15],
"year_high" => $individualMetric[16],
"year_low" => $individualMetric[17],
"current_market_cap" => $numberOfShares * $individualMetric[1]/1000000, //Market cap is number of shares * last trade / 1,000,000
"dividend_yield" => $individualMetric[19],
"updated_at" => date("Y-m-d H:i:s")
]);
}
}
}
$this->info("Updating... ".round(($iterationNumber)*(100/$maxIterations), 2)."%");
$iterationNumber++;
}
$this->info('All stock metrics were updated successfully!');
}
//Creates rows for stocks that aren't yet in the metrics table (Required because getStockCodeParameter gets the 100 oldest metrics)
private static function insertMetricRowsForNewStocks(){
$stockCodes = Stock::lists('stock_code');
foreach($stockCodes as $stockCode){
StockMetrics::updateOrCreate(['stock_code' => $stockCode], []);
}
}
//Gets list of stock codes separated by addition symbols, only TLS and CBA in test mode
private static function getStockCodeParameter($testMode = false){
if(!$testMode){
//Limit of 100 at a time due to yahoo's url length limit
$stockCodeList = StockMetrics::where('updated_at', '<', Carbon::now()->subSeconds(60))->orderBy('updated_at')->take(100)->lists('stock_code');
$stockCodeParameter = "";
foreach($stockCodeList as $stockCode){
$stockCodeParameter .= "+".$stockCode.".AX";
}
return substr($stockCodeParameter, 1);
}
else{
return "TLS.AX+CBA.AX";
}
}
//Checks EBITDA value and calls appropriate helper function to format it
private static function formatEBITDA($ebitda){
if(substr($ebitda, -1) == 'B' || substr($ebitda, -1) == 'M'){
return formatMoneyAmountToNumber($ebitda);
}
elseif($ebitda > 10000 || $ebitda < -10000){
return formatHundredThousandToMillion($ebitda);
}
return $ebitda;
}
//Checks number of shares provided by API, if zero, use most recent non-zero number
private static function correctNumberOfShares($stockCode, $numberOfShares){
if($numberOfShares == 'N/A'){
return Historicals::where('stock_code', $stockCode)->where('shares', '!=', 0)->orderBy('date', 'DESC')->pluck('shares');
}
return $numberOfShares;
}
//Nulls current day's percentage change if it's the exact same as yesterday's
private static function correctPercentChange($lastTrade, $percentChange, $stockCode){
$mostRecentHistoricalDate = Historicals::getMostRecentHistoricalDate();
$yesterdaysClose = Historicals::where(['stock_code' => $stockCode, 'date' => $mostRecentHistoricalDate])->pluck('close');
if($yesterdaysClose && $percentChange != 0 && $lastTrade == $yesterdaysClose){
return 0;
}
return $percentChange;
}
//Nulls current day's volume if it's the exact same as yesterday's
private static function correctVolume($volume, $stockCode){
$mostRecentHistoricalDate = Historicals::getMostRecentHistoricalDate();
$yesterdaysVolume = Historicals::where(['stock_code' => $stockCode, 'date' => $mostRecentHistoricalDate])->pluck('volume');
if($yesterdaysVolume == $volume){
return 0;
}
return $volume;
}
/**
* Get the console command arguments.
*
* @return array
*/
protected function getArguments()
{
return [
['example', InputArgument::OPTIONAL, 'An example argument.'],
];
}
/**
* Get the console command options.
*
* @return array
*/
protected function getOptions()
{
return [
['testMode', null, InputOption::VALUE_OPTIONAL, 'Runs the command in Test Mode.', false],
];
}
} |
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class ChangeVideosAndUsersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
// videos
DB::statement("ALTER TABLE learner.videos change column resource_id resource_id varchar(26)");
// users
DB::statement("ALTER TABLE learner.users ADD nickname VARCHAR(255) NULL AFTER email");
DB::statement("ALTER TABLE learner.users MODIFY password VARCHAR(60)");
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
// videos
DB::statement("ALTER TABLE videos change column resource_id resource_id int");
// users
DB::statement("ALTER TABLE learner.users DROP nicknam");
DB::statement("ALTER TABLE learner.users MODIFY password VARCHAR(60) NOT NULL");
}
}
|
<?php
App::uses('BaseAuthorize', 'Controller/Component/Auth');
App::uses('Token', 'Apis.Model');
App::uses('OauthCredentials', 'Apis.Lib');
/**
* @property Token $Token
*/
class OauthAuthorize extends BaseAuthorize {
public $Token;
public function __construct(\ComponentCollection $collection, $settings = array()) {
$this->Token = ClassRegistry::init('Apis.Token');
$defaults = array('Apis' => array());
$settings = array_merge($defaults, $settings);
parent::__construct($collection, $settings);
}
public function authorize($user, \CakeRequest $request) {
$dbs = ConnectionManager::sourceList();
$apiNames = array_intersect(array_keys($this->settings['Apis']), array_values($dbs));
$count = 0;
foreach ($apiNames as $index => $name) {
switch ($this->settings['Apis'][$name]['store']) {
case 'Session':
$allowed = $this->_checkTokenSession($name, $user['id']);
break;
case 'Cookie':
$allowed = $this->_checkTokenCookie($name, $user['id']);
break;
default:
$allowed = $this->_checkTokenDb($name, $user['id']);
break;
}
if ($allowed) {
$count++;
}
}
if ($count == count($apiNames)) {
return true;
}
return false;
}
protected function _checkTokenDb($apiName, $userId) {
$token = $this->Token->getTokenDb($userId, $apiName);
if (!empty($token['access_token'])) {
$tokenSecret = (empty($token['token_secret'])) ? null : $token['token_secret'];
OauthCredentials::setAccessToken(strtolower($apiName), $token['access_token'], $tokenSecret);
return true;
} else {
//$this->controller()->Auth->flash('Not authorized to access ' . $apiName . ' Api functions');
return false;
}
}
protected function _checkTokenSession($apiName, $userId) {
App::uses('CakeSession', 'Model/Datasource');
$token = CakeSession::read('Oauth.' . $apiName);
if (!empty($token['access_token'])) {
// check for token validity?
$tokenSecret = (empty($token['token_secret'])) ? null : $token['token_secret'];
OauthCredentials::setAccessToken(strtolower($apiName), $token['access_token'], $tokenSecret);
return true;
} else {
//$this->controller()->Auth->flash('Not authorized to access ' . $apiName . ' Api functions');
return false;
}
}
protected function _checkTokenCookie($apiName, $userId) {
//not implemented
//$this->controller()->Auth->flash('Not authorized to access ' . $apiName . ' Api functions');
return false;
}
}
?> |
<?php
declare(strict_types=1);
namespace App\Services\Activity;
use App\Models\Activity;
use App\Models\Game;
use Illuminate\Support\Facades\Auth;
class ActivityService
{
public function create(string $action, array $data = null, Game $game = null): Activity
{
$coverUrl = null;
$gameId = null;
if ($game) {
$coverUrl = $game->getCoverUrl();
$gameId = $game->id;
}
if (Auth::check()) {
$data['user_name'] = Auth::user()->name;
}
return Activity::create([
'action' => $action,
'cover_url' => $coverUrl,
'game_id' => $gameId,
'data' => $data,
]);
}
public function getActivities(int $userId)
{
return Activity::where(['user_id' => $userId])
->orderBy('created_at')
->get();
}
}
|
<?php namespace App\Http\Controllers;
use App\Http\Requests;
use App\Http\Controllers\Controller;
use App\Equipo;
use App\CalixtaAPI;
use Illuminate\Http\Request;
class MensajeController extends Controller {
public function enviar_mensaje(Request $request)
{
$sms= CalixtaAPI::enviaMensaje($request->numtel,$request->msg);
echo $sms;
}
/**
* Display a listing of the resource.
*
* @return Response
*/
public function index()
{
$equipos = Equipo::all();
return view('equipos.index',compact('equipos'));
}
/**
* Show the form for creating a new resource.
*
* @return Response
*/
public function create()
{
return view('equipos.create');
}
/**
* Store a newly created resource in storage.
*
* @return Response
*/
public function store(Request $request)
{
$equipo= Equipo::create($request->all());
$equipos = Equipo::all();
return view('equipos.index',compact('equipos'));
}
/**
* Display the specified resource.
*
* @param int $id
* @return Response
*/
public function show($id)
{
//
}
/**
* Show the form for editing the specified resource.
*
* @param int $id
* @return Response
*/
public function edit($id)
{
$equipo= Equipo::find($id);
return view('equipos.edit',compact('equipo'));
}
/**
* Update the specified resource in storage.
*
* @param int $id
* @return Response
*/
public function update($id,Request $request)
{
$equipo = Equipo::find($id);
$equipo->update($request->all());
return redirect('equipos');
}
/**
* Remove the specified resource from storage.
*
* @param int $id
* @return Response
*/
public function destroy($id)
{
$equipo = Equipo::find($id);
$equipo->delete();
return redirect('equipos');
}
}
|
<?php
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/
Route::get('/share','PageController@share');
Route::get('/test','PageController@special')->name('khulduli');
Route::get('/numberOfComments','PageController@sortNC')->name('sortNC');
Route::get('/mostRead','PageController@sortMR')->name('sortMR');
Route::post('/post','PageController@check')->name('check');
Route::get('/solution','PageController@solution')->name('quiz.solution');
Route::get('/questionThread/{question}','questionController@openThread')->name('question.thread');
Route::post('/search','PageController@search')->name('search');
//gallery views
Route::get('/gallery','PageController@gallery')->name('gal');
Route::get('/gallery/{gallery}','PageController@gallery_view')->name('gal_view');
//infographic views
Route::get('/infographic','PageController@infographic')->name('info');
Route::get('/infographic/{infographic}','PageController@infographic_view')->name('info_view');
Route::post('/reply','questionController@reply')->name('reply.post');
Route::post('/questionP','questionController@insertQuestion')->name('postQuestion');
Route::post('/jigyasa','JigyasaController@create')->name('jigyasa.create');
Route::get('/ask','questionController@show')->name('askQuestion');
Route::get('/about','PageController@about')->name('about');
Route::get('/','PageController@home')->name('home');
Route::get('/loadComments/{comment}','PageController@loadComments')->name('loadComments');
Route::get('/categories/{category}','PageController@categorywise')->name('category');
Route::get('/allpost','PageController@allpost')->name('all');
Route::get('/article/{content}','PageController@show')->name('view');
Route::post('/comment','PageController@comment')->name('comment.post');
Route::get('/login','loginController@login')->name('login');
Route::post('/login','loginController@verify')->name('login.verify');
Route::get('/logout','loginController@destroy')->name('logout');
Route::get('/quiz','PageController@quiz')->name('quiz');
Route::get('/fetchcategories','PageController@fetchcategories')->name('test');
Route::get('/fetchspecial','PageController@fetchspecial');
Route::group(['prefix'=>'/dashboard'],function(){
Route::get('','ArticlesController@index')->name('dashboard');
Route::get('/content','ArticlesController@index')->name('content.index');
Route::get('/content/video','ArticlesController@vindex')->name('content.vindex');
Route::get('content/create','ArticlesController@create')->name('content.create');
Route::get('content/vcreate','ArticlesController@vcreate')->name('video.create');
Route::post('/content','ArticlesController@store')->name('content.store');
Route::get('/content/{content}','ArticlesController@show')->name('content.show');
Route::get('/content/{content}/edit','ArticlesController@edit')->name('content.edit');
Route::put('/content/{content}','ArticlesController@update')->name('content.update');
Route::delete('/content/{content}','ArticlesController@destroy')->name('content.destroy');
#tag routes
Route::get('/tag','TagController@index')->name('tag.index');
Route::get('tag/create','TagController@create')->name('tag.create');
Route::post('/tag','TagController@store')->name('tag.store');
Route::get('/tag/{tag}','TagController@show')->name('tag.show');
Route::get('/tag/{tag}/edit','TagController@edit')->name('tag.edit');
Route::put('/tag/{tag}','TagController@update')->name('tag.update');
Route::delete('/tag/{tag}','TagController@destroy')->name('tag.destroy');
//infographics route
Route::get('/infographics','infoController@index')->name('info.index');
Route::get('infographics/create','infoController@create')->name('info.create');
Route::post('/infographics','infoController@store')->name('info.store');
Route::get('/infographics/{infographics}','infoController@show')->name('info.show');
Route::get('/infographics/{infographics}/edit','infoController@edit')->name('info.edit');
Route::put('/infographics/{infographics}','infoController@update')->name('info.update');
Route::delete('/infographics/{infographics}','infoController@destroy')->name('info.destroy');
//gallery routes
Route::get('/gallery','galleryController@index')->name('gal.index');
Route::get('gallery/create','galleryController@create')->name('gal.create');
Route::post('/gallery','galleryController@store')->name('gal.store');
Route::get('/gallery/{gallery}','galleryController@show')->name('gal.show');
Route::get('/gallery/{gallery}/edit','galleryController@edit')->name('gal.edit');
Route::put('/gallery/{gallery}','galleryController@update')->name('gal.update');
Route::delete('/gallery/{gallery}','galleryController@destroy')->name('gal.destroy');
//viewing the comments,questions,replies
Route::get('/review/question','review@question')->name('question.review');
Route::get('/review/comment','review@comment')->name('comment.review');
Route::get('/review/replies','review@reply')->name('reply.review');
//deleting routes
Route::delete('/review/question/{question}','review@questiondel')->name('question.delete');
Route::delete('/review/comment/{comment}','review@commentdel')->name('comment.delete');
Route::delete('/review/replies/{replies}','review@replydel')->name('reply.delete');
#quiz routes
Route::get('/quiz','quizController@index')->name('quiz.index');
Route::get('/quiz/create','quizController@create')->name('quiz.create');
Route::post('/quiz','quizController@store')->name('quiz.store');
Route::get('/quiz/{quiz}','quizController@show')->name('quiz.show');
Route::get('/quiz/{quiz}/edit','quizController@edit')->name('quiz.edit');
Route::put('/quiz/{quiz}','quizController@update')->name('quiz.update');
Route::delete('/quiz/{quiz}','quizController@destroy')->name('quiz.destroy');
Route::get('/quizq','quizController@indexq')->name('quiz.indexq');
Route::get('/quizq/create','quizController@createq')->name('quiz.createq');
Route::post('/quizq','quizController@storeq')->name('quiz.storeq');
Route::get('/quizq/{quiz}','quizController@showq')->name('quiz.showq');
Route::get('/quizq/{quiz}/edit','quizController@editq')->name('quiz.editq');
Route::put('/quizq/{quiz}','quizController@updateq')->name('quiz.updateq');
Route::delete('/quizq/{quiz}','quizController@destroyq')->name('quiz.destroyq');
#category routes
Route::get('/category','categoryController@index')->name('category.index');
Route::get('category/create','categoryController@create')->name('category.create');
Route::post('/category','categoryController@store')->name('category.store');
Route::get('/category/{content}','categoryController@show')->name('category.show');
Route::get('/category/{content}/edit','categoryController@edit')->name('category.edit');
Route::put('/category/{content}','categoryController@update')->name('category.update');
Route::delete('/category/{content}','categoryController@destroy')->name('category.destroy');
//user routes
Route::get('/user','UserController@index')->name('user.index');
Route::get('user/create','UserController@create')->name('user.create');
Route::post('/user','UserController@store')->name('user.store');
Route::get('/user/{user}','UserController@show')->name('user.show');
Route::get('/user/{user}/edit','UserController@edit')->name('user.edit');
Route::put('/user/{user}','UserController@update')->name('user.update');
Route::delete('/user/{user}','UserController@destroy')->name('user.destroy');
//jigyasa routes
Route::get('/jigyasa','JigyasaController@index')->name('jigyasa.index');
Route::delete('/jigyasa/{jigyasa}','JigyasaController@destroy')->name('jigyasa.destroy');
});
|
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateRecebidosTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('recebidos', function (Blueprint $table) {
$table->Increments('idRecebido');
$table->decimal("valor",10,2);
$table->dateTime("dataEntrada");
$table->string("descricao",100);
$table->integer('idPlano')->unsigned()->nullable();
$table->foreign('idPlano')->references('idPlano')->on('planos')->onDelete('cascade');
$table->boolean("deletado")->nullable();
$table->boolean("ativo");
$table->timestamps(); // data cadastro e modificado
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('recebidos');
}
}
|
<?php
/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/
// Basic Routes
Route::get('/', [
'as' => 'home',
'uses' => 'PagesController@getHomePage',
]);
Route::get('/about', [
'as' => 'about',
'uses' => 'PagesController@getAboutPage',
]);
Route::get('/donate', [
'as' => 'donate',
'uses' => 'PagesController@getDonatePage',
]);
Route::get('/terms', [
'as' => 'terms',
'uses' => 'PagesController@getTermsPage',
]);
Route::get('/privacy', [
'as' => 'privacy',
'uses' => 'PagesController@getPrivacyPage',
]);
Route::get('/cookies', [
'as' => 'cookies',
'uses' => 'PagesController@getCookiesPage',
]);
Route::post('/getArticles', [
'as' => 'getArticles',
'uses' => 'PagesController@getArticles',
]);
Route::post('/getAllArticles', [
'as' => 'getAllArticles',
'uses' => 'PagesController@getAllArticles',
'middleware' => 'auth-admin'
]);
Route::get('/getAdminPanel', [
'as' => 'getAdminPanel',
'uses' => 'PagesController@getAdminPanel',
'middleware' => 'auth-admin'
]);
// Authentication Routes
require ('auth.php');
// Articles Routes
require ('articles.php');
// Categories Routes
require ('categories.php');
// Newsletters Routes
require ('newsletters.php');
|
<?php
declare(strict_types=1);
namespace wpengine\cache_plugin;
require_once __DIR__ . '/../clear-all-cache-status.php';
require_once __DIR__ . '/../security/security-checks.php';
require_once __DIR__ . '/../wpe-common-adapter.php';
require_once __DIR__ . '/../max-cdn-provider.php';
\wpengine\cache_plugin\check_security();
class QuickActions {
public static function display( int $status = ClearAllCacheStatus::DEFAULT ) {
?>
<div class="wpe-quick-actions wpe-common-plugin-container">
<h2>Quick Actions</h2>
<p>Caching reduces the load on your site by storing the results of a request, so that it can be served to the next visitor. This significantly increases the speed of the site. However, this can lead to a visitor receiving an old version of the page. This can be fixed by clearing the cache below.</p>
<?php self::display_maxcdn_info(); ?>
<p><b>Note:</b> Cache is cleared by environment not by domain.</p>
<?php
self::display_panel_links();
self::display_all_cache_button_panel( $status );
?>
</div>
<?php
}
private static function display_maxcdn_info() {
$cdn_provider = new MaxCDNProvider();
if ( ! $cdn_provider->is_enabled() ) {
return;
}
$site_name = WpeCommonAdapter::get_instance()->get_site_name();
?>
<p>CDN cache can be cleared every five minutes. <a href=<?php echo esc_url( 'https://my.wpengine.com/installs/' . $site_name . '/cdn' ); ?> target='_blank'>Disable CDN.</a></p>
<?php
}
private static function display_panel_links() {
$site_name = WpeCommonAdapter::get_instance()->get_site_name();
?>
<div class="wpe-admin-button-controls">
<a href=<?php echo esc_url( 'https://my.wpengine.com/installs/' . $site_name . '/domains' ); ?> target='_blank'> Clear Global Edge Security caches by domain in Portal</a>
<a href=<?php echo esc_url( 'https://my.wpengine.com/installs/' . $site_name . '/cache_dashboard' ); ?> target='_blank'> Clear Advanced Network cache in Portal</a>
<a href='https://wpengine.com/support/cache/' target='_blank'>Learn more about caching</a>
</div>
<?php
}
private static function display_all_cache_button_panel( int $status ) {
?>
<div class="wpe-common-cta-panel">
<div class="wpe-common-cta-wrap">
<div id="wpe-clear-all-cache-icon" class="wpe-admin-icon-check-solid"></div>
<div class="wpe-common-cta-text">
<p class="wpe-common-cta-heading">Clear all caches at once</p>
<p>This will slow down your site until caches are rebuilt.</p>
<?php self::display_multisite_info_text(); ?>
<p id="wpe-last-cleared-text"></p>
<p id="wpe-last-cleared-error-text"></p>
</div>
</div>
<div class="wpe-common-cta-button">
<button id="wpe-clear-all-cache-btn" class="wpe-admin-button-primary">Clear all caches</button>
</div>
</div>
<?php
}
private static function display_multisite_info_text() {
if ( is_multisite() ) {
?>
<p id="wpe-multisite-info-text" style="font-size: small; max-width: 400px;">For multisite environments, using this tool will clear caches for all sites. This will slow down your sites until caches are rebuilt</p>
<?php
}
}
}
|
<?php
namespace App\AppBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
/**
* @ORM\Entity()
*/
class User
{
/**
* @ORM\Column(type="integer")
* @ORM\Id()
* @ORM\GeneratedValue()
*/
public $id;
/**
* @ORM\Column()
*/
public $name;
/**
* @ORM\Column()
*/
public $email;
/**
* @ORM\Column(type="array")
*/
public $skills = [];
/**
* @ORM\Column(type="datetime")
*/
public $created;
/**
* @ORM\Column(type="datetime")
*/
public $updated;
public function setEmail($email)
{
$this->email = $email;
}
public function getEmail()
{
return $this->email;
}
public function setId($id)
{
$this->id = $id;
}
public function getId()
{
return $this->id;
}
public function setName($name)
{
$this->name = $name;
}
public function getName()
{
return $this->name;
}
public function setSkills(array $skills = [])
{
$this->skills = $skills;
}
public function getSkills()
{
return $this->skills;
}
public function setCreated(\DateTime $created)
{
$this->created = $created;
}
public function getCreated()
{
return $this->created;
}
public function setUpdated(\DateTime $updated)
{
$this->updated = $updated;
}
public function getUpdated()
{
return $this->updated;
}
} |
<?php
namespace Verkoo\Common\Entities;
use Verkoo\Common\Traits\Priceable;
use Illuminate\Database\Eloquent\Model;
class Product extends Model
{
use Priceable;
protected $appends = ['vat', 'quantity', 'product_id', 'product_name'];
protected $hidden = ['category', 'cost', 'created_at', 'initial_stock', 'priority', 'updated_at'];
protected $casts = [
'stock_control' => 'bool',
'active' => 'bool',
];
protected $fillable = [
'name',
'active',
'category_id',
'supplier_id',
'brand_id',
'unit_of_measure_id',
'kitchen_id',
'price',
'cost',
'short_description',
'description',
'ean13',
'photo',
'initial_stock',
'stock',
'stock_control',
'priority',
];
public function category()
{
return $this->belongsTo(Category::class);
}
public function customers()
{
return $this->belongsToMany(Customer::class)->withPivot('price');
}
public function getCostAttribute()
{
return number_format($this->attributes['cost'] / 100,2,',','');
}
public function setCostAttribute($cost)
{
$this->attributes['cost'] = toCents($cost);
}
public function getVatAttribute()
{
if ($this->category->tax) {
return $this->category->tax->percentage;
}
$options = Options::first();
if ($options && $tax = $options->tax) {
return $tax->percentage;
}
}
public static function generateBarcode($provider = '00', $category = '00') {
$pool = '0123456789';
$randomNumber = substr(str_shuffle(str_repeat($pool, 9)), 0, 9);
$provider = str_pad($provider, 2, "0", STR_PAD_LEFT);
$category = str_pad($category, 2, "0", STR_PAD_LEFT);
return $provider . $category . $randomNumber;
}
public static function orderByCategory($categoryId)
{
$result = (new static)::join('categories','products.category_id','=','categories.id')
->select('products.id', 'products.name', 'categories.name as category');
if ($categoryId) {
$result = $result->where('categories.id', $categoryId);
}
$result->orderBy('categories.name', 'asc')
->orderBy('products.name', 'asc');
return $result;
}
public function reduceStock($quantity)
{
$this->stock = $this->stock - $quantity;
$this->save();
}
public function increaseStock($quantity)
{
$this->stock = $this->stock + $quantity;
$this->save();
}
public function updateStock($oldQuantity, $newQuantity)
{
$value = $oldQuantity - $newQuantity;
if ($value > 0) {
$this->increaseStock(abs($value));
}
else {
$this->reduceStock(abs($value));
}
$this->save();
}
public static function scopeActive($query)
{
return $query->where('active', 1);
}
public static function scopeWithStock($query)
{
if (! Settings::get('hide_out_of_stock')) {
return $query;
}
return $query->where('stock', '>', 0);
}
public static function scopeWithRecountableCategory($query)
{
return $query->whereHas('category', function ($query) {
$query->where('recount_stock', 1);
});
}
public static function scopeCategoryOrChildren($query, $parent)
{
return $query->whereHas('category', function($query) use ($parent) {
$query->where('lft', '>=', $parent->lft)
->where('lft', '<=', $parent->rgt);
});
}
public function setBrandIdAttribute($value)
{
if (!$value) {
$this->attributes['brand_id'] = null;
} else {
$this->attributes['brand_id'] = $value;
}
}
public function setSupplierIdAttribute($value)
{
if (!$value) {
$this->attributes['supplier_id'] = null;
} else {
$this->attributes['supplier_id'] = $value;
}
}
public function getPriceFor($customer)
{
$customer = Customer::find($customer);
if (!$customer) return $this->price;
$product = $customer->products->where('id', $this->id)->first();
if ($product) {
return number_format($product->pivot->price / 100,2,',','');
}
return $this->price;
}
}
|
<?php
/**
* This file is part of the Zephir.
*
* (c) Phalcon Team <team@zephir-lang.com>
*
* For the full copyright and license information, please view
* the LICENSE file that was distributed with this source code.
*/
namespace Zephir;
/**
* Class Exception for backward compatibility after migrating to namespaces.
*/
class Exception extends \Exception
{
}
|
<?php
namespace App\Controller;
use App\Repository\ItemsRepository;
use App\Services\Cart\CartService;
use App\Services\SecurityService;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\Routing\Annotation\Route;
class DefaultController extends AbstractController
{
public function __construct(ItemsRepository $productsRepository)
{
$this->productsRepository = $productsRepository;
}
/**
* @Route("/", name="home")
*/
public function home()
{
return $this->render('home.html.twig', [
'products' => $this->productsRepository->findVisibleLimit(9)
]);
}
} |
<?php
/*
* Copyright 2014 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
* License for the specific language governing permissions and limitations under
* the License.
*/
class Google_Service_JobService_CommutePreference extends Google_Model
{
public $allowNonStreetLevelAddress;
public $departureHourLocal;
public $method;
public $roadTraffic;
protected $startLocationType = 'Google_Service_JobService_LatLng';
protected $startLocationDataType = '';
public $travelTime;
public function setAllowNonStreetLevelAddress($allowNonStreetLevelAddress)
{
$this->allowNonStreetLevelAddress = $allowNonStreetLevelAddress;
}
public function getAllowNonStreetLevelAddress()
{
return $this->allowNonStreetLevelAddress;
}
public function setDepartureHourLocal($departureHourLocal)
{
$this->departureHourLocal = $departureHourLocal;
}
public function getDepartureHourLocal()
{
return $this->departureHourLocal;
}
public function setMethod($method)
{
$this->method = $method;
}
public function getMethod()
{
return $this->method;
}
public function setRoadTraffic($roadTraffic)
{
$this->roadTraffic = $roadTraffic;
}
public function getRoadTraffic()
{
return $this->roadTraffic;
}
/**
* @param Google_Service_JobService_LatLng
*/
public function setStartLocation(Google_Service_JobService_LatLng $startLocation)
{
$this->startLocation = $startLocation;
}
/**
* @return Google_Service_JobService_LatLng
*/
public function getStartLocation()
{
return $this->startLocation;
}
public function setTravelTime($travelTime)
{
$this->travelTime = $travelTime;
}
public function getTravelTime()
{
return $this->travelTime;
}
}
|
<?php
use Illuminate\Support\Facades\Route;
use App\Http\Controllers\ProductTypeController;
use App\Http\Controllers\ProductBrandController;
use App\Http\Controllers\ProductController;
use App\Http\Controllers\ProductVendorController;
Route::get('/', function () {
return view('auth/login');
});
Route::middleware(['auth:sanctum', 'verified'])->get('/dashboard', function () {
return view('dashboard');
})->name('dashboard');
Route::group([ 'middleware' => 'auth' ], function(){
Route::resource('product-vendors', ProductVendorController::class);
Route::resource('product-brands', ProductBrandController::class);
Route::get('product-types', [ProductTypeController::class, 'index']);
Route::post('add-product-type', [ProductTypeController::class, 'store']);
Route::resource('products', ProductController::class);
});
|
<?php
use yii\db\Schema;
use yii\db\Migration;
class m150909_134657_user extends Migration
{
/*
public function up()
{
}
public function down()
{
echo "m150909_134657_user cannot be reverted.\n";
return false;
}
*/
// Use safeUp/safeDown to run migration code within a transaction
public function safeUp()
{
$this->addColumn('user','telephone',Schema::TYPE_STRING.'(20)');
$this->addColumn('user','user_id_1c',Schema::TYPE_STRING.'(30)');
$this->dropColumn('profile','telephone');
}
public function safeDown()
{
$this->addColumn('profile','telephone',Schema::TYPE_STRING.'(15)');
$this->dropColumn('user','telephone');
$this->dropColumn('user','user_id_1c');
}
}
|
<?php
namespace Atemschutz\CoreBundle\Entity;
use Doctrine\ORM\NoResultException;
use Symfony\Component\Security\Core\User\UserProviderInterface;
use Symfony\Component\Security\Core\User\UserInterface;
use Symfony\Component\Security\Core\Exception\UsernameNotFoundException;
use Symfony\Component\Security\Core\Exception\UnsupportedUserException;
use Doctrine\ORM\EntityRepository;
/**
* @author Benjamin Ihrig
*/
class UserRepository extends EntityRepository implements UserProviderInterface {
/**
* finds all active users in the database
* @return Ambigous <multitype:, \Doctrine\ORM\mixed, \Doctrine\ORM\Internal\Hydration\mixed, \Doctrine\DBAL\Driver\Statement, \Doctrine\Common\Cache\mixed>
*/
public function findAllActive() {
$query = $this->createQueryBuilder('a')
->where('a.isActive = :isActive')
->setParameter('isActive', true)
->getQuery();
return $query->getResult();
}
/**
* (non-PHPdoc)
* @see \Symfony\Component\Security\Core\User\UserProviderInterface::loadUserByUsername()
*/
public function loadUserByUsername($email) {
$q = $this
->createQueryBuilder('u')
->where('u.email = :email')
->setParameter('email', $email)
->getQuery();
try {
$user = $q->getSingleResult();
} catch (NoResultException $nre) {
throw new UsernameNotFoundException(sprintf('Kann keinen Benutzer mit dem Benutzernamen %s finden.', $email), 0, $nre);
}
return $user;
}
/**
* (non-PHPdoc)
* @see \Symfony\Component\Security\Core\User\UserProviderInterface::refreshUser()
*/
public function refreshUser(UserInterface $user) {
$class = get_class($user);
if (!$this->supportsClass($class)) {
throw new UnsupportedUserException(sprintf('Instanzen der Klasse "%s" sind nicht unterstützt.', $class));
}
return $this->find($user->getId());
}
/**
* (non-PHPdoc)
* @see \Symfony\Component\Security\Core\User\UserProviderInterface::supportsClass()
*/
public function supportsClass($class) {
return $this->getEntityName() === $class || is_subclass_of($class, $this->getEntityName());
}
} |
<?php
/**
* Install Overview, Furasta.Org
*
* An overview of whats required to install the CMS.
*
* @author Conor Mac Aoidh <conormacaoidh@gmail.com>
* @license http://furasta.org/licence.txt The BSD License
* @version 1.0
* @package installer
*/
session_start( );
require 'header.php';
$phpversion=phpversion();
$ver=explode('/',$_SERVER['SERVER_SOFTWARE']);
$apacheversion=$ver[1].' '.$ver[2];
$access=(is_writable(HOME)) ? '<span class="green">Granted</span>':'<span id="notgranted" class="red">Not Granted</span>';
$php=($phpversion<<5) ? '<span class="green">'.$phpversion.'</span>':'<span class="red">'.$phpversion.'</span>';
$apache=($ver[1]<<2) ? '<span class="green">'.$apacheversion.'</span>':'<span class="red">'.$apacheversion.'</span>';
if(function_exists('apache_get_modules')){
$modules=apache_get_modules();
$mods=(in_array('mod_rewrite',$modules))?'<span class="green">Installed</span>':'<span id="notgranted" class="red">Not Installed</span>';
}
else
$mods='Unknown';
echo '
<script type="text/javascript">
$(function(){
$("#help-access").click(function(){
fHelp("Write Access must be enabled for Furasta.Org to perform properly. It is recommended not to install the CMS without granting write access.");
});
$("#help-rewrite").click(function(){
fHelp("The Apache module Mod_rewrite is essential for the CMS to run properly. It must be installed. However there are also dependencies of the Mod_rewrite module itself, such as Mod_proxy.");
});
});
</script>
<h1>Welcome to the Furasta.Org Installation</h1>
<br/>
The installation is comprised of 3 short steps. Please have your webserver\'s database details ready, then you will enter some user details and some information on the website your creating and that\'s it!
<table class="row-color">
<tr><th>Installation Requirements</th><th>Required</th><th>Current</th></tr>
<tr><td>PHP Version:</td><td>5</td><td>'.$php.'</td></tr>
<tr><td>MySQL Version:</td><td>5</td><td>Unknown</td></tr>
<tr><td>Apache Version:</td><td>2</td><td>'.$apache.'</td></tr>
<tr><td>Apache Rewrite Module: <a id="help-rewrite" class="help link"> </a></td><td> </td><td>'.$mods.'</td></tr>
<tr><td colspan="3">Write Access: <a id="help-access" class="help link"> </a></td></tr>
<tr><td colspan="2">'.HOME.'</td><td>'.$access.'</td></tr>
</table>
<br/>
<p><a href="stage1.php" class="grey-submit right">Begin</a></p>
<br style="clear:both"/>
';
require 'footer.php';
?>
|
<?php
namespace Academe\Instructions\Traits;
trait Sortable
{
/**
* @var array
*/
protected $orders = [];
/**
* @param $field
* @param $direction
* @return $this
*/
public function sort($field, $direction)
{
$this->orders[] = [$field, $direction];
return $this;
}
} |
<?php
// No utilizar el registro 0
$ayudas = array(
'1' => array(
'titulo_cuadro' => 'Generar Ayudas',
'introduccion' => 'Una plantilla que para como generar mas ayudas.',
'ruta' => '/help_plantilla/',
'fichero' => 'index.php'
),
'2' => array(
'titulo_cuadro' => 'Ayuda Importar Virtuemart',
'introduccion' => 'El modulo de importar desde Virtuemart, una ayuda tecnica como para ejecutarlos.',
'ruta' => '/help_import_virtuemart/',
'fichero' => 'index.php'
),
'3' => array(
'titulo_cuadro' => 'Testeo Productos',
'introduccion' => 'El modulo de productos, una ayuda tecnica como para ejecutar el testeo.',
'ruta' => '/help_productos/',
'fichero' => 'index.php'
),
'4' => array(
'titulo_cuadro' => 'Ayuda Tickets',
'introduccion' => 'El modulo de tickets, una ayuda tecnica como para ejecutar el testeo.',
'ruta' => '/help_tickets/',
'fichero' => 'index.php'
),
'5' => array(
'titulo_cuadro' => 'Ayuda Tickets Cerrados Cobrados',
'introduccion' => 'El listado de tickets cerrados, punto pendiente de revisar, paginacion y filtrado.',
'ruta' => '/help_tickets_cerrados_cobrados/',
'fichero' => 'index.php'
),
'6' => array(
'titulo_cuadro' => 'Fichero HEADER',
'introduccion' => 'En cargado mostrar menu y controlar que items mostrar según el usuario',
'ruta' => '/help_fichero_header/',
'fichero' => 'index.php'
),
'7' => array(
'titulo_cuadro' => 'Ayuda Cierres Caja',
'introduccion' => 'Cerrar caja',
'ruta' => '/help_cierresCaja/',
'fichero' => 'index.php'
),
'8' => array(
'titulo_cuadro' => 'Ayuda Tiendas',
'introduccion' => 'Dar de alta o modificar datos de tiendas, tanto tiendas fisicas , como webs',
'ruta' => '/help_tiendas/',
'fichero' => 'index.php'
)
);
?>
|
<?php
class Solution {
/**
* @param Integer[] $nums1
* @param Integer[] $nums2
* @return Integer[]
*/
function intersection($nums1, $nums2) {
$count1 = count($nums1);
$count2 = count($nums2);
if($count1 == 0 || $count2==0){
return [];
}
$newArr = [];
if($count1 <= $count2){
$arr = $nums1;
$arr2 = $nums2;
}else{
$arr = $nums2;
$arr2 = $nums1;
}
for($i=0;$i<count($arr);$i++){
if(in_array($arr[$i],$arr2) && !in_array($arr[$i],$newArr)){
$newArr[] = $arr[$i];
}
}
return $newArr;
}
} |
<?php
function display_styles($id){
$width = '';
$height = '';
$mr = ''; $ml = ''; $mt = ''; $mb = '';
$pt = ''; $pr = ''; $pb = ''; $pl = '';
$bg_color = '';
$bg_img = '';
$ff = '';
/* *************************************************************************
** Width & Heigh Section
************************************************************************* */
if (get_post_meta($id,'width', true)) {
$width = 'width: ' . get_post_meta($id,'width', true) . '; ';
}
if (get_post_meta($id,'height', true)) {
$height = 'height: ' . get_post_meta($id,'height', true) . '; ';
}
/* *************************************************************************
** Font Section
************************************************************************* */
if (get_post_meta($id,'cf_font_family', true)) {
$ff = 'font-family: ' . get_post_meta($id,'cf_font_family', true) . '; ';
}
/* *************************************************************************
** Margin Section
************************************************************************* */
if (get_post_meta($id,'margin_top', true)) {
$mt = 'margin-top: ' . get_post_meta($id,'margin_top', true) . 'px; ';
}
if (get_post_meta($id,'margin_right', true)) {
$mr = 'margin-right: ' . get_post_meta($id,'margin_right', true) . 'px; ';
}
if (get_post_meta($id,'margin_bottom', true)) {
$mb = 'margin-bottom: ' . get_post_meta($id,'margin_bottom', true) . 'px; ';
}
if (get_post_meta($id,'margin_left', true)) {
$ml = 'margin-left: ' . get_post_meta($id,'margin_left', true) . 'px; ';
}
/* *************************************************************************
** Padding Section
************************************************************************* */
if (get_post_meta($id,'cf_padding_top', true)) {
$pl = 'padding-top: ' . get_post_meta($id,'cf_padding_top', true) . 'px; ';
}
if (get_post_meta($id,'cf_padding_right', true)) {
$pr = 'padding-right: ' . get_post_meta($id,'cf_padding_right', true) . 'px; ';
}
if (get_post_meta($id,'cf_padding_bottom', true)) {
$pl = 'padding-bottom: ' . get_post_meta($id,'cf_padding_bottom', true) . 'px; ';
}
if (get_post_meta($id,'cf_padding_left', true)) {
$pl = 'padding-left: ' . get_post_meta($id,'cf_padding_left', true) . 'px; ';
}
/* *************************************************************************
** Media File Section
** This section is for the background image
************************************************************************* */
if (get_post_meta($id,'cf_colorpicker', true)) {
$bg_color = 'background-color: ' . get_post_meta($id,'cf_colorpicker', true) . ';';
}
if (get_post_meta($id,'cf_upload_media', true)) {
$bg_img = 'background-image: url("' . wp_get_attachment_url( get_post_meta($id,'cf_upload_media', true) ) . '");';
}
$style = $ff. $width . $height . $mt . $mr . $mb . $ml . $pt . $pr . $pb . $pl . $bg_color . $bg_img;
return $style;
}
|
<?php
use common\modules\catalog\models\CatalogCategory;
use common\modules\catalog\models\CatalogCategoryAttributeValue;
use frontend\widgets\leads\LeadForm;
use yii\helpers\Html;
use yii\helpers\Url;
use yii\web\View;
/* @var $this View */
/* @var $model CatalogCategory */
?><div class="catalog-item__info">
<div class="catalog-item__title">
<a href="<?= $model->present()->getUrl() ?>"><?= Html::encode($model->name) ?></a>
</div>
<div class="catalog-item__rating">
<i class="fa fa-star"></i>
<i class="fa fa-star"></i>
<i class="fa fa-star"></i>
<i class="fa fa-star"></i>
<i class="fa fa-star"></i>
</div>
<?php if ($announce = $model->present()->getAttributeValueByKey('announce')): ?>
<div class="catalog-item__announce">
<?= nl2br($announce) ?>
</div>
<?php endif; ?>
<div class="catalog-item__button">
<a class="btn btn-primary" href="<?= $model->present()->getUrl() ?>">Подробнее</a>
<?= LeadForm::widget([
'key' => 'order',
'text' => 'Заказать',
'options' => [
'class' => 'btn btn-primary btn-buy',
'href' => Url::to(['/leads/default/modal', 'key' => 'order', 'productId' => $model->id]),
],
]) ?>
</div>
</div>
|
<?php
namespace App\Modules;
class Direction{
public $routes;
public $optimized_routes;
public $optimized_routes_geocoding;
const API_URL = 'https://maps.googleapis.com/maps/api/directions/json';
const API_KEY = 'AIzaSyCHb-YMhGAiffYYib4AgztCBKH_U2C1iRE';
public function __construct(){
$this->optimized_routes = [];
$this->optimized_routes_geocoding = [];
}
public function get_simple_direction($origin, $destination){
$link = self::API_URL.'?origin='.urlencode($origin).'&destination='.urlencode($destination).'&key='.self::API_KEY;
$this->routes = file_get_contents($link);
$this->routes = json_decode($this->routes);
}
public function get_multiple_destinations($markers, $distance = [], $markers_optimized = []){
$routes_info = [];
for($i = 1; $i < count($markers); $i++){
$origin = $markers[0];
$destination = $markers[$i];
$this->get_simple_direction($origin, $destination);
$direction = $this->get_routes();
array_push($distance, $direction['general_info']['distance']);
array_push($routes_info, $direction['polyline']);
}
$next_marker = 0;
for($i = 1; $i < count($distance); $i++){
if(str_replace(' km', '', $distance[$i]) < str_replace(' km', '', $distance[$next_marker])){
$next_marker = $i;
}
else{
array_push($markers_optimized, $markers[$i]);
}
}
array_push($this->optimized_routes_geocoding, $routes_info[$next_marker]);
if($next_marker != 0){
array_unshift($markers_optimized, $markers[$next_marker]);
}
else{
array_push($markers_optimized, $markers[count($markers) - 1]);
}
array_push($this->optimized_routes, $markers_optimized[0]);
if(count($markers_optimized) > 1){
$this->get_multiple_destinations($markers_optimized);
}
}
public function get_routes(){
$direction = $this->routes->routes[0]->legs[0];
$general_info = [
'distance' => $direction->distance->text,
'delay' => $direction->duration->text,
'origin' => [
'address' => $direction->start_address,
'lat' => $direction->start_location->lat,
'lng' => $direction->start_location->lng
],
'destination' => [
'address' => $direction->end_address,
'lat' => $direction->end_location->lat,
'lng' => $direction->end_location->lng
]
];
$route_direction = [];
$polyline = [
['lat' => $direction->start_location->lat, 'lng' => $direction->start_location->lng]
];
$steps = $direction->steps;
for($i = 0; $i < count($steps) && $i < 21; $i++){
$comp_var = [
'distance' => $steps[$i]->distance->text,
'delay' => $steps[$i]->duration->text,
'end_location' => [
'lat' => $steps[$i]->end_location->lat,
'lng' => $steps[$i]->end_location->lng
],
'start_location' => [
'lat' => $steps[$i]->start_location->lat,
'lng' => $steps[$i]->start_location->lng
]
];
array_push($polyline, $comp_var['end_location']);
array_push($polyline, $comp_var['start_location']);
array_push($route_direction, $comp_var);
}
array_push($polyline, ['lat' => $direction->end_location->lat, 'lng' => $direction->end_location->lng]);
return ['general_info' => $general_info, 'route_direction' => $route_direction, 'polyline' => $polyline];
}
}
|
<?php
/**
* Aist Console (http://mateuszsitek.com/projects/console)
*
* @copyright Copyright (c) 2017 DIGITAL WOLVES LTD (http://digitalwolves.ltd) All rights reserved.
* @license http://opensource.org/licenses/BSD-3-Clause BSD-3-Clause
*/
namespace Aist\Console;
class Module
{
/**
* {@inheritDoc}
*/
public function getConfig()
{
$provider = new ConfigProvider();
return [
'service_manager' => $provider->getDependencies(),
];
}
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.