query
stringlengths
7
5.25k
document
stringlengths
15
1.06M
metadata
dict
negatives
sequencelengths
3
101
negative_scores
sequencelengths
3
101
document_score
stringlengths
3
10
document_rank
stringclasses
102 values
Determine if the user is authorized to make this request.
public function authorize() { return Auth::user()->hasAnyRole(['kuchar', 'manager']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function authorize()\n {\n if ($this->user() !== null) {\n return true;\n }\n return false;\n }", "public function authorize()\n {\n return $this->user() !== null;\n }", "public function authorize()\n {\n return $this->user() !== null;\n }", "public function authorize()\n {\n return $this->user() != null;\n }", "public function authorize(): bool\n {\n return $this->user() !== null;\n }", "public function authorize(): bool\n {\n return $this->isUserAuthorised();\n }", "public function authorize()\n {\n return !is_null($this->user());\n }", "public function authorize()\n {\n return request()->user() != null;\n }", "public function authorize()\n\t{\n\t\t// if user is updating his profile or a user is an admin\n\t\tif( $this->user()->isSuperAdmin() || !$this->route('user') ){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function authorize()\n {\n // this was my best guess\n return $this->user()->id === $this->route('user')->id;\n }", "public function isAuthorized()\n {\n return $this->cookieHelper->requestCookieExists('auth');\n }", "public function authorize()\n {\n return !empty(Auth::user()) && ($this->user()->isAnAdmin() || $this->user()->hasRole('user'));\n }", "public function authorize()\n {\n $originAccount = Account::find($this->get('origin_account_id'));\n return $originAccount->user_id == auth()->id();\n }", "public function authorize()\n {\n switch ($this->method()) {\n case 'GET':\n case 'POST':\n case 'PUT':\n case 'PATCH':\n case 'DELETE':\n default:\n return $this->user()->type == 'App\\\\Staff' ? true : false;\n break;\n }\n\n return false;\n }", "public function authorize()\n {\n if($this->user()->role == \"admin\" || $this->user()->id == $this->request->get('author_id')) return true;\n else return false;\n }", "public function authorize()\n {\n if(\\Auth::guest())\n {\n return false;\n } else {\n // Action 1 - Check if authenticated user is a superadmin\n if(\\Auth::User()->hasRole('superadmin'))\n return true;\n\n // Action 2 - Find UUID from request and compare to authenticated user\n $user = User::where('uuid', $this->user_uuid)->firstOrFail();\n if($user->id == \\Auth::User()->id)\n return true;\n\n // Action 3 - Fail request\n return false;\n }\n }", "public function authorize()\n {\n $this->model = $this->route('user');\n\n $this->model = is_null($this->model) ? User::class : $this->model;\n\n return $this->isAuthorized();\n }", "public function isAuthorized(): bool\n {\n // TODO: implement authorization check\n\n return true;\n }", "public function isAuthorized() {}", "public function authorize()\n {\n return request()->loggedin_role === 1;\n }", "public function authorize()\n {\n $this->model = $this->route('user');\n\n if ($this->isEdit() && !is_null($this->model)) {\n if (!user()->hasPermissionTo('Administrations::admin.user') && $this->model->id != user()->id) {\n return false;\n }\n }\n\n $this->model = is_null($this->model) ? User::class : $this->model;\n\n return $this->isAuthorized();\n }", "public function authorize()\n {\n $accessor = $this->user();\n\n return $accessor->isAdmin() || $accessor->hasKey('post-users');\n }", "public function authorize()\n {\n $user = \\Auth::getUser();\n\n return $user->user_type == 1;\n }", "public function authorize()\n {\n return auth()->check() ? true : false;\n }", "public function authorize()\n {\n return auth()->check() ? true : false;\n }", "public function authorize()\n {\n /**\n * @var User $user\n * @var Document $document\n */\n $user = Auth::user();\n $document = $this->route('document');\n\n return (int)$user->id === (int)$document->user_id;\n }", "public function authorize()\n {\n switch (true) {\n case $this->wantsToList():\n case $this->wantsToShow():\n if ($this->hasRoles(['owner', 'administrator'])) {\n return true;\n }\n break;\n case $this->wantsToStore():\n case $this->wantsToUpdate():\n case $this->wantsToDestroy():\n if ($this->hasRoles(['owner'])) {\n return true;\n }\n break;\n }\n\n return false;\n }", "public function authorize()\n {\n $user = JWTAuth::parseToken()->authenticate();\n $organisation = Organization::findOrFail($this->route('organizations'));\n return $organisation->admin_id == $user->id;\n }", "public function authorize()\n {\n if($this->user()->isAdmin())\n return true;\n\n return false;\n }", "function isAuthorized()\n {\n $authorized = parent::isAuthorized();\n return $authorized;\n }", "public function authorize()\n {\n $user = auth('web')->user();\n if ($user && $user->active) {\n return true;\n }\n\n return false;\n }", "public function authorize()\n {\n $this->user = User::query()->find($this->route()->parameter('user'));\n $this->merge(['verified' => $this->get('verified') ? 1 : 0]);\n\n return true;\n }", "public function authorize()\n {\n $user = request()->user('api');\n return $user->isSenior();\n }", "public function authorize()\n {\n return is_client_or_staff();\n }", "public function isAuthorized() {\n\t\treturn true;\n\t}", "public function authorize()\n {\n switch ($this->method()) {\n case 'POST':\n return true;\n case 'GET':\n default:\n {\n return false;\n }\n }\n }", "public function authorize()\n {\n switch ($this->method()) {\n case 'POST':\n return true;\n case 'GET':\n default:\n {\n return false;\n }\n }\n }", "public function authorize()\n {\n //Check if user is authorized to access this page\n if($this->user()->authorizeRoles(['admin'])) {\n return true;\n } else {\n return false;\n }\n }", "public function isAuthorized()\n\t{\n\t\t$sessionVal = Yii::$app->session->get($this->sessionParam);\n\t\treturn (!empty($sessionVal));\n\t}", "public function authorize() {\n\n return auth()->user() && auth()->user()->username === $this->user->username;\n }", "public function authorize()\n {\n return session('storefront_key') || request()->session()->has('api_credential');\n }", "public function authorize()\n {\n if ($this->user()->isAdmin($this->route('organization'))) {\n return true;\n }\n\n return false;\n\n }", "public function authorize()\n {\n return $this->user() && $this->user()->role === Constants::USER_ROLE_ADMIN;\n }", "public function authorized()\n {\n return $this->accepted && ! $this->test_mode;\n }", "public function authorize()\n {\n if (!auth()->check()) {\n return false;\n }\n return true;\n }", "public function hasAuthorized() {\n return $this->_has(1);\n }", "public function authorize()\n {\n $resource = Resource::find($this->route('id'));\n\n if (!$resource) {\n return true;\n }\n\n return $resource && $this->user()->can('access', $resource);\n }", "public function authorize()\n {\n /*\n if ($this->loan_id && is_numeric($this->loan_id) && $loan = Loan::whereId($this->loan_id)->first()) {\n // loan_id belongs to requesting user\n return $loan && $this->user()->id == $loan->user_id;\n }\n */\n return true; // let rules handle it\n }", "public function authorize()\n {\n //TODO Authorice Request (without Controller)\n return auth()->user()->role_id === 1;\n }", "public function authorize(): bool\n {\n return $this->user()->id === $this->article->user->id;\n }", "public function authorize()\n {\n return $this->user()->rol == 'admin' ? true : false;\n }", "public function isAuth()\n {\n return $this->session->hasAuthorisation();\n }", "public function authorize()\n {\n if(Auth::user())\n {\n return true;\n }\n else\n {\n return false;\n }\n }", "public function authorize()\n {\n //Check if user is authorized to access this page\n if($this->user()->authorizeRoles(['admin', 'hrmanager', 'hruser'])) {\n return true;\n } else {\n return false;\n }\n }", "public function authorize()\n {\n return \\Auth::check() ? true : false;\n }", "public function authorize()\n\t{\n\t\treturn true; //no user checking\n\t}", "public function authorize()\n {\n return $this->user()->id === $this->route('report')->user_id;\n }", "public function authorize()\n {\n return $this->user()->id === $this->route('report')->user_id;\n }", "public function authorize()\n {\n return !empty(Auth::user());\n }", "public function authorize()\n {\n return $this->groupHasUser() || $this->hasSeller();\n }", "public function authorize()\n\t{\n\t\t//@todo check with perissions\n\t\treturn (request()->user()->user_type == ADMIN_USER);\n\t}", "public function authorize()\n\t{\n\t\t//@todo check with perissions\n\t\treturn (request()->user()->user_type == ADMIN_USER);\n\t}", "public function isAuthorized() {\n\t\t\n\t}", "public function authorize()\n {\n if(Auth::check())\n {\n return (Auth::user()->has_world_admin_access);\n }\n return false;\n }", "public function authorize()\n {\n if (!\\Auth::guest()) {\n $user = \\Auth::getUser();\n if ($user->type == User::USER_TYPE_ADMIN) {\n return true;\n }\n }\n\n return false;\n }", "public function authorize()\n {\n if (auth()->user()->is_admin) {\n return true;\n }\n return false;\n }", "public function authorize()\n {\n if ($this->user()->is_admin){\n return true;\n }\n else if ($this->method == \"PUT\"){\n if ($this->user()->id == $this->input('id')){\n return true;\n }\n }\n return false;\n }", "public function authorize(): bool\n {\n return parent::authorize() && (int)$this->playList->user_id === auth()->user()->id;\n }", "public function authorize() {\n\t\treturn $this->user()->is_admin;\n\t}", "public function authorize()\n {\n if (Auth::check()) {\n \n return true;\n \n }\n return false;\n }", "public function authorize()\n {\n $user = Auth::user();\n return $user && $user->rol == 'admin';\n }", "public function authorize()\n\t{\n\t\t// Nutzern akzeptiert werden\n\t\tif(Auth::check())\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "public function authorize()\n {\n // TODO: Check if has business\n return session()->has('id');\n }", "public function authorize()\n {\n if (auth()->check() && auth()->user()->isAdmin()) {\n return true;\n }\n\n return false;\n }", "public function authorize()\n {\n return $this->auth->check();\n }", "public function authorize() {\n\t\t$user = \\Auth::user();\n\n\t\tif ( $user->isAdmin() ) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public function authorize()\n {\n if (auth()->user()->isAdmin() || auth()->user()->isCustomer()) {\n return true;\n }\n return false;\n }", "public function authorize()\n {\n return $this->container['auth']->check();\n }", "function isAuthorized($request) {\n return true;\n }", "public function authorize()\n {\n return Auth::guest() || isMember();\n }", "public function authorize()\n {\n return auth()->user() && auth()->user()->isCeo();\n }", "public function authorize(): bool\n {\n $deckId = $this->request->get('deck_id');\n $userId = Deck::whereKey($deckId)->value('user_id');\n\n return $userId === user()->id;\n }", "public function authorize()\n {\n return Auth::check() && Auth::user()->is_contractor;\n }", "public function authorize()\n {\n return TRUE;\n }", "public function authorize()\n {\n $user = User::find($this->id);\n\n if (!$user) {\n $user = User::where('no_ahli', $this->no_ahli)->first();\n }\n if ($user && $user->id == auth()->user()->id) return true;\n if (auth()->user()->is('admin')) return true;\n\n return false;\n }", "public function authorize()\n {\n # if it's false, it will rejected\n return true;\n }", "public function authorize()\n {\n $isValid = auth()->user()->is($this->route('task')->attempt->checklist->owner);\n\n return $isValid;\n }", "public function authorize()\n {\n $user = Auth::user();\n\n return ($user->getRole() == 'admin');\n }", "public function is_authorized() {\n\t\t$authorized = true;\n\t\tif ( $this->is_access_token_expired() ) {\n\t\t\t$authorized = false;\n\t\t}\n\n\t\treturn $authorized;\n\t}", "public function authorize()\n {\n $user = User::findOrFail($this->route('id'));\n\n return $user->hasRole('admin') || $user->hasRole('teacher');\n }", "public function authorize()\n {\n $project = \\App\\Project::find($this->request->get('project'));\n return $project && $project->isManager($this->user()->name);\n }", "public function isAuthorized() {\n\t\treturn (bool)$this->_storage->hasData();\n\t}", "public function authorize()\n {\n $idExpense = $this->input('expense');\n $expense = Expense::find($idExpense);\n\n return $expense && $this->user()->id == $expense->user_id;\n }", "public function authorize()\n {\n // User system not implemented\n return true;\n }", "public function authorize() : bool\n {\n // TODO check request to xhr in middleware\n return true;\n }", "public function authorize()\n {\n $organizationId = (string) $this->route('id');\n\n $this->organization = Organization::findByUuidOrFail($organizationId);\n\n return $this->user()->can('show', [Organization::class, $this->organization]);\n }", "public function authorize()\n {\n $user = $this->findFromUrl('user');\n return $this->user()->can('update', $user);\n }", "public function authorize()\n {\n $user = Auth::user();\n $orderElement = OrderElement::find($this->input(\"order_element_id\"));\n $order = $orderElement->order;\n\n if ($user->id == $order->user_id) {\n return true;\n } else {\n return false;\n }\n }", "public function authorize()\n {\n $current_user = auth()->user();\n $convention = Convention::find($this->route('convention_id'));\n\n // Use ClientPolicy here to authorize before checking the fields\n return $current_user->can('store', Convention::class)\n || $current_user->can('update', $convention);\n }", "public function authorize()\n {\n if (session()->has('user'))\n {\n $participantController = new ParticipantController();\n\n return !$participantController->isParticipating($this->input('id_user'), $this->input('id_event'));\n }\n else\n {\n return false;\n }\n }", "public function authorize()\n {\n return (Auth::user()->allowSuperAdminAccess || Auth::user()->allowAdminAccess);\n }" ]
[ "0.8401071", "0.8377486", "0.8377486", "0.8344406", "0.8253731", "0.824795", "0.8213121", "0.8146598", "0.81115526", "0.8083369", "0.7991986", "0.79907674", "0.79836637", "0.79604936", "0.79516214", "0.79494005", "0.79265946", "0.7915068", "0.79001635", "0.7894822", "0.7891453", "0.7890965", "0.7862504", "0.78414804", "0.78414804", "0.7837965", "0.78248763", "0.7812292", "0.7809632", "0.77928597", "0.7788316", "0.7781619", "0.77815884", "0.7763308", "0.7754035", "0.7717961", "0.7717961", "0.77171147", "0.77138597", "0.7705001", "0.7693082", "0.7692783", "0.76915383", "0.76909506", "0.76733255", "0.7667128", "0.7665592", "0.7656238", "0.7650853", "0.764326", "0.76431626", "0.76431614", "0.7635147", "0.76311624", "0.76294273", "0.7627076", "0.76207024", "0.76207024", "0.76139116", "0.76036394", "0.76035625", "0.76035625", "0.76032084", "0.7602515", "0.76007926", "0.75971127", "0.7588128", "0.7586303", "0.7581912", "0.7563037", "0.7554785", "0.75526226", "0.755171", "0.75436753", "0.75432944", "0.7540682", "0.7538806", "0.75280696", "0.751548", "0.75149626", "0.7501161", "0.74959517", "0.74956346", "0.74911124", "0.7489147", "0.74858016", "0.748033", "0.7478443", "0.7472642", "0.7472576", "0.7465409", "0.7464371", "0.74630046", "0.7462218", "0.7461453", "0.7449168", "0.74399257", "0.74358094", "0.7433247", "0.7432659", "0.74248093" ]
0.0
-1
Get the validation rules that apply to the request.
public function rules() { return [ "menu-validity-start" => "required", "menu-validity-end" => "required", "menu-name" => "required", "menu-soup" => ["required", Rule::notIn([-1])], "menu-meal-1" => ["required", Rule::notIn([-1])] ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function rules()\n {\n $commons = [\n\n ];\n return get_request_rules($this, $commons);\n }", "public function getRules()\n {\n return $this->validator->getRules();\n }", "public function getValidationRules()\n {\n $rules = [];\n\n // Get the schema\n $schema = $this->getSchema();\n\n return $schema->getRules($this);\n }", "public function rules()\n {\n return $this->validationRules;\n }", "public function rules()\n {\n $rules = [];\n switch ($this->getMethod()):\n case \"POST\":\n $rules = [\n 'course_id' => 'required|numeric',\n 'questions' => 'required|array',\n ];\n break;\n case \"PUT\":\n $rules = [\n 'id' => 'required|numeric',\n 'course_id' => 'required|numeric',\n 'questions' => 'required|array',\n ];\n break;\n case \"DELETE\":\n $rules = [\n 'id' => 'required|numeric'\n ];\n break;\n endswitch;\n return $rules;\n }", "public static function getRules()\n {\n return (new static)->getValidationRules();\n }", "public function getRules()\n {\n return $this->validation_rules;\n }", "public function getValidationRules()\n {\n return [];\n }", "public function getValidationRules() {\n return [\n 'email' => 'required|email',\n 'name' => 'required|min:3',\n 'password' => 'required',\n ];\n }", "public function rules()\n {\n if($this->isMethod('post')){\n return $this->post_rules();\n }\n if($this->isMethod('put')){\n return $this->put_rules();\n }\n }", "public function rules()\n {\n $rules = [];\n\n // Validation request for stripe keys for stripe if stripe status in active\n if($this->has('stripe_status')){\n $rules[\"api_key\"] = \"required\";\n $rules[\"api_secret\"] = \"required\";\n $rules[\"webhook_key\"] = \"required\";\n }\n\n if($this->has('razorpay_status')){\n $rules[\"razorpay_key\"] = \"required\";\n $rules[\"razorpay_secret\"] = \"required\";\n $rules[\"razorpay_webhook_secret\"] = \"required\";\n }\n\n // Validation request for paypal keys for paypal if paypal status in active\n if($this->has('paypal_status')){\n $rules[\"paypal_client_id\"] = \"required\";\n $rules[\"paypal_secret\"] = \"required\";\n $rules[\"paypal_mode\"] = \"required_if:paypal_status,on|in:sandbox,live\";\n }\n\n\n return $rules;\n }", "protected function getValidationRules()\n {\n $rules = [\n 'title' => 'required|min:3|max:255',\n ];\n\n return $rules;\n }", "public function getRules()\n\t{\n\t\t$rules['user_id'] = ['required', 'exists:' . app()->make(User::class)->getTable() . ',id'];\n\t\t$rules['org_id'] = ['required', 'exists:' . app()->make(Org::class)->getTable() . ',id'];\n\t\t$rules['role'] = ['required', 'string', 'in:' . implode(',', Static::ROLES)];\n\t\t$rules['scopes'] = ['nullable', 'array'];\n\t\t$rules['ended_at'] = ['nullable', 'date'];\n\t\t$rules['photo_url'] = ['nullable', 'string'];\n\n\t\treturn $rules;\n\t}", "public function rules()\n {\n switch ($this->method()) {\n case 'POST':\n return [\n 'username' => 'required|max:255',\n 'user_id' => 'required',\n 'mobile' => 'required|regex:/^1[34578][0-9]{9}$/',\n 'birthday' => 'required',\n 'cycle_id' => 'required',\n 'expired_at' => 'required',\n 'card_price' => 'required',\n ];\n case 'PUT':\n return [\n 'username' => 'required|max:255',\n 'user_id' => 'required',\n 'mobile' => 'required|regex:/^1[34578][0-9]{9}$/',\n 'birthday' => 'required',\n 'cycle_id' => 'required',\n 'expired_at' => 'required',\n 'card_price' => 'required',\n ];\n }\n }", "public function rules()\n {\n\n switch ($this->method()) {\n case 'GET':\n case 'POST':\n $rules = [\n 'name' => 'required|max:255',\n 'email' => 'required|email|max:255|unique:users',\n 'password' => 'required|min:6|confirmed',\n 'password_confirmation' => 'min:6|same:password',\n 'role_id' => 'required'\n ];\n break;\n case 'PUT':\n case 'PATCH':\n $rules = [\n 'name' => 'required|max:255',\n 'email' => 'required|email|max:255|unique:users,email,'.$this->id,\n ];\n break;\n\n default:\n $rules = [\n 'name' => 'required|max:255',\n 'email' => 'required|email|max:255|unique:users,email,'.$this->id,\n ];\n break;\n }\n return $rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n return $this->rules;\n }", "public function rules()\n {\n switch($this->method()) {\n case 'GET':\n return [];\n case 'POST':\n return [\n 'name' => 'required|max:50',\n 'company' => 'required|max:100',\n 'position' => 'required|max:50',\n 'email' => 'required|email|max:150',\n 'phone' => 'required|max:25',\n 'description' => 'nullable|max:500',\n ];\n case 'PUT':\n case 'PATCH':\n return [\n 'name' => 'required|max:50',\n 'company' => 'required|max:100',\n 'position' => 'required|max:50',\n 'email' => 'required|email|max:150',\n 'phone' => 'required|max:25',\n 'description' => 'nullable|max:500',\n ];\n case 'DELETE':\n return [];\n default:break;\n }\n \n }", "public function rules($request) {\n $function = explode(\"@\", $request->route()[1]['uses'])[1];\n return $this->getRouteValidateRule($this->rules, $function);\n // // 获取请求验证的函数名\n // // ltrim(strstr($a,'@'),'@')\n // if (count(explode(\"@\", Request::route()->getActionName())) >= 2) {\n // $actionFunctionName = explode(\"@\", Request::route()->getActionName()) [1];\n // }\n\n // // 取配置并返回\n // if (isset($this->rules[$actionFunctionName])) {\n // if (is_array($this->rules[$actionFunctionName])) {\n // return $this->rules[$actionFunctionName];\n // }\n // else {\n // return $this->rules[$this->rules[$actionFunctionName]];\n // }\n // }\n // else {\n // return [];\n // }\n }", "function getValidationRules() {\n\t\treturn array(\n\t\t\t'_MovieID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_UserID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CountryID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_BroadCastDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t\t'_CreatedDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t);\n\t}", "public function rules()\n {\n if ($this->method() === 'POST') {\n return $this->rulesForCreating();\n }\n\n return $this->rulesForUpdating();\n }", "public function rules()\n {\n $validation = [];\n if ($this->method() == \"POST\") {\n $validation = [\n 'name' => 'required|unique:users',\n 'email' => 'required|unique:users|email',\n 'password' => 'required|min:6|confirmed',\n 'password_confirmation' => 'required|min:6',\n 'roles' => 'required',\n ];\n } elseif ($this->method() == \"PUT\") {\n $validation = [\n 'name' => 'required|unique:users,name,' . $this->route()->parameter('id') . ',id',\n 'email' => 'required|unique:users,email,' . $this->route()->parameter('id') . ',id|email',\n 'roles' => 'required',\n ];\n\n if ($this->request->get('change_password') == true) {\n $validation['password'] = 'required|min:6|confirmed';\n $validation['password_confirmation'] = 'required|min:6';\n }\n }\n\n return $validation;\n }", "protected function getValidationRules()\n {\n $class = $this->model;\n\n return $class::$rules;\n }", "public function rules()\n {\n $data = $this->request->all();\n $rules['username'] = 'required|email';\n $rules['password'] = 'required'; \n\n return $rules;\n }", "public function rules()\n {\n $rules = $this->rules;\n\n $rules['fee'] = 'required|integer';\n $rules['phone'] = 'required|min:8|max:20';\n $rules['facebook'] = 'required|url';\n $rules['youtube'] = 'required|url';\n $rules['web'] = 'url';\n\n $rules['requestgender'] = 'required';\n $rules['serviceaddress'] = 'required|max:150';\n $rules['servicetime'] = 'required|max:150';\n $rules['language'] = 'required|max:150';\n $rules['bust'] = 'required|max:100|integer';\n $rules['waistline'] = 'required|max:100|integer';\n $rules['hips'] = 'required|max:100|integer';\n $rules['motto'] = 'max:50';\n\n return $rules;\n }", "protected function getValidRules()\n {\n return $this->validRules;\n }", "public function rules()\n {\n switch($this->method())\n {\n case 'GET':\n case 'DELETE':\n {\n return [];\n }\n case 'POST':\n case 'PUT':\n {\n return [\n 'name' => 'required',\n ];\n }\n default:break;\n }\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'GET':\n case 'POST':\n {\n return [\n 'mobile' => ['required','max:11','min:11'],\n 'code' => ['required','max:6','min:6'],\n 'avatar' => ['required'],\n 'wx_oauth' => ['required'],\n 'password' => ['nullable','min:6','max:20']\n ];\n }\n case 'PUT':\n case 'PATCH':\n case 'DELETE':\n default: {\n return [];\n }\n }\n }", "public function rules()\n {\n switch ($this->getRequestMethod()) {\n case 'index':\n return [\n 'full_name' => 'nullable|string',\n 'phone' => 'nullable|string',\n ];\n break;\n case 'store':\n return [\n 'crm_resource_id' => 'required|exists:crm_resources,id',\n 'channel' => 'required|in:' . get_validate_in_string(CrmResourceCallLog::$channel),\n 'call_status' => 'required|in:' . get_validate_in_string(CrmResourceCallLog::$call_statuses),\n ];\n break;\n default:\n return [];\n break;\n }\n }", "public function rules()\n {\n //With password\n if(request('password') || request('password_confirmation')) {\n return array_merge($this->passwordRules(), $this->defaultRules());\n }\n //Without password\n return $this->defaultRules();\n }", "public function rules()\n {\n $rules = [\n '_token' => 'required'\n ];\n\n foreach($this->request->get('emails') as $key => $val) {\n $rules['emails.'.$key] = 'required|email';\n }\n\n return $rules;\n }", "function getValidationRules() {\n\t\treturn array(\n\t\t\t'_ID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CoverImageID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_TrackID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_Status' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_Rank' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CreateDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t);\n\t}", "public function rules()\n { \n return $this->rules;\n }", "public function getValidationRules()\n {\n if (method_exists($this, 'rules')) {\n return $this->rules();\n }\n\n $table = $this->getTable();\n $cacheKey = 'validate.' . $table;\n\n if (config('validate.cache') && Cache::has($cacheKey)) {\n return Cache::get($cacheKey);\n }\n\n // Get table info for model and generate rules\n $manager = DB::connection()->getDoctrineSchemaManager();\n $details = $manager->listTableDetails($table);\n $foreignKeys = $manager->listTableForeignKeys($table);\n\n $this->generateRules($details, $foreignKeys);\n\n if (config('validate.cache')) {\n Cache::forever($cacheKey, $this->rules);\n }\n\n return $this->rules;\n }", "public function getValidationRules()\n {\n $rules = $this->getBasicValidationRules();\n\n if (in_array($this->type, ['char', 'string', 'text', 'enum'])) {\n $rules[] = 'string';\n if (in_array($this->type, ['char', 'string']) && isset($this->arguments[0])) {\n $rules[] = 'max:' . $this->arguments[0];\n }\n } elseif (in_array($this->type, ['timestamp', 'date', 'dateTime', 'dateTimeTz'])) {\n $rules[] = 'date';\n } elseif (str_contains(strtolower($this->type), 'integer')) {\n $rules[] = 'integer';\n } elseif (str_contains(strtolower($this->type), 'decimal')) {\n $rules[] = 'numeric';\n } elseif (in_array($this->type, ['boolean'])) {\n $rules[] = 'boolean';\n } elseif ($this->type == 'enum' && count($this->arguments)) {\n $rules[] = 'in:' . join(',', $this->arguments);\n }\n\n return [$this->name => join('|', $rules)];\n }", "public function rules()\n {\n $rules = [];\n if ($this->isMethod('post')) {\n $rules = [\n 'vacancy_name' => 'required|string|min:4|max:20',\n 'workers_amount' => 'required|integer|min:1|max:10',\n 'organization_id'=> 'required|integer|exists:organizations,id',\n 'salary' => 'required|integer|min:1|max:10000000',\n ];\n } elseif ($this->isMethod('put')) {\n $rules = [\n 'vacancy_name' => 'required|string|min:4|max:20',\n 'workers_amount' => 'required|integer|min:1|max:10',\n 'organization_id'=> 'required|integer|exists:organizations,id',\n 'salary' => 'required|integer|min:1|max:10000000',\n ];\n }\n return $rules;\n }", "public function validationRules()\n {\n return [];\n }", "public function rules()\n {\n $rules = $this->rules;\n if(Request::isMethod('PATCH')){\n $rules['mg_name'] = 'required|min:2,max:16';\n }\n return $rules;\n }", "function getValidationRules() {\n\t\treturn array(\n\t\t\t'_ID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_EventID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_SourceID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_UserID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_HasEvent' => array(\n\t\t\t\t'inArray' => array('values' => array(self::HASEVENT_0, self::HASEVENT_1),),\n\t\t\t),\n\t\t);\n\t}", "public function rules()\n {\n $rules = [];\n switch ($this->method()){\n case 'GET':\n $rules['mobile'] = ['required', 'regex:/^1[3456789]\\d{9}$/'];\n break;\n case 'POST':\n if($this->route()->getActionMethod() == 'sms') {\n $rules['area_code'] = ['digits_between:1,6'];\n if(in_array($this->get('type'), ['signup', 'reset_pay_pwd'])) {\n $rules['mobile'] = ['required', 'digits_between:5,20'];\n if($this->get('type') == 'signup' && !$this->get('area_code')) {\n $this->error('请选择区号');\n }\n }\n $rules['type'] = ['required', Rule::in(\\App\\Models\\Captcha::getSmsType())];\n }\n break;\n }\n return $rules;\n }", "public function rules()\n {\n if ($this->isMethod('post')) {\n return $this->createRules();\n } elseif ($this->isMethod('put')) {\n return $this->updateRules();\n }\n }", "public function rules()\n {\n $rules = [\n 'first_name' => ['required'],\n 'birthdate' => ['required', 'date', 'before:today'],\n ];\n\n if (is_international_session()) {\n $rules['email'] = ['required', 'email'];\n }\n\n if (should_collect_international_phone()) {\n $rules['phone'] = ['phone'];\n }\n\n if (is_domestic_session()) {\n $rules['phone'] = ['required', 'phone'];\n }\n\n return $rules;\n }", "public function rules()\n {\n dd($this->request->get('answer'));\n foreach ($this->request->get('answer') as $key => $val)\n {\n $rules['answer.'.$key] = 'required';\n }\n\n return $rules;\n }", "public function rules()\n {\n return static::$rules;\n }", "function getRules() {\n\t\t$fields = $this->getFields();\n\t\t$allRules = array();\n\n\t\tforeach ($fields as $field) {\n\t\t\t$fieldRules = $field->getValidationRules();\n\t\t\t$allRules[$field->getName()] = $fieldRules;\n\t\t}\n\n\t\treturn $allRules;\n\t}", "public static function getValidationRules(): array\n {\n return [\n 'name' => 'required|string|min:1|max:255',\n 'version' => 'required|float',\n 'type' => 'required|string',\n ];\n }", "public function rules()\n {\n $rules = [\n 'name' => 'required',\n 'phone' => 'required|numeric',\n 'subject' => 'required',\n 'message' => 'required',\n 'email' => 'required|email',\n ];\n\n return $rules;\n }", "public function getValidationRules(): array\n {\n return [\n 'email_address' => 'required|email',\n 'email_type' => 'nullable|in:html,text',\n 'status' => 'required|in:subscribed,unsubscribed,cleaned,pending',\n 'merge_fields' => 'nullable|array',\n 'interests' => 'nullable|array',\n 'language' => 'nullable|string',\n 'vip' => 'nullable|boolean',\n 'location' => 'nullable|array',\n 'location.latitude' => ['regex:/^[-]?(([0-8]?[0-9])\\.(\\d+))|(90(\\.0+)?)$/'], \n 'location.longitude' => ['regex:/^[-]?((((1[0-7][0-9])|([0-9]?[0-9]))\\.(\\d+))|180(\\.0+)?)$/'],\n 'marketing_permissions' => 'nullable|array',\n 'tags' => 'nullable|array'\n ];\n }", "protected function getValidationRules()\n {\n return [\n 'first_name' => 'required|max:255',\n 'last_name' => 'required|max:255',\n 'email' => 'required|email|max:255',\n 'new_password' => 'required_with:current_password|confirmed|regex:' . config('security.password_policy'),\n ];\n }", "public function rules()\n {\n // get 直接放行\n if( request()->isMethod('get') ){\n return []; // 规则为空\n }\n\n // 只在post的时候做验证\n return [\n 'username' => 'required|min:2|max:10', \n 'password' => 'required|min:2|max:10', \n 'email' => 'required|min:2|max:10|email', \n 'phoneNumber' => 'required|min:2|max:10', \n\n ];\n }", "public function rules()\n {\n\n $rules = [\n 'id_tecnico_mantenimiento' => 'required',\n 'id_equipo_mantenimiento' => 'required'\n ];\n\n if ($this->request->has('status')) {\n $rules['status'] = 'required';\n }\n\n if ($this->request->has('log_mantenimiento')) {\n $rules['log_mantenimiento'] = 'required';\n }\n\n return $rules;\n }", "public function rules()\n {\n $this->buildRules();\n return $this->rules;\n }", "public function rules()\n {\n $rules = [];\n\n if ($this->isUpdate() || $this->isStore()) {\n $rules = array_merge($rules, [\n 'name' => 'required|string',\n 'email' => 'email',\n 'password' => 'confirmed|min:6',\n\n ]);\n }\n\n if ($this->isStore()) {\n $rules = array_merge($rules, [\n\n ]);\n }\n\n if ($this->isUpdate()) {\n $rules = array_merge($rules, [\n ]);\n }\n\n return $rules;\n }", "public function rules()\n {\n switch (true) {\n case $this->wantsToList():\n $rules = $this->listRules;\n break;\n case $this->wantsToStore():\n $rules = $this->storeRules;\n break;\n case $this->wantsToUpdate():\n $this->storeRules['email'] = 'required|email|between:5,100|unique:users,email,' . $this->route('administrators');\n\n $rules = $this->storeRules;\n break;\n default:\n $rules = [];\n }\n\n return $rules;\n }", "public function rules()\n {\n if($this->isMethod('post')) {\n return $this->storeRules();\n }\n else if($this->isMethod('put') || $this->isMethod('patch')){\n return $this->updateRules();\n }\n }", "abstract protected function getValidationRules();", "public function rules()\n\t{\n\t\treturn ModelHelper::getRules($this);\n\t}", "public function rules()\n {\n switch ($this->method()) {\n case 'POST':\n return $this->getPostRules();\n case 'PUT':\n return $this->getPutRules();\n }\n }", "public function rules()\n {\n $rules = [\n 'name' => 'required|string|min:2',\n 'email' => \"required|email|unique:users,email, {$this->request->get('user_id')}\",\n 'role_id' => 'required|numeric',\n 'group_id' => 'required|numeric',\n ];\n\n if ($this->request->has('password')){\n $rules['password'] = 'required|min:6';\n }\n\n return $rules;\n }", "public function rules()\n {\n if($this->method() == 'POST')\n {\n return [\n 'reason'=>'required',\n 'date_from'=>'required',\n 'date_to'=>'required',\n 'attachment'=>'required',\n ];\n }\n }", "public function rules()\n {\n $method = $this->method();\n if ($this->get('_method', null) !== null) {\n $method = $this->get('_method');\n }\n // $this->offsetUnset('_method');\n switch ($method) {\n case 'DELETE':\n case 'GET':\n break; \n case 'POST':\n $mailRules = \\Config::get('database.default').'.users';\n break;\n case 'PUT':\n $user = $this->authService->authJWTUserForm();\n $mailRules = \\Config::get('database.default').'.users,email,'.$user->getKey();\n break;\n case 'PATCH':\n break;\n default:\n break;\n }\n \n return [\n 'name' => 'required|string|max:256',\n 'email' => 'required|string|email|max:255|unique:'.$mailRules,\n 'password' => 'required|string|min:3',\n ];\n }", "public function rules() {\n $rule = [\n 'value' => 'bail|required',\n ];\n if ($this->getMethod() == 'POST') {\n $rule += ['type' => 'bail|required'];\n }\n return $rule;\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'GET':\n case 'DELETE': {\n return [];\n }\n case 'POST': {\n return [\n 'from' => 'required|max:100',\n 'to' => 'required|max:500',\n 'day' => 'required|max:500',\n ];\n }\n case 'PUT':\n case 'PATCH': {\n return [\n 'from' => 'required|max:100',\n 'to' => 'required|max:500',\n 'day' => 'required|max:500',\n ];\n }\n default:\n break;\n }\n\n return [\n //\n ];\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'GET':\n case 'DELETE': {\n return [];\n }\n case 'POST':\n case 'PUT':\n case 'PATCH': {\n return [\n 'name' => 'required|string|max:255',\n 'iso_code_2' => 'required|string|size:2',\n 'iso_code_3' => 'required|string|size:3',\n ];\n }\n default:\n return [];\n }\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'GET':\n case 'DELETE':\n return [];\n case 'POST':\n return [\n 'name' => 'required|string',\n 'lastName' => 'string',\n 'gender' => 'boolean',\n 'avatar' => 'sometimes|mimes:jpg,png,jpeg|max:3048'\n ];\n case 'PUT':\n case 'PATCH':\n return [\n 'oldPassword' => 'required|string',\n 'newPassword' => 'required|string',\n ];\n default:\n break;\n }\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'GET':\n case 'DELETE':\n {\n return [\n 'validation' => [\n 'accepted'\n ]\n ];\n }\n case 'POST':\n {\n return [\n 'title' => [\n 'required',\n 'string',\n 'min:3',\n 'max:250'\n ],\n 'body' => [\n 'required',\n 'string',\n 'min:3',\n 'max:250000'\n ],\n 'online' => [\n 'required',\n ],\n 'indexable' => [\n 'required',\n ],\n 'published_at' => [\n 'required',\n ],\n 'published_at_time' => [\n 'required',\n ],\n 'unpublished_at' => [\n 'nullable',\n ],\n 'unpublished_time' => [\n 'nullable',\n ],\n ];\n }\n case 'PUT':\n {\n return [\n 'title' => [\n 'required',\n 'string',\n 'min:3',\n 'max:250'\n ],\n 'body' => [\n 'required',\n 'string',\n 'min:3',\n 'max:250000'\n ],\n 'online' => [\n 'required',\n ],\n 'indexable' => [\n 'required',\n ],\n 'published_at' => [\n 'required',\n ],\n 'unpublished_at' => [\n 'nullable',\n ],\n ];\n }\n case 'PATCH':\n {\n return [];\n }\n default:\n break;\n }\n }", "public function rules()\n {\n if (in_array($this->method(), ['PUT', 'PATCH'])) {\n $user = User::findOrFail(\\Request::input('id'))->first();\n\n array_forget($this->rules, 'email');\n $this->rules = array_add($this->rules, 'email', 'required|email|max:255|unique:users,email,' . $user->id);\n }\n\n return $this->rules;\n }", "public function rules()\n {\n $method = explode('@', $this->route()->getActionName())[1];\n return $this->get_rules_arr($method);\n }", "public function rules()\n {\n $rules = parent::rules();\n $extra_rules = [];\n $rules = array_merge($rules, $extra_rules);\n return $rules;\n }", "public function rules()\n {\n\t\tswitch($this->method()) {\n\t\t\tcase 'POST':\n\t\t\t\t{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'field_id' => 'integer|required',\n\t\t\t\t\t\t'label' => 'string|required',\n\t\t\t\t\t\t'value' => 'alpha_dash|required',\n\t\t\t\t\t\t'selected' => 'boolean',\n\t\t\t\t\t\t'actif' => 'boolean',\n\t\t\t\t\t];\n\t\t\t\t}\n\t\t\tcase 'PUT':\n\t\t\t\t{\n\t\t\t\t\treturn [\n\t\t\t\t\t\t'field_id' => 'integer|required',\n\t\t\t\t\t\t'label' => 'string|required',\n\t\t\t\t\t\t'value' => 'alpha_dash|required',\n\t\t\t\t\t\t'selected' => 'boolean',\n\t\t\t\t\t\t'actif' => 'boolean',\n\t\t\t\t\t];\n\t\t\t\t}\n\t\t\tdefault:break;\n\t\t}\n }", "public function rules()\n {\n $this->sanitize();\n return [\n 'event_id' => 'required',\n 'member_id' => 'required',\n 'guild_pts' => 'required',\n 'position' => 'required',\n 'solo_pts' => 'required',\n 'league_id' => 'required',\n 'solo_rank' => 'required',\n 'global_rank' => 'required',\n ];\n }", "public function rules()\n {\n $this->rules['email'] = ['required', 'min:6', 'max:60', 'email'];\n $this->rules['password'] = ['required', 'min:6', 'max:60'];\n\n return $this->rules;\n }", "public function getValidatorRules()\n {\n if ($validator = $this->getValidator()) {\n return $validator->getRulesForField($this->owner);\n }\n \n return [];\n }", "public function getValidationRules() : array;", "public function rules()\n {\n switch ($this->route()->getActionMethod()) {\n case 'login': {\n if ($this->request->has('access_token')) {\n return [\n 'access_token' => 'required',\n 'driver' => 'required|in:facebook,github,google',\n ];\n }\n return [\n 'email' => 'required|email',\n 'password' => 'required|min:6',\n ];\n }\n case 'register': {\n return [\n 'email' => 'required|email|unique:users,email',\n 'password' => 'required|min:6',\n 'name' => 'required',\n ];\n }\n default: return [];\n }\n }", "public function rules()\n {\n Validator::extend('mail_address_available', function($attribute, $value, $parameters, $validator){\n return MailAddressSpec::isAvailable($value);\n });\n Validator::extend('password_available', function($attribute, $value, $parameters, $validator){\n return PassWordSpec::isAvailable($value);\n });\n\n return [\n 'mail_address' => [\n 'required',\n 'mail_address_available'\n ],\n 'password' => [\n 'required',\n 'password_available',\n ],\n ];\n }", "public function rules()\n {\n switch (strtolower($this->method())) {\n case 'get':\n return $this->getMethodRules();\n case 'post':\n return $this->postMethodRules();\n case 'put':\n return $this->putMethodRules();\n case 'patch':\n return $this->patchMethodRules();\n case 'delete':\n return $this->deleteMethodRules();\n }\n }", "public function rules()\n {\n /**\n * This is the original way, expecting post params for each user value\n */\n return [\n 'firstName' => 'required|min:2|max:255',\n 'lastName' => 'required|min:2|max:255',\n 'phone' => 'min:9|max:25',\n 'gender' => 'in:M,V',\n 'dateOfBirth' => 'before:today|after:1890-01-01',\n 'email' => 'email|min:12|max:255',\n ];\n }", "public function getValidationRules(): array {\n\t\t$result = [];\n\t\t\n\t\tforeach ($this->getSections() as $section) {\n\t\t\t$result = array_merge($result, $section->getValidationRules());\n\t\t}\n\t\t\n\t\treturn $result;\n\t}", "public function rules()\n\t{\n\t\t$rule = [];\n\t\tif(Request::path() == 'api/utility/upload-image'){\n\t\t\t$rule = [\n\t\t\t\t'imagePath' => 'required',\n\t\t\t];\n\t\t}else if(Request::path() == 'api/utility/check-transaction'){\n\t\t\t$rule = [\n\t\t\t\t'countNumber' => 'required',\n\t\t\t];\n\t\t}\n\t\treturn $rule;\n\t}", "public function rules()\n {\n $rules = array();\n return $rules;\n }", "public function rules()\n {\n $this->setValidator($this->operation_type);\n return $this->validator;\n }", "public function rules()\n {\n switch($this->method()){\n case 'POST':\n return [\n 'name' => 'required',\n 'app_id' => 'required',\n 'account_id' => 'required',\n 'start_at' => 'required',\n 'end_at' => 'required',\n 'content' => 'required',\n ];\n break;\n default:\n return [];\n break;\n }\n\n }", "protected function get_validation_rules()\n {\n }", "public function rules()\n {\n $rules = [\n 'users' => 'required|array',\n ];\n\n foreach($this->request->get('users') as $key => $user) {\n $rules['users.'. $key . '.name'] = 'required|string|min:3|max:255';\n $rules['users.'. $key . '.phone'] = 'required|regex:/^[0-9\\+\\s]+$/|min:10|max:17';\n $rules['users.'. $key . '.country'] = 'required|string|min:2:max:3';\n }\n\n return $rules;\n }", "public function rules()\n {\n $rules = [\n 'mail_driver' => 'required',\n 'mail_name' => 'required',\n 'mail_email' => 'required',\n ];\n\n $newRules = [];\n\n if($this->mail_driver == 'smtp') {\n $newRules = [\n 'mail_host' => 'required',\n 'mail_port' => 'required|numeric',\n 'mail_username' => 'required',\n 'mail_password' => 'required',\n 'mail_encryption' => 'required',\n ];\n }\n\n return array_merge($rules, $newRules);\n }", "public function rules()\n {\n $rules['name'] = 'required';\n $rules['poa'] = 'required';\n $rules['background'] = 'required';\n $rules['tester_name'] = 'required';\n $rules['location'] = 'required';\n $rules['end_recruit_date'] = 'required';\n $rules['time_taken'] = 'required';\n $rules['payment'] = 'required';\n $rules['objective'] = 'required';\n $rules['method_desc'] = 'required';\n $rules['health_condition'] = 'required';\n $rules['required_applicant'] = 'required|integer';\n $rules['applicant'] = 'nullable';\n $rules['datetime'] = 'required';\n\n return $rules;\n }", "public function rules()\n {\n switch($this->method()) {\n\n case 'PUT':\n {\n return [\n 'company_name' => 'required',\n 'status' => 'required|integer',\n 'notify_url' => 'required',\n 'name' => 'required'\n ];\n }\n case 'POST':\n {\n return [\n 'company_name' => 'required',\n 'status' => 'required|integer',\n 'notify_url' => 'required',\n 'name' => 'required'\n ];\n }\n default:\n return [];\n }\n\n }", "public function rules()\n {\n $rules['name'] = 'required';\n $rules['poa'] = 'required';\n $rules['background'] = 'required';\n $rules['tester_name'] = 'required';\n\n return $rules;\n }", "public function rules()\n {\n switch(Route::currentRouteName()){\n case 'adminBinding' :\n return [\n 'order_id' => 'required|integer',\n 'money' => 'required|numeric',\n ];\n case 'adminUnbinding' :\n return [\n 'order_id' => 'required|integer',\n 'pivot_id' => 'required|integer',\n ];\n case 'adminReceiptSave' :\n case 'adminReceiptUpdate' :\n return [\n 'customer_id' => 'required',\n 'receiptcorp' => 'required',\n 'account' => 'required',\n 'account_id' => 'required',\n 'bank' => 'required',\n 'currency_id' => 'required',\n 'advance_amount' => 'required|numeric',\n 'picture' => 'required',\n 'business_type' => 'required|in:1,2,3,4,5',\n 'exchange_type' => 'required_unless:currency_id,354|in:1,2',\n 'expected_received_at' => 'required|date_format:Y-m-d',\n ];\n case 'adminReceiptExchange' :\n return [\n 'rate' => 'required|numeric',\n ];\n default :\n return [];\n }\n }", "public function rules()\n {\n $rules = [];\n $method = $this->getMethod();\n switch ($method) {\n case 'GET':\n if (Route::currentRouteName() === 'schoolActivity.getSchoolActivity') {\n $rules = [\n ];\n }\n break;\n }\n return $rules;\n }", "public function rules()\n {\n $rules = new Collection();\n\n if (!$this->user() or !$this->user()->addresses()->count()) {\n $rules = $rules->merge($this->addressRules('billing'));\n if ($this->has('different_shipping_address')) {\n $rules = $rules->merge($this->addressRules('shipping'));\n }\n\n return $rules->toArray();\n }\n\n return $rules->merge([\n 'billing_address_id' => 'required|numeric',\n 'shipping_address_id' => 'required|numeric',\n ])->toArray();\n }", "public function rules(): array\n {\n switch ($this->method()) {\n case 'POST':\n return $this->__rules() + $this->__post();\n case 'PUT':\n return $this->__rules() + $this->__put();\n default:\n return [];\n }\n }", "public function defineValidationRules()\n {\n return [];\n }", "public function rules(Request $request)\n {\n return Qc::$rules;\n }", "public function rules()\n {\n switch ($this->method()) {\n case 'POST':\n return [\n 'user_name' => 'nullable|string',\n 'excel' => 'nullable|file|mimes:xlsx',\n 'category' => 'required|int|in:' . implode(',', array_keys(UserMessage::$categories)),\n 'content' => 'required|string|max:500',\n 'member_status' => 'required|int|in:' . implode(',', array_keys(User::$statuses)),\n ];\n break;\n }\n }", "public function rules()\n {\n return [\n 'lead_id' => [\n 'required', 'string',\n ],\n 'api_version' => [\n 'required', 'string',\n ],\n 'form_id' => [\n 'required', 'int',\n ],\n 'campaign_id' => [\n 'required', 'int',\n ],\n 'google_key' => [\n 'required', 'string', new GoogleKeyRule,\n ],\n ];\n }" ]
[ "0.8342703", "0.80143493", "0.7937251", "0.79264987", "0.79233825", "0.79048395", "0.78603816", "0.7790699", "0.77842164", "0.77628785", "0.7737272", "0.7733618", "0.7710535", "0.7691693", "0.76849866", "0.7683038", "0.7683038", "0.7683038", "0.7683038", "0.7683038", "0.7683038", "0.7675849", "0.76724476", "0.76665044", "0.7657698", "0.7641827", "0.7630892", "0.76293766", "0.7617708", "0.76102096", "0.7607475", "0.7602442", "0.7598732", "0.7597544", "0.75924", "0.75915384", "0.7588146", "0.7581354", "0.7555758", "0.755526", "0.7551423", "0.7546329", "0.7541439", "0.75366044", "0.75363225", "0.7530296", "0.7517988", "0.75155175", "0.7508439", "0.75069886", "0.7505724", "0.749979", "0.7495976", "0.74949056", "0.7492888", "0.7491117", "0.74901396", "0.7489651", "0.7486808", "0.7486108", "0.7479687", "0.7478561", "0.7469412", "0.74635684", "0.74619836", "0.7461325", "0.74591017", "0.7455279", "0.745352", "0.7453257", "0.7449877", "0.74486", "0.7441391", "0.7440429", "0.7435489", "0.7435326", "0.74341524", "0.7430354", "0.7429103", "0.7423808", "0.741936", "0.74152505", "0.7414828", "0.741382", "0.74126065", "0.74105227", "0.740555", "0.7404385", "0.74040926", "0.74015605", "0.73905706", "0.73837525", "0.73732615", "0.7371123", "0.7369176", "0.73619753", "0.73554605", "0.73448825", "0.7344659", "0.73427117", "0.73357755" ]
0.0
-1
Get the error messages for the defined validation rules.
public function messages() { return [ 'menu-validity-start.required' => 'Začátek platnosti menu musí být uveden.', 'menu-validity-end.required' => 'Konec platnosti menu musí být uveden.', 'menu-name.required' => 'Název menu musí být uveden.', 'menu-soup.required' => 'Polévka musí být vybrána.', 'menu-meal-1.required' => 'Alespoň jedno jídlo musí být vybráno.', 'menu-soup.not_in' => "Polévka musí být vybrána.", 'menu-meal-1.not_in' => 'Jídlo 1 musí být vybráno.' ]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getValidationMessages();", "public function errorMessages()\n {\n return [\n self::RULE_REQUIRED => 'This field is required',\n self::RULE_EMAIL => 'This field must be a valid email address',\n self::RULE_MIN => 'Min length of this field must be {min}',\n self::RULE_MAX => 'Max length of this field must be {max}',\n self::RULE_MATCH => 'This field must be the same as {match}',\n self::RULE_UNIQUE => 'Record with this {field} already exists'\n ];\n }", "public function getValidationErrorMessages() {}", "public function getValidationMessages()\n {\n return $this->validationMessages;\n }", "public function errorMessages() : array\n {\n return [\n self::RULE_REQUIRED => 'Required.',\n self::RULE_EMAIL => 'Must be a valid email address.',\n self::RULE_MIN => 'Must be at least {min} characters.',\n self::RULE_MAX => 'Must be less than {max} characters.',\n self::RULE_MATCH => 'Must match {match}.',\n self::RULE_UNIQUE => '{column} is already in use.'\n ];\n }", "protected function validationErrorMessages()\n {\n return [];\n }", "protected function validationErrorMessages()\n {\n return [];\n }", "public function getErrorMessages() {}", "public function getValidatorMessages()\n {\n $messages = [];\n \n foreach ($this->owner->getValidatorRules() as $rule) {\n \n if ($rule->hasMessage()) {\n $messages[$rule->getType()] = $rule->getMessage();\n }\n \n }\n \n return $messages;\n }", "public function messages()\n {\n return VALIDATION_MESSAGE;\n }", "public function messages()\n {\n return VALIDATION_MESSAGE;\n }", "public function errors()\n {\n return $this->getRules()->getMessageBag()->all();\n }", "public function get_validation_messages() {\n\t\t$field = $this->field;\n\t\t$id = $this->get_id( $field );\n\t\t$is_required = $this->is_required( $field );\n\t\t$messages = '';\n\n\t\t$post_title = self::get_property( 'post_title', $field, '' );\n\t\t$post_content = self::get_property( 'post_content', $field, '' );\n\t\t$post_excerpt = self::get_property( 'post_excerpt', $field, '' );\n\t\t$post_image = self::get_property( 'post_image', $field, '' );\n\t\t$setting_required_message = self::get_property( 'required_message', $field, '' );\n\t\t$post_type = self::get_property( 'post_type', $field, 'post' );\n\n\t\t$post_title_enabled = ! empty( $post_title );\n\t\t$post_content_enabled = ! empty( $post_content );\n\t\t$post_excerpt_enabled = ! empty( $post_excerpt );\n\t\t$post_image_enabled = ! empty( $post_image );\n\t\t$category_list = forminator_post_categories( $post_type );\n\n\t\tif ( $is_required ) {\n\t\t\tif ( $post_title_enabled ) {\n\t\t\t\t$messages .= '\"' . $id . '-post-title\": {' . \"\\n\";\n\n\t\t\t\t$required_message = apply_filters(\n\t\t\t\t\t'forminator_postdata_field_post_title_validation_message',\n\t\t\t\t\t( ! empty( $setting_required_message ) ? $setting_required_message : __( 'This field is required. Please enter the post title', Forminator::DOMAIN ) ),\n\t\t\t\t\t$id,\n\t\t\t\t\t$field\n\t\t\t\t);\n\t\t\t\t$messages = $messages . '\"required\": \"' . forminator_addcslashes( $required_message ) . '\",' . \"\\n\";\n\n\t\t\t\t$messages .= '},' . \"\\n\";\n\t\t\t}\n\t\t\tif ( $post_content_enabled ) {\n\t\t\t\t$messages .= '\"' . $id . '-post-content\": {' . \"\\n\";\n\n\t\t\t\t$required_message = apply_filters(\n\t\t\t\t\t'forminator_postdata_field_post_content_validation_message',\n\t\t\t\t\t( ! empty( $setting_required_message ) ? $setting_required_message : __( 'This field is required. Please enter the post content', Forminator::DOMAIN ) ),\n\t\t\t\t\t$id,\n\t\t\t\t\t$field\n\t\t\t\t);\n\t\t\t\t$messages = $messages . '\"required\": \"' . forminator_addcslashes( $required_message ) . '\",' . \"\\n\";\n\n\t\t\t\t$messages .= '},' . \"\\n\";\n\t\t\t}\n\t\t\tif ( $post_excerpt_enabled ) {\n\t\t\t\t$messages .= '\"' . $id . '-post-excerpt\": {' . \"\\n\";\n\n\t\t\t\t$required_message = apply_filters(\n\t\t\t\t\t'forminator_postdata_field_post_excerpt_validation_message',\n\t\t\t\t\t( ! empty( $setting_required_message ) ? $setting_required_message : __( 'This field is required. Please enter the post excerpt', Forminator::DOMAIN ) ),\n\t\t\t\t\t$id,\n\t\t\t\t\t$field\n\t\t\t\t);\n\t\t\t\t$messages = $messages . '\"required\": \"' . forminator_addcslashes( $required_message ) . '\",' . \"\\n\";\n\n\t\t\t\t$messages .= '},' . \"\\n\";\n\t\t\t}\n\t\t\tif ( $post_image_enabled ) {\n\t\t\t\t$messages .= '\"' . $id . '-post-image\": {' . \"\\n\";\n\n\t\t\t\t$required_message = apply_filters(\n\t\t\t\t\t'forminator_postdata_field_post_image_validation_message',\n\t\t\t\t\t( ! empty( $setting_required_message ) ? $setting_required_message : __( 'This field is required. Please upload a post image', Forminator::DOMAIN ) ),\n\t\t\t\t\t$id,\n\t\t\t\t\t$field\n\t\t\t\t);\n\t\t\t\t$messages = $messages . '\"required\": \"' . forminator_addcslashes( $required_message ) . '\",' . \"\\n\";\n\n\t\t\t\t$messages .= '},' . \"\\n\";\n\t\t\t}\n\t\t\tif( ! empty( $category_list ) ) {\n\t\t\t\tforeach ( $category_list as $category ) {\n\t\t\t\t\t$post_category_enabled = self::get_property( $category['value'], $field, '' );\n\t\t\t\t\tif ( $post_category_enabled ) {\n\t\t\t\t\t\t$post_category_multiple = self::get_property( $category['value'].'_multiple', $field, '' );\n\t\t\t\t\t\tif( $post_category_multiple ){\n\t\t\t\t\t\t\t$messages .= '\"' . $id . '-' . $category['value'] . '[]\": {' . \"\\n\";\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$messages .= '\"' . $id . '-' . $category['value'] . '\": {' . \"\\n\";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$required_message = apply_filters(\n\t\t\t\t\t\t\t'forminator_postdata_field_' . $category['value'] . '_validation_message',\n\t\t\t\t\t\t\t( ! empty( $setting_required_message ) ? $setting_required_message : __( 'This field is required. Please select a '. $category['singular'], Forminator::DOMAIN ) ),\n\t\t\t\t\t\t\t$id,\n\t\t\t\t\t\t\t$field\n\t\t\t\t\t\t);\n\t\t\t\t\t\t$messages = $messages . '\"required\": \"' . forminator_addcslashes( $required_message ) . '\",' . \"\\n\";\n\n\t\t\t\t\t\t$messages .= '},' . \"\\n\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $messages;\n\t}", "public function validation_errors()\n\t{\n\t\t$errors = array();\n\n\t\tforeach ($this->validators as $fld=>$arr)\n\t\t{\n\t\t\tforeach ($arr as $vl)\n\t\t\t{\n\t\t\t\t$vl->page = $this;\n\n\t\t\t\tif (!$vl->validate($fld, $this->vars))\n\t\t\t\t{\n\t\t\t\t\t$errors[$fld] = $vl->error_message($fld, $this->vars);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $errors;\n\t}", "public function errors()\n {\n return $this->validation->messages()->messages();\n }", "public function getErrors()\n {\n return $this->getInputFilter()->getMessages();\n }", "public function getErrorMessages() {\n\t\t$errorMessages = '';\n\t\tforeach ($this->errorMessages as $index => $error) {\n\t\t\t$errorMessages .= \"[Error:\" . $index . '] ' . $error . \"\\n<br />\";\n\t\t}\n\t\treturn $errorMessages;\n\t}", "public static function getMessageRule(){\n return [\n 'title.required' => 'Please input the title',\n 'cat_id.required' => 'Please chose a category',\n 'country_id.required' => 'Please chose a country',\n ];\n }", "public function getValidationErrors();", "public function getValidationErrors();", "public function getErrorMessages()\n {\n return $this->errorMessages;\n }", "public function messages()\n {\n return [\n 'started_at.required_if' => __('validation.required'),\n 'ended_at.required_if' => __('validation.required'),\n 'subject_id.required_if' => __('validation.required'),\n 'competency.required_if' => __('validation.required'),\n 'learning_goals.required_if' => __('validation.required'),\n 'behavior.required_if' => __('validation.required'),\n ];\n }", "public function get_error_messages();", "function getMessages() {\n\t\t$fields = $this->getFields();\n\t\t$allMessages = array();\n\n\t\tforeach ($fields as $field) {\n\t\t\t$fieldMessages = $field->getValidationMessages();\n\t\t\tif ($fieldMessages) {\n\t\t\t\t$allMessages[$field->getName()] = $fieldMessages;\n\t\t\t}\n\n\t\t}\n\n\t\treturn $allMessages;\n\t}", "public function getErrorMessage()\n {\n return $this->validator->errors()->all();\n }", "public function getErrorMessages()\n {\n $errors = [];\n foreach ($this->fields as $field) {\n if ($field instanceof AbstractFormField && !$field->isValid()) {\n $fldErrors = $field->getErrorMessages();\n $errors = array_merge($errors, $fldErrors);\n }\n }\n\n return $errors;\n }", "public function errors()\n {\n return $this->validator->errors()->messages();\n }", "public function getErrorMessages() : array\n {\n return $this->errors_messages;\n }", "public function getMessages()\n {\n return $this->_errorMessages;\n }", "public function getMandatoryValidationMessages() {}", "public function getValidationErrors()\n {\n $fields = $this->getFields();\n if (!$fields) {\n return [];\n }\n\n $result = [];\n foreach ($fields as $field) {\n if ($field instanceof AbstractFormField) {\n if (!$field->isValid()) {\n $result = array_merge($result, $field->getErrorMessages());\n }\n }\n }\n\n return $result;\n }", "protected function validationErrorMessages()\n {\n return [\n 'password.required' => trans('strings.request_password_required'),\n 'password.confirmed' => trans('strings.request_password_confirmed'),\n 'password.min' => trans('strings.request_password_min', ['chars' => config('db_limits.users.minPasswordLength')]),\n ];\n }", "protected function getValidationErrors()\n {\n return $this->validation->errors();\n }", "protected function getValidationRules()\n {\n $rules = [\n 'title' => 'required|min:3|max:255',\n ];\n\n return $rules;\n }", "public function messages()\n {\n return [\n 'file.required' => trans('validation.downloadable_required'),\n 'category_list.required' => trans('validation.category_list_required'),\n ];\n }", "public function getMessages()\n {\n foreach (parent::getMessages() as $message) {\n switch ($message->getType()) {\n case 'PresenceOf':\n $message->setMessage('The field ' . $message->getField() . ' is required');\n break;\n case 'Uniqueness':\n $message->setMessage('The field ' . $message->getField() . ' must be unique');\n break;\n case 'Email':\n $message->setMessage('The field ' . $message->getField() . ' must contain a valid email');\n break;\n case 'Url':\n $message->setMessage('The field ' . $message->getField() . ' must contain a valid url');\n break;\n case 'InclusionIn':\n $message->setMessage('The field ' . $message->getField() . ' must contain a value in [' . implode(',', $message->getDomain()) . ']');\n break;\n case 'DateValidator':\n $message->setMessage('The field ' . $message->getField() . ' must contain a valid date.');\n break;\n case 'TimestampValidator':\n $message->setMessage('The field ' . $message->getField() . ' must contain a valid timestamps.');\n break;\n }\n }\n\n return parent::getMessages();\n }", "public function getValidationErrors() {\n if (true == ($this->validation instanceof Validation)) {\n return $this->validation->getErrors();\n }\n\n return array();\n }", "public function getErrorMessagesList(){\n \t$errors = $this->getMessages();\n \tif(count($errors)){\n \t\t$result = [];\n \t\tforeach ($errors as $elementName => $elementErrors){\n \t\t\tforeach ($elementErrors as $errorMsg){\n \t\t\t\t$result[] = $errorMsg;\n \t\t\t}\n \t\t}\n \t\treturn $result;\n \t}\n \treturn null;\n }", "protected function get_errors_description() {\n $errors = array();\n if ($this->options->is_check_errors == true) {\n\n $i = 0;\n $rules_names = $this->get_error_hints_names();\n\n foreach($rules_names as $rule_name) {\n $rule = new $rule_name($this->get_dst_root());\n $rhr = $rule->check_hint();\n\n if (count($rhr->problem_ids) > 0) {\n $errors[$i] = array();\n\n $errors[$i][\"problem\"] = $rhr->problem;\n $errors[$i][\"solve\"] = $rhr->solve;\n $errors[$i][\"problem_ids\"] = $rhr->problem_ids;\n $errors[$i][\"problem_type\"] = $rhr->problem_type;\n $errors[$i][\"problem_indfirst\"] = $rhr->problem_indfirst;\n $errors[$i][\"problem_indlast\"] = $rhr->problem_indlast;\n\n ++$i;\n }\n }\n }\n return $errors;\n }", "protected function validationErrorMessages()\n {\n return [\n 'password.regex' => 'Password must contain at least 1 uppercase letter and 1 number.',\n ];\n }", "public function customValidationMessages()\n {\n return [\n 'role_id.required' => 'The role ID is required.',\n 'role_id.exists' => 'The role ID provided does not exist.',\n 'staff_code.required' => 'The staff code is required.',\n 'name.required' => 'The name field is required.',\n 'name.max' => 'The name field exceeds the maximum length of 255.',\n 'email.email' => 'Please provide an email address.',\n ];\n }", "public function _getValidationErrors()\n {\n $errs = parent::_getValidationErrors();\n $validationRules = $this->_getValidationRules();\n if ([] !== ($vs = $this->getDataRequirement())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_DATA_REQUIREMENT, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getEncounter())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ENCOUNTER] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getEvaluationMessage())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_EVALUATION_MESSAGE, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getIdentifier())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_IDENTIFIER, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getModuleCanonical())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_MODULE_CANONICAL] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getModuleCodeableConcept())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_MODULE_CODEABLE_CONCEPT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getModuleUri())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_MODULE_URI] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getNote())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_NOTE, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getOccurrenceDateTime())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_OCCURRENCE_DATE_TIME] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getOutputParameters())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_OUTPUT_PARAMETERS] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPerformer())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PERFORMER] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getReasonCode())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_REASON_CODE, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getReasonReference())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_REASON_REFERENCE, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getRequestIdentifier())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_REQUEST_IDENTIFIER] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getResult())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_RESULT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getStatus())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_STATUS] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getSubject())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_SUBJECT] = $fieldErrs;\n }\n }\n if (isset($validationRules[self::FIELD_DATA_REQUIREMENT])) {\n $v = $this->getDataRequirement();\n foreach($validationRules[self::FIELD_DATA_REQUIREMENT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_DATA_REQUIREMENT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_DATA_REQUIREMENT])) {\n $errs[self::FIELD_DATA_REQUIREMENT] = [];\n }\n $errs[self::FIELD_DATA_REQUIREMENT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ENCOUNTER])) {\n $v = $this->getEncounter();\n foreach($validationRules[self::FIELD_ENCOUNTER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_ENCOUNTER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ENCOUNTER])) {\n $errs[self::FIELD_ENCOUNTER] = [];\n }\n $errs[self::FIELD_ENCOUNTER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EVALUATION_MESSAGE])) {\n $v = $this->getEvaluationMessage();\n foreach($validationRules[self::FIELD_EVALUATION_MESSAGE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_EVALUATION_MESSAGE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EVALUATION_MESSAGE])) {\n $errs[self::FIELD_EVALUATION_MESSAGE] = [];\n }\n $errs[self::FIELD_EVALUATION_MESSAGE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IDENTIFIER])) {\n $v = $this->getIdentifier();\n foreach($validationRules[self::FIELD_IDENTIFIER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_IDENTIFIER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IDENTIFIER])) {\n $errs[self::FIELD_IDENTIFIER] = [];\n }\n $errs[self::FIELD_IDENTIFIER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODULE_CANONICAL])) {\n $v = $this->getModuleCanonical();\n foreach($validationRules[self::FIELD_MODULE_CANONICAL] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_MODULE_CANONICAL, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODULE_CANONICAL])) {\n $errs[self::FIELD_MODULE_CANONICAL] = [];\n }\n $errs[self::FIELD_MODULE_CANONICAL][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODULE_CODEABLE_CONCEPT])) {\n $v = $this->getModuleCodeableConcept();\n foreach($validationRules[self::FIELD_MODULE_CODEABLE_CONCEPT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_MODULE_CODEABLE_CONCEPT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODULE_CODEABLE_CONCEPT])) {\n $errs[self::FIELD_MODULE_CODEABLE_CONCEPT] = [];\n }\n $errs[self::FIELD_MODULE_CODEABLE_CONCEPT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODULE_URI])) {\n $v = $this->getModuleUri();\n foreach($validationRules[self::FIELD_MODULE_URI] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_MODULE_URI, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODULE_URI])) {\n $errs[self::FIELD_MODULE_URI] = [];\n }\n $errs[self::FIELD_MODULE_URI][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_NOTE])) {\n $v = $this->getNote();\n foreach($validationRules[self::FIELD_NOTE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_NOTE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_NOTE])) {\n $errs[self::FIELD_NOTE] = [];\n }\n $errs[self::FIELD_NOTE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_OCCURRENCE_DATE_TIME])) {\n $v = $this->getOccurrenceDateTime();\n foreach($validationRules[self::FIELD_OCCURRENCE_DATE_TIME] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_OCCURRENCE_DATE_TIME, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_OCCURRENCE_DATE_TIME])) {\n $errs[self::FIELD_OCCURRENCE_DATE_TIME] = [];\n }\n $errs[self::FIELD_OCCURRENCE_DATE_TIME][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_OUTPUT_PARAMETERS])) {\n $v = $this->getOutputParameters();\n foreach($validationRules[self::FIELD_OUTPUT_PARAMETERS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_OUTPUT_PARAMETERS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_OUTPUT_PARAMETERS])) {\n $errs[self::FIELD_OUTPUT_PARAMETERS] = [];\n }\n $errs[self::FIELD_OUTPUT_PARAMETERS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PERFORMER])) {\n $v = $this->getPerformer();\n foreach($validationRules[self::FIELD_PERFORMER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_PERFORMER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PERFORMER])) {\n $errs[self::FIELD_PERFORMER] = [];\n }\n $errs[self::FIELD_PERFORMER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_REASON_CODE])) {\n $v = $this->getReasonCode();\n foreach($validationRules[self::FIELD_REASON_CODE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_REASON_CODE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_REASON_CODE])) {\n $errs[self::FIELD_REASON_CODE] = [];\n }\n $errs[self::FIELD_REASON_CODE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_REASON_REFERENCE])) {\n $v = $this->getReasonReference();\n foreach($validationRules[self::FIELD_REASON_REFERENCE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_REASON_REFERENCE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_REASON_REFERENCE])) {\n $errs[self::FIELD_REASON_REFERENCE] = [];\n }\n $errs[self::FIELD_REASON_REFERENCE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_REQUEST_IDENTIFIER])) {\n $v = $this->getRequestIdentifier();\n foreach($validationRules[self::FIELD_REQUEST_IDENTIFIER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_REQUEST_IDENTIFIER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_REQUEST_IDENTIFIER])) {\n $errs[self::FIELD_REQUEST_IDENTIFIER] = [];\n }\n $errs[self::FIELD_REQUEST_IDENTIFIER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_RESULT])) {\n $v = $this->getResult();\n foreach($validationRules[self::FIELD_RESULT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_RESULT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_RESULT])) {\n $errs[self::FIELD_RESULT] = [];\n }\n $errs[self::FIELD_RESULT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_STATUS])) {\n $v = $this->getStatus();\n foreach($validationRules[self::FIELD_STATUS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_STATUS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_STATUS])) {\n $errs[self::FIELD_STATUS] = [];\n }\n $errs[self::FIELD_STATUS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_SUBJECT])) {\n $v = $this->getSubject();\n foreach($validationRules[self::FIELD_SUBJECT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_GUIDANCE_RESPONSE, self::FIELD_SUBJECT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_SUBJECT])) {\n $errs[self::FIELD_SUBJECT] = [];\n }\n $errs[self::FIELD_SUBJECT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_CONTAINED])) {\n $v = $this->getContained();\n foreach($validationRules[self::FIELD_CONTAINED] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_CONTAINED, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CONTAINED])) {\n $errs[self::FIELD_CONTAINED] = [];\n }\n $errs[self::FIELD_CONTAINED][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EXTENSION])) {\n $v = $this->getExtension();\n foreach($validationRules[self::FIELD_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EXTENSION])) {\n $errs[self::FIELD_EXTENSION] = [];\n }\n $errs[self::FIELD_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODIFIER_EXTENSION])) {\n $v = $this->getModifierExtension();\n foreach($validationRules[self::FIELD_MODIFIER_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_MODIFIER_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODIFIER_EXTENSION])) {\n $errs[self::FIELD_MODIFIER_EXTENSION] = [];\n }\n $errs[self::FIELD_MODIFIER_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TEXT])) {\n $v = $this->getText();\n foreach($validationRules[self::FIELD_TEXT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_TEXT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TEXT])) {\n $errs[self::FIELD_TEXT] = [];\n }\n $errs[self::FIELD_TEXT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ID])) {\n $v = $this->getId();\n foreach($validationRules[self::FIELD_ID] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_ID, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ID])) {\n $errs[self::FIELD_ID] = [];\n }\n $errs[self::FIELD_ID][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IMPLICIT_RULES])) {\n $v = $this->getImplicitRules();\n foreach($validationRules[self::FIELD_IMPLICIT_RULES] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_IMPLICIT_RULES, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IMPLICIT_RULES])) {\n $errs[self::FIELD_IMPLICIT_RULES] = [];\n }\n $errs[self::FIELD_IMPLICIT_RULES][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_LANGUAGE])) {\n $v = $this->getLanguage();\n foreach($validationRules[self::FIELD_LANGUAGE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_LANGUAGE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_LANGUAGE])) {\n $errs[self::FIELD_LANGUAGE] = [];\n }\n $errs[self::FIELD_LANGUAGE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_META])) {\n $v = $this->getMeta();\n foreach($validationRules[self::FIELD_META] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_META, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_META])) {\n $errs[self::FIELD_META] = [];\n }\n $errs[self::FIELD_META][$rule] = $err;\n }\n }\n }\n return $errs;\n }", "public function getErrors()\n {\n $errors = $this->getValue('klarna_validation_errors');\n return $errors ? $errors : array();\n }", "public function getMessage(): array\n {\n return [\n self::RULE_REQUIRED => 'This Field is required',\n self::RULE_EMAIL => 'Please input valid email address',\n self::RULE_MATCH => 'The Passwords must match',\n self::RULE_UNIQUE => 'This record exists in the database',\n self::RULE_VALID_START_DATE => 'Project start date cannot be before today',\n self::RULE_VALID_END_DATE => 'Project end date cannot be before start date'\n\n ];\n }", "public function getErrorMessages()\n {\n $translator = Mage::helper('importexport');\n $messages = array();\n\n foreach ($this->_errors as $errorCode => $errorRows) {\n if (isset($this->_messageTemplates[$errorCode])) {\n $errorCode = $translator->__($this->_messageTemplates[$errorCode]);\n }\n foreach ($errorRows as $errorRowData) {\n $key = $errorRowData[1] ? sprintf($errorCode, $errorRowData[1]) : $errorCode;\n $messages[$key][] = $errorRowData[0];\n }\n }\n return $messages;\n }", "public function getErrors(): array\n {\n return $this->getInputFilter()->getMessages();\n }", "protected function _getValidationErrors()\n {\n if (is_null($this->validationErrors)) {\n return array();\n }\n\n return $this->validationErrors;\n }", "public function _getValidationErrors(): array\n\t{\n\t\t$errs = parent::_getValidationErrors();\n\t\t$validationRules = $this->_getValidationRules();\n\t\tif (null !== ($v = $this->getUrl())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_URL] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getIdentifier())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_IDENTIFIER, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getVersion())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_VERSION] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getName())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_NAME] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getDisplay())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_DISPLAY] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getStatus())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_STATUS] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getExperimental())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_EXPERIMENTAL] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getPublisher())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_PUBLISHER] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getContact())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_CONTACT, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getDate())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_DATE] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getDescription())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_DESCRIPTION] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getUseContext())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_USE_CONTEXT, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getRequirements())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_REQUIREMENTS] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getCopyright())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_COPYRIGHT] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getCode())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_CODE, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getFhirVersion())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_FHIR_VERSION] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getMapping())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_MAPPING, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getKind())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_KIND] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getConstrainedType())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_CONSTRAINED_TYPE] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getAbstract())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_ABSTRACT] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getContextType())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_CONTEXT_TYPE] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif ([] !== ($vs = $this->getContext())) {\n\t\t\tforeach ($vs as $i => $v) {\n\t\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t\t$errs[sprintf('%s.%d', self::FIELD_CONTEXT, $i)] = $fieldErrs;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getBase())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_BASE] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getSnapshot())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_SNAPSHOT] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (null !== ($v = $this->getDifferential())) {\n\t\t\tif ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n\t\t\t\t$errs[self::FIELD_DIFFERENTIAL] = $fieldErrs;\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_URL])) {\n\t\t\t$v = $this->getUrl();\n\t\t\tforeach ($validationRules[self::FIELD_URL] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_URL,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_URL])) {\n\t\t\t\t\t\t$errs[self::FIELD_URL] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_URL][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_IDENTIFIER])) {\n\t\t\t$v = $this->getIdentifier();\n\t\t\tforeach ($validationRules[self::FIELD_IDENTIFIER] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_IDENTIFIER,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_IDENTIFIER])) {\n\t\t\t\t\t\t$errs[self::FIELD_IDENTIFIER] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_IDENTIFIER][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_VERSION])) {\n\t\t\t$v = $this->getVersion();\n\t\t\tforeach ($validationRules[self::FIELD_VERSION] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_VERSION,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_VERSION])) {\n\t\t\t\t\t\t$errs[self::FIELD_VERSION] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_VERSION][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_NAME])) {\n\t\t\t$v = $this->getName();\n\t\t\tforeach ($validationRules[self::FIELD_NAME] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_NAME,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_NAME])) {\n\t\t\t\t\t\t$errs[self::FIELD_NAME] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_NAME][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_DISPLAY])) {\n\t\t\t$v = $this->getDisplay();\n\t\t\tforeach ($validationRules[self::FIELD_DISPLAY] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_DISPLAY,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_DISPLAY])) {\n\t\t\t\t\t\t$errs[self::FIELD_DISPLAY] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_DISPLAY][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_STATUS])) {\n\t\t\t$v = $this->getStatus();\n\t\t\tforeach ($validationRules[self::FIELD_STATUS] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_STATUS,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_STATUS])) {\n\t\t\t\t\t\t$errs[self::FIELD_STATUS] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_STATUS][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_EXPERIMENTAL])) {\n\t\t\t$v = $this->getExperimental();\n\t\t\tforeach ($validationRules[self::FIELD_EXPERIMENTAL] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_EXPERIMENTAL,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_EXPERIMENTAL])) {\n\t\t\t\t\t\t$errs[self::FIELD_EXPERIMENTAL] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_EXPERIMENTAL][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_PUBLISHER])) {\n\t\t\t$v = $this->getPublisher();\n\t\t\tforeach ($validationRules[self::FIELD_PUBLISHER] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_PUBLISHER,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_PUBLISHER])) {\n\t\t\t\t\t\t$errs[self::FIELD_PUBLISHER] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_PUBLISHER][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CONTACT])) {\n\t\t\t$v = $this->getContact();\n\t\t\tforeach ($validationRules[self::FIELD_CONTACT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_CONTACT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CONTACT])) {\n\t\t\t\t\t\t$errs[self::FIELD_CONTACT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CONTACT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_DATE])) {\n\t\t\t$v = $this->getDate();\n\t\t\tforeach ($validationRules[self::FIELD_DATE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_DATE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_DATE])) {\n\t\t\t\t\t\t$errs[self::FIELD_DATE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_DATE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_DESCRIPTION])) {\n\t\t\t$v = $this->getDescription();\n\t\t\tforeach ($validationRules[self::FIELD_DESCRIPTION] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_DESCRIPTION,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_DESCRIPTION])) {\n\t\t\t\t\t\t$errs[self::FIELD_DESCRIPTION] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_DESCRIPTION][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_USE_CONTEXT])) {\n\t\t\t$v = $this->getUseContext();\n\t\t\tforeach ($validationRules[self::FIELD_USE_CONTEXT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_USE_CONTEXT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_USE_CONTEXT])) {\n\t\t\t\t\t\t$errs[self::FIELD_USE_CONTEXT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_USE_CONTEXT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_REQUIREMENTS])) {\n\t\t\t$v = $this->getRequirements();\n\t\t\tforeach ($validationRules[self::FIELD_REQUIREMENTS] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_REQUIREMENTS,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_REQUIREMENTS])) {\n\t\t\t\t\t\t$errs[self::FIELD_REQUIREMENTS] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_REQUIREMENTS][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_COPYRIGHT])) {\n\t\t\t$v = $this->getCopyright();\n\t\t\tforeach ($validationRules[self::FIELD_COPYRIGHT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_COPYRIGHT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_COPYRIGHT])) {\n\t\t\t\t\t\t$errs[self::FIELD_COPYRIGHT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_COPYRIGHT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CODE])) {\n\t\t\t$v = $this->getCode();\n\t\t\tforeach ($validationRules[self::FIELD_CODE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_CODE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CODE])) {\n\t\t\t\t\t\t$errs[self::FIELD_CODE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CODE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_FHIR_VERSION])) {\n\t\t\t$v = $this->getFhirVersion();\n\t\t\tforeach ($validationRules[self::FIELD_FHIR_VERSION] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_FHIR_VERSION,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_FHIR_VERSION])) {\n\t\t\t\t\t\t$errs[self::FIELD_FHIR_VERSION] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_FHIR_VERSION][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_MAPPING])) {\n\t\t\t$v = $this->getMapping();\n\t\t\tforeach ($validationRules[self::FIELD_MAPPING] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_MAPPING,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_MAPPING])) {\n\t\t\t\t\t\t$errs[self::FIELD_MAPPING] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_MAPPING][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_KIND])) {\n\t\t\t$v = $this->getKind();\n\t\t\tforeach ($validationRules[self::FIELD_KIND] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_KIND,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_KIND])) {\n\t\t\t\t\t\t$errs[self::FIELD_KIND] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_KIND][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CONSTRAINED_TYPE])) {\n\t\t\t$v = $this->getConstrainedType();\n\t\t\tforeach ($validationRules[self::FIELD_CONSTRAINED_TYPE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_CONSTRAINED_TYPE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CONSTRAINED_TYPE])) {\n\t\t\t\t\t\t$errs[self::FIELD_CONSTRAINED_TYPE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CONSTRAINED_TYPE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_ABSTRACT])) {\n\t\t\t$v = $this->getAbstract();\n\t\t\tforeach ($validationRules[self::FIELD_ABSTRACT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_ABSTRACT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_ABSTRACT])) {\n\t\t\t\t\t\t$errs[self::FIELD_ABSTRACT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_ABSTRACT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CONTEXT_TYPE])) {\n\t\t\t$v = $this->getContextType();\n\t\t\tforeach ($validationRules[self::FIELD_CONTEXT_TYPE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_CONTEXT_TYPE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CONTEXT_TYPE])) {\n\t\t\t\t\t\t$errs[self::FIELD_CONTEXT_TYPE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CONTEXT_TYPE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CONTEXT])) {\n\t\t\t$v = $this->getContext();\n\t\t\tforeach ($validationRules[self::FIELD_CONTEXT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_CONTEXT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CONTEXT])) {\n\t\t\t\t\t\t$errs[self::FIELD_CONTEXT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CONTEXT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_BASE])) {\n\t\t\t$v = $this->getBase();\n\t\t\tforeach ($validationRules[self::FIELD_BASE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_BASE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_BASE])) {\n\t\t\t\t\t\t$errs[self::FIELD_BASE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_BASE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_SNAPSHOT])) {\n\t\t\t$v = $this->getSnapshot();\n\t\t\tforeach ($validationRules[self::FIELD_SNAPSHOT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_SNAPSHOT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_SNAPSHOT])) {\n\t\t\t\t\t\t$errs[self::FIELD_SNAPSHOT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_SNAPSHOT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_DIFFERENTIAL])) {\n\t\t\t$v = $this->getDifferential();\n\t\t\tforeach ($validationRules[self::FIELD_DIFFERENTIAL] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_STRUCTURE_DEFINITION,\n\t\t\t\t\tself::FIELD_DIFFERENTIAL,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_DIFFERENTIAL])) {\n\t\t\t\t\t\t$errs[self::FIELD_DIFFERENTIAL] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_DIFFERENTIAL][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_TEXT])) {\n\t\t\t$v = $this->getText();\n\t\t\tforeach ($validationRules[self::FIELD_TEXT] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE,\n\t\t\t\t\tself::FIELD_TEXT,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_TEXT])) {\n\t\t\t\t\t\t$errs[self::FIELD_TEXT] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_TEXT][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_CONTAINED])) {\n\t\t\t$v = $this->getContained();\n\t\t\tforeach ($validationRules[self::FIELD_CONTAINED] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE,\n\t\t\t\t\tself::FIELD_CONTAINED,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_CONTAINED])) {\n\t\t\t\t\t\t$errs[self::FIELD_CONTAINED] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_CONTAINED][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_EXTENSION])) {\n\t\t\t$v = $this->getExtension();\n\t\t\tforeach ($validationRules[self::FIELD_EXTENSION] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE,\n\t\t\t\t\tself::FIELD_EXTENSION,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_EXTENSION])) {\n\t\t\t\t\t\t$errs[self::FIELD_EXTENSION] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_EXTENSION][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_MODIFIER_EXTENSION])) {\n\t\t\t$v = $this->getModifierExtension();\n\t\t\tforeach ($validationRules[self::FIELD_MODIFIER_EXTENSION] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE,\n\t\t\t\t\tself::FIELD_MODIFIER_EXTENSION,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_MODIFIER_EXTENSION])) {\n\t\t\t\t\t\t$errs[self::FIELD_MODIFIER_EXTENSION] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_MODIFIER_EXTENSION][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_ID])) {\n\t\t\t$v = $this->getId();\n\t\t\tforeach ($validationRules[self::FIELD_ID] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_RESOURCE,\n\t\t\t\t\tself::FIELD_ID,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_ID])) {\n\t\t\t\t\t\t$errs[self::FIELD_ID] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_ID][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_META])) {\n\t\t\t$v = $this->getMeta();\n\t\t\tforeach ($validationRules[self::FIELD_META] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_RESOURCE,\n\t\t\t\t\tself::FIELD_META,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_META])) {\n\t\t\t\t\t\t$errs[self::FIELD_META] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_META][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_IMPLICIT_RULES])) {\n\t\t\t$v = $this->getImplicitRules();\n\t\t\tforeach ($validationRules[self::FIELD_IMPLICIT_RULES] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_RESOURCE,\n\t\t\t\t\tself::FIELD_IMPLICIT_RULES,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_IMPLICIT_RULES])) {\n\t\t\t\t\t\t$errs[self::FIELD_IMPLICIT_RULES] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_IMPLICIT_RULES][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif (isset($validationRules[self::FIELD_LANGUAGE])) {\n\t\t\t$v = $this->getLanguage();\n\t\t\tforeach ($validationRules[self::FIELD_LANGUAGE] as $rule => $constraint) {\n\t\t\t\t$err = $this->_performValidation(\n\t\t\t\t\tPHPFHIRConstants::TYPE_NAME_RESOURCE,\n\t\t\t\t\tself::FIELD_LANGUAGE,\n\t\t\t\t\t$rule,\n\t\t\t\t\t$constraint,\n\t\t\t\t\t$v,\n\t\t\t\t);\n\t\t\t\tif (null !== $err) {\n\t\t\t\t\tif (!isset($errs[self::FIELD_LANGUAGE])) {\n\t\t\t\t\t\t$errs[self::FIELD_LANGUAGE] = [];\n\t\t\t\t\t}\n\t\t\t\t\t$errs[self::FIELD_LANGUAGE][$rule] = $err;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $errs;\n\t}", "public function get_errors() {\n\t\treturn $this->errors->get_error_messages();\n\t}", "public function getValidationErrors()\n\t{\n\t\treturn $this->validationErrors;\n\t}", "public function messages() \n {\n return[\n 'name.required' => ['code' => 'ERROR-1', 'title' => 'Unprocessable Entity'],\n 'price.required' => ['code' => 'ERROR-1', 'title' => 'Unprocessable Entity'],\n 'price.numeric' => ['code' => 'ERROR-1', 'title' => 'Unprocessable Entity'],\n 'price.major' => ['code' => 'ERROR-1', 'title' => 'Unprocessable Entity']\n ];\n }", "public function get_clear_error_msgs()\n {\n $msgs = array();\n foreach ($this->errors as $e) {\n $msgs[$e['field']][$e['rule']] = $this->get_validation_error_msg($e['field'], $e['rule'], $e['value']);\n\n }\n return $msgs;\n }", "public function messages()\n {\n $items = [];\n foreach (static::attributes() as $key => $val) {\n $items[$key . '.required'] = t('common.form.errors.required', [\n 'attribute' => $val,\n ]);\n }\n \n return $items;\n }", "public function messages()\n {\n return [\n 'name.required' => 'A Team Name is required',\n 'filename.required' => 'A Team Logo is required',\n 'club_state.required' => 'A Club state is required',\n ];\n }", "public function messages()\n {\n return [\n 'code_day.required' => 'Code day must required!',\n 'name.required' => 'Name must required!',\n ];\n }", "public function messages()\n {\n return [\n 'name.required' => 'Email is required!',\n 'year.required' => 'Year is required!',\n 'artist_id.required' => 'Artist is required!'\n ];\n }", "public function messages()\n {\n return [\n 'required' => ':attribute field must be filled',\n 'email' => ':attribute field must be an email',\n 'unique' => ':attribute field already registered',\n ];\n }", "public function _getValidationErrors()\n {\n $errs = parent::_getValidationErrors();\n $validationRules = $this->_getValidationRules();\n if (null !== ($v = $this->getAccident())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ACCIDENT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getAccidentType())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ACCIDENT_TYPE] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getAdditionalMaterials())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_ADDITIONAL_MATERIALS, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getCondition())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_CONDITION, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getCoverage())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_COVERAGE, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getCreated())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_CREATED] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getDiagnosis())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_DIAGNOSIS, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getEnterer())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ENTERER] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getException())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_EXCEPTION, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getFacility())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_FACILITY] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getFundsReserve())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_FUNDS_RESERVE] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getIdentifier())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_IDENTIFIER, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getInterventionException())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_INTERVENTION_EXCEPTION, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getItem())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_ITEM, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getMissingTeeth())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_MISSING_TEETH, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getOrganization())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ORGANIZATION] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getOriginalPrescription())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ORIGINAL_PRESCRIPTION] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getOriginalRuleset())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_ORIGINAL_RULESET] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPatient())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PATIENT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPayee())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PAYEE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPrescription())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PRESCRIPTION] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPriority())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PRIORITY] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getProvider())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PROVIDER] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getReferral())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_REFERRAL] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getRuleset())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_RULESET] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getSchool())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_SCHOOL] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getTarget())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_TARGET] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getType())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_TYPE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getUse())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_USE] = $fieldErrs;\n }\n }\n if (isset($validationRules[self::FIELD_ACCIDENT])) {\n $v = $this->getAccident();\n foreach($validationRules[self::FIELD_ACCIDENT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ACCIDENT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ACCIDENT])) {\n $errs[self::FIELD_ACCIDENT] = [];\n }\n $errs[self::FIELD_ACCIDENT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ACCIDENT_TYPE])) {\n $v = $this->getAccidentType();\n foreach($validationRules[self::FIELD_ACCIDENT_TYPE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ACCIDENT_TYPE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ACCIDENT_TYPE])) {\n $errs[self::FIELD_ACCIDENT_TYPE] = [];\n }\n $errs[self::FIELD_ACCIDENT_TYPE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ADDITIONAL_MATERIALS])) {\n $v = $this->getAdditionalMaterials();\n foreach($validationRules[self::FIELD_ADDITIONAL_MATERIALS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ADDITIONAL_MATERIALS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ADDITIONAL_MATERIALS])) {\n $errs[self::FIELD_ADDITIONAL_MATERIALS] = [];\n }\n $errs[self::FIELD_ADDITIONAL_MATERIALS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_CONDITION])) {\n $v = $this->getCondition();\n foreach($validationRules[self::FIELD_CONDITION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_CONDITION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CONDITION])) {\n $errs[self::FIELD_CONDITION] = [];\n }\n $errs[self::FIELD_CONDITION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_COVERAGE])) {\n $v = $this->getCoverage();\n foreach($validationRules[self::FIELD_COVERAGE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_COVERAGE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_COVERAGE])) {\n $errs[self::FIELD_COVERAGE] = [];\n }\n $errs[self::FIELD_COVERAGE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_CREATED])) {\n $v = $this->getCreated();\n foreach($validationRules[self::FIELD_CREATED] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_CREATED, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CREATED])) {\n $errs[self::FIELD_CREATED] = [];\n }\n $errs[self::FIELD_CREATED][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_DIAGNOSIS])) {\n $v = $this->getDiagnosis();\n foreach($validationRules[self::FIELD_DIAGNOSIS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_DIAGNOSIS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_DIAGNOSIS])) {\n $errs[self::FIELD_DIAGNOSIS] = [];\n }\n $errs[self::FIELD_DIAGNOSIS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ENTERER])) {\n $v = $this->getEnterer();\n foreach($validationRules[self::FIELD_ENTERER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ENTERER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ENTERER])) {\n $errs[self::FIELD_ENTERER] = [];\n }\n $errs[self::FIELD_ENTERER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EXCEPTION])) {\n $v = $this->getException();\n foreach($validationRules[self::FIELD_EXCEPTION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_EXCEPTION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EXCEPTION])) {\n $errs[self::FIELD_EXCEPTION] = [];\n }\n $errs[self::FIELD_EXCEPTION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_FACILITY])) {\n $v = $this->getFacility();\n foreach($validationRules[self::FIELD_FACILITY] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_FACILITY, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_FACILITY])) {\n $errs[self::FIELD_FACILITY] = [];\n }\n $errs[self::FIELD_FACILITY][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_FUNDS_RESERVE])) {\n $v = $this->getFundsReserve();\n foreach($validationRules[self::FIELD_FUNDS_RESERVE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_FUNDS_RESERVE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_FUNDS_RESERVE])) {\n $errs[self::FIELD_FUNDS_RESERVE] = [];\n }\n $errs[self::FIELD_FUNDS_RESERVE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IDENTIFIER])) {\n $v = $this->getIdentifier();\n foreach($validationRules[self::FIELD_IDENTIFIER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_IDENTIFIER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IDENTIFIER])) {\n $errs[self::FIELD_IDENTIFIER] = [];\n }\n $errs[self::FIELD_IDENTIFIER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_INTERVENTION_EXCEPTION])) {\n $v = $this->getInterventionException();\n foreach($validationRules[self::FIELD_INTERVENTION_EXCEPTION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_INTERVENTION_EXCEPTION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_INTERVENTION_EXCEPTION])) {\n $errs[self::FIELD_INTERVENTION_EXCEPTION] = [];\n }\n $errs[self::FIELD_INTERVENTION_EXCEPTION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ITEM])) {\n $v = $this->getItem();\n foreach($validationRules[self::FIELD_ITEM] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ITEM, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ITEM])) {\n $errs[self::FIELD_ITEM] = [];\n }\n $errs[self::FIELD_ITEM][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MISSING_TEETH])) {\n $v = $this->getMissingTeeth();\n foreach($validationRules[self::FIELD_MISSING_TEETH] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_MISSING_TEETH, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MISSING_TEETH])) {\n $errs[self::FIELD_MISSING_TEETH] = [];\n }\n $errs[self::FIELD_MISSING_TEETH][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ORGANIZATION])) {\n $v = $this->getOrganization();\n foreach($validationRules[self::FIELD_ORGANIZATION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ORGANIZATION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ORGANIZATION])) {\n $errs[self::FIELD_ORGANIZATION] = [];\n }\n $errs[self::FIELD_ORGANIZATION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ORIGINAL_PRESCRIPTION])) {\n $v = $this->getOriginalPrescription();\n foreach($validationRules[self::FIELD_ORIGINAL_PRESCRIPTION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ORIGINAL_PRESCRIPTION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ORIGINAL_PRESCRIPTION])) {\n $errs[self::FIELD_ORIGINAL_PRESCRIPTION] = [];\n }\n $errs[self::FIELD_ORIGINAL_PRESCRIPTION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ORIGINAL_RULESET])) {\n $v = $this->getOriginalRuleset();\n foreach($validationRules[self::FIELD_ORIGINAL_RULESET] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_ORIGINAL_RULESET, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ORIGINAL_RULESET])) {\n $errs[self::FIELD_ORIGINAL_RULESET] = [];\n }\n $errs[self::FIELD_ORIGINAL_RULESET][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PATIENT])) {\n $v = $this->getPatient();\n foreach($validationRules[self::FIELD_PATIENT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_PATIENT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PATIENT])) {\n $errs[self::FIELD_PATIENT] = [];\n }\n $errs[self::FIELD_PATIENT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PAYEE])) {\n $v = $this->getPayee();\n foreach($validationRules[self::FIELD_PAYEE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_PAYEE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PAYEE])) {\n $errs[self::FIELD_PAYEE] = [];\n }\n $errs[self::FIELD_PAYEE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PRESCRIPTION])) {\n $v = $this->getPrescription();\n foreach($validationRules[self::FIELD_PRESCRIPTION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_PRESCRIPTION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PRESCRIPTION])) {\n $errs[self::FIELD_PRESCRIPTION] = [];\n }\n $errs[self::FIELD_PRESCRIPTION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PRIORITY])) {\n $v = $this->getPriority();\n foreach($validationRules[self::FIELD_PRIORITY] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_PRIORITY, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PRIORITY])) {\n $errs[self::FIELD_PRIORITY] = [];\n }\n $errs[self::FIELD_PRIORITY][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PROVIDER])) {\n $v = $this->getProvider();\n foreach($validationRules[self::FIELD_PROVIDER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_PROVIDER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PROVIDER])) {\n $errs[self::FIELD_PROVIDER] = [];\n }\n $errs[self::FIELD_PROVIDER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_REFERRAL])) {\n $v = $this->getReferral();\n foreach($validationRules[self::FIELD_REFERRAL] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_REFERRAL, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_REFERRAL])) {\n $errs[self::FIELD_REFERRAL] = [];\n }\n $errs[self::FIELD_REFERRAL][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_RULESET])) {\n $v = $this->getRuleset();\n foreach($validationRules[self::FIELD_RULESET] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_RULESET, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_RULESET])) {\n $errs[self::FIELD_RULESET] = [];\n }\n $errs[self::FIELD_RULESET][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_SCHOOL])) {\n $v = $this->getSchool();\n foreach($validationRules[self::FIELD_SCHOOL] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_SCHOOL, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_SCHOOL])) {\n $errs[self::FIELD_SCHOOL] = [];\n }\n $errs[self::FIELD_SCHOOL][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TARGET])) {\n $v = $this->getTarget();\n foreach($validationRules[self::FIELD_TARGET] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_TARGET, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TARGET])) {\n $errs[self::FIELD_TARGET] = [];\n }\n $errs[self::FIELD_TARGET][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TYPE])) {\n $v = $this->getType();\n foreach($validationRules[self::FIELD_TYPE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_TYPE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TYPE])) {\n $errs[self::FIELD_TYPE] = [];\n }\n $errs[self::FIELD_TYPE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_USE])) {\n $v = $this->getUse();\n foreach($validationRules[self::FIELD_USE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_CLAIM, self::FIELD_USE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_USE])) {\n $errs[self::FIELD_USE] = [];\n }\n $errs[self::FIELD_USE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_CONTAINED])) {\n $v = $this->getContained();\n foreach($validationRules[self::FIELD_CONTAINED] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_CONTAINED, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CONTAINED])) {\n $errs[self::FIELD_CONTAINED] = [];\n }\n $errs[self::FIELD_CONTAINED][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EXTENSION])) {\n $v = $this->getExtension();\n foreach($validationRules[self::FIELD_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EXTENSION])) {\n $errs[self::FIELD_EXTENSION] = [];\n }\n $errs[self::FIELD_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODIFIER_EXTENSION])) {\n $v = $this->getModifierExtension();\n foreach($validationRules[self::FIELD_MODIFIER_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_MODIFIER_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODIFIER_EXTENSION])) {\n $errs[self::FIELD_MODIFIER_EXTENSION] = [];\n }\n $errs[self::FIELD_MODIFIER_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TEXT])) {\n $v = $this->getText();\n foreach($validationRules[self::FIELD_TEXT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_TEXT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TEXT])) {\n $errs[self::FIELD_TEXT] = [];\n }\n $errs[self::FIELD_TEXT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ID])) {\n $v = $this->getId();\n foreach($validationRules[self::FIELD_ID] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_ID, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ID])) {\n $errs[self::FIELD_ID] = [];\n }\n $errs[self::FIELD_ID][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IMPLICIT_RULES])) {\n $v = $this->getImplicitRules();\n foreach($validationRules[self::FIELD_IMPLICIT_RULES] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_IMPLICIT_RULES, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IMPLICIT_RULES])) {\n $errs[self::FIELD_IMPLICIT_RULES] = [];\n }\n $errs[self::FIELD_IMPLICIT_RULES][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_LANGUAGE])) {\n $v = $this->getLanguage();\n foreach($validationRules[self::FIELD_LANGUAGE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_LANGUAGE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_LANGUAGE])) {\n $errs[self::FIELD_LANGUAGE] = [];\n }\n $errs[self::FIELD_LANGUAGE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_META])) {\n $v = $this->getMeta();\n foreach($validationRules[self::FIELD_META] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_META, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_META])) {\n $errs[self::FIELD_META] = [];\n }\n $errs[self::FIELD_META][$rule] = $err;\n }\n }\n }\n return $errs;\n }", "public function messages()\n {\n return [\n 'baskets.required' => trans('validation.recipe baskets'),\n 'steps.required' => trans('validation.recipe steps'),\n 'ingredients.required' => trans('validation.recipe ingredients'),\n ];\n }", "public function getValidationErrors() {\n\t\t$out = array();\n\t\t$this->loadFields();\n\t\tforeach($this->fields as $field) {\n\t\t\t$out = array_merge($out, $field->getValidationErrors());\n\t\t}\n\t\tif ((!$this->lat || !$this->lng) && !$this->feature_id) {\n\t\t\t$out[] = \"You must set a location!\";\n\t\t}\n\t\treturn $out;\n\t}", "public function errors() {\n $errors = array();\n foreach ($this->properties as $property) {\n if (!$property->rulesPassed()) {\n $errors[$property->getName()] = $property->getErrors();\n }\n }\n return $errors;\n }", "public function messages()\n {\n return [\n 'curp.required' => 'Falta la C.U.R.P.',\n 'curp.unique' => 'Esta C.U.R.P. ya existe',\n 'curp.min' => 'C.U.R.P. incorrecta',\n 'curp.max' => 'C.U.R.P. incorrecta',\n 'nombre1.required' => 'Falta el nombre',\n 'nombre1.min' => 'Nombre incorrecto',\n 'nombre1.max' => 'Nombre incorrecto',\n 'apellido1.required' => 'Falta el apellido',\n 'apellido1.min' => 'Apellido incorrecto',\n 'apellido1.max' => 'Apellido incorrecto',\n 'fechanacimiento.required' => 'Falta la fecha de nac.',\n 'genero.required' => 'Obligatorio'\n ];\n }", "public function getValidationErrors() {\n\t\treturn $this->_validationErrors;\n\t}", "private function getErrorMessages(): array\n {\n return [\n 'notEmpty' => 'Campo {{name}} obligatorio',\n 'date' => '{{name}} debe tener una fecha valida. Ejemplo de formato: {{format}}\\'',\n 'intVal' => '',\n 'between' => '',\n 'in' => '',\n 'floatVal' => '',\n 'length' => '',\n 'stringType' => '',\n 'objectType' => '',\n 'cantidadRegistros' => 'dsfsdfsd',\n 'periodo.notEmpty' => 'Campo Periodo: es obligatorio',\n 'periodo' => 'Campo Periodo: Debe tener el formato AAAAMM, donde AAAA indica el año y MM el mes en números',\n 'orden.notEmpty' => 'Campo Orden: es obligatorio',\n 'orden' => 'Campo Orden: Debe ser igual a 1 ó 2.',\n 'codigoComprobante.notEmpty' => 'Campo Codigo de Comprobante: es obligatorio',\n 'codigoComprobante' => 'Campo Codigo de Comprobante: Debe debe estar comprendido entre 1 y 9998.',\n 'numeroComprobante.notEmpty' => 'Campo Numero de Comprobante: es obligatorio',\n 'numeroComprobante' => 'Campo Numero de Comprobante: Debe debe estar comprendido entre 1 y 99999999.',\n 'puntoVenta.notEmpty' => 'Punto de venta: es obligatorio',\n 'puntoVenta' => 'Punto de venta: Debe debe estar comprendido entre 1 y 9998.',\n ];\n }", "public function messages()\n {\n return [\n 'code_area.required' => 'Code area cannot be blank',\n 'name.required' => 'Name area cannot be blank'\n ];\n }", "public function messages()\n {\n return [\n 'zipcode.required' => 'A Zipcode is required',\n 'publicPlace.required' => 'A Public Place is required',\n 'neighbordhood.required' => 'A Neighbordhood is required',\n 'complement.required' => 'A Complement Name is required',\n 'number.required' => 'A Number is required',\n 'city.required' => 'A City is required',\n 'state.required' => 'A State is required',\n\n 'zipcode.max' => 'A Zipcode max 255 characteres required.',\n 'publicPlace.max' => 'A Public Place max 255 characteres required.',\n 'neighbordhood.max' => 'A Neighbordhood max 255 characteres required.',\n 'complement.max' => 'A Complementmax 255 characteres required.',\n 'number.max' => 'A Number max 255 characteres required.',\n 'city.max' => 'A City max 255 characteres required.',\n 'state.max' => 'A State max 255 characteres required.',\n ];\n }", "public function validateAll()\n {\n $errorMsgs = array();\n return $errorMsgs;\n }", "public function _getValidationErrors()\n {\n $errs = parent::_getValidationErrors();\n $validationRules = $this->_getValidationRules();\n if ([] !== ($vs = $this->getCountry())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_COUNTRY, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getDataExclusivityPeriod())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_DATA_EXCLUSIVITY_PERIOD] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getDateOfFirstAuthorization())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_DATE_OF_FIRST_AUTHORIZATION] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getHolder())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_HOLDER] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getIdentifier())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_IDENTIFIER, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getInternationalBirthDate())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_INTERNATIONAL_BIRTH_DATE] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getJurisdiction())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_JURISDICTION, $i)] = $fieldErrs;\n }\n }\n }\n if ([] !== ($vs = $this->getJurisdictionalAuthorization())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_JURISDICTIONAL_AUTHORIZATION, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getLegalBasis())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_LEGAL_BASIS] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getProcedure())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PROCEDURE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getRegulator())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_REGULATOR] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getRestoreDate())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_RESTORE_DATE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getStatus())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_STATUS] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getStatusDate())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_STATUS_DATE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getSubject())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_SUBJECT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getValidityPeriod())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_VALIDITY_PERIOD] = $fieldErrs;\n }\n }\n if (isset($validationRules[self::FIELD_COUNTRY])) {\n $v = $this->getCountry();\n foreach($validationRules[self::FIELD_COUNTRY] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_COUNTRY, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_COUNTRY])) {\n $errs[self::FIELD_COUNTRY] = [];\n }\n $errs[self::FIELD_COUNTRY][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_DATA_EXCLUSIVITY_PERIOD])) {\n $v = $this->getDataExclusivityPeriod();\n foreach($validationRules[self::FIELD_DATA_EXCLUSIVITY_PERIOD] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_DATA_EXCLUSIVITY_PERIOD, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_DATA_EXCLUSIVITY_PERIOD])) {\n $errs[self::FIELD_DATA_EXCLUSIVITY_PERIOD] = [];\n }\n $errs[self::FIELD_DATA_EXCLUSIVITY_PERIOD][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_DATE_OF_FIRST_AUTHORIZATION])) {\n $v = $this->getDateOfFirstAuthorization();\n foreach($validationRules[self::FIELD_DATE_OF_FIRST_AUTHORIZATION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_DATE_OF_FIRST_AUTHORIZATION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_DATE_OF_FIRST_AUTHORIZATION])) {\n $errs[self::FIELD_DATE_OF_FIRST_AUTHORIZATION] = [];\n }\n $errs[self::FIELD_DATE_OF_FIRST_AUTHORIZATION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_HOLDER])) {\n $v = $this->getHolder();\n foreach($validationRules[self::FIELD_HOLDER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_HOLDER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_HOLDER])) {\n $errs[self::FIELD_HOLDER] = [];\n }\n $errs[self::FIELD_HOLDER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IDENTIFIER])) {\n $v = $this->getIdentifier();\n foreach($validationRules[self::FIELD_IDENTIFIER] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_IDENTIFIER, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IDENTIFIER])) {\n $errs[self::FIELD_IDENTIFIER] = [];\n }\n $errs[self::FIELD_IDENTIFIER][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_INTERNATIONAL_BIRTH_DATE])) {\n $v = $this->getInternationalBirthDate();\n foreach($validationRules[self::FIELD_INTERNATIONAL_BIRTH_DATE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_INTERNATIONAL_BIRTH_DATE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_INTERNATIONAL_BIRTH_DATE])) {\n $errs[self::FIELD_INTERNATIONAL_BIRTH_DATE] = [];\n }\n $errs[self::FIELD_INTERNATIONAL_BIRTH_DATE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_JURISDICTION])) {\n $v = $this->getJurisdiction();\n foreach($validationRules[self::FIELD_JURISDICTION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_JURISDICTION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_JURISDICTION])) {\n $errs[self::FIELD_JURISDICTION] = [];\n }\n $errs[self::FIELD_JURISDICTION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_JURISDICTIONAL_AUTHORIZATION])) {\n $v = $this->getJurisdictionalAuthorization();\n foreach($validationRules[self::FIELD_JURISDICTIONAL_AUTHORIZATION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_JURISDICTIONAL_AUTHORIZATION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_JURISDICTIONAL_AUTHORIZATION])) {\n $errs[self::FIELD_JURISDICTIONAL_AUTHORIZATION] = [];\n }\n $errs[self::FIELD_JURISDICTIONAL_AUTHORIZATION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_LEGAL_BASIS])) {\n $v = $this->getLegalBasis();\n foreach($validationRules[self::FIELD_LEGAL_BASIS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_LEGAL_BASIS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_LEGAL_BASIS])) {\n $errs[self::FIELD_LEGAL_BASIS] = [];\n }\n $errs[self::FIELD_LEGAL_BASIS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PROCEDURE])) {\n $v = $this->getProcedure();\n foreach($validationRules[self::FIELD_PROCEDURE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_PROCEDURE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PROCEDURE])) {\n $errs[self::FIELD_PROCEDURE] = [];\n }\n $errs[self::FIELD_PROCEDURE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_REGULATOR])) {\n $v = $this->getRegulator();\n foreach($validationRules[self::FIELD_REGULATOR] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_REGULATOR, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_REGULATOR])) {\n $errs[self::FIELD_REGULATOR] = [];\n }\n $errs[self::FIELD_REGULATOR][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_RESTORE_DATE])) {\n $v = $this->getRestoreDate();\n foreach($validationRules[self::FIELD_RESTORE_DATE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_RESTORE_DATE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_RESTORE_DATE])) {\n $errs[self::FIELD_RESTORE_DATE] = [];\n }\n $errs[self::FIELD_RESTORE_DATE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_STATUS])) {\n $v = $this->getStatus();\n foreach($validationRules[self::FIELD_STATUS] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_STATUS, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_STATUS])) {\n $errs[self::FIELD_STATUS] = [];\n }\n $errs[self::FIELD_STATUS][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_STATUS_DATE])) {\n $v = $this->getStatusDate();\n foreach($validationRules[self::FIELD_STATUS_DATE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_STATUS_DATE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_STATUS_DATE])) {\n $errs[self::FIELD_STATUS_DATE] = [];\n }\n $errs[self::FIELD_STATUS_DATE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_SUBJECT])) {\n $v = $this->getSubject();\n foreach($validationRules[self::FIELD_SUBJECT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_SUBJECT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_SUBJECT])) {\n $errs[self::FIELD_SUBJECT] = [];\n }\n $errs[self::FIELD_SUBJECT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_VALIDITY_PERIOD])) {\n $v = $this->getValidityPeriod();\n foreach($validationRules[self::FIELD_VALIDITY_PERIOD] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_MEDICINAL_PRODUCT_AUTHORIZATION, self::FIELD_VALIDITY_PERIOD, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_VALIDITY_PERIOD])) {\n $errs[self::FIELD_VALIDITY_PERIOD] = [];\n }\n $errs[self::FIELD_VALIDITY_PERIOD][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_CONTAINED])) {\n $v = $this->getContained();\n foreach($validationRules[self::FIELD_CONTAINED] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_CONTAINED, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CONTAINED])) {\n $errs[self::FIELD_CONTAINED] = [];\n }\n $errs[self::FIELD_CONTAINED][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EXTENSION])) {\n $v = $this->getExtension();\n foreach($validationRules[self::FIELD_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EXTENSION])) {\n $errs[self::FIELD_EXTENSION] = [];\n }\n $errs[self::FIELD_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_MODIFIER_EXTENSION])) {\n $v = $this->getModifierExtension();\n foreach($validationRules[self::FIELD_MODIFIER_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_MODIFIER_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_MODIFIER_EXTENSION])) {\n $errs[self::FIELD_MODIFIER_EXTENSION] = [];\n }\n $errs[self::FIELD_MODIFIER_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TEXT])) {\n $v = $this->getText();\n foreach($validationRules[self::FIELD_TEXT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_DOMAIN_RESOURCE, self::FIELD_TEXT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TEXT])) {\n $errs[self::FIELD_TEXT] = [];\n }\n $errs[self::FIELD_TEXT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ID])) {\n $v = $this->getId();\n foreach($validationRules[self::FIELD_ID] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_ID, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ID])) {\n $errs[self::FIELD_ID] = [];\n }\n $errs[self::FIELD_ID][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_IMPLICIT_RULES])) {\n $v = $this->getImplicitRules();\n foreach($validationRules[self::FIELD_IMPLICIT_RULES] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_IMPLICIT_RULES, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_IMPLICIT_RULES])) {\n $errs[self::FIELD_IMPLICIT_RULES] = [];\n }\n $errs[self::FIELD_IMPLICIT_RULES][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_LANGUAGE])) {\n $v = $this->getLanguage();\n foreach($validationRules[self::FIELD_LANGUAGE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_LANGUAGE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_LANGUAGE])) {\n $errs[self::FIELD_LANGUAGE] = [];\n }\n $errs[self::FIELD_LANGUAGE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_META])) {\n $v = $this->getMeta();\n foreach($validationRules[self::FIELD_META] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_RESOURCE, self::FIELD_META, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_META])) {\n $errs[self::FIELD_META] = [];\n }\n $errs[self::FIELD_META][$rule] = $err;\n }\n }\n }\n return $errs;\n }", "public function _getValidationErrors()\n {\n $errs = parent::_getValidationErrors();\n $validationRules = $this->_getValidationRules();\n if (null !== ($v = $this->getCity())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_CITY] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getCountry())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_COUNTRY] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getDistrict())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_DISTRICT] = $fieldErrs;\n }\n }\n if ([] !== ($vs = $this->getLine())) {\n foreach($vs as $i => $v) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[sprintf('%s.%d', self::FIELD_LINE, $i)] = $fieldErrs;\n }\n }\n }\n if (null !== ($v = $this->getPeriod())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_PERIOD] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getPostalCode())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_POSTAL_CODE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getState())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_STATE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getText())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_TEXT] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getType())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_TYPE] = $fieldErrs;\n }\n }\n if (null !== ($v = $this->getUse())) {\n if ([] !== ($fieldErrs = $v->_getValidationErrors())) {\n $errs[self::FIELD_USE] = $fieldErrs;\n }\n }\n if (isset($validationRules[self::FIELD_CITY])) {\n $v = $this->getCity();\n foreach($validationRules[self::FIELD_CITY] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_CITY, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_CITY])) {\n $errs[self::FIELD_CITY] = [];\n }\n $errs[self::FIELD_CITY][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_COUNTRY])) {\n $v = $this->getCountry();\n foreach($validationRules[self::FIELD_COUNTRY] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_COUNTRY, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_COUNTRY])) {\n $errs[self::FIELD_COUNTRY] = [];\n }\n $errs[self::FIELD_COUNTRY][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_DISTRICT])) {\n $v = $this->getDistrict();\n foreach($validationRules[self::FIELD_DISTRICT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_DISTRICT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_DISTRICT])) {\n $errs[self::FIELD_DISTRICT] = [];\n }\n $errs[self::FIELD_DISTRICT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_LINE])) {\n $v = $this->getLine();\n foreach($validationRules[self::FIELD_LINE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_LINE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_LINE])) {\n $errs[self::FIELD_LINE] = [];\n }\n $errs[self::FIELD_LINE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_PERIOD])) {\n $v = $this->getPeriod();\n foreach($validationRules[self::FIELD_PERIOD] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_PERIOD, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_PERIOD])) {\n $errs[self::FIELD_PERIOD] = [];\n }\n $errs[self::FIELD_PERIOD][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_POSTAL_CODE])) {\n $v = $this->getPostalCode();\n foreach($validationRules[self::FIELD_POSTAL_CODE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_POSTAL_CODE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_POSTAL_CODE])) {\n $errs[self::FIELD_POSTAL_CODE] = [];\n }\n $errs[self::FIELD_POSTAL_CODE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_STATE])) {\n $v = $this->getState();\n foreach($validationRules[self::FIELD_STATE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_STATE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_STATE])) {\n $errs[self::FIELD_STATE] = [];\n }\n $errs[self::FIELD_STATE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TEXT])) {\n $v = $this->getText();\n foreach($validationRules[self::FIELD_TEXT] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_TEXT, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TEXT])) {\n $errs[self::FIELD_TEXT] = [];\n }\n $errs[self::FIELD_TEXT][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_TYPE])) {\n $v = $this->getType();\n foreach($validationRules[self::FIELD_TYPE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_TYPE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_TYPE])) {\n $errs[self::FIELD_TYPE] = [];\n }\n $errs[self::FIELD_TYPE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_USE])) {\n $v = $this->getUse();\n foreach($validationRules[self::FIELD_USE] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ADDRESS, self::FIELD_USE, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_USE])) {\n $errs[self::FIELD_USE] = [];\n }\n $errs[self::FIELD_USE][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_EXTENSION])) {\n $v = $this->getExtension();\n foreach($validationRules[self::FIELD_EXTENSION] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ELEMENT, self::FIELD_EXTENSION, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_EXTENSION])) {\n $errs[self::FIELD_EXTENSION] = [];\n }\n $errs[self::FIELD_EXTENSION][$rule] = $err;\n }\n }\n }\n if (isset($validationRules[self::FIELD_ID])) {\n $v = $this->getId();\n foreach($validationRules[self::FIELD_ID] as $rule => $constraint) {\n $err = $this->_performValidation(PHPFHIRConstants::TYPE_NAME_ELEMENT, self::FIELD_ID, $rule, $constraint, $v);\n if (null !== $err) {\n if (!isset($errs[self::FIELD_ID])) {\n $errs[self::FIELD_ID] = [];\n }\n $errs[self::FIELD_ID][$rule] = $err;\n }\n }\n }\n return $errs;\n }", "public function messages() : array\n {\n return [\n 'department_id.required' => 'The department field is required.',\n 'user_group_id.required' => 'The user group field is required.',\n 'password.required_if' => 'The password field is required.',\n ];\n }", "public function messages()\n {\n return [\n 'style.required' => 'Please the style is required',\n 'service.required' => 'Please select service type',\n 'session.required' => 'Please select session'\n ];\n }", "public function messages()\n {\n return [\n 'candidates_needed.required' => 'The candidates number field is required!',\n 'start_posting_date.required' => 'The start posting date field is required!',\n 'end_posting_date.required' => 'The end posting date field is required!',\n 'appl_deadline_date.required' => 'The application deadline field is required!',\n 'start_trial_date.required' => 'The start trial field is required!',\n 'end_trial_date.required' => 'The end trial field is required!',\n ];\n }", "public function messages()\n {\n return [\n 'title.required' => 'A title is required',\n 'title.max' => 'Title is too long',\n 'image.required' => 'An image is required',\n ];\n }", "public function messages()\n {\n return [\n 'name.required' => 'A name is required.',\n 'color.required' => 'Please select a color.'\n ];\n }", "public function messages() {\n\t\treturn [\n\t\t\t'titulo.required' => 'El :attribute es obligatorio.',\n\t\t\t'descripcion.required' => 'La :attribute es obligatoria',\n\t\t\t'ciudad.required' => 'La :attribute es obligatoria',\n\t\t\t'telefono.required' => 'El :attribute es obligatorio.',\n\t\t\t'latitud.required' => 'La :attribute es obligatoria',\n\t\t\t'longitud.required' => 'La :attribute es obligatoria',\n\t\t\t'subcategoria.required' => 'La :attribute es obligatoria',\n\t\t\t'tags.required' => 'Los :attribute son obligatorios',\n\t\t];\n\t}", "public function messages() {\n return [\n 'name.required' => 'Missing name.',\n 'description.required' => 'Missing description.',\n 'max_level.required' => 'Missing max level.',\n 'bonus_per_level.required' => 'Missing bonus per level.',\n 'effect_type.required' => 'Missing effect type.',\n 'hours_per_level.required' => 'Missing length of time per level.'\n ];\n }", "public function messages()\n {\n return [\n 'contractor_account_id.exists' => 'Invalid data.',\n 'truck_id.exists' => 'Invalid data.',\n 'source_id.exists' => 'Invalid data.',\n 'destination_id.exists' => 'Invalid data.',\n 'driver_id.exists' => 'Invalid data.',\n 'material_id.exists' => 'Invalid data.',\n ];\n }", "public function getErrors()\n {\n return $this->_arrValidationErrors;\n }", "public function messages()\n {\n return [\n 'origin.required' => 'INVALID_PARAMETERS',\n 'destination.required' => 'INVALID_PARAMETERS',\n ];\n }", "public function messages()\n {\n return [\n 'name.required' => 'Name is required!',\n 'category.required' => 'category is required!',\n 'price.required' => 'price is required!',\n 'price.regex' => 'invalid price!',\n 'weight.required' => 'weight is required!',\n 'stock.required' => 'stock is required!',\n 'stock.integer' => 'invalid stock!',\n 'files.mimes' => 'invalid File(s)!',\n 'files.max' => 'File size must be 2MB or lesser !',\n ];\n }", "public function messages()\n {\n return [\n 'first_name.required' => 'First name cannot be blank.',\n 'first_name.string' => 'First name must be formatted as a string.',\n 'first_name.max' => 'First name exceeded the max number of characters.',\n 'last_name.required' => 'Last name cannot be blank.',\n 'last_name.string' => 'Last name must be formatted as a string.',\n 'last_name.max' => 'Last name exceeded the max number of characters.',\n 'email.required' => 'Email cannot be blank.',\n 'email.string' => 'Email name must be formatted as a string.',\n 'email.email' => 'Email must be formatted as a valid email address',\n 'email.max' => 'Email exceeded the max number of characters.',\n ];\n }", "public function messages()\n {\n return [\n 'name' => 'required',\n 'address' => 'required',\n 'city' => 'required',\n 'latitude' => 'required',\n 'longitude' => 'required',\n 'type' => 'required',\n 'is_public' => 'required',\n 'school_zone' => 'required',\n ];\n }", "public function getErrors()\n {\n return $this->validator->errors();\n }", "public function getValidationErrors()\n\t{\n\t\tif(is_array($this->validation_errors) && \n\t\t\tsizeof($this->validation_errors))\n\t\t{\n\t\t\treturn array_unique($this->validation_errors);\n\t\t}\n\t\treturn array();\n\t}", "public function messages()\n {\n return [\n 'name.required' => 'Full Name is required',\n 'name.min' => 'Name must be of minimum 3 characters',\n 'name.max' => 'Name can be of maximum 190 characters',\n 'support_pin.required' => 'Support PIN is required',\n 'support_pin.numeric' => 'Support PIN can only be numeric',\n 'support_pin.digits' => 'Only 4 digit Support PIN is accepted',\n 'rng_level.required' => 'Random Generator Difficutly is required',\n 'rng_level.numeric' => 'Invalid Random Generator Setting',\n 'rng_level.digits' => 'Invalid Random Generator Setting',\n 'dob.required' => 'Date of Birth is required',\n 'mobile.required' => 'Mobile Number is required',\n 'mobile.numeric' => 'Mobile Number can only be numeric',\n 'country' => 'Country is required',\n ];\n }", "public function getErrors()\n\t{\n\t\t$errors = array();\n\t\t/** @var Miao_Form_Control $control */\n\t\t/** @var Miao_Form_Validate $validator */\n\t\tforeach ( $this->getControls() as $control )\n\t\t{\n\t\t\tif ( !$control->isValid() )\n\t\t\t{\n\t\t\t\t$validator = $control->error();\n\t\t\t\t$errors[] = array(\n\t\t\t\t\t'name' => $control->getName(),\n\t\t\t\t\t'error' => $validator->getMessage() );\n\t\t\t}\n\t\t}\n\t\treturn $errors;\n\t}", "public function messages()\n {\n return [\n 'title.required' => Lang::get('controller.title_required'),\n 'title.string' => Lang::get('controller.title_required'),\n 'description.required' => Lang::get('controller.description_required'),\n 'topic_id.required' => Lang::get('controller.topic_id_required'),\n 'grade_id.required' => Lang::get('controller.grade_id_required'),\n 'skill_category_id.required' => Lang::get('controller.skill_category_id_required'),\n 'language_id.required' => Lang::get('controller.language_id_required'),\n 'publish_status.required' => Lang::get('controller.publish_status_required'),\n 'minimum_age.required' => Lang::get('controller.minimum_age_required'),\n 'maximum_age.required' => Lang::get('controller.maximum_age_required'),\n ];\n }", "public function messages()\n {\n return [\n 'created_by_id.required' => 'Employer Id is required',\n 'created_by_id.numeric' => 'Employer Id must be an integer type',\n 'team_name.required' => 'Team Name is required',\n 'team_name.string' => 'Team Name must be a string type',\n 'company_id.required' => 'Company Id is required',\n 'company_id.numeric' => 'Company Id must be an integer',\n ];\n }", "public function messages()\n {\n return array_merge(trans('news::validation'), trans('news::validation.custom'));\n }", "protected function messages()\n {\n return [\n 'id.required' => HttpAttributeInvalidCode::ID_REQUIRED,\n 'password.required' => HttpAttributeInvalidCode::PASSWORD_REQUIRED,\n 'password.same' => HttpAttributeInvalidCode::CONFIRM_PASSWORD_NOT_SAME,\n 'display_name.required' => HttpAttributeInvalidCode::DISPLAY_NAME_REQUIRED,\n 'role_id.required' => HttpAttributeInvalidCode::ROLE_REQUIRED,\n 'status.required' => HttpAttributeInvalidCode::STATUS_REQUIRE\n ];\n }", "function getValidationRules() {\n\t\treturn array(\n\t\t\t'_MovieID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_UserID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CountryID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_BroadCastDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t\t'_CreatedDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t);\n\t}", "public function messages()\n {\n $illegalFields = [ 'email', 'type', 'status', 'branches', ];\n $messages = [];\n\n foreach ($illegalFields as $key => $attribute) {\n $messages[\"{$attribute}.not_present\"] = __('The field :attribute must not be present.');\n }\n\n return $messages;\n }", "public function messages()\n {\n return [\n 'truck_id.required' => 'The truck field is required.',\n 'truck_id.exists' => 'Invalid data.',\n 'account_id.required' => 'The supplier field is required.',\n 'account_id.exists' => 'Invalid data.'\n ];\n }", "public function getValidationErrors() {\n\t\tif ($this->_errors === null) {\n\t\t\treturn array();\n\t\t}\n\n\t\treturn $this->_errors->toArray();\n\t}", "public function getErrors(): array {\n return $this->validationError;\n }", "function getErrors()\n {\n $errMsg = '';\n foreach ($this->errors as $error) {\n $errMsg .= $error;\n $errMsg .= '<br/>';\n }\n return $errMsg;\n }", "public function messages()\n {\n return $messages = [\n 'source_funds.required' => trans('common.error_messages.req_this_field'),\n 'jurisdiction_funds.required' => trans('common.error_messages.req_this_field'),\n 'annual_income.required' => trans('common.error_messages.req_this_field'),\n 'other_source.required' => trans('common.error_messages.req_this_field'),\n 'estimated_wealth.required' => trans('common.error_messages.req_this_field'),\n 'wealth_source.required' => trans('common.error_messages.req_this_field'),\n 'other_wealth_source.required' => trans('common.error_messages.req_this_field'),\n 'tin_code.required' => trans('common.error_messages.req_this_field'),\n 'is_abandoned.required' => trans('common.error_messages.req_this_field'),\n 'date_of_abandonment.required' => trans('common.error_messages.req_this_field'),\n 'abandonment_reason.required' => trans('common.error_messages.req_this_field'),\n 'justification.required' => trans('common.error_messages.req_this_field'),\n 'tin_country_name.required' => trans('common.error_messages.req_this_field'),\n 'tin_number.required' => trans('common.error_messages.req_this_field'),\n ];\n }", "function getValidationRules() {\n\t\treturn array(\n\t\t\t'_ID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CoverImageID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_TrackID' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_Status' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_Rank' => array(\n\t\t\t\t'number' => array(),\n\t\t\t),\n\t\t\t'_CreateDate' => array(\n\t\t\t\t'dateTime' => array(),\n\t\t\t),\n\t\t);\n\t}", "public function messages()\n {\n /*\n return [\n 'bio.required' => 'Bio is required',\n 'state.required' => 'State is required',\n 'city.required' => 'City name is required',\n 'postalcode.required' => 'Postal Code is required',\n 'gender.required' => 'Gender is required',\n 'seeking_gender.requred' => 'Gender you are searching for is required',\n ];\n */\n }", "private function getValidationRules(): array\n {\n return [\n 'year_month' => new Assert\\DateTime(\n [\n 'format' => 'Y-m',\n 'message' => 'Unexpected $yearMonth value. `Y-m` format is expected.',\n ]\n ),\n 'months_count' => new Assert\\Range(\n [\n 'min' => 1,\n 'max' => 12,\n 'minMessage' => 'Months count must be at least {{ limit }}',\n 'maxMessage' => 'Months count must not be greater than {{ limit }}',\n ]\n ),\n ];\n }", "public function getErrorMessages(){\n return $this->arr_msg; \n }" ]
[ "0.82462656", "0.8072122", "0.79855305", "0.7869173", "0.7831077", "0.7776483", "0.7776483", "0.7589036", "0.75582355", "0.75402904", "0.75402904", "0.7525044", "0.75227535", "0.7516879", "0.7475822", "0.7457696", "0.7425241", "0.74180096", "0.7405273", "0.7405273", "0.7400484", "0.7395581", "0.7392798", "0.7389888", "0.7360024", "0.73180616", "0.73162127", "0.7305573", "0.7279752", "0.7274237", "0.7268171", "0.7261277", "0.7242113", "0.72149134", "0.7214028", "0.7211038", "0.72069424", "0.7205835", "0.71890676", "0.7186795", "0.7184488", "0.71786416", "0.7169952", "0.7161326", "0.715333", "0.7151148", "0.7149324", "0.7133506", "0.712178", "0.7110109", "0.71095705", "0.7093795", "0.7087011", "0.70712256", "0.7070143", "0.70600915", "0.7059444", "0.7056968", "0.704947", "0.70437986", "0.70437384", "0.7041736", "0.7038512", "0.7036984", "0.7032627", "0.70229805", "0.70208246", "0.702044", "0.7007877", "0.7000938", "0.69963926", "0.69936424", "0.69912916", "0.6985551", "0.6982829", "0.6981308", "0.6980877", "0.6979931", "0.69782096", "0.6977083", "0.69753224", "0.69692177", "0.6966572", "0.6958873", "0.6957573", "0.6957456", "0.6944549", "0.69384116", "0.6934856", "0.69259256", "0.6918059", "0.6914203", "0.6909962", "0.69095904", "0.6906319", "0.6900933", "0.6900174", "0.6893932", "0.6892958", "0.68911815", "0.6887292" ]
0.0
-1
Add course/group container info
function addContainerInfo($a_obj_id) { $refs = $this->getReadableRefIds($a_obj_id); $ref_id = current($refs); if (count($refs) == 1 && $ref_id > 0) { $tree = $this->tree; $f = $this->ui->factory(); $r = $this->ui->renderer(); //parent course or group title $cont_ref_id = $tree->checkForParentType($ref_id, 'grp'); if ($cont_ref_id == 0) { $cont_ref_id = $tree->checkForParentType($ref_id, 'crs'); } if ($cont_ref_id > 0) { $type = ilObject::_lookupType($cont_ref_id, true); $href = ilLink::_getStaticLink($cont_ref_id); $parent_title = ilObject::_lookupTitle(ilObject::_lookupObjectId($cont_ref_id)); $this->addInfoProperty($this->lng->txt("obj_" . $type), $r->render($f->button()->shy($parent_title, $href))); $this->addListItemProperty($this->lng->txt("obj_" . $type), $r->render($f->button()->shy($parent_title, $href))); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function processContainer()\n {\n $class = \"container\";\n if ($this->hasFluid()) $class .= \"-fluid\";\n $this->add($this->createWrapper('div', ['class' => $class], $this->stringifyHeader() . $this->stringifyCollapse()));\n }", "public function add_course_view(){\n\n\t\t$headerData = null;\n\t\t$sidebarData = null;\n\t\t$page = 'admin/add_course';\n\t\t$mainData = array(\n\t\t\t'pagetitle'=> 'Add course',\n\t\t\t'course_list'=> $this->setting_model->Get_All('course'),\n\t\t);\n\t\t$footerData = null;\n\n\t\t$this->template($headerData, $sidebarData, $page, $mainData, $footerData);\n\t}", "function gotravel_mikado_add_admin_container($attributes) {\n\t\t$name = '';\n\t\t$parent = '';\n\t\t$hidden_property = '';\n\t\t$hidden_value = '';\n\t\t$hidden_values = array();\n\n\t\textract($attributes);\n\n\t\tif(!empty($name) && is_object($parent)) {\n\t\t\t$container = new GoTravelMikadoContainer($name, $hidden_property, $hidden_value, $hidden_values);\n\t\t\t$parent->addChild($name, $container);\n\n\t\t\treturn $container;\n\t\t}\n\n\t\treturn false;\n\t}", "public function addContainer($name, $label = NULL, $required = FALSE)\n\t{\n\t\t$control = new FormContainer;\n\t\t$control->label = $label;\n\t\t//$control->setOption('inline') = TRUE; // vnoreny container\n\t\tif($required) $control->setOption('required', TRUE);\n\t\t//$control->currentGroup = $this->currentGroup;\n\t\treturn $this[$name] = $control;\n\t}", "function cm_add_meta_box_course() {\n\n\t$screens = array( 'course' );\n\n\n$post_id = $_GET['post'] ? $_GET['post'] : $_POST['post_ID'] ;\n // check for a template type\n \n \n\tforeach ( $screens as $screen ) {\n\n\t\n add_meta_box(\n\t\t\t'myplugin_sectionid',\n\t\t\t__( 'Course Information', 'lps_wp' ),\n\t\t\t'cm_meta_box_course_callback',\n\t\t\t$screen\n\t\t);\n \n\t\t\n\t}\n}", "public function addContainer($data) {\n try {\n $client = new Zend_Soap_Client($this->CONTAINER_WSDL_URI);\n $options = array('soap_version' => SOAP_1_1,\n 'encoding' => 'ISO-8859-1',\n );\n $client->setOptions($options);\n $client->action = 'createContainer';\n $result = $client->createContainer(\n $this->toXml(\n array(\n 'backgroundColor' => $data['backgroundColor'],\n 'borderBottom' => $data['borderBottom'],\n 'borderBottomColor' => $data['borderBottomColor'],\n 'borderBottomStyle' => $data['borderBottomStyle'],\n 'borderBottomUnit ' => $data['borderBottomUnit'],\n 'borderLeft' => $data['borderLeft'],\n 'borderLeftColor' => $data['borderLeftColor'],\n 'borderLeftStyle' => $data['borderLeftStyle'],\n 'borderLeftUnit' => $data['borderLeftUnit'],\n 'borderRight' => $data['borderRight'],\n 'borderRightColor' => $data['borderRightColor'],\n 'borderRightStyle' => $data['borderRightStyle'],\n 'borderRightUnit' => $data['borderRightUnit'],\n 'borderTop' => $data['borderTop'],\n 'borderTopColor' => $data['borderTopColor'],\n 'borderTopStyle' => $data['borderTopStyle'],\n 'borderTopUnit' => $data['borderTopUnit'],\n 'bottomMargin' => $data['bottomMargin'],\n 'bottomMarginUnit' => $data['bottomMarginUnit'],\n 'bottomPadding' => $data['bottomPadding'],\n 'bottomPaddingUnit' => $data['bottomPaddingUnit'],\n 'containerHeight' => $data['containerHeight'],\n 'containerId' => $data['containerId'],\n 'containerName' => $data['containerName'],\n 'containerWidth' => $data['containerWidth'],\n 'containerXaxis' => $data['containerXaxis'],\n 'containerYaxis' => $data['containerYaxis'],\n 'css' => $data['css'],\n 'font' => $data['font'],\n 'fontAlignment' => $data['fontAlignment'],\n 'fontColor' => $data['fontColor'],\n 'fontSize' => $data['fontSize'],\n 'isActive' => true,\n 'isBold' => $data['isBold'],\n 'isBorderColorSameForAll' => $data['isBorderColorSameForAll'],\n 'isBorderStyleSameForAll' => $data['isBorderStyleSameForAll'],\n 'isBorderWidthSameForAll' => $data['isBorderWidthSameForAll'],\n 'isItalic' => $data['isItalic'],\n 'isMargineSameForAll' => $data['isMargineSameForAll'],\n 'isPaddingSameForAll' => $data['isPaddingSameForAll'],\n 'leftMargin' => $data['leftMargin'],\n 'leftMarginUnit' => $data['leftMarginUnit'],\n 'leftPadding' => $data['leftPadding'],\n 'leftPaddingUnit' => $data['leftPaddingUnit'],\n 'letterSpacing' => $data['letterSpacing'],\n 'lineHeight' => $data['lineHeight'],\n 'primaryKey' => 0,\n 'rightMargin' => $data['rightMargin'],\n 'rightMarginUnit' => $data['rightMarginUnit'],\n 'rightPadding' => $data['rightPadding'],\n 'rightPaddingUnit' => $data['rightPaddingUnit'],\n 'textDecoration' => $data['textDecoration'],\n 'topMargin' => $data['topMargin'],\n 'topMarginUnit' => $data['topMarginUnit'],\n 'topPadding' => $data['topPadding'],\n 'topPaddingUnit' => $data['topPaddingUnit'],\n 'updatedby' => $_SESSION['Username'],\n 'updatedt' => date('Y-m-d') . 'T' . date('H:i:s') . 'Z',\n 'wordSpacing' => $data['wordSpacing'],\n )\n ,$rootNodeName = 'AddContainer')\n );\n return $result;\n } catch (Exception $e) {\n // print_r($e);\n }\n }", "public function addContainer(&$container)\n {\n parent::addContainer($container);\n \n if (ObjectIntrospector::isA($container, 'TabPage') && $this->activeTabPagePersistor->getValue() == '')\n $this->activeTabPagePersistor->setValue($container->getName());\n }", "public function add()\n {\n $course_description = new CourseDescription();\n $session_id = api_get_session_id();\n $course_description->set_session_id($session_id);\n\n $data = array();\n if (strtoupper($_SERVER['REQUEST_METHOD']) == \"POST\") {\n if (!empty($_POST['title']) && !empty($_POST['contentDescription'])) {\n if (1) {\n $title = $_POST['title'];\n $content = $_POST['contentDescription'];\n $description_type = $_POST['description_type'];\n if ($description_type >= ADD_BLOCK) {\n $course_description->set_description_type($description_type);\n $course_description->set_title($title);\n $course_description->set_content($content);\n $course_description->insert(api_get_course_int_id());\n }\n\n Display::addFlash(\n Display::return_message(\n get_lang('CourseDescriptionUpdated')\n )\n );\n }\n $this->listing(false);\n } else {\n $data['error'] = 1;\n $data['default_description_titles'] = $course_description->get_default_description_title();\n $data['default_description_title_editable'] = $course_description->get_default_description_title_editable();\n $data['default_description_icon'] = $course_description->get_default_description_icon();\n $data['question'] = $course_description->get_default_question();\n $data['information'] = $course_description->get_default_information();\n $data['description_title'] = $_POST['title'];\n $data['description_content'] = $_POST['contentDescription'];\n $data['description_type'] = $_POST['description_type'];\n $this->view->set_data($data);\n $this->view->set_layout('layout');\n $this->view->set_template('add');\n $this->view->render();\n }\n } else {\n $data['default_description_titles'] = $course_description->get_default_description_title();\n $data['default_description_title_editable'] = $course_description->get_default_description_title_editable();\n $data['default_description_icon'] = $course_description->get_default_description_icon();\n $data['question'] = $course_description->get_default_question();\n $data['information'] = $course_description->get_default_information();\n $data['description_type'] = $course_description->get_max_description_type();\n // render to the view\n $this->view->set_data($data);\n $this->view->set_layout('layout');\n $this->view->set_template('add');\n $this->view->render();\n }\n }", "public function container();", "public function addCourse()\n {\n Logger::Log(\n 'starts POST AddCourse',\n LogLevel::DEBUG\n );\n\n $body = $this->app->request->getBody();\n\n $course = Course::decodeCourse($body);\n\n foreach ( $this->_createCourse as $_link ){\n $result = Request::routeRequest(\n 'POST',\n '/course',\n array(),\n Course::encodeCourse($course),\n $_link,\n 'course'\n );\n\n // checks the correctness of the query\n if ( $result['status'] >= 200 &&\n $result['status'] <= 299 ){\n\n $this->app->response->setStatus( 201 );\n if ( isset( $result['headers']['Content-Type'] ) )\n $this->app->response->headers->set(\n 'Content-Type',\n $result['headers']['Content-Type']\n );\n\n } else {\n\n /* if ($course->getId()!==null){\n $this->deleteCourse($course->getId());\n }*/\n\n Logger::Log(\n 'POST AddCourse failed',\n LogLevel::ERROR\n );\n $this->app->response->setStatus( isset( $result['status'] ) ? $result['status'] : 409 );\n $this->app->response->setBody( Course::encodeCourse( $course ) );\n $this->app->stop( );\n }\n }\n\n $this->app->response->setBody( Course::encodeCourse( $course ) );\n }", "function add_sections_and_fields(): void {}", "public static function addCourse()\n {\n global $cont;\n if(!empty($_POST['script']))\n {\n session_start();\n $_SESSION['message'] = \"you are script\";\n header(\"location:../admin/pages/forms/add-course.php\");\n die();\n }\n $title = $_POST['title'];\n $price = $_POST['price'];\n $body = $_POST['body'];\n $categoryId = $_POST['cat_id'];\n \n $imageName = $_FILES['image']['name'];\n $imageType = $_FILES['image']['type'];\n $imageTmp = $_FILES['image']['tmp_name'];\n \n\n $imageExt = Courses::checkImageExt($imageType); \n\n if($imageExt == 0 )\n {\n session_start();\n $_SESSION['error'] = \"U Must Upload Correct File\";\n header(\"location:../admin/pages/forms/add-course.php\");\n die();\n }\n\n \n $imageLink = dirname(__FILE__) . \"/../admin/pages/upload/courses/\";\n\n $avatarName = Courses::chekImageExist(time() . \"_\" . $imageName);\n\n move_uploaded_file($imageTmp , $imageLink.$avatarName);\n\n\n $courses = $cont->prepare(\"INSERT INTO courses(title , price , `image` , body , catagory_id) VALUES (? , ? , ? , ? , ?) \");\n $courses->execute([$title , $price , $avatarName , $body , $categoryId]);\n session_start();\n $_SESSION['message'] = \"course was created\";\n header(\"location:../admin/pages/tables/Courses.php\");\n \n }", "public function create()\n {\n \n $courseContainer = new CourseContainer();\n $action = route('course-containers.store');\n $method = '';\n\n return view('admin.course-containers.create-edit', compact('courseContainer', 'action', 'method'));\n }", "public function frontpage_available_courses() {\n\n global $CFG , $DB;\n $coursecontainer = '';\n $chelper = new coursecat_helper();\n $chelper->set_show_courses(self::COURSECAT_SHOW_COURSES_EXPANDED)->set_courses_display_options( array(\n 'recursive' => true,\n 'limit' => $CFG->frontpagecourselimit,\n 'viewmoreurl' => new moodle_url('/course/index.php'),\n 'viewmoretext' => new lang_string('fulllistofcourses')\n ));\n\n $chelper->set_attributes( array( 'class' => 'frontpage-course-list-all frontpageblock-theme' ) );\n\n $courses = core_course_category::get(0)->get_courses( $chelper->get_courses_display_options() );\n\n $totalcount = core_course_category::get(0)->get_courses_count( $chelper->get_courses_display_options() );\n\n $rcourseids = array_keys( $courses );\n\n //$acourseids = array_chunk( $rcourseids, 6);\n $acourseids = $rcourseids;\n $tcount = count($acourseids);\n\n $newcourse = get_string( 'availablecourses' );\n $header = \"\";\n $header .= html_writer::tag('div', \"<div></div>\", array('class' => 'bgtrans-overlay'));\n\n $header .= html_writer::start_tag('div',\n array( 'class' => 'available-courses', 'id' => 'available-courses') );\n $header .= html_writer::start_tag('div', array( 'class' => 'available-overlay' ) );\n $header .= html_writer::start_tag('div', array( 'class' => 'available-block' ) );\n $header .= html_writer::start_tag('div', array('class' => 'container'));\n $header .= html_writer::tag('h2', get_string('availablecourses'));\n\n /* if ($tcount > '1') {\n $header .= html_writer::start_tag('div', array('class' => 'pagenav slider-nav') );\n $header .= html_writer::tag('button', '', array('class' => 'slick-prev nav-item previous', 'type' => 'button') );\n $header .= html_writer::tag('button', '', array('class' => 'slick-next nav-item next', 'type' => 'button') );\n $header .= html_writer::tag('div', '', array('class' => 'clearfix') );\n $header .= html_writer::end_tag('div');\n }*/\n $sliderclass = 'course-slider';\n $header .= html_writer::start_tag('div', array('class' => 'row') );\n $header .= html_writer::start_tag('div', array( 'class' => \" $sliderclass col-md-12\") );\n\n $footer = html_writer::end_tag('div');\n $footer .= html_writer::end_tag('div');\n $footer .= html_writer::end_tag('div');\n $footer .= html_writer::end_tag('div');\n if (count($rcourseids) > 0) {\n $i = '0';\n /* foreach ($acourseids as $courseids) {\n\n $rowcontent = '<div class=\"slider-row \">';*/\n $rowcontent = '';\n foreach ($acourseids as $courseid) {\n $container = '';\n $course = get_course($courseid);\n $noimgurl = $this->output->image_url('no-image', 'theme');\n $courseurl = new moodle_url('/course/view.php', array('id' => $courseid ));\n\n if ($course instanceof stdClass) {\n $course = new core_course_list_element($course);\n }\n\n $imgurl = '';\n $context = context_course::instance($course->id);\n\n foreach ($course->get_course_overviewfiles() as $file) {\n $isimage = $file->is_valid_image();\n $imgurl = file_encode_url(\"$CFG->wwwroot/pluginfile.php\",\n '/'. $file->get_contextid(). '/'. $file->get_component(). '/'.\n $file->get_filearea(). $file->get_filepath(). $file->get_filename(), !$isimage);\n if (!$isimage) {\n $imgurl = $noimgurl;\n }\n }\n\n if (empty($imgurl)) {\n $imgurl = $noimgurl;\n }\n\n $container .= html_writer::start_tag('div', array( 'class' => 'col-md-2') );\n $container .= html_writer::start_tag('div', array( 'class' => 'available-content'));\n $container .= html_writer::start_tag('div', array( 'class' => 'available-img'));\n\n $container .= html_writer::start_tag('a', array( 'href' => $courseurl) );\n $container .= html_writer::empty_tag('img',\n array(\n 'src' => $imgurl,\n 'width' => \"249\",\n 'height' => \"200\",\n 'alt' => $course->get_formatted_name() ) );\n $container .= html_writer::end_tag('a');\n $container .= html_writer::end_tag('div');\n $container .= html_writer::tag('h6', html_writer::tag('a',\n $course->get_formatted_name(),\n array( 'href' => $courseurl ) ),\n array('class' => 'title-text') );\n $container .= html_writer::end_tag('div');\n $container .= html_writer::end_tag('div');\n\n $rowcontent .= $container;\n }\n $i++;\n /*$rowcontent .= html_writer::end_tag('div');*/\n $coursecontainer .= $rowcontent;\n // }\n\n }\n $footer .= html_writer::end_tag('div');\n $footer .= html_writer::end_tag('div');\n $coursehtml = $header.$coursecontainer.$footer;\n return $coursehtml;\n\n if (!$totalcount && !$this->page->user_is_editing() && has_capability('moodle/course:create', context_system::instance())) {\n // Print link to create a new course, for the 1st available category.\n echo $this->add_new_course_button();\n }\n }", "public function add_sections()\n {\n }", "public function createContainer($name, $parentContainerName)\n {\n $newDG = new Container($this);\n $newDG->load_from_templateContainerXml();\n $newDG->setName($name);\n\n $parentNode = DH::findFirstElementOrCreate('parent', $newDG->xmlroot );\n DH::setDomNodeText($parentNode, $parentContainerName );\n\n $this->containers[] = $newDG;\n\n if( $this->version >= 70 )\n {\n if( $this->version >= 80 )\n $dgMetaDataNode = DH::findXPathSingleEntryOrDie('/config/readonly/max-internal-id', $this->xmlroot);\n else\n $dgMetaDataNode = DH::findXPathSingleEntryOrDie('/config/readonly/dg-meta-data/max-dg-id', $this->xmlroot);\n\n $dgMaxID = $dgMetaDataNode->textContent;\n $dgMaxID++;\n DH::setDomNodeText($dgMetaDataNode, \"{$dgMaxID}\");\n\n if( $this->version >= 80 )\n $dgMetaDataNode = DH::findXPathSingleEntryOrDie('/config/readonly/devices/entry[@name=\"localhost.localdomain\"]/container', $this->xmlroot);\n else\n $dgMetaDataNode = DH::findXPathSingleEntryOrDie('/config/readonly/dg-meta-data/dg-info', $this->xmlroot);\n\n if( $this->version >= 80 )\n $newXmlNode = DH::importXmlStringOrDie($this->xmldoc, \"<entry name=\\\"{$name}\\\"><id>{$dgMaxID}</id></entry>\");\n else\n $newXmlNode = DH::importXmlStringOrDie($this->xmldoc, \"<entry name=\\\"{$name}\\\"><dg-id>{$dgMaxID}</dg-id></entry>\");\n\n $dgMetaDataNode->appendChild($newXmlNode);\n }\n\n $parentContainer = $this->findContainer( $parentContainerName );\n if( $parentContainer === null )\n mwarning(\"Container '$name' has Container '{$parentContainerName}' listed as parent but it cannot be found in XML\");\n else\n {\n $parentContainer->_childContainers[$name] = $newDG;\n $newDG->parentContainer = $parentContainer;\n $newDG->addressStore->parentCentralStore = $parentContainer->addressStore;\n $newDG->serviceStore->parentCentralStore = $parentContainer->serviceStore;\n $newDG->tagStore->parentCentralStore = $parentContainer->tagStore;\n $newDG->scheduleStore->parentCentralStore = $parentContainer->scheduleStore;\n $newDG->appStore->parentCentralStore = $parentContainer->appStore;\n $newDG->securityProfileGroupStore->parentCentralStore = $parentContainer->securityProfileGroupStore;\n //Todo: swaschkut 20210505 - check if other Stores must be added\n //- appStore;scheduleStore/securityProfileGroupStore/all kind of SecurityProfile\n }\n\n return $newDG;\n }", "function addExtraCategoryFields($tag, $edit_form = false) {\n\t\tif($this->checkPermissions()) {\n\t\t\t$form_row_title = __('This category is a course', lepress_textdomain);\n\t\t\t$form_row_desc = __('Is this category a course for students ?', lepress_textdomain);\n\t\t\t$form_row_title2 = __('Open access course', lepress_textdomain);\n\t\t\t$form_row_desc2 = __('Can participant subscribe to this course without teacher\\'s verification ?', lepress_textdomain);\n\t\t\t$form_row_title3 = __('Course teachers', lepress_textdomain);\n\t\t\t$form_row_desc3 = __('Choose additional teachers for this course (Only current WordPress installation users).', lepress_textdomain);\n\t\t\t$form_row_title4 = __('Advertise this course', lepress_textdomain);\n\t\t\t$form_row_desc4 = __('Advertise this course on LePress Courses Sitewide widget ?', lepress_textdomain);\n\t\t\t$form_row_title5 = __('Close this course', lepress_textdomain);\n\t\t\t$form_row_desc5 = __('Close this course <b>CAUTION!</b> Cannot be undone! no changes can be made to course data!', lepress_textdomain);\n\t\t\t\n\t\t\tglobal $current_user;\n\t\t\tget_currentuserinfo();\n\t\t\tif(function_exists('get_users')) {\n\t\t\t\t$users = get_users(array('role' => 'lepress_teacher', 'exclude' => array($current_user->ID)));\n\t\t\t} else {\n\t\t\t\t$users = get_users_of_blog();\n\t\t\t}\n\t\t\t//Get also super admins, they are allowed to be teachers too\n\t\t\tif(is_super_admin()) {\n\t\t\t\tforeach(get_super_admins() as $super_user_login) {\n\t\t\t\t\t$user = get_user_by('login', $super_user_login);\n\t\t\t\t\t$users[] = $user;\n\t\t\t\t}\n\t\t\t}\n\t\t\t//If new category page\n\t\t\tif(!$edit_form) {\n\t\t\t\techo '<div class=\"form-field lepress-field\">';\n\t\t\t\techo '<input type=\"checkbox\" id=\"lepress-course\" name=\"lepress-course\" value=\"1\"/>';\n\t\t\t\techo '<label for=\"lepress-course\">'.$form_row_title.'</label>';\n\t\t\t\techo '<p>'.$form_row_desc.'</p>';\n\t\t\t\techo '</div>';\n\n\t\t\t\techo '<div class=\"form-field lepress-field\">';\n\t\t\t\techo '<input type=\"checkbox\" id=\"lepress-course-open-access\" name=\"lepress-course-open-access\" value=\"1\" />';\n\t\t\t\techo '<label for=\"lepress-course-open-access\">'.$form_row_title2.'</label>';\n\t\t\t\techo '<p>'.$form_row_desc2.'</p>';\n\t\t\t\techo '</div>';\n\n\t\t\t\techo '<div style=\"margin:0 0 10px; padding: 8px;\">';\n\t\t\t\techo '<input type=\"hidden\" value=\"'.$current_user->ID.'\" name=\"lepress-course-teachers['.$current_user->ID.']\" />';\n\t\t\t\techo '<label><b>'.$form_row_title3.'</b></label>';\n\t\t\t\tforeach($users as $user) {\n\t\t\t\t\tif($user->ID != $current_user->ID) {\n\t\t\t\t\t\t$userdata = get_userdata($user->ID);\n\t\t\t\t\t\techo '<input type=\"hidden\" name=\"lepress-course-teachers['.$user->ID.']\" value=\"0\"/>';\n\t\t\t\t\t\techo '<div style=\"margin-left: 4px;\"><input type=\"checkbox\" class=\"lepress-teacher\" value=\"'.$user->ID.'\" name=\"lepress-course-teachers['.$user->ID.']\" /> '.(!empty($userdata->user_firstname) ? $userdata->user_firstname : $userdata->user_login).' '.$userdata->user_lastname.'</div>';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//Found only one user - current user\n\t\t\t\tif(count($users) <= 1) {\n\t\t\t\t\techo '<p><b>'.__('No LePress teachers found', lepress_textdomain).' <a href=\"'.admin_url().'user-new.php'.'\">'.__('Add here', lepress_textdomain).'</a></b></p>';\n\t\t\t\t}\n\t\t\t\techo '<p>'.$form_row_desc3.'</p>';\n\t\t\t\techo '</div>';\n\t\t\t\t\n\t\t\t\t//IF multisite, add advertise checkbox\n\t\t\t\tif(is_multisite()) {\n\t\t\t\t\techo '<div class=\"form-field lepress-field\">';\n\t\t\t\t\techo '<input type=\"checkbox\" id=\"lepress-course-advertise\" name=\"lepress-course-advertise\" value=\"1\" />';\n\t\t\t\t\techo '<label for=\"lepress-course-advertise\">'.$form_row_title4.'</label>';\n\t\t\t\t\techo '<p>'.$form_row_desc4.'</p>';\n\t\t\t\t\techo '</div>';\n\t\t\t\t}\t\t\t\n\t\t\t} else { //If edit category page\n\t\t\t\t$course_meta = new CourseMeta($tag->term_id);\n\t\t\t\techo '<tr class=\"form-field\">';\n\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course\">'.$form_row_title.'</label></th>';\n\t\t\t\techo '<td><input type=\"hidden\" name=\"lepress-course\" value=\"0\"/>';\n\t\t\t\techo '<input type=\"checkbox\" class=\"lepress-edit-form-field\" id=\"lepress-course\" '.($course_meta->getIsCourse() ? 'checked=checked':'').' '.($course_meta->hasSubscriptions() ? 'disabled=\"disabled\"' : '').' name=\"lepress-course\" value=\"1\"/><br />';\n\t\t\t\techo '<span class=\"description\">'.$form_row_desc.' '.__('You <b>cannot change</b> this, if course has <b>active subscriptions</b>', lepress_textdomain).'</span></td>';\n\t\t\t\techo '</tr>';\n\n\t\t\t\techo '<tr class=\"form-field\">';\n\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course-open-access\">'.$form_row_title2.'</label></th>';\n\t\t\t\techo '<td><input type=\"hidden\" name=\"lepress-course-open-access\" value=\"0\" />';\n\t\t\t\techo '<input type=\"checkbox\" class=\"lepress-edit-form-field\" id=\"lepress-course-open-access\" '.($course_meta->getAccessType() ? 'checked=checked':'').' name=\"lepress-course-open-access\" value=\"1\"/><br />';\n\t\t\t\techo '<span class=\"description\">'.$form_row_desc2.'</span></td>';\n\t\t\t\techo '</tr>';\n\n\t\t\t\techo '<tr>';\n\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course-open-access\">'.$form_row_title3.'</label></th>';\n\t\t\t\techo '<td>';\n\t\t\t\tforeach($users as $user) {\n\t\t\t\t\tif($user->ID != $current_user->ID) {\n\t\t\t\t\t\t$userdata = get_userdata($user->ID);\n\t\t\t\t\t\t$isTeacher = $course_meta->isTeacher($user->ID) ? 'checked=\"checked\"' : '';\n\t\t\t\t\t\techo '<input type=\"hidden\" name=\"lepress-course-teachers['.$user->ID.']\" value=\"0\"/>';\n\t\t\t\t\t\techo '<div><input class=\"lepress-edit-form-field\" type=\"checkbox\" value=\"'.$user->ID.'\" '.$isTeacher.' name=\"lepress-course-teachers['.$user->ID.']\" /> '.(!empty($userdata->user_firstname) ? $userdata->user_firstname : $userdata->user_login).' '.$userdata->user_lastname.'</div>';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//Found only one user - current user\n\t\t\t\tif(count($users) <= 1) {\n\t\t\t\t\techo '<p><b>'.__('No LePress teachers found', lepress_textdomain).' <a href=\"'.admin_url().'user-new.php'.'\">'.__('Add here', lepress_textdomain).'</a></b></p>';\n\t\t\t\t}\n\t\t\t\techo '<span class=\"description\">'.$form_row_desc3.'</span></td>';\n\t\t\t\techo '</tr>';\n\t\t\t\t\n\t\t\t\t//IF is multisite, add advertise checkbox\n\t\t\t\tif(is_multisite()) {\n\t\t\t\t\techo '<tr class=\"form-field\">';\n\t\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course-open-access\">'.$form_row_title4.'</label></th>';\n\t\t\t\t\techo '<td><input type=\"hidden\" name=\"lepress-course-advertise\" value=\"0\" />';\n\t\t\t\t\techo '<input class=\"lepress-edit-form-field\" type=\"checkbox\" id=\"lepress-course-advertise\" '.($course_meta->getAdvertise() ? 'checked=checked':'').' name=\"lepress-course-advertise\" value=\"1\"/><br />';\n\t\t\t\t\techo '<span class=\"description\">'.$form_row_desc4.'</span></td>';\n\t\t\t\t\techo '</tr>';\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif(!$course_meta->getIsClosed()) {\n\t\t\t\t\techo '<tr class=\"form-field\">';\n\t\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course-locked\">'.$form_row_title5.'</label></th>';\n\t\t\t\t\techo '<td><input type=\"hidden\" name=\"lepress-course-locked\" value=\"0\" />';\n\t\t\t\t\techo '<input type=\"checkbox\" class=\"lepress-edit-form-field\" id=\"lepress-course-locked\" '.($course_meta->getIsClosed() ? 'checked=checked':'').' name=\"lepress-course-locked\" value=\"1\"/><br />';\n\t\t\t\t\techo '<span class=\"description\">'.$form_row_desc5.'</span></td>';\n\t\t\t\t\techo '</tr>';\n\t\t\t\t} else {\n\t\t\t\t\techo '<tr class=\"form-field\">';\n\t\t\t\t\techo '<th scope=\"row\" valign=\"top\"><label for=\"lepress-course-locked\">'.__('Export', lepress_textdomain).'</label></th>';\n\t\t\t\t\techo '<td>';\n\t\t\t\t\techo '<a href=\"\">'.__('Export current state',lepress_textdomain).'</a><br />';\n\t\t\t\t\techo '<a href=\"'.add_query_arg(array('page' => 'lepress-import-export', 'export_tpl' => $tag->term_id), admin_url().'admin.php').'\">'.__('Export as template (all assignments without students related information)', lepress_textdomain).'</a><br />';\n\t\t\t\t\techo '<span class=\"description\">'.__('Export this course data. \"Export current state\" exports also classbook, \"Export as template\" exports assginments and creates a new template.', lepress_textdomain).'</span></td>';\n\t\t\t\t\techo '</tr>';\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t}", "private function toContainer(): void\n {\n $configFiles = [\n 'config' => $this->configManager->getFilePath(),\n 'router' => $this->router->getFilePath(),\n ];\n $this->container::add('configFiles', $configFiles);\n $this->container::add('config', $this->configData);\n $this->container::add('defaultLang', $this->defaultLang);\n $this->container::add('request', $this->request);\n }", "public function addTextContainer($name, $content, $language);", "public function registerCourseClick ()\n {\n $objCourse = new Course();\n $result = $objCourse->fetchCoursename();\n if (! empty($result)) {\n $this->showSubViews(\"registerCourse\", $result);\n } else {\n $message = \"You cannnot register<br> No courses exist yet\";\n $this->setCustomMessage(\"ErrorMessage\", $message);\n }\n }", "function createCourse ($id, $name, $description) {\n\t\t\t\n\t\t}", "function CoursesBodyContent()\n\t{\tif ($this->can_resources)\n\t\t{\techo $this->course->HeaderInfo(), \"<div class='clear'></div>\\n\", $this->resource->InputForm($this->course->id);\n\t\t}\n\t}", "public function frontpage_my_courses() {\n\n global $USER, $CFG, $DB;\n $content = html_writer::start_tag('div', array('class' => 'frontpage-enrolled-courses') );\n $content .= html_writer::start_tag('div', array('class' => 'container'));\n $content .= html_writer::tag('h2', get_string('mycourses'));\n $coursehtml = parent::frontpage_my_courses();\n if ($coursehtml == '') {\n\n $coursehtml = \"<div id='mycourses'><style> #frontpage-course-list.frontpage-mycourse-list { display:none;}\";\n $coursehtml .= \"</style></div>\";\n }\n $content .= $coursehtml;\n $content .= html_writer::end_tag('div');\n $content .= html_writer::end_tag('div');\n\n return $content;\n }", "private function init_category_and_course() {\n global $DB;\n\n // Category.\n $category = new stdClass;\n $category->name = 'category';\n $category->id = $DB->insert_record('course_categories', $category);\n context_coursecat::instance($category->id);\n\n // Course.\n $coursedata = new stdClass;\n $coursedata->category = $category->id;\n $coursedata->fullname = 'fullname';\n $course = create_course($coursedata);\n\n return context_course::instance($course->id);\n }", "public function addCoursesPage(){\n return View('admin.addcourse');\n }", "function addComponent($data);", "public function add_course_subject(){\n\n\t\t$headerData = null;\n\t\t$sidebarData = null;\n\t\t$page = 'admin/add_course_module';\n\t\t$mainData = array(\n\t\t\t'pagetitle'=> 'Add courses Modules (Subjects)',\n\t\t\t'courses_lists'=> $this->setting_model->Get_All('course'),\n\t\t);\n\t\t$footerData = null;\n\n\t\t$this->template($headerData, $sidebarData, $page, $mainData, $footerData);\n\t}", "function add_course($course_details)\n\t{\n\t\t$query = 'INSERT INTO courses (name, description, created_at, updated_at) \n\t\tVALUES (?,?,?,?)';\n\t\t$values = array($course_details['name'], $course_details['description'],\n\t\t\tdate(\"Y-m-d, H:i:s\"),date(\"Y-m-d, H:i:s\"));\n\t\treturn $this->db->query($query, $values);\n\t}", "public static function container()\n {\n $containerOutput = '[ServiceContainer]' . PHP_EOL;\n ServiceContainer::init();\n $services = ServiceContainer::getServiceCollection();\n $serviceDebug = [];\n foreach ($services as $name => $service) {\n $serviceDebug[] = [\n 'name' => $name,\n 'class' => get_class($service),\n ];\n }\n $containerOutput .= CLITableBuilder::init(\n $serviceDebug,\n ['Name', 'Class'],\n false,\n 10\n );\n CLIShellColor::commandOutput($containerOutput.PHP_EOL, 'white', 'green');\n }", "private function addSection() {\n // courseid, secNo, daysMet, startTime, endTime, totalReleasedSeats, building, room\n\n $courseID = $_POST['courseID'];\n $secNo = $_POST['secNo'];\n $daysMet = $_POST['daysMet'];\n $startTime = $_POST['startTime'];\n $endTime = $_POST['endTime'];\n $totalReleasedSeats = $_POST['totalReleasedSeats'];\n $building = $_POST['building'];\n $room = $_POST['room'];\n\n $this->openConn();\n\n $sql = \"SELECT DISTINCT term, secStartDate, secEndDate, sessionYear, sessionCode FROM Section WHERE courseID = :courseID\";\n $stmt = $this->conn->prepare($sql);\n $stmt->execute(array(':courseID'=> $courseID));\n\n while($row = $stmt->fetch(PDO::FETCH_ASSOC)) {\n $term = $row['term'];\n $secStartDate = $row['secStartDate'];\n $secEndDate = $row['secEndDate'];\n $sessionYear = $row['sessionYear'];\n $sessionCode = $row['sessionCode'];\n }\n\n $totalEnrolment = 0;\n $isOptimized = 0;\n $secType = \"LAB\";\n\n // if($row){\n //\n // }\n\n $sql2 = \"INSERT INTO Section (courseID, secNo, daysMet, startTime, endTime, totalReleasedSeats, totalEnrolment, building, room,\n term, isOptimized, secStartDate, secEndDate, sessionYear, sessionCode, secType)\n VALUES (:courseID, :secNo, :daysMet, :startTime, :endTime, :totalReleasedSeats, :totalEnrolment, :building, :room,\n :term, :isOptimized, :secStartDate, :secEndDate, :sessionYear, :sessionCode, :secType)\";\n $stmt2 = $this->conn->prepare($sql2);\n $stmt2->execute(array(':courseID'=> $courseID, ':secNo'=> $secNo, ':daysMet'=> $daysMet, ':startTime'=> $startTime, ':endTime'=> $endTime, ':totalReleasedSeats'=> $totalReleasedSeats, ':totalEnrolment'=> $totalEnrolment, ':building'=> $building, ':room'=> $room,\n ':term'=> $term, ':isOptimized'=> $isOptimized, ':secStartDate'=> $secStartDate, ':secEndDate'=> $secEndDate, ':sessionYear'=> $sessionYear, ':sessionCode'=> $sessionCode, ':secType'=> $secType));\n\n $this->closeConn();\n\n }", "function get_course_metadata($courseid) {\n $handler = \\core_customfield\\handler::get_handler('core_course', 'course');\n // This is equivalent to the line above.\n // $handler = \\core_course\\customfield\\course_handler::create();\n $datas = $handler->get_instance_data($courseid);\n $metadata = [];\n foreach ($datas as $data) {\n if (empty($data->get_value())) {\n continue;\n }\n $cat = $data->get_field()->get_category()->get('name');\n $metadata[$data->get_field()->get('shortname')] = $cat . ': ' . $data->get_value();\n }\n return $metadata;\n}", "function minorite_container($variables) {\n $element = $variables['element'];\n\n // Special handling for form elements.\n if (isset($element['#array_parents'])) {\n // Add the 'rw' and 'form-rw' class.\n $element['#attributes']['class'][] = 'rw';\n\n switch ($element['#type']) {\n case 'actions':\n break;\n\n default:\n $element['#attributes']['class'][] = 'form-rw';\n }\n }\n\n // Add the grid when specified.\n if (isset($element['#grid'])) {\n $element['#children'] = '<p class=\"' . $element['#grid'] . '\">' . $element['#children'] . '</p>';\n }\n\n return '<div' . drupal_attributes($element['#attributes']) . '>' . $element['#children'] . '</div>';\n}", "function display_courses_before( $section ) {\n\tif ( get_field( 'section_layout', $section ) !== 'courses' ) {\n\t\treturn '';\n\t}\n\n\treturn '<div id=\"coursesAccordion\" role=\"tablist\">';\n}", "public function __construct(Container $container){\n $this->container=$container;\n\n //config by default\n $this->config=$this->container['config'];\n $this->bigquery=$this->container['bigquery']($this->config->google('bigquery'));\n $this->modules['tc-subgroup']=$this->container['tc-subgroup']($this->bigquery);\n\n }", "function recommends_req_crstut_9_add_course($form, &$form_state) {\n // Everything in $form_state is persistent, so we'll just use\n // $form_state['add_course']\n $form_state['num_courses']++;\n\n // Setting $form_state['rebuild'] = TRUE causes the form to be rebuilt again.\n $form_state['rebuild'] = TRUE;\n}", "public function addcmsData(&$pages);", "public function store()\n {\n Permissions::getInstaince()->allow('course_store');\n\n\n if ($_SERVER[\"REQUEST_METHOD\"] == \"POST\") {\n $validate = \\Validation::validate([\n 'course_title' => array(['required' => 'required']),\n 'course_description' => array(['required' => 'required']),\n 'courses_image' => array(['imageRequired' => 'imageRequired']),\n 'course_price' => array(['required' => 'required']),\n 'course_price_afterDiscount' => array(['required' => 'required']),\n 'course_students_target' => array(['required' => 'required']),\n 'course_goals' => array(['required' => 'required']),\n 'categories_ids' => array(['hasElements' => 'hasElements']),\n 'course_owner' => array(['hasElements' => 'hasElements']),\n ]);\n if (count($validate) == 0) {\n if (isset($_FILES['courses_image']['name']))\n $image = Helper::saveImage('courses_image', 'images/courses/');\n $course = array(\n ':course_owner' => htmlentities($_REQUEST['course_owner']),\n ':course_title' => htmlentities($_REQUEST['course_title']),\n ':course_description' => htmlentities($_REQUEST['course_description']),\n ':courses_image' => $image,\n ':course_price' => htmlentities($_REQUEST['course_price']),\n ':course_price_afterDiscount' => htmlentities($_REQUEST['course_price_afterDiscount']),\n ':course_students_target' => htmlentities($_REQUEST['course_students_target']),\n ':course_goals' => htmlentities($_REQUEST['course_goals']),\n ':categories_ids' => json_encode($_REQUEST['categories_ids']),\n );\n $this->model('Course');\n $id = $this->model->add($course);\n if ($id) {\n Helper::back('/admin/courses/index', 'add successfully', 'success');\n return;\n }\n } else {\n Helper::back('/admin/courses/create', 'error in required input', 'danger');\n return;\n }\n }\n\n\n }", "public function __construct(Container $container){\n $this->container=$container;\n\n //config by default\n $this->config=$this->container['config'];\n $this->bigquery=$this->container['bigquery']($this->config->google('bigquery'));\n $this->modules['tc-group']=$this->container['tc-group']($this->bigquery);\n\n }", "public function addContent(Course $course) {\n\t\t$btnText = __(\"Adicionar\");\n\t\t$clases = $course->courseContent;\n\t\treturn view('courses.content_form',compact('course','btnText', 'clases'));\n\t}", "function CoursesLoggedInConstruct()\n\t{\tparent::CoursesLoggedInConstruct(\"resources\");\n\n\t\t$this->breadcrumbs->AddCrumb(\"courseresources.php?cid={$this->course->id}\", \"Resources\");\n\t\tif ($this->resource->id)\n\t\t{\t$this->breadcrumbs->AddCrumb(\"courseresource.php?id={$this->resource->id}\", $this->InputSafeString($this->resource->details[\"crlabel\"]));\n\t\t} else\n\t\t{\t$this->breadcrumbs->AddCrumb(\"courseresource.php?cid={$this->course->id}\", \"Add new\");\n\t\t}\n\t}", "public function showPrepareAddCourse( $courses, $subjects )\n {\n // y Mostrar todos los cursos ya existentes.\n $this->smarty->assign( 'title_s', 'Admin: Add a course' );\n $this->smarty->assign( 'courses_s', $courses );\n $this->smarty->assign( 'subjects_s', $subjects );\n $this->smarty->display( 'templates/prepare_add_course.tpl' );\n }", "public function Populate() {\r\n\t\t$form_instance = $this->form_instance;\r\n\t\t// Retrieve the field data\r\n\t\t$_els = vcff_parse_container_data($form_instance->form_content);\r\n\t\t// If an error has been detected, return out\r\n\t\tif (!$_els || !is_array($_els)) { return; }\r\n\t\t// Retrieve the form instance\r\n\t\t$form_instance = $this->form_instance; \r\n\t\t// Loop through each of the containers\r\n\t\tforeach ($_els as $k => $_el) {\r\n\t\t\t// Retrieve the container instance\r\n\t\t\t$container_instance = $this->_Get_Container_Instance($_el);\r\n\t\t\t// Add the container to the form instance\r\n\t\t\t$form_instance->Add_Container($container_instance);\r\n\t\t}\r\n\t}", "function addCategory($data){\n\t\t\t\n\t\t\t$token = '847895ee848fdb5fb2d43b275705470c';\n\t\t\t$domainname = 'https://elearning.inaba.ac.id';\n\t\t\t$functionname = 'core_course_create_categories';\n\t\t\t$restformat = 'json';\n\t\t\t\t$category = new stdClass();\n\t\t\t\t$category->name=$data['nama'];\t\n\t\t\t\t$category->parent=$data['parent'];\t\t\t\t\t\n\t\t\t\t$category->description='<p>'.$data['nama'].'</p>';\n\t\t\t\t$category->idnumber=$data['idnumber'];\t\t\t\t\t\n\t\t\t\t$category->descriptionformat=1;\t\t\t\t\t\t\t\t\t\n\t\t\t\t$categories = array($category);\n\t\t\t\t$params = array('categories' => $categories);\n\t\t\t\t/// REST CALL\n\t\t\t\t//header('Content-Type: text/plain');\n\t\t\t\t$serverurl = $domainname . '/webservice/rest/server.php'. '?wstoken=' . $token . '&wsfunction='.$functionname;\n\t\t\t\trequire_once($conf['model_dir'].'m_curl.php');\n\t\t\t\t$curl = new curl;\n\t\t\t\t//if rest format == 'xml', then we do not add the param for backward compatibility with Moodle < 2.2\n\t\t\t\t$restformat = ($restformat == 'json')?'&moodlewsrestformat=' . $restformat:'';\n\t\t\t\t$resp = $curl->post($serverurl . $restformat, $params);\n\t\t\t\t$data = json_decode($resp, true);\n\t\t\t\t\n\t\t\t\t\n\n\t\t\n\n\t\t}", "public function addContainerServices()\n {\n $this->replaceParamsObject();\n\n $this->addCommonServices();\n\n if ( $this->container->platform->isBackend() )\n {\n $this->addAdminServices();\n }\n else\n {\n $this->addSiteServices();\n }\n }", "function _hps_courses_instances() {\n $fields = _hps_courses_fields();\n return array(\n 'field_collection_item' => array(\n 'hps_course_participants' => array(\n 'hps_participant_first_name' => $fields['hps_participant_first_name'],\n 'hps_participant_last_name' => $fields['hps_participant_last_name'],\n 'hps_participant_id' => $fields['hps_participant_id'],\n 'hps_participant_role' => $fields['hps_participant_role'],\n 'hps_participant_notes' => $fields['hps_participant_notes'],\n 'hps_person_authority' => $fields['hps_person_authority'],\n ),\n 'hps_course_items' => array(\n 'hps_course_item_type' => $fields['hps_course_item_type'],\n 'hps_course_item_uri' => $fields['hps_course_item_uri'],\n 'hps_course_item_entity' => $fields['hps_course_item_entity'],\n ),\n ),\n 'node' => array(\n 'hps_course' => array(\n 'hps_course_name' => $fields['hps_course_name'],\n 'hps_course_year' => $fields['hps_course_year'],\n 'hps_course_notes' => $fields['hps_course_notes'],\n 'hps_course_participants' => $fields['hps_course_participants'],\n 'hps_course_items' => $fields['hps_course_items'],\n ),\n ),\n 'taxonomy_term' => array(\n 'hps_person_authority' => array(\n 'hps_person_authority_uuid' => $fields['hps_person_authority_uuid'],\n 'hps_person_authority_ids' => $fields['hps_person_authority_ids'],\n 'hps_person_authority_names' => $fields['hps_person_authority_names'],\n ),\n ),\n );\n}", "function showCardContainer()\n {\n // instantiate template class\n $tpl = new template;\n $tpl->setCacheLevel($this->cachelevel);\n $tpl->setCacheTtl($this->cachetime);\n $usecache = checkParameters();\n\n $template = $GLOBALS[\"templates_\".$this->language][$this->tmpl][1] . \"/\" . \"module_isic_list2.html\";\n\n $tpl->setInstance($_SERVER[\"PHP_SELF\"] . \"?language=\" . $this->language . \"&module=isic_experimental\");\n $tpl->setTemplateFile($template);\n\n // PAGE CACHED\n if ($tpl->isCached($template) == true && $usecache == true) {\n $GLOBALS[\"caching\"][] = \"isic_experimental\";\n if ($GLOBALS[\"modera_debug\"] == true) {\n return \"<!-- module isic_experimental cached -->\\n\" . $tpl->parse();\n }\n else {\n return $tpl->parse();\n }\n }\n\n $tpl->addDataItem(\"DATA_URL\", \"/?content={$this->vars['content']}\");\n $tpl->addDataItem(\"DATA_MAXROWS\", $this->maxresults);\n $tpl->addDataItem(\"DATA_FIELDS\", $this->getFieldList($this->fieldData['listview'], 'list'));\n $tpl->addDataItem(\"DATA_GRID_COLUMN\", $this->getFieldList($this->fieldData['listview'], 'grid_column'));\n $tpl->addDataItem(\"DATA_FILTERS\", $this->getFieldList($this->fieldData['filterview'], 'filters'));\n\n $tpl->addDataItem(\"DATA_FORM_COLUMNS\", $this->getColumnList());\n $fs_list = $this->getFieldSetList();\n $tpl->addDataItem(\"DATA_FORM_FIELDSETS\", JsonEncoder::encode($fs_list));\n $tpl->addDataItem(\"DATA_FORM_FIELDS\", $this->getFieldList($this->fieldData['detailview'], 'detail', $fs_list));\n $tpl->addDataItem(\"DATA_FORM_FIELDS_MAPPING\", $this->getFieldList($this->fieldData['detailview'], 'list'));\n return $tpl->parse();\n }", "public function containers()\n {\n }", "public function addContentData()\n\t\t{\n\t\t\t_is_logged_in();\n\n\t\t\t$data = array();\n\n\t\t\tif ($_POST) {\n\n\t\t\t\tforeach ($this->input->post() as $key => $value) {\n\n\t\t\t\t\tif ($key == 'section_name') {\n\t\t\t\t\t\t$data['section_slug'] = url_title(convert_accented_characters($value));\n\t\t\t\t\t}\n\t\t\t\t\t$data[$key] = $value;\n\t\t\t\t}\n\n\t\t\t\t$data['language'] = $this->session->userdata('language');\n\t\t\t}\n\n\t\t\t// Send data\n\t\t\t$query = $this->co_pages_model->add_section($data);\n\n\t\t\tif ($query > 0) {\n\t\t\t\tredirect('admin/co_pages/add_content?action=success');\n\t\t\t} else {\n\t\t\t\tredirect('admin/co_pages/add_content?action=error');\n\t\t\t}\n\n\t\t}", "public function getContainer() {}", "public function addChild($header = \"\");", "public function frontpage_available_courses() {\n global $CFG, $DB;\n\n $chelper = new coursecat_helper();\n $chelper->set_show_courses(self::COURSECAT_SHOW_COURSES_EXPANDED)->set_courses_display_options(array(\n 'recursive' => true,\n 'limit' => $CFG->frontpagecourselimit,\n 'viewmoreurl' => new moodle_url('/course/index.php'),\n 'viewmoretext' => new lang_string('fulllistofcourses')));\n\n $chelper->set_attributes(array('class' => 'frontpage-course-list-all'));\n $courses = core_course_category::get(0)->get_courses($chelper->get_courses_display_options());\n $totalcount = core_course_category::get(0)->get_courses_count($chelper->get_courses_display_options());\n if (!$totalcount &&\n !$this->page->user_is_editing() &&\n has_capability('moodle/course:create', \\context_system::instance())\n ) {\n // Print link to create a new course, for the 1st available category.\n return $this->add_new_course_button();\n }\n $latestcard = get_config('theme_remui', 'enablenewcoursecards');\n $coursehtml = '<div class=\"\">\n <div class=\"card-deck slick-course-slider slick-slider ' . ($latestcard ? 'latest-cards' : '') . '\">';\n\n if (!empty($courses)) {\n foreach ($courses as $course) {\n $coursesummary = strip_tags($chelper->get_course_formatted_summary(\n $course,\n array('overflowdiv' => false, 'noclean' => false, 'para' => false)\n ));\n $coursesummary = strlen($coursesummary) > 100 ? substr($coursesummary, 0, 100).\"...\" : $coursesummary;\n $image = \\theme_remui_coursehandler::get_course_image($course, 1);\n $coursename = strip_tags($chelper->get_course_formatted_name($course));\n if (!$latestcard) {\n $coursehtml .= \"\n <div class='card w-100 rounded-bottom mx-0 bg-transparent d-inline-flex flex-column' style='height: 100%;'>\n <div class='m-2 bg-white border' style='height: 100%;'>\n <div\n class='rounded-top'\n style='height: 200px;\n background-image: url({$image});\n background-size: cover;\n background-position: center;\n box-shadow: 0 2px 5px #cccccc;'>\n </div>\n <div class='card-body p-3'>\n <h4 class='card-title m-1 ellipsis ellipsis-2'>\n <a\n href='{$CFG->wwwroot}/course/view.php?id={$course->id}'\n class='font-weight-400 blue-grey-600 font-size-18'>\n {$coursename}\n </a>\n </h4>\n <p class='card-text m-1'>{$coursesummary}</p>\n </div>\n </div>\n </div>\";\n } else {\n if (isset($course->startdate)) {\n $startdate = date('d M, Y', $course->startdate);\n $day = substr($startdate, 0, 2);\n $month = substr($startdate, 3, 3);\n $year = substr($startdate, 8, 4);\n }\n $categoryname = $DB->get_record('course_categories', array('id' => $course->category))->name;\n $categoryname = strip_tags(format_text($categoryname));\n $coursehtml .= \"\n <div class='px-1 course_card card '>\n <div class='wrapper h-100'\n style='background-image: url({$image});\n background-size: cover;\n background-position: center;\n position: relative;'>\n <div class='date btn-primary'>\n <span class='day'>{$day}</span>\n <span class='month'>{$month}</span>\n <span class='year'>{$year}</span>\n </div>\n <div class='data'>\n <div class='content' title='{$coursename}'>\n <span class='author'>{$categoryname}</span>\n <h4 class='title ellipsis ellipsis-3' style='-webkit-box-orient: vertical;visibility: visible;'>\n <a href='{$CFG->wwwroot}/course/view.php?id={$course->id}'>{$coursename}</a>\n </h4>\n <p class='text'>{$coursesummary}</p>\n </div>\n </div>\n </div>\n </div>\";\n }\n }\n }\n\n $coursehtml .= '</div></div>';\n\n $coursehtml .= \" <div class='available-courses button-container w-100 text-center '>\n <button type='button' class='btn btn-floating btn-primary btn-prev btn-sm'>\n <i class='icon fa fa-chevron-left' aria-hidden='true'></i>\n </button>\n <button type='button' class='btn btn-floating btn-primary btn-next btn-sm'>\n <i class='icon fa fa-chevron-right' aria-hidden='true'></i>\n </button>\n </div>\";\n\n $coursehtml .= \"\n <div class='row'>\n <div class='col-12 text-right'>\n <a href='{$CFG->wwwroot}/course' class='btn btn-primary'>\" . get_string('viewallcourses', 'core').\"</a>\n </div>\n </div>\";\n\n return $coursehtml;\n }", "function _container($instance) {\n $output = '<div id=\"' . $this->CI->ciwy->component_config[$instance]['outerContainer'] . '\">' . $this->new_line;\n $output .= ' '. form_input($this->CI->ciwy->component_config[$instance]['inputAttributes']) . $this->new_line;\n $output .= ' <div id=\"' . $this->CI->ciwy->component_config[$instance]['containerId'] . '\"></div>' . $this->new_line;\n $output .= '</div>' . $this->new_line;\n return $output;\n }", "private function createCollection()\n {\n try\n {\n $request = $_POST;\n\n global $cbcollection;\n\n if(!userid())\n throw_error_msg(lang(\"you_not_logged_in\")); \n else \n $uid = userid();\n\n //check if video id provided\n if( !isset($request['collection_name']) || $request['collection_name']==\"\" )\n throw_error_msg(\"Collection Name not provided\");\n\n if( !isset($request['collection_description']) || $request['collection_description']==\"\" )\n throw_error_msg(\"Collection Description not provided\");\n\n if( !isset($request['collection_tags']) || $request['collection_tags']==\"\" )\n $request['tags'] = 'sample_tag';\n\n if( !isset($request['category']) || $request['category']==\"\" ) {\n throw_error_msg(\"Collection category not provided\");\n } else {\n $request['category'] = array($request['category']);\n }\n\n if( !isset($request['type']) || $request['type']==\"\" )\n throw_error_msg(\"Collection type not provided\");\n\n if( !isset($request['broadcast']) || $request['broadcast']==\"\" )\n $request['broadcast'] = 'public';\n\n if( !isset($request['allow_comments']) || $request['allow_comments']==\"\" )\n $request['allow_comments'] = 'yes';\n\n if( !isset($request['public_upload']) || $request['public_upload']==\"\" )\n $request['public_upload'] = 'no';\n\n $toclean = array('collection_name','collection_description');\n foreach ($toclean as $key => $item) {\n $request[$item] = mysql_clean($request[$item]);\n }\n\n $status = $cbcollection->create_collection($request);\n # pex($status,true);\n if( $status )\n {\n $newdata = $cbcollection->get_collection($status);\n $data = array('code' => \"200\", 'status' => \"success\", \"msg\" => \"Collection has been created successfully :P \", \"data\" => $newdata);\n $this->response($this->json($data));\n }\n else\n {\n throw_error_msg(\"Something went wrong trying to create collection\"); \n } \n }\n catch(Exception $e)\n {\n $this->getExceptionDelete($e->getMessage());\n }\n }", "public function CreateCourse($clusterID, $user, $request){\n\t\t$clusterUpdate['editedUser'] = $user;\n\t\t$clusterUpdate['editedDate'] = date('Y-m-d H:i:s', time());\n\t\t$clusterResult = $this->Update('[STAGE CLUSTERS TABLE]', $clusterID, $clusterUpdate);\n\t\t$courseResult = $this->Create('[STAGE COURSES TABLE]', $request);\n\t\treturn array(\"results\" => $clusterResult && $courseResult);\n\t}", "public function addContainer( $container, $index = false )\n\t\t{\n\t\t\treturn $this->getTab( '_options_tab' )->addContainer( $container, $index );\n\t\t}", "private function initContainerId()\n {\n if ($this->containerId === null) {\n $procFile = sprintf('/proc/%d/cpuset', $this->processId);\n if (is_readable($procFile)) {\n if (preg_match(\"#([a-f0-9]{64})#\", trim(file_get_contents($procFile)), $cid)) {\n $this->containerId = $cid[0];\n return;\n }\n }\n $this->containerId = '';\n }\n }", "public function addSectionData()\n\t\t{\n\t\t\t_is_logged_in();\n\n\t\t\t$data = array();\n\n\t\t\tif ($_POST) {\n\n\t\t\t\tforeach ($this->input->post() as $key => $value) {\n\n\t\t\t\t\tif ($key == 'section_name') {\n\t\t\t\t\t\t$data['section_slug'] = url_title(convert_accented_characters($value));\n\t\t\t\t\t}\n\t\t\t\t\t$data[$key] = $value;\n\t\t\t\t}\n\n\t\t\t\t$data['language'] = $this->session->userdata('language');\n\t\t\t}\n\n\t\t\t// Send data\n\t\t\t$query = $this->co_pages_model->add_section($data);\n\n\t\t\tif ($query > 0) {\n\t\t\t\tredirect('admin/co_pages/add_section?action=success');\n\t\t\t} else {\n\t\t\t\tredirect('admin/co_pages/add_section?action=error');\n\t\t\t}\n\n\t\t}", "function course_add_view()\n {\n if ($this->session->userdata('admin_login') != 1)\n redirect(base_url(), 'refresh');\n\n $page_data['page_name'] = 'course_add';\n $page_data['page_title'] = get_phrase('add_course');\n $this->load->view('backend/index', $page_data);\n }", "function ting_ting_collection_create($empty, $data = NULL, $conf = FALSE) {\n $context = new ctools_context('ting_collection');\n $context->plugin = 'ting_collection';\n\n if ($empty) {\n return $context;\n }\n\n if ($conf) {\n $collection_id = is_array($data) && isset($data['object_id']) ? $data['object_id'] : (is_object($data) ? $data->id : 0);\n\n module_load_include('client.inc', 'ting');\n $data = ting_get_collection_by_id($collection_id, TRUE);\n }\n\n if (!empty($data)) {\n $context->data = $data;\n $context->title = t('@title by @author', array('@title' => $data->title, '@author' => $data->creators_string));\n $context->argument = $collection_id;\n\n return $context;\n }\n}", "private function _createContainerForms() {\n $forms = [\n [\n 'name' => 'inline',\n 'classname' => 'App\\Models\\Backoffice\\ContainerForms\\Inline'\n ],\n [\n 'name' => 'popup',\n 'classname' => 'App\\Models\\Backoffice\\ContainerForms\\Popup'\n ]\n ];\n\n foreach ($forms as $form) {\n $newForm = new ContainerForm;\n $newForm->fill($form);\n $newForm->save();\n }\n }", "function create_cmecourse() {\n\n\tregister_post_type( 'cmecourse',\n\t// CPT Options\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => __( 'CME Courses' ),\n\t\t\t\t'singular_name' => __( 'CME Course' ),\n\t\t\t'supports' => array('title,editor,thumbnail,comments,uvacme_id,uvacme_credit,uvacme_date,uvacme_time,uvacme_endtime,uvacme_status,uvacme_webpublish,uvacme_sponsorship,uvacme_progurl,uvacme_url,uvacme_facility,uvacme_city,uvasomcme_state,uvasomcme_thumb,uvasomcme_thumblink'),\n\t\t\t),\n\t\t\t'public' => true,\n\t\t\t'has_archive' => true,\n\t\t\t'rewrite' => array('slug' => 'cmecourse'),\n\t\t)\n\t);\n}", "public function getContainer();", "public function getContainer();", "public function getContainer();", "public function getContainer();", "public function getContainer();", "public function createContainer( $options ){\n\n // options container open\n if( $options['container'] == 'open' ) {\n // open container\n $this->openContainer( $options );\n // add text\n $this->addText( $options );\n } \n // options container open\n\n // options container close\n if( $options['container'] == 'close' ) {\n // close container\n $this->closeContainer( $options );\n } \n // options container close\n \n }", "public function addForm()\n {\n $this->getState()->template = 'displaygroup-form-add';\n $this->getState()->setData([\n 'help' => $this->getHelp()->link('DisplayGroup', 'Add')\n ]);\n }", "abstract public function retrieve_course_summary_data();", "private function register_cluster_connection_fields() {\n if ( ! current_user_can( 'edit_clusters' ) ) {\n return;\n }\n\n // Standard cluster groups\n $group_entities_to_clusters = new \\Fieldmanager_Group( '', [\n 'name' => 'pedestal_entities_to_clusters_connections',\n 'tabbed' => true,\n ] );\n $group_stories_to_clusters = new \\Fieldmanager_Group( '', [\n 'name' => 'pedestal_stories_to_clusters_connections',\n 'tabbed' => true,\n ] );\n\n // Locality cluster groups\n $group_entities_to_localities = new \\Fieldmanager_Group( '', [\n 'name' => 'pedestal_entities_to_localities_connections',\n 'tabbed' => true,\n ] );\n $group_stories_to_localities = new \\Fieldmanager_Group( '', [\n 'name' => 'pedestal_stories_to_localities_connections',\n 'tabbed' => true,\n ] );\n\n foreach ( Types::get_cluster_post_types( false ) as $post_type ) {\n $name = Types::get_post_type_name( $post_type );\n $sanitized_name = Utils::sanitize_name( $name );\n $child = new \\Fieldmanager_Group( esc_html__( $name, 'pedestal' ), [\n 'name' => $sanitized_name,\n ] );\n\n // Add clusters to entity box\n $group_entities_to_clusters->add_child( $child );\n\n // Add non-identical clusters to some clusters\n if ( ! Types::is_story( $post_type ) ) {\n $group_stories_to_clusters->add_child( $child );\n }\n }\n\n // Add standard Cluster boxes\n $group_entities_to_clusters->add_meta_box( esc_html__( 'Clusters', 'pedestal' ), Types::get_entity_post_types(), 'normal', 'default' );\n $group_stories_to_clusters->add_meta_box( esc_html__( 'Clusters', 'pedestal' ), 'pedestal_story', 'normal', 'default' );\n }", "function edc_campos_clases() {\n\t$prefix = 'edc_cursos_';\n\n\t/**\n\t * Repeatable Field Groups\n\t */\n\t$edc_campos_cursos = new_cmb2_box( array(\n\t\t'id' => $prefix . 'metabox',\n\t\t'title' => esc_html__( 'Información de Clases y Cursos', 'cmb2' ),\n\t\t'object_types' => array( 'clases' ),\n\t\t'context' \t=> 'normal',\n\t\t'priority'\t=> 'high',\n\t\t'show_names' => 'true',\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Subtitulo del Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada un subtitulo para el curso', 'cmb2' ),\n\t\t'id' => $prefix . 'subtitulo',\n\t\t'type' => 'text',\n\t) );\n\n\t// Horas y Días\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Información sobre la fecha y Horarios del curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada información relacionada a fechas, días y horas para el curso', 'cmb2' ),\n\t\t'id' => $prefix . 'info',\n\t\t'type' => 'title'\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Indicaciones de los días', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada lasa indicaciones de los días ej: Todos los sábados', 'cmb2' ),\n\t\t'id' => $prefix . 'indicaciones',\n\t\t'type' => 'text',\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Fecha de Inicio de Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada la fecha de Inicio de Curso', 'cmb2' ),\n\t\t'id' => $prefix . 'fecha_inicio_curso',\n\t\t'type' => 'text_date',\n\t\t'date_format' => 'd-m-Y',\n\t\t'column' => true\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Fecha de Fin de Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada la fecha de Fin de Curso', 'cmb2' ),\n\t\t'id' => $prefix . 'fecha_fin_curso',\n\t\t'type' => 'text_date',\n\t\t'date_format' => 'd-m-Y',\n\t\t'column' => true\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Hora de Inicio de Clase', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada la hora', 'cmb2' ),\n\t\t'id' => $prefix . 'hora_inicio_clase',\n\t\t'type' => 'text_time',\n\t\t// 'time_format' => 'H:i', // Set to 24hr format\n\t\t'column' => true\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Hora de Fin de Clase', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada la hora', 'cmb2' ),\n\t\t'id' => $prefix . 'hora_fin_clase',\n\t\t'type' => 'text_time',\n\t\t// 'time_format' => 'H:i', // Set to 24hr format\n\n\t) );\n\n\t// Añada información sobre cupos, precio, etc\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Información Extra del curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada cupo, precio, instructor en esta sección', 'cmb2' ),\n\t\t'id' => $prefix . 'bloque',\n\t\t'type' => 'title'\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Precio del Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada el costo del curso', 'cmb2' ),\n\t\t'id' => $prefix . 'costo',\n\t\t'type' => 'text_money',\n\t\t// 'before_field' => '£', // override '$' symbol if needed\n\t\t// 'repeatable' => true,\n\t\t'column' => true\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Cupo', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Cupo para el curso', 'cmb2' ),\n\t\t'id' => $prefix . 'cupo',\n\t\t'type' => 'text',\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Que Incluye El Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Añada lo que incluye el curso (1 por línea)', 'cmb2' ),\n\t\t'id' => $prefix . 'incluye',\n\t\t'type' => 'text',\n\t\t'repeatable' => true\n\t) );\n\n\t$edc_campos_cursos->add_field( array(\n\t\t'name' => esc_html__( 'Instructor del Curso', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Seleccione el profesor que impartirá el curso', 'cmb2' ),\n\t\t'id' => $prefix . 'instructor',\n\t\t'limit' => 10,\n\t\t'type' => 'post_search_ajax',\n\t\t'query_args'\t=> array(\n\t\t\t'post_type'\t\t\t=> array( 'profesores' ),\n\t\t\t'post_status'\t\t=> array( 'publish' ),\n\t\t\t'posts_per_page'\t=> -1\n\t\t)\n\t) );\n\n}", "public function addChild($name)\n\t{\n\t\treturn $this->_auth->addItemChild($this->_calendarId,$this->_name,$name);\n\t}", "function container($params,$content,&$smarty,&$repeat) {\n\t\t$smarty->assign('title',$params['title']);\n\t\t$smarty->display('open_container.tpl');\n\t\techo($content);\n\t\t$smarty->display('close_container.tpl');\n\t}", "function gsAddCourse($imageBase, $course, $golfObj=null) {\n $areaArray = $output = $errors = $loc_errors = array();\n $loc_id = 0;\n \n //$image = \"http://devxml.golfswitch.com/img/course/$id/$image\";\n $keys = array(\n 'id' => 'fid',\n 'sCou' => 'golf_country_code',\n 'sReg' => 'golf_region_code',\n 'sAr' => 'golf_district_code',\n 'onReq' => 'on_request',\n 'nm' => 'name',\n 'lat' => 'location_lat', \n 'lon' => 'location_long', \n 'cou' => 'address_country',\n 'st' => 'address_state',\n 'cty' => 'address_city',\n 'advDays' => 'adv_days',\n 'insideDays' => 'inside_days',\n 'dist' => 'length_men',\n 'promo' => 'description',\n 'rating' => 'rating_men',\n 'img' => 'image',\n 'lastUpd' => 'source_updated');\n $loc_keys = array('name', 'location_lat', 'location_long', 'address_city', 'address_state', 'address_country');\n $data = array_copy($course, $keys);\n $fid = $data['fid'];\n\n $data['image_base'] = \"$imageBase/$fid/\";\n //$data['image'] = $data['image'] ? \"$imageBase/$fid/\".$data['image'] : '';\n $data['source_updated'] = date('Y-m-d H:i:s', strtotime($data['source_updated']));\n\n\n // figure out country,region,district\n $city_name = $course->cty;\n $region_name = $course->sAr;\n $cCode = $course->sCou;\n $rCode = $course->sReg;\n $dCode = $course->sAr;\n\n //if(!($course->lat && $course->lon)) return array(0, array(\"Missing lat/long\"));\n //if(!($cCode && $rCode && $dCode)) return array(0, array(\"Missing search area params\"));\n \n list($c_id, $r_id, $d_id) = gsAreaIds($course, $areaArray);\n //if(!($c_id && $r_id && $d_id)) return array(0, array(\"Could not find area ids for $cCode/$rCode/$dCode\"));\n\n $data['golf_country_id'] = $areaArray['country'][$cCode] = $c_id; \n $data['golf_region_id'] = $areaArray['region'][$rCode] = $r_id; \n $data['golf_district_id'] = $areaArray['district'][$dCode] = $d_id; \n \n $golfObj = $golfObj ?: find_object('golf_course', array('fid' => $fid)); // search for existing\n\n if($course->lat && $course->lon) {\n $locData = array_copy($data, $loc_keys);\n $locData['description'] = $data['short_description'];\n $locData['alt_names'] = $data['name'].\" Golf Course $city_name $region_name\";\n $cc = $data['address_country'];\n $country_name = $cc ? get_object('countries', $cc, 'name') : '';\n $locData['address_formatted'] = implode(',', array_filter(array($data['name'], $data['address_city'], $data['address_state'], $country_name)));\n $locData['location_radius'] = 1000;\n $locData['location_bounds'] = json_encode(radius2bounds($locData, 1000));\n $locData['parent_type'] = 'golf_course';\n $locData['parent_id'] = $golf_id;\n $locData['accuracy'] = 8;\n $locData['zoom'] = 17;\n\n // add or update location \n if($loc_id = $golfObj->location_id) {\n $action = 'update';\n //list($loc_id, $loc_errors) = update_object('location', $locData, $loc_id); \n } else {\n $action = 'add';\n list($loc_id, $loc_errors) = add_object('location', $locData); \n }\n if($loc_errors) {echo(\"Failed to $action location\".dump($loc_errors, true));}\n }\n\n // add or update golf course \n if($loc_id) $data['location_id'] = $loc_id;\n \n if($golfObj) {\n list($id, $errors) = update_object('golf_course', $data, $golfObj->id);\n $action = \"update\";\n } else {\n list($id, $errors) = add_object('golf_course', $data);\n $action = \"add\";\n }\n\n if($errors) {echo(\"Failed to $action golf_course\".dump($errors, true));}\n if($id && $loc_id && !$golfObj->location_id) db_query(\"UPDATE location SET parent_id=$id WHERE id=$loc_id\");\n \n return array($id, $errors);\n}", "function display_courses_after( $section ) {\n\tif ( get_field( 'section_layout', $section ) !== 'courses' ) {\n\t\treturn '';\n\t}\n\n\treturn '</div>';\n}", "public function add()\n { \n return view('admin.control.add_career',[\n 'jobs'=> Career::all(),\n 'categories'=>Category::all(),\n 'contents'=>Content::all(),\n ]);\n }", "function cm_add_meta_box_schedule_course() {\n\n\t$screens = array( 'scheduled_course' );\n\n\n$post_id = $_GET['post'] ? $_GET['post'] : $_POST['post_ID'] ;\n // check for a template type\n \n \n\tforeach ( $screens as $screen ) {\n\n\t\n add_meta_box(\n\t\t\t'myplugin_sectionid',\n\t\t\t__( 'Course Settings', 'myplugin_textdomain' ),\n\t\t\t'cm_meta_box_schedule_course_callback',\n\t\t\t$screen\n\t\t);\n \n\t\t\n\t}\n}", "public function showAddComponentGroup()\n {\n return View::make('dashboard.components.groups.add')\n ->withPageTitle(trans('dashboard.components.groups.add.title').' - '.trans('dashboard.dashboard'));\n }", "function render_page_container( $pageinfo , $firstClass )\n\t\t{\t\n\t\t\tif(!isset($pageinfo['sortable'])) $pageinfo['sortable'] = \"\";\n\t\t\t\n\t\t\t$output = '<div class=\"ace_subpage_container '.$firstClass.' '.$pageinfo['sortable'].'\" id=\"ace_'.ace_backend_safe_string($pageinfo['title']).'\">';\t\n\t\t\t$output .= '\t<div class=\"ace_section_header\">';\t\n\t\t\t$output .= '\t\t<strong class=\"ace_page_title\" style=\"background-Image:url('.ACE_IMG_URL.\"icons/\".$pageinfo['icon'].');\">'; \n\t\t\t$output .= \t\t\t$pageinfo['title'];\n\t\t\t$output .= '\t\t</strong>'; \n\t\t\t$output .= '\t</div>'; \n\t\t\treturn $output;\n\t\t}", "public function display_add_content_block() {\n\t\t?>\n\t\t<div id=\"add-wsublock-single\" class=\"wsublock-add\">Add single section</div>\n\t\t<div id=\"add-wsublock-sidebar\" class=\"wsublock-add\">Add sidebar section</div>\n\t\t<div id=\"add-wsublock-sideleft\" class=\"wsublock-add\">Add sideleft section</div>\n\t\t<div id=\"add-wsublock-halves\" class=\"wsublock-add\">Add halves section</div>\n\t\t<div class=\"clear\"></div>\n\t\t<?php\n\t}", "public static function card( $entry, $template, $atts ) {\n\t\t\t?>\n<?php\nglobal $thisCatFound;\n$thisCat = strip_tags($entry->getCategoryBlock( array( 'label' => '', 'separator' => ', ', 'before' => '', 'after' => '', 'return' => TRUE ) ));\n?>\n<?php\n$paddingBottom = '0px';\nif (!$thisCatFound[$thisCat]) {\n\tprint('<h2 style=\"padding-left:20px; padding-top:20px\" id=\"squelch-taas-title-0\" class=\"squelch-taas-group-title\">');\n\tprint($thisCat);\n\tprint(\"</h2>\\n\");\n\t$paddingBottom = '0px';\n\t$thisCatFound[$thisCat] = TRUE;\n}\n?>\n\n<div style=\"padding-left:40px; padding-bottom:<?php print($paddingBottom); ?>\" role=\"tablist\" id=\"squelch-taas-accordion-0\" class=\"squelch-taas-accordion squelch-taas-override ui-accordion ui-widget ui-helper-reset\" data-active=\"false\" data-disabled=\"false\" data-autoheight=\"false\" data-collapsible=\"true\">\n<h3 tabindex=\"-1\" aria-selected=\"false\" aria-controls=\"ui-accordion-squelch-taas-accordion-0-panel-0\" role=\"tab\" class=\"ui-accordion-header ui-helper-reset ui-state-default ui-corner-all ui-accordion-icons\" id=\"squelch-taas-header-0\"><span class=\"ui-accordion-header-icon ui-icon ui-icon-triangle-1-e\"></span><a href=\"#squelch-taas-accordion-shortcode-content-0\">\n<?php echo $entry->getNameBlock(array('link' => '')); ?></a></h3>\n<div aria-hidden=\"true\" aria-expanded=\"false\" role=\"tabpanel\" aria-labelledby=\"squelch-taas-header-0\" id=\"ui-accordion-squelch-taas-accordion-0-panel-0\" style=\"display: none;\" class=\"squelch-taas-accordion-shortcode-content-0 ui-accordion-content ui-helper-reset ui-widget-content ui-corner-bottom\">\n\t\t\t<div class=\"cn-entry\" style=\"-moz-border-radius:4px; background-color:#FFFFFF; border:1px solid #E3E3E3; color: #000000; margin:8px 0px; padding:6px; position: relative;\">\n\t\t\t\t<div style=\"width:49%; float:left\">\n<?php\n##$img1 = $entry->getImage();\n##print(\"<br />\\n\");\n\n$image = $entry->getImage( array( 'image' => 'photo' , 'preset' => 'thumbnail', 'return' => TRUE, 'action' => 'none' ) );\n\n$logo=$entry->getImage( array( 'image' => 'logo', 'return' => TRUE, 'action' => 'none', 'style' => FALSE ) );\n\n$photo=$entry->getImage( array( 'image' => 'photo' , 'preset' => 'profile', 'return' => TRUE, 'action' => 'none', 'style' => FALSE ) );\n\n##echo $image;\n##echo $logo;\n##echo $photo;\n\nlist($span1, $span2, $photo, $endspan1, $endspan2) = explode(\"><\", $photo);\n\n$photo2 = '<' . $photo . '>';\n\nlist($span1, $span2, $logo2, $endspan1, $endspan2) = explode(\"><\", $logo);\n\n\n$logo3 = '<' . $logo2 . '>';\n\n##echo '<a href=\"/wp-content/uploads/sites/33/2014/12/bilde-300x255.jpg\"><img src=\"/wp-content/uploads/sites/33/2014/12/bilde-300x255-150x150.jpg\" alt=\"home\" class=\"aligncenter size-thumbnail wp-image-107\" height=\"150\" width=\"150\"></a>\n##echo 'start' . $photo . 'end';\n\n##<span class=\"cn-image-style\"><span style=\"display: block; max-width: 100%; width: 180px\">\n##<img src=\"/wp-content/uploads/sites/33/connections-images/kyle-bentz/kyle-bentz-180x180-59628f0b61c9babe89c3c0bbd16c6ede.jpg\" sizes=\"100vw\" class=\"cn-image logo\" alt=\"Logo for Kyle Bentz\" title=\"Logo for Kyle Bentz\" srcset=\"/wp-content/uploads/sites/33/connections-images/kyle-bentz/kyle-bentz-180x180-59628f0b61c9babe89c3c0bbd16c6ede.jpg 1x\" height=\"180\" width=\"180\">\n##</span></span>\n\n\n\n$photoTagArray = getHtmlTagArray2($photo);\n$srcset = $photoTagArray['srcset'];\n\nlist($photoUrl, $mag) = explode(\" \", $srcset);\n$photowidth = $photoTagArray['width'];\n$photoheight = $photoTagArray['height'];\n$photoalt = $photoTagArray['alt'];\necho '<span class=\"cn-image-style\"><span style=\"display: block; max-width: 100%; width: 180px\"><a href=\"' . $photoUrl . '\">\n' . $logo3 . '</a></span></span>';\n\n##echo '<pre>'; print_r($photoTagArray); echo '</pre>';\n ?>\n\t\t\t\t\t<div style=\"clear:both;\"></div>\n\t\t\t\t\t<div style=\"margin-bottom: 10px;\">\n\t\t\t\t\t\t<!--<span style=\"font-size:larger;font-variant: small-caps\"><strong><?php echo $entry->getNameBlock(array('link' => '')); ?></strong></span>-->\n\t\t\t\t\t\t<?php $entry->getTitleBlock(); ?>\n\t\t\t\t\t\t<?php $entry->getOrgUnitBlock(); ?>\n\t\t\t\t\t\t<?php $entry->getContactNameBlock(); ?>\n\n\t\t\t\t\t</div>\n\n\t\t\t\t\t\t<?php $entry->getAddressBlock(); ?>\n\t\t\t\t</div>\n\n\t\t\t\t<div align=\"right\">\n\n\t\t\t\t\t<?php $entry->getFamilyMemberBlock(); ?>\n\t\t\t\t\t<?php $entry->getPhoneNumberBlock(); ?>\n\t\t\t\t\t<?php $entry->getEmailAddressBlock(); ?>\n\t\t\t\t\t<?php $entry->getSocialMediaBlock(); ?>\n\t\t\t\t\t<?php $entry->getImBlock(); ?>\n\t\t\t\t\t<?php $entry->getLinkBlock(); ?>\n\t\t\t\t\t<?php $entry->getDateBlock(); ?>\n\n\n\t\t\t\t</div>\n\n\t\t\t\t<div style=\"clear:both\"></div>\n\n\t\t\t\t<?php echo $entry->getBioBlock(); ?>\n<?php\necho '<!--';\n\t$thisentry = $entry->getMetaBlock(array('separator' => '-', 'key' => 'Music'),'','');\necho '-->';\n\techo $thisentry;\n?>\n\n\t\t\t\t<div style=\"clear:both\"></div>\n\n\t\t\t\t<div class=\"cn-meta\" align=\"left\" style=\"margin-top: 6px\">\n\n\t\t\t\t\t<?php $entry->getContentBlock( $atts['content'], $atts, $template ); ?>\n\n\t\t\t\t\t<!--<div style=\"display: block; margin-bottom: 8px;\"><?php $entry->getCategoryBlock( array( 'separator' => ', ', 'before' => '<span>', 'after' => '</span>' ) ); ?></div>-->\n\n\t\t\t\t\t<?php if ( cnSettingsAPI::get( 'connections', 'connections_display_entry_actions', 'vcard' ) ) $entry->vcard( array( 'before' => '<span>', 'after' => '</span>' ) ); ?>\n\n\t\t\t\t\t<?php\n\t\t\t\t\t/*\n\n\t\t\t\t\tcnTemplatePart::updated(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'timestamp' => $entry->getUnixTimeStamp(),\n\t\t\t\t\t\t\t'style' => array(\n\t\t\t\t\t\t\t\t'font-size' => 'x-small',\n\t\t\t\t\t\t\t\t'font-variant' => 'small-caps',\n\t\t\t\t\t\t\t\t'position' => 'absolute',\n\t\t\t\t\t\t\t\t'right' => '36px',\n\t\t\t\t\t\t\t\t'bottom' => '8px'\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t\t);\n\n\t\t\t\t\tcnTemplatePart::returnToTop( array( 'style' => array( 'position' => 'absolute', 'right' => '8px', 'bottom' => '5px' ) ) );\n\t\t\t\t\t*/\n\n\t\t\t\t\t?>\n\n\t\t\t\t</div>\n\n\t\t\t</div>\n</div>\n</div>\n\n\t\t\t<?php\n\t\t}", "public function apiContainer($id){\n try{\n $query_id = Crypt::decryptString($id);\n } catch (DecryptException $e) {\n return 'UPD-E0002';\n }\n \n $container = GroupContainer::find($query_id);\n $container->crypt = $id;\n return $container;\n }", "public function addAction()\n {\n $manager = $this->getDI()->get('core_category_manager');\n $this->view->form = $manager->getForm();\n }", "private function group_member_added($event) {\n global $DB;\n $groupid = $event->objectid;\n $userid = $event->relateduserid;\n $gmail = $this->get_google_authenticated_users_gmail($userid);\n\n $group = groups_get_group($groupid, 'courseid');\n $courseid = $group->courseid;\n $course = $DB->get_record('course', array('id' => $courseid), 'visible');\n $coursecontext = context_course::instance($courseid);\n\n $coursemodinfo = get_fast_modinfo($courseid, -1);\n $cms = $coursemodinfo->get_cms();\n\n $insertcalls = array();\n $deletecalls = array();\n\n foreach ($cms as $cm) {\n $cmid = $cm->id;\n $cmcontext = context_module::instance($cmid);\n $fileids = $this->get_fileids($cmid);\n if ($fileids) {\n foreach ($fileids as $fileid) {\n if (has_capability('moodle/course:view', $coursecontext, $userid)) {\n // Manager; do nothing.\n } elseif (is_enrolled($coursecontext, $userid, null, true) && has_capability('moodle/course:manageactivities', $cmcontext, $userid)) {\n // Teacher (enrolled) (active); do nothing.\n } elseif (is_enrolled($coursecontext, $userid, null, true)) {\n // Student (enrolled) (active); continue checks.\n if ($course->visible == 1) {\n // Course is visible; continue checks.\n rebuild_course_cache($courseid, true);\n $modinfo = get_fast_modinfo($courseid, $userid);\n $cminfo = $modinfo->get_cm($cmid);\n $sectionnumber = $this->get_cm_sectionnum($cmid);\n $secinfo = $modinfo->get_section_info($sectionnumber);\n if ($cminfo->uservisible && $secinfo->available && is_enrolled($coursecontext, $userid, '', true)) {\n // Course module and section are visible and available.\n // Insert reader permission.\n $call = new stdClass();\n $call->fileid = $fileid;\n $call->gmail = $gmail;\n $call->role = 'reader';\n $insertcalls[] = $call;\n if (count($insertcalls) == 1000) {\n $this->batch_insert_permissions($insertcalls);\n $insertcalls = array();\n }\n } else {\n // User cannot access course module; delete permission.\n try {\n $permissionid = $this->service->permissions->getIdForEmail($gmail);\n $permission = $this->service->permissions->get($fileid, $permissionid->id);\n if ($permission->role != 'owner') {\n $call = new stdClass();\n $call->fileid = $fileid;\n $call->permissionid = $permissionid->id;\n $deletecalls[] = $call;\n if (count($deletecalls) == 1000) {\n $this->batch_delete_permissions($deletecalls);\n $deletecalls = array();\n }\n }\n } catch (Exception $e) {\n debugging($e);\n }\n }\n }\n } else {\n // Unenrolled user; do nothing.\n }\n }\n }\n }\n\n // Call any remaining batch requests.\n if (count($insertcalls) > 0) {\n $this->batch_insert_permissions($insertcalls);\n }\n\n if (count($deletecalls) > 0) {\n $this->batch_delete_permissions($deletecalls);\n }\n }", "public function store(Course $course)\n {\n $this->validate(request(), [\n 'title' => 'required|spamfree'\n ]);\n\n $section = Section::add([\n 'title' => request('title'),\n 'course_id' => $course->id,\n 'description' => request('description')\n ], $course);\n\n return $section;\n }", "public function store(CoursesRequest $request)\n {\n \n $course = new Courses($request->validated());\n $course->course_name = $request->course_name;\n $course->course_description = $request->course_description;\n $course->is_active = $request->is_active;\n $course->type = $request->type == 1 ? '1' : '0';\n $course->save();\n if($course){\n $course->getCategory()->attach($request->cat_id);\n } \n return response()->json($course, 201);\n }", "function CoursesBodyContent()\n\t{\techo $this->date->InputForm($this->course->id);\n\t}", "public function addContainerId() {\n $saved = true;\n /** @var modSystemSetting $setting */\n $setting = $this->modx->getObject('modSystemSetting',array('key' => 'articles.container_ids'));\n if (!$setting) {\n $setting = $this->modx->newObject('modSystemSetting');\n $setting->set('key','articles.container_ids');\n $setting->set('namespace','articles');\n $setting->set('area','furls');\n $setting->set('xtype','textfield');\n }\n $value = $setting->get('value');\n $archiveKey = $this->object->get('id').':arc_';\n $value = is_array($value) ? $value : explode(',',$value);\n if (!in_array($archiveKey,$value)) {\n $value[] = $archiveKey;\n $value = array_unique($value);\n $setting->set('value',implode(',',$value));\n $saved = $setting->save();\n }\n return $saved;\n }", "public function addContainerId() {\n $saved = true;\n /** @var modSystemSetting $setting */\n $setting = $this->modx->getObject('modSystemSetting',array('key' => 'articles.container_ids'));\n if (!$setting) {\n $setting = $this->modx->newObject('modSystemSetting');\n $setting->set('key','articles.container_ids');\n $setting->set('namespace','articles');\n $setting->set('area','furls');\n $setting->set('xtype','textfield');\n }\n $value = $setting->get('value');\n $archiveKey = $this->object->get('id').':arc_';\n $value = is_array($value) ? $value : explode(',',$value);\n if (!in_array($archiveKey,$value)) {\n $value[] = $archiveKey;\n $value = array_unique($value);\n $setting->set('value',implode(',',$value));\n $saved = $setting->save();\n }\n return $saved;\n }", "public function addData()\n {\n $data['city'] = $this->admin_m->getCities();\n $data['deptt'] = $this->admin_m->getDeptt();\n $data['pName'] = $this->admin_m->getPapers();\n $data['cat'] = $this->admin_m->getCategories();\n\n $data['content'] = 'admin/admin_v';\n $this->load->view('components/template', $data);\n }", "private function add_sections(&$data)\n\t{\n\t\t$data['header']\t\t\t= $this->load->controller('common/header');\n\t\t$data['column_left']\t= $this->load->controller('common/column_left');\n\t\t$data['footer']\t\t\t= $this->load->controller('common/footer');\n\t}", "function set_sections() {\n\t\t\n\t\t$this->sections[] = '<script type=\"text/javascript\" charset=\"utf-8\">$(\"#accessoryTabs a.'.$this->id.'\").parent().remove();</script>';\n\n\t\tif($this->EE->input->get('C') == 'admin_content' && $this->EE->input->get('M') == 'category_edit' ) {\n\n\t\t\t// help!\n\t\t\trequire_once(PATH_THIRD.'dm_eeck/includes/eeck_helper.php');\n\t\t\t$this->helper = new eeck_helper();\n\n\t\t\t// we'll need the settings from the Editor field type\n\t\t\t$this->eeck_settings = $this->helper->load_editor_settings();\n\n\t\t\t$this->helper->include_editor_js($this->eeck_settings['eeck_ckepath'], $this->eeck_settings['eeck_ckfpath']);\n\t\t\t\n\t\t\t// get our settings for this field\n\t\t\t$myConf = $this->eeck_settings['eeck_config_settings'];\n\t\t\t\n\t\t\t// load out config file\n\t\t\t$conf = $this->load_config_file($myConf);\n\t\t\tif($conf != '') $conf .= ',';\n\n\t\t\t// add on integration for CK finder\n\t\t\t$conf .= $this->integrate_ckfinder($this->eeck_settings['eeck_ckfpath'],'Images','Files','Flash');\n\n\t\t\t$str = 'CKEDITOR.replace( \"cat_description\",{'.$conf.'});';\n\t\t\t$this->sections[] = '<script type=\"text/javascript\" charset=\"utf-8\">'.$str.'</script>';\n\t\t}\n\t}", "function add_course($course, $school, $title, $description, $exam_date, $exam_start, $exam_end){\n $connection_manager = new connection_manager();\n $conn = $connection_manager->connect();\n\n $stmt = $conn->prepare(\"INSERT INTO course VALUES(:course, :school, :title, :description, :exam_date, :exam_start, :exam_end)\");\n \n $stmt->bindParam(\":course\", $course);\n $stmt->bindParam(\":school\", $school);\n $stmt->bindParam(\":title\", $title);\n $stmt->bindParam(\":description\", $description);\n $stmt->bindParam(\":exam_date\", $exam_date);\n $stmt->bindParam(\":exam_start\", $exam_start);\n $stmt->bindParam(\":exam_end\", $exam_end);\n\n $success = $stmt->execute();\n\n $stmt = null;\n $conn = null;\n\n return $success;\n }", "function add()\n\t{\n\t\t$CFG = $this->config->item('image_configure');\n\t\t$data[\"title\"] = _e(\"Image\");\n\t\t## for check admin or not ##\n\t\t$data[\"response\"] = addPermissionMsg( $CFG[\"sector\"][\"add\"] );\t\t\t\n\t\t## Other auxilary variable ##\n\t\t$data['var'] = array();\t\t\n\t\t$this->load->module('context/context_admin');\n\t\t$user_context = $this->context_admin->getContext();\n\t\t$data['var']['context_dd'] = ( array('' => _e('Choose Context') ) + $user_context );\n\t\t$data['var']['relation_dd'] = ( array('' => _e('Choose Relation') ) );\n\t\t$data[\"top\"] = $this->template->admin_view(\"top\", $data, true, \"image\");\t\n\t\t$data[\"content\"] = $this->template->admin_view(\"image_add\", $data, true, \"image\");\n\t\t$this->template->build_admin_output($data);\n\t}", "public function store(StoreCourseContainerRequest $request)\n {\n CourseContainer::create($request->only('title'));\n\n return redirect()\n ->route('course-containers.index')\n ->with('alert-success', 'Course Container succesfully added');\n }", "public function process(ContainerBuilder $container)\n {\n if (false === $container->hasDefinition('asset.projects_collection')) {\n return;\n }\n $definition = $container->getDefinition('asset.projects_collection');\n foreach ($container->findTaggedServiceIds('asset.project') as $id => $attributes) {\n $definition->addMethodCall('addProject', array(new Reference($id)));\n }\n }", "private function register_cluster_fields() {\n\n $types = [];\n foreach ( Types::get_cluster_post_types() as $post_type ) {\n if ( ! post_type_supports( $post_type, 'editor' ) ) {\n $types[] = $post_type;\n }\n }\n\n $description = new \\Fieldmanager_RichTextArea( false, [\n 'name' => 'description',\n 'required' => false,\n ] );\n $description->add_meta_box( esc_html__( 'Description', 'pedestal' ), $types, 'normal', 'default' );\n\n }", "public function add_courses()\n {\n if ($this->input->is_ajax_request()) {\n\n $process = $this->M_Courses->add_courses();\n $courses = 'courses';\n if ($process) {\n echo json_encode([\n 'status' => true,\n 'message' => $this->lang->line('success_add_courses')\n ]);\n } else {\n echo json_encode([\n 'status' => false,\n 'message' => $this->lang->line('failed_add_courses')\n ]);\n }\n } else {\n redirect(base_url());\n }\n }", "public function admin_add(){\n \n $this->set(\"title_for_layout\",\"Create a Satellite Group\");\n \n // Load all existing satellites\n $this->set('satellites', $this->Satellite->find('all'));\n }", "function get_course_infos($courseid, $DB){\n\n\n $final_course_infos=new stdClass();\n\n $course_allowedfields='id,category,fullname,shortname,summary,format,lang,timecreated,timemodified,courseurl';\n $course_allowedfieldsarray=explode(',',$course_allowedfields);\n $category_allowedfields='id,name,description,parent,coursecount,depth,path';\n $category_allowedfieldsarray=explode(',',$category_allowedfields);\n $module_allowedfields='id,course,module,instance,section,added,score,modname,moduleurl';\n $module_allowedfieldsarray=explode(',',$module_allowedfields);\n $moduleinstance_allowedfields='id,course,name,intro,introformat';\n $moduleinstance_allowedfieldsarray=explode(',',$moduleinstance_allowedfields);\n $context_allowedfields='id,contextlevel,instanceid,path,depth';\n $context_allowedfieldsarray=explode(',',$context_allowedfields);\n $file_allowedfields='id,contextid,component,filearea,filepath,filename,filesize,mimetype,source,author,license,timecreated,timemodified,sortorder,referencefileid,fileurl';\n $file_allowedfieldsarray=explode(',',$file_allowedfields);\n $licence_allowedfields='id,shortname,fullname,source,enabled,version';\n $licence_allowedfieldsarray=explode(',',$licence_allowedfields);\n\n $course_mods = get_course_mods($courseid);\n $final_course_infos->course_gen_infos= $DB->get_record('course', array('id' =>$courseid));\n //Addition of 'CourseURl' as attribute\n $final_course_infos->course_gen_infos->courseurl= $GLOBALS['GLBMDL_CFG']->wwwroot.\"/course/view.php?id=\".$final_course_infos->course_gen_infos->id;\n $final_course_infos->course_cat_infos= $DB->get_record('course_categories', array('id' =>$final_course_infos->course_gen_infos->category ));\n\n\n $result = array();\n if($course_mods) {\n foreach($course_mods as $course_mod) {\n\n //Addition of 'ModuleURl' as attribute\n $course_mod->moduleurl= $GLOBALS['GLBMDL_CFG']->wwwroot.\"/mod/\".$course_mod->modname.\"/view.php?id=\".$course_mod->id;\n $course_mod->course_module_instance = $DB->get_record($course_mod->modname, array('id' =>$course_mod->instance ));\n $course_mod->course_module_context = $DB->get_record('context', array('instanceid' =>$course_mod->id, 'contextlevel' => 70 ));\n\n\n $course_mod->course_module_file = $DB->get_record('files', array('contextid' =>$course_mod->course_module_context->id, 'sortorder' => 1));\n $course_mod->course_module_file_licence= null;\n if($course_mod->course_module_file){\n\n $course_mod->course_module_file_licence = $DB->get_record('license', array('shortname' =>$course_mod->course_module_file->license));\n //Addition of 'FileURl' as attribute\n $course_mod->course_module_file->fileurl= $GLOBALS['GLBMDL_CFG']->wwwroot.\"/pluginfile.php/\".$course_mod->course_module_context->id.\"/\".$course_mod->course_module_file->component.\"/\".$course_mod->course_module_file->filearea.\"/\".$course_mod->course_module_file->itemid.$course_mod->course_module_file->filepath.$course_mod->course_module_file->filename;\n\n }\n //$course_mod=module_filesandrelatedlicences($DB, $course_mod, array('content'));\n $result[$course_mod->id] = $course_mod;\n\n }\n }\n $final_course_infos->course_modules=$result;\n $final_course_infos->response_notice=\"Response success\";\n\n //Return only the needed infos: allowed infos to the frontEnd side.\n $finalfinal_course_infos=new stdClass();\n $finalfinal_course_infos->course_gen_infos=json_encode( clean_object($final_course_infos->course_gen_infos, $course_allowedfieldsarray));\n $finalfinal_course_infos->course_cat_infos=json_encode( clean_object($final_course_infos->course_cat_infos, $category_allowedfieldsarray));\n $finalfinal_course_infos->course_modules=null;\n foreach ($final_course_infos->course_modules as $key => $value) {\n\n $finalcoursemodule =new stdClass();\n $finalcoursemodule->course_module_geninfos=clean_object($value, $module_allowedfieldsarray);\n $finalcoursemodule->course_module_instance=clean_object($value->course_module_instance, $moduleinstance_allowedfieldsarray);\n $finalcoursemodule->course_module_context=clean_object($value->course_module_context, $context_allowedfieldsarray);\n $finalcoursemodule->course_module_file=clean_object($value->course_module_file, $file_allowedfieldsarray);\n $finalcoursemodule->course_module_file_licence=clean_object($value->course_module_file_licence, $licence_allowedfieldsarray);\n\n $finalfinal_course_infos->course_modules[\"$key\"]=$finalcoursemodule;\n $finalcoursemodule=null;\n }\n\n\n $finalfinal_course_infos->course_modules= json_encode( $finalfinal_course_infos->course_modules);\n\n return $final_course_infos;\n }" ]
[ "0.57198757", "0.56334317", "0.5376082", "0.5373823", "0.53295565", "0.52709484", "0.5211322", "0.5112306", "0.5111507", "0.5109121", "0.50899845", "0.5083939", "0.5033106", "0.50281346", "0.5005085", "0.4993219", "0.49897462", "0.49813628", "0.4975462", "0.49718344", "0.49620923", "0.49526408", "0.4926558", "0.4912684", "0.49103415", "0.48857355", "0.48785043", "0.48783383", "0.48767748", "0.48657355", "0.48524013", "0.4846921", "0.48411983", "0.48360446", "0.48258093", "0.48172763", "0.48157614", "0.48079216", "0.48075524", "0.4807129", "0.48062304", "0.4805406", "0.4796726", "0.47937867", "0.477639", "0.4772732", "0.47679815", "0.47656298", "0.4765173", "0.47628123", "0.47607192", "0.47510988", "0.4750374", "0.47469413", "0.47337854", "0.47282064", "0.472616", "0.47167054", "0.47133598", "0.47092584", "0.4703982", "0.4703282", "0.4703282", "0.4703282", "0.4703282", "0.4703282", "0.46986887", "0.4692875", "0.46853954", "0.46827865", "0.46814305", "0.4680153", "0.4674721", "0.46633595", "0.4662756", "0.46553785", "0.46536723", "0.46493208", "0.46431315", "0.46400934", "0.46387854", "0.46343023", "0.46210673", "0.46209645", "0.46191895", "0.46174005", "0.4616639", "0.46164972", "0.46164972", "0.461438", "0.46137902", "0.46117538", "0.46055272", "0.46046463", "0.46014705", "0.4589476", "0.45873484", "0.45846248", "0.45825484", "0.45764664" ]
0.60336614
0
Add list item property
function addListItemProperty($a_txt, $a_val) { $this->list_properties[] = array("txt" => $a_txt, "val" => $a_val); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function createProperty()\n {\n $prop = new LiquibaseProperty();\n $this->properties[] = $prop;\n\n return $prop;\n }", "public function addProperty(Property $property)\n {\n $this->properties[(string)$property->getFqsen()] = $property;\n }", "public function addProperty($key, $value);", "function addMetadataValueToItem(&$item, $md) {\n $value = $this->getMetadataValue($item, $md);\n $md->setValue($value);\n $item->addMetadata($md);\n }", "protected function _add($property, $value): void {\n if (property_exists($this, $property)) {\n $this->{$property}[] = $value;\n } else {\n $this->_properties[$property][] = $value;\n }\n }", "public function add($item)\n {\n $index = \"properties\";\n if (is_subclass_of($item->object, Model::class)) {\n $index = \"globals\";\n }\n $this->{$index}[$item->key] = $item;\n return $this;\n }", "function createProperty();", "function appendItemMetadataList(&$item) {\n $mda = array();\n\n // Static metadata\n $mda = $this->getHardCodedMetadataList(true);\n foreach($mda as $md) {\n $md->setValue($item->getHardCodedMetadataValue($md->getLabel()));\n $item->addMetadata($md);\n unset($md);\n }\n \n // Dynamic metadata\n $mdIter = $this->getRealMetadataIterator(true);\n $mdIter->rewind();\n while($mdIter->valid()) {\n $md = $mdIter->current();\n $this->addMetadataValueToItem($item, $md);\n $mdIter->next();\n }\n }", "public function setAddClassToListItem(bool $flag = true);", "public function addElement($item,array $args) {\n\t\tif (!array_key_exists($item,$this->_properties)) {\n\t\t\tforeach ($args as $key => $val) {\n\t\t\t\t$this->_properties[$item][$key]=$val;\n\t\t\t}\n\t\t}\n\t}", "public function add_custom_list_item() {\n\t\t//verify nonce\n\t\tcheck_ajax_referer( 'fsn-admin-edit', 'security' );\n\t\t\n\t\t//verify capabilities\n\t\tif ( !current_user_can( 'edit_post', intval($_POST['post_id']) ) )\n\t\t\tdie( '-1' );\n\t\t\n\t\tglobal $fsn_custom_lists;\t\n\t\t$listID = sanitize_text_field($_POST['listID']);\n\t\t$params = $fsn_custom_lists[$listID]['params'];\n\t\t$uniqueID = uniqid();\t\n\t\techo '<div class=\"custom-list-item\">';\t\t\n\t\t\techo '<div class=\"custom-list-item-details\">';\t\t\t\t\n\t\t\t\tforeach($params as $param) {\n\t\t\t\t\t$param_value = '';\n\t\t\t\t\t$param['param_name'] = (!empty($param['param_name']) ? $param['param_name'] : '') . '-paramid'. $uniqueID;\n\t\t\t\t\t$param['nested'] = true;\n\t\t\t\t\t//check for dependency\n\t\t\t\t\t$dependency = !empty($param['dependency']) ? true : false;\n\t\t\t\t\tif ($dependency === true) {\n\t\t\t\t\t\t$depends_on_field = $param['dependency']['param_name']. '-paramid'. $uniqueID;\n\t\t\t\t\t\t$depends_on_not_empty = !empty($param['dependency']['not_empty']) ? $param['dependency']['not_empty'] : false;\n\t\t\t\t\t\tif (!empty($param['dependency']['value']) && is_array($param['dependency']['value'])) {\n\t\t\t\t\t\t\t$depends_on_value = json_encode($param['dependency']['value']);\n\t\t\t\t\t\t} else if (!empty($param['dependency']['value'])) {\n\t\t\t\t\t\t\t$depends_on_value = $param['dependency']['value'];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$depends_on_value = '';\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$dependency_callback = !empty($param['dependency']['callback']) ? $param['dependency']['callback'] : '';\n\t\t\t\t\t\t$dependency_string = ' data-dependency-param=\"'. esc_attr($depends_on_field) .'\"'. ($depends_on_not_empty === true ? ' data-dependency-not-empty=\"true\"' : '') . (!empty($depends_on_value) ? ' data-dependency-value=\"'. esc_attr($depends_on_value) .'\"' : '') . (!empty($dependency_callback) ? ' data-dependency-callback=\"'. esc_attr($dependency_callback) .'\"' : '');\n\t\t\t\t\t}\n\t\t\t\t\techo '<div class=\"form-group'. ( !empty($param['class']) ? ' '. esc_attr($param['class']) : '' ) .'\"'. ( $dependency === true ? $dependency_string : '' ) .'>';\n\t\t\t\t\t\techo FusionCore::get_input_field($param, $param_value);\n\t\t\t\t\techo '</div>';\n\t\t\t\t}\n\t\t\t\techo '<a href=\"#\" class=\"collapse-custom-list-item\">'. __('collapse', 'fusion') .'</a>';\n\t \t\techo '<a href=\"#\" class=\"remove-custom-list-item\">'. __('remove', 'fusion') .'</a>';\n\t\t\techo '</div>';\n\t\techo '</div>';\n\t\texit;\n\t}", "function listItem() {\n\t\treturn ($this->nodes[] = new flStrideListItem())->paragraph();\n\t}", "public function addProperty(Entities\\Devices\\Properties\\Property $property): void\n\t{\n\t\tif (!$this->properties->contains($property)) {\n\t\t\t// ...and assign it to collection\n\t\t\t$this->properties->add($property);\n\t\t}\n\t}", "public function addProperty($property) {\n $this->optionalProperties[] = $property;\n return $this->optionalProperties;\n }", "function addItem(&$item) {\n\t\tglobal $CONF ; \n\t\t$this->items [$item->alias] = $item;\n\t\t$item->menu = $this ;\n\t}", "public function __construct()\n {\n $this->ListItem = [];\n // $this->type='ul';\n }", "public function addItem($item) {\n\t\t$this->result .= '<li>' . $item . '</li>' . PHP_EOL;\n\t}", "public function getAddClassToListItem(): bool;", "public function add( EchoContainmentList $list ) {\n\t\t$this->lists[] = $list;\n\t}", "function add_menu_atts( $atts, $item, $args ) {\n\t\t\t\t$atts['itemprop'] = 'url';\n\t\t\t\treturn $atts;\n\t\t\t}", "function add($item);", "public function addColumn(Property $property);", "public function push($value): IProperty;", "public function initMutateProperty()\n {\n foreach ( $this->initMutateProperties as $property ) {\n $this->mutateProperties[ $property ] = $this->{$property};\n }\n $this->view->addParams( [\n 'mutateProperties' => $this->mutateProperties\n ] );\n }", "protected function configureListFields(ListMapper $listMapper)\r\n {\r\n $listMapper\r\n ->addIdentifier('nombre')\r\n ;\r\n }", "public function embedProperty() {\n\n $this->addEmbed(\"Property\");\n return $this;\n }", "public function addPropertyValues(Property $property) {\r\n foreach ($property->getPropertyValues() as $propertyValue) {\r\n $property->addPropertyValue($propertyValue);\r\n }\r\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('username' , 'text', array('label'=>'Pseudo')) //This will carry the link that leads to item's individual page\n ->add('enabled' , 'boolean', array('label'=>'Activé'))\n ->add('email' , 'text')\n ->add('roles', null, array('label'=>'Droits'))\n ;\n }", "public function add_declaration($property, $value)\n {\n }", "public function addObjectProperty($field, ObjectProperty $property);", "private function addPropertyMetadata(PropertyMetadataInterface $metadata)\n {\n $property = $metadata->getPropertyName();\n\n $this->members[$property][] = $metadata;\n }", "public function addProperty(string $name, mixed $value): void\n\t{\n\t\t$this->properties[$name] = $value;\n\t}", "protected function configureListFields(ListMapper $list)\n {\n $list\n ->addIdentifier('notificationType')\n ->addIdentifier('code')\n ->add('_action', 'actions', array ('actions' => array (\n 'show' => array (),\n 'edit' => array (),\n 'delete' => array ()\n )));\n }", "function doAction() {\n\n\t\t$i18n = new I18n($this->context->config->UI_LANG);\n\n\t\tif (isset($this->session->errorCode)) {\n\t\t\t$listItemProperty = unserialize($this->session->formData);\n\t\t\t$applicationId = $listItemProperty->applicationDefinitionId;\n\t\t} else {\n\t\t\t$listItemPropertyId = Request::get(\n\t\t\t\t\"list_item_property_id\", Request::TYPE_INTEGER, 0);\n\t\t\tif ($listItemPropertyId) {\n\t\t\t\t$listItemProperty = ListItemPropertyDefinition::fetch(\n\t\t\t\t\t$this->context, $listItemPropertyId);\n\t\t\t\t$applicationId = $listItemProperty->applicationDefinitionId;\n\t\t\t} else {\n\t\t\t\t$listItemProperty =\n\t\t\t\t\tnew ListItemPropertyDefinition($this->context);\n\t\t\t\t$applicationId = Request::get(\n\t\t\t\t\t\"application_definition_id\", Request::TYPE_INTEGER, 0);\n\t\t\t}\n\t\t}\n\n\t\t$title = $listItemProperty->id\n\t\t\t? $i18n[\"Edit list item property\"]\n\t\t\t: $i18n[\"Create new list item property\"];\n\n\t\t$helpTexts = array(\n\n\t\tListItemPropertyDefinition::TYPE_INPUT =>\n\t\t$i18n[\"\\nWIDTH\".\n\t\t\t\"\\tWidth of the input box in pixels, number\".\n\t\t\t\"\\tWIDTH=100\".\n\t\t\t\"\\nMAXLENGTH\".\n\t\t\t\"\\tMaximum number of characters that will be accepted\".\n\t\t\t\"\\tMAXLENGTH=50\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\"\\nWIDTH\".\n\t\t\t\"\\tBreedte in pixels van de input box, getal\".\n\t\t\t\"\\tWIDTH=100\".\n\t\t\t\"\\nMAXLENGTH\".\n\t\t\t\"\\tMaximaal aantal karkaters dat wordt geaccepteerd\".\n\t\t\t\"\\tMAXLENGTH=50\".\n\t\t\t\"\\n\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_INFO =>\n\t\t$i18n[\"\\nThe info property provides you with a possibility to add \".\n\t\t\t\"informative texts in the dialog window. Just enter the text in \".\n\t\t\t\"the \\\"type data\\\" field. The text can contain HTML.\"],\n\t\t/*$i18n[\"\\nHet info data type is een mogelijkheid om eigen tekst in \".\n\t\t \"het dialoogvenster te zetten. Alleen het \\\"type data\\\" veld hoeft \".\n\t\t \"hier ingevuld te worden. Het veld kan HTML bevatten.\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_HTML_TEXT =>\n\t\t$i18n[\"\\nHEIGHT\".\n\t\t\t\"\\tHeight if the text field in pixels\".\n\t\t\t\"\\tHEIGHT=100\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\"\\nHEIGHT\".\n\t\t\t\"\\tHoogte van het textvak in pixels\".\n\t\t\t\"\\tHEIGHT=100\".\n\t\t\t\"\\n\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_TEXT =>\n\t\t$i18n[\"\\nROWS\".\n\t\t\t\"\\tHeight if the text field in rows\".\n\t\t\t\"\\tROWS=5\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\"\\nROWS\".\n\t\t\t\"\\tHoogte van het textvak in regels\".\n\t\t\t\"\\tROWS=5\".\n\t\t\t\"\\n\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_IMAGE =>\n\t\t$i18n[\"\\nWIDTH\".\n\t\t\t\"\\tWidth in pixels of the image in the CMS dialog window, number\".\n\t\t\t\"\\tWIDTH=100\".\n\t\t\t\"\\nHEIGHT\".\n\t\t\t\"\\tHeight in pixels of the image in the CMS dialog window, number\".\n\t\t\t\"\\nTEMPLATE_WIDTH\".\n\t\t\t\"\\tSuggested width in pixels when cropping the image, number\".\n\t\t\t\"\\nTEMPLATE_HEIGHT\".\n\t\t\t\"\\tSuggested height in pixels when cropping the image, number\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\n\t\t\t\"\\nWIDTH\".\n\t\t\t\"\\tBreedte in pixels van het plaatje in cms dialoogvenster, getal\".\n\t\t\t\"\\tWIDTH=100\".\n\t\t\t\"\\nHEIGHT\".\n\t\t\t\"\\tHoogte in pixels van het plaatje in cms dialoogvenster, getal\".\n\t\t\t\"\\nTEMPLATE_WIDTH\".\n\t\t\t\"\\tVoorgestelde breedte voor het croppen van de afbeelding, getal\".\n\t\t\t\"\\nTEMPLATE_HEIGHT\".\n\t\t\t\"\\tVoorgestelde hoogte voor het croppen van de afbeelding, getal\".\n\t\t\t\"\\n\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_DATE_TIME =>\n\t\t$i18n[\"\\nDEFAULT_VALUE\".\n\t\t\t\"\\tThe 'default' DEFAULT_VALUE is the current date. You can enter \".\n\t\t\t\"NULL if you don't want a default date set. Else you can enter \".\n\t\t\t\"any by PHP:strtotime parseble value as DEFAULT_VALUE.\".\n\t\t\t\"\\tDEFAULT_VALUE=NULL\".\n\t\t\t\"\\tDEFAULT_VALUE=-2 days\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\n\t\t\t\"\\nDEFAULT_VALUE\".\n\t\t\t\"\\tDe 'default' DEFAULT_VALUE is de huidige datum. NULL kan je \".\n\t\t\t\"opgeven als je geen default geen waarde ingevuld wilt. Daarnaast \".\n\t\t\t\"kan je elke door PHP:strtotime parsebare waarde als \".\n\t\t\t\"DEFAULT_VALUE opgeven.\".\n\t\t\t\"\\tDEFAULT_VALUE=NULL\".\n\t\t\t\"\\tDEFAULT_VALUE=-2 days\".\n\t\t\t\"\\n\"],*/\n\n\t\tListItemPropertyDefinition::TYPE_SELECT =>\n\t\t$i18n[\"\\nDATA\".\n\t\t\t\"\\tList with items to display in the select list. These are \".\n\t\t\t\"value/text pairs separated by a semicolon. Each value/text pair \".\n\t\t\t\"is on its turn separated by a colon.\".\n\t\t\t\"\\tDATA=M:male;F:Female\".\n\t\t\t\"\\nTYPE\".\n\t\t\t\"\\tSelect list type\".\n\t\t\t\"\\tTYPE=MULTIPLE\".\n\t\t\t\"\\nSIZE\".\n\t\t\t\"\\tSize of the (multiple) select list in rows\".\n\t\t\t\"\\tSIZE=4\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\n\t\t\t\"\\nDATA\".\n\t\t\t\"\\tLijst met items die worden getoond in de select list. \".\n\t\t\t\"Waarde-tekst paren gescheiden door een punt-komma. Elk \".\n\t\t\t\"waarde-tekst paar is weer gescheiden door een dubbele punt.\".\n\t\t\t\"\\tDATA=M:male;F:Female\".\n\t\t\t\"\\nTYPE\".\n\t\t\t\"\\tType van de select list\".\n\t\t\t\"\\tTYPE=MULTIPLE\".\n\t\t\t\"\\nSIZE\".\n\t\t\t\"\\tGrootte van de (multiple) select list\".\n\t\t\t\"\\tSIZE=4\".\n\t\t\t\"\\n\"],*/\n\n\t\t\"col\" =>\n\t\t$i18n[\"Settings for the property in column layout\".\n\t\t\t\"\\nCOL_WIDTH\".\n\t\t\t\"\\tcolumn width, number (defaults to 100)\".\n\t\t\t\"\\tCOL_WIDTH=125\".\n\t\t\t\"\\nCOL_ALIGN\".\n\t\t\t\"\\tAlingment of the column. left-center-right (defaults to 'left')\".\n\t\t\t\"\\tCOL_ALIGN=center\".\n\t\t\t\"\\nCOL_IS_NUMERIC\".\n\t\t\t\"\\tTo indicate that column contains a numerical value so that \".\n\t\t\t\"these columns will be sorted correctly, true-false (defaults \".\n\t\t\t\"to false)\".\n\t\t\t\"\\tCOL_IS_NUMERIC=true\".\n\t\t\t\"\\n\"],\n\t\t/*$i18n[\"Instellingen voor velden in kolom lay out\".\n\t\t\t\"\\nCOL_WIDTH\".\n\t\t\t\"\\tkolombreedte, getal (default waarde is 100)\".\n\t\t\t\"\\tCOL_WIDTH=125\".\n\t\t\t\"\\nCOL_ALIGN\".\n\t\t\t\"\\tUitlijning van de kolom. left-center-right (default waarde \".\n\t\t\t\"is 'left')\".\n\t\t\t\"\\tCOL_ALIGN=center\".\n\t\t\t\"\\nCOL_IS_NUMERIC\".\n\t\t\t\"\\tGeef aan dat de waarde nummeriek is, zodat kolommen met \".\n\t\t\t\"getallen goed worden gesorteerd, true-false (default waarde \"\n\t\t\t\"is false)\".\n\t\t\t\"\\tCOL_IS_NUMERIC=true\".\n\t\t\t\"\\n\"],*/\n\t\t);\n\n\t\t$tr = \"../ScrivoUi/Config/Templates\";\n\t\tinclude \"{$tr}/common.tpl.php\";\n\t\tinclude \"{$tr}/Forms/list_item_property_form.tpl.php\";\n\t\t$this->useLayout(\"{$tr}/master.tpl.php\");\n\n\t\t$this->setResult(self::SUCCESS);\n\n\t}", "function SetupListOptions() {\r\n\t\tglobal $Security, $Language;\r\n\r\n\t\t// \"edit\"\r\n\t\t$item = &$this->ListOptions->Add(\"edit\");\r\n\t\t$item->CssStyle = \"white-space: nowrap;\";\r\n\t\t$item->Visible = $Security->CanEdit();\r\n\t\t$item->OnLeft = TRUE;\r\n\r\n\t\t// Call ListOptions_Load event\r\n\t\t$this->ListOptions_Load();\r\n\t}", "function addItemForUpdate($item) {\n $this->_update[$item->getId()] = $item;\n }", "public function addListItem($text, $depth = 0, $styleFont = null, $styleList = null, $styleParagraph = null) {\n\t\t$text = utf8_encode($text);\n\t\t$listItem = new PHPWord_Section_ListItem($text, $depth, $styleFont, $styleList, $styleParagraph);\n\t\t$this->_elementCollection[] = $listItem;\n\t\treturn $listItem;\n\t}", "public function custom_item_properties()\n {\n return array(\n 'supports_hierarchy' => $this->supports_hierarchy,\n 'display_callback' => array($this, 'display'),\n 'validate_callback' => array($this, 'validate'),\n 'sanitize_callback' => array($this, 'sanitize'),\n 'get_children_callback' => array($this, 'get_children'),\n 'get_date_from_timeframe_callback' => array($this, 'get_date_from_timeframe'),\n );\n }", "public function add($item);", "public function add($item);", "public function setAttributes($item,$attributes) {\n\t\t$this->_properties[$item]['Attributes'] = ' '.$attributes;\n\t}", "public function addPropertyValue(string $property, $value) : DataContainerInterface;", "private function pushOneArg($item)\n {\n if ($item instanceof Property)\n {\n if ('uid' === $item->getName())\n $this->setUID($item->getValue());\n elseif ($item->getSpecification()->requiresSingleProperty())\n $this->data[$item->getName()] = $item;\n else\n $this->data[$item->getName()][] = $item; \n } elseif (is_array($item) || ($item instanceof \\Traversable)) {\n foreach ($item as $property)\n {\n $this->pushOneArg($property);\n }\n } else {\n throw new \\UnexpectedValueException('Not a property');\n } \n }", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper->addIdentifier('frTitle')\n ->addIdentifier('enTitle')\n ->addIdentifier('plot')\n ->addIdentifier('screenplay')\n ->addIdentifier('runningTime')\n ->addIdentifier('releaseDate')\n ->addIdentifier('music')\n ->addIdentifier('country')\n ->addIdentifier('language')\n\n ;\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('name','string',array('template'=>'MyUtilsBundle:Administration:list_sport_icon.html.twig'))\n ->add('slug')\n ->add('category',null,array('associatied_property'=>'name'))\n ;\n }", "public function add($item) {\n $this->items[$item->id()] = $item;\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('title')\n ->add('json')\n ;\n }", "public function propertyInfoAlter(EntityMetadataWrapper $wrapper, array $property_info) {\n if (entity_get_property_info($wrapper->type())) {\n // Overwrite the existing properties with the list of properties including\n // all fields regardless of the used bundle.\n $property_info['properties'] = entity_get_all_property_info($wrapper->type());\n }\n\n if (!isset($this->added_properties)) {\n $this->added_properties = array(\n 'search_api_language' => array(\n 'label' => t('Item language'),\n 'description' => t(\"A field added by the search framework to let components determine an item's language. Is always indexed.\"),\n 'type' => 'token',\n 'options list' => 'entity_metadata_language_list',\n ),\n );\n // We use the reverse order here so the hierarchy for overwriting property\n // infos is the same as for actually overwriting the properties.\n foreach (array_reverse($this->getAlterCallbacks()) as $callback) {\n $props = $callback->propertyInfo();\n if ($props) {\n $this->added_properties += $props;\n }\n }\n }\n // Let fields added by data-alter callbacks override default fields.\n $property_info['properties'] = array_merge($property_info['properties'], $this->added_properties);\n\n return $property_info;\n }", "public function addItem($key, $value);", "public function addProperty(PropertyInterface $property)\n\t{\n\t\t$this->properties[$property->key()] = $property;\n\n\t\treturn $this;\n\t}", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper->addIdentifier('title');\n $listMapper->addIdentifier('description');\n }", "function makeListItems($list, $name=null, $extra=false)\n{\n $list_items = '';\n foreach ( $list as $item ) {\n // Prepare values\n $list_item = htmlspecialchars($item->getName());\n if ( method_exists($item, 'getUrl') ) {\n $url = $item->getUrl();\n if ( !empty($url) ) {\n $list_item = \"<a href=\\\"{$url}\\\">{$list_item}</a>\\n\";\n }\n }\n // Make the li\n $list_items .= <<<LI\n <li>\n {$list_item}\n </li>\n\nLI;\n }\n return $list_items;\n}", "function appendAllListOfValuesToItem(&$item) {\n $iter = $item->getMetadataIterator();\n $this->appendAllListOfValues($iter);\n }", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper\n ->addIdentifier('id')\n ->add('title')\n ->add('active')\n ;\n }", "abstract protected function onBeforeAdd($oItem);", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper\n ->addIdentifier('id')\n ->add('title')\n ;\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('id')\n\t\t\t->add('name_rus')\n\t\t\t->add('education')\t\t\t\t\n ;\n }", "public function add($item)\n {\n $this->manuallyAddedData[] = $item;\n }", "function addItem(SitemapItem $item){\r\n $this->items[] = $item;\r\n }", "abstract public function add_item();", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addAdditionalProperty($name, $value)\n {\n $this->additionalProperties[$name] = $value;\n }", "public function addItem($item){\n $this->items[] = $item;\n }", "public function configureListFields(ListMapper $list)\n {\n $list\n ->addIdentifier('status', null, ['label' => 'Status'])\n ->add('_action', null, [\n 'actions' => [\n 'delete' => [],\n 'edit' => []\n ]\n ]);\n }", "function set_property(){\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n\t\t\t->add('isActive')\n\t\t\t->addIdentifier('id')\n\t\t\t->addIdentifier('name')\n\t\t\t->add('description')\n\t\t\t->add('video')\n ->add('thumbnail')\n\t\t\t->add('createdAt')\n ->add('updated')\n ;\n }", "public function addToNamePref($item)\n {\n // validation for constraint: itemType\n if (!false) {\n throw new \\InvalidArgumentException(sprintf('The NamePref property can only contain items of anyType, \"%s\" given', is_object($item) ? get_class($item) : gettype($item)), __LINE__);\n }\n $this->NamePref[] = $item;\n return $this;\n }", "function wsdl_docs_soapclient_ui_property_row_new($name) {\n $property['name'] = array(\n '#type' => 'textfield',\n '#disabled' => TRUE,\n '#size' => 40,\n '#default_value' => $name,\n );\n return $property;\n}", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('name')\n ->add('status')\n \n ;\n }", "function addProperty($name, $value) {\r\n\r\n\t\tif($this->configured) {\r\n\t\t\treturn 'Configuration is frozen';\r\n\t\t}\r\n\r\n\t\t// XML boolean needs to be converted\r\n\t\tif( strtolower($value) == 'true') {\r\n\t\t\t$value = True;\r\n\t\t} elseif(strtolower($value) == 'false') {\r\n\t\t\t$value = False;\r\n\t\t}\r\n\r\n\t\t// Look for a setter method matching the \"name\" parameter\r\n\t\t$beanUtils = new PhpBeanUtils();\r\n\t\t$beanUtils->setProperty($this, $name, $value);\r\n\r\n\t}", "function SetupListOptions() {\r\n\t\tglobal $Security, $Language;\r\n\r\n\t\t// \"view\"\r\n\t\t$item = &$this->ListOptions->Add(\"view\");\r\n\t\t$item->CssStyle = \"white-spaceJAMES: nowrapJAMES;\";\r\n\t\t$item->Visible = $Security->CanView();\r\n\t\t$item->OnLeft = FALSE;\r\n\r\n\t\t// \"edit\"\r\n\t\t$item = &$this->ListOptions->Add(\"edit\");\r\n\t\t$item->CssStyle = \"white-spaceJAMES: nowrapJAMES;\";\r\n\t\t$item->Visible = $Security->CanEdit();\r\n\t\t$item->OnLeft = FALSE;\r\n\r\n\t\t// \"copy\"\r\n\t\t$item = &$this->ListOptions->Add(\"copy\");\r\n\t\t$item->CssStyle = \"white-spaceJAMES: nowrapJAMES;\";\r\n\t\t$item->Visible = $Security->CanAdd();\r\n\t\t$item->OnLeft = FALSE;\r\n\r\n\t\t// \"delete\"\r\n\t\t$item = &$this->ListOptions->Add(\"delete\");\r\n\t\t$item->CssStyle = \"white-spaceJAMES: nowrapJAMES;\";\r\n\t\t$item->Visible = $Security->CanDelete();\r\n\t\t$item->OnLeft = FALSE;\r\n\r\n\t\t// Call ListOptions_Load event\r\n\t\t$this->ListOptions_Load();\r\n\t}", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper\n ->addIdentifier('id')\n ->add('status')\n ;\n }", "protected function configureListFields(ListMapper $listMapper)\r\n {\r\n $listMapper\r\n ->addIdentifier('padelUser')\r\n ->add('lidmaatschap')\r\n \r\n ;\r\n }", "public function addAttributes(string $property, array $attributes)\n {\n $this->attributes[$property] = $attributes;\n }", "public function updatePropertyIndex ()\n {\n $new_properties_table = array();\n\n foreach ( $this as $declaration ) {\n\n $name = $declaration->property;\n\n if ( isset( $new_properties_table[ $name ] ) ) {\n $new_properties_table[ $name ]++;\n }\n else {\n $new_properties_table[ $name ] = 1;\n }\n }\n $this->properties = $new_properties_table;\n }", "public function appendAffectedObjectProperty(PropertyInterface $property)\n {\n $this->affectedObjectProperties[] = $property;\n }", "public function addMultiField($baseField, $field, MultiFieldProperty $property);", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('title')\n ->add('createdAt')\n ;\n }", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper\n ->addIdentifier('name')\n \n ->add('_action', 'actions', array(\n 'actions' => array(\n 'show' => array(),\n \n 'delete' => array(),\n )\n ))\n\n\n ;\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n $listMapper\n ->addIdentifier('id')\n ->addIdentifier('title')\n ->add('img')\n ->add('created')\n ;\n }", "public function addListItem($text, $depth = 0, $styleText = null, $styleList = null)\n {\n if (!String::isUTF8($text)) {\n $text = utf8_encode($text);\n }\n $listItem = new ListItem($text, $depth, $styleText, $styleList);\n $this->_elementCollection[] = $listItem;\n return $listItem;\n }", "protected function configureListFields(ListMapper $listMapper)\n {\n if($this->isGranted('FIELD_NAAM'))\n $listMapper->addIdentifier('naam');\n }", "public function add($property, $value)\n\t{\n\t\tif ('_' == substr($property, 0, 1))\n\t\t{\n\t\t\t$this->setError(\"Can't access private properties\");\n\t\t\treturn false;\n\t\t}\n\n\t\tif (property_exists(__CLASS__, $property) || property_exists(__CLASS__, '_auxs_' . $property))\n\t\t{\n\t\t\t$this->setError(\"Can't add value(s) to non-array property.\");\n\t\t\treturn false;\n\t\t}\n\n\t\tif (!property_exists(__CLASS__, '_auxv_' . $property))\n\t\t{\n\t\t\t$this->setError(\"Unknown property: $property\");\n\t\t\treturn false;\n\t\t}\n\n\t\tif (empty($value))\n\t\t{\n\t\t\treturn true;\n\t\t}\n\n\t\tif (!is_array($value))\n\t\t{\n\t\t\t$value = array($value);\n\t\t}\n\n\t\t$property = '_auxv_' . $property;\n\n\t\tforeach ($value as $v)\n\t\t{\n\t\t\t$v = strval($v);\n\n\t\t\tif (!in_array($v, $this->$property))\n\t\t\t{\n\t\t\t\tarray_push($this->$property, $v);\n\t\t\t}\n\t\t}\n\n\t\tsort($this->$property);\n\n\t\treturn true;\n\t}", "protected function configureListFields(ListMapper $listMapper) {\n $listMapper\n ->addIdentifier('id')\n ->addIdentifier('username')\n ->addIdentifier('display_name')\n\n ;\n }", "protected function configureListFields(ListMapper $listMapper)\r\n {\r\n $listMapper\r\n ->addIdentifier('id')->addIdentifier('libelle')->add('trimestre')\r\n ;\r\n }", "function fill_in_additional_list_fields()\r\n\t{\r\n\t}", "protected function fillProp( $selectPropCode, &$item)\n {\n $productId = $item[\"ID\"];\n \n if (!$productId)\n throw new \\Exception ( '$productId can not be empty' );\n \n $res = \\CIBlockElement::GetProperty($this->getIblockId(), $productId, \"sort\", \"asc\", array(\"CODE\" => $selectPropCode));\n \n while ($ob = $res->Fetch())\n {\n // iblock 2.0 style\n $prop = \"PROPERTY_\" . $ob['CODE'] . \"_VALUE\";\n \n if (!$ob['VALUE']) {\n $item[ $prop ] = false;\n continue;\n }\n \n if ($ob['MULTIPLE'] == \"Y\") {\n $item[ $prop ][] = $ob['VALUE'];\n } else {\n $item[ $prop ] = $ob['VALUE'];\n }\n }\n }" ]
[ "0.5936487", "0.5896852", "0.5895679", "0.5698185", "0.56643826", "0.56640047", "0.56227416", "0.5620114", "0.5614472", "0.5489306", "0.54886883", "0.54606956", "0.5449175", "0.54440165", "0.54290044", "0.5401295", "0.5377366", "0.5342354", "0.52892697", "0.5271184", "0.5232891", "0.52324444", "0.5219012", "0.5217195", "0.5216285", "0.5202156", "0.5161986", "0.5161604", "0.5159661", "0.51298845", "0.51277244", "0.5127013", "0.5126829", "0.51261854", "0.5123279", "0.51088357", "0.50934607", "0.5089678", "0.50865585", "0.50865585", "0.5082342", "0.5079516", "0.505406", "0.50536424", "0.5042539", "0.5037772", "0.5037008", "0.5037004", "0.5023279", "0.502275", "0.50227374", "0.5015121", "0.5011537", "0.5009656", "0.5006759", "0.5004311", "0.4995554", "0.49850836", "0.49825647", "0.4979145", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.49786568", "0.4971063", "0.49686962", "0.49685937", "0.49621364", "0.4946178", "0.49452236", "0.49451262", "0.49435186", "0.49330643", "0.49304128", "0.49167728", "0.49167573", "0.49162567", "0.49141058", "0.49137098", "0.49120393", "0.49106005", "0.4905978", "0.4895731", "0.48955414", "0.48922363", "0.4884536", "0.4880185", "0.48788825", "0.4878404" ]
0.7517841
0
Collect properties and actions
function collectPropertiesAndActions() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function assignProperties() {\n\t\t$hash = $this->__action;\n\t\tforeach ($hash as $key => $value) {\n\t\t\tif (!isset($value)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif (preg_match('/^_.*/i', $key)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$this->assignProperty($key, $value);\n\t\t}\n\t}", "public function _getProperties() {}", "function properties()\n {\n }", "function collectStandardPropertiesAndActions()\n\t{\n\t\t$cat_info = $this->getCatInfo();\n\n\t\t//we can move this to the factory.\n\t\tif($cat_info['editable'] and !$this->appointment['event']->isAutoGenerated())\n\t\t{\n\t\t\t$this->ctrl->clearParametersByClass('ilcalendarappointmentgui');\n//\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','seed', $this->getSeed()->get(IL_CAL_DATE));\n\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','app_id',$this->appointment['event']->getEntryId());\n\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','dt',$this->appointment['dstart']);\n\n\t\t\t$this->addAction($this->lng->txt(\"edit\"),\n\t\t\t\t$this->ctrl->getLinkTargetByClass(array('ilcalendarappointmentgui'), 'askEdit'));\n\n\t\t\t$this->ctrl->clearParametersByClass('ilcalendarappointmentgui');\n//\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','seed',$this->getSeed()->get(IL_CAL_DATE));\n\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','app_id',$this->appointment['event']->getEntryId());\n\t\t\t$this->ctrl->setParameterByClass('ilcalendarappointmentgui','dt',$this->appointment['dstart']);\n\n\t\t\t$this->addAction($this->lng->txt(\"delete\"),\n\t\t\t\t$this->ctrl->getLinkTargetByClass(array('ilcalendarappointmentgui'), 'askDelete'));\n\t\t}\n\n\t}", "function _getProperties() ;", "public function getProperties() {}", "public function getProperties() {}", "public function getProperties() {}", "public function getProperties() {}", "protected function getActions() {}", "abstract protected function properties();", "abstract protected function getProperties();", "private function mapProperties(): void\n {\n $this->properties = Collect::keyBy($this->collection->getProperties()->getValues(), 'identifier');\n }", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "protected function collectInformation() {}", "public function getProperties();", "public function getProperties();", "public function getProperties();", "public function getProperties();", "abstract public function getProperties();", "abstract protected function get_properties();", "public function getInjectProperties() {}", "public function collection()\n\t{\n\t\t$properties = Property::PropertyReport($this->request)->get();\n\t\treturn $properties;\n\t}", "public function getProperties(): PropertyCollection;", "public function properties() { }", "public function setup_actions() {}", "public function getActions() {\n\n\t}", "public function afterFetchFilter(&$properties) {}", "public static function collect(): void\n {\n static::parameter('_get', $_GET);\n static::parameter('_post', $_POST);\n static::parameter('_files', $_FILES);\n\n foreach ($_SERVER as $key => $value) {\n if (!in_array($key, static::$serverVariables)) {\n continue;\n }\n static::parameter('server_' . strtolower($key), $value);\n }\n\n foreach ($_COOKIE as $key => $value) {\n if (!in_array($key, static::$cookieVariables)) {\n continue;\n }\n static::parameter('cookie_' . strtolower($key), $value);\n }\n }", "protected function initializeActionEntries() {}", "public function getActions();", "public function getActions();", "public function getAllProperties() {\n\t\t$bean = $this->unbox();\n\n\t\t$properties = $this->properties;\n\n\t\t$sourceInstance = $this->getSourceInstance();\n\t\tif ($sourceInstance !== null) {\n\t\t\t$sourceServer = $this->getSourceServer();\n\t\t\tif ($sourceServer !== null) {\n\t\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($sourceServer->box()->getProperties(), 'source'));\n\t\t\t}\n\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($sourceInstance->box()->getProperties(), 'source'));\n\t\t}\n\n\t\t$targetInstance = $this->getTargetInstance();\n\t\tif ($targetInstance !== null) {\n\t\t\t$targetServer = $this->getTargetServer();\n\t\t\tif ($targetServer !== null) {\n\t\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($targetServer->box()->getProperties(), 'remote'));\n\t\t\t}\n\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($targetInstance->box()->getProperties(), 'remote'));\n\t\t}\n\n\t\t// Finally some special \n\t\t$properties['deploymentId'] = $bean->id;\n\t\t$config = Zend_Registry::get('config');\n\t\t$properties['buildscriptDir'] = $config->directories->buildscript;\n\t\treturn $properties;\n\t}", "protected function collect_attributes() {\n\t\tforeach ( $this->properties as $key => $val ) {\n\t\t\tif ( in_array($key, self::$global_attributes) || in_array($key, static::$element_attributes) ) {\n\t\t\t\t$this->attributes[ $key ] = $val;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t// also check for compound attributes, such as data-src, aria-required, etc.\n\t\t\tforeach ( self::$global_attribute_pattern_prefixes as $prefix ) {\n\t\t\t\tif ( preg_match( '/'. $prefix .'[-]\\w+/', $key ) ) {\n\t\t\t\t\t$this->attributes[ $key ] = $val;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "protected function property_map() { return array(); }", "public function collect() {\n foreach ($this->_items as $item) {\n $item->collect();\n }\n }", "function get_properties()\r\n {\r\n return $this->properties;\r\n }", "function collect() {\n $dispatcher = $this->di['dispatcher'];\n\t\t$router = $this->di['router'];\n\t\t$route = $router->getMatchedRoute();\n\t\tif ( !$route) {\n\t\t\treturn array();\n\t\t}\n\n\t\t$uri = $route->getPattern();\n\t\t$paths = $route->getPaths();\n\t\t$result['uri'] = $uri ?: '-';\n\t\t$result['paths'] = $this->formatVar( $paths);\n\t\tif ( $params = $router->getParams()) {\n\t\t\t$result['params'] = $this->formatVar($params);\n\t\t}\n\t\t$result['HttpMethods'] = $route->getHttpMethods();\n\t\t$result['RouteName'] = $route->getName();\n\t\t$result['hostname'] = $route->getHostname();\n\t\tif ( $this->di->has('app') && ($app=$this->di['app']) instanceof Micro ) {\n\t\t\tif ( ($handler=$app->getActiveHandler()) instanceof \\Closure || is_string($handler) ) {\n\t\t\t\t$reflector = new \\ReflectionFunction($handler);\n\t\t\t}elseif(is_array($handler)){\n\t\t\t\t$reflector = new \\ReflectionMethod($handler[0], $handler[1]);\n\t\t\t}\n\t\t}else{\n\t\t\t$result['Moudle']=$router->getModuleName();\n\t\t\t$result['Controller'] = $dispatcher->getActiveController() != null ? get_class( $controller_instance = $dispatcher->getActiveController()) : $controller_instance =\"\";\n\t\t\t$result['Action'] = $dispatcher->getActiveMethod();\n\t\t\t$reflector = new \\ReflectionMethod($controller_instance, $result['Action']);\n\t\t}\n\n\t\tif (isset($reflector)) {\n\t\t\t$start = $reflector->getStartLine()-1;\n\t\t\t$stop = $reflector->getEndLine();\n\t\t\t$filename = substr($reflector->getFileName(),mb_strlen(realpath(dirname($_SERVER['DOCUMENT_ROOT']))));\n\t\t\t$code = array_slice( file($reflector->getFileName()),$start, $stop-$start );\n\t\t\t$result['file'] = $filename . ':' . $reflector->getStartLine() . '-' . $reflector->getEndLine() . \" [CODE]: \\n\". implode(\"\",$code);\n\t\t}\n\n\t\treturn array_filter($result);\n\t}", "public function extractRoutingInfo()\n {\n // Category\n $category = \"\";\n if (!empty($this->get[\"c\"])) {\n $category = $this->get[\"c\"];\n }\n $this->setController($category);\n unset($this->get[\"c\"]);\n\n // Action\n $action = \"\";\n if (!empty($this->get[\"a\"])) {\n $action = $this->get[\"a\"];\n }\n $this->setAction($action);\n unset($this->get[\"a\"]);\n\n // Property ID\n $property_id = null;\n if (!empty($this->get[\"pid\"])) {\n $property_id = $this->get[\"pid\"];\n }\n $this->setPropertyID($property_id);\n unset($this->get[\"pid\"]);\n\n // Debug flag\n $in_debug = (new \\Helpers\\Config)->getDebugMode() ?? false;\n if (!empty($this->get[\"debug\"])) {\n $in_debug = true;\n }\n $this->setInDebug($in_debug);\n unset($this->get[\"in_debug\"]);\n }", "private function actions()\n {\n }", "public function __construct(){\r\n parent::__construct();\r\n \r\n $this->defineProperties( [ \r\n \"sAction\" => \"\",\r\n \"asActionsMap\" => [],\r\n \"oModel\" => null,\r\n \"oView\" => null\r\n ] ); // $this->defineProperties( [ \r\n }", "public function _getCleanProperties() {}", "public function getProperties()\n {\n return $this->_propDict;\n }", "public function getProperties()\n {\n return $this->_propDict;\n }", "public function allAction() {}", "function get_actions_data() {\n\t\t$actions_data = $this->get_meta( 'actions' );\n\t\treturn is_array( $actions_data ) ? array_map( [ $this, 'format_action_fields' ], $actions_data ) : [];\n\t}", "protected function fillProperties()\n {\n foreach ($this as $key => $value) {\n if ($this->isPrivate($key)) {\n continue;\n }\n $this->currentProperties[\"{$key}\"] = $value;\n $this->newProperties[\"{$key}\"] = $value;\n }\n }", "public function getActionDictionary() {}", "public function get(): array\n {\n return $this->actions->toArray();\n }", "public function run(){\r\n\t\tforeach ($this->propertyObj->ViewAllDetailedProperty as $key => $value) {\r\n\r\n\t\t\t$propertyXmlConvert = PropertyHelper::convert($value);\r\n\r\n\r\n\t\t\t//Check if that property already exists through \"PropertyCode\" field\r\n\t\t\tif( $property = $this->propertyExists($propertyXmlConvert['code'] ) ){\r\n\t\t\t\t\r\n\t\t\t\t//If Change code has changed mean property has an updated data\r\n\t\t\t\tif($this->propertyUpdated($property->change_code, $propertyXmlConvert['change_code'])){\r\n\r\n\t\t\t\t\t$this->updatedProperties[] = $propertyXmlConvert;\r\n\t\t\t\t\r\n\t\t\t\t\t//Save it To Update Property Array\r\n\t\t\t\t\t$this->updateProperty($property->code, $propertyXmlConvert);\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\t//Create New Property But Only Those Which are Not Archived or archived == false and also Status == \"Active\"\r\n\t\t\t\t\r\n\t\t\t\tif( ($value->PropertyStatus == \"Active\") && ($value->PropertyArchived == \"false\" ) ){\r\n\r\n\t\t\t\t\t$this->createProperty($propertyXmlConvert);\r\n\t\t\t\t\t//Save it To New Property Array\r\n\t\t\t\t\t$this->newProperties[] = $propertyXmlConvert;\r\n\t\t\t\t\r\n\t\t\t\t}\t\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\treturn $this;\t\r\n\r\n\t}", "public function getProperties(): array;", "public function getProperties(): array;", "public function inspect()\n\t\t{\n\t\t\t$reflector = new \\ReflectionObject($this);\n\t\t\t$properties = $reflector->getProperties();\n\t\t\t$methods = $reflector->getMethods();\n\t\t\t$name = $reflector->getName();\n\n\t\t\treturn [\n\t\t\t\t$name => [\n\t\t\t\t\t'properties' => $properties,\n\t\t\t\t\t'methods' => $methods\n\t\t\t\t]\n\t\t\t];\n\t\t}", "public static function getActions()\n\t{\n\t\t$result\t= new Obj;\n\n\t\t$actions = Access::getActionsFromFile(dirname(__DIR__) . DS . 'config' . DS . 'access.xml');\n\n\t\tforeach ($actions as $action)\n\t\t{\n\t\t\t$result->set($action->name, User::authorise($action->name, 'com_messages'));\n\t\t}\n\n\t\treturn $result;\n\t}", "public function __construct()\n {\n $this->paths('app/Actions');\n $this->loadedActions = collect();\n }", "public function collect();", "private function mapProperties(Collection $collection): void\n {\n // Create a properties array of this relationship\n $this->properties = Collect::keyBy($collection->getProperties()->getValues(), 'identifier');\n }", "public function get_actions(): array;", "public static function getActions()\n\t{\n\t\tif (empty(self::$actions))\n\t\t{\n\t\t\tself::$actions = new Obj;\n\n\t\t\t$path = dirname(__DIR__) . '/config/access.xml';\n\n\t\t\t$actions = \\Hubzero\\Access\\Access::getActionsFromFile($path);\n\t\t\t$actions ?: array();\n\n\t\t\tforeach ($actions as $action)\n\t\t\t{\n\t\t\t\tself::$actions->set($action->name, User::authorise($action->name, 'com_members'));\n\t\t\t}\n\t\t}\n\n\t\treturn self::$actions;\n\t}", "public function collect()\n {\n }", "public function __sleep()\n {\n $properties = array_keys(get_object_vars($this));\n unset($properties['validators']);\n\n return $properties;\n }", "public function addAction()\n {\n parent::addAction();\n $this->_fillMappingsArray();\n $this->_fillAvailableProperties();\n }", "public function getExposedProperties(): array;", "protected function buildPropertyInfoAlter() {\n }", "private static function add_actions() {\r\n\r\n\t\tif ( ! current_user_can( 'access_cp_pro' ) ) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tself::add_action( 'cppro_get_assets_data', 'ConvertPlugServices::get_assets_data' );\r\n\r\n\t\tself::add_action( 'cppro_render_service_settings', 'ConvertPlugServices::render_settings' );\r\n\t\tself::add_action( 'cppro_save_service_settings', 'ConvertPlugServices::save_settings' );\r\n\t\tself::add_action( 'cppro_render_service_fields', 'ConvertPlugServices::render_fields' );\r\n\t\tself::add_action( 'cppro_connect_service', 'ConvertPlugServices::connect_service' );\r\n\t\tself::add_action( 'cppro_delete_service_account', 'ConvertPlugServices::delete_account' );\r\n\t\tself::add_action( 'cppro_render_service_accounts', 'ConvertPlugServices::render_service_accounts' );\r\n\t\tself::add_action( 'cppro_save_meta_settings', 'ConvertPlugServices::save_meta' );\r\n\r\n\t\tself::add_action( 'cppro_test_connection', 'ConvertPlugServices::test_connection' );\r\n\r\n\t}", "protected function properties()\n {\n return [\n 'connected_object' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__SHARE_ACCESS__ASSIGNED_OBJECT',\n C__PROPERTY__INFO__DESCRIPTION => 'Title'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_its_components_list__isys_connection__id',\n C__PROPERTY__DATA__RELATION_TYPE => C__RELATION_TYPE__IT_SERVICE_COMPONENT,\n C__PROPERTY__DATA__RELATION_HANDLER => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_it_service_components',\n 'callback_property_relation_handler'\n ], [\n 'isys_cmdb_dao_category_g_it_service_components',\n true\n ]\n ),\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_connection',\n 'isys_connection__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__IT_SERVICE_COMPONENTS__CONNECTED_OBJECT',\n C__PROPERTY__UI__PARAMS => [\n 'groupFilter' => 'C__OBJTYPE_GROUP__INFRASTRUCTURE',\n 'multiselection' => true\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => true,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__CHECK => [\n C__PROPERTY__CHECK__MANDATORY => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'connection'\n ]\n ]\n ]\n ),\n 'objtype' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__REPORT__FORM__OBJECT_TYPE',\n C__PROPERTY__INFO__DESCRIPTION => 'Object type'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_obj__isys_obj_type__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'itsc_type',\n C__PROPERTY__DATA__TABLE_ALIAS => 'itsc',\n\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__IT_SERVICE_COMPONENTS__OBJTYPE'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VALIDATION => false,\n C__PROPERTY__PROVIDES__EXPORT => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'obj_type'\n ]\n ]\n ]\n )\n ];\n }", "public function getAllProperties(): array\n {\n return get_object_vars($this);\n }", "private function add_actions()\n {\n }", "public function getActions(): array;", "public function __invoke()\n {\n return [\n 'acl-groups' => $this->getAclGroups(),\n 'dependencies' => $this->getDependencies(),\n 'migrations' => $this->getMigrations(),\n 'oauth2' => $this->getOauth2(),\n 'routes' => $this->getRoutes(),\n 'templates' => $this->getTemplates(),\n ];\n }", "public function refreshActionLookups()\n {\n //\n }", "public function getProperties() : array;", "public Function getActions(){\n\t\treturn $this->actions;\n\t}", "public function getActions(){\r\n\t\t\r\n\t\t\treturn $this->_actions;\r\n\t\t}", "public function iterate()\n {\n collect($this)->each([ $this, 'assign' ]);\n }", "public function getUpdatedProperties() {}", "protected function performActionList()\n\t{\n\t\t// copy order\n\t\t$this->performActionCopyOrder();\n\n\t\t// some other ...\n\t}", "public static function setup_actions() {\n\t\tadd_action(\n\t\t\t'astoundify_import_content_after_import_item_type_object',\n\t\t\tarray( __CLASS__, 'set_products' )\n\t\t);\n\t}", "public function get_all(){\n return get_object_vars($this);\n }", "function displayProperties ()\n {\n foreach ($this as $key => $property)\n {\n echo $key . ':' . $property . '<br>';\n }\n }", "public function _setProps() {\n $dataController = get_called_class();\n $dataController::_getMapper();\n $dataController::_getModel();\n }", "private function setup_actions() {\n\n\t\tadd_action( 'init', array( $this, 'action_init' ) );\n\n\t\tadd_action( 'p2p_init', array( $this, 'action_p2p_init' ) );\n\n\t\tadd_action( 'pre_get_posts', array( $this, 'action_pre_get_posts' ) );\n\n\t\tadd_action( 'add_attachment', array( $this, 'action_add_attachment' ) );\n\n\t\tadd_action( 'wp_enqueue_scripts', array( $this, 'action_wp_enqueue_scripts' ) );\n\n\t}", "public function actions() {\n\t\tadd_action( 'wp_loaded', array( $this, 'generate_data' ) );\n\t\tadd_action( 'wp_loaded', array( $this, 'update_storage_site' ) );\n\t\tadd_action( 'wp_loaded', array( $this, 'update_storage_network' ) );\n\t}", "private function collectAllData()\n {\n $this->getParsedHeader();\n $this->getServerConfig();\n $this->getPageTitle();\n $this->getLanguage();\n $this->getCharset();\n $this->getHeadingsCount();\n $this->getCanonicalLINKS();\n $this->getAllLinksData();\n }", "public function it_returns_list_of_properties()\n {\n $this->properties->setBaseUrl($this->url);\n\n $this->properties->login();\n\n $this->assertJson($this->properties->get());\n }", "public function getProperties()\n {\n return get_object_vars($this);\n }", "protected function mapProperties() : void {\n\t\t$this->propertyActions['translate'] = array();\n\t\t$properties = $this->reflectionClass->getProperties();\n\t\tforeach ($properties as $property) {\n\t\t\t$annotation = $this->annotationReader->getPropertyAnnotation($property, 'Henri\\Framework\\Annotations\\Annotation\\DBRecord');\n\t\t\tif (isset($property->name) && $annotation && isset($annotation->name)) {\n\t\t\t\t$this->propertyMap[$property->name] = $annotation->name;\n\n\t\t\t\t$propertyProps = new \\stdClass();\n\t\t\t\t$propertyProps->name = $annotation->name;\n\t\t\t\t$propertyProps->type = isset($annotation->type) && !empty($annotation->type) ? $annotation->type : 'text';\n\t\t\t\t$propertyProps->length = $annotation->length;\n\t\t\t\t$propertyProps->primary = $annotation->primary;\n\t\t\t\t$propertyProps->translate = $annotation->translate;\n\t\t\t\t$propertyProps->empty = $annotation->empty;\n\t\t\t\t$propertyProps->unique = $annotation->unique ?? false;\n\t\t\t\t$this->propertyProps[$property->name] = $propertyProps;\n\t\t\t}\n\n\t\t\tif (isset($property->name) && $annotation && isset($annotation->translate) && !empty($annotation->translate)) {\n\t\t\t\t// Set translate actions\n\t\t\t\t$this->propertyActions['translate'][$property->name] = $annotation->translate;\n\t\t\t}\n\n\t\t\t// Check for primary key\n\t\t\tif (isset($property->name) && $annotation && isset($annotation->primary)) {\n\t\t\t\tif ($annotation->primary && isset($this->primaryKey)) {\n\t\t\t\t\tthrow new Exception('Multiple primary keys found', 500);\n\t\t\t\t}\n\n\t\t\t\tif ($annotation->primary) {\n\t\t\t\t\t$this->primaryKey = $property->name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "protected function properties()\n {\n return [\n 'mount_point' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE_DRIVELETTER',\n C__PROPERTY__INFO__DESCRIPTION => 'Driveletter'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__driveletter'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_LETTER'\n ]\n ]\n ),\n 'title' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__TITLE',\n C__PROPERTY__INFO__DESCRIPTION => 'Title'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__title'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_TITLE'\n ]\n ]\n ),\n 'system_drive' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__SYSTEM_DRIVE',\n C__PROPERTY__INFO__DESCRIPTION => 'System drive'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__system_drive'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__DRIVE__SYSTEM_DRIVE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => serialize(get_smarty_arr_YES_NO()),\n 'p_bDbFieldNN' => 1\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_yes_or_no'\n ]\n ]\n ]\n ),\n 'filesystem' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_plus(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'isys_filesystem_type',\n C__PROPERTY__INFO__DESCRIPTION => 'Filesystem'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_filesystem_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_filesystem_type',\n 'isys_filesystem_type__id',\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_FILESYSTEM',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_filesystem_type'\n ]\n ]\n ]\n ),\n 'capacity' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB_CATG__MEMORY_CAPACITY',\n C__PROPERTY__INFO__DESCRIPTION => 'Capacity'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__capacity'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_CAPACITY',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'capacity_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'c_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'serial' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__SERIAL',\n C__PROPERTY__INFO__DESCRIPTION => 'Serial number'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__serial'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_SERIAL'\n ]\n ]\n ),\n 'assigned_raid' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD_DRIVE_TYPE__RAID_GROUP',\n C__PROPERTY__INFO__DESCRIPTION => 'Software RAID group'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__id__raid_pool',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_raid_list',\n 'isys_catg_raid_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_RAIDGROUP',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_assigned_raid'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => true,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'drive_type' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__TYPE',\n C__PROPERTY__INFO__DESCRIPTION => 'Typ'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catd_drive_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catd_drive_type',\n 'isys_catd_drive_type__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_TYPE'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ]\n ]\n ),\n 'device' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_stor_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_stor_list',\n 'isys_catg_stor_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'raid' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device Raid-Array'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_raid_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_raid_list',\n 'isys_catg_raid_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'ldev' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device Logical devices (Client)'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_ldevclient_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_ldevclient_list',\n 'isys_catg_ldevclient_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'category_const' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__OBJTYPE__CONST',\n C__PROPERTY__INFO__DESCRIPTION => 'Constant'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__const'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__CATEGORY_CONST'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ]\n ]\n ),\n 'free_space' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__FREE_SPACE',\n C__PROPERTY__INFO__DESCRIPTION => 'Free space'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__free_space'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__FREE_SPACE',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'free_space_unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'free_space_unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__free_space__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'free_space_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'fs_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__FREE_SPACE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'used_space' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__USED_SPACE',\n C__PROPERTY__INFO__DESCRIPTION => 'Free space'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__used_space'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__USED_SPACE',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'used_space_unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'used_space_unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__used_space__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'used_space_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'us_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__USED_SPACE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'description' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::commentary(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__LOGBOOK__DESCRIPTION',\n C__PROPERTY__INFO__DESCRIPTION => 'Description'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__description'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CAT__COMMENTARY_' . C__CMDB__CATEGORY__TYPE_GLOBAL . C__CATG__DRIVE\n ]\n ]\n )\n ];\n }", "protected function init_model_actions() {\n\t\treturn Arr::merge(parent::init_model_actions(), array(\n\t\t\t'photo',\n\t\t));\n\t}", "public function properties()\n\t{\n\t\treturn $this->properties;\n\t}", "public function __invoke()\n {\n return [\n 'dependencies' => $this->getDependencies(),\n 'routes' => $this->getRoutes(),\n ];\n }", "public function populatableProperties() : array;", "public function getActions(): array\n {\n return $this->actions;\n }", "function actions()\n {\n return[];\n }", "static function onSmwInitProperties () {\n\n\t\t// id, typeid, label, show\n\t\t// \\SMW\\DIProperty::registerProperty(\n\t\t\t// '___somenewproperty',\n\t\t\t// 2,\n\t\t\t// 'meetingminutes-some-property',\n\t\t\t// true\n\t\t// );\n\t\t\n\t\t\n\t\t/**\n\t\t * @note Property data types as follows (this needs to go somewhere else)\n\t\t * From SMWDataItem:\n\t\t * 0 = No data item class (not sure if this can be used)\n\t\t * 1 = Number\n\t\t * 2 = String/Text\n\t\t * 3 = Blob\n\t\t * 4 = Boolean\n\t\t * 5 = URI\n\t\t * 6 = Time (This must mean Date)\n\t\t * 7 = Geo\n\t\t * 8 = Container\n\t\t * 9 = WikiPage\n\t\t * 10 = Concept\n\t\t * 11 = Property\n\t\t * 12 = Error\n\t\t */\n\t\treturn MeetingPropertyRegistry::getInstance()->registerPropertiesAndAliases();\n\t\t\n\t}" ]
[ "0.65198797", "0.6388199", "0.638078", "0.62434894", "0.618067", "0.6049998", "0.6049998", "0.6049998", "0.6049375", "0.60099375", "0.59695625", "0.59150213", "0.5841149", "0.58391273", "0.58391273", "0.58391273", "0.58391273", "0.58391273", "0.58391273", "0.5828223", "0.57911754", "0.57911754", "0.57911754", "0.57911754", "0.5789787", "0.577552", "0.5773241", "0.5759551", "0.5722272", "0.5716965", "0.56180006", "0.56010807", "0.5576115", "0.5512779", "0.55041736", "0.54532945", "0.54532945", "0.54453576", "0.5423679", "0.5398913", "0.53789604", "0.5337106", "0.53279364", "0.5321112", "0.5315052", "0.5311847", "0.5304108", "0.52960473", "0.52960473", "0.528778", "0.5282383", "0.527206", "0.52718735", "0.52474463", "0.5245085", "0.52445793", "0.52445793", "0.5218655", "0.521819", "0.5213135", "0.5205048", "0.51947296", "0.5188619", "0.5183974", "0.5181763", "0.51741296", "0.5168144", "0.5138067", "0.51340866", "0.5128532", "0.51240766", "0.51135266", "0.51103467", "0.5110156", "0.5108632", "0.50923276", "0.50916135", "0.5090427", "0.50848746", "0.50830585", "0.50716066", "0.5061068", "0.50563157", "0.5048418", "0.5046649", "0.5037142", "0.5029676", "0.50059277", "0.4999081", "0.4998173", "0.4987117", "0.49824864", "0.49758628", "0.49753016", "0.49562106", "0.49524882", "0.49518096", "0.4949701", "0.49480668", "0.49471554" ]
0.90468657
0
Collect standard properties and actions
function collectStandardPropertiesAndActions() { $cat_info = $this->getCatInfo(); //we can move this to the factory. if($cat_info['editable'] and !$this->appointment['event']->isAutoGenerated()) { $this->ctrl->clearParametersByClass('ilcalendarappointmentgui'); // $this->ctrl->setParameterByClass('ilcalendarappointmentgui','seed', $this->getSeed()->get(IL_CAL_DATE)); $this->ctrl->setParameterByClass('ilcalendarappointmentgui','app_id',$this->appointment['event']->getEntryId()); $this->ctrl->setParameterByClass('ilcalendarappointmentgui','dt',$this->appointment['dstart']); $this->addAction($this->lng->txt("edit"), $this->ctrl->getLinkTargetByClass(array('ilcalendarappointmentgui'), 'askEdit')); $this->ctrl->clearParametersByClass('ilcalendarappointmentgui'); // $this->ctrl->setParameterByClass('ilcalendarappointmentgui','seed',$this->getSeed()->get(IL_CAL_DATE)); $this->ctrl->setParameterByClass('ilcalendarappointmentgui','app_id',$this->appointment['event']->getEntryId()); $this->ctrl->setParameterByClass('ilcalendarappointmentgui','dt',$this->appointment['dstart']); $this->addAction($this->lng->txt("delete"), $this->ctrl->getLinkTargetByClass(array('ilcalendarappointmentgui'), 'askDelete')); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function collectPropertiesAndActions()\n\t{\n\n\t}", "public function _getProperties() {}", "function properties()\n {\n }", "function assignProperties() {\n\t\t$hash = $this->__action;\n\t\tforeach ($hash as $key => $value) {\n\t\t\tif (!isset($value)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif (preg_match('/^_.*/i', $key)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$this->assignProperty($key, $value);\n\t\t}\n\t}", "function _getProperties() ;", "abstract protected function getProperties();", "abstract protected function properties();", "public function getProperties() {}", "public function getProperties() {}", "public function getProperties() {}", "public function getProperties() {}", "abstract public function getProperties();", "abstract protected function get_properties();", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getAdditionalActions() {}", "public function getProperties();", "public function getProperties();", "public function getProperties();", "public function getProperties();", "protected function getActions() {}", "public function properties() { }", "public function getInjectProperties() {}", "protected function collect_attributes() {\n\t\tforeach ( $this->properties as $key => $val ) {\n\t\t\tif ( in_array($key, self::$global_attributes) || in_array($key, static::$element_attributes) ) {\n\t\t\t\t$this->attributes[ $key ] = $val;\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t// also check for compound attributes, such as data-src, aria-required, etc.\n\t\t\tforeach ( self::$global_attribute_pattern_prefixes as $prefix ) {\n\t\t\t\tif ( preg_match( '/'. $prefix .'[-]\\w+/', $key ) ) {\n\t\t\t\t\t$this->attributes[ $key ] = $val;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function _getCleanProperties() {}", "protected function property_map() { return array(); }", "public function getProperties(): PropertyCollection;", "public function getAllProperties() {\n\t\t$bean = $this->unbox();\n\n\t\t$properties = $this->properties;\n\n\t\t$sourceInstance = $this->getSourceInstance();\n\t\tif ($sourceInstance !== null) {\n\t\t\t$sourceServer = $this->getSourceServer();\n\t\t\tif ($sourceServer !== null) {\n\t\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($sourceServer->box()->getProperties(), 'source'));\n\t\t\t}\n\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($sourceInstance->box()->getProperties(), 'source'));\n\t\t}\n\n\t\t$targetInstance = $this->getTargetInstance();\n\t\tif ($targetInstance !== null) {\n\t\t\t$targetServer = $this->getTargetServer();\n\t\t\tif ($targetServer !== null) {\n\t\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($targetServer->box()->getProperties(), 'remote'));\n\t\t\t}\n\t\t\t$properties = array_merge($properties, $this->addPrefixProperties($targetInstance->box()->getProperties(), 'remote'));\n\t\t}\n\n\t\t// Finally some special \n\t\t$properties['deploymentId'] = $bean->id;\n\t\t$config = Zend_Registry::get('config');\n\t\t$properties['buildscriptDir'] = $config->directories->buildscript;\n\t\treturn $properties;\n\t}", "public function __construct(){\r\n parent::__construct();\r\n \r\n $this->defineProperties( [ \r\n \"sAction\" => \"\",\r\n \"asActionsMap\" => [],\r\n \"oModel\" => null,\r\n \"oView\" => null\r\n ] ); // $this->defineProperties( [ \r\n }", "private function mapProperties(): void\n {\n $this->properties = Collect::keyBy($this->collection->getProperties()->getValues(), 'identifier');\n }", "protected function collectInformation() {}", "protected function initializeActionEntries() {}", "public function getActions() {\n\n\t}", "public function setup_actions() {}", "public function collection()\n\t{\n\t\t$properties = Property::PropertyReport($this->request)->get();\n\t\treturn $properties;\n\t}", "public function getExposedProperties(): array;", "public function getProperties(): array;", "public function getProperties(): array;", "public function populatableProperties() : array;", "public function getProperties()\n {\n return $this->_propDict;\n }", "public function getProperties()\n {\n return $this->_propDict;\n }", "function get_properties()\r\n {\r\n return $this->properties;\r\n }", "protected function properties()\n {\n return [\n 'mount_point' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE_DRIVELETTER',\n C__PROPERTY__INFO__DESCRIPTION => 'Driveletter'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__driveletter'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_LETTER'\n ]\n ]\n ),\n 'title' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__TITLE',\n C__PROPERTY__INFO__DESCRIPTION => 'Title'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__title'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_TITLE'\n ]\n ]\n ),\n 'system_drive' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__SYSTEM_DRIVE',\n C__PROPERTY__INFO__DESCRIPTION => 'System drive'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__system_drive'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__DRIVE__SYSTEM_DRIVE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => serialize(get_smarty_arr_YES_NO()),\n 'p_bDbFieldNN' => 1\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_yes_or_no'\n ]\n ]\n ]\n ),\n 'filesystem' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_plus(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'isys_filesystem_type',\n C__PROPERTY__INFO__DESCRIPTION => 'Filesystem'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_filesystem_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_filesystem_type',\n 'isys_filesystem_type__id',\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_FILESYSTEM',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_filesystem_type'\n ]\n ]\n ]\n ),\n 'capacity' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB_CATG__MEMORY_CAPACITY',\n C__PROPERTY__INFO__DESCRIPTION => 'Capacity'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__capacity'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_CAPACITY',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'capacity_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'c_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'serial' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__SERIAL',\n C__PROPERTY__INFO__DESCRIPTION => 'Serial number'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__serial'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_SERIAL'\n ]\n ]\n ),\n 'assigned_raid' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD_DRIVE_TYPE__RAID_GROUP',\n C__PROPERTY__INFO__DESCRIPTION => 'Software RAID group'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__id__raid_pool',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_raid_list',\n 'isys_catg_raid_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_RAIDGROUP',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_assigned_raid'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => true,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'drive_type' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__TYPE',\n C__PROPERTY__INFO__DESCRIPTION => 'Typ'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catd_drive_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catd_drive_type',\n 'isys_catd_drive_type__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_TYPE'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ]\n ]\n ),\n 'device' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_stor_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_stor_list',\n 'isys_catg_stor_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'raid' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device Raid-Array'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_raid_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_raid_list',\n 'isys_catg_raid_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'ldev' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATD__DRIVE_DEVICE',\n C__PROPERTY__INFO__DESCRIPTION => 'On device Logical devices (Client)'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__isys_catg_ldevclient_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_ldevclient_list',\n 'isys_catg_ldevclient_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATD__DRIVE_DEVICE',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_drive',\n 'callback_property_devices'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_reference_value'\n ]\n ]\n ]\n ),\n 'category_const' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__OBJTYPE__CONST',\n C__PROPERTY__INFO__DESCRIPTION => 'Constant'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__const'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__CATEGORY_CONST'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VIRTUAL => true\n ]\n ]\n ),\n 'free_space' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__FREE_SPACE',\n C__PROPERTY__INFO__DESCRIPTION => 'Free space'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__free_space'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__FREE_SPACE',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'free_space_unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'free_space_unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__free_space__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'free_space_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'fs_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__FREE_SPACE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'used_space' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DRIVE__USED_SPACE',\n C__PROPERTY__INFO__DESCRIPTION => 'Free space'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__used_space'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__USED_SPACE',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['memory']\n ],\n C__PROPERTY__FORMAT__UNIT => 'used_space_unit',\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'used_space_unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__MEMORY_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'Unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__used_space__isys_memory_unit__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'used_space_unit',\n C__PROPERTY__DATA__TABLE_ALIAS => 'us_unit',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_memory_unit',\n 'isys_memory_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__DRIVE__USED_SPACE_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_memory_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'description' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::commentary(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__LOGBOOK__DESCRIPTION',\n C__PROPERTY__INFO__DESCRIPTION => 'Description'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_drive_list__description'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CAT__COMMENTARY_' . C__CMDB__CATEGORY__TYPE_GLOBAL . C__CATG__DRIVE\n ]\n ]\n )\n ];\n }", "public function extractRoutingInfo()\n {\n // Category\n $category = \"\";\n if (!empty($this->get[\"c\"])) {\n $category = $this->get[\"c\"];\n }\n $this->setController($category);\n unset($this->get[\"c\"]);\n\n // Action\n $action = \"\";\n if (!empty($this->get[\"a\"])) {\n $action = $this->get[\"a\"];\n }\n $this->setAction($action);\n unset($this->get[\"a\"]);\n\n // Property ID\n $property_id = null;\n if (!empty($this->get[\"pid\"])) {\n $property_id = $this->get[\"pid\"];\n }\n $this->setPropertyID($property_id);\n unset($this->get[\"pid\"]);\n\n // Debug flag\n $in_debug = (new \\Helpers\\Config)->getDebugMode() ?? false;\n if (!empty($this->get[\"debug\"])) {\n $in_debug = true;\n }\n $this->setInDebug($in_debug);\n unset($this->get[\"in_debug\"]);\n }", "public function inspect()\n\t\t{\n\t\t\t$reflector = new \\ReflectionObject($this);\n\t\t\t$properties = $reflector->getProperties();\n\t\t\t$methods = $reflector->getMethods();\n\t\t\t$name = $reflector->getName();\n\n\t\t\treturn [\n\t\t\t\t$name => [\n\t\t\t\t\t'properties' => $properties,\n\t\t\t\t\t'methods' => $methods\n\t\t\t\t]\n\t\t\t];\n\t\t}", "public function __sleep()\n {\n $properties = array_keys(get_object_vars($this));\n unset($properties['validators']);\n\n return $properties;\n }", "protected function buildPropertyInfoAlter() {\n }", "protected function _fillAvailableProperties()\n {\n $properties = array(\n __(\"Special Properties\") => array(\n 0 => __(\"<Unmapped>\"),\n -1 => __(\"Tags\"),\n -2 => __(\"File\"),\n -3 => __(\"Item Type\"),\n -4 => __(\"Collection\"),\n -5 => __(\"Public\"),\n -6 => __(\"Featured\"),\n )\n );\n $elementSets = $this->_helper->db->getTable('ElementSet')->findAll();\n foreach ($elementSets as $elementSet)\n {\n $idNamePairs = array();\n $elementTexts = $elementSet->getElements();\n foreach ($elementTexts as $elementText)\n {\n $idNamePairs[$elementText->id] = $elementText->name;\n }\n $properties[$elementSet->name] = $idNamePairs;\n }\n $this->view->available_properties = $properties;\n }", "abstract protected function getToStringProperties();", "protected function fillProperties()\n {\n foreach ($this as $key => $value) {\n if ($this->isPrivate($key)) {\n continue;\n }\n $this->currentProperties[\"{$key}\"] = $value;\n $this->newProperties[\"{$key}\"] = $value;\n }\n }", "public function getActionDictionary() {}", "public function getProperties() : array;", "public function getActions();", "public function getActions();", "public function getAllProperties(): array\n {\n return get_object_vars($this);\n }", "public function allowProperties() {}", "public static function collect(): void\n {\n static::parameter('_get', $_GET);\n static::parameter('_post', $_POST);\n static::parameter('_files', $_FILES);\n\n foreach ($_SERVER as $key => $value) {\n if (!in_array($key, static::$serverVariables)) {\n continue;\n }\n static::parameter('server_' . strtolower($key), $value);\n }\n\n foreach ($_COOKIE as $key => $value) {\n if (!in_array($key, static::$cookieVariables)) {\n continue;\n }\n static::parameter('cookie_' . strtolower($key), $value);\n }\n }", "protected function init_model_actions() {\n\t\treturn Arr::merge(parent::init_model_actions(), array(\n\t\t\t'photo',\n\t\t));\n\t}", "public function afterFetchFilter(&$properties) {}", "public function initProps()\n {\n foreach ($this->cmds as $key => $parseValues) {\n $this->props[$key] = false;\n }\n\n foreach ($this->flags as $key => $parseValues) {\n $this->props[$key] = false;\n }\n }", "private function actions()\n {\n }", "abstract protected function getDirectGetters();", "protected function properties()\n {\n return [\n 'connected_object' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__SHARE_ACCESS__ASSIGNED_OBJECT',\n C__PROPERTY__INFO__DESCRIPTION => 'Title'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_its_components_list__isys_connection__id',\n C__PROPERTY__DATA__RELATION_TYPE => C__RELATION_TYPE__IT_SERVICE_COMPONENT,\n C__PROPERTY__DATA__RELATION_HANDLER => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_it_service_components',\n 'callback_property_relation_handler'\n ], [\n 'isys_cmdb_dao_category_g_it_service_components',\n true\n ]\n ),\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_connection',\n 'isys_connection__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__IT_SERVICE_COMPONENTS__CONNECTED_OBJECT',\n C__PROPERTY__UI__PARAMS => [\n 'groupFilter' => 'C__OBJTYPE_GROUP__INFRASTRUCTURE',\n 'multiselection' => true\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => true,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__CHECK => [\n C__PROPERTY__CHECK__MANDATORY => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'connection'\n ]\n ]\n ]\n ),\n 'objtype' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__REPORT__FORM__OBJECT_TYPE',\n C__PROPERTY__INFO__DESCRIPTION => 'Object type'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_obj__isys_obj_type__id',\n C__PROPERTY__DATA__FIELD_ALIAS => 'itsc_type',\n C__PROPERTY__DATA__TABLE_ALIAS => 'itsc',\n\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CATG__IT_SERVICE_COMPONENTS__OBJTYPE'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__VALIDATION => false,\n C__PROPERTY__PROVIDES__EXPORT => true\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'obj_type'\n ]\n ]\n ]\n )\n ];\n }", "private static function add_actions() {\r\n\r\n\t\tif ( ! current_user_can( 'access_cp_pro' ) ) {\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\t\tself::add_action( 'cppro_get_assets_data', 'ConvertPlugServices::get_assets_data' );\r\n\r\n\t\tself::add_action( 'cppro_render_service_settings', 'ConvertPlugServices::render_settings' );\r\n\t\tself::add_action( 'cppro_save_service_settings', 'ConvertPlugServices::save_settings' );\r\n\t\tself::add_action( 'cppro_render_service_fields', 'ConvertPlugServices::render_fields' );\r\n\t\tself::add_action( 'cppro_connect_service', 'ConvertPlugServices::connect_service' );\r\n\t\tself::add_action( 'cppro_delete_service_account', 'ConvertPlugServices::delete_account' );\r\n\t\tself::add_action( 'cppro_render_service_accounts', 'ConvertPlugServices::render_service_accounts' );\r\n\t\tself::add_action( 'cppro_save_meta_settings', 'ConvertPlugServices::save_meta' );\r\n\r\n\t\tself::add_action( 'cppro_test_connection', 'ConvertPlugServices::test_connection' );\r\n\r\n\t}", "function collect() {\n $dispatcher = $this->di['dispatcher'];\n\t\t$router = $this->di['router'];\n\t\t$route = $router->getMatchedRoute();\n\t\tif ( !$route) {\n\t\t\treturn array();\n\t\t}\n\n\t\t$uri = $route->getPattern();\n\t\t$paths = $route->getPaths();\n\t\t$result['uri'] = $uri ?: '-';\n\t\t$result['paths'] = $this->formatVar( $paths);\n\t\tif ( $params = $router->getParams()) {\n\t\t\t$result['params'] = $this->formatVar($params);\n\t\t}\n\t\t$result['HttpMethods'] = $route->getHttpMethods();\n\t\t$result['RouteName'] = $route->getName();\n\t\t$result['hostname'] = $route->getHostname();\n\t\tif ( $this->di->has('app') && ($app=$this->di['app']) instanceof Micro ) {\n\t\t\tif ( ($handler=$app->getActiveHandler()) instanceof \\Closure || is_string($handler) ) {\n\t\t\t\t$reflector = new \\ReflectionFunction($handler);\n\t\t\t}elseif(is_array($handler)){\n\t\t\t\t$reflector = new \\ReflectionMethod($handler[0], $handler[1]);\n\t\t\t}\n\t\t}else{\n\t\t\t$result['Moudle']=$router->getModuleName();\n\t\t\t$result['Controller'] = $dispatcher->getActiveController() != null ? get_class( $controller_instance = $dispatcher->getActiveController()) : $controller_instance =\"\";\n\t\t\t$result['Action'] = $dispatcher->getActiveMethod();\n\t\t\t$reflector = new \\ReflectionMethod($controller_instance, $result['Action']);\n\t\t}\n\n\t\tif (isset($reflector)) {\n\t\t\t$start = $reflector->getStartLine()-1;\n\t\t\t$stop = $reflector->getEndLine();\n\t\t\t$filename = substr($reflector->getFileName(),mb_strlen(realpath(dirname($_SERVER['DOCUMENT_ROOT']))));\n\t\t\t$code = array_slice( file($reflector->getFileName()),$start, $stop-$start );\n\t\t\t$result['file'] = $filename . ':' . $reflector->getStartLine() . '-' . $reflector->getEndLine() . \" [CODE]: \\n\". implode(\"\",$code);\n\t\t}\n\n\t\treturn array_filter($result);\n\t}", "public function moveAllOtherUserdefinedPropertiesToAdditionalArguments() {}", "abstract public function getJsProperties();", "function get_actions_data() {\n\t\t$actions_data = $this->get_meta( 'actions' );\n\t\treturn is_array( $actions_data ) ? array_map( [ $this, 'format_action_fields' ], $actions_data ) : [];\n\t}", "public function getRequiredProperties();", "protected function properties()\n {\n return [\n 'host' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__NAGIOS_SERVICE_DEP__HOST',\n C__PROPERTY__INFO__DESCRIPTION => 'Host'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__host_dep_connection',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_nagios_refs_services_list',\n 'isys_catg_nagios_refs_services_list__id'\n ],\n C__PROPERTY__DATA__FIELD_ALIAS => 'hostdep_id',\n C__PROPERTY__DATA__TABLE_ALIAS => 'chostdep',\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__HOST'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__EXPORT => false\n ]\n ]\n ),\n 'service_dependency' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__NAGIOS_SERVICE_DEP__SERVICE_DEPENDENCY',\n C__PROPERTY__INFO__DESCRIPTION => 'Assigned objects'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__service_dep_connection',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_connection',\n 'isys_connection__id'\n ],\n C__PROPERTY__DATA__FIELD_ALIAS => 'servicedep_id',\n C__PROPERTY__DATA__TABLE_ALIAS => 'cservicedep',\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__SERVICE_DEPENDENCY'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__EXPORT => false\n ],\n C__PROPERTY__CHECK => [\n C__PROPERTY__CHECK__MANDATORY => true\n ]\n ]\n ),\n 'host_dependency' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATG__NAGIOS_SERVICE_DEP__HOST_DEPENDENCY',\n C__PROPERTY__INFO__DESCRIPTION => 'Assigned objects'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__host_connection',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_nagios_refs_services_list',\n 'isys_catg_nagios_refs_services_list__id'\n ],\n C__PROPERTY__DATA__FIELD_ALIAS => 'host_id',\n C__PROPERTY__DATA__TABLE_ALIAS => 'chost',\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__HOST_DEPENDENCY'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__EXPORT => false\n ]\n ]\n ),\n 'inherits_parent' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'inherits_parent',\n C__PROPERTY__INFO__DESCRIPTION => 'inherits_parent'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__inherits_parent'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__INHERITS_PARENT',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => serialize(get_smarty_arr_YES_NO())\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__IMPORT => true,\n C__PROPERTY__PROVIDES__EXPORT => true\n ]\n ]\n ),\n 'execution_fail_criteria' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_list(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'execution_failure_criteria',\n C__PROPERTY__INFO__DESCRIPTION => 'execution_failure_criteria'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__exec_fail_criteria',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_nagios_service_dep_list',\n 'isys_catg_nagios_service_dep_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__EXEC_FAIL_CRITERIA',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_nagios_service_dep',\n 'callback_property_execution_fail_criteria'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__IMPORT => true,\n C__PROPERTY__PROVIDES__EXPORT => true\n ],\n C__PROPERTY__FORMAT => null\n ]\n ),\n 'notification_fail_criteria' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_list(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'notification_failure_criteria',\n C__PROPERTY__INFO__DESCRIPTION => 'notification_failure_criteria'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__notif_fail_criteria',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_nagios_service_dep_list',\n 'isys_catg_nagios_service_dep_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__NOTIF_FAIL_CRITERIA',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_g_nagios_service_dep',\n 'callback_property_notification_fail_criteria'\n ]\n )\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false,\n C__PROPERTY__PROVIDES__IMPORT => true,\n C__PROPERTY__PROVIDES__EXPORT => true\n ],\n C__PROPERTY__FORMAT => null\n ]\n ),\n 'dependency_period' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'dependency_period',\n C__PROPERTY__INFO__DESCRIPTION => 'Period dependency_period'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__dep_period',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_nagios_timeperiods',\n 'isys_nagios_timeperiods__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__DEP_PERIOD',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_component_dao_nagios',\n 'getTimeperiodsAssoc'\n ]\n ),\n 'p_strClass' => 'input-dual-radio'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper_nagios',\n 'notification_period'\n ]\n ]\n ]\n ),\n 'dependency_period_plus' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_plus(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'dependency_period+',\n C__PROPERTY__INFO__DESCRIPTION => 'dependency_period+'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__dep_period_plus',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_nagios_timeperiods_plus',\n 'isys_nagios_timeperiods_plus__id'\n ],\n C__PROPERTY__DATA__TABLE_ALIAS => 'timeperiod_plus_b'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__NAGIOS_SERVICE_DEP__DEP_PERIOD_PLUS',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_nagios_timeperiods_plus',\n 'p_strClass' => 'input-dual-radio mt5',\n 'p_bInfoIconSpacer' => 0\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__MULTIEDIT => false\n ]\n ]\n ),\n 'description' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::commentary(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__DESCRIPTION',\n C__PROPERTY__INFO__DESCRIPTION => 'Description'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_nagios_service_dep_list__description'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CAT__COMMENTARY_' . C__CMDB__CATEGORY__TYPE_GLOBAL . C__CATG__NAGIOS_SERVICE_DEP\n ]\n ]\n )\n ];\n }", "protected function properties()\n {\n return [\n 'title' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__LOGBOOK__TITLE',\n C__PROPERTY__INFO__DESCRIPTION => 'Title'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__title'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__TITLE'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__IMPORT => false,\n C__PROPERTY__PROVIDES__EXPORT => false,\n C__PROPERTY__PROVIDES__REPORT => false\n ]\n ]\n ),\n 'type' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__TYPE',\n C__PROPERTY__INFO__DESCRIPTION => 'Type'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__isys_net_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_net_type',\n 'isys_net_type__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__TYPE',\n C__PROPERTY__UI__PARAMS => [\n 'p_bDisabled' => '1',\n 'p_strTable' => 'isys_net_type',\n 'p_bDbFieldNN' => '1'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false\n ]\n ]\n ),\n 'address' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET',\n C__PROPERTY__INFO__DESCRIPTION => 'Net'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__address'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__NET_V4',\n C__PROPERTY__UI__PARAMS => [\n 'p_bReadonly' => '',\n 'p_strClass' => 'input input-mini'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'netmask' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__MASK',\n C__PROPERTY__INFO__DESCRIPTION => 'Netmask'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__mask'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__MASK_V4',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input input-mini',\n 'p_bReadonly' => ''\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'gateway' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__DEF_GW',\n C__PROPERTY__INFO__DESCRIPTION => 'Default Gateway'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__isys_catg_ip_list__id'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__DEF_GW_V4',\n C__PROPERTY__UI__PARAMS => [\n 'p_arData' => new isys_callback(\n [\n 'isys_cmdb_dao_category_s_net',\n 'callback_property_gateway'\n ]\n )\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_gateway'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false\n ]\n ]\n ),\n 'range_from' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__ADDRESS_FROM',\n C__PROPERTY__INFO__DESCRIPTION => 'DHCP from'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__address_range_from'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__ADDRESS_RANGE_FROM'\n ]\n ]\n ),\n 'range_to' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__ADDRESS_TO',\n C__PROPERTY__INFO__DESCRIPTION => 'DHCP to'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__address_range_to'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__ADDRESS_RANGE_TO'\n ]\n ]\n ),\n 'dns_server' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__DNS_SERVER',\n C__PROPERTY__INFO__DESCRIPTION => 'DNS server'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_cats_net_list_2_isys_catg_ip_list',\n 'isys_cats_net_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__DNS_SERVER'\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'get_net_dns_server'\n ]\n ]\n ]\n ),\n 'dns_domain' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::multiselect(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__DNS_DOMAIN',\n C__PROPERTY__INFO__DESCRIPTION => 'Domain / DNS namespace'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__id',\n C__PROPERTY__DATA__TABLE_ALIAS => 'dns_domain',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_cats_net_list_2_isys_net_dns_domain',\n 'isys_cats_net_list__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__DNS_DOMAIN',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_net_dns_domain',\n 'placeholder' => _L('LC__CMDB__CATS__NET__DNS_DOMAIN'),\n 'emptyMessage' => _L('LC__CMDB__CATS__NET__NO_DNS_DOMAINS_FOUND'),\n 'p_onComplete' => \"idoit.callbackManager.triggerCallback('cmdb-cats-net-dns_domain-update', selected);\",\n 'multiselect' => true\n //'p_arData' => new isys_callback(array('isys_cmdb_dao_category_s_net', 'callback_property_dns_domain'))\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__LIST => false,\n C__PROPERTY__PROVIDES__VALIDATION => false,\n C__PROPERTY__PROVIDES__REPORT => false\n ],\n C__PROPERTY__CHECK => [\n C__PROPERTY__CHECK__MANDATORY => false,\n C__PROPERTY__CHECK__VALIDATION => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'dialog_multiselect'\n ]\n ]\n ]\n ),\n 'cidr_suffix' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__CIDR_SUFFIX',\n C__PROPERTY__INFO__DESCRIPTION => 'CIDR-Suffix'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__cidr_suffix'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__CIDR',\n C__PROPERTY__UI__PARAMS => [\n 'p_bReadonly' => '',\n 'p_strClass' => 'input input-mini'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false\n ]\n ]\n ),\n 'reverse_dns' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::text(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CATS__NET__REVERSE_DNS',\n C__PROPERTY__INFO__DESCRIPTION => 'Reverse dns'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__reverse_dns'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__REVERSE_DNS'\n ]\n ]\n ),\n 'layer2_assignments' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::object_browser(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET__LAYER2_NET',\n C__PROPERTY__INFO__DESCRIPTION => 'Layer-2-net assignments'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_obj__id'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__LAYER2',\n C__PROPERTY__UI__PARAMS => [\n isys_popup_browser_object_ng::C__TITLE => 'LC__BROWSER__TITLE__NET',\n isys_popup_browser_object_ng::C__MULTISELECTION => true,\n isys_popup_browser_object_ng::C__CAT_FILTER => 'C__CATS__LAYER2_NET'\n ]\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__SEARCH => false,\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__LIST => false\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'layer_2_assignments'\n ]\n ]\n ]\n ),\n 'address_v6' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::virtual(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATS__NET',\n C__PROPERTY__INFO__DESCRIPTION => 'Net v6'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATS__NET__NET_V6'\n ]\n ]\n ),\n 'description' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::commentary(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__LOGBOOK__DESCRIPTION',\n C__PROPERTY__INFO__DESCRIPTION => 'Description'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_cats_net_list__description'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CAT__COMMENTARY_' . C__CMDB__CATEGORY__TYPE_SPECIFIC . C__CATS__NET\n ]\n ]\n )\n ];\n }", "protected function properties()\n {\n return [\n 'formfactor' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog_plus(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR',\n C__PROPERTY__INFO__DESCRIPTION => 'Form factor'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__isys_catg_formfactor_type__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_catg_formfactor_type',\n 'isys_catg_formfactor_type__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_TYPE',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_catg_formfactor_type',\n 'p_strClass' => 'input-small'\n ]\n ]\n ]\n ),\n 'rackunits' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::int(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__RACKUNITS',\n C__PROPERTY__INFO__DESCRIPTION => 'Rack units'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__rackunits'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_RACKUNITS',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-mini'\n ]\n ]\n ]\n ),\n 'unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_DIMENSION_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'dimension unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__isys_depth_unit__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_depth_unit',\n 'isys_depth_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_DEPTH_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_depth_unit',\n 'p_strClass' => 'input-mini',\n 'p_bDbFieldNN' => 1\n ],\n C__PROPERTY__UI__DEFAULT => C__DEPTH_UNIT__INCH\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false\n ]\n ]\n ),\n 'width' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_WIDTH',\n C__PROPERTY__INFO__DESCRIPTION => 'Width'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__installation_width'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_WIDTH',\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['measure']\n ],\n C__PROPERTY__FORMAT__UNIT => 'unit'\n ]\n ]\n ),\n 'height' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_HEIGHT',\n C__PROPERTY__INFO__DESCRIPTION => 'Height'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__installation_height'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_HEIGHT',\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['measure']\n ],\n C__PROPERTY__FORMAT__UNIT => 'unit'\n ]\n ]\n ),\n 'depth' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_DEPTH',\n C__PROPERTY__INFO__DESCRIPTION => 'Depth'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__installation_depth'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_DEPTH',\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['measure']\n ],\n C__PROPERTY__FORMAT__UNIT => 'unit'\n ]\n ]\n ),\n 'weight' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::float(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_WEIGHT',\n C__PROPERTY__INFO__DESCRIPTION => 'Weight'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__installation_weight'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_WEIGHT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strClass' => 'input-dual-large'\n ]\n ],\n C__PROPERTY__FORMAT => [\n C__PROPERTY__FORMAT__CALLBACK => [\n 'isys_export_helper',\n 'convert',\n ['weight']\n ],\n C__PROPERTY__FORMAT__UNIT => 'weight_unit'\n ]\n ]\n ),\n 'weight_unit' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::dialog(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__CATG__FORMFACTOR_INSTALLATION_WEIGHT_UNIT',\n C__PROPERTY__INFO__DESCRIPTION => 'weight unit'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__isys_weight_unit__id',\n C__PROPERTY__DATA__REFERENCES => [\n 'isys_weight_unit',\n 'isys_weight_unit__id'\n ]\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CATG__FORMFACTOR_INSTALLATION_WEIGHT_UNIT',\n C__PROPERTY__UI__PARAMS => [\n 'p_strTable' => 'isys_weight_unit',\n 'p_strClass' => 'input-dual-small',\n 'p_bDbFieldNN' => 1,\n 'p_bInfoIconSpacer' => 0,\n ],\n C__PROPERTY__UI__DEFAULT => C__WEIGHT_UNIT__G,\n ],\n C__PROPERTY__PROVIDES => [\n C__PROPERTY__PROVIDES__REPORT => false,\n C__PROPERTY__PROVIDES__SEARCH => false\n ]\n ]\n ),\n 'description' => array_replace_recursive(\n isys_cmdb_dao_category_pattern::commentary(),\n [\n C__PROPERTY__INFO => [\n C__PROPERTY__INFO__TITLE => 'LC__CMDB__LOGBOOK__DESCRIPTION',\n C__PROPERTY__INFO__DESCRIPTION => 'Description'\n ],\n C__PROPERTY__DATA => [\n C__PROPERTY__DATA__FIELD => 'isys_catg_formfactor_list__description'\n ],\n C__PROPERTY__UI => [\n C__PROPERTY__UI__ID => 'C__CMDB__CAT__COMMENTARY_' . C__CMDB__CATEGORY__TYPE_GLOBAL . C__CATG__FORMFACTOR\n ]\n ]\n )\n ];\n }", "public function get_props() : array\n {\n return $this->additional['props'] ?? [];\n }", "function displayProperties ()\n {\n foreach ($this as $key => $property)\n {\n echo $key . ':' . $property . '<br>';\n }\n }", "public function get_actions(): array;", "protected function init_model_actions() {\n\t\treturn Arr::merge(parent::init_model_actions(), array(\n\t\t\t'popover_add',\n\t\t));\n\t}", "public static function getActions()\n\t{\n\t\t$result\t= new Obj;\n\n\t\t$actions = Access::getActionsFromFile(dirname(__DIR__) . DS . 'config' . DS . 'access.xml');\n\n\t\tforeach ($actions as $action)\n\t\t{\n\t\t\t$result->set($action->name, User::authorise($action->name, 'com_messages'));\n\t\t}\n\n\t\treturn $result;\n\t}", "abstract public function getRawAdditionalProperties();", "public function getUpdatedProperties() {}", "public function properties(){\n \t\treturn CMap::mergeArray(\n \t\t\tparent::properties(),\n \t\t\tarray(\n\t\t\t\t'inboundMessageID' => array('type' => 'string'),\n\t\t\t\t'sourceAddress' => array('type' => 'string'),\n\t\t\t\t'messageContent' => array('type' => 'string'),\n\t\t\t\t'externalTransactionID' => array('type' => 'string'),\n\t\t\t\t'status' => array('type' => 'string'),\n\t\t\t\t'dateCreated' => array('type' => 'string'),\n\t\t\t\t'dateModified' => array('type' => 'string'),\n \t\t\t)\n \t\t);\n \t}", "public function glitchDump(): iterable\n {\n yield 'properties' => [\n 'context' => $this->context,\n '*record' => $this->record\n ];\n }", "private function parseProperties(): void\n {\n $properties = $this->extractProperties();\n\n foreach ($properties as $property)\n {\n if ($property['docblock']===null)\n {\n $docId = null;\n }\n else\n {\n $docId = PhpAutoDoc::$dl->padDocblockInsertDocblock($property['docblock']['doc_line_start'],\n $property['docblock']['doc_line_end'],\n $property['docblock']['doc_docblock']);\n }\n\n PhpAutoDoc::$dl->padClassInsertProperty($this->clsId,\n $docId,\n $property['name'],\n Cast::toManInt($property['is_static']),\n $property['visibility'],\n $property['value'],\n $property['start'],\n $property['end']);\n }\n }", "function getProperties($properties);", "protected function resetProperties() {}", "public function attributes();", "public function convensionInit() {\n return [\n// 'Admin' => 'All',\n// 'Customer' => 'actionname',\n// 'Performer' => 'actionname2',\n// 'Guest' => 'actionname-toLogin actionname2-toLogin',\n ];\n }", "public function get(): array\n {\n return $this->actions->toArray();\n }", "public function getProperties(): array\n {\n return $this->getParam('properties');\n }", "public function getActions(){\r\n\t\t\r\n\t\t\treturn $this->_actions;\r\n\t\t}", "public static function getActions()\n\t{\n\t\tif (empty(self::$actions))\n\t\t{\n\t\t\tself::$actions = new Obj;\n\n\t\t\t$path = dirname(__DIR__) . '/config/access.xml';\n\n\t\t\t$actions = \\Hubzero\\Access\\Access::getActionsFromFile($path);\n\t\t\t$actions ?: array();\n\n\t\t\tforeach ($actions as $action)\n\t\t\t{\n\t\t\t\tself::$actions->set($action->name, User::authorise($action->name, 'com_members'));\n\t\t\t}\n\t\t}\n\n\t\treturn self::$actions;\n\t}", "public function get_properties()\r\n\t{\r\n\t\treturn get_object_vars($this);\r\n\t}", "public function testGetClassProperties() {\n\t\t$result = array_map(\n\t\t\tfunction($property) { return $property['name']; },\n\t\t\tInspector::properties($this)\n\t\t);\n\t\t$expected = ['test', 'test2'];\n\t\t$this->assertEqual($expected, $result);\n\n\t\t$result = array_map(\n\t\t\tfunction($property) { return $property['name']; },\n\t\t\tInspector::properties($this, ['public' => false])\n\t\t);\n\t\t$expected = ['test', 'test2', '_test'];\n\t\t$this->assertEqual($expected, $result);\n\n\t\t$result = Inspector::properties($this);\n\t\t$expected = [\n\t\t\t[\n\t\t\t\t'modifiers' => ['public'],\n\t\t\t\t'value' => 'foo',\n\t\t\t\t'docComment' => false,\n\t\t\t\t'name' => 'test'\n\t\t\t],\n\t\t\t[\n\t\t\t\t'modifiers' => ['public', 'static'],\n\t\t\t\t'value' => 'bar',\n\t\t\t\t'docComment' => false,\n\t\t\t\t'name' => 'test2'\n\t\t\t]\n\t\t];\n\t\t$this->assertEqual($expected, $result);\n\n\t\t$controller = new Controller(['init' => false]);\n\n\t\t$result = array_map(\n\t\t\tfunction($property) { return $property['name']; },\n\t\t\tInspector::properties($controller)\n\t\t);\n\t\t$this->assertTrue(in_array('request', $result));\n\t\t$this->assertTrue(in_array('response', $result));\n\t\t$this->assertFalse(in_array('_render', $result));\n\t\t$this->assertFalse(in_array('_classes', $result));\n\n\t\t$result = array_map(\n\t\t\tfunction($property) { return $property['name']; },\n\t\t\tInspector::properties($controller, ['public' => false])\n\t\t);\n\t\t$this->assertTrue(in_array('request', $result));\n\t\t$this->assertTrue(in_array('response', $result));\n\t\t$this->assertTrue(in_array('_render', $result));\n\t\t$this->assertTrue(in_array('_classes', $result));\n\n\t\t$this->assertNull(Inspector::properties('\\lithium\\core\\Foo'));\n\t}", "public Function getActions(){\n\t\treturn $this->actions;\n\t}", "public function getAllActionsAttribute()\n\t{\n\t\t$output = array();\n\t\t//check if model has default permissions. if so, lets add them.\n\t\tif($defaults = config('alpacajs.model-permissions.'. class_basename($this), false)){\n\t\t\t$output = $defaults;\n\t\t} \n\t\t//check if model exist, if it does then check if it has actions.\n\t\tif($this->exists && $modelActions = $this->actions)\n\t\t{\n\t\t\t$output = array_merge($output, $modelActions);\n\t\t}\n\t\t\n\t\treturn $output;\n\t}", "public function getFrontEndActions();", "private function setup_actions() {\n\n\t\tadd_action( 'init', array( $this, 'action_init' ) );\n\n\t\tadd_action( 'p2p_init', array( $this, 'action_p2p_init' ) );\n\n\t\tadd_action( 'pre_get_posts', array( $this, 'action_pre_get_posts' ) );\n\n\t\tadd_action( 'add_attachment', array( $this, 'action_add_attachment' ) );\n\n\t\tadd_action( 'wp_enqueue_scripts', array( $this, 'action_wp_enqueue_scripts' ) );\n\n\t}", "protected function get_available_actions()\n {\n }" ]
[ "0.8810592", "0.6445596", "0.644509", "0.6407183", "0.6366273", "0.62556255", "0.6227583", "0.6152637", "0.6152637", "0.6152637", "0.6152103", "0.61252975", "0.6114845", "0.6023548", "0.6023548", "0.6023548", "0.6023548", "0.6023548", "0.6023548", "0.5967956", "0.5967956", "0.5967956", "0.5967956", "0.59556246", "0.579391", "0.57799095", "0.5739634", "0.57269555", "0.57132727", "0.5673144", "0.5647511", "0.5635985", "0.5625272", "0.556747", "0.553021", "0.55135983", "0.5469734", "0.54637504", "0.5407361", "0.54009974", "0.54009974", "0.5398196", "0.53836274", "0.53836274", "0.5377852", "0.53594214", "0.535018", "0.53448844", "0.5344683", "0.53334", "0.5309681", "0.53012115", "0.530072", "0.53002435", "0.52952635", "0.52779025", "0.52779025", "0.5257244", "0.5251024", "0.5249395", "0.52483934", "0.5240373", "0.523918", "0.5217099", "0.5191934", "0.5191548", "0.51819116", "0.5170847", "0.51676446", "0.51622653", "0.5156826", "0.5155597", "0.51442605", "0.51433784", "0.5141386", "0.5133308", "0.51318765", "0.5118447", "0.51053965", "0.51041085", "0.5093461", "0.50832254", "0.5077605", "0.5068866", "0.50658613", "0.5065189", "0.50636464", "0.50581926", "0.50561035", "0.5043533", "0.50390786", "0.5033891", "0.5033495", "0.50243187", "0.5021612", "0.50213283", "0.50108504", "0.5005033", "0.5004727", "0.50005454" ]
0.70133436
1
Get readable ref ids
function getReadableRefIds($a_obj_id) { if (!isset($this->readable_ref_ids[$a_obj_id])) { $ref_ids = array(); foreach (ilObject::_getAllReferences($a_obj_id) as $ref_id) { if ($this->access->checkAccess("read", "", $ref_id)) { $ref_ids[] = $ref_id; } } $this->readable_ref_ids[$a_obj_id] = $ref_ids; } return $this->readable_ref_ids[$a_obj_id]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getReferenceIdsList(){\n return $this->_get(2);\n }", "public function getReferences();", "public function getReferencesList(){\n return $this->_get(1);\n }", "public function getIds();", "public function getIds();", "public function getDefinedObjectIds() {}", "public function getDefinedObjectIds() {}", "public function getDefinedObjectIds() {}", "public function getRefitListAttribute()\n {\n return $this->allrefits->pluck('id')->all();\n }", "public function getReferences() {\n $result = TingOpenformatMethods::parseFields($this->_getDetails(), array('references'));\n return (is_array($result)) ? reset($result) : $result;\n }", "public function getReferenceables() {\r\n\r\n $keyFields = array_keys($this->fields);\r\n\r\n $referenciables = array_intersect_key($keyFields, $this->indexReferences);\r\n\r\n $fields = array_flip($referenciables);\r\n\r\n\r\n return $fields;\r\n }", "public abstract function get_ids();", "public function getObjectIds();", "public function getCurrentlyReferencedEntityIds() {\n $ret = array();\n if (isset($this->entity) && isset($this->field)) {\n $entity_type = $this->entity_type;\n $field_name = $this->field['field_name'];\n $wrapper = entity_metadata_wrapper($entity_type, $this->entity);\n $ret = $wrapper->{$field_name}->raw();\n }\n\n return $ret;\n }", "public function getConsortialIDs()\n {\n return $this->getFieldArray('035', 'a', true);\n }", "public function getIds()\n {\n\n }", "public function getAllReferences()\n {\n\n return static::$references;\n\n }", "public function get_references()\n\t{\n\t\t$arr = array();\t// returned result\n\t\t$sql = \"SELECT * FROM refs WHERE issue_id = '{$this->id}'\";\n\t\t$this->db->execute_query($sql);\n\t\twhile($line = $this->db->fetch_line()) {\n\t\t\t$arr[] = $line;\n\t\t}\n\t\treturn $arr;\n\t}", "public function getIdentifiers();", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function get_ids()\n {\n }", "public function getAllIds(): array;", "public function getIds() {\n $sources = array();\n \n $sources[] = $this->id;\n \n foreach ($this->points as &$g) {\n $sources[] = $g->id;\n }\n foreach ($this->lines as &$g) {\n $sources[] = $g->id;\n }\n foreach ($this->polygons as &$g) {\n $sources[] = $g->id;\n }\n if ( !empty($this->address) ) {\n $sources[] = $this->address->id;\n }\n foreach ($this->relationships as &$r) {\n $sources[] = $r->id;\n }\n \n return array_filter($sources);\n }", "function taminoGetIds() {\n $rval = $this->tamino->xquery($this->xquery);\n if ($rval) { // tamino Error\n print \"<p>LinkCollection Error: failed to retrieve linkRecord id list.<br>\";\n print \"(Tamino error code $rval)</p>\";\n } else { \n // convert xml ids into a php array \n $this->ids = array();\n $this->xml_result = $this->tamino->xml->getBranches(\"ino:response/xq:result\");\n if ($this->xml_result) {\n\t// Cycle through all of the branches \n\tforeach ($this->xml_result as $branch) {\n\t if ($att = $branch->getTagAttribute(\"id\", \"xq:attribute\")) {\n\t array_push($this->ids, $att);\n\t }\n\t} /* end foreach */\n } \n }\n\n }", "function getReferences()\n\t{\n\t\tif ($nodes = $this->getElementsByTagname(\"LO\"))\n\t\t{\n\t\t\tforeach ($nodes as $node)\n\t\t\t{\n\t\t\t\t$attr[] = $node->get_attribute(\"id\");\n\t\t\t}\n\t\t}\n\n\t\treturn $attr;\n\t}", "public function getRefs() {\n return $this->entity_refs;\n }", "public function getAllIds();", "function getObjectIDs() {\n\t\t$tmp = array();\n\t\tif ( $this->getCount() > 0 ) {\n\t\t\tforeach ( $this as $oObject ) {\n\t\t\t\t$tmp[] = $oObject->getID();\n\t\t\t}\n\t\t}\n\t\treturn $tmp;\n\t}", "public function getReferences()\n {\n return $this->references;\n }", "public function getReferences()\n {\n return $this->references;\n }", "public function getReferences()\n {\n return $this->references;\n }", "public function hasReferenceIds(){\n return $this->_has(2);\n }", "public function getIds() {\n\t\treturn array_keys($this->registered);\n\t}", "public function ids()\n {\n return $this->_ids;\n }", "public function getReferenceIdentifier();", "public function getIds()\n\t{\n\t\treturn $this->ids;\n\t}", "public function getIds(): array\n {\n return $this->ids;\n }", "public function getIdsList() {\n return $this->_get(1);\n }", "public function getIds()\n {\n return $this->ids;\n }", "public function getIds()\n {\n return $this->ids;\n }", "public function getRefId()\n {\n return $this->refId;\n }", "public function getReferenceProperties() {}", "public function getResourceTypeIds();", "public function getUuids();", "public static function getIDProperties()\n {\n return static::$ids;\n }", "function getIds( array $Objects );", "public function getReferencingFields() {\n $refs = [];\n foreach ($this->fields as $field) {\n if ($field->getReferencedFields()) {\n foreach ($field->getReferencedFields() as $ref) {\n $refs[] = $ref;\n }\n }\n }\n return $refs;\n }", "public function scopeFetchIds()\n {\n return $this->pluck(\"id\");\n }", "public function getIdentifiers()\n {\n return $this->init()->_identifiers;\n }", "public function getAllIdentifiers() {}", "function getEventIDs() {\n\t\t$return = array();\n\n\t\tif ( $this->getCount() > 0 ) {\n\t\t\tforeach ( $this as $oObject ) {\n\t\t\t\t$return[] = $oObject->getID();\n\t\t\t}\n\t\t}\n\n\t\treturn $return;\n\t}", "public function getReverseEngineeringRelicIDs()\n {\n return $this->reverseEngineeredFromRelicIDs;\n }", "function reference_from_page($pages)\n{\n\tglobal $db;\n\t\n\t$references = array();\n\t\n\t$sql = 'SELECT * from rdmp_reference_page_joiner WHERE PageID IN (' . join(\",\", $pages) . ')';\n\n\t$result = $db->Execute($sql);\n\tif ($result == false) die(\"failed [\" . __FILE__ . \":\" . __LINE__ . \"]: \" . $sql);\n\t\n\twhile (!$result->EOF) \n\t{\n\t\t$references[$result->fields['PageID']] = $result->fields['reference_id'];\n\t\t$result->MoveNext();\t\t\t\t\n\t}\t\n\t\n\t$references = array_unique($references);\n\t\n\treturn $references;\n}", "public function getReferenceSetsList(){\n return $this->_get(1);\n }", "public static function getAllReference()\n {\n return self::with('profiles')->get()->pluck('profiles.0.name', 'user_id')->filter()->toArray();\n }", "public function sigLeadershipsIds()\n {\n return $this->sigs()->where('main', 1)->lists('id')->toArray();\n }", "public function getAllReferences()\n {\n $references = array();\n\n if ($this->headers->has('In-Reply-To')) {\n $references[] = $this->headers->get('In-Reply-To')->getFieldValue();\n }\n\n if ($this->headers->has('References')) {\n $values = explode(' ', $this->headers->get('References')->getFieldValue());\n $references = array_merge($references, $values);\n }\n\n return array_unique($references);\n }", "protected function getReferences()\n {\n $extensions = $this->extensionRepository->findByHasSphinxDocumentation();\n $references = array();\n foreach ($extensions as $extension) {\n $typeLabel = $this->translate('extensionType_' . $extension->getInstallType());\n $references[$typeLabel]['EXT:' . $extension->getExtensionKey()] = sprintf('[%2$s] %1$s', $extension->getTitle(), $extension->getExtensionKey());\n }\n\n $this->signalSlotDispatcher->dispatch(\n __CLASS__,\n 'afterInitializeReferences',\n array(\n 'references' => &$references,\n )\n );\n\n foreach (array_keys($references) as $key) {\n asort($references[$key]);\n }\n\n return $references;\n }", "public function getForeignReferList()\n\t{\n\t\treturn Yii::app()->db->createCommand()->select('code as key, printable_name as title')->from(self::tableName())->queryAll();\n\t}", "public function getIdentifiers()\n {\n return $this->identifiers;\n }", "public static function\tIdentifiers()\n {\n $accesses = array(self::TypePublic);\n\n if (Cache::Exist(\"user\") == false)\n\treturn $accesses;\n\n $user = Cache::Get(\"user\");\n\n $accesses[] = $user->id;\n\n foreach (self::$entities as $entity)\n\t{\n\t // XXX[we could perform theses operations in parallel to speed up the process]\n\t $access = call_user_func($entity . \"::Access\", $user->id);\n\n\t if (empty($access) == true)\n\t continue;\n\n\t foreach ($access as $object)\n\t $accesses[] = $object[\"id\"];\n\t}\n\n return $accesses;\n }", "public function identifier(): array;", "public function getReferrers()\n {\n if ($this->referrers === null) {\n $this->referrers = array();\n }\n\n return $this->referrers;\n }", "private function getReferencesFromIsolates(array $data) {\n $references = [];\n foreach ($data as $isolate) {\n $references[$isolate['Reference']] = true;\n }\n\n return array_keys($references);\n }", "public function listId()\n {\n return $this->contractor->all()->pluck('id')->all();\n }", "public function getArrayOfChildIdentifiersAttribute() : array\n {\n $idArray = [];\n\n foreach ($this->allChild->pluck('array_of_child_identifiers') as $array) {\n $idArray = array_merge($array, $idArray);\n }\n\n return array_merge($idArray, [$this->id]);\n }", "public function getFieldIds()\n {\n return $this->fieldIds;\n }", "public function getReferrers()\n {\n return $this->referrers;\n }", "public function getReferences()\n {\n if (is_null($this->references)) {\n /** @psalm-var ?list<stdClass> $data */\n $data = $this->raw(self::FIELD_REFERENCES);\n if (is_null($data)) {\n return null;\n }\n $this->references = ReferenceCollection::fromArray($data);\n }\n\n return $this->references;\n }", "public function getGeneratedIds() {}", "public function getClid() : array\n {\n\n return [ $this->parsed['class'], $this->parsed['id'] ];\n }", "public function getItemIds(){\n\t return $this->getIds();\n\t}", "public function getAll()\n {\n return $this->_identifiers;\n }", "public function getIdTokens()\n {\n return $this->idtokens;\n }", "public function getEventDefinitionReferences();", "public function getQueueableIds();", "public function get_member_ids() {\n return array_values($this->redscores);\n }", "public function get_refs( $req = array() ) {\n\t\t\t$refs = mycred_get_used_references( $this->args['ctype'] );\n\n\t\t\tforeach ( $refs as $i => $ref ) {\n\t\t\t\tif ( ! empty( $req ) && ! in_array( $ref, $req ) )\n\t\t\t\t\tunset( $refs[ $i ] );\n\t\t\t}\n\t\t\t$refs = array_values( $refs );\n\n\t\t\treturn apply_filters( 'mycred_log_get_refs', $refs );\n\t\t}", "private function reference(array $arguments): array {\n $references = [];\n foreach ($arguments as $id) {\n $references[] = new Reference($id);\n }\n return $references;\n }", "public function listReferences()\n {\n $schema = $this->fetchDatabase();\n\n $references = $this->fetchAll(\"SELECT\n kcu.referenced_table_name, \n kcu.referenced_column_name,\n kcu.table_name AS foreign_table_name, \n kcu.column_name AS foreign_column_name, \n kcu.constraint_name\n FROM\n information_schema.key_column_usage kcu\n WHERE\n kcu.referenced_table_name IS NOT NULL\n AND kcu.table_schema = '{$schema}'\n ORDER BY kcu.referenced_table_name, kcu.referenced_column_name\n \");\n\n $grouped = [];\n foreach ($references as $reference) {\n $grouped[$reference['referenced_table_name']][] = $reference;\n }\n\n return $grouped;\n }", "function getIDlist() {\n return array_keys($this->varList);\n }", "public function get_reserved_ids() {\n\t\t/**\n\t\t * Filters the array of reserved IDs considered when auto-generating IDs for\n\t\t * ToC sections.\n\t\t *\n\t\t * This is mostly for specifying markup IDs that may appear on the same page\n\t\t * as the ToC for which any ToC-generated IDs would conflict. In such\n\t\t * cases, the first instance of the ID on the page would be the target of\n\t\t * the ToC section permalink which is likely not the ToC section itself.\n\t\t *\n\t\t * By specifying these reserved IDs, any potential use of the IDs by the theme\n\t\t * can be accounted for by incrementing the auto-generated ID to avoid conflict.\n\t\t *\n\t\t * E.g. if the theme has `<div id=\"main\">`, a ToC with a section titled \"Main\"\n\t\t * would have a permalink that links to the div and not the ToC section.\n\t\t *\n\t\t * @param array $ids Array of IDs.\n\t\t */\n\t\treturn (array) apply_filters(\n\t\t\t'handbooks_reserved_ids',\n\t\t\t[\n\t\t\t\t'main', 'masthead', 'menu-header', 'page', 'primary', 'secondary', 'secondary-content', 'site-navigation',\n\t\t\t\t'wordpress-org', 'wp-toolbar', 'wpadminbar', 'wporg-footer', 'wporg-header'\n\t\t\t]\n\t\t);\n\t}", "public function getOrderReferences(): array\n {\n \\Logger::getLogger(\\get_class($this))\n ->info(__METHOD__.\" get '%s'\");\n return $this->orderReferences;\n }", "public static function bkap_get_resource_ids() {\n\t\t\n\t\t$all_resource_ids \t= array();\n\t\t$args \t\t\t\t= array('post_type' => 'bkap_resource','posts_per_page'=> -1,);\n\t\t$resources \t\t\t= get_posts( $args );\n\t\t\n\t\tif( count( $resources ) > 0 ){\n\t\t\tforeach ( $resources as $key => $value ) {\n\t\t\t\t$all_resource_ids[] = $value->ID;\n\t\t\t}\n\t\t}\n\t\treturn $all_resource_ids;\n\t}", "public static function officeIds()\n {\n return collect([\n AdminOffice::all()->first()->office_id,\n Auth::user()->office_id,\n ])->unique();\n }", "public function getIdManifest(): array\n {\n return $this->books->getIdDict();\n }", "public static function getResolveForeignIdFields();", "public function getRelatedIds()\n {\n $related = $this->getRelated ();\n $fullKey = $related->getQualifiedKeyName ();\n return $this->getQuery ()->select ( $fullKey )->lists ( $related->getKeyName () );\n }", "public function getUids()\n {\n return $this->map(\n function (RecordInterface $model) {\n return $model->getUid();\n }\n )->toArray();\n }", "private function getGroupsIds() : array {\n\t\treturn array_map(static function($a) {\n\t\t\treturn $a->getId();\n\t\t}, $this->groups);\n\t}", "public function getEditableLocaleIds(): array\n {\n Craft::$app->getDeprecator()->log('craft.i18n.getEditableLocaleIds()', 'craft.i18n.getEditableLocaleIds() has been deprecated. Use craft.app.i18n.editableLocaleIds instead.');\n\n return Craft::$app->getI18n()->getEditableLocaleIds();\n }", "public function cryptoIds()\n {\n $ticker = $this->ticker();\n\n return array_map(function($o) {\n return $o->id;\n }, $ticker);\n }", "public function getItemIds();", "public function getRoleIds() {\n\t \treturn array_map(\n \t\t\tfunction($role) {\n\t\t \t\treturn $role->getRoleid();\n\t\t \t},\n\t\t \t$this->getRoles()\n\t \t );\n\t }" ]
[ "0.7446031", "0.6592448", "0.65029806", "0.6434908", "0.6434908", "0.64225173", "0.64218223", "0.64218223", "0.634521", "0.63354915", "0.6313947", "0.6222172", "0.621776", "0.6198486", "0.61848336", "0.618409", "0.61287004", "0.6108813", "0.6063347", "0.60613656", "0.60613656", "0.60613656", "0.60613656", "0.60613656", "0.60613656", "0.60613656", "0.60613656", "0.5940688", "0.59398705", "0.59119296", "0.59089106", "0.59085065", "0.59032696", "0.5900851", "0.5838696", "0.5838696", "0.5838696", "0.5831541", "0.58289504", "0.58150476", "0.5800435", "0.5798375", "0.5754012", "0.57521355", "0.5745461", "0.5745461", "0.57409775", "0.5670542", "0.5668747", "0.5664667", "0.5662258", "0.56602", "0.56428176", "0.56377524", "0.56259966", "0.5600096", "0.5561988", "0.5551258", "0.5532855", "0.5530243", "0.5526344", "0.550989", "0.5500492", "0.5492367", "0.5481489", "0.54689884", "0.546346", "0.54502666", "0.5441434", "0.54402864", "0.5433461", "0.5427688", "0.541943", "0.54141706", "0.54120505", "0.5410379", "0.54086435", "0.5402963", "0.5397605", "0.538292", "0.53754467", "0.5355737", "0.5355662", "0.53466976", "0.533951", "0.5333459", "0.53233904", "0.5320962", "0.5320632", "0.5313904", "0.5307029", "0.5302092", "0.5299739", "0.52897984", "0.52875274", "0.52853197", "0.52847457", "0.5284223", "0.52743137", "0.52736896" ]
0.7715353
0
Get (linked if possible) user name
function getUserName($a_user_id, $a_force_name = false) { $type = ilObject::_lookupType((int) $_GET["ref_id"], true); $ctrl_path = array(); if ($type == "crs") { $ctrl_path[] = "ilobjcoursegui"; } if ($type == "grp") { $ctrl_path[] = "ilobjgroupgui"; } if (strtolower($_GET["baseClass"]) == "ilpersonaldesktopgui") { $ctrl_path[] = "ilpersonaldesktopgui"; } $ctrl_path[] = "ilCalendarPresentationGUI"; $ctrl_path[] = "ilpublicuserprofilegui"; return ilUserUtil::getNamePresentation( $a_user_id, false, true, $this->ctrl->getParentReturn($this), $a_force_name, false, true, false, $ctrl_path); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_user_name() {\n return $this->call('get_user_name', array(), TRUE);\n }", "public function getExternalUserName();", "public function getUserOrProperName()\n {\n $person = $this->getPerson();\n if (strtolower($person->getEmail()) != strtolower($this->username)) {\n return $this->username;\n } else {\n $init = substr($person->getFirstname(), 0, 1);\n return \"{$init}. {$person->getLastname()}\";\n }\n }", "function user_name () {\r\n\t$info = user_info();\r\n\treturn (isset($info[1]) ? $info[1] : 'default');\r\n}", "public function getUserDisplayName();", "public function get_user_name() { \n\n\t\tif ($this->user == '-1') { return _('All'); } \n\t\t\n\t\t$user = new User($this->user);\n\t\treturn $user->fullname . \" (\" . $user->username . \")\";\n\t\t\n\t}", "public function username() {\n if ($this->proxy_user)\n return $this->proxy_user;\n\n return '';\n }", "public function getUsername() : string\n {\n return explode(':', $this->uri->getUserInfo() ?: '')[0];\n }", "function user_name($user = false)\n{\n $user = $user ? $user : $GLOBALS['user'];\n\n // first check if the name is in the DB\n if ($info = user_info($user))\n return $info['name'];\n\n //no, it isn't. fetch it from the master server\n return master_user_name($user);\n}", "public function getUsername();", "public function getUsername();", "public function getUsername();", "public function getUsername();", "public function getUsername();", "public function name() {\n return isset($this->_adaptee->user_info['user_displayname']) ? $this->_adaptee->user_info['user_displayname'] : null;\n }", "public function getUserName() {\n if (isset($this->rUser)) {\n return $this->rUser->getFullName();\n }\n return '';\n }", "function getUserName() {\n\t\treturn $this->nickname;\n\t\t/*\n\t\tif(!$this->user_name) {\n\t\t\t$this->sql(\"SELECT nickname FROM \".UT_USE.\" WHERE id = \".$this->user_id);\n\t\t\t$this->user_name = $this->getQueryResult(0, \"nickname\");\n \t\t}\n\t\treturn $this->user_name;\n\t\t*/\n\t}", "public function getMemberName() {\n return Html::a( $this->user->username, Yii::$app->params['url_admin'].'/user/view?id='.$this->user->id );\n }", "public function getUserName()\n {\n return $this->user->name;\n }", "function getUserName() {\n return $this->userName . \".guest\";\n }", "public function getUsername() {}", "public function getNameOrUsername() {\n return $this->getName() ? : $this->username;\n }", "public function getUserName()\n {\n return $this->user_name;\n }", "public function getUserName();", "public function getUserNameIdentifier()\n {\n return $this->user_name;\n }", "final public function getUserName():string \n {\n return $this->userState->getUserName();\n }", "public function getNameOrUsername() {\n return $this->getName() ?: $this->username;\n }", "public static function getUserName($user_id);", "public function usualname()\n\t{\n\t\treturn coalesce(User::info('UsualName'), User::info('Username'));\n\t}", "function get_user_name()\n {\n return isset($_SESSION['username']) ? $_SESSION['username'] : null;\n }", "public function username(){\n \treturn $this->users->name.' '.$this->users->ape;\n }", "public function getUserName() : string\n {\n return $this->userName;\n }", "public function getUserName() : string\n {\n return $this->userName;\n }", "public function getUserName() {}", "function get_user_name() {\n\treturn isset($_SESSION['username']) ? $_SESSION['username'] : null;\n}", "public function getUsername(): string\n {\n return (string) $this->pseudo;\n }", "public function getUserName()\r\n {\r\n return $this->user->username;\r\n }", "public static function getNameIdentification() {\n global $advancedCustomUser;\n if (self::isLogged()) {\n if (!empty(self::getName()) && empty($advancedCustomUser->doNotIndentifyByName)) {\n return self::getName();\n }\n if (!empty(self::getMail()) && empty($advancedCustomUser->doNotIndentifyByEmail)) {\n return self::getMail();\n }\n if (!empty(self::getUserName()) && empty($advancedCustomUser->doNotIndentifyByUserName)) {\n return self::getUserName();\n }\n if (!empty(self::getUserChannelName())) {\n return self::getUserChannelName();\n }\n }\n return __(\"Unknown User\");\n }", "public function getUserName()\n {\n return $this->formattedData['username'];\n }", "public function getFullName()\n {\n if (! $this->_getVar('user_name')) {\n $name = ltrim($this->_getVar('user_first_name') . ' ') .\n ltrim($this->_getVar('user_surname_prefix') . ' ') .\n $this->_getVar('user_last_name');\n\n if (! $name) {\n // Use obfuscated login name\n $name = $this->getLoginName();\n $name = substr($name, 0, 3) . str_repeat('*', max(5, strlen($name) - 2));\n }\n\n $this->_setVar('user_name', $name);\n\n // \\MUtil_Echo::track($name);\n }\n\n return $this->_getVar('user_name');\n }", "public function getNameIdentificationBd() {\n global $advancedCustomUser;\n if (!empty($this->name) && empty($advancedCustomUser->doNotIndentifyByName)) {\n return $this->name;\n }\n if (!empty($this->email) && empty($advancedCustomUser->doNotIndentifyByEmail)) {\n return $this->email;\n }\n if (!empty($this->user) && empty($advancedCustomUser->doNotIndentifyByUserName)) {\n return $this->user;\n }\n if (!empty($this->channelName)) {\n return $this->channelName;\n }\n return __(\"Unknown User\");\n }", "Public Function getUserName()\n\t{\n\t\treturn $this->firstName . ' ' . $this->lastName;\n\t}", "public function getCurrentUserName()\n {\n $currentUserName = '';\n try {\n $loggedInUser = $this->getLoggedInUser();\n if ($loggedInUser) {\n $currentUserName = $loggedInUser['name'];\n }\n } catch (FamilyGraphException $ex) {\n // ignore error\n }\n \n return $currentUserName;\n }", "public function getUsername(): string\n {\n return (string) $this->nickname;\n }", "public function getUserName() {\n\t\tif(($username=$this->getState('__username'))!==null) return $username;\n\t\telse return NULL;\n\t}", "public function getName()\n {\n // Look for value only if not already set\n if (!isset($this->name)) {\n $us = SemanticScuttle_Service_Factory::get('User');\n $user = $us->getUser($this->id);\n $this->name = $user['name'];\n }\n return $this->name;\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->username;\n }", "public function getUsername()\n {\n return empty($this->username) ? 'anonymous' : $this->username;\n }", "public function getUsername(): string\n {\n return $this->username;\n }", "public function getUsername(): string\n {\n return $this->username;\n }", "public function getUsername(): string\n {\n return $this->username;\n }", "public function getUsername()\r\n\t{\r\n\t\treturn $this->admin['user'];\r\n\t}", "function getName(): string\n\t{\n\t\treturn $this->username;\n\t}", "public function getUsername()\n {\n return $this->getName();\n }", "public function name()\n\t{\n\t\treturn User::info('Username');\n\t}", "public function getUsername()\n {\n return $this->getUserIdentifier();\n }", "public function getUserName()\n {\n return $this->getUserAttribute(static::ATTRIBUTE_NAME);\n }", "function getUnameFromId( $userid = 0, $usereal = 0, $is_linked = 1 )\n {\t\t\n\t\tif (isset($this)) {\n\t\t\t$zariliaUser = &$this;\n\t\t} else {\n\t\t\tglobal $zariliaUser;\n\t\t}\t\t\n $name = '';\n $userid = intval( $userid ) > 0 ? intval( $userid ) : $zariliaUser->getVar( 'uid' );\n $usereal = intval( $usereal );\n if ( $userid > 0 ) {\n $member_handler = &zarilia_gethandler( 'member' );\n $user = &$member_handler->getUser( $userid );\n if ( is_object( $user ) ) {\n if ( $usereal ) {\n $name = htmlSpecialChars( $user->getVar( 'name' ), ENT_QUOTES );\n } else {\n $name = htmlSpecialChars( $user->getVar( 'uname' ), ENT_QUOTES );\n }\n }\n if ( $is_linked ) {\n $name = '<a href=\"' . ZAR_URL . '/index.php?page_type=userinfo&uid=' . $userid . '\">' . $name . '</a>';\n }\n } else {\n $name = $GLOBALS['zariliaConfig']['anonymous'];\n }\n return $name;\n }", "public function link() {\n return isset($this->_adaptee->user_info['user_username']) ? \"profile.php?user=\".$this->_adaptee->user_info['user_username'] : null;\n }", "public function getUserName()\n {\n return $this->getName();\n }", "public function getCurrentUsername(): string;", "public function getUserName() {\n\t\treturn ($this->userName);\n\t}", "public function getUsername()\n {\n return $this->getNickname();\n }", "public function getUsername(): string\n {\n return (string) $this->login;\n }", "public function getUsername(): string\n {\n return (string) $this->login;\n }", "public function getUsername(): string\n {\n return (string) $this->login;\n }", "public function getUsername(): string\n {\n return (string) $this->login;\n }", "public function getUsername()\n {\n return $this->get(self::_USERNAME);\n }", "public function getUserUsername () {\n\t\treturn ($this->userUsername);\n\t}", "public function getUsername(): string\n {\n return $this->getEmail();\n }", "function getUsername()\n\t{\n\t\treturn $this->Info['Username'];\n\t}", "public function getUsername(): string\n {\n return $this->getCorreo();\n }", "public function getUsername(): string {\n return $this->username;\n }", "public function username(): string\n\t{\n\t\treturn \"username\";\n\t}", "public function getUsername()\n {\n return $this->company_id.'+'.$this->username;\n }", "public function getUserName()\n {\n return substr($this->email, 0, strpos($this->email, '@'));\n }", "public function getUsername()\n {\n // TODO: Implement getUsername() method.\n }", "public function getUsername()\n {\n // TODO: Implement getUsername() method.\n }", "public function getUsername()\n {\n // TODO: Implement getUsername() method.\n }", "function getUserlink($id, $name = '')\n{\n\tif(!$name)\n\t\t$name = getUsername($id);\n\n\tif($name)\n\t\treturn makeLink($name, 'a=viewuserdetails&user=' . $id, SECTION_USER);\n\telse\n\t\treturn 'Guest';\n}", "public function getOwnerusername() {}", "public function getNameForDisplay()\n {\n if (null !== $this->getName() && '' !== $this->getName()) {\n return $this->getName();\n } elseif (1 == $this->getRealUserName()) {\n return $this->getUsername();\n }\n\n return $this->getEmail();\n }", "public function getuserName()\n {\n return $this->userName;\n }", "public function getUserName()\n {\n return $this->userName;\n }", "public function getUserName()\n {\n return $this->userName;\n }", "protected function user()\n {\n if ($this->wrappedObject->security) {\n return ' this user\\'s ';\n }\n\n $user = $this->wrappedObject->revisionable()->withTrashed()->first(['first_name', 'last_name']);\n\n return ' '.$user->first_name.' '.$user->last_name.'\\'s ';\n }", "public function getUsername(): string;", "public function getUserProfileName(): string {\n\t\treturn ($this->userProfileName);\n\t}", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }", "public function getUsername(): string\n {\n return (string) $this->username;\n }" ]
[ "0.78639", "0.78243506", "0.78040504", "0.7700495", "0.7644855", "0.7639059", "0.76065373", "0.7542634", "0.74925655", "0.7470896", "0.7470896", "0.7470896", "0.7470896", "0.7470896", "0.74382156", "0.74365723", "0.7368542", "0.73565876", "0.7355273", "0.73503554", "0.73415166", "0.73364115", "0.733411", "0.7322072", "0.7293969", "0.7292522", "0.7284034", "0.7275968", "0.72738224", "0.7270769", "0.7268375", "0.7267979", "0.7267979", "0.726612", "0.72521484", "0.7240101", "0.72141206", "0.72137684", "0.72117966", "0.7203376", "0.72011745", "0.7199458", "0.7188848", "0.71769905", "0.71759945", "0.71692556", "0.7163528", "0.7146215", "0.71402407", "0.71402407", "0.71402407", "0.71228755", "0.7118097", "0.7113379", "0.7112741", "0.710776", "0.7104984", "0.70919186", "0.70907307", "0.70884633", "0.7080528", "0.7077117", "0.70721453", "0.7072133", "0.7072133", "0.7072133", "0.7072133", "0.70691514", "0.7043718", "0.7042557", "0.70382464", "0.7034911", "0.7030971", "0.70261985", "0.7023602", "0.70210516", "0.70155907", "0.70155907", "0.70155907", "0.7014999", "0.70024276", "0.69991994", "0.6992532", "0.69894195", "0.69894195", "0.6988525", "0.6977125", "0.6975278", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387", "0.69715387" ]
0.0
-1
Download files from an appointment ( Modals )
function downloadFiles() { $appointment = $this->appointment; //calendar in the sidebar (marginal calendar) if(empty($appointment)) { $entry_id = (int)$_GET['app_id']; $entry = new ilCalendarEntry($entry_id); //if the entry exists if($entry->getStart()) { $appointment = array( "event" => $entry, "dstart" => $entry->getStart(), "dend" => $entry->getEnd(), "fullday" => $entry->isFullday() ); } else { ilUtil::sendFailure($this->lng->txt("obj_not_found"), true); $this->ctrl->returnToParent($this); } } include_once './Services/Calendar/classes/BackgroundTasks/class.ilDownloadFilesBackgroundTask.php'; $download_job = new ilDownloadFilesBackgroundTask($this->user->getId()); $download_job->setBucketTitle($this->lng->txt("cal_calendar_download")." ".$appointment['event']->getTitle()); $download_job->setEvents(array($appointment)); $download_job->run(); $this->ctrl->returnToParent($this); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function downloadFile();", "public function download()\n\t{\n\t\tR::selectDatabase('oxid');\n\t\t$files = $this->getFilesByName(Flight::request()->query->file);\n\t\tif (empty($files)) $this->redirect('/');\n\t\t$file = reset($files);\n\t\t$dwnloadDir = substr($file['OXSTOREHASH'], 0, 2);\n\t\t$dwnloadFile = Flight::get('oxid_dir_downloads').$dwnloadDir.'/'.$file['OXSTOREHASH'];\n\t\tif ( ! is_file($dwnloadFile)) $this->redirect('/');\n\t\t//error_log($dwnloadFile);\n\t\theader('Content-type: application/pdf');\n\t\theader('Content-Disposition: inline; filename=\"'.$file['OXFILENAME'].'\"');\n\t\t@readfile($dwnloadFile);\n\t}", "public function downloadAction(){\n //These are the files that are downloadable.\n $pathToDocs = RAIZ. \"/docs\";\n $param_to_file = array( \"milestone1\" => $pathToDocs . \"/milestone 1/group13-milestone1.pdf\",\n \"milestone2\" => $pathToDocs . \"/milestone 2/group13-milestone2.pdf\",\n \"milestone2-revision1\" => $pathToDocs . \"/milestone 2/group13-milestone2-comments.pdf\",\n \"milestone2-presentation\" => $pathToDocs . \"/milestone 2/group13-milestone2-presentation.pptx\");\n $file = $param_to_file[$this->_getParam('file')];\n //If we are being ask for a file that is not in the previous array, throw an Exception.\n if(is_null($file)){\n throw new Exception(\"Unknown file\");\n }\n //Disable view and layout\n $this->_helper->layout()->disableLayout();\n $this->_helper->viewRenderer->setNoRender(true);\n //The file is in the previous array. So, fetch it and force the download.\n if (file_exists($file) && is_file($file)) {\n header('Content-Description: File Transfer');\n header('Content-Type: application/octet-stream');\n header('Content-Disposition: attachment; filename='.basename($file));\n header('Content-Transfer-Encoding: binary');\n header('Expires: 0');\n header('Cache-Control: must-revalidate, post-check=0, pre-check=0');\n header('Pragma: public');\n header('Content-Length: ' . filesize($file));\n ob_clean();\n flush();\n readfile($file);\n exit;\n }else{\n echo \"<pre style='color:red'>The file does not exists</pre>\";\n } \n }", "public function download() {\n $this->autoRender = false;\n $filename = $this->request->params['pass'][3];\n $orgfilename = $this->request->params['pass'][4];\n// pr($this->request->params); exit;\n $this->response->file(\n 'webroot/uploads/post/files/' . $filename, array(\n 'download' => true,\n 'name' => $orgfilename\n )\n );\n// return $this->response;\n }", "public function downloadAction() {}", "public function download() {\t\t}", "function download()\n {\n $field = $this->GET('field');\n $id = $this->GET('id');\n $file = $this->table->data[$id][$field];\n header('Content-Type: ' . $this->_mime_content_type($file));\n header('Content-Length: ' . strlen($file));\n header('Content-Disposition: attachment; filename=\"' . $field . '_' . $id . '\";');\n echo $file;\n }", "public function actionDownloadApp($app_version = NULL)\n {\n if ($app_version) {\n $sql = 'SELECT * FROM app_update WHERE `version`=' . $app_version;\n $update_data = AppUpdate::findBySql($sql)->one()->toArray();\n Yii::$app->response->SendFile(str_replace('frontend', '', Yii::$app->basePath) . '/uploads/companies/' . $update_data['file_name']);\n Yii::$app->end();\n }\n }", "function download_activity_file($filename)\n\t{\n\t\t$this->http_set_content_type(NULL);\n\t\t$this->load_url(\"activities/$filename\", 'get');\n\t\treturn $this->http_response_body;\n\t}", "public function download()\n {\n $hashids = new Hashids(Configure::read('Security.salt'));\n $pk = $hashids->decode($this->request->query['i'])[0];\n $this->loadModel($this->request->query['m']);\n $data = $this->{$this->request->query['m']}->find('first', array(\n 'recursive' => -1,\n 'conditions' => array(\n \"{$this->request->query['m']}.\" . $this->{$this->request->query['m']}->primaryKey => $pk\n ),\n 'fields' => array(\n \"{$this->request->query['m']}.{$this->request->query['f']}\"\n )\n ));\n $file = json_decode($data[$this->request->query['m']][$this->request->query['f']], true);\n\n header('Content-length: ' . $file['size']);\n header('Content-type: ' . $file['type']);\n header('Content-Disposition: inline; filename=' . $file['name']);\n echo base64_decode($file['content']);\n\n die();\n }", "public function exportExcelAction()\n {\n $fileName = 'appointments.xml';\n $grid = $this->getLayout()->createBlock('appointments/adminhtml_appointments_grid');\n $this->_prepareDownloadResponse($fileName, $grid->getExcelFile($fileName));\n }", "public function download() {\n\t\theader('Content-Disposition: attachment; filename=\"' . basename($this->fileName) . '\"');\n\t\t$this->show();\n\t}", "public function download()\n {\n $encrypt = $this->services['encrypt'];\n $file_name = $encrypt->decode($this->getPost('id'));\n $type = $this->getPost('type');\n $storage = $this->services['backup']->setStoragePath($this->settings['working_directory']);\n if($type == 'files')\n {\n $file = $storage->getStorage()->getFileBackupNamePath($file_name);\n }\n else\n {\n $file = $storage->getStorage()->getDbBackupNamePath($file_name);\n }\n \n \n $backup_info = $this->services['backups']->setLocations($this->settings['storage_details'])->getBackupData($file);\n $download_file_path = false;\n if( !empty($backup_info['storage_locations']) && is_array($backup_info['storage_locations']) )\n {\n foreach($backup_info['storage_locations'] AS $storage_location)\n {\n if( $storage_location['obj']->canDownload() )\n {\n $download_file_path = $storage_location['obj']->getFilePath($backup_info['file_name'], $backup_info['backup_type']); //next, get file path\n break;\n }\n }\n }\n \n if($download_file_path && file_exists($download_file_path))\n {\n $this->services['files']->fileDownload($download_file_path);\n exit;\n }\n }", "public function Download(){\n\t\t\n\t\t\n\t}", "public function download_app_update() {\n \n // Download Update\n (new MidrubBaseAdminCollectionUpdateHelpers\\Apps)->download_update();\n \n }", "public function download() {\n $file_name = get('name');\n// return \\Response::download(temp_path($file_name));\n return \\Response::download(storage_path('app') . '/' . $file_name);\n }", "private function fileDownload()\n {\n /**\n * Defined variables\n */\n $configHelper = $this->dataHelper;\n $request = $this->getRequest();\n $ds = DIRECTORY_SEPARATOR;\n $baseDir = DirectoryList::VAR_DIR;\n $fileFactory = $this->fileFactory;\n $contentType = 'application/octet-stream';\n $paramNameRequest = $request->getParam('m');\n $packagePathDir = $configHelper->getConfigAbsoluteDir();\n\n $lastItem = $this->packageFilter();\n $versionPackageData = $lastItem;\n $file = $versionPackageData->getData('file');\n\n $packageName = str_replace('_', '/', $paramNameRequest);\n $correctPathFile = $packagePathDir . $ds . $packageName . $ds . $file;\n\n $fileName = $file;\n $content = file_get_contents($correctPathFile, true);\n $fileDownload = $fileFactory->create($fileName, $content, $baseDir, $contentType);\n\n return $fileDownload;\n }", "public function downloadAllEventPictures(){\n\t\treturn response()->download(public_path('pictures/events'));\n\t}", "public function sendPrroductDownloadToBrowser() {\n $transaction = getTransaction($_GET['id']);\n if ($transaction['status'] == \"valid\") {\n header(\"Content-Type: application/octet-stream\");\n header(\"Content-Transfer-Encoding: binary\");\n header(\"Content-Description: File Transfer\");\n if ($_GET[\"oto\"] && $transaction['oto']) {\n $fparts = explode(\"/\", $sys_oto_location);\n $filename = $fparts[count($fparts)-1];\n header(\"Content-Disposition: attachment; filename=$filename\");\n @readfile($sys_oto_location);\n } else {\n $fparts = explode(\"/\", $sys_item_location);\n $filename = $fparts[count($fparts)-1];\n header(\"Content-Disposition: attachment; filename=$filename\");\n @readfile($sys_item_location);\n }\n exit;\n } elseif ($transaction['status'] == \"expired\") {\n $filename = \"downloadexpired.html\";\n } else {\n $filename = \"invalid.html\";\n }\n showTemplate($filename);\n }", "function ciniki_events_web_fileDownload($ciniki, $tnid, $event_permalink, $file_permalink) {\n\n //\n // Get the tenant storage directory\n //\n ciniki_core_loadMethod($ciniki, 'ciniki', 'tenants', 'hooks', 'storageDir');\n $rc = ciniki_tenants_hooks_storageDir($ciniki, $tnid, array());\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n $tenant_storage_dir = $rc['storage_dir'];\n\n //\n // Get the file details\n //\n $strsql = \"SELECT ciniki_event_files.id, \"\n . \"ciniki_event_files.uuid, \"\n . \"ciniki_event_files.name, \"\n . \"ciniki_event_files.permalink, \"\n . \"ciniki_event_files.extension, \"\n . \"ciniki_event_files.binary_content \"\n . \"FROM ciniki_events, ciniki_event_files \"\n . \"WHERE ciniki_events.tnid = '\" . ciniki_core_dbQuote($ciniki, $tnid) . \"' \"\n . \"AND ciniki_events.permalink = '\" . ciniki_core_dbQuote($ciniki, $event_permalink) . \"' \"\n . \"AND ciniki_events.id = ciniki_event_files.event_id \"\n . \"AND (ciniki_events.flags&0x01) = 0x01 \"\n . \"AND ciniki_event_files.tnid = '\" . ciniki_core_dbQuote($ciniki, $tnid) . \"' \"\n . \"AND CONCAT_WS('.', ciniki_event_files.permalink, ciniki_event_files.extension) = '\" . ciniki_core_dbQuote($ciniki, $file_permalink) . \"' \"\n . \"AND (ciniki_event_files.webflags&0x01) = 0 \" // Make sure file is to be visible\n . \"\";\n $rc = ciniki_core_dbHashQuery($ciniki, $strsql, 'ciniki.events', 'file');\n if( $rc['stat'] != 'ok' ) {\n return $rc;\n }\n if( !isset($rc['file']) ) {\n return array('stat'=>'noexist', 'err'=>array('code'=>'ciniki.events.62', 'msg'=>'Unable to find requested file'));\n }\n $rc['file']['filename'] = $rc['file']['name'] . '.' . $rc['file']['extension'];\n\n //\n // Get the storage filename\n //\n $storage_filename = $tenant_storage_dir . '/ciniki.events/files/' . $rc['file']['uuid'][0] . '/' . $rc['file']['uuid'];\n if( file_exists($storage_filename) ) {\n $rc['file']['binary_content'] = file_get_contents($storage_filename); \n }\n\n return array('stat'=>'ok', 'file'=>$rc['file']);\n}", "public function downloadAction() {\r\n $file_id = $this->getRequest()->getParam('file_id');\r\n $chanelphoto = Engine_Api::_()->getItem('sesvideo_chanelphoto', $this->getRequest()->getParam('photo_id'));\r\n if (!$chanelphoto)\r\n return;\r\n $chanelphoto->download_count = $chanelphoto->download_count + 1;\r\n $chanelphoto->save();\r\n $file_id = $chanelphoto->file_id;\r\n if ($file_id == '' || intval($file_id) == 0)\r\n return;\r\n $storageTable = Engine_Api::_()->getDbTable('files', 'storage');\r\n $select = $storageTable->select()->from($storageTable->info('name'), array('storage_path', 'name'))->where('file_id = ?', $file_id);\r\n $storageData = $storageTable->fetchRow($select);\r\n $storageData = (object) $storageData->toArray();\r\n if (empty($storageData->name) || $storageData->name == '' || empty($storageData->storage_path) || $storageData->storage_path == '')\r\n return;\r\n //Get base path\r\n $basePath = APPLICATION_PATH . '/' . $storageData->storage_path;\r\n @chmod($basePath, 0777);\r\n header(\"Content-Disposition: attachment; filename=\" . urlencode(basename($storageData->name)), true);\r\n header(\"Content-Transfer-Encoding: Binary\", true);\r\n header(\"Content-Type: application/force-download\", true);\r\n header(\"Content-Type: application/octet-stream\", true);\r\n header(\"Content-Type: application/download\", true);\r\n header(\"Content-Description: File Transfer\", true);\r\n header(\"Content-Length: \" . filesize($basePath), true);\r\n readfile(\"$basePath\");\r\n exit();\r\n // for safety resason double check\r\n return;\r\n }", "public function downloadTask()\n\t{\n\t\t$filters = array(\n\t\t\t'event_id' => Request::getState(\n\t\t\t\t$this->_option . '.' . $this->_controller . '.event_id',\n\t\t\t\t'id',\n\t\t\t\tarray()\n\t\t\t),\n\t\t\t'search' => urldecode(Request::getState(\n\t\t\t\t$this->_option . '.' . $this->_controller . '.search',\n\t\t\t\t'search',\n\t\t\t\t''\n\t\t\t)),\n\t\t\t// Get sorting variables\n\t\t\t'sort' => Request::getState(\n\t\t\t\t$this->_option . '.' . $this->_controller . '.sort',\n\t\t\t\t'filter_order',\n\t\t\t\t'registered'\n\t\t\t),\n\t\t\t'sort_Dir' => Request::getState(\n\t\t\t\t$this->_option . '.' . $this->_controller . '.sortdir',\n\t\t\t\t'filter_order_Dir',\n\t\t\t\t'DESC'\n\t\t\t)\n\t\t);\n\n\t\t$query = Respondent::all();\n\n\t\tif ($filters['search'])\n\t\t{\n\t\t\t$query->whereLike('first_name', strtolower((string)$filters['search']), 1)\n\t\t\t\t->orWhereLike('last_name', strtolower((string)$filters['search']), 1)\n\t\t\t\t->resetDepth();\n\t\t}\n\n\t\tif ($filters['event_id'])\n\t\t{\n\t\t\tif (!is_array($filters['event_id']))\n\t\t\t{\n\t\t\t\t$filters['event_id'] = array($filters['event_id']);\n\t\t\t}\n\t\t\tif (!empty($filters['event_id']))\n\t\t\t{\n\t\t\t\t$query->whereIn('event_id', $filters['event_id']);\n\t\t\t}\n\t\t}\n\n\t\t$rows = $query\n\t\t\t->order($filters['sort'], $filters['sort_Dir'])\n\t\t\t->paginated('limitstart', 'limit')\n\t\t\t->rows();\n\n\t\tCsv::downloadlist($rows, $this->_option);\n\t}", "function downloadFile($data){\r\n\r\n $dao = new \\PNORD\\Model\\MaintenanceDAO($this->app); \r\n $info = $dao->getMaintenance($data); \r\n $this->app->log->info('****info **** -> '.$this->dumpRet($info));\r\n\r\n\r\n if (file_exists($info['FILES'])) {\r\n\r\n // header('Content-Description: File Transfer');\r\n header('Content-Type: application/zip');\r\n $name = split('maintenances/', $info['FILES']);\r\n $this->app->log->info('****name **** -> '.$this->dumpRet($name));\r\n $this->app->log->info('****info Files **** -> '.$this->dumpRet($info['FILES']));\r\n $this->app->log->info('****filesize(info[FILES]) **** -> '.$this->dumpRet(filesize($info['FILES'])));\r\n header('Content-Disposition: inline; filename='.basename($name[1]));\r\n header('Expires: 0');\r\n header('Cache-Control: must-revalidate');\r\n header('Pragma: public');\r\n header('Content-Length: ' . filesize($info['FILES']));\r\n ob_clean();\r\n flush();\r\n readfile($info['FILES']);\r\n exit;\r\n\r\n } \r\n\r\n }", "function executeDownload($e){\n $url = \"app/info/exportRequestHistory.php?account=\" . $this->account->intVal();\n $html = '<iframe src=\"'.$url.'\" width=\"1\" height=\"1\" style=\"position:absolute;visibility:hidden;\"></iframe>';\n $this->downloadFrame->html($html);\n $this->downloadFrame->updateClient();\n }", "function downloadDocumentAction()\n\t{\n\t\t$request = $this->_request->getParams();\n\t\t$this->_redirect(\"/BO/download-quote.php?type=\".$request['type'].\"&mission_id=\".$request['mission_id'].\"&index=\".$request['index'].\"&quote_id=\".$request['quote_id'].\"&logid=\".$request['logid'].\"&filename=\".$request['filename']);\n\t}", "public function downloadFile()\n {\n // Check for request forgeries.\n Session::checkToken('get') or jexit(Text::_('JINVALID_TOKEN'));\n\n $model = $this->getModel();\n $model->downloadFile();\n }", "public function download_file($id_cc){\n $file = $this->Dao_control_cambios_model->getFileCC($id_cc);\n\n $archivo = $file['archivo'];\n $nombre = $file['nombre_archivo'];\n $tipo = $file['tipo_archivo'];\n $extension = $file['extension_archivo'];\n\n header(\"Content-type: $tipo\");\n header('Content-disposition: attachment; filename=\"'.$nombre.'.docx\"');\n header(\"Content-disposition: attachment; filename='$nombre.$extension'\");\n // header(\"Content-Disposition: inline; filename=$nombre.pdf\");\n print_r($archivo);\n }", "function download_all_attachments($year, $month)\n {\n global $kids;\n global $absolute_destination_folder;\n global $lat, $lng;\n\n $exiftool_path = shell_exec('which exiftool');\n if(strlen($exiftool_path) == 0) {\n unset($exiftool_path);\n }\n\n $events = events($year, $month);\n $count = count($events);\n foreach($events as $i => $e) {\n if($e->type == 'Activity') {\n foreach($e->new_attachments as $a) {\n // Skip photos where our kids are not the primary child in the picture.\n if(!in_array($e->member_display, $kids)) {\n continue;\n }\n\n $description = $e->comment;\n $date = date('Y-m-d H.i.s', $e->event_time);\n\n // Parse Tadpoles' bizzare date format.\n // NOTE: They don't seem to be sending this strange format any longer. Leaving this here just in case.\n // $ts = explode('E', $e->create_time)[0];\n // $ts = str_replace('.', '', $ts);\n // $date = date('Y-m-d H.i.s', $ts);\n\n // Build the filename: \"folder/YYYY-mm-dd HH.mm.ss - Tadpoles - Kid Name.[jpg|mp4]\"\n $filename = $date . ' - Tadpoles - ' . $e->member_display;\n if($a->mime_type == 'image/jpeg') {\n $filename .= '.jpg';\n } else if($a->mime_type == 'video/mp4') {\n $filename .= '.mp4';\n }\n $filename = rtrim($absolute_destination_folder, '/') . '/' . $filename;\n\n echo \"# Downloading $i/$count: $filename\\n\";\n download_attachment($a->key, $filename);\n\n if(isset($exiftool_path)) {\n set_exif_date($filename);\n if(!empty($lat) && !empty($lng)) {\n set_exif_coords($filename, $lat, $lng);\n }\n if(!empty($description)) {\n set_exif_description($filename, $description);\n }\n }\n\n // Set the file's modification date to match date taken for good measure.\n touch($filename, strtotime($date));\n }\n }\n }\n }", "function httpdownload($product_id) {\n \n \t //extra security set form must be filled as session param\n\t //to prevent cmd instant download without it.\n\t if (GetSessionParam('FORMSUBMITED')) {//&&\n\t //(GetGlobal('controller')->calldpc_method('httpdownload.get_filename'))) {\t \n\n $file = $this->wherethefileis . $product_id . $this->file_epithema . $this->ftype;\t \n\t $title = $this->get_product_info($product_id);\t\t \n \n \n if ($this->download_link) { \n //$d = new httpdownload($file);\n\t //$ret = $d->select_download_type();\t \n\t\t //$ret = GetGlobal('controller')->calldpc_method('httpdownload.select_download_type');\n\t\t $ret = GetGlobal('controller')->calldpc_method('httpdownload.set_download use NRSPEED');\n\t\t //infoem by mail and sms\n\t\t $this->send_downloaded_mail($product_id);\n\t }\n\t else\n\t $ret = \"ERROR:file not exist!\";\t \n\t \n\t $w = new window($title. \" SHAREWARE EDITION\",\"<h2>\".$ret.\"</h2>\");//$link);\n\t $out = $w->render();\n\t unset($w);\t\n\t }\n\t else\n\t $out = \"Prohibited area!\"; \n\t \n\t return ($out);\n }", "function downloadfolder($fd)\r\n{\r\n $this->get_files_from_folder($fd,'');\r\n header(\"Content-Disposition: attachment; filename=\" .$this->cs(basename($fd)).\"-\".\".zip\"); \r\n header(\"Content-Type: application/download\");\r\n header(\"Content-Length: \" . strlen($this -> file()));\r\n flush();\r\n echo $this -> file(); \r\n exit();\r\n}", "function instant_download($product_id, $ftype=null) {\n \n if (!$filetype = GetReq('filetype'))\n $filetype = $ftype ? $ftype : $this->ftype;\n \n \t //extra security set form must be filled as session param\n\t //to prevent cmd instant download without it.\n\t if ((GetSessionParam('FORMSUBMITED')) || GetSessionParam(\"CODESUBMITED\")) {\t \n \n $file = $this->wherethefileis . $product_id . $this->file_epithema . $filetype;\t \n\t //$file = \"c:\\\\php\\\\webos2\\\\projects\\\\re-coding-official\\\\demo\\\\delphi2java_shareware.zip\";\n\t //echo \"DOWNLOAD:\",$file;\n\t //die();\n $downloadfile = new DOWNLOADFILE($file);\n\t \n /*$this->tell_by_mail(\"demo file downloaded\",\n\t '[email protected]',\n\t\t '[email protected]',\n\t\t\t\t\t\t $file);\t\n\t\t\t\t\t\t \n $this->tell_by_sms(\"$product_id demo file downloaded.\");*/\t\n\t\t \n\t //inform bt mail and sms\n\t $this->send_downloaded_mail($product_id);\t\t\t\t\t \n\t \n if (!$downloadfile->df_download()) {\n\t //echo \"Sorry, we are experiencing technical difficulties downloading this file. Please report this error to Technical Support.\";\t \t \n\t\t$m = paramload('RCDOWNLOAD','error');\t\n\t\t$ff = $this->prpath.$m;\n\t\tif (is_file($ff)) {\n\t\t $ret = file_get_contents($ff);\n\t\t}\n\t\telse\n\t\t $ret = $m; //plain text\t\t \n\t }\n\t //else\n\t // $ret = \"OK\";\t\n\t }\n\t else\n\t $ret = \"Prohibited area!\"; \n\t\t \t \n\t return ($ret);\n\t \n\t \n\t //use download2.lib\n\t //$dFile = new Download_file($this->prpath . paramload('RCDOWNLOAD','dirsource') , $product_id . $this->ftype);\n }", "private function downloadFileAction($os)\n {\n $basePath = $this->container->getParameter('kernel.root_dir').'/Resources/my_custom_folder';\n $dir = \"../../builds/quota\";\n $handle = fopen(\"$dir/index.txt\", \"r\");\n if ($handle) {\n $version=\"0.0.0\";\n $link=\"\";\n while (($line = fgets($handle)) !== false) {\n $s=explode('#',$line);\n if(version_compare($s[0],$version)==1){\n $link=$s[1];\n $version=$s[0];\n }\n }\n\n fclose($handle);\n } else {\n // error opening the file.\n }\n\n $a=explode(\"/\",$link);\n $filename = trim(end($a));\n $filePath=\"$dir/$filename\";\n // check if file exists\n $fs = new FileSystem();\n if (!$fs->exists($filePath)) {\n throw $this->createNotFoundException();\n }\n $filename=\"Quota_Setup_$os.exe\";\n // prepare BinaryFileResponse\n $response = new BinaryFileResponse($filePath);\n $response->trustXSendfileTypeHeader();\n $response->setContentDisposition(\n ResponseHeaderBag::DISPOSITION_INLINE,\n $filename,\n iconv('UTF-8', 'ASCII//TRANSLIT', $filename)\n );\n\n return $response;\n }", "public function actionDownloadedit() {\n\n $model = $this->loadModel();\n if (isset($_POST['file_index'])) { //download file from file_bytes \t\t\n CActiveForm::validate($model);\n /**\n *\n */\n $model->validate();\n /**\n *\n */\n $attachment_id = $_POST['file_index'];\n /**\n *\n */\n if ($attachment_id == '1') {\n $file_name = $model->attachment1_file_name;\n $file_type = $model->attachment1_file_type;\n $content = base64_decode($model->attachment1_file_bytes);\n } else if ($attachment_id == '2') {\n $file_name = $model->attachment2_file_name;\n $file_type = $model->attachment2_file_type;\n $content = base64_decode($model->attachment2_file_bytes);\n } else if ($attachment_id == '3') {\n $file_name = $model->attachment3_file_name;\n $file_type = $model->attachment3_file_type;\n $content = base64_decode($model->attachment3_file_bytes);\n }\n /**\n *\n */\n header('Content-Type: ' . $file_type);\n header('Content-Disposition: attachment;filename=\"' . $file_name . '\"');\n header('Cache-Control: max-age=0');\n echo $content;\n } else {\n //download file from host\n $attachment_id = 0;\n if (isset($_GET['1'])) {\n $attachment_id = 1;\n } else if (isset($_GET['2'])) {\n $attachment_id = 2;\n } else if (isset($_GET['3'])) {\n $attachment_id = 3;\n }\n if ($attachment_id != 0) {\n $file_name = Yii::app()->db->createCommand()\n ->select('attachment' . $attachment_id)\n ->from('hobby_new')\n ->where('id=:id', array('id' => $_GET['id']))\n ->queryScalar();\n if ($file_name != \"\" && file_exists(Yii::getPathOfAlias('webroot') . $file_name)) {\n Yii::import('ext.helpers.EDownloadHelper');\n EDownloadHelper::download(Yii::getPathOfAlias('webroot') . $file_name);\n }\n }\n }\n exit;\n }", "public function getLink() {\r\n\r\n\t\t// init vars\r\n\t\t$download_mode = $this->config->get('download_mode');\r\n\r\n\t\t// create download link\r\n\t\t$query = array('task' => 'callelement', 'format' => 'raw', 'item_id' => $this->_item->id, 'element' => $this->identifier, 'method' => 'download');\r\n\r\n\t\tif ($download_mode == 1) {\r\n\t\t\treturn $this->app->link($query);\r\n\t\t} else if ($download_mode == 2) {\r\n\t\t\t$query['args[0]'] = $this->filecheck();\r\n\t\t\treturn $this->app->link($query);\r\n\t\t} else {\r\n\t\t\treturn $this->get('file');\r\n\t\t}\r\n\r\n\t}", "function downloadFile($folder,$fielname) {\n\t\t$this->autoLayout = false;\n\t\t$newFileName = $fielname;\n\t\t$folder = str_replace('-','/',$folder);\n\t\t//Replace - to / to view subfolder\n\t $path = WWW_ROOT.$folder.'/'.$fielname;\n\t\tif(file_exists($path) && is_file($path)) {\t\n\t\t\t$mimeContentType = 'application/octet-stream';\n\t\t\t$temMimeContentType = $this->_getMimeType($path); \n\t\t\tif(isset($temMimeContentType) && !empty($temMimeContentType))\t{ \n\t\t\t\t\t\t\t$mimeContentType = $temMimeContentType;\n\t\t\t}\n\t\n\t\t\t// START ANDR SILVA DOWNLOAD CODE\n\t\t\t// required for IE, otherwise Content-disposition is ignored\n\t\t\tif(ini_get('zlib.output_compression'))\n\t\t\t \tini_set('zlib.output_compression', 'Off');\n\t\t\theader(\"Pragma: public\"); // required\n\t\t\theader(\"Expires: 0\");\n\t\t\theader(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n\t\t\theader(\"Cache-Control: private\",false); // required for certain browsers\n\t\t\theader(\"Content-Type: \" . $mimeContentType );\n\t\t\t// change, added quotes to allow spaces in filenames, by Rajkumar Singh\n\t\t\theader(\"Content-Disposition: attachment; filename=\\\"\".(is_null($newFileName)?basename($path):$newFileName).\"\\\";\" );\n\t\t\theader(\"Content-Transfer-Encoding: binary\");\n\t\t\theader(\"Content-Length: \".filesize($path));\n\t\t\treadfile($path);\n\t\t\texit();\n\t\t\t// END ANDR SILVA DOWNLOAD CODE\n\t\t }\n\t\t if(isset($_SERVER['HTTP_REFERER'])) {\n\t\t \t $this->Session->setFlash('File not found.');\n\t\t\t $this->redirect($_SERVER['HTTP_REFERER']);\n\t\t }\n \t}", "public function download(): void\n\t{\n\t\t/** @var ExtensionModel $model */\n\t\t$model = $this->getModel();\n\t\t$id = $this->input->getInt('id');\n\t\t$fileDetails = $model->getFilename($id);\n\n\t\tif (!file_exists($fileDetails->file))\n\t\t{\n\t\t\tthrow new InvalidArgumentException(Text::sprintf('COM_JED_EXTENSIONS_DOWNLOAD_NOT_FOUND',\n\t\t\t\t$fileDetails->file));\n\t\t}\n\n\t\theader('Content-type: application/zip');\n\t\theader('Content-Disposition: attachment; filename=' . $fileDetails->originalFile);\n\t\theader('Content-length: ' . filesize($fileDetails->file));\n\t\theader('Pragma: no-cache');\n\t\theader('Expires: 0');\n\t\treadfile($fileDetails->file);\n\n\t\tFactory::getApplication()->close();\n\t}", "public function actionDownload($id){\n $model = $this->findModel($id);\n $file = $model->file_surat;\n $path = Yii::getAlias('@webroot').'/'.$file;\n if(file_exists($path)){\n Yii::$app->response->sendFile($path);\n }else{\n $this->render('download404');\n }\n }", "public function downloadMaterialAction()\n {\n $codigo = $this->_getParam('codigo');\n $anexo = $this->getService('AnexoArtefatoVinculo')->find($codigo);\n $path = explode('/',$anexo->getDeCaminhoAnexo());\n $registry = \\Zend_Registry::get('configs');\n $options = array('path' => $registry['upload']['material']);\n $file = \"{$path['4']}\";\n $this->_helper->download($file, $options);\n }", "public function download($id) {\n\t\tif (!$this->request->is('post')) {\n\t\t\tthrow new MethodNotAllowedException();\n\t\t}\n\t\tConfigure::write('debug', 0);\n\t\t$file = $this->Resource->findById($id);\n\t\t\n\t\t//header('Content-type: ' . $file['MyFile']['type']);\n//\t\theader('Content-length: ' . $file['MyFile']['size']); // some people reported problems with this line (see the comments), \t\t\tcommenting out this line helped in those cases\n\t\theader('Content-Disposition: attachment; filename=\"'.$file['Resource']['title'].'\"');\n\t\techo $file['Resource']['data'];\n\t\t\t\n\t\texit();\n}", "public function download($id);", "public function download()\n\t{\n\t\t$sfUsers = sfCore::getClass('sfUsers');\n\t\tif($this->auth_requirement != 0)\n\t\t{\n\t\t\tif($sfUsers::translateAuthLevelString($sfUsers::getUserAuthLevel()) < $this->auth_requirement)\n\t\t\t{\n\t\t\t\tthrow new sfAuthorizationException();\n\t\t\t}\n\t\t}\n\n\t\t$update = sfCore::db->query(\"UPDATE `swoosh_file_storage` SET `downloads` = `downloads`+1 WHERE `id` = '%i' LIMIT 1;\",\n\t\t\t$this->id);\n\t\tfSession::close();\n\t\t$this->fFile->output(true, true);\n\t}", "public function actionDownloadBackupFile()\n\t{\n\t\t$fileName = craft()->request->getRequiredQuery('fileName');\n\n\t\tif (($filePath = IOHelper::fileExists(craft()->path->getTempPath().$fileName.'.zip')) == true)\n\t\t{\n\t\t\tcraft()->request->sendFile(IOHelper::getFileName($filePath), IOHelper::getFileContents($filePath), array('forceDownload' => true));\n\t\t}\n\t}", "function download($filename){\n\t\t$this->downloadFile('files/pdf/',$filename);\n\t}", "function download($file = \"\") {\n\t\t// Set maximum execution time in seconds (0 means no limit).\n\n\t\tset_time_limit(0);\n\t\t\n\t\t// Check downloader is admin or manager\n\t\tif(!empty($file)) {\n\t\t\t$file = SITE_DIR.\"public\".base64_decode($file);\n\n\t\t\t$this->output_file($file);\n\t\t} else\n\t\t\t$this->download_forbidden();\n\t\texit;\n\t}", "function download_suket_018_perempuan()\n\t{\n\t\tforce_download('assets/uploads/warga/suket_018/template_surat_pengantar_nikah_perempuan.docx', NULL);\n\t}", "function download($id){\r\n\t\t\r\n\t\t$id = Sanitize::escape($id);\r\n\t\t//$this->Version->unbind();\r\n\t\t$archivo = $this->Version->findById($id);\r\n\t\t$archivo_id = $archivo['Archivo']['id'];\r\n\t\t\r\n\t\t#Permitir la descarga del archivo si tiene los permisos\r\n\t\tif(!$this->Archivo->verificarPermiso($archivo_id, $this->Session->read('usuario_id'), 'read', $this->Session->read('alias')) ){\r\n\t\t\t$this->flash(\"Existio un error no es posible descargar el Archivo\", \"/categorias/index\");\r\n\t\t}else{\r\n\t\t\t$f = new File($archivo['Version']['nombre']);\r\n\t\t\theader('Content-type: ' . $archivo['Archivo']['type']);\r\n\t\t\theader('Content-length: ' . $archivo['Version']['size']);\r\n\t\t\theader('Content-Disposition: attachment; filename=\"'.$archivo['Archivo']['nombre'].'\"');\r\n\t\t\techo $f->read();\r\n\t\t\tConfigure::write('debug',0);\r\n\t\t\texit(0);\r\n\t\t}\r\n\t}", "public function downloadAction()\n {\n $url = $this->getRequest()->REQUEST_URI;\n $url = str_replace('/stream/download/', '/', '../data/uploads/images' . $url);\n $this->download($url, null, 'application/jpg');\n $this->view->message = \"Download erfolgreich.\";\n }", "public function getDownload($fileimgname)\n {\n \n // $dl= Jobfiles::find($fileimgname);\n \n \n\n // return Storage::download($dl->path,$dl->title);\n return response()->download(public_path('/uploads/Files/'.$fileimgname));\n // return response()->download(public_path('/uploads/Files/', $fileimgname, $headers));\n \n }", "public function downloadApp()\n {\n $pathToFile = storage_path('static/iipzs-release.apk');\n return Response::download($pathToFile);\n }", "protected function downloadFiles() {\n\t\t// Metadata.\n\t\t$metadataFile = $this->jobDir() . '/metadata.json';\n\t\tif ( !file_exists( $metadataFile ) ) {\n\t\t\t$this->log->info( \"Saving IA metadata to $metadataFile\" );\n\t\t\t$metadata = $this->iaClient->fileDetails( $this->itemId );\n\t\t\tfile_put_contents( $metadataFile, \\GuzzleHttp\\json_encode( $metadata ) );\n\t\t}\n\t\tif ( !isset( $metadata ) ) {\n\t\t\t$metadata = \\GuzzleHttp\\json_decode( file_get_contents( $metadataFile ), true );\n\t\t}\n\n\t\t// Other files (JP2 and DjVu XML).\n\t\t$filesToDownload = preg_grep( '/.*(_djvu.xml|_jp2.zip)/', array_keys( $metadata['files'] ) );\n\t\tforeach ( $filesToDownload as $file ) {\n\t\t\tif ( !file_exists( $this->jobDir() . $file ) ) {\n\t\t\t\t$this->log->info( \"Downloading $this->itemId$file\" );\n\t\t\t\t$this->iaClient->downloadFile( $this->itemId . $file, $this->jobDir() . $file );\n\t\t\t}\n\t\t}\n\t}", "public function downloadEmolumentTemplate(){\n\n $financialYear = FinancialYear::where('status', '=', true)->first();\n $items = RefEmolument::all();\n $headers = array(\n \"Content-type\"=>\"application/ms-excel\",\n \"Content-Disposition\"=>\"attachment;Filename= Personal_Emolument_Template.xls\"\n );\n\n $content = View::make('personal_emoluments/htmlViews/emolument_template', array('items' => $items, 'financialYear' => $financialYear->year));\n return Response::make($content, 200, $headers);\n }", "function download_suket_018_janda()\n\t{\n\t\tforce_download('assets/uploads/warga/suket_018/template_surat_pengantar_nikah_janda.docx', NULL);\n\t}", "public function download(){\n\t\t$lang = \"En\";\n\t\tif (isset ( $_SESSION [\"user_settings\"] [\"language\"] )) {\n\t\t\t$lang = $_SESSION [\"user_settings\"] [\"language\"];\n\t\t}\n\t\t\n\t\t// get form posts\n\t\t$localurl = $this->request->getParameter(\"localurl\");\n\t\t$filename = $this->request->getParameter(\"filename\");\n\t\t\n\t\t// get the user login\n\t\t$idUser = $_SESSION[\"id_user\"];\n\t\t$modelUser = new User();\n\t\t$userlogin = $modelUser->userLogin($idUser);\n\t\t\n\t\t// parse the files names\n\t\t$filename = str_replace(\"__--__\", \".\", $filename);\n\t\t$filename = str_replace(\"__---__\", \" \", $filename);\n\t\t$filename = str_replace(\"__----__\", \"/\", $filename);\n\t\t$localurl = str_replace(\"\\\\\", \"/\" , $localurl) . \"/\" . basename($filename);\n\t\t$fileName = \"./\" . $userlogin .\"/\".basename($filename);\n\t\t\n\t\t// refuse to download if the quotas is over\n\t\t$modelQuotas = new StUserQuota();\n\t\t$userQuotas = $modelQuotas->getQuota($idUser); // in GB\n\t\t$modelUploader = new StUploader();\n\t\t$usage = $modelUploader->getUsage($userlogin);\n\t\t$usage = $usage/1000000000; \n\t\t\n\t\tif ($usage >= $userQuotas){\n\t\t\t$this->index( StTranslator::QuotasHoverMessage($lang) . $localurl);\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// download\n\t\t$modelFiles = new StUploader();\n\t\t$modelFiles->downloadFile($localurl, $fileName);\n\t\t\n\t\t\n\t\t// view\n\t\t$this->index( StTranslator::DownloadMessage($lang) . $localurl);\n\t\treturn;\n\t}", "public function sendResponse(){\n\t\theader( 'Content-Type:' . $this->getMimeType() );\n\t\t\n\t\t$encodedName = rawurlencode($this->getFilename());\n\t\tif (preg_match(\"/MSIE/\", $_SERVER[\"HTTP_USER_AGENT\"])){\n\t\t\theader(\n\t\t\t\t\t'Content-Disposition: attachment; filepath=\"' . $encodedName . '\"'\n\t\t\t\t\t);\n\t\t} else {\n\t\t\theader('Content-Disposition: attachment; filepath*=UTF-8\\'\\'' . $encodedName\n\t\t\t\t\t. '; filepath=\"' . $encodedName . '\"');\n\t\t}\n\t\t\n\t\theader('Content-Length: ' . $this->view->filesize($this->filepath));\n\n\t\t\\OC_Util::obEnd();\n\t\t $this->view->readfile($this->filepath);\n\t}", "public function download()\n {\n header('Content-Description: File Transfer');\n header('Content-Type: application/octet-stream');\n header('Content-Disposition: attachment; filename=' . $this->getFilename());\n header('Content-Transfer-Encoding: binary');\n header('Expires: 0');\n header('Cache-Control: must-revalidate, post-check=0, pre-check=0');\n header('Pragma: public');\n header('Content-Length: ' . $this->getSize());\n \\Oka\\Web\\Buffer::Clean();\n\n $this->read();\n exit;\n }", "public function DownoadFile()\r\n\t{\r\n\t\theader(\"download.php?key=\".$this->secretKey);\r\n\t}", "public function downloadFile()\n {\n $file= public_path(). \"/images/MRS_OLUREMI_ABIMBOLA_NEW ++.pdf\";\n \n $headers = array(\n 'Content-Type: application/pdf',\n );\n \n return \\Response::download($file, 'funeral_for_mrs_oluremilekun_abimbola.pdf', $headers);\n }", "function download() {\r\n $this->zip->read_dir('./uploads/',FALSE);\r\n // create zip file on server\r\n $this->zip->archive('./downloads/'.'images.zip');\r\n // prompt user to download the zip file\r\n $this->zip->download('images.zip');\r\n }", "public function get_download($id){\n\n\t\t$data = Media::find($id);\n\n\t\treturn Response::download('public/'.$data->original, $data->name);\n\t}", "function emc_download() {\r\n\r\n\tif ( ! class_exists( 'Acf', false ) ) return false;\r\n\r\n\t$html = '';\r\n\tif ( get_field( 'download_files' ) ) {\r\n\r\n\t\twhile ( has_sub_field( 'download_files' ) ) {\r\n\r\n\t\t\t$download = get_sub_field( 'download_file' );\r\n\r\n\t\t\t// Determine icon\r\n\t\t\t$mime = get_post_mime_type( $download[ 'id' ] );\r\n\t\t\tswitch ( $mime ) {\r\n\t\t\t\tcase 'application/pdf':\r\n\t\t\t\t\t$icon = get_stylesheet_directory_uri() . '/img/' . 'pdf.png';\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase 'application/msword':\r\n\t\t\t\t\t$icon = get_stylesheet_directory_uri() . '/img/' . 'word.png';\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase 'application/vnd.ms-excel':\r\n\t\t\t\t\t$icon = get_stylesheet_directory_uri() . '/img/' . 'excel.png';\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase 'application/vnd.ms-powerpoint':\r\n\t\t\t\t\t$icon = get_stylesheet_directory_uri() . '/img/' . 'powerpoint.png';\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tdefault:\r\n\t\t\t\t\t$icon = get_stylesheet_directory_uri() . '/img/' . 'download.png';\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\r\n\t\t\t$html .= sprintf( '<a href=\"%1$s\" title=\"%2$s\">',\r\n\t\t\t\tesc_url( $download[ 'url' ] ),\r\n\t\t\t\t__( 'Download this file', 'emc' )\r\n\t\t\t);\r\n\t\t\t$html .= '<div class=\"emc-download emc-button\">';\r\n\t\t\t$html .= '<img class=\"emc-download-icon\" src=\"' . $icon . '\"/>';\r\n\t\t\t$html .= esc_html( $download[ 'title' ] );\r\n\t\t\t$html .= '</div></a>';\r\n\r\n\r\n\t\t\t}\r\n\r\n\t}\r\n\r\n\techo $html;\r\n\r\n}", "function get_file(){\n extract($this->_url_params);\n /**\n * @var string $file_name\n * @var int $project_id\n */\n $this->load_view(false);\n if(!isset($file_name, $project_id)) goto redirect;\n /**\n * @var \\AWorDS\\App\\Models\\Project $project\n */\n $project = $this->set_model();\n $logged_in = $project->login_check();\n if($logged_in AND $project->verify($project_id)){\n $file_type = null;\n switch($file_name){\n case 'SpeciesRelation.txt': $file_type = Constants::EXPORT_SPECIES_RELATION; break;\n case 'DistantMatrix.txt' : $file_type = Constants::EXPORT_DISTANT_MATRIX; break;\n case 'NeighbourTree.jpg' : $file_type = Constants::EXPORT_NEIGHBOUR_TREE; break;\n case 'UPGMATree.jpg' : $file_type = Constants::EXPORT_UPGMA_TREE;\n }\n if($file_type == null) goto redirect;\n $file = $project->export($project_id, $file_type);\n if($file == null){\n redirect:\n $this->redirect(isset($_SERVER['HTTP_REFERER']) ?\n $_SERVER['HTTP_REFERER'] :\n Config::WEB_DIRECTORY . 'projects');\n exit();\n }\n header('Content-Type: ' . $file['mime']);\n header('Content-Disposition: attachment; filename=\"' . $file['name'] . '\"');\n readfile($file['path']);\n exit();\n }\n goto redirect;\n }", "public function downloadImages(){\n if(Auth::user()->statut_id != 3) return back();\n $this->createZip();\n return response()->download(public_path('allImages.zip'));\n }", "public function downloadftvAction()\n {\n $user_params=$this->_request->getParams();\n $request_id = $user_params['request_id'];\n $zipname = explode(\"/\",$user_params['filename']);\n // set example variables\n $filename = $zipname[1];\n $filepath = $request_id.\"-\".$filename;\n\n $this->_redirect(\"/BO/download_ftv.php?ftvfile=\".$filepath.\"\");\n /** Author: Thilagam **/\n /** Date:05/05/2016 **/\n /** Reason: Code optimization **/\n //$this->_redirect(\"/BO/download-files.php?function=downloadFtv&ftvfile=\".$filepath.\"\");\n\n }", "public function downloadAction()\n {\n $user = $this->getConnectedUser();\n\n $em = $this->getDoctrine()->getManager();\n\n $request = $this->get('request');\n\n if ($request->getMethod() == 'POST') {\n $foldersId = $request->request->get('foldersId');\n $foldersId = json_decode($foldersId);\n $filesId = $request->request->get('filesId');\n $filesId = json_decode($filesId);\n\n if ((!is_null($filesId) && sizeof($filesId) > 0) ||\n (!is_null($foldersId) && sizeof($foldersId) > 0)) {\n $filesToDownload = $em->getRepository('TimeBoxMainBundle:Version')->getLastestFileVersion($user, $filesId);\n $foldersToDownload = $em->getRepository('TimeBoxMainBundle:Folder')->findBy(array(\n 'id' => $foldersId,\n 'user' => $user\n ));\n\n if (!is_null($filesToDownload)) {\n // One file and no folder is requested\n if (sizeof($filesToDownload) == 1 && sizeof($foldersToDownload) == 0) {\n $version = $filesToDownload[0];\n $file = $version->getFile();\n\n $filePath = $version->getAbsolutePath();\n $filename = $file->getName();\n $type = $file->getType();\n if (!is_null($type)) {\n $filename .= '.'.$type;\n }\n\n if (!file_exists($filePath)) {\n throw $this->createNotFoundException();\n }\n\n // Trigger file download\n $response = new Response();\n $response->headers->set('Content-type', 'application/octet-stream');\n $response->headers->set('Content-Disposition', sprintf('attachment; filename=\"%s\"', $filename));\n $response->setContent(file_get_contents($filePath));\n return $response;\n }\n\n // Create zip folder on server if not exist\n $zipFolder = $this->get('kernel')->getRootDir() . '/../web/uploads/zip/';\n if (!file_exists($zipFolder)) {\n mkdir($zipFolder, 0755, true);\n }\n\n // Create zip archive\n $zip = new ZipArchive();\n $zipName = 'TimeBoxDownloads-'.time().'.zip';\n $zipPath = $zipFolder . $zipName;\n $zip->open($zipPath, ZipArchive::CREATE);\n\n // Fill zip with folders\n foreach($foldersToDownload as $folder){\n $this->addFolderToZip($folder, $zip);\n }\n\n // Fill zip with files\n foreach ($filesToDownload as $f) {\n $version = $f;\n $file = $version->getFile();\n\n $filePath = $version->getAbsolutePath();\n $filename = $file->getName();\n $type = $file->getType();\n if (!is_null($type)) {\n $filename .= '.'.$type;\n }\n\n $zip->addFile($filePath, $filename);\n }\n\n $zip->close();\n\n // Trigger file download\n $response = new Response();\n $response->headers->set('Content-type', 'application/octet-stream');\n $response->headers->set('Content-Disposition', sprintf('attachment; filename=\"%s\"', $zipName));\n $response->setContent(file_get_contents($zipPath));\n return $response;\n }\n }\n }\n return new Response('An error has occured.');\n }", "function cfc_edd_receipt_show_download_files() {\n\treturn false;\n}", "function download_attachment($key, $filename)\n {\n global $standard_headers;\n global $cookie;\n\n $fp = fopen($filename, 'w');\n\n $ch = curl_init('https://www.tadpoles.com/remote/v1/attachment?key=' . $key);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);\n curl_setopt($ch, CURLOPT_HTTPHEADER, $standard_headers);\n curl_setopt($ch, CURLOPT_COOKIE, $cookie);\n curl_setopt($ch, CURLOPT_FILE, $fp);\n\n $response = curl_exec($ch);\n curl_close($ch);\n fclose($fp);\n }", "public function download($id)\n\t{\n\t\t$fileInfo = $this->m_admin->getRows(array('name' => $id));\n\t\t//file path\n\t\t$filename = $fileInfo['name'] ?? 'default value';\n\t\t$filepath = 'C:\\xampp\\htdocs\\repositori\\uploads\\file_aplikasi/' . $fileInfo['name'];\n\t\t$data = file_get_contents($filepath);\n\t\t//download file from directory\n\t\t$mime = get_mime_by_extension($filepath);\n\t\theader('Content-Type: ' . $mime); // Add the mime type from Code igniter.\n\n\t\treturn force_download($filename, $data);\n\t}", "public function getDownload($id){\n //PDF file is stored under project/public/download/info.pdf\n\n $file= public_path(). \"/download/\";\n $headers = array(\n 'Content-Type: application/pdf',\n );\n return Response::download($file, 'info.pdf', $headers);\n }", "function download_suket_021()\n\t{\n\t\tforce_download('assets/uploads/warga/suket_021/template_surat_recomendasi_usaha_mikro_kecil.docx', NULL);\n\t}", "function download_suket_018_laki()\n\t{\n\t\tforce_download('assets/uploads/warga/suket_018/template_surat_pengantar_nikah_laki_laki.docx', NULL);\n\t}", "function download_project(){\n $this->_HTML = false;\n if(isset($this->_url_params['project_id'])) $project_id = $this->_url_params['project_id'];\n else exit();\n \n /**\n * @var \\AWorDS\\App\\Models\\Project $project\n */\n $project = $this->set_model();;\n $logged_in = $project->login_check();\n if($logged_in){\n if((string) ((int) $project_id) == $project_id AND $project->verify($project_id)) {\n $file = $project->export($project_id, Constants::EXPORT_ALL);\n if ($file != null) {\n header('Content-Type: ' . $file['mime']);\n header('Content-Disposition: attachment; filename=\"' . $file['name'] . '\"');\n readfile($file['path']);\n } else $this->redirect(Config::WEB_DIRECTORY . 'projects');\n }else $this->redirect(Config::WEB_DIRECTORY . 'projects');\n }else $this->redirect();\n }", "public function download(){\n\t\treturn $this->fpdi->Output($this->fileName, 'D');\n\t}", "public function download_backup(){\n\t\tif ($this->in->get('backups') != \"\"){\n\n\t\t\t$file_name = $this->pfh->FolderPath('backup', 'eqdkp').$this->in->get('backups');\n\n\t\t\tif (preg_match('#^eqdkp-backup_([0-9]{10})_([0-9]{1,10})\\.(sql|zip?)$#', $this->in->get('backups'), $matches) || preg_match('#^eqdkp-fbackup_([0-9]{10})_([0-9]{1,10})\\.(sql|zip?)$#', $this->in->get('backups'), $matches) ){\n\n\t\t\t\t$name = 'eqdkp-backup_' . $this->time->date('Y-m-d_Hi', $matches[1]).\".\".$matches[3];\n\n\t\t\t\tswitch ($matches[3]){\n\t\t\t\t\tcase 'sql':\n\t\t\t\t\t\t$mimetype = 'text/x-sql';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'zip':\n\t\t\t\t\t\t$mimetype = 'application/zip';\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\n\t\t\t\theader('Pragma: no-cache');\n\t\t\t\theader(\"Content-Type: $mimetype; name=\\\"$name\\\"\");\n\t\t\t\theader(\"Content-disposition: attachment; filename=$name\");\n\n\t\t\t\t@set_time_limit(0);\n\n\t\t\t\t$fp = @fopen($file_name, 'rb');\n\n\t\t\t\tif ($fp !== false){\n\t\t\t\t\twhile (!feof($fp)){\n\t\t\t\t\t\techo fread($fp, 8192);\n\t\t\t\t\t}\n\t\t\t\t\tfclose($fp);\n\t\t\t\t}\n\t\t\t\tflush();\n\t\t\t}\n\t\t\texit();\n\t\t\t//$this->display('1');\n\t\t} else {\n\t\t}\n\t}", "public function downloadFile($id) {\n $lmsFile = LMSFile::find($id);\n //$file = Storage::disk('local')->get('lms/'.$lmsFile->hash);\n //Alternaive method\n $url = public_path().'/../storage/lms/'.$lmsFile->hash;\n return response()->download($url);\n //return (new Response($file, 200));\n }", "public function download()\n {\n\n $hashes = explode(',', $this->request->get('hashes'));\n $ids = array_map(function($hash) {\n return $this->fileEntry->decodeHash($hash);\n }, $hashes);\n\n $entries = $this->fileEntry->whereIn('id', $ids)->get();\n\n // TODO: refactor file entry policy to accent multiple IDs\n $entries->each(function($entry) {\n $this->authorize('show', [FileEntry::class, $entry]);\n });\n\n if ($entries->count() === 1 && $entries->first()->type !== 'folder') {\n $entry = $entries->first();\n\n $disk = $entry->getDisk();\n $stream = $disk->readStream($entry->getStoragePath());\n\n return response()->stream(function() use($stream) {\n fpassthru($stream);\n }, 200, [\n \"Content-Type\" => $entry->mime,\n \"Content-Length\" => $disk->size($entry->getStoragePath()),\n \"Content-disposition\" => \"attachment; filename=\\\"\" . $entry->name . \"\\\"\",\n ]);\n } else {\n $path = $this->createZip($entries);\n $timestamp = Carbon::now()->getTimestamp();\n return response()->download($path, \"download-$timestamp.zip\");\n }\n }", "function downloadFile($option, $cid){\n global $jlistConfig;\n\n $app = &JFactory::getApplication(); \n $database = &JFactory::getDBO(); \n clearstatcache(); \n \n $view_types = array();\n $view_types = explode(',', $jlistConfig['file.types.view']);\n \n // get path\n $database->SetQuery(\"SELECT * FROM #__jdownloads_files WHERE file_id = $cid\");\n $file = $database->loadObject();\n\n if ($file->url_download){\n $database->SetQuery(\"SELECT cat_dir FROM #__jdownloads_cats WHERE cat_id = $file->cat_id\");\n $cat_dir = $database->loadResult();\n $filename_direct = JURI::root().$jlistConfig['files.uploaddir'].DS.$cat_dir.DS.$file->url_download;\n $file = JPATH_SITE.DS.$jlistConfig['files.uploaddir'].DS.$cat_dir.DS.$file->url_download; \n } else {\n exit;\n } \n\n $len = filesize($file);\n \n // if set the option for direct link to the file\n if (!$jlistConfig['use.php.script.for.download']){\n if (empty($filename_direct)) {\n $app->redirect($file);\n } else {\n $app->redirect($filename_direct);\n }\n } else { \n $filename = basename($file);\n $file_extension = strtolower(substr(strrchr($filename,\".\"),1));\n $ctype = datei_mime($file_extension);\n ob_end_clean();\n // needed for MS IE - otherwise content disposition is not used?\n if (ini_get('zlib.output_compression')){\n ini_set('zlib.output_compression', 'Off');\n }\n \n header(\"Cache-Control: public, must-revalidate\");\n header('Cache-Control: pre-check=0, post-check=0, max-age=0');\n // header(\"Pragma: no-cache\"); // Problems with MS IE\n header(\"Expires: 0\"); \n header(\"Content-Description: File Transfer\");\n header(\"Expires: Sat, 26 Jul 1997 05:00:00 GMT\");\n header(\"Content-Type: \" . $ctype);\n header(\"Content-Length: \".(string)$len);\n if (!in_array($file_extension, $view_types)){\n header('Content-Disposition: attachment; filename=\"'.$filename.'\"');\n } else {\n // view file in browser\n header('Content-Disposition: inline; filename=\"'.$filename.'\"');\n } \n header(\"Content-Transfer-Encoding: binary\\n\");\n \n // set_time_limit doesn't work in safe mode\n if (!ini_get('safe_mode')){ \n @set_time_limit(0);\n }\n @readfile($file);\n }\n exit;\n}", "public function index($id,$file)\n {\n \t$user = Auth::user();\n // Getting current task\n \t$task = Task::find($id);\n // checking if task is completed, if it is we check if the user has permission to retrieve from archive\n \tif ($task->completed_on != null && Gate::denies(\"create_inquiry\")) {\n \treturn view('errors.403');\n // checking if task is from another party when user is not part of LyuboINC.\n \t}elseif(Gate::denies(\"view_tasks_LyuboINC\") && ($task->partner != $user->partner)){\n \t\treturn view('errors.403');\n \t}else{\n \t\treturn response()->download(base_path().\"/storage/app/public/FileCatalog/\".$id.\"/\".$file);\n \t}\n }", "public function getDownloadPath() {}", "public function downloadAction()\n\t{\n\t\t$settings = $this->getProgressParameters();\n\n\t\tif (!empty($settings['downloadParams']['filePath']) && !empty($settings['downloadParams']['fileName']))\n\t\t{\n\t\t\t$file = new Main\\IO\\File($settings['downloadParams']['filePath']);\n\t\t\tif ($file->isExists())\n\t\t\t{\n\t\t\t\t$response = new Main\\Engine\\Response\\File(\n\t\t\t\t\t$file->getPath(),\n\t\t\t\t\t$settings['downloadParams']['fileName'],\n\t\t\t\t\t$settings['downloadParams']['fileType']\n\t\t\t\t);\n\n\t\t\t\treturn $response;\n\t\t\t}\n\t\t}\n\n\t\t$this->addError(new Error('File not found'));\n\t}", "function download() {\n $diffusion_id = JFactory::getApplication()->input->getInt('id', null, 'int');\n $order_id = JFactory::getApplication()->input->getInt('order', null, 'int');\n\n if (empty($diffusion_id)):\n $return['ERROR'] = JText::_('COM_EASYSDI_SHOP_ORDER_ERROR_EMPTY_ID');\n echo json_encode($return);\n die();\n endif;\n\n $order = JTable::getInstance('order', 'Easysdi_shopTable');\n $order->load($order_id);\n\n /////////// Check user right on this order\n $downloadAllowed = false;\n\n //the user is shop admin\n if (JFactory::getUser()->authorise('core.manage', 'com_easysdi_shop')):\n $downloadAllowed = true;\n endif;\n\n if (!$downloadAllowed) {\n $return['ERROR'] = JText::_('JERROR_ALERTNOAUTHOR');\n echo json_encode($return);\n die();\n }\n\n //Load order response\n $orderdiffusion = JTable::getInstance('orderdiffusion', 'Easysdi_shopTable');\n $keys = array();\n $keys['order_id'] = $order_id;\n $keys['diffusion_id'] = $diffusion_id;\n $orderdiffusion->load($keys);\n\n return Easysdi_shopHelper::downloadOrderFile($orderdiffusion);\n }", "public function exportCsvAction()\n {\n $fileName = 'appointments.csv';\n $grid = $this->getLayout()->createBlock('appointments/adminhtml_appointments_grid');\n $this->_prepareDownloadResponse($fileName, $grid->getCsvFile());\n }", "public function download($id_pelapor)\n {\n // $id = 0;\n // $noTiket = 0;\n // foreach ($query as $key) {\n // $id = $key['id_pelapor'];\n // $noTiket = $key['no_tiket'];\n // }\n\n // $query2 = $this->detailLaporanModel->where('report_id', $id)->findAll();\n\n\n // foreach ($query2 as $key) {\n // # code...\n // // $url = ROOTPATH . \"public/uploads/\" . $key['gambar'];\n // $url = ROOTPATH . \"public/uploads/\" . $key['gambar'];\n // // file_get_contents($url);\n // // print_r($url);\n // }\n // return $this->response->download($key['gambar'], $url);\n // session()->setFlashdata('pesan', 'Gambar berhasil diunduh.');\n // return redirect()->to(base_url('/admin/reportLaporan'));\n $query = $this->load->library('zip');\n }", "public function downloads(){\r\n $this->load->helper('download');\r\n //Get the file from whatever the user uploaded (NOTE: Users needs to upload first), @See http://localhost/CI/index.php/upload\r\n $data = file_get_contents(\"./uploads/Past and on-going SC projects.xlsx\");\r\n //Read the file's contents\r\n $name = 'Past and on-going SC projects.xlsx';\r\n\r\n //use this function to force the session/browser to download the file uploaded by the user \r\n force_download($name, $data);\r\n }", "function downloadFile($folder,$filename) {\n\t\t$this->autoLayout = false;\n\t\t$newFileName = $filename;\n\t\t$folder = str_replace('-','/',$folder);\n\t\t//Replace - to / to view subfolder\n\t $path = WWW_ROOT.$folder.'/'.$filename;\n\t\tif(file_exists($path) && is_file($path)) {\n\t\t\t$mimeContentType = 'application/octet-stream';\n\t\t\t$temMimeContentType = $this->_getMimeType($path);\n\t\t\tif(isset($temMimeContentType) && !empty($temMimeContentType))\t{\n\t\t\t\t\t\t\t$mimeContentType = $temMimeContentType;\n\t\t\t}\n\t\t //echo 'sssssssssss--->' . $mimeContentType;\t\t exit;\n\t\t\t// START ANDR SILVA DOWNLOAD CODE\n\t\t\t// required for IE, otherwise Content-disposition is ignored\n\t\t\tif(ini_get('zlib.output_compression'))\n\t\t\t \tini_set('zlib.output_compression', 'Off');\n\t\t\theader(\"Pragma: public\"); // required\n\t\t\theader(\"Expires: 0\");\n\t\t\theader(\"Cache-Control: must-revalidate, post-check=0, pre-check=0\");\n\t\t\theader(\"Cache-Control: private\",false); // required for certain browsers \n\t\t\theader(\"Content-Type: \" . $mimeContentType );\n\t\t\t// change, added quotes to allow spaces in filenames, by Rajkumar Singh\n\t\t\theader(\"Content-Disposition: attachment; filename=\\\"\".(is_null($newFileName)?basename($path):$newFileName).\"\\\";\" );\n\t\t\theader(\"Content-Transfer-Encoding: binary\");\n\t\t\theader(\"Content-Length: \".filesize($path));\n\t\t\treadfile($path);\n\t\t\texit();\n\t\t\t// END ANDR SILVA DOWNLOAD CODE\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t }\n\t\t if(isset($_SERVER['HTTP_REFERER'])) {\n\t\t \t $this->Session->setFlash('File not found.');\n\t\t\t $this->redirect($_SERVER['HTTP_REFERER']);\n\t\t }\t \n \t}", "public function download()\n {\n $this->pdf->Output(\n $this->fileName,\n self::EXPORT_TYPE_DOWNLOAD\n );\n }", "function zip_download_alternative($files)\r\n{\r\n\tglobal $_course;\r\n\tglobal $_user;\r\n\r\n\t$temp_zip_dir = api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp/\";\r\n\r\n\t// Step 1: create the overview file and add it to the zip\r\n\t$overview_file_content=generate_html_overview($files, array('filename'), array('title'));\r\n\t$overview_file=$temp_zip_dir.'overview'.$_user['firstname'].$_user['lastname'].'.html';\r\n\t$handle=fopen($overview_file,'w');\r\n\tfwrite($handle,$overview_file_content);\r\n\t// todo: find a different solution for this because even 2 seconds is no guarantee.\r\n\tsleep(2);\r\n\r\n\t// Step 2: we copy all the original dropbox files to the temp folder and change their name into the original name\r\n\tforeach ($files as $key=>$value)\r\n\t{\r\n\t\t$value['title']=check_file_name($value['title']);\r\n\t\t$files[$value['filename']]['title']=$value['title'];\r\n\t\tcopy(api_get_path(SYS_COURSE_PATH).$_course['path'].\"/dropbox/\".$value['filename'], api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp/\".$value['title']);\r\n\t}\r\n\r\n\t// Step 3: create the zip file and add all the files to it\r\n\t$temp_zip_file=$temp_zip_dir.'/dropboxdownload-'.$_user['user_id'].'-'.mktime().'.zip';\r\n\t$zip_folder=new PclZip($temp_zip_file);\r\n\tforeach ($files as $key=>$value)\r\n\t{\r\n\t\t$zip_folder->add(api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp/\".$value['title'],PCLZIP_OPT_REMOVE_PATH, api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp\");\r\n\t}\r\n\r\n\t// Step 4: we add the overview file\r\n\t$zip_folder->add($overview_file,PCLZIP_OPT_REMOVE_PATH, api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp\");\r\n\r\n\t// Step 5: send the file for download;\r\n\tDocumentManager::file_send_for_download($temp_zip_file,true,$name);\r\n\r\n\t// Step 6: remove the files in the temp dir\r\n\tforeach ($files as $key=>$value)\r\n\t{\r\n\t\tunlink(api_get_path(SYS_COURSE_PATH).$_course['path'].\"/temp/\".$value['title']);\r\n\t}\r\n\t//unlink($overview_file);\r\n\r\n\texit;\r\n}", "function downloadFile($args) {\n\t\t$monographId = isset($args[0]) ? $args[0] : 0;\n\t\t$fileId = isset($args[1]) ? $args[1] : 0;\n\t\t$revision = isset($args[2]) ? $args[2] : null;\n\n\t\t$this->validate($monographId);\n\t\t$submission =& $this->submission;\n\t\tif (!CopyeditorAction::downloadCopyeditorFile($submission, $fileId, $revision)) {\n\t\t\tRequest::redirect(null, null, 'submission', $monographId);\n\t\t}\n\t}", "public function downloadAttachment($id_attachment)\n {\n $user = Sentinel::getUser();\n\n\n $maintenance_job_document = MaintenanceJobDocument::findOrFail($id_attachment);\n\n // dd($maintenance_job_document);\n // $bookingDocument = BookingDocument::findOrFail($id_booking_document);\n\n //get saas client business id of user who download the document\n // $id_saas_client_business_user_down = $user->id_saas_client_business;\n\n //get saas client business id of user who uploaded the document\n // $staff = $maintenance_job_document->id_staff;\n // $user = User::findOrFail($staff);\n // $id_saas_client_business_user_upload = $user->id_saas_client_business;\n\n //TODO check if this booking document belongs to this saas client, if not return\n\n // if ($id_saas_client_business_user_down == $id_saas_client_business_user_upload) {\n //get file name + the extension\n $file_name = $maintenance_job_document->document_name;\n\n //calculate relative path for the file\n $file_path = $maintenance_job_document->document_address . $file_name;\n\n Log::info(\"in DocumentManagementController- downloadDocument function \" . \" try to download documents of a booking:\" . \" ------- by user \" . $user->first_name . \" \" . $user->last_name);\n\n\n //download file, use public path to calculate absolute path of the file\n return response()->download(public_path($file_path), $file_name);\n // } else {\n\n // throw new \\Exception( trans('booking.you_are_not_allowed_to_download_this_document'));\n // }\n\n\n\n }", "function download_suket_018_duda()\n\t{\n\t\tforce_download('assets/uploads/warga/suket_018/template_surat_pengantar_nikah_duda.docx', NULL);\n\t}", "abstract function download($rempath, $locpath, $mode = 'auto');", "public function downloadBackup() {\n $nonce = $this->getNonce();\n\n if ($nonce && isset($_GET['download'])) {\n $zipfile = $this->tempPath() . self::ZIPCOMP_STUB;\n if (file_exists($zipfile)) {\n $this->loadManifest();\n\n $filename = array(\n __CLASS__,\n $nonce,\n preg_replace('/(?:https?)?[^a-z0-9]+/i', '-', $this->manifest['home_url']),\n );\n\n header('Content-Description: File Transfer');\n header('Content-Type: application/octet-stream');\n header('Content-Disposition: attachment; filename=' . implode('-', $filename) . '.zip');\n header('Expires: 0');\n header('Cache-Control: no-cache');\n header('Content-Length: ' . filesize($zipfile));\n readfile($zipfile);\n $this->doCleanup();\n exit();\n } else {\n wp_die('No matching cambrian archive found');\n }\n }\n }", "public function index()\n {\n $fileName = 'itsolutionstuff.txt';\n $fileData = 'This file created by Itsolutionstuff.com';\n \n $this->zip->add_data($fileName, $fileData);\n \n $fileName2 = 'itsolutionstuff_file2.txt';\n $fileData2 = 'This file created by Itsolutionstuff.com - 2';\n \n $this->zip->add_data($fileName2, $fileData2);\n \n $this->zip->download('Itsolutionstuff_zip.zip');\n }", "public static function view_Download () {\n header(\"Content-type: text/csv\");\n header('Content-disposition: attachment; filename=\"'.$_SESSION['CSV']['title'].'.csv\"');\n echo $_SESSION['CSV']['csv'];\n exit;\n }", "public function testDownloadSubmissionArchive()\n {\n $mockFileStorage = Mockery::mock(FileStorageManager::class);\n $mockFileStorage->shouldReceive(\"getWorkerSubmissionArchive\")\n ->withArgs(['student', 'id1'])->andReturn(Mockery::mock(LocalImmutableFile::class))->once();\n $this->presenter->fileStorage = $mockFileStorage;\n\n $request = new \\Nette\\Application\\Request(\n $this->presenterPath,\n 'GET',\n ['action' => 'downloadSubmissionArchive', 'type' => 'student', 'id' => 'id1']\n );\n $response = $this->presenter->run($request);\n\n Assert::type(StorageFileResponse::class, $response);\n }", "public function downloadFiles()\r\n {\r\n // check permission\r\n $this->_check_group_permission();\r\n\r\n $access_full_path = $this->_get_access_full_path();\r\n $filenames = $this->input->get_post('filenames');\r\n $filenames_arr = json_decode($filenames);\r\n $targetname = $this->input->get_post('targetname');\r\n\r\n // insert userlog\r\n $gid = $this->input->get_post('gid');\r\n if (substr($gid, 0, 1) === 's')\r\n {\r\n $b36_sid = substr($gid, 1);\r\n $share = $this->login->get_share_access($b36_sid);\r\n $gid = $share['gid'];\r\n $folder_name = $share['name'];\r\n }\r\n else\r\n {\r\n $folder_name = $this->login->get_group_name($gid);\r\n }\r\n if (count($filenames_arr) == 1)\r\n {\r\n $fileinode = $this->files_model->fileinode($access_full_path .'/'. $filenames_arr[0]);\r\n $target = str_replace('/'. $folder_name, '', $access_full_path, $cnt = 1) .'/'. $filenames_arr[0];\r\n $details = '';\r\n }\r\n else\r\n {\r\n $fileinode = 0;\r\n $target = $this->files_model->get_utf8_basename($access_full_path) . '.zip';\r\n $details = $filenames;\r\n }\r\n $user = $this->login->get_user();\r\n $this->userlog_model->insert(\r\n $user['id'],\r\n $user['name'],\r\n Userlog_model::FILE_DOWNLOAD,\r\n $gid,\r\n $folder_name,\r\n $fileinode,\r\n $target,\r\n $details\r\n );\r\n\r\n $this->files_model->download_files($access_full_path, $filenames_arr, $targetname);\r\n }", "function downloadFile($filename, $downloadPath)\n{\n App::set_response_header('Content-Type', 'text/plain');\n App::set_response_header('Pragma', 'no-cache');\n App::set_response_header(\n 'Content-Disposition',\n \"attachment; filename={$filename}\"\n );\n readfile($downloadPath);\n}", "function http_send_content_disposition($filename, $inline = null) {}", "public function action_download()\n\t{\n\t\t$view = View::forge('tracker/download');\n\t\t$data = array(\n\t\t\t'page_title' => '動漫清單',\n\t\t\t'loggedin' => true,\n\t\t\t'user' => $this->getUserInfo(),\n\t\t);\n\t\t$view->set_global($data);\n\t\treturn $view;\n\t}", "public function downloadpresskitveue($file_name)\n {\n // echo $file_name;die;\n $filennmdownload = base64_decode($file_name);\n // echo $filennm;die;\n //********its working for single file\n $download_path = ( public_path() . '/upload/venue-press-kit/source-file/' . $filennmdownload );\n return( Response::download( $download_path ) );\n \n }", "function bookking_pluginfile($course, $cm, $context, $filearea, $args, $forcedownload, array $options=array()) {\n global $CFG, $DB, $USER;\n\n if ($context->contextlevel != CONTEXT_MODULE) {\n return false;\n }\n\n require_course_login($course, true, $cm);\n if (!has_any_capability(array('mod/bookking:appoint', 'mod/bookking:attend'), $context)) {\n return false;\n }\n\n try {\n $bookking = bookking_instance::load_by_coursemodule_id($cm->id);\n\n $entryid = (int)array_shift($args);\n $relativepath = implode('/', $args);\n\n if ($filearea === 'slotnote') {\n if (!$bookking->get_slot($entryid)) {\n return false;\n }\n // No further access control required - everyone can see slots notes.\n\n } else if ($filearea === 'appointmentnote') {\n if (!$bookking->uses_appointmentnotes()) {\n return false;\n }\n\n list($slot, $app) = $bookking->get_slot_appointment($entryid);\n if (!$app) {\n return false;\n }\n\n if (!($USER->id == $app->studentid || $USER->id == $slot->teacherid)) {\n require_capability('mod/bookking:manageallappointments', $context);\n }\n\n } else if ($filearea === 'teachernote') {\n if (!$bookking->uses_teachernotes()) {\n return false;\n }\n\n list($slot, $app) = $bookking->get_slot_appointment($entryid);\n if (!$app) {\n return false;\n }\n\n if (!($USER->id == $slot->teacherid)) {\n require_capability('mod/bookking:manageallappointments', $context);\n }\n\n } else if ($filearea === 'bookinginstructions') {\n $caps = array('moodle/course:manageactivities', 'mod/bookking:appoint');\n if (!has_any_capability($caps, $context)) {\n return false;\n }\n\n } else if ($filearea === 'studentfiles') {\n if (!$bookking->uses_studentfiles()) {\n return false;\n }\n\n list($slot, $app) = $bookking->get_slot_appointment($entryid);\n if (!$app) {\n return false;\n }\n\n if (($USER->id != $slot->teacherid) && ($USER->id != $app->studentid)) {\n require_capability('mod/bookking:manageallappointments', $context);\n }\n\n } else {\n // Unknown file area.\n return false;\n }\n } catch (Exception $e) {\n // Typically, records that are not found in the database.\n return false;\n }\n\n $fullpath = \"/$context->id/mod_bookking/$filearea/$entryid/$relativepath\";\n\n $fs = get_file_storage();\n if (!$file = $fs->get_file_by_hash(sha1($fullpath)) or $file->is_directory()) {\n return false;\n }\n\n send_stored_file($file, 0, 0, $forcedownload, $options);\n}" ]
[ "0.6597378", "0.65054774", "0.64853954", "0.6481185", "0.64392763", "0.6373567", "0.63659817", "0.6301281", "0.6253963", "0.6248563", "0.6192465", "0.61775964", "0.6139654", "0.6127384", "0.60666096", "0.6053498", "0.60405105", "0.60267556", "0.6007248", "0.59849405", "0.59810925", "0.5952657", "0.5951173", "0.59496623", "0.5905247", "0.58739054", "0.5862654", "0.5860495", "0.5850642", "0.58202463", "0.58054984", "0.5791456", "0.5790337", "0.5774471", "0.57718587", "0.5744659", "0.57288516", "0.5719807", "0.57141", "0.5696669", "0.5688124", "0.5682294", "0.5671557", "0.5661057", "0.5656317", "0.56552804", "0.5643507", "0.56357735", "0.563396", "0.5633278", "0.5623266", "0.56158024", "0.56105036", "0.560767", "0.56058204", "0.5603807", "0.56027937", "0.5586766", "0.55740136", "0.5568439", "0.555575", "0.5555533", "0.55496955", "0.5545757", "0.5542842", "0.5541593", "0.55409914", "0.55312794", "0.55252504", "0.55231065", "0.55209696", "0.5519902", "0.5517574", "0.5514215", "0.5509453", "0.5503583", "0.5477211", "0.5470705", "0.5461856", "0.5461532", "0.5457923", "0.545303", "0.54503465", "0.5449497", "0.54455185", "0.5438713", "0.54320294", "0.54289466", "0.54237163", "0.54236203", "0.54155946", "0.54137516", "0.54065096", "0.54019815", "0.54014766", "0.54003763", "0.5394247", "0.5390302", "0.5387843", "0.5387802" ]
0.7904505
0
Clear object properties when $this is destroyed.
public function __destruct() { $this->data = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __destruct()\n {\n $vars = get_object_vars($this);\n if (is_array($vars)) {\n foreach ($vars as $key => $val) {\n $this->$key = null;\n }\n }\n\n parent::__destruct();\n }", "public function clear() {\n\t\t$vars = get_object_vars($this);\n\t\tforeach ($vars as $key => $val) {\n\t\t\t$this->$key = null;\n\t\t}\n\t}", "public function __destruct() {\r\n unset( $this );\r\n }", "public function __destruct()\n {\n $this->clear();\n }", "public function __destruct()\n {\n $this->clear();\n }", "public function __destruct() {\n\t\tunset($this);\n\t}", "public function clear()\n\t{\n\t\tforeach( self::$properties as $prop )\n\t\t\tunset( $this->$prop ) ;\n\t\treturn $this ;\n\t}", "public function __destruct() {\n\t\tunset ( $this );\n\t}", "public function __destruct(){unset($this);}", "public function __destruct() {\n $this->this = null;\n }", "public function __destruct()\n {\n foreach ($this as $key => $value) {\n unset($this->$key);\n }\n }", "public function clear()\n\t{\n\t\t$classvars = get_class_vars(__CLASS__);\n\n\t\tforeach ($classvars as $property => $value)\n\t\t{\n\t\t\tif ('_s_' == substr($property, 0, 3)) // Don't touch static variables\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tunset($this->$property);\n\t\t\t$this->$property = $value;\n\t\t}\n\n\t\t$objvars = get_object_vars($this);\n\n\t\tforeach ($objvars as $property => $value)\n\t\t{\n\t\t\tif (!array_key_exists($property, $classvars))\n\t\t\t{\n\t\t\t\tunset($this->$property);\n\t\t\t}\n\t\t}\n\n\t\treturn true;\n\t}", "public function __destruct()\n\t{\n\t\tunset($this);\n\t}", "public function clearProperties();", "function clear()\r\n\t{\r\n\t\t// Clear the all list\r\n\t\t$this->all = array();\r\n\r\n\t\t// Clear errors\r\n\t\t$this->error = new stdClass();\r\n\t\t$this->error->all = array();\r\n\t\t$this->error->string = '';\r\n\r\n\t\t// Clear this objects properties and set blank error messages in case they are accessed\r\n\t\tforeach ($this->fields as $field)\r\n\t\t{\r\n\t\t\t$this->{$field} = NULL;\r\n\t\t\t$this->error->{$field} = '';\r\n\t\t}\r\n\r\n\t\t// Clear this objects \"has many\" related objects\r\n\t\tforeach ($this->has_many as $related)\r\n\t\t{\r\n\t\t\tunset($this->{$related});\r\n\t\t}\r\n\r\n\t\t// Clear this objects \"has one\" related objects\r\n\t\tforeach ($this->has_one as $related)\r\n\t\t{\r\n\t\t\tunset($this->{$related});\r\n\t\t}\r\n\r\n\t\t// Clear the query related list\r\n\t\t$this->query_related = array();\r\n\r\n\t\t// Clear and refresh stored values\r\n\t\t$this->stored = new stdClass();\r\n\r\n\t\t$this->_refresh_stored_values();\r\n\t}", "public function Clear () \r\n\t{\r\n\t\tself::Event (\"Clearing Object Properties\", \"\");\r\n\t\t$this->ID = 0;\r\n\t\t$this->AccountID = 0;\r\n\t\t$this->Code = \"\";\r\n\t\t$this->Name = \"\";\r\n\t\treturn ($this);\r\n\t}", "public function clear()\n\t{\n\t\t$this->getObject()->clear();\n\t}", "function __destruct(){\n unset($this->charset);\n foreach (get_object_vars($this) as $prop => $val) {\n if ($prop != null) {\n unset($this->{$prop});\n }\n }\n }", "public function cleanSavedProperties(){\n\t\t\n\t\tunset( $_SESSION[ get_class($this) ] );\n\t}", "public function __destruct()\n {\n unset($this->index);\n unset($this->objectList);\n unset($this->objectListKeys);\n }", "public function __destruct() {\n\t\tforeach ($this as $index => $value) unset($this->$index);\n\t}", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->metadata);\n\t\t\tunset($this->models);\n\t\t\tunset($this->translators);\n\t\t}", "public function __destruct()\n {\n unset($this->vars);\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->value);\n\t\t}", "public function clear() {\n foreach ($this->Fields as $key => $item) {\n $this->$key = null;\n }\n }", "public function __destruct()\n {\n unset($this->data);\n }", "function __destruct()\n {\n unset($this->parent);\n unset($this->sz);\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->info);\n\t\t\tunset($this->name);\n\t\t\tunset($this->value);\n\t\t}", "protected function tear_down()\n {\n unset($this->_object, $this->_view);\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->after);\n\t\t\tunset($this->before);\n\t\t\tunset($this->builder);\n\t\t\tunset($this->data_source);\n\t\t}", "public function clearVariables(): self\n {\n $attributes = get_object_vars($this);\n foreach ($attributes as $attributeName => $attributeValue) {\n $this->$attributeName = null;\n }\n return $this;\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->collection);\n\t\t}", "public function reset() {\n foreach ($this->syncedProperties as $property) {\n unset($this->data[$property]);\n }\n\n if (session_id()) {\n unset($_SESSION[self::SESSION_KEY]);\n }\n }", "public function forgetCached() {\n lRedis::del(Helpers::cacheKey($this) . \":properties\");\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->resource);\n\t\t\tunset($this->methods);\n\t\t\tunset($this->name);\n\t\t}", "function clear(){\r\n\t\t$_SESSION[self::_KEY_][get_class($this)]->reset();\r\n\t}", "public function cleanup()\n\t{\n\t\t$this->getObject()->cleanup();\n\t}", "public static function destroyObject()\n {\n static::$bxObject = null;\n }", "public function __destruct() {\n unset($this->_hash);\n }", "public function Dispose()\n {\n foreach($this as $key => $value)\n {\n if($key[0] == \"_\")\n unset($this->$key);\n }\n }", "protected function resetProperties() {}", "public function __destruct()\n\t{\n\t\tunset(self::$handles[spl_object_hash($this)]);\n\t}", "public function __wakeup() {\n $this->unset_members();\n }", "public function __destruct() {\n\t\t$this->clean();\n\t}", "public function __destruct()\n\t{\n\t\t$this->detach();\n\t}", "public function unsetProperty()\n\t{\n\t\t$this -> tableName = '';\n\t\t$this -> databaseName = '';\n\t\t$this -> arrNewData = array();\n\t\t$this -> arrOldData = array();\n\t}", "private function unsetAll() {\n $ref = new ReflectionClass( $this );\n foreach ( $ref->getProperties() as $key => $value ) {\n $value = $value->getName();\n if ( in_array($value, array('_mysqlCharset', '_mysqlEngine', '_arraySplitChar', '_dbObject', '_singletonThis', '_dbConfig', '_lastQuery')) ) {\n continue;\n }\n\n $this->$value = NULL;\n }\n\n return $this;\n }", "public function __destruct()\n {\n\tunset($this->model);\n }", "public function __destruct()\n {\n unset($this->idDetalleOrden);\n unset($this->valorInventario);\n unset($this->valorVenta);\n unset($this->cantidad);\n unset($this->idOrden);\n unset($this->idProducto);\n unset($this->estado);\n unset($this->fechaCreacion);\n unset($this->fechaModificacion);\n unset($this->idUsuarioCreacion);\n unset($this->idUsuarioModificacion);\n unset($this->conn);\n }", "public function clear() {\n\t\t$bucket = $this->bucket();\n\t\t$props = $this->getPublicProperties();\n\t\tforeach($props as $k => $v) {\n\t\t\tunset($this->$k);\n\t\t}\n\t\treturn $this;\n\t}", "public function cleanUp()\n {\n $this->_value = null;\n }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->data);\n\t\t\tunset($this->file);\n\t\t\tunset($this->image);\n\t\t\tunset($this->uri);\n\t\t}", "public function __destruct(){\n\t\tunset($this->user);\n\t\tunset($this->gid);\n\t}", "public function __destruct() {\n $this->save(null);\n }", "public function reset() {\n $this->_property = false;\n $this->_interface = false;\n $this->_variable = false;\n }", "public function reset() {\n $this->_property = false;\n $this->_interface = false;\n $this->_variable = false;\n }", "protected function _clear()\n\t{\n\t\t$this->_query = null;\n\t\t$this->_set = null;\n\t\t$this->_where = null;\n\t\t$this->_limit = null;\n\t}", "public function __destruct()\n {\n Util::wipe($this->key);\n }", "private function unsetProperties(){\n //Human::log(\"--------------------------------------------------- unset initial properties for \".$this->modelName);\n foreach($this->fields() as $f){\n \n $fieldName=$f->name;\n \n unset($this->$fieldName);\n /*\n if(gettype($this->$fieldName)==\"object\"){\n Human::log(\"FIELD now $fieldName is \". get_class($this->$fieldName)); \n }else{\n Human::log(\"FIELD now $fieldName is \". gettype($this->$fieldName)); \n }\n\t \n\t */\n } \n }", "public function free()\n {\n if ($this->freed) {\n return;\n }\n $this->freed = true;\n\n $this->where = null;\n $this->orderBy = null;\n $this->groupBy = null;\n $this->innerJoins = [];\n $this->data = null;\n $this->joinedData = [];\n $this->vFieldCallbacks = [];\n $this->options = [];\n }", "private function _destruct()\r\n {\r\n $this->table = null;\r\n $this->select = null;\r\n $this->fields = null;\r\n $this->where = null;\r\n $this->ar_where = null;\r\n }", "public function __destruct()\n {\n unset($this->options);\n }", "public function clear()\n {\n\n $this->synchronized = true;\n $this->id = null;\n $this->newId = null;\n $this->data = [];\n $this->savedData = [];\n $this->multiRef = [];\n\n }", "public function flushProperties()\n\t{\n\t\t$this->properties = array();\n\t}", "public function clear()\n\t{\n\t\t$this->venueid = null;\n\t\t$this->address = null;\n\t\t$this->address2 = null;\n\t\t$this->city = null;\n\t\t$this->province = null;\n\t\t$this->country = null;\n\t\t$this->latitude = null;\n\t\t$this->longitude = null;\n\t\t$this->phone = null;\n\t\t$this->name = null;\n\t\t$this->description = null;\n\t\t$this->website = null;\n\t\t$this->twitter = null;\n\t\t$this->facebook = null;\n\t\t$this->rssfeed = null;\n\t\t$this->closed = null;\n\t\t$this->lastfmid = null;\n\t\t$this->slug = null;\n\t\t$this->hasphotos = null;\n\t\t$this->submittedbyuser = null;\n\t\t$this->alreadyInSave = false;\n\t\t$this->alreadyInValidation = false;\n\t\t$this->clearAllReferences();\n\t\t$this->applyDefaultValues();\n\t\t$this->resetModified();\n\t\t$this->setNew(true);\n\t\t$this->setDeleted(false);\n\t}", "public function destroy() {\n unset($this->items);\n $this->items = false;\n }", "public function __destruct()\n {\n $this->setValidates([]);\n }", "public function reset(): void\n {\n $this->_add = new SplObjectStorage();\n $this->_delete = new SplObjectStorage();\n }", "public function clear()\n {\n $this->fromArray(array());\n }", "public function clear()\n\t{\n\t\t$this->id = null;\n\t\t$this->uf_id = null;\n\t\t$this->nome = null;\n\t\t$this->slug = null;\n\t\t$this->longitude = null;\n\t\t$this->latitude = null;\n\t\t$this->alreadyInSave = false;\n\t\t$this->alreadyInValidation = false;\n\t\t$this->clearAllReferences();\n\t\t$this->resetModified();\n\t\t$this->setNew(true);\n\t\t$this->setDeleted(false);\n\t}", "public function destroy()\n {\n parent::destroy();\n foreach ($this->parameters as $param) {\n $param->destroy();\n }\n $this->parameters = [];\n }", "public function __destruct()\n\t{\n\t\tunset($this -> arrNewData);\n\t\tunset($this -> arrOldData);\n\t\tunset($this -> isCheckModify);\n\t\tunset($this -> tableName);\n\t\tunset($this -> databaseName);\n\t\t\t\n\t}", "public function __destruct() {\n unset($this->components);\n }", "public function __destruct()\n {\n if ($this->cache instanceof Swift_KeyCache) {\n $this->cache->clearAll($this->cacheKey);\n }\n }", "public function __destruct()\n\t{\n\t\t$this->db = null;\n\t\t$this->cat_data = false;\n\t\t$this->settings = null;\n\t}", "public function free()\n\t{\n\t\t//$fh = fopen(\"x:\\x.log\", \"a\");fwrite($fh, __CLASS__ . \"/\" .__FUNCTION__ . \"\\n\");fclose($fh);\n\n\t\tforeach (array_keys(get_object_vars($this)) as $k => $key) {\n\t\t\t// nejdrive okolni property pak asociace a data\n\t\t\tif (in_array($k, array(\"_associations\", \"_data\"))) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t// je to objekt? je typu IObjectContainerToFree? spustime na nej free\n\t\t\tif (is_object($this->$key) && $this->$key instanceof IObjectContainerToFree) {\n\t\t\t\t// nejdrive prepojime\n\t\t\t\t$object = $this->$key;\n\t\t\t\t// pak odpojime\n\t\t\t\t$this->$key = NULL;\n\t\t\t\t// a pak zlikvidujeme, jinak by se to mohlo zacyklit, record vola free kolekce a kolekce patri k rekordu takze zase zavola jeho zniceni a tak dokola\n\t\t\t\t$object->free();\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$this->$key = NULL;\n\t\t\t}\n\t\t}\n\n\t\tif (count($this->_associations)) {\n\t\t\tforeach ($this->_associations as $v) {\n\t\t\t\tif ($v) {\n\t\t\t\t\t$v->free();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t$this->_data = array();\n\n\t}", "protected function clear() {}", "function clear()\n {\n $this->tags = [];\n $this->extra = [];\n $this->user = null;\n }", "public function unset()\n {\n unset($this->value);\n }", "public function clear(): self;", "public function __destruct()\n {\n if ($this == self::$instance) {\n self::$instance = null;\n }\n }", "public function __destruct()\n {\n unset($this->binaryReaderEntity);\n }", "public function __destruct()\n {\n $this->configuration->eventDispatcher()->dispatch(new Destruct($this));\n }", "public function unload()\n {\n\n $this->synchronized = true;\n $this->id = null;\n $this->newId = null;\n $this->data = [];\n $this->savedData = [];\n $this->orm = null;\n\n $this->multiRef = [];\n $this->i18n = null;\n\n }", "public function destroy()\n {\n $this->items = array();\n }", "public function __destruct() {\n \n /*\n * a non-persistant DB connection should be disconnected here, e.g. for MySQL using mysql_close($this->connection)\n */\n trace('***** '.__CLASS__.' object destroyed. *****');\n \n }", "public function clear()\n {\n $this->id = null;\n $this->name = null;\n $this->is_active = null;\n $this->is_closed = null;\n $this->from_date = null;\n $this->to_date = null;\n $this->sortable_rank = null;\n $this->alreadyInSave = false;\n $this->alreadyInValidation = false;\n $this->alreadyInClearAllReferencesDeep = false;\n $this->clearAllReferences();\n $this->applyDefaultValues();\n $this->resetModified();\n $this->setNew(true);\n $this->setDeleted(false);\n }", "public function __destruct() {\n echo $this->name . \" is being destroyed :( <br>\";\n }", "function clear()\n \t{\n \t\tforeach ($this as &$value) \n \t\t $value = null;\n \t}", "function __destruct() {\n\t\t\tunset($this->db);\n\t\t}", "function __destruct() {\n $this->Disconnect();\n unset($this);\n }", "function __destruct() {\n $this->Disconnect();\n unset($this);\n }", "public function __unset($property) {\n\t\tif (strpos($property, 'source') === 0) {\n\t\t\t$property = lcfirst(substr($property, 6));\n\t\t\tif ($property === '') {\n\t\t\t\tunset($this->bean->source);\n\t\t\t} else {\n\t\t\t\tunset($this->source->$property);\n\t\t\t\t$this->bean->setMeta('tainted', true);\n\t\t\t}\n\t\t} elseif (strpos($property, 'remote') === 0) {\n\t\t\t$property = lcfirst(substr($property, 6));\n\t\t\tif ($property === '') {\n\t\t\t\tunset($this->bean->target);\n\t\t\t} else {\n\t\t\t\tunset($this->remote->$property);\n\t\t\t\t$this->bean->setMeta('tainted', true);\n\t\t\t}\n\t\t\t//Temporary properties are kept in the object, and not written to the database.\n\t\t} elseif (strpos($property, 'temp') === 0) {\n\t\t\t$property = lcfirst(substr($property, 4));\n\t\t\tunset($this->tempProperties[$property]);\n\t\t} else {\n\t\t\tif (isset($this->properties[$property])) {\n\t\t\t\tif ($this->loadedProperties === false) {\n\t\t\t\t\t$this->loadProperties();\n\t\t\t\t}\n\t\t\t\tunset($this->properties[$property]);\n\t\t\t\t$this->bean->setMeta('tainted', true);\n\t\t\t}\n\t\t\tif (isset($this->bean->$property)) {\n\t\t\t\tunset($this->bean->$property);\n\t\t\t}\n\t\t}\n\t}", "function __destruct()\n {\n $this->db = null;\n static::$instance = null;\n }", "public function reset() {\n\t\t// Get the default values for the class from the table.\n\t\tforeach ($this->getFields() as $k => $v) {\n\t\t\t// If the property is not private, reset it.\n\t\t\tif (strpos($k, '_') !== 0) {\n\t\t\t\t$this->$k = NULL;\n\t\t\t}\n\t\t}\n\t}", "protected function __del__() { }", "public function clean(): self\n {\n $this->storage = [];\n return $this;\n }", "public function clear()\n {\n if (null !== $this->aCakeType) {\n $this->aCakeType->removeArticle($this);\n }\n if (null !== $this->aShape) {\n $this->aShape->removeArticle($this);\n }\n $this->article_id = null;\n $this->description = null;\n $this->price = null;\n $this->creation = null;\n $this->visible = null;\n $this->shape_id = null;\n $this->cake_type_id = null;\n $this->alreadyInSave = false;\n $this->clearAllReferences();\n $this->resetModified();\n $this->setNew(true);\n $this->setDeleted(false);\n }", "public function __destroy()\n\t{\n\t\t$this->Obj_Doc->disconnectWorksheets();\n\t\tunset($this->Obj_Doc);\n\t\t$this->Obj_Doc = false;\n\t}", "function __destruct()\n\t{\n\t\t$this->id = NULL;\n\t\t$this->name = NULL;\t\n\t\t$this->email =NULL;\t\n\t\t$this->balance = NULL;\n\t}" ]
[ "0.77053636", "0.7522202", "0.733787", "0.72088313", "0.72088313", "0.7208302", "0.71409816", "0.7081025", "0.7078832", "0.7072388", "0.7037601", "0.7029224", "0.701855", "0.697838", "0.68256205", "0.68089914", "0.68046916", "0.67891526", "0.67224145", "0.671505", "0.6706799", "0.6701291", "0.66857547", "0.66706586", "0.66587025", "0.66221464", "0.6577915", "0.65626967", "0.6547114", "0.6532827", "0.65181255", "0.6517308", "0.64960563", "0.64945716", "0.6467217", "0.64664197", "0.64115155", "0.6400386", "0.6399263", "0.639415", "0.63834673", "0.6381441", "0.63789064", "0.6356404", "0.6353115", "0.6346462", "0.6319346", "0.63176966", "0.6307337", "0.6300788", "0.6288791", "0.6279367", "0.6247662", "0.62462395", "0.6238591", "0.6238591", "0.62371874", "0.62337947", "0.62321", "0.6228515", "0.62187034", "0.62155753", "0.62124264", "0.61681914", "0.61608064", "0.61532027", "0.61521626", "0.61387616", "0.6137583", "0.6132405", "0.6126291", "0.61202455", "0.6114979", "0.6110578", "0.61084086", "0.6094117", "0.6066999", "0.606212", "0.604655", "0.604557", "0.6037702", "0.6028577", "0.6026628", "0.6024437", "0.6016635", "0.60139424", "0.60092217", "0.60088015", "0.60086155", "0.6005627", "0.60039544", "0.60039544", "0.5996098", "0.59947723", "0.5980457", "0.5979596", "0.597226", "0.59465355", "0.59313256", "0.5924018" ]
0.6508619
32
Create an object to handle response from api.
public static function fromCommand(OperationCommand $command) { $data = @unserialize( (string) $command ->getResponse() ->getBody() ); if (is_null($data)) { $data = array(); } return new self( (array) $data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract function parse_api_response();", "public function get_response_object()\n {\n }", "static function parseResponse(string $data): ApiResponse\n {\n $obj = new static;\n $obj->setData($data);\n return $obj;\n }", "public function createResponse()\n {\n return new Response;\n }", "protected function _getResponse() {\n\t\treturn new Response;\n\t}", "function response() {\n return new Response;\n }", "public function createResponse(): IResponse;", "public function __construct()\n {\n $this->response = new Response();\n }", "public static function response(): Response\n {\n return new Response;\n }", "public function createResponse()\n {\n return new GuzzleResponse();\n }", "protected function createHttpResponse()\n {\n return new Response();\n }", "protected function asObject()\n\t{\n\t\treturn \\json_decode($this->response);\n\t}", "protected function getResponseFactory()\n {\n }", "public function __construct(Response $response)\n {\n $decoded = json_decode($response->getBody());\n\n //If things did not go well.\n if ($response->getStatusCode() >= 400 && $response->getStatusCode() < 600) {\n $this->success = false;\n\n if (isset($decoded->error)) {\n $this->errors = $decoded->error;\n }\n\n if (!$this->errors) {\n // API calls don't always provide an error :(\n $this->errors[] = 'An error occurred, however, no error message was given. Use the response body, HTTP status code and URL to help troubleshoot the issue.';\n }\n\n //If things went well.\n } else {\n $this->body = $decoded;\n }\n\n $this->statusCode = $response->getStatusCode();\n\n //DME's request limit meta data.\n if (isset($response->getHeaders()['x-dnsme-requestId'])) {\n $this->requestId = $response->getHeaders()['x-dnsme-requestId'];\n }\n\n if (isset($response->getHeaders()['x-dnsme-requestsRemaining'])) {\n $this->requestsRemaining = $response->getHeaders()['x-dnsme-requestsRemaining'];\n }\n\n if (isset($response->getHeaders()['x-dnsme-requestLimit'])) {\n $this->requestLimit = $response->getHeaders()['x-dnsme-requestLimit'];\n }\n\n if(!$this->success){\n \tthrow new ResultErrorException($this);\n }\n }", "public function makeResponse(): ResponseInterface;", "protected function construct_response()\n {\n $this->feedback['ok'] = $this->ok;\n $this->feedback['code'] = $this->code;\n $this->feedback['resource'] = $this->resource;\n }", "public function __construct($response){\n \n $this->_helper = new Helper();\n \n $this->_response = $response;\n \n }", "public function getResponse() {}", "public function getResponse() {}", "public function toObject(): object\n {\n $body = (string) $this->response->getBody();\n\n return json_decode($body) ?? (object) [];\n }", "public function initialize()\n {\n parent::initialize();\n\n // Constroi a resposta da API\n $this->response = new stdClass();\n $this->response->errorCode = 0;\n $this->response->errorMessage = '';\n $this->response->successMessage = '';\n $this->response->data = NULL;\n }", "public function & GetResponse ();", "function createResponse ( $from, $action=\"Process Request\", $api_key=null )\n {\n $response = new SyndicationResponse();\n $response->raw = $from;\n\n /// an exception was thrown\n if ( is_subclass_of($from,'Exception') )\n {\n $response->success = false;\n $response->status = $from->getCode();\n $response->format = 'Exception';\n $response->addMessage(array(\n 'errorCode' => $from->getCode(),\n 'errorMessage' => $from->getMessage(),\n 'errorDetail' => \"{$action} Exception\"\n ));\n return $response;\n\n /// we got a response from the server\n } else if ( is_array($from)\n && !empty($from['http'])\n && !empty($from['format']) )\n {\n $status = isset($from['http']['http_code']) ? intval($from['http']['http_code']) : null;\n $response->status = $status;\n /// SUCCESS\n if ( $status>=200 && $status<=299 )\n {\n $response->success = true;\n /// CLIENT SIDE ERROR\n } else if ( $status>=400 && $status<=499 ) {\n /// BAD API KEY\n if ( $status == 401 ) {\n $errorDetail = \"Unauthorized. Check API Key.\";\n /// VALID URL but specific id given does not exist\n } else if ( $status == 404 && !empty($api_key) ) {\n $errorDetail = \"Failed to {$action}. {$api_key} Not Found.\";\n /// Error in the request\n } else {\n $errorDetail = \"Failed to {$action}. Request Error.\";\n }\n $response->success = false;\n $response->addMessage(array(\n 'errorCode' => $status,\n 'errorMessage' => $this->httpStatusMessage($status),\n 'errorDetail' => $errorDetail\n ));\n /// SERVER SIDE ERROR\n } else if ( $status>=500 && $status<=599 ) {\n $response->success = false;\n $response->addMessage(array(\n 'errorCode' => $status,\n 'errorMessage' => $this->httpStatusMessage($status),\n 'errorDetail' => \"Failed to {$action}. Server Error.\"\n ));\n }\n\n if ( $from['format']=='json' )\n {\n /// for any json response\n /// [meta] and [results] expected back from api\n /// [meta][messages] should be consumed if found\n /// [meta][pagination] should be consumed if found\n /// [message] was changed to plural, check for both for now just incase\n\n /// look for meta\n if ( isset($from['meta']) )\n {\n if ( isset($from['meta']['pagination']) )\n {\n $response->addPagination($from['meta']['pagination']);\n }\n if ( isset($from['meta']['messages']) )\n {\n $response->addMessage($from['content']['meta']['messages']);\n }\n if ( isset($from['meta']['message']) )\n {\n $response->addMessage($from['content']['meta']['message']);\n }\n } else if ( isset($from['content']) && isset($from['content']['meta']) ) {\n if ( isset($from['content']['meta']['pagination']) )\n {\n $response->addPagination($from['content']['meta']['pagination']);\n }\n if ( isset($from['content']['meta']['messages']) )\n {\n $response->addMessage($from['content']['meta']['messages']);\n }\n if ( isset($from['content']['meta']['message']) )\n {\n $response->addMessage($from['content']['meta']['message']);\n }\n }\n /// look for results\n if ( isset($from['content']) )\n {\n if ( isset($from['content']['results']) )\n {\n $response->results = (array)$from['content']['results'];\n } else {\n $response->results = (array)$from['content'];\n }\n }\n $response->format = 'json';\n return $response;\n } else if ( $from['format']=='image' ) {\n $response->format = 'image';\n\n /// a single string: base64 encoded image : imagecreatefromstring?\n $response->results = $from['content'];\n return $response;\n /// unknown format\n } else {\n $response->format = $from['format'];\n /// a single string : html : filtered_html?\n $response->results = $from['content'];\n return $response;\n }\n }\n /// we got something weird - can't deal with this\n $response->success = false;\n $status = null;\n if ( is_array($from) && !empty($from['http']) && isset($from['http']['http_status']) )\n {\n $status = $from['http']['http_status'];\n }\n $response->addMessage(array(\n 'errorCode' => $status,\n 'errorMessage' => $this->httpStatusMessage($status),\n 'errorDetail' => \"Unknown response from Server.\"\n ));\n return $response;\n }", "abstract protected function createResponse(GuzzleResponse $response);", "public function getResponse(): ResponseInterface;", "public function getResponse(): ResponseInterface;", "public function prepareResponse();", "public function _response($response) {\n\t\treturn $this->_instance($this->_classes['response'], array(\n\t\t\t'body' => $response\n\t\t));\n\t}", "public static function create(\\GuzzleHttp\\Psr7\\Response $response)\n {\n // - validate body\n $data = json_decode($response->getBody(), true, 512, JSON_BIGINT_AS_STRING);\n if (empty($data)) {\n throw new ApiException('Invalid response body');\n }\n // - validate internal data\n if (isset($data['status'])) {\n if ($data['status'] != 0) {\n throw new ApiException('Remote error: ' .\n (isset($data['status_message']) ? $data['status_message'] : '-'),\n $data['status']);\n }\n $item = new self();\n $item->data = $data;\n return $item;\n }\n throw new ApiException('Invalid response json');\n }", "public function __construct()\n {\n return response([],400);\n }", "public function getResponse($response) {\r\n\r\n\r\n }", "abstract public function response();", "public function __construct(Response $guzzleResponse)\n {\n // Save the guzzle response in case an advanced user wants to access it\n $this->guzzleResponse = $guzzleResponse;\n\n // Save the response contents (because it's a stream that can't be re-read)\n $this->guzzleBody = $guzzleResponse->getBody()->getContents();\n\n // Decode the JSON response\n $content = json_decode($this->guzzleBody, true);\n\n // This will be true if there is no JSON to parse or if PHP cannot parse the\n // given JSON\n if($content == null)\n {\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'Malformed JSON response from API server'\n );\n }\n\n // Check that all required key's exist in the response\n foreach(self::REQUIRED_KEYS as $key) {\n if(!array_key_exists($key, $content))\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'API server response missing expected field: '.$key\n );\n }\n\n // Pull out generic response information\n $this->version = $content['version'];\n $this->id = $content['id'];\n $this->ts = $content['ts'];\n $this->type = $content['type'];\n\n // Check HTTP response code for problems\n $success = [200, 201];\n $error = [400, 401, 402, 404, 405, 406, 500];\n $rateLimit = 429;\n if(in_array($guzzleResponse->getStatusCode(), $success)) {\n // Check that the response type is in our type mappings\n if(array_key_exists($this->type, self::RESPONSE_TYPES)) {\n // Check that the data field is there\n if(array_key_exists($this->type, $content))\n $this->responseData = $content[$this->type];\n else\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'JSON response does not contain field of type: \"' . $this->type . '\"'\n );\n }\n else {\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'JSON response contains unknown type: \"' . $this->type . '\"'\n );\n }\n }\n else if($guzzleResponse->getStatusCode() == $rateLimit) {\n if(array_key_exists('rate_limit', $content) &&\n array_key_exists('requests', $content['rate_limit']) &&\n array_key_exists('max', $content['rate_limit']) &&\n array_key_exists('retryAfter', $content['rate_limit']))\n {\n throw new SmartwaiverRateLimitException($guzzleResponse, $this->guzzleBody, $content);\n } else {\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'Malformed rate limit response'\n );\n }\n }\n else if(in_array($guzzleResponse->getStatusCode(), $error)) {\n // Check that a message exists\n if(array_key_exists('message', $content))\n throw new SmartwaiverHTTPException($guzzleResponse, $this->guzzleBody, $content);\n // If not, throw an error, this is unexpected\n else\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'Error response does not include message'\n );\n }\n else {\n // Unknown response from the API server, throw an exception\n throw new SmartwaiverSDKException(\n $guzzleResponse,\n $this->guzzleBody,\n 'Unknown HTTP code returned: ' . $guzzleResponse->getStatusCode()\n );\n }\n }", "public function __construct($response)\n {\n $this->init($response);\n\n }", "public function __construct($response)\n {\n $this->response = $response;\n }", "public function __construct($response)\n {\n $this->response = $response;\n }", "public function __construct($response)\n {\n $this->response = $response;\n }", "public function __construct($response)\n {\n $this->response = $response;\n }", "public function getResponse() {\n }", "protected function _response() {}", "function get_obj()\n {\n $object = new ApiRest;\n return $object;\n }", "public function getResponseObject()\n {\n return $this->response_object;\n }", "function api_response($data = null)\n {\n if (null === $data) {\n $data = 'Success';\n }\n return new ApiResponse($data);\n }", "public function __construct(Response $response)\n {\n $this->response = $response;\n }", "public function parse()\r\n\t{\r\n\t\tif(is_string($this->_raw)) {\r\n\t\t\t$response = self::toArray($this->_format, $this->_raw);\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$response = $this->_raw;\r\n\t\t}\r\n\r\n\t\tif(!empty($response['error_code'])) {\r\n\t\t\tthrow new MediaMonks_Service_Hyves_Response_Exception($response['error_message'], $response['error_code']);\r\n\t\t}\r\n\t\t\r\n\t\tif(null == $this->_method && !empty($response['method'])) {\r\n\t\t\t$this->_method = $response['method'];\r\n\t\t\tunset($response['method']);\r\n\t\t}\r\n\t\t\r\n\t\t$this->_info = $response['info'];\r\n\t\tunset($response['info']);\r\n\t\t\r\n\t\t$this->_body = $response;\r\n\t\t\r\n\t\t// pagination\r\n\t\tif(!empty($this->_info['totalresults'])) {\r\n\t\t\t$this->_paginated = true;\r\n\t\t}\r\n\t\t\r\n\t\t$this->_parsed = true;\r\n\t\treturn $this;\r\n\t}", "abstract public function responseProvider();", "public function getResponse()\n {\n }", "public function createResponse(): ResponseInterface {\n return $this->responseFactory->createResponse()->withHeader('Content-Type', 'application/json');\n }", "abstract public function createResponse(AbstractRequestClient $request);", "abstract public function prepare_response( $object, $context );", "public function __construct($response)\n {\n $this->transformResultData($response->results);\n\n }", "public function toResponse()\n {\n $response = new ApiResponse();\n try {\n $this->execute();\n if ($this->code !== 200) {\n $messages = $this->errors();\n } else {\n $messages = $this->messages();\n }\n $response = $response->withParams([\n 'code' => $this->code(),\n 'data' => $this->data(),\n 'message' => $messages,\n ]);\n if ($this->extra->count()) {\n $response = $response->withParams($this->extra->toArray());\n }\n\n return $response;\n } catch (Exception $exception) {\n return $this->handleExceptions($response, $exception);\n }\n }", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function toResponse()\n {\n $response = new ApiResponse();\n try {\n $data = $this->data();\n if (empty($data)) {\n $messages = $this->errors();\n } else {\n $messages = $this->messages();\n }\n\n return $response->withParams([\n 'code' => $this->code(),\n 'data' => $data,\n 'message' => $messages,\n ]);\n } catch (Exception $exception) {\n return $this->handleExceptions($response, $exception);\n }\n }", "protected function parseResponse()\n {\n // get the status code from response.\n $statusCode = $this->httpResponse->getStatusCode();\n\n // set as error, if http status code is not between 200 and 299 (inclusive).\n $this->networkError = !($statusCode >= 200 && $statusCode <= 299);\n\n // decode the response body.\n $body = $this->decodeBody();\n\n // stop when no body is present.\n if ($body) {\n // parse the response id from the body.\n $this->id = (int) array_get($body, 'id', null);\n\n // set as error when there is a an error key and it's not null.\n $this->isError = array_get($body, 'error', null) !== null;\n\n // parse the response data, from result or error.\n $this->data = collect(array_get($body, $this->isError ? 'error' : 'result', []));\n }\n\n // just return the response body.\n return $this->body;\n }", "function get_response() {\n return $this->response;\n }", "private function response() {\n if ($this->responseStatus !== 200) {\n $this->request['format'] = self::DEFAULT_RESPONSE_FORMAT;\n }\n $method = $this->request['format'] . 'Response';\n $this->response = array('status' => $this->responseStatus, 'body' => $this->$method());\n return $this;\n }", "public function __construct($response)\n {\n $this->address = $response['address'];\n $this->url = $response['url'];\n $this->id = $response['id'];\n }", "protected function getCreateResponse()\n\t{\n\t\treturn new Api\\Response\\Create();\t\n\t}", "public function handleRequests() {\r\n $response = null;\r\n try {\r\n $urlArray = $this->uri->uri_to_assoc(3);\r\n if (array_key_exists('login', $urlArray)) {\r\n $response = self::postLogin();\r\n } else {\r\n $login = self::clientLogin();\r\n $response = self::instantiateRequestedClass($urlArray, $login);\r\n }\r\n } catch (Exception $ex) {\r\n $response = $this->apiv1_core->errorResponse($ex->getCode(), $ex->getMessage());\r\n }\r\n\r\n $httpcode = substr($response['code'], 0, 3);\r\n\r\n $name = '';\r\n foreach ($urlArray as $key => $value) {\r\n $this->$key = $value;\r\n $name = ucfirst($key);\r\n }\r\n $method = strtolower($this->input->server('REQUEST_METHOD')) . $name;\r\n $reqParam = $this->input->get() ? $this->input->get() : file_get_contents(\"php://input\");\r\n\r\n $msg = array(\r\n 'resourceURL' => $this->uri->assoc_to_uri($urlArray),\r\n 'className' => $response['className'],\r\n 'methodName' => $method,\r\n 'requestJSON' => json_encode($reqParam),\r\n 'responseHTTP' => $httpcode,\r\n 'responseJSON' => ($response['message']) ? json_encode($response) : json_encode($response['res']),\r\n );\r\n\r\n $logCid = isset($urlArray['account']) ? $urlArray['account'] : NULL;\r\n dblog_message(LOG_LEVEL_INFO, LOG_TYPE_API, \"API: \" . \r\n $this->input->server('REQUEST_METHOD') . \" \" .\r\n $this->uri->assoc_to_uri($urlArray) . \"\\n\" . print_r($msg, TRUE), $logCid);\r\n\r\n header(\"Content-Type: application/json\");\r\n header(\"HTTP/1.1 $httpcode\", true, $httpcode);\r\n\r\n if ($response['message']) {\r\n echo json_encode($response);\r\n } else {\r\n echo json_encode($response['res']);\r\n }\r\n return;\r\n }", "public function getResponseParser()\n {\n return new ResponseParser();\n }", "private function getResponse() {\n $this->response['status_code'] = $this->status->getStatusCode();\n $this->response['reason_phrase'] = $this->status->getReasonPhrase();\n \n $this->readHeaders();\n }", "private function parse()\n {\n if ($this->isError()) {\n // error parsing\n if (empty($this->body) || !isset($this->body['errors'])) {\n // response body isn't an error object, return a custom one\n $error = new Entity\\Error();\n $error->message = \"Error $this->http_status\";\n $error->name = \"INVALID REQUEST\";\n $error->at = \"\";\n $this->objects[] = $error;\n } else {\n // parse error\n $errors = $this->body['errors'];\n foreach ($errors as $error) {\n $this->objects[] = Entity\\Error::parse($error);\n }\n }\n } else if (isset($this->body['card'])) {\n // card parsing\n $cards = $this->body['card'];\n foreach ($cards as $card) {\n $this->objects[] = Entity\\Card::parse($card);\n }\n } else if (isset($this->body['paymentmethod'])) {\n // payment parsing\n $this->objects[] = Entity\\Payment::parse($this->body);\n if (isset($this->body['subscription_plan'])) {\n // subscription also found, payment is a subscription\n $this->objects[] = Entity\\Subscription::parse($this->body['subscription_plan']);\n }\n } else if (isset($this->body['vendor'])) {\n // vendor parsing\n $this->objects[] = Entity\\Vendor::parse($this->body['vendor']);\n } else if (isset($this->body['item'])) {\n // item parsing\n $this->objects[] = Entity\\Item::parse($this->body['item']);\n } else if (isset($this->body['refunded'])) {\n // refund parsing, same as payment\n $this->objects[] = Entity\\Payment::parse($this->body);\n } else if (isset($this->body['subscription_plan'])) {\n // subscription parsing\n $this->objects[] = Entity\\Subscription::parse($this->body['subscription_plan']);\n } else if (isset($this->body['deleted'])) {\n // nothing to return\n } else {\n throw new \\RuntimeException('Could not recognize response type');\n }\n }", "public function response(): ResponseContract;", "public function jsonToObject(): ?ViaCepApi {\n if ($this->responseType == \"json\" && $this->response != \"[]\") {\n $this->responseType = \"object\";\n $this->response = (object) json_decode($this->response);\n }\n \n return $this; \n }", "public function fromAPI($data);", "public function deserializeResponse(string $response): Response;", "private function createResponse(){\r\n #scraping metatag to get IMAGE TITLE and FULL PATH INC FILE NAME \r\n $metaTag = get_meta_tags($this->url);\r\n\r\n \r\n $this->setImageTitle($metaTag[\"sailthru_title\"]); #setting up title\r\n $this->setFileName($metaTag[\"sailthru_image_full\"]); #setting up full file name\r\n $this->setDimensions(); #setting up image dimensions\r\n \r\n $this->setFileSize(); #setting up file size in kB\r\n \r\n #create response array based on properties\r\n $array = array('title' => $this->imageTitle,\r\n 'dimensions' => $this->imageDimensions,\r\n 'filename' => $this->getPlainFileName(),\r\n 'file size in kB' => $this->fileSize\r\n );\r\n \r\n return $array;\r\n }", "public function getResponse() {\n\t}", "public function test_can_create_psr7_response(): void {\n\n\t\t$response = HTTP_Helper::response( array( 'key' => 'test_VALUE' ), 500 );\n\n\t\t$body = json_decode( (string) $response->getBody(), true );\n\n\t\t$this->assertInstanceOf( ResponseInterface::class, $response );\n\t\t$this->assertIsArray( $body );\n\t\t$this->assertArrayHasKey( 'key', $body );\n\t\t$this->assertEquals( 'test_VALUE', $body['key'] );\n\t\t$this->assertEquals( 500, $response->getStatusCode() );\n\t}", "public function __construct(\\GuzzleHttp\\Message\\ResponseInterface $response)\n {\n $this->http_status = intval($response->getStatusCode());\n $this->is_error = !($this->http_status >= 200 && $this->http_status < 300);\n try {\n $this->body = $response->json();\n }\n catch (\\GuzzleHttp\\Exception\\ParseException $e) { }\n \n $this->parse();\n }", "public function create(): ResponseInterface\n\t{\n\t\t$this->content = [];\n\t}", "public function createFromResponse(): Article\n {\n return new Article((array) $this);\n }", "public function response($response)\n {\n\n return new Response($response);\n\n }", "public static function createFromResponse(ResponseInterface $response, ApiProviderInterface $api, ApiResourceInterface $owner = null)\n {\n $data = json_decode((string) $response->getBody(), true);\n\n return new static($api, $data, $owner);\n }", "public function getResponseObject()\n {\n return $this->responseObject;\n }", "public function getResponseObject()\n {\n return $this->responseObject;\n }", "public function getResponseObject()\n {\n return $this->responseObject;\n }", "public function rest_api_init( $response ) {\n\t\t$this->is_api_request = true;\n\n\t\treturn $response;\n\t}", "function api_create_response($payload, $status, $message) {\n if (is_numeric($payload)) {\n\n if ($payload == 1)\n $payload = array();\n elseif ($payload == 2)\n $payload = new \\stdClass();\n }\n\n $response_array = array('payload' => $payload, 'status' => $status, 'message' => $message);\n return $response_array;\n}", "protected function buildResponse(): self\n {\n $verb = $this->apiCall['verb'] ?? 'get';\n $this->response = $this->client->$verb(\"{$this->apiCall['endpoint']}?{$this->getQuery()}\");\n\n return $this;\n }", "public function __CONSTRUCT($db) {\r\n $this->db = $db;\r\n $this->response = new Response();\r\n }", "public function __CONSTRUCT($db) {\r\n $this->db = $db;\r\n $this->response = new Response();\r\n }", "function makeResponse($response)\n {\n $result = current(Util::toArray($response));\n\n $response = new Response([\n 'raw_body' => $result,\n\n ## get response message as array\n 'default_expected' => function($rawBody) use ($result) {\n return $result;\n }\n ]);\n // TODO handle exceptions\n\n /** @var iResponse $response */\n $response = $this->exceptionHandler($response);\n \n\n return $response;\n }", "public function getResponseInstance(){\n\t\treturn ControllerResponse::getInstance();\n\t}", "function __construct(ResponseFactory $response)\n {\n $this->response = $response;\n }", "public function prepare()\n {\n $this->status = $this->response->getStatusCode();\n\n $rawResponseData = $this->response->getBody()->getContents();\n\n $this->body = $rawResponseData ? \\GuzzleHttp\\json_decode($rawResponseData, true) : '';\n\n $this->errors = isset($this->body['errors']) ? $this->body['errors'] : [];\n\n if ($this->throwException && (substr($this->status, 0, 1) != 2)) {\n $this->throwException($this->status, $this->errors);\n }\n\n //Set data\n if ($this->body) {\n //This happens when array was expected but it is empty\n if (empty($this->body['data'])) {\n $this->data = collect([]);\n } else {\n $document = Document::createFromArray($this->body);\n $hydrator = new ClassHydrator();\n $hydrated = $hydrator->hydrate($document);\n $this->data = is_array($hydrated) ? collect($hydrated) : $hydrated;\n }\n }\n\n //Set meta\n if (isset($this->body['meta'])) {\n $this->meta = $this->body['meta'];\n }\n }", "public function me():ResponseInterface;", "public function createResponse() {\n\t\t\t$query = \"SELECT * FROM $this->table_name WHERE name=:name AND drink=:drink\";\n\n\t\t\t// prepare \n\t\t\t$stmt = $this->conn->prepare($query);\n\n\t\t\t// bind values\n\t\t\t$stmt->bindParam(':name', $this->name);\n\t\t\t$stmt->bindParam(':drink', $this->drink);\n\n\t\t\t$stmt->execute();\n\n\t\t\t// get retrieved row\n\t\t\t$row = $stmt->fetch(PDO::FETCH_ASSOC);\n\n\t\t\t// set values to object properties\n\t\t\t$this->id = $row['id'];\n\t\t\t$this->name = $row['name'];\n\t\t\t$this->drink = $row['drink'];\n\t\t}", "public function test_response() \n\t{\n\t\treturn CCResponse::create( 'Callbacks are pretty cool' );\n\t}", "public function getResponseParser(): ResponseParserInterface\n {\n return new ResponseParser();\n }" ]
[ "0.7185769", "0.71777177", "0.7118141", "0.7078582", "0.69274795", "0.68896157", "0.6834795", "0.6829799", "0.67860204", "0.6769813", "0.67430514", "0.66455287", "0.6639601", "0.65706694", "0.6562243", "0.65071595", "0.6505292", "0.6487715", "0.6487715", "0.6480839", "0.6480049", "0.6457218", "0.63937694", "0.63801485", "0.63637656", "0.63637656", "0.6349023", "0.63415843", "0.633968", "0.6336051", "0.63169247", "0.6315132", "0.63150764", "0.63084877", "0.6307963", "0.6307963", "0.6307963", "0.6307963", "0.626869", "0.62639827", "0.62535596", "0.6239038", "0.62215185", "0.62209684", "0.62171847", "0.62091684", "0.61716443", "0.6157422", "0.61458087", "0.61351025", "0.61336577", "0.61221707", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6107896", "0.6084614", "0.60688287", "0.6067991", "0.60653573", "0.606196", "0.60612154", "0.6056357", "0.6049279", "0.60453427", "0.6032107", "0.60250217", "0.60228086", "0.6011959", "0.6011597", "0.60105693", "0.5993772", "0.5990806", "0.5968133", "0.5956518", "0.59549993", "0.59436214", "0.59398913", "0.5935552", "0.5935552", "0.5935552", "0.59333366", "0.59297127", "0.5929665", "0.59291744", "0.59291744", "0.59252566", "0.58803713", "0.5878907", "0.58656776", "0.5858309", "0.5846875", "0.58318967", "0.58259815" ]
0.0
-1
Pass data from api response.
public function __construct(array $data) { $this->data = $data; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract function parse_api_response();", "public function getResponseData();", "public function fromAPI($data);", "public function prepareResponse();", "private function response($data) {\n\t\treturn json_decode($data);\n\t}", "public function getResponse($response) {\r\n\r\n\r\n }", "function api_response($res)\n{\n $response_code = $res['code'];\n $response_data = $res['data'];\n\n header('Content-Type: application/json');\n if(DEBUG)\n {\n exit('<pre>' . print_r(\n array(\n 'response'=>$response_code,\n 'data'=>$response_data\n\n ),true));\n }\n exit(json_encode(\n array(\n 'response'=>$response_code,\n 'data'=>$response_data\n )\n ));\n}", "public static function getData($response)\n {\n return $response; //->data;\n }", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "public function handleResponse($data)\n {\n // Retrieve the specific request data\n $requestData = current($data->getReturnsArray());\n \n // Initialize the inventory response\n $inventoryResponse = new GetInventoryResponse();\n\n // Unmarshall the response\n $inventoryResponse->read($requestData);\n\n $this->setData($inventoryResponse);\n }", "public function requestData() {\n\t\t// Set up cURL \n\t\t$curl = curl_init($this->query); \n\t\tcurl_setopt($curl, CURLOPT_POST, false); \n\t\tcurl_setopt($curl, CURLOPT_RETURNTRANSFER, true);\n\t\t$response = curl_exec($curl);\n\t\tcurl_close($curl);\n\t\t\t\n\t\treturn $this->parseAPIResponse($response);\n\t}", "protected function _response() {}", "public function & GetResponse ();", "public function getResponse() {}", "public function getResponse() {}", "public function handleGetData()\n\t{\n\t\t$data = $this->getData();\n\t\t$options = $this->getOptions();\n\n\t\t$this->presenter->sendResponse(\n\t\t\tnew JsonResponse(\n\t\t\t\t[\n\t\t\t\t\t\"data\" => $data,\n\t\t\t\t\t\"options\" => $options,\n\t\t\t\t]\n\t\t\t)\n\t\t);\n\t}", "public function handleShowResponse(array $data) {\n\t\t$this->template->json = $data;\n\t\t$this->template->parsedResponse = $this->iqrfAppManager->parseResponse($data);\n\t\t$this->redrawControl('responseChange');\n\t}", "abstract protected function getReponseData() ;", "abstract public function response();", "public function getApiData();", "protected function _handleResponse(){\n $this->_results[] = array(\n 'http_code' => $this->getInfoHTTPCode(),\n 'response' => $this->getResponse(),\n 'server' => $this->getUrl()\n );\n }", "public function respond($data){\n\t\treturn $data;\n\t}", "protected function extractApiData() {\n\n foreach($this->apiData->items as $key => $value) { \n $key = $key + 1;\n $this->dataArray[$key]['id'] = $value->id;\n $this->dataArray[$key]['firstname'] = $value->firstname;\n $this->dataArray[$key]['lastname'] = $value->lastname;\n $this->dataArray[$key]['email'] = $value->email;\n $this->dataArray[$key]['dob'] = isset($value->dob) ? $value->dob : '';\n $this->dataArray[$key]['website_id'] = $value->website_id;\n $this->dataArray[$key]['store_id'] = $value->store_id;\n $this->dataArray[$key]['created_in'] = $value->created_in; \n $this->dataArray[$key]['group_id'] = $value->group_id; \n $this->dataArray[$key]['gender'] = $this->gender[$value->gender];\n $this->dataArray[$key]['address'] = $this->getAddress($value->addresses);\n }\n }", "function get_response() {\n return $this->response;\n }", "public function handleResponse($data)\n {\n // Retrieve the specific request data\n $requestData = current($data->getReturnsArray());\n\n // Initialize the rename pokemon response\n $setFavoritePokemonResponse = new SetFavoritePokemonResponse();\n\n // Unmarshall the response\n $setFavoritePokemonResponse->read($requestData);\n\n $this->setData($setFavoritePokemonResponse);\n }", "function deliver_response($api_response){\r\n \r\n // Set HTTP Response\r\n header('HTTP/1.1 200 OK');\r\n\r\n // Set HTTP Response Content Type\r\n header('Content-Type: application/json; charset=utf-8');\r\n \r\n // Format data into a JSON response\r\n $json_response = json_encode($api_response);\r\n\r\n // Deliver formatted data\r\n echo $json_response;\r\n \r\n // End script process\r\n exit;\r\n \r\n}", "function babeliumsubmission_get_response_data($responseid){\n Logging::logBabelium(\"Getting response data\");\n $g = $this->getBabeliumRemoteService();\n $data = $g->getResponseInformation($responseid);\n $captions = null;\n if(isset($data) && isset($data['subtitleId'])){\n $subtitleId = $data['subtitleId'];\n $mediaId = '';\n $captions = $g->getCaptions($subtitleId, $mediaId);\n }\n if (!$captions){\n return;\n }\n else{\n $exerciseRoles = $this->getExerciseRoles($captions);\n $recinfo = null;\n return $this->getResponseInfo($data, $captions, $exerciseRoles, $recinfo);\n }\n }", "public function processResponseData($rawResponseData);", "public function response($data){\n echo json_encode($data);\n }", "function getResponseData( $response ) {\n\t\t\n\t\tif ( is_array( $response ) && !empty( $response ) ) {\n\t\t\treturn $response;\n\t\t}\n\t}", "abstract public function responseProvider();", "public function getResponse() {\n }", "protected function response($data = NULL)\n {\n return API::response()->set_data($data);\n }", "function api_response($data = null)\n {\n if (null === $data) {\n $data = 'Success';\n }\n return new ApiResponse($data);\n }", "function getData() {\n return $this->body->getResponse();\n }", "public function get_response_object()\n {\n }", "function decodeResponse($method, $data) \n {\n return $data;\n }", "function deliver_response($format, $api_response)\n {\n\n // Define HTTP responses\n $http_response_code = array(200 => 'OK', 400 => 'Bad Request', 401 => 'Unauthorized', 403 => 'Forbidden', 404 => 'Not Found');\n\n // Set HTTP Response\n header('HTTP/1.1 ' . $api_response['status'] . ' ' . $http_response_code[$api_response['status']]);\n header('Content-Type: application/json; charset=utf-8');\n\n $json_response = json_encode($api_response);\n echo $json_response;\n exit;\n\n }", "protected function parseResponse()\n {\n $data = simplexml_load_string($this->body);\n \n $this->data = $data;\n }", "public function getResponse()\n {\n }", "abstract protected function updateResponse(Model $data);", "function prepData($responseCode,$data){\n header('Content-Type: application/json');\n echo json_encode($data);\n http_response_code($responseCode);\n }", "function api_response($res)\n{\nheader('Content-Type: application/json');\n if(ENABLE_DEBUG)\n {\n exit('<pre>' . print_r(\n $res,true));\n }\n exit(json_encode(\n $res\n ));\n}", "public function setApiData( array $data );", "public function populate(stdClass $response);", "protected function construct_response()\n {\n $this->feedback['ok'] = $this->ok;\n $this->feedback['code'] = $this->code;\n $this->feedback['resource'] = $this->resource;\n }", "public function set_response($response_data)\n\t{\n\t\t$this->response = (is_array($response_data))\n\t\t\t? json_encode($response_data)\n\t\t\t: $response_data;\n\t}", "public function response() {\n $response = (object)[\n 'count' => $this->response,\n 'errors' => $this->errors\n ];\n echo json_encode($response); \n }", "abstract public function processResponse($response);", "public function route_respond( $result_data ) {\n\t\t// Logic depends on the contents/state of result_data\n\t\tif ( !is_null( $result_data ) ) {\n\t\t\t// Check if we got an instance of one of our Api response classes\n\t\t\tif ( $result_data instanceof ApiResponse ) {\n\t\t\t\t$this->response->code( $result_data->get_code() );\n\t\t\t\t$this->response->status = $result_data->get_status();\n\t\t\t\t$this->response->message = $result_data->get_message();\n\t\t\t\t$this->response->more_info = $result_data->get_more_info();\n\t\t\t\t$this->response->data = $result_data->get_data();\n\n\t\t\t\tforeach( $result_data->get_headers() as $name => $value ) {\n\t\t\t\t\t$this->response->header( $name, $value );\n\t\t\t\t}\n\n\t\t\t\t// Ooo, we're a paged response?!\n\t\t\t\tif ( $result_data instanceof PagedApiResponse ) {\n\t\t\t\t\t// Add the paging data to our response data\n\t\t\t\t\t$this->response->paging = $result_data->get_formatted_paging_data();\n\n\t\t\t\t\t// Build a resources object for paging links/refs\n\t\t\t\t\tif ($this->show_paging_resources) {\n\t\t\t\t\t\t$this->response->paging->resources = (object) array();\n\n\t\t\t\t\t\tif ($result_data->get_has_next_page()) {\n\t\t\t\t\t\t\t// Merge our next page number into our query vars\n\t\t\t\t\t\t\t$query_vars = array_merge(\n\t\t\t\t\t\t\t\t$_GET,\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t'page' => ($this->response->paging->page + 1)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\n\t\t\t\t\t\t\t$this->response->paging->resources->next = $this->app->parse(\n\t\t\t\t\t\t\t\t'{APP_URL}{ENDPOINT}?'\n\t\t\t\t\t\t\t\t. http_build_query($query_vars)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif ($this->response->paging->page > 1) {\n\t\t\t\t\t\t\t// Merge our next page number into our query vars\n\t\t\t\t\t\t\t$query_vars = array_merge(\n\t\t\t\t\t\t\t\t$_GET,\n\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t'page' => ($this->response->paging->page - 1)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t);\n\n\t\t\t\t\t\t\t$this->response->paging->resources->previous = $this->app->parse(\n\t\t\t\t\t\t\t\t'{APP_URL}{ENDPOINT}?'\n\t\t\t\t\t\t\t\t. http_build_query($query_vars)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// True response\n\t\t\telseif ( $result_data === true ) {\n\t\t\t\t// True case WITHOUT any returned data\n\t\t\t}\n\t\t\telseif ( $result_data === false ) {\n\t\t\t\t// Throw an exception\n\t\t\t\tthrow new InvalidApiParameters();\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\t// The response is null, throw an exception\n\t\t\tthrow new ObjectNotFound();\n\t\t}\n\n\t}", "public function getResponse() {\n\t}", "protected abstract function prepareResponse(stubResponse $response);", "public function get_response()\n {\n return $this->response; \n }", "public function getAuthDataFromResponse(): array;", "function handleResponse($response) : void\n{\n print_r(json_encode($response));\n die();\n}", "protected function found()\n {\n $this->response = $this->response->withStatus(200);\n $this->jsonBody($this->payload->getOutput());\n }", "public function getData()\n {\n return (object) $this->_response;\n }", "public function setResponse(Response $response) {}", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function getResponse();", "public function set_response($response_data)\n\t{\n\t\t$this->response = (is_array($response_data))\n\t\t\t? $this->array2json($response_data)\n\t\t\t: $response_data;\n\t}", "protected function bindResponse()\r\n {\r\n $responseArray = explode( '&', $this->responseString );\r\n \r\n foreach ( $responseArray as $value ){\r\n $pair = explode( '=', $value );\r\n $this->$pair[0] = $pair[1];\r\n }\r\n }", "function deliverResponse($status,$status_msg,$data){\n $response['status'] = $status;\n $response['status_msg'] = $status_msg;\n $response['data'] = $data;\n\n $json_response = json_encode($response);\n echo $json_response;\n}", "public function handleData();", "public function setResponse() {\n }", "public function getData($data) { \n\t\t\t\t$this->sponsor = $data[0]; \n\t\t\t\t$this->amount = $data[1];\n\t\t\t}", "function deliver_response(){\n\n // --- Step 1: Initialize variables and functions\n //\n // Deliver HTTP Response\n // The desired HTTP response content type: [json, html, xml]\n // The desired HTTP response data\n\n\n header('HTTP/1.1 '.$this->response['status'] . // Set HTTP Response\n ' '.$this->http_response_code[$this->response['status'] ]);\n header('Content-Type: application/json; charset=utf-8'); // Set HTTP Response Content Type\n $json_response = json_encode($this->response['data']); // Format data into a JSON response\n echo $json_response; // Deliver formatted data\n }", "private function processResponse(IspapiApi $api, IspapiResponse $response)\n {\n $this->logRequest($api, $response);\n\n // Set errors, if any\n if ($response->response()['CODE'] != 200) {\n $errors = $response->response()['DESCRIPTION'] ? $response->response()['DESCRIPTION'] : [];\n $errors = (object)$errors;\n $this->Input->setErrors(['errors' => $errors]);\n }\n }", "public function response ();", "protected function process_response() {\n\t\t\t$this->response['response']['Message'] = isset($this->response['response']['Message']) ? $this->response['response']['Message'] : '';\n\t\t\t$this->response['response']['error'] = (strpos(strtolower($this->response['response']['Message']), 'invalid') !== false) ? true : $this->response['response']['error'];\n\t\t\t$this->response['response']['error'] = (strpos(strtolower($this->response['response']['Message']), 'the item code was specified more than once') !== false) ? true : $this->response['response']['error'];\n\t\t\t$this->response['response']['Level1Code'] = $this->request['Level1Code'];\n\t\t\t\n\t\t\tif (!$this->response['response']['error']) { // IF Error is False\n\t\t\t\tif (in_array($this->response['server']['http_code'], array('200', '201', '202', '204'))) {\n\t\t\t\t\t$this->log_sendlogitem($this->request['Level1Code']);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$this->log_error($this->response['response']['Message']);\n\t\t\t}\n\t\t}", "function deliverResponse($status,$status_msg,$data)\n{\n $response['status'] = $status;\n $response['status_msg'] = $status_msg;\n $response['data'] = $data;\n $json_response = json_encode($response);\n echo $json_response;\n}", "function deliverResponse($status,$status_msg,$data)\n{\n $response['status'] = $status;\n $response['status_msg'] = $status_msg;\n $response['data'] = $data;\n $json_response = json_encode($response);\n echo $json_response;\n}", "function deliverResponse($status,$status_msg,$data)\n{\n $response['status'] = $status;\n $response['status_msg'] = $status_msg;\n $response['data'] = $data;\n $json_response = json_encode($response);\n echo $json_response;\n}", "function deliverResponse($status,$status_msg,$data)\n{\n $response['status'] = $status;\n $response['status_msg'] = $status_msg;\n $response['data'] = $data;\n $json_response = json_encode($response);\n echo $json_response;\n}", "function response($code, $dataAry)\n{\n if($code != 200)\n {\n $dataAry['status'] = 'error'; \n }\n else\n {\n $dataAry['status'] = 'success'; \n }\n $response = $GLOBALS['app']->response();\n $response['Content-Type'] = 'application/json';\n $response->status($code);\n $response->body(json_encode($dataAry));\n}", "public function getResponseData()\n {\n if($this->getHttpStatusCode() === 200){\n try{\n $resp = $this->getResponse();\n if(isset($resp->data)){\n $this->responseData = $resp->data;\n }\n }catch (Exception $e){\n\n }\n }\n return $this->responseData;\n }", "function _handler_response(&$app, &$c) {\n\t\t$c->param('app.view_http.response.status', $this->_http->getResponseCode());\n\t\t$c->param('app.view_http.response.body', $this->_http->getResponseBody());\n\t\t$c->param('app.view_http.response.headers', $this->_http->getResponseHeader());\n\t}", "function updateResponse($name, $value) {\n\t\t\t$this->responseVar[$name] = $value;\n\t\t}", "public function Response($response) {\n\t\t\n\t}", "abstract public function prepare_response( $object, $context );", "public function getItemDataFromResponse(Unirest\\Response $response)\n {\n return $response->body->data;\n }", "private function getData(){\n if($this->type == \"auto\"){\n \n \n $result = $this->get_from_link( self::AUTO_STRING.http_build_query($this->data));\n $array_names = json_decode($result, true); \n //var_dump($array_names); \n if(!isset($array_names)){\n $this->serverSideError(); \n }\n $ans = array(); \n \n foreach($array_names[\"predictions\"] as $key => $value){\n array_push($ans, $value[\"description\"]); \n }\n \n $response['status_code_header'] = 'HTTP/1.1 200 OK'; \n $response['body'] = json_encode($ans); \n \n return $response; \n }\n\n else if($this->type == \"geocode\"){\n \n\n //echo() $this->data); \n $result = $this->get_from_link( self::GEOCODE_STRING.http_build_query($this->data));\n // echo $result; \n $array = json_decode($result, true); \n if(!isset($array)){\n $this->serverSideError(); \n }\n \n $response['status_code_header'] = 'HTTP/1.1 200 OK'; \n $response['body'] = json_encode( $array[\"results\"][0][\"geometry\"][\"location\"]); \n \n return $response; \n }\n }", "public function setResponse( $response ){\n \n $this->response = $response;\n \n }", "function get_oembed_response_data_for_url($url, $args)\n {\n }", "public function setData( ) {\r\n\t\t\tself::callEvent('response.setData', $this, func_get_args());\r\n\t\t}", "public function setResponseData(array $data)\n {\n $this->responseData = json_encode($data);\n }", "public function getResponse(){\n \n return $this->response;\n \n }", "function parse_response($response)\n {\n $data = $response->getBody();\n\n // Note we could not use Guzzle XML method becuase Endicia does not return valid XML it seems\n $sxe = new SimpleXMLElement($data);\n\n if ($sxe->status == 0) {\n $return_data = array();\n $return_data['Status'] = (string)$sxe->Status;\n $return_data['Base64LabelImage'] = (string)$sxe->Base64LabelImage;\n $return_data['TrackingNumber'] = (string)$sxe->TrackingNumber;\n $return_data['FinalPostage'] = (string)$sxe->FinalPostage;\n $return_data['TransactionID'] = (string)$sxe->TransactionID;\n $return_data['PostmarkDate'] = (string)$sxe->PostmarkDate;\n $return_data['DeliveryTimeDays'] = (string)$sxe->PostagePrice->DeliveryTimeDays;\n\t $return_data['error'] = (string)$data;\n \n\t\treturn $return_data;\n } else {\n return array('status' => 'error', 'message' => $sxe);\n }\n }" ]
[ "0.6951925", "0.6871588", "0.66494673", "0.6442426", "0.627666", "0.6251916", "0.6206425", "0.6192471", "0.6153437", "0.6153437", "0.6153437", "0.6153437", "0.6153437", "0.61521286", "0.6149554", "0.61207575", "0.6069496", "0.6033674", "0.6033674", "0.6015838", "0.60068434", "0.6004309", "0.59961814", "0.59613234", "0.5957799", "0.5944525", "0.5943891", "0.5942854", "0.59284", "0.5904346", "0.5902189", "0.5891862", "0.5874933", "0.58678085", "0.58483016", "0.5836456", "0.5806048", "0.580066", "0.57953566", "0.5786734", "0.57842904", "0.577658", "0.57723147", "0.57581055", "0.5745952", "0.5739027", "0.57374185", "0.5728536", "0.57117677", "0.57107216", "0.5695334", "0.5685024", "0.5655445", "0.56495184", "0.56429845", "0.56427735", "0.56385523", "0.56379956", "0.56354666", "0.5634026", "0.56194586", "0.56134784", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.5592337", "0.55899936", "0.55897576", "0.5585638", "0.55824125", "0.55748427", "0.55706334", "0.556298", "0.555948", "0.5552057", "0.5537209", "0.55355877", "0.55355877", "0.55355877", "0.55355877", "0.55292904", "0.55245245", "0.5522643", "0.5516167", "0.5516133", "0.5513684", "0.55103624", "0.5508631", "0.5508124", "0.5497924", "0.5490137", "0.5483327", "0.5475132", "0.54739976" ]
0.0
-1
Get the current page.
public function getCurrentPage() { return isset($this['info']['page']) ? $this['info']['page'] : 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getCurrentPage()\r\n\t{\r\n\t\treturn $this->current_page;\r\n\t}", "public function getCurrentPage();", "public function getCurrentPage();", "public function getCurrentPage();", "public function getCurrentPage()\n {\n return $this->_currentpage;\n }", "function getCurrentPage() {\n return $this->current_page;\n }", "public function get_current_page()\n {\n return $this->current_page;\n }", "public function getCurrentPage() {\n\t\treturn $this->currentPage;\n\t}", "public function getCurrentPage()\n {\n return $this->currentPage;\n }", "public function getCurrentPage()\n\t{\n\t\treturn $this->_currentPage;\n\t}", "public function getCurrentPage() {\r\n\t\treturn $this->_currentPage;\r\n\t}", "public function getCurrentPage()\r\n {\r\n return $this->_currentPage;\r\n }", "protected function getCurrentPage() {\n if (isset($this->data['page'])) return $this->data['page'];\n else return 1;\n }", "public function getCurrentPage()\n\t{\n\t\tif (!$this->currentPage)\n\t\t{\n\t\t\t$this->currentPage = 1;\n\t\t}\n\t\treturn $this->currentPage;\n\t}", "public function getCurrentPage() {\r\n\t\treturn $this->__currentPage;\r\n\t}", "public function getCurrentPage()\n {\n return $this->getData('current_page') ? $this->getData('current_page') : 1;\n }", "function getCurrentPage() { return $this->m_currentPage; }", "public function getCurrentPage() {\n return $this->_currentPage;\n }", "static function getCurrentPage()\r\n {\r\n return $_SESSION[\"curr_page\"];\r\n }", "public function loadCurrentPage()\n\t{\n\t\treturn $this->getPage($this->getCurrentPage());\n\t}", "public function getCurrentPage() {\n\t\t\t$parts = parse_url($this->getCurrentPageURL());\n\t\t\treturn substr($parts['path'], strrpos($parts['path'], '/') + 1);\n\t\t}", "public function getCurrentPage() {\n $this->getCurrentPageParameter(TRUE);\n if (is_null($this->_lastPage)) {\n $this->calculate();\n }\n return $this->_currentPage;\n }", "public function getCurPage()\n {\n return $this->curPage;\n }", "function current()\n {\n if (!isset($this->_curPage)\n || $this->_curPage->getPage() != $this->_position\n ) {\n $this->_curPage = $this->_pages->get($this->_position);\n }\n return $this->_curPage;\n }", "public function getCurrentPage()\n {\n return $this->request->param('paging.' . $this->pagingType . '.page');\n }", "public function getCurrentPage()\n {\n return min($this->current_page, $this->getNumberOfTotalPages());\n }", "function CurrentPage ( )\n{\n return $this->_CurrentPage;\n}", "function getCurrentPage() {\n\t$protocol = (!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443) ? \"https://\" : \"http://\";\n\t$currentPage = $protocol . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];\n\treturn $currentPage;\n}", "public function getCurrentPage() : int\n {\n return $this->currentPage;\n }", "public static function getCurrentPage()\n {\n $page = '';\n\n if (isset($_SERVER['REQUEST_URI']) === TRUE && isset($_SERVER['HTTP_HOST']) === TRUE) {\n $protocol = 'http';\n $page = $protocol.'//'.$_SERVER['HTTP_HOST'].'/'.$_SERVER['REQUEST_URI'];\n $page = substr($page, strlen(url::getUrl()));\n $page = trim($page, '/');\n }\n\n return $page;\n }", "public function getCurrentPage() \n { \n\t/*\n $total_of_pages = $this->getTotalOfPages();\n $pager = $this->getPager();\n \n if ( isset( $pager ) && is_numeric( $pager ) ) { \n $currentPage = $pager; \n } else { \n $currentPage = 1; \n } \n\n if ( $currentPage > $total_of_pages ) { \n $currentPage = $total_of_pages; \n } \n\n if ($currentPage < 1) { \n $currentPage = 1; \n } \n\t\t*/\n \n\t\tif (empty($_GET['page'])){$currentPage = 1;}\n\t\t\telse {$currentPage = $_GET['page'];}\n return (int) $currentPage; \n \n }", "public function getCurrentPage(): int;", "public function getCurrentPage(): int;", "public function getCurrentPage(): int\n {\n return $this->currentPage;\n }", "public static function getPage()\n {\n return self::$page;\n }", "public function currentPage()\n {\n return $this->setRightOperand(PVar::CURRENT_PAGE);\n }", "protected function _getCurrentPage() {\r\n\r\n // determine which object the current request belongs\r\n $currentPage = null;\r\n\r\n // perform \"polling\" to get who can manage this request\r\n foreach ($this->getItems() as $item) {\r\n if (($item instanceof Page) && $item->isResponsibleFor($this->_request)) {\r\n $currentPage = $item;\r\n break;\r\n }\r\n }\r\n\r\n return $currentPage;\r\n }", "public function currentPage()\n {\n return $this->page ? $this->page->currentPage() : 0;\n }", "public function getCurentPage()\n\t{\n\t\t$pattern = '#[a-z]*.php$#';\n\t\tpreg_match($pattern, $_SERVER['REQUEST_URI'], $current_page);\n\t\tif(isset($current_page) && $current_page){\n\t\t\tforeach($current_page as $cp){\n\t\t\t\tswitch($cp){\n\t\t\t\t\tcase 'index.php': \n\t\t\t\t\treturn 'index';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'rooms.php':\n\t\t\t\t\treturn 'rooms';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'chat.php':\n\t\t\t\t\treturn 'chat';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'contact.php': \n\t\t\t\t\treturn 'contact';\n\t\t\t\t\tbreak;\n\t\t\t\t\tdefault: \t\n\t\t\t\t\treturn 'other';\n\t\t\t\t}\n\t\t\t}\n\t\t}else{\n\t\t\t$this->goToIndex();\n\t\t}\n\t}", "function getCurrentPage(){\n\t$file = $_SERVER[\"PHP_SELF\"];\n\t$break = Explode('/', $file);\n\t$currentPage = $break[count($break) - 1];\n return $currentPage;\n}", "function GetCurrentPage()\n\t{\n\t\t// when list is used from Site and not from CMS\n\t\tif ($this->m_externalParmas && is_array ( $this->m_externalParmas ))\n\t\t{\n\t\t\t// looking for page param\n\t\t\tforeach ( $this->m_externalParmas as $parma )\n\t\t\t{\n\t\t\t\t// if param start with 'page'\n\t\t\t\tif (substr ( $parma, 0, 4 ) == 'page')\n\t\t\t\t{\n\t\t\t\t\t// if afther 'page' is number\n\t\t\t\t\t$pageIndex = intval ( substr ( $parma, 4 ) );\n\t\t\t\t\tif ($pageIndex)\n\t\t\t\t\t{\n\t\t\t\t\t\treturn $pageIndex;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t//From CMS\n\t\t$res = DB::REQUEST ( \"page{$this->m_linkIDName}\" );\n\t\t\n\t\tif (! $res)\n\t\t{\n\t\t\t$res = 1;\n\t\t}\n\t\treturn $res;\n\t}", "public function getPage() {\n\t\treturn $this->page;\n\t}", "public function getPage()\n\t{\n\t\treturn $this->page;\n\t}", "public function getPage() {\n\t\treturn $this->_page;\n\t}", "protected function getCurrentPage(): int\n {\n if (isset($_GET['page']) and $_GET['page'] !== 0 and $_GET['page'] > 0) {\n $currentPage = (int) $_GET['page'];\n\n if ($currentPage > $this->pages) {\n $this->redirect($_SERVER['PHP_SELF']);\n }\n } else {\n $currentPage = 1;\n }\n\n return $currentPage;\n }", "public function current(int $page): string;", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->page;\n }", "public function getPage() {\n return $this->page;\n }", "function get()\n {\n return $this->page;\n }", "public function getPage()\n {\n return $this->_page;\n }", "public function get_page_id() {\n\t\t\treturn $this->current_page_id;\n\t\t}", "protected function currentPage()\n {\n return $this->paginator->currentPage();\n }", "protected function currentPage()\n {\n return $this->paginator->currentPage();\n }", "protected function currentPage()\n {\n return $this->paginator->currentPage();\n }", "public function getPage() {\n return $this->_strPage;\n }", "protected function getCurrentPage(){\n \n $request = $this->getRequest();\n $user = $this->getUser(); \n $page = 1;\n // Manage the current page\n if($request->hasParameter('page'))\n {\n $page = $request->getParameter('page');\n $user->setAttribute('page', $page, 'project/list');\n }\n elseif($user->hasAttribute('page', 'project/list'))\n {\n $page = $user->getAttribute('page', $page, 'project/list');\n } \n \n return $page;\n }", "public function page()\n {\n return $this->conversation->page;\n }", "public function getPage() {\n return $this->_page;\n }", "public function currentPage(){\n return $this->page;\n }", "public function currentPage()\n {\n $page = (int)($this->params['page'] ?? 1);\n\n return max(1, $page);\n }", "public function getPage() {\n if (isset($_REQUEST['page'])) {\n return $_REQUEST['page'];\n } else\n return 0;\n }", "function current_page() {\n $current = substr($_SERVER[\"SCRIPT_NAME\"],strrpos($_SERVER[\"SCRIPT_NAME\"],\"/\")+1);\n return $current;\n}", "public function get_page();", "public function getCurrentPage()\n {\n try {\n $orderId = $this->request->getActionName() === 'success' ? $this->checkoutSession->getData('last_real_order_id') : null;\n $module = $this->request->getModuleName();\n\n $productId = 0;\n\n //Product page\n if ($module === 'catalog' && $this->currentProductRegistry) {\n $productId = $this->currentProductRegistry->getId();\n $latestViewedProducts = $this->coreSession->getUserViewedProducts();\n if (!empty($latestViewedProducts)) {\n $latestViewedProducts .= ',' . $productId;\n $this->coreSession->setUserViewedProducts($latestViewedProducts);\n } else {\n $this->coreSession->setUserViewedProducts($productId);\n }\n $this->coreSession->setHistory(true);\n }\n\n // Category page\n if ($module === 'catalog' && $this->currentCategoryRegistry) {\n // check if the category is a root category to avoid it\n if ($this->catalogLayer->getCurrentCategory()->getLevel() !== \"1\") {\n\n $catName = $this->coreSession->getLastVisitedCategoryName();\n $catLink = $this->coreSession->getLastVisitedCategoryLink();\n\n $currentCategoryName = $this->catalogLayer->getCurrentCategory()->getName();\n $currentCategoryLink = $this->catalogLayer->getCurrentCategory()->getUrl();\n\n if (!empty($catName) && !empty($catLink)) {\n $catName .= ',' . $currentCategoryName;\n $catLink .= ',' . $currentCategoryLink;\n $this->coreSession->setLastVisitedCategoryName($catName);\n $this->coreSession->setLastVisitedCategoryLink($catLink);\n } else {\n $this->coreSession->setLastVisitedCategoryName($currentCategoryName);\n $this->coreSession->setLastVisitedCategoryLink($currentCategoryLink);\n }\n $this->coreSession->setHistory(true);\n }\n }\n\n $current = array(\n 'currentUrl' => $this->coreUrlHelper->getCurrentUrl(),\n 'orderId' => $orderId,\n 'currentPageType' => $this->getPageType(),\n 'product' => $this->getProductInformation($productId)\n );\n } catch (Exception $exception) {\n $this->exceptionHandler->logException($exception);\n\n $current = array(\n 'currentUrl' => null,\n 'orderId' => null,\n 'currentPageType' => null,\n 'product' => $this->getDefaultProduct()\n );\n }\n\n return $current;\n }", "public function getPage() {\n return $this->getValueOrDefault('Page');\n }", "public function get() {\n $temp = $this->page;\n $this->addFooter();\n //Restore $page for the next call to get\n $page = $this->page;\n $this->page = $temp;\n return $page;\n //if not needed, use $this->addFooter(); return $this->page;\n }", "public function get_page() {\n return $this->list_page;\n }", "public function currentPage()\n {\n return $this->paginator->currentPage();\n }", "public function getPage() {\n if ($this->getParameter('page')) {\n return $this->getParameter('page');\n }\n\n return 1;\n }", "public function getPage(){\n return $this->page;\n }", "public function getPage() {\n \t\n \t// Return our page instance\n \treturn $this->oPage;\n }", "public function get_cur_page()\n\t{\n\t\t$total = $this->get_total();\n\t\t$pages = ceil($total / $this->per_page);\n\t\t$page = $this->config['cur_page'];\n\t\t\n\t\tif ($page < 1) {\n\t\t\t$page = 1;\n\t\t} elseif ($page > $pages) {\n\t\t\t$page = max($pages, 1);\n\t\t}\n\t\t\n\t\treturn $page;\n\t}", "function currentPage($newValue=NULL) {\n\t\tif ( isset($newValue) ) $this->current_page = IntVal($newValue);\n\t\treturn $this->current_page;\n\t}", "function get_one_page(){\n\t\t$this->m_n_current_page_number = gf_get_value_n('v_current_page_number');\n\t}", "public function getCurrentPageIndex()\n {\n return ! empty($this->result) ? $this->result->getCurrentPageIndex() : NULL;\n }", "public function getPage()\n\t{\n\t\treturn $this->parameters['page'];\n\t}", "public function getCurrentPage(): int\n {\n return $this->limit && 0 < $this->start\n ? ($this->start / $this->limit) + 1\n : 1\n ;\n }", "public function get_page() {\n\n\t\tif ( null === $this->page ) {\n\n\t\t\t$page = isset( $_GET['page'] ) && $this->dashboard_slug !== $_GET['page'] ? esc_attr( $_GET['page'] ) : $this->dashboard_slug . '-' . $this->get_initial_page();\n\n\t\t\t$this->page = str_replace( $this->dashboard_slug . '-', '', $page );\n\t\t}\n\n\t\treturn $this->page;\n\t}", "public function getPage()\n {\n return $this->firstPage;\n }", "public function getPage()\n {\n return $this->getParameter('page');\n }", "public function getPage()\n {\n return $this->getRequest()->get('page', 1);\n }", "abstract protected function getCurrentPageId() ;", "function current_page(){\n return isset($_GET['p']) ? (int)$_GET['p'] : 1;\n}", "protected function getCurrentPageId() {}", "protected function getCurrentPageId() {}", "protected function getCurrentPageId() {}", "protected function getCurrentPageId() {}", "public static function current()\n\t{\n\t\treturn Request::$current;\n\t}", "public function current()\n {\n return $this->pager->current();\n }", "static function get_current_page_url() {\n\t\tif ( isset($_SERVER['REQUEST_URI']) ) {\n\t\t\t$_SERVER['REQUEST_URI'] = preg_replace('/&?offset=[0-9]*/', '', $_SERVER['REQUEST_URI']);\n\t\t}\n\t\treturn wp_kses($_SERVER['REQUEST_URI'], '');\n\t}", "function give_get_current_setting_page() {\n\t// Get current page.\n\t$setting_page = ! empty( $_GET['page'] ) ? urldecode( $_GET['page'] ) : '';\n\n\t// Output.\n\treturn $setting_page;\n}", "public function getPage() {\n $page = $this->_getParam('page');\n if(!isset($page)){\n $start = 1;\n } else {\n $start = $page;\n }\n return $start;\n }" ]
[ "0.8847023", "0.8765536", "0.8765536", "0.8765536", "0.8763776", "0.86920536", "0.8654788", "0.85925245", "0.85766447", "0.85546815", "0.8550184", "0.85201836", "0.846496", "0.8435532", "0.84172547", "0.83792293", "0.8376027", "0.83635056", "0.8354244", "0.82469374", "0.8085574", "0.8019326", "0.7974174", "0.7905993", "0.7880419", "0.7874474", "0.7854656", "0.7842535", "0.78376514", "0.78271943", "0.78042567", "0.77838427", "0.77838427", "0.7760039", "0.767374", "0.7615521", "0.7610054", "0.7599601", "0.7541815", "0.7536253", "0.75109863", "0.75028783", "0.74665755", "0.7438464", "0.74245936", "0.7384857", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.73731905", "0.7369312", "0.73370576", "0.73223305", "0.726681", "0.72576094", "0.72576094", "0.72576094", "0.7239625", "0.72219336", "0.7210326", "0.7203746", "0.7182823", "0.7180333", "0.7180101", "0.7171403", "0.7155072", "0.7105104", "0.70997185", "0.70888543", "0.7079707", "0.70670116", "0.7022009", "0.7020098", "0.7012257", "0.69996464", "0.6998088", "0.69528496", "0.6948911", "0.69262487", "0.6922823", "0.69102424", "0.6900734", "0.68988514", "0.68932074", "0.6885293", "0.68675476", "0.6864689", "0.6864689", "0.6864689", "0.68623734", "0.68560654", "0.6854807", "0.679476", "0.6791402", "0.67879343" ]
0.8528796
11
Get the total results count.
public function getTotalResults() { return isset($this['info']['results']) ? (int) $this['info']['results'] : 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getTotalResults() : int\n {\n return $this->totalResults;\n }", "public function totalResults()\n {\n\t\treturn (int) $this->totalResultsReturned;\n }", "public function getTotalResults(): int\n {\n return $this->totalResults;\n }", "public function getTotalNumberOfResults();", "public function count()\r\n {\r\n\t\tif ( null === $this->totalResults )\r\n\t\t{\r\n\t\t\t$this->warmUp();\r\n\t\t}\r\n\r\n\t\treturn $this->totalResults;\r\n\t}", "public function total_results()\n\t{\n\t\t$results = $this->get_results();\n\t\t$total = 0;\n\n\t\tforeach\t( $results as $set ) {\n\t\t\t$total = $total + count( $set );\n\t\t}\n\n\t\treturn $total;\n\t}", "public function getNumTotalQueryResults() : int{\n return $this->numTotalQueryResults;\n }", "public function getTotalResults()\n {\n return $this->totalResults;\n }", "public function getTotalResults()\n {\n return $this->totalResults;\n }", "public function getTotalResults() {\n return $this->totalResults;\n }", "public function getTotalResults()\n {\n if (null === $this->totalResults) {\n $this->totalResults = $this->countResults();\n }\n return $this->totalResults;\n }", "public function getTotalResultsCount()\n {\n if (!$this->xmlRoot) {\n $this->processData();\n }\n return intval((string)$this->xmlRoot->xpath('/searchRetrieveResponse/numberOfRecords'));\n }", "public function getTotalCount($results)\n {\n return $results->getNumFound();\n }", "public function count(): int\n {\n if ($this->numberOfResults === null) {\n $this->initialize();\n if ($this->queryResult !== null) {\n $this->numberOfResults = count($this->queryResult ?? []);\n } else {\n parent::count();\n }\n }\n\n return $this->numberOfResults;\n }", "public function getTotalCount($results)\n {\n return count($results);\n }", "public function numResults()\n {\n return $this->numResults;\n }", "public function getResultCount()\n {\n return ! empty($this->result) ? $this->result->getResultCount() : 0;\n }", "public function count()\n {\n return count($this->getResults());\n }", "public function getNbResults(): int\n {\n return $this->adapter->getTotalHits();\n }", "public function getTotalCount()\n {\n return $this->totalCount;\n }", "public function getTotalHits()\n {\n if (isset($this->results)) {\n return $this->results->getTotalHits();\n }\n }", "public function totalCount();", "public function totalCount();", "public function getTotalResults();", "public function total(): int\n {\n return count($this->all());\n }", "public function getResultCount()\n {\n return $this->count(self::_RESULT);\n }", "public function getResultCount()\n {\n return $this->count(self::_RESULT);\n }", "public function getTotalCount()\n\t{\n\t\treturn $this->totalCount;\n\t}", "public function getTotalCount();", "public function getTotalCount();", "public function getTotalCount();", "public function GetNumberOfResults()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $ret = 0;\n \n if (!$this->_my_root && $this->_search_results instanceof c_comdef_meetings) {\n $ret = $this->_search_results->GetNumMeetings();\n } elseif ($this->_my_root instanceof c_comdef_meeting_search_manager) {\n $ret = $this->_my_root->GetNumberOfResults();\n }\n \n return $ret;\n }", "public function getTotalCount($results)\n {\n return $results->first();\n }", "public function getCount() : int\n\t{\n\t\treturn (int)$this->getResult();\n\t}", "public function getTotal()\n {\n if ( empty ( $this->_total ) ) {\n $query = $this->_buildQuery();\n $this->_total = $this->_getListCount($query);\n }\n\n return $this->_total;\n }", "private function getCountAllResults()\n {\n $qb = $this->em->createQueryBuilder();\n $qb->select('count(' . $this->tableName . '.' . $this->rootEntityIdentifier . ')');\n $qb->from($this->metadata->getName(), $this->tableName);\n\n $this->setWhereCallbacks($qb);\n\n return (int) $qb->getQuery()->getSingleScalarResult();\n }", "public function getTotal() {\n\t\treturn $this->find('count', array(\n\t\t\t'contain' => false,\n\t\t\t'recursive' => false,\n\t\t\t'cache' => $this->alias . '::' . __FUNCTION__,\n\t\t\t'cacheExpires' => '+24 hours'\n\t\t));\n\t}", "public function getNbResults()\n {\n $this->sphinxQL->execute();\n\n $helper = Helper::create($this->sphinxQL->getConnection());\n $meta = $helper->showMeta()->execute()->fetchAllAssoc();\n\n foreach ($meta as $item) {\n if ('total_found' === $item['Variable_name']) {\n return (int) $item['Value'];\n }\n }\n\n return 0;\n }", "function getTotal() {\n\t\tif (empty($this->_total)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "static public function getTotalCount()\n\t{\n\t\treturn self::$count;\n\t}", "public function getNumResultsStored() : int{\n return $this->numResults;\n }", "function getTotal() {\r\n\t\tif (empty ( $this->_total )) {\r\n\t\t\t$query = $this->_buildQuery ();\r\n\t\t\t$this->_total = $this->_getListCount ( $query );\r\n\t\t}\r\n\t\treturn $this->_total;\r\n\t}", "public function getNbResults()\n\t{\n\t\tif (!$this->itemCount) {\n\t\t\t$this->itemCount = count($this->collection);\n\t\t}\n\n\t\treturn $this->itemCount;\n\t}", "public function totalCount()\n\t{\n\t\tif ($this->total_count_cache === null) {\n\t\t\t$this->total_count_cache = $this->query->runTotalRowsCount(false);\n\t\t}\n\n\t\treturn $this->total_count_cache;\n\t}", "function getTotal()\n\t{\n\t\tif (empty($this->_total)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\t\treturn $this->_total;\n\t}", "public static function totalNumber()\n {\n return (int)self::find()->count();\n }", "function getTotal()\n\t{\n\t\tif (empty($this->_total)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query); \n\t\t}\n\t\treturn $this->_total;\n\t}", "public function getTotalResults()\n {\n $query = $this->deliverQueryObject();\n\n return $query->resetQueryParts(['groupBy', 'orderBy'])->select('count(distinct uph.upID)')->setMaxResults(1)->execute()->fetchColumn();\n }", "public function getCount()\n {\n if ($this->_queryResult === null) {\n return 0;\n }\n\n return $this->_queryResult->count();\n }", "public function getTotal()\n\t{\n\t\t\n\t\treturn count($this->findAll());\n\t}", "public function getTotalCount()\n {\n $this->loadItems();\n return $this->calculator->getCount($this->items);\n }", "public function getNbResults()\n {\n return $this->nbResults;\n }", "function numResults() {\n\t\treturn $this->num_rows();\n\t}", "public function getTotal()\n {\n $query = $this->getQuery()->select('COUNT(*) as total');\n \n $rows = $this->database->query($query, $this->database->getBinds());\n \n if (!isset($rows[0]['total'])) {\n return 0;\n }\n \n return $rows[0]['total'];\n }", "public function getNbResults()\n {\n return $this->select->count();\n }", "public function count()\n {\n return $this->queryResult->getSize();\n }", "public function count()\n {\n $result = new QueryResult($this);\n return $result->count();\n }", "public function getTotalCount()\n {\n return $this->readOneof(9);\n }", "function getTotal()\r\n{\r\n if (empty($this->_total))\r\n {\r\n $query = $this->_buildQuery();\r\n $this->_total = $this->_getListCount($query);\r\n }\r\n \r\n return $this->_total;\r\n}", "public function getTotalCount()\n {\n if ($this->getPagination() === false) {\n return $this->getCount();\n } elseif ($this->_totalCount === null) {\n $this->_totalCount = $this->prepareTotalCount();\n }\n\n return $this->_totalCount;\n }", "public function get_total()\n\t{\n\t\t$query = $this->query;\n\t\tif(isset($query['order']))\n\t\t\t$query['order'] = $this->model->table() . '.id';\n\t\treturn $this->model->count($query);\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function getTotal()\r\n\t{\r\n\t\tif( empty($this->_total) )\r\n\t\t{\r\n\t\t\t$this->_total\t= $this->_getListCount( $this->_query() );\r\n\t\t}\r\n\r\n\t\treturn $this->_total;\r\n\t}", "public function total(): int\n {\n return Arr::get($this->meta, 'total', $this->count());\n }", "public function countResults()\n {\n return mysqli_num_rows($this->lastResults);\n }", "public function count() {\n $this->_active_query->fields($this->func()->count());\n $query = $this->query( $this->_active_query->getQuery(), $this->_active_query->getParams() );\n return (int)$query->rowCount();\n }", "public function getCurrentCount(): int\n {\n return count($this->getResults());\n }", "public function computeCount() {\n if ($str = elis_consumer_http_request($this->url_pattern . '&rows=0', array('Accept' => 'application/json'))) {\n if ($json = json_decode($str)) {\n $this->totalCount = $json->response->numFound;\n }\n }\n return $this->totalCount;\n }", "public function get_query_total_count() {\n // Return the total engine count minus the docs we have determined are bad.\n return $this->totalenginedocs - $this->skippeddocs;\n }", "public function getTotalCount()\n {\n return $this->provider->totalCount;\n }", "public function count()\n {\n $query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n return $row['total_rows'];\n }", "public function count()\n {\n return $this->client->count($this->compile())['count'];\n }", "public function count()\n\t{\n\t\treturn $this->result->count();\n\t}", "protected function calculateTotalItemCount()\n\t{\n\t\t$this->addScopes();\n\t\treturn CActiveRecord::model($this->modelClass)->count($this->getCriteria());\n\t}", "public function getCount()\n {\n return $this->doQuery(null, false, false)->count();\n }", "public function count(){\n $query = \"SELECT COUNT(*) as total_rows FROM \".$this->table_name. \"\";\n\n $stmt = $this->conn->prepare($query);\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\n return $row['total_rows'];\n }", "public function getResultCount()\n {\n if (!$this->getData('result_count')) {\n $size = $this->_getVendorCollection()->getSize();\n $this->_getQuery()->saveNumResults($size);\n $this->setResultCount($size);\n }\n return $this->getData('result_count');\n }", "public function count() {\n $total = 0;\n $this->setColumns(array('COUNT(*) '.$this->modx->escape('ct')));\n if ($this->execute()) {\n $count = $this->getResults();\n if (!empty($count) && !empty($count[0]['ct'])) {\n $total = intval($count[0]['ct']);\n }\n $this->close();\n }\n return $total;\n }", "protected function get_total_count() {\n\t\treturn affiliate_wp()->utils->data->get( \"{$this->batch_id}_total_count\", 0 );\n\t}", "public function count()\n {\n if (array_key_exists('count', $this->information))\n $totalCount = $this->information['count'];\n else\n $totalCount = 0;\n if ($this->limit < $totalCount)\n return $this->limit;\n else\n return $totalCount;\n }", "public function count(){\n\t\t\t$query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n\t\t\n\t\t\t$stmt = $this->conn->prepare( $query );\n\t\t\t$stmt->execute();\n\t\t\t$row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\n\t\t\treturn $row['total_rows'];\n\t\t}", "public function getTotal()\n\t{\n $rows = (new \\yii\\db\\Query())\n ->select('*')\n ->from($this->table)\n ->all();\n\t\treturn count($rows);\n\t}", "public function count()\n {\n return $this->getTotalItemCount();\n }", "public function count()\n {\n return $this->model->paginate(1, $this->select)->total();\n }", "public function count(){\n $query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n return $row['total_rows'];\n }", "public function count()\n\t{\n\t\treturn $this->_totalItemCount;\n\t}", "public function count(): int\r\n\t{\r\n\t\t$limit = $this->queryBuilder->getMaxResults();\r\n\t\t$offset = $this->queryBuilder->getFirstResult();\r\n\r\n\t\t$this->queryBuilder->setMaxResults(null);\r\n\t\t$this->queryBuilder->setFirstResult(null);\r\n\r\n\t\t$pager = new Paginator($this->queryBuilder->getQuery());\r\n\r\n\t\t$this->queryBuilder->setMaxResults($limit);\r\n\t\t$this->queryBuilder->setFirstResult($offset);\r\n\r\n\t\treturn $pager->count();\r\n\t}", "public static function countAll(){\n\t\t\t$qb = new QueryBuilder(get_called_class());\n\t\t\t$res = $qb->select(\"COUNT(*) as total\")->get();\n\t\t\treturn $res?$res[\"total\"]:0;\n\t\t}", "public function count(): int\n {\n if ($this->clause('action') !== self::ACTION_READ) {\n return 0;\n }\n\n if (!$this->_result) {\n $this->_execute();\n }\n\n if ($this->_result) {\n /** @psalm-suppress PossiblyInvalidMethodCall, PossiblyUndefinedMethod */\n return (int)$this->_result->total();\n }\n\n return 0;\n }", "public function getTotalResultsAvailable()\n {\n return $this->TotalResultsAvailable;\n }", "public function getCount() {\n return $this->get(self::COUNT);\n }", "public function getCount()\n {\n $query = $this->createSearchQuery()\n ->select(\"COUNT(p.id)\")\n ->getQuery();\n \n $queryPath = $this->getCreatedSearchQueryCachePath();\n $query->useResultCache(true, self::CACHE_DAY, $this->getCachePrefix(__FUNCTION__) . $queryPath);\n \n $result = $query->getScalarResult();\n\n return $result[0][1];\n }", "public function GetNumberOfResultsInThisPage()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $ret = 0;\n \n if ($this->_search_results instanceof c_comdef_meetings) {\n $ret = $this->_search_results->GetNumMeetings();\n }\n\n return $ret;\n }", "public function getCount() : int\n {\n return $this->count;\n }", "public static function getTotal()\n {\n return Query::select()->\n count('*', 'total')->\n from(self::getTableName())->\n execute()->\n getFirstRow()->\n getValue('total', 'int');\n }", "public function count(): int\n\t{\n\t\treturn $this->paginator->count();\n\t}", "function countTotal() {\n $dbr = wfGetDB( DB_SLAVE );\n $count = 0;\n $s = $dbr->selectRow(\n 'Comments',\n array( 'COUNT(*) AS CommentCount' ),\n array( 'Comment_Page_ID' => $this->id ),\n __METHOD__\n );\n if ( $s !== false ) {\n $count = $s->CommentCount;\n }\n return $count;\n }", "protected function fetchTotalCount()\n {\n //get total if fetching a list\n $this->main_model_obj = new $this->main_model();\n $total_builder = $this->main_model_obj->getModelsManager()->createBuilder()\n ->columns(['COUNT(1) AS total'])\n ->from($this->main_model);\n\n $this->formJoinsUsingFilters($total_builder);\n $this->formConditions($total_builder);\n\n $result_obj = $total_builder->getQuery()->getSingleResult();\n $this->total_count = (empty($result_obj['total'])) ? 0 : $result_obj['total'];\n }" ]
[ "0.8893402", "0.8884857", "0.8872842", "0.87649435", "0.8741128", "0.8674973", "0.86277914", "0.8570707", "0.8570707", "0.8527656", "0.847599", "0.8427657", "0.8361371", "0.83166695", "0.82680714", "0.8250403", "0.8212007", "0.82115483", "0.81814116", "0.81425965", "0.8130029", "0.8129455", "0.8129455", "0.8119201", "0.8112236", "0.8107297", "0.81067175", "0.8098135", "0.80971676", "0.80971676", "0.80971676", "0.80507314", "0.80365974", "0.8031276", "0.80167824", "0.8005309", "0.8000988", "0.79768157", "0.79744095", "0.79693466", "0.7953503", "0.79397553", "0.79323", "0.79220074", "0.7921581", "0.7911394", "0.7894281", "0.7844852", "0.78433895", "0.78341156", "0.7824058", "0.7822562", "0.78208846", "0.7820827", "0.78178465", "0.7810968", "0.7778849", "0.7774595", "0.77740324", "0.7768045", "0.7747724", "0.7747504", "0.7747504", "0.7747504", "0.7746502", "0.7743229", "0.77424145", "0.7718677", "0.7702935", "0.7699553", "0.76872617", "0.7684354", "0.7678459", "0.7666735", "0.7660769", "0.76592493", "0.7632775", "0.76153165", "0.7611978", "0.76087534", "0.76054394", "0.75999624", "0.7597912", "0.7587305", "0.75716805", "0.756815", "0.75581956", "0.7538577", "0.7529394", "0.75110626", "0.75103855", "0.7505518", "0.75002974", "0.7492742", "0.7483802", "0.7482923", "0.7478067", "0.74717796", "0.746932", "0.74616903" ]
0.8944239
0
Get the error message from the response object.
public function getError() { return isset($this['error']) ? $this['error'] : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getError()\n {\n\n if (!$this->getResponse()) {\n return null;\n }\n\n if ($this->isOK()) {\n return null;\n }\n\n $message = ($this->getResponse()->getStatusCode() ? $this->getResponse()->getStatusCode() . ' ' : '') .\n ($this->getResponse()->getReasonPhrase() ? $this->getResponse()->getReasonPhrase() : 'Unknown response reason phrase');\n\n try {\n\n $data = $this->getJson();\n\n if (!empty($data->message)) {\n $message = $data->message;\n }\n\n if (!empty($data->error_description)) {\n $message = $data->error_description;\n }\n\n if (!empty($data->description)) {\n $message = $data->description;\n }\n\n } catch (Exception $e) {\n }\n\n return $message;\n\n }", "public function getError()\n {\n $errorMessage = null;\n \n if (!$this->isOk())\n {\n $errorMessage = $this->m_responseArray['message'];\n }\n else\n {\n throw new Exception('Calling getError when there was no error');\n }\n \n return $errorMessage;\n }", "public function getError()\r\n {\r\n if (isset($this->response['faultString'])) {\r\n return $this->response['faultString'];\r\n } elseif (isset($this->response['errmsg'])) {\r\n return $this->response['errmsg'];\r\n }\r\n return null;\r\n }", "private function _getErrorFromResponse($response)\n {\n if(isset($response['Envelope']['Body']['Fault']['FaultString']) && !empty($response['Envelope']['Body']['Fault']['FaultString'])) {\n return $response['Envelope']['Body']['Fault']['FaultString'];\n }\n return 'Unknown Server Error';\n }", "public function getMessageFromResponse()\n {\n $response = $this->getResponse();\n $message = [];\n\n if ($response->getCode()) {\n $message[] = $response->getCode();\n }\n\n if ($response->getErrorCode()) {\n $message[] = '(' . $response->getErrorCode() . ')';\n }\n\n if ($response->getErrorMessage()) {\n $message[] = $response->getErrorMessage();\n }\n\n return implode(' ', $message);\n }", "public function getErrorMessage(): ?string {\n\t\t// 1. a string with an error message (e.g. `{\"error\":{\"code\":404,\"errors\":\"invalid token\"},\"success\":false}`)\n\t\t// 2. an object (e.g. `{\"error\":{\"code\":120,\"errors\":{\"name\":\"payload\",\"reason\":\"required\"}},\"success\":false}`)\n\t\t//\n\t\t// Below is an attempt to make sense of such craziness.\n\t\t$error = $this->getValue('[error][errors]');\n\t\tif ($error === null) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (!is_array($error)) {\n\t\t\t$error = [\n\t\t\t\t'name' => 'generic',\n\t\t\t\t'reason' => $error,\n\t\t\t];\n\t\t}\n\n\t\treturn sprintf(\n\t\t\t'name=%s, reason=%s',\n\t\t\t(array_key_exists('name', $error) ? $error['name'] : 'missing'),\n\t\t\t(array_key_exists('reason', $error) ? $error['reason'] : 'missing')\n\t\t);\n\t}", "public function getErrorMessage() : ?string\n {\n if ($this->isSuccessful())\n {\n return null;\n }\n \n if ($this->httpResponse)\n {\n return $this->httpResponse->getReasonPhrase();\n }\n\n return null;\n }", "public function getMessage()\n {\n return $this->_error;\n }", "public function getErrorMessage() {\n return curl_error($this->curl_handle);\n }", "public function get_error_message() {\n\t\treturn $this->error_message;\n\t}", "public function getErrorMessage()\n {\n return $this->error_message;\n }", "protected function getApiResponseError(array $response)\n\t{\n\t\treturn array_get($response, 'ResponseCode').': '.array_get($response, 'ResponseMsg');\n\t}", "public function getErrorMessage()\r\n {\r\n return $this->error_message;\r\n }", "public function getError(): string\n {\n foreach ($this->getBulkResponses() as $bulkResponse) {\n if ($bulkResponse->hasError()) {\n return $bulkResponse->getError();\n }\n }\n\n return '';\n }", "public function getErrorMessage() {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function getLastErrorResponse() {\n if (!empty($this->rawResponses)) {\n foreach (array_reverse($this->rawResponses) as $x) {\n if (isset($x['error'])) {\n return $x;\n }\n }\n }\n }", "protected function responseMessage()\n {\n return isset($this->codes[$this->code]) ? $this->codes[$this->code] : '';\n }", "function get_error_message() {\n return $this->error_msg;\n }", "protected static function extractErrorMessage($data)\n {\n if (is_string($data)) return $data;\n if (isset($data->message)) return $data->message;\n \n if (isset($data->error)) {\n return isset($data->error->message) ? $data->error->message : $data->error;\n }\n\n trigger_error(\"Failed to extract error message from response\", E_USER_NOTICE);\n return null;\n }", "private function messageFrom($response)\n {\n return $response['status_message'] ?: $response['error_description'];\n }", "public function getErrorMessage()\n\t{\n\t\treturn $this->errorMessage;\n\t}", "public function getErrorMessage() : string\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->singleValue('//i:errorMessage');\n }", "public function getError(): string\n {\n return $this->error;\n }", "public function message(): string\n {\n return $this->errorMessage;\n }", "final public function error_get() : string{\r\n return (string) ($this->code != 0) ? \"[<b>{$this->code}</b>]: \".$this->message : $this->message;\r\n }", "public function message()\n {\n return $this->errorText;\n }", "public function getErrorMessage()\n\t{\n\t\treturn $this->_errorMessage;\n\t}", "public function message()\n {\n return $this->error_message;\n }", "public function getError(){\n if (empty($this->getErrorCode())) {\n return null;\n }\n return $this->getErrorCode().': '.$this->getErrorMessage();\n }", "public function getMessage()\n {\n if ($this->isSuccessful()) {\n return null;\n }\n\n if (isset($this->data['response']['gatewayCode'])) {\n return self::GATEWAY_CODES[$this->data['response']['gatewayCode']];\n }\n\n if (isset($this->data['error'])) {\n return sprintf('[%s] %s', $this->data['error']['cause'], $this->data['error']['explanation']);\n }\n\n return 'Unknown Error';\n }", "public function getError() {\n return $this->get(self::ERROR);\n }", "public function getError() {\n return $this->get(self::ERROR);\n }", "public function getMessage()\n {\n return isset($this->data->failure_msg) ? $this->data->failure_msg : '';\n }", "public function getMessageError($response)\n {\n $errors = \\MercadoPago\\Core\\Helper\\Response::PAYMENT_CREATION_ERRORS;\n\n //set default error\n $messageErrorToClient = $errors['NOT_IDENTIFIED'];\n\n if (isset($response['response']) &&\n isset($response['response']['cause']) &&\n count($response['response']['cause']) > 0\n ) {\n\n // get first error\n $cause = $response['response']['cause'][0];\n\n if (isset($errors[$cause['code']])) {\n\n //if exist get message error\n $messageErrorToClient = $errors[$cause['code']];\n }\n }\n\n return $messageErrorToClient;\n }", "public function getErrorMessage(): string\n {\n if ($this->getSuccess()) {\n return '';\n }\n\n return (string) $this->errorMessage;\n }", "public function getErrMsg() {\n return $this->get(self::ERR_MSG);\n }", "public function getMessage()\n {\n return self::getMessageForError($this->value);\n }", "public function getErrMsg()\n {\n return $this->get(self::ERRMSG);\n }", "public function message()\n {\n return $this->getError();\n }", "public function getErrorMessage()\n {\n if (! $this->executed) {\n throw new Exception('Curl request not executed');\n }\n\n return '';\n }", "public function getErrorMessage()\n {\n // then re-apply the error code:\n if(($this->error_code !== 0) && empty($this->error_msg))\n {\n $this->setError($this->error_code);\n }\n return $this->error_msg;\n }", "function error() {\n return $this->error_message;\n }", "public function getError(): string\n {\n return $this->Error;\n }", "public function getErrorText(){\n return $this->error;\n }", "public function getErrorMsg()\n\t{\n\t\treturn $this->error;\n\t}", "public function errorMessage() { return $this->errorMessage; }", "public function errorMessage()\n {\n return $this->provider->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->streamErrorMessage;\n }", "public function getErrorMessage()\n {\n $error = $this->_checkoutSession->getErrorMessage();\n return $error;\n }", "public function getError() {\n return $this->error;\n }", "public function getError() {\n return $this->error;\n }", "public function getError() {\n return $this->error;\n }", "public function getError() {\r\n return $this->error;\r\n }", "public function getErrorResponse()\n {\n $result['responseCode'] = self::RESPONSE_LOGIN_ERROR;\n return $result;\n }", "public function getError() : string\r\n {\r\n return $this->strError;\r\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError() {\n\n return $this->error;\n }", "public static function getErrorMessage(ResponseInterface $response): ?string\n {\n try {\n /** @var scalar|array */\n $error = self::getContent($response)['error'] ?? self::getContent($response) ?? null;\n } catch (RuntimeException $e) {\n return null;\n }\n\n return is_array($error) ? self::getMessageFromError($error) : null;\n }", "protected function getError()\n {\n return json_encode([\n '__type' => basename(__CLASS__) . 'Exception',\n 'Errors' => [\n [\n 'Code' => basename(__CLASS__) . 'CurlError',\n 'Message' => curl_error($this->handler) .'.'\n ]\n ]\n ]);\n }", "public final function last_error_message()\n {\n return isset($this->error) ? $this->error['message'] : '';\n }", "public function getMessage(): string\n\t{\n\t\treturn $this->err->getMessage();\n\t}", "function getMessage()\n {\n return ($this->error_message_prefix . $this->message);\n }", "public function getErrorMessage();", "public function getErrorMessage();", "public function getError()\n {\n if (null == $this->error) {\n $this->error = new MessageContainer();\n }\n return $this->error;\n }", "public function getErrorMessage()\n\t\t{\n\t\t\t$error = $this->statement->errorInfo();\n\t\t\t$errorText \t= '<h6>Something happened ... :(</h6>';\n\t\t\t$errorText .= 'Error code : '.$error[0].'<br>';\n\t\t\t$errorText .= 'Driver error code : '.$error[1].'<br>';\n\t\t\t$errorText .= 'Error Message : '.$error[2].'<br>';\n\t\t\treturn $errorText;\n\t\t}", "private function getResponseMessage(\\Exception $e): string\n {\n return ($this->isValidResponseCode($e))\n ? $this->messages[$e->getCode()]\n : $this->messages[$this->defaultResponseCode];\n }", "public function errorMessage()\n {\n return $this->error;\n }", "public function getError()\r\n {\r\n return count($this->strError) == 0 ? null :\r\n (count($this->strError) == 1 ? $this->strError[0] :\r\n $this->strError);\r\n }", "function getErrorMsg() {\n\t\treturn $this->errorMsg;\n\t}", "public function getError() {}", "public function getError() {\n\t\treturn $this->error;\n\t}", "public function getError() {\n\t\treturn $this->error;\n\t}" ]
[ "0.81947714", "0.73576534", "0.73277676", "0.7265922", "0.7264803", "0.7197107", "0.7172981", "0.71594256", "0.71381795", "0.71135587", "0.7089961", "0.70775896", "0.70765257", "0.7069952", "0.70403314", "0.7039101", "0.7039101", "0.7039101", "0.7039101", "0.7039101", "0.7039101", "0.7039101", "0.70214295", "0.70214295", "0.6994497", "0.6983454", "0.6978649", "0.6974242", "0.6925767", "0.69180787", "0.69031656", "0.68783027", "0.6866715", "0.6857923", "0.6848827", "0.6814598", "0.68092215", "0.67978495", "0.6791202", "0.677609", "0.67728955", "0.67728955", "0.6772855", "0.67718697", "0.6758521", "0.6732832", "0.67135054", "0.6692514", "0.6689138", "0.6675719", "0.6666985", "0.6660814", "0.66560143", "0.66366655", "0.6620017", "0.6603093", "0.6537421", "0.65233713", "0.6520331", "0.65202475", "0.65202475", "0.65202475", "0.651582", "0.6513039", "0.6501712", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.6484794", "0.64779544", "0.6477517", "0.6477041", "0.64767146", "0.6472531", "0.6466745", "0.6453666", "0.6453666", "0.64406615", "0.64393437", "0.64334303", "0.6432892", "0.64245594", "0.64174", "0.6415909", "0.64069647", "0.64069647" ]
0.6456764
89
Check if a index from the data array exists.
public function offsetExists($key) { return array_key_exists($key, $this->data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function offsetExists($index);", "public function offsetExists($index)\n {\n }", "public function offsetExists($index) : bool\n {\n return isset($this->samples[$index]);\n }", "public function offsetExists($key){\n return isset($this->data[$key]);\n }", "public function offsetExists ( $offset )\r\n {\r\n return array_key_exists($offset, $this->data);\r\n }", "public function offsetExists($index) : bool\n {\n return isset($this->a[$index]);\n }", "public function offsetExists($offset)\n {\n if(isset($this->data) && is_array($this->data) && array_key_exists($offset, $this->data))\n {\n return true;\n }\n return false;\n }", "#[\\ReturnTypeWillChange]\n public function offsetExists($key)\n {\n return array_key_exists($key, $this->data);\n }", "public function offsetExists($offset)\n {\n return is_array($this->data) && array_key_exists($offset, $this->data);\n }", "public function offsetExists($offset) {\n\t return isset($this->data[$this->index][$offset]);\n\t }", "public function offsetExists($offset)\r\n {\r\n return array_key_exists($offset, $this->data);\r\n }", "public function offsetExists ($offset) {\n return array_key_exists($offset, $this->_data);\n }", "public function offsetExists( $index )\n {\n return isset( $this->_values[ $index ] );\n }", "public function offsetExists($offset) {\n\t\treturn isset($this->data[$offset]);\n\t}", "public function offsetExists($offset) {\n\t\treturn isset($this->data[$offset]);\n\t}", "public function offsetExists($index)\n\t{\n\t\tif (isset(self::$global[$index]))\n\t\t{\n\t\t\treturn true;\n\t\t}\n\n\t\treturn parent::offsetExists($index);\n\t}", "public function offsetExists($index): bool\n {\n if (!($exists = parent::offsetExists($index))) {\n if (isset($this->{$index})) {\n return true;\n }\n }\n return $exists;\n }", "public function offsetExists($key): bool;", "public function offsetExists($index)\r\n\t{\r\n\t\treturn isset($this->elements[$this->keyAssocation[$index]]);\r\n\t}", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]) ? true : false;\n }", "public function indexExist(int $index): bool {\n\n return isset($this->cells[$index]);\n }", "public function offsetExists( $key );", "#[\\ReturnTypeWillChange]\n public function offsetExists($offset)\n {\n return array_key_exists($offset, $this->_data);\n }", "public function offsetExists($offset): bool\n {\n $this->dataToArray();\n\n return array_key_exists($offset, $this->data);\n }", "public function offsetExists($offset) {\n\t\t$result = false;\n\t\t\n\t\tif($this->_data[$offset]) {\n\t\t\t$result = true;\n\t\t}\n\t\t\n\t\treturn $result;\n\t}", "public function offsetExists( $key )\n {\n return isset( $this->data[$key] );\n }", "public function offsetExists($offset) {\n return isset(current($this->_data)[$offset]);\n }", "public function verify_array_index(array & $arr, $index)\n\t{\n\t\treturn (isset($arr[$index]) AND array_key_exists($index, $arr));\n\t}", "public function verify_array_index(array & $arr, $index)\n\t{\n\t\treturn (isset($arr[$index]) AND array_key_exists($index, $arr));\n\t}", "#[\\ReturnTypeWillChange]\n public function offsetExists($index)\n {\n }", "#[ReturnTypeWillChange]\n final public function offsetExists( $key )\n {\n return isset( $this->dataset[$key] );\n }", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "function has ( $index )\n\t{\n\t\treturn !is_null($this->getAt($index)) ;\n\t}", "public /*bool*/ function offsetExists(/*scalar*/ $offset)\n\t{\n\t\treturn isset($this->_data[$offset]);\n\t}", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->_data[$offset]);\n }", "public function offsetExists($offset)\n {\n return isset($this->_data[$offset]);\n }", "public function offsetExists($key)\n\t{\n\t\treturn array_key_exists($key, $this->array);\n\t}", "public function offsetExists($offset);", "public function offsetExists($offset);", "public function offsetExists($index): bool\n {\n throw new \\Exception('Not (yet) supported');\n }", "public function offsetExists($key)\n\t{\n\t\ttry\n\t\t{\n\t\t\treturn (bool) $this->find($key);\n\t\t}\n\t\tcatch (\\OutOfBoundsException $e)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t}", "public function hasIndex() {\n return $this->_has(14);\n }", "public function offsetExists($offset): bool;", "public function offsetExists($offset)\n {\n $data = $this->getData();\n return isset($data[$offset]);\n }", "public function hasIndex(){\n return $this->_has(1);\n }", "public function offsetExists($key): bool\n {\n return isset($this->array[$key]);\n }", "public function offsetExists($offset): bool\n {\n return array_key_exists($offset, $this->array);\n }", "public function offsetExists( $index )\n {\n return $this->_getDelegate()->offsetExists($index);\n }", "public function offsetExists(mixed $offset): bool {\n return array_key_exists($offset, $this->items);\n }", "public function containsIndex($index)\n\t{\n\t\treturn parent::offsetExists($index);\n\t}", "public function offsetExists($offset): bool\n {\n return isset($this->array[$offset]);\n }", "public function offsetExists($key) \n {\n return $this->has($key);\n }", "public function offsetExists($offset) {\n\t\tsettype($offset, 'integer');\n\n\t\tif ($offset >= 0 && $offset < $this->indexMax) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}", "public function offsetExists($key) {\n\t\treturn $this->__isset($key);\n\t}", "public function offsetExists($offset)\n\t{\n\t\treturn isset(self::$arrayMap[$offset]);\n\t}", "public function offsetExists($key)\r\n {\r\n return $this->exists($key);\r\n }", "public static function offsetExists($key)\n {\n return self::has($key);\n }", "public function offsetExists($offset) {\n\t\treturn array_key_exists($offset, $this->access_test_results);\n\t}", "public function offsetExists($offset){\n\t\treturn $this->has($offset);\n\t}", "public function offsetExists($key)\n {\n return isset($this->$key) || isset($this->data[$key]);\n }", "public function offsetExists($offset)\n {\n return array_key_exists($offset, $this->info);\n }", "public function hasIndex(): bool\n {\n return true;\n }", "public function offsetExists($key) {\n\t\treturn $this->has($key);\n\t}", "public function offsetExists( $key )\n\t{\n\t\treturn $this->has( $key );\n\t}", "public function offsetExists($offset): bool\n {\n return isset($this->json()[$offset]);\n }", "public function offsetExists($index)\n {\n return isset($this->entities[$index]);\n }", "function offsetExists($offset)\n {\n return isset($this->items[$offset]);\n }", "public static function checkIdx($idx, $array)\n {\n if (isset($array[$idx]) && !empty($array[$idx])) {\n return true;\n }\n\n return false;\n }", "public function offsetExists($offset)\n {\n return isset($this->view_data[$offset]);\n }", "public final function offsetExists($index) : bool\n {\n return isset($this->children[$index]);\n }", "public function valid()\n {\n return array_key_exists($this->index, $this->keys);\n }", "public function offsetExists($offset)\r\n {\r\n return array_key_exists($offset, $this->_values);\r\n }", "public function hasIndex($index)\r\n {\r\n return isset($this->indexes[$index]);\r\n }", "public function offsetExists($key)\n {\n return $this->__isset($key);\n }", "public function offsetExists($key)\n {\n return $this->__isset($key);\n }", "public function offsetExists($offset)\n\t{\n\t\treturn isset($this->list[$offset]);\n\t}", "public function offsetExists($offset): bool\n {\n return array_key_exists($offset, $this->elements);\n }", "public function offsetExists($offset): bool {\n return array_key_exists($offset, $this->_items);\n }", "function offsetExists($offset)\n\t{\n\t\treturn isset($this->fields[$offset]);\n\t}", "public function offsetExists($offset)\n {\n return isset($this->getValue()[$offset]);\n }", "public function offsetExists(mixed $name): bool\n {\n return $this->has($name);\n }", "public function offsetExists($offset)\n\t\t{\n\t\t\treturn isset($this->source[$offset]);\n\t\t}", "public function offsetExists($offset)\n {\n return isset($this->item[$offset]);\n }", "public function offsetExists($key)\n {\n return array_key_exists($key, $this->items);\n }", "public function offsetExists($key)\n {\n return array_key_exists($key, $this->items);\n }", "public function offsetExists($key)\n {\n return array_key_exists($key, $this->items);\n }" ]
[ "0.7559149", "0.73411554", "0.72237885", "0.72195643", "0.72074515", "0.7186613", "0.7183279", "0.7183202", "0.7175527", "0.71543354", "0.71534973", "0.7130766", "0.71259654", "0.7119464", "0.7119464", "0.71002203", "0.70994794", "0.7088504", "0.70761746", "0.7061529", "0.70558757", "0.7030351", "0.7029145", "0.70253396", "0.7013559", "0.6999334", "0.6994073", "0.69893354", "0.69893354", "0.6989168", "0.6982623", "0.6974296", "0.6974296", "0.6974296", "0.6974296", "0.6974296", "0.6974296", "0.697283", "0.6968209", "0.696649", "0.696649", "0.696649", "0.696649", "0.696649", "0.696649", "0.696649", "0.696649", "0.6939934", "0.6939934", "0.6938532", "0.6926083", "0.6926083", "0.68987465", "0.68918395", "0.6879469", "0.68670005", "0.6863684", "0.68610054", "0.68555695", "0.68279374", "0.68259084", "0.6825184", "0.6796561", "0.67542344", "0.67315364", "0.672686", "0.67127216", "0.6711929", "0.67109567", "0.66810465", "0.6673996", "0.6671835", "0.66709715", "0.6670637", "0.6654596", "0.6646046", "0.6644651", "0.66373163", "0.66290414", "0.66129094", "0.65915716", "0.65880924", "0.6587386", "0.6586617", "0.6585451", "0.6582394", "0.65801334", "0.65801334", "0.6577525", "0.6575578", "0.65745425", "0.6573795", "0.6559905", "0.6549216", "0.6548636", "0.6536454", "0.6533218", "0.6533218", "0.6533218" ]
0.7182617
9
Get an index from the data array.
public function offsetGet($key) { return (array_key_exists($key, $this->data)) ? (array) $this->data[$key] : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getIdx()\n {\n return $this->get(self::_IDX);\n }", "function getIndex() ;", "public static function getIndex(): int\n {\n return static::$index;\n }", "abstract protected function getIndex();", "public function offsetGet($index);", "final public function getArrayIndex(): ?int\n {\n return $this->arrayIndex;\n }", "public function key() {\n\t\t$this->checkResultSet();\n\n\t\tif (! is_null($this->keyColumn)) {\n\t\t\t$row = $this->fetchRowAssoc($this->index, true);\n\t\t\treturn $row[$this->keyColumn];\n\t\t}\n\n\t\treturn $this->index;\n\t}", "public function key(){\n\t\treturn (is_array($this->data) ? key($this->data) : null);\n\t}", "public function get ($index)\n {\n if (isset($this->data[$index])) {\n return $this->data[$index];\n } else {\n throw new IndexOutOfBoundsException();\n }\n }", "public function key(): int\n {\n return $this->_index;\n }", "public function indexOf ($item)\n {\n $index = array_search($item, $this->data);\n return $index === false ? -1 : $index;\n }", "public function key(): int\n {\n return $this->index;\n }", "public function getItemByIndex($i) {\n if(isset($this->data[$i])) :\n return $this->data[$i];\n elseif($i<$this->count()) : \n $keys = array_keys($this->data);\n if(isset($keys[$i])) :\n return $this->data[$keys[$i]];\n endif;\n endif; \n return null;\n }", "public function getIndex();", "public function getIndex();", "public function getIndex();", "function sa_array_index($ary,$idx){\n if( isset($ary) and isset($idx) and isset($ary[$idx]) ) return $ary[$idx];\n}", "public function index(): int\n {\n return $this->index;\n }", "public function get(int $index): mixed;", "function getIDAt ( $index = 0 )\n\t{\n\t\t$item = $this->getAt($index) ;\n\t\t\n\t\treturn !is_null ( $item ) ? str_get_last_int ($str) : null ;\n\t}", "function key()\n\t{\n\t\treturn $this->index;\n\t}", "public function key()\n\t{\n\t\treturn $this->index;\n\t}", "public function key()\n\t{\n\t\treturn $this->index;\n\t}", "public function key() {\n\t\t\treturn $this->index;\n\t\t}", "public function get(int $index);", "public function get(int $index);", "public function key(): mixed\n {\n return key($this->data);\n }", "public function index($data)\n {\n $current = $this->head;\n $i = 0;\n while (($current->data) == $data) \n {\n $i++;\n $current = $current->next;\n }\n return $i;\n }", "public function getIndex() {\r\n\t\treturn $this->_index;\r\n\t}", "public function indexOf($element)\n {\n return array_search($element, $this->data);\n }", "function getArrayFirstIndex($arr) {\n\tforeach ($arr as $key => $value)\n\treturn $key;\n}", "public function getData($key = '', $index = null);", "public function getIndex($name)\n {\n $result = null;\n $array = $this->getDatanamesArray();\n foreach($array as $key=>$row)\n {\n if($result == null && $row==$name) $result = $key;\n }\n return $result;\n\n }", "public function key(){\n return $this->index;\n }", "public function indexOf($value)\n {\n return array_search($value, $this->data, true);\n }", "public function getIndex()\n\t\t{\n\t\t\treturn $this->_index;\n\t\t}", "public function get_pollutant_index($data, $pollutant) \n {\n $indexes = [];\n foreach($data as $key => $value) \n {\n if($key == $pollutant) \n {\n for($i = 0; $i < 13; $i++)\n {\n $indexes[$key][] = isset($value[$i]) ? $this->check_index($key, $value[$i]) : -1;\n }\n }\n }\n return (array_key_exists($pollutant, $indexes) ? $indexes[$pollutant] : array_fill(0, 12, -1));\n }", "function key() {\r\n return $this->i >= 0 ? $this->i : NULL;\r\n }", "public function getIndex()\n {\n return isset($this->index) ? $this->index : null;\n }", "function first_index_arr($arr)\n {\n foreach ($arr as $k => $v) return $k;\n }", "public function key(): string|int\n {\n if ($this->_data instanceof \\Iterator) {\n return $this->out($this->_data->key(), 'key', 'iterator');\n } elseif (is_array($this->_data)) {\n return $this->out(key($this->_data), 'key', 'iterator');\n }\n }", "public function getIndex(): ?int\n {\n return $this->index;\n }", "#[\\ReturnTypeWillChange]\n public function key()\n {\n return key($this->_data);\n }", "#[\\ReturnTypeWillChange]\n public function key()\n {\n return key($this->_data);\n }", "public function offsetGet($index)\n {\n }", "function get_index($array, $index, $required=false){\r\n if ((array_key_exists($index, $array)) &&\r\n (($required === false) || ($required && (!empty($array[$index])))) )\r\n {\r\n return $array[$index];\r\n }\r\n else{\r\n $this->msg .= \"$index is required \" . (($required)?\" and must not be empty \":\" \") . \"\\n\";\r\n }\r\n }", "public function getValue(int $indexX, int $indexY): int;", "public function testIndexOf() {\n\t\t$array = array(1, 2, 3, 4, 5);\n\t\t$result = _::indexOf($array, 4);\n\t\t$this->assertEquals(3, $result);\n\n\t\t// test not finding an element's index\n\t\t$result = _::indexOf($array, 6);\n\t\t$this->assertEquals(-1, $result);\n\t}", "function findStationIndex($checkStationName, $dataArray) {\n foreach($dataArray as $key => $station) \n if ($checkStationName == $station[\"stationName\"]) return $key;\n return -1;\n }", "public static function getArrayItem (array $data, $key)\n\t{\n\t\treturn !empty ($data[$key]) ? $data[$key] : false;\n\t}", "public function &offsetGet($offset)\r\n {\r\n return $this->data[$offset];\r\n }", "public function getIndex(): ?int {\n $val = $this->getBackingStore()->get('index');\n if (is_null($val) || is_int($val)) {\n return $val;\n }\n throw new \\UnexpectedValueException(\"Invalid type found in backing store for 'index'\");\n }", "public function getIndex() {}", "public function key()\n {\n return key($this->array);\n }", "public function key()\n {\n return key($this->array);\n }", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function getIndex() {}", "public function offsetGet($offset)\n {\n return $this->data[$offset];\n }", "public function offsetGet($offset)\n {\n return $this->_data[$offset];\n }", "public function offsetGet($index)\r\n\t{\r\n\t\treturn $this->elements[$this->keyAssocation[$index]];\r\n\t}", "public function offsetGet($offset)\n\t{\n\t\t$data = $this->getData();\n\t\treturn $data[$offset];\n\t}", "#[\\ReturnTypeWillChange]\n function offsetGet($index)\n {\n if (isset($this->{$index})) {\n return $this->{$index};\n } else {\n $records = $this->records();\n if ($index === \"results\") {\n return $records;\n }\n if ($record = &$records[$index]) {\n return $record;\n }\n foreach ((array) $records as $key => $record) {\n if ($record[\"id\"] === $index) {\n $record = &$records[$key];\n return $record;\n }\n }\n }\n\n return null;\n }", "public function getIndex() {\r\n\t\t\treturn $this->index;\r\n\t\t}", "public function offsetGet($offset)\n {\n return $this->array[$offset];\n }", "public function get ($index) { return $this[$index]; }", "public function offset(?int $offset = null) : int;", "public function getIndex() {\n\t\treturn $this->index;\n\t}", "public function getIndex() {\n\t\treturn $this->index;\n\t}", "public function getIndex() {\n\t\treturn $this->index;\n\t}", "public function getIndex() {\n\t\treturn $this->index;\n\t}", "public function key()\n {\n return $this->keys[$this->index];\n }", "public function key() {\n return $this->keys[$this->index];\n }", "function getIndexOfRegistry($registryNumber, $array) {\n $i = 0;\n\t$index = -1;\n\tfor ($i = 0; $i < sizeof($array); $i++) {\n\t\tif ($array[$i][0] == $registryNumber) {\n\t\t\t$index = $i;\n\t\t\tbreak;\n\t\t}\n\t} \n\treturn $index;\n}", "public function index() {\n if ($this->_m_index !== null)\n return $this->_m_index;\n $this->_m_index = ($this->isIndexSeparate() ? $this->indexSeparate() : $this->indexInTag());\n return $this->_m_index;\n }", "function search_loc_index($data, $loc)\n{\n\tforeach($data as $d)\n\t{\n\t\tif($d['loc']==$loc) $index=array_search($d,$data);\n\t}\n\tif(!isset($index)) return false;\n\telse return $index;\n}", "public function key() {\n\t\treturn key($this->array);\n\t}", "public function getIndex() {\n \treturn $this->index;\n }", "public function key()\n\t{\n\t\treturn $this->_keys[$this->_idx];\n\t}", "public function offset() { return $this->_m_offset; }", "public function array_key_index(&$arr, $key) {\n\t\t$i = 0;\n\t\t$arr_keys = array_keys($arr);\n\t\tforeach ($arr_keys as $k) {\n\t\t\tif ($k == $key) {\n\t\t\t\treturn $i;\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\t}", "function element_size_data_array_index($size){\n\tif ( $size == \"\" or $size == 100 ) return 0;\n\telse if ( $size == 75 ) return 1;\n\telse if ( $size == 50 ) return 2;\n\telse if ( $size == 25 ) return 3;\n}", "public function key() {\n\t\treturn key($this->_data);\n\t}", "public function key ()\n {\n return $this->offset;\n }", "private function get_event ($idx) {\n\t\tif (isset($idx)) {\n\n\t\t\t# try index as key\n\t\t\tif (array_key_exists($idx, $this->data))\n\t\t\t\treturn $this->data[$idx];\n\n\t\t\t# try integer index translation\n\t\t\telse {\n\t\t\t\t$keys = array_keys ($this->data);\n\n\t\t\t\tif (array_key_exists($idx,$keys)) {\n\t\t\t\t\t$key = $keys[$idx];\n\n\t\t\t\t\tif (array_key_exists($key, $this->data))\n\t\t\t\t\t\treturn $this->data[$key];\n\t\t\t\t\telse\n\t\t\t\t\t\treturn False;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\treturn False;\n\t\t\t}\n\t\t}\n\t}", "public function getIndex() : ?string\n {\n return $this->index;\n }", "public function getValue($index) {}", "public function firstKey(): int|string|null\n {\n return array_key_first($this->data);\n }", "public function arrayElemAt($array, $index): static;", "public function batchIndex(): ?int;", "function getMiiInfoIndex($index){\n return $this->miiInfo[$index];\n }", "public function getValue($index){\n\n if(is_object($this->data)){\n return $this->data->$index;\n }\n return isset($this->data[$index]) ? $this->data[$index] : null;\n }", "protected function getIndices($data)\n\t{\n\t\t$indices = array();\n\n\t\tfor ($counter = 0; $counter < 3; $counter++)\n\t\t{\n\t\t\t$value = '';\n\t\t\t$keyName = wbArrayGet($this->indices, $counter, '');\n\t\t\tif (!empty($keyName))\n\t\t\t{\n\t\t\t\tif (is_array($data))\n\t\t\t\t{\n\t\t\t\t\t$value = wbArrayGet($data, $keyName, '');\n\t\t\t\t}\n\t\t\t\telse if (is_object($data))\n\t\t\t\t{\n\t\t\t\t\t$value = empty($data->{$keyName}) ? '' : $data->{$keyName};\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$indices['key_' . ($counter + 1)] = $value;\n\t\t}\n\n\t\treturn $indices;\n\t}", "public function getDataOffset() : int{\n return $this->dataOffset;\n }", "public function offsetGet($idx)\t\t\t//\teg. var_dump($obj['two']);\r\n\t{\r\n\t\treturn $this->members[$idx];\r\n\t}", "public function offsetGet ($offset) {\n return $this->__fields[$offset]['data'];\n }" ]
[ "0.70701844", "0.6743048", "0.65265036", "0.63313276", "0.6261514", "0.6223711", "0.6153173", "0.6127401", "0.6096573", "0.60831356", "0.6068003", "0.6049266", "0.5988996", "0.5982205", "0.5982205", "0.5982205", "0.59726965", "0.5959033", "0.5950047", "0.59311485", "0.5928332", "0.5921313", "0.5921313", "0.59154314", "0.59151876", "0.59151876", "0.59108055", "0.58708066", "0.5866794", "0.585811", "0.5808496", "0.58058536", "0.58045113", "0.5799636", "0.5784795", "0.57825774", "0.57640266", "0.57632244", "0.5762686", "0.57578444", "0.5756822", "0.57547647", "0.5731596", "0.5731596", "0.5707853", "0.56783986", "0.56767726", "0.56684554", "0.56682396", "0.5653077", "0.56525105", "0.56517595", "0.5643398", "0.5643218", "0.5643218", "0.5642674", "0.5642674", "0.5642674", "0.5642", "0.5642", "0.5642", "0.5641827", "0.5641827", "0.56299406", "0.5623031", "0.56218874", "0.56198496", "0.56146574", "0.56068945", "0.56033933", "0.55987203", "0.5586484", "0.55859876", "0.55859876", "0.55859876", "0.55859876", "0.5583758", "0.5576955", "0.55757093", "0.5574668", "0.55704296", "0.5567865", "0.5563919", "0.55627155", "0.5555532", "0.5522467", "0.5501244", "0.5498307", "0.54898673", "0.5489015", "0.5484025", "0.54774904", "0.54682577", "0.5466372", "0.5464516", "0.5462741", "0.54608285", "0.5460376", "0.54595464", "0.5459117", "0.54543716" ]
0.0
-1
Unset an index in the data array.
public function offsetUnset($key) { if (array_key_exists($key, $this->data)) { unset($this->data[$key]); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function offsetUnset($index);", "public function offsetUnset($index)\n {\n }", "public function offsetUnset($index):void {\n\tunset($this->_elArray[$index]);\n\t$this->_elArray = array_values($this->_elArray);\n}", "public function unsetItemArray($index)\n {\n unset($this->itemArray[$index]);\n }", "public function offsetUnset($index)\n {\n unset($this->entities[$index]);\n }", "public function offsetUnset($offset);", "public function offsetUnset($offset);", "public function offsetUnset($key)\n {\n unset($this->data[$key]);\n }", "public function offsetUnset($key)\n {\n unset($this->data[$key]);\n }", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($index)\n\t{\n\t\tif (isset($this->_messages[$index]))\n\t\t{\n\t\t\tarray_splice($this->_messages, $index, 1);\n\t\t}\n\t}", "public function offsetUnset($key){\n if($this->offsetExists($key)){\n unset($this->data[$key]);\n }//if\n }", "public function offsetUnset($offset)\n {\n unset($this->_data[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->_data[$offset]);\n }", "public function offsetUnset( $key );", "public function offsetUnset($offset)\n {\n unset($this->data[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->data[$offset]);\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($key)\n {\n unset($this->data[$key]);\n }", "public /*void*/ function offsetUnset(/*scalar*/ $offset)\n\t{\n\t\tif(isset($this->_data[$offset]))\n\t\t\tunset($this->_data[$offset]);\n\t}", "public function offsetUnset($index)\r\n\t{\r\n\t\t$this->count--;\r\n\t\tunset($this->elements[$this->keyAssocation[$index]]);\r\n\t\tunset($this->keyAssocation[$index]);\r\n\t\tif( $index == $this->i )\r\n\t\t{\r\n\t\t\t$this->i--;\r\n\t\t}\r\n\t\treturn $this->elements[$this->i];\r\n\t}", "public /*void*/ function offsetUnset(/*scalar*/ $offset){}", "public function offsetUnset($offset)\n {\n if ($this->offsetExists($offset))\n {\n unset($this->data[$offset]);\n }\n }", "public function offsetUnset($offset)\n {\n if ($this->offsetExists($offset)) {\n unset($this->data[$offset]);\n }\n }", "public function offsetUnset($index): void\n {\n throw new \\Exception('Not (yet) supported');\n }", "abstract public function wipeIndex();", "public function offsetUnset($key): void;", "public function offsetUnset($offset): void;", "public function offsetUnset($key)\n {\n }", "public function offsetUnset( $offset ) {\n\t\t// ...\n\t}", "public function offsetUnset($index) : void\n {\n if (isset($this->children[$index])) {\n \\array_splice($this->children, $index, 1);\n }\n }", "public function offsetUnset($offset) {\n $this->remove(array($offset));\n }", "public function dropIndex(): void;", "public function unsetAttributeSet($index)\n {\n unset($this->attributeSet[$index]);\n }", "public function offsetUnset($key)\n\t{\n\t\t$this->updating();\n\t\tunset($this->array[$key]);\n\t}", "public function offsetUnset($offset)\n {\n }", "public function unsetUniqueID($index)\n {\n unset($this->uniqueID[$index]);\n }", "public function offsetUnset( $index )\n {\n throw new UnmodifiableException(\"This collection cannot be changed\");\n }", "public function offsetUnset($offset): void\n {\n unset($this->array[$offset]);\n }", "public function unsetTiming($index)\n {\n unset($this->timing[$index]);\n }", "public function unsetItemID($index)\n {\n unset($this->itemID[$index]);\n }", "public function offsetUnset($offset)\n {\n unset($this->getValue()[$offset]);\n }", "function offsetUnset(/*. mixed .*/ $offset)\n\t\t/*. throws BadMethodCallException .*/ {}", "public function revertIndex($index, $dataType);", "public function remove(int $index);", "public function remove(int $index);", "public function offsetUnset(mixed $offset): void {\n unset($this->items[$offset]);\n }", "public function offsetUnset($offset)\n\t{\n\t\t$this->remove($offset);\n\t}", "public function offsetUnset($offset)\n\t{\n\t\t$this->remove($offset);\n\t}", "public function offsetUnset($offset)\n\t\t{\n\t\t\tunset($this->source[$offset]);\n\t\t}", "public function offsetUnset ($offset) {\n $this->__fields[$offset]['data'] = null;\n }", "public function offsetUnset($key) {\n\t\t$this->remove($key);\n\t}", "public function offsetUnset($offset)\n\t{\n\t\t// TODO: Implement offsetUnset() method.\n\t}", "public function offsetUnset($key)\r\n {\r\n $this->remove($key);\r\n }", "public function offsetUnset($offset)\n {\n unset($this->item[$offset]);\n }", "public function offsetUnset($offset)\n {\n $this->remove($offset);\n }", "public function unsetAdditional($index)\n {\n unset($this->additional[$index]);\n }", "function offsetUnset($offset) {\n $property = defined('static::$DOMAIN_PROPERTY') ? static::$DOMAIN_PROPERTY : 'data';\n \n unset($this->{$property}[$offset]);\n }", "public function offsetUnset($offset) {\n return;\n }", "public function remove($index);", "public function offsetUnset($key) {\n\t\tunset($this->sets[$key]);\n\t}", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "public function offsetUnset($offset){\n\t\t$this->set($offset, null);\n\t}", "public function offsetUnset($offset)\n {\n $this->clear($offset);\n }", "public function offsetUnset($offset) {\n unset($this->_items[$offset]);\n }", "public function offsetUnset($offset)\n\t{\n\t\t$this->store()->offsetUnset($offset);\n\t}", "public function offsetUnset($name)\n\t{\n\t\t$this->remove ( $name );\n\t}", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "public function offsetUnset(mixed $offset): void\n {\n $this->delete((string) $offset);\n }", "public function offsetUnset($offset): void\n {\n }", "public function unsetInvCounts($index)\n {\n unset($this->invCounts[$index]);\n }", "public function offsetUnset($key)\n {\n unset(static::$origin[$key]);\n }", "public function offsetUnset($offset)\n {\n $this->unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->unset($offset);\n }", "public function __unset($key) {\n unset(current($this->_data)[$key]);\n }", "public function offsetUnset ($offset)\n {\n unset($this->elements[$offset]);\n }", "public function offsetUnset($offset) {\n\t\tif(!array_key_exists($offset, $this->_data)) {\n\t\t\tthrow new \\Bedrock\\Model\\Record\\Exception('The specified column \"' . $offset . '\" is not a part of this record, the value was not unset.');\n\t\t}\n\t\t\n\t\tunset($this->_data[$offset]);\n\t}", "public function unsetSignature($index)\n {\n unset($this->signature[$index]);\n }", "public function offsetUnset( $key )\n {\n if ( !isset( $this->data[$key] ) )\n {\n throw new ezcGraphNoSuchDataSetException( $key );\n }\n\n unset( $this->data[$key] );\n }", "public function offsetUnset($key)\n {\n $this->forget($key);\n }", "public function offsetUnset($key)\n {\n $this->forget($key);\n }", "public function unsetRefundTransactionArray($index)\n {\n unset($this->refundTransactionArray[$index]);\n }", "public function unsetVariationKey($index)\n {\n unset($this->variationKey[$index]);\n }", "public function offsetUnset($offset)\n {\n $this->getIterator()->offsetUnset($offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->attributes[$offset]);\n }", "public function offsetUnset(mixed $offset): void\n {\n unset($this->items[$offset]);\n }", "public function offsetUnset($offset)\n\t{\n\t\tif(isset(self::$arrayMap[$offset])) {\n\t\t\t$this->{self::$arrayMap[$offset]} = null;\n\t\t}\n\t}", "public function unsetRefPoint($index)\n {\n unset($this->refPoint[$index]);\n }", "function offsetUnset($key)\n\t{\n\t\tif (isset($this->fields[$key]))\n\t\t\tunset($this->fields[$key]);\n\t}", "function removeAt($index)\r\n\t\t{\r\n\t\t\tarray_splice($this->elements, $index, 1);\r\n\t\t}", "public function removeAt( $index )\n\t\t{\n\t\t\tif( isset( $this->items[(int)$index] ))\n\t\t\t{\n\t\t\t\tunset( $this->items[(int)$index] );\n\t\t\t\t$this->items = array_values( $this->items );\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tthrow new \\System\\Base\\ArgumentOutOfRangeException(\"Argument out of range in \".get_class($this).\"::removeAt()\");\n\t\t\t}\n\t\t}" ]
[ "0.8245711", "0.80493176", "0.77757126", "0.7304811", "0.71038955", "0.7077767", "0.7077767", "0.70621645", "0.70621645", "0.7022848", "0.7022848", "0.70225894", "0.70225894", "0.70225894", "0.7007129", "0.6998982", "0.69857854", "0.69857854", "0.69629085", "0.6962833", "0.6962833", "0.6942324", "0.69332427", "0.6928506", "0.6919017", "0.6808875", "0.6799885", "0.67675596", "0.67634785", "0.6746595", "0.6732771", "0.668857", "0.66676927", "0.66671973", "0.6629715", "0.6629015", "0.65825313", "0.65616775", "0.65554124", "0.6551654", "0.6550375", "0.65486836", "0.6540885", "0.6523311", "0.6518199", "0.6454487", "0.64503974", "0.6443928", "0.6443928", "0.64432514", "0.6430107", "0.6430107", "0.6427691", "0.6423428", "0.6416502", "0.6393052", "0.6390316", "0.638647", "0.6376615", "0.6370404", "0.636888", "0.6348503", "0.63422066", "0.63391846", "0.63368905", "0.63368905", "0.63368905", "0.63368905", "0.6336453", "0.6329036", "0.6322449", "0.6320383", "0.63198316", "0.63110065", "0.62994385", "0.62994385", "0.62994385", "0.6293566", "0.6290611", "0.6287569", "0.62837607", "0.62820405", "0.62820405", "0.6281057", "0.6271372", "0.6266746", "0.62577873", "0.6254203", "0.6245881", "0.6245881", "0.62451357", "0.62379616", "0.62292755", "0.6225712", "0.6223114", "0.6221762", "0.62217414", "0.621687", "0.6215063", "0.6214028" ]
0.7037412
9
Set value to an index in the data array.
public function offsetSet($key, $value) { $this->data[$key] = $value; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function set(int $index, $value);", "public function offsetSet($index, $newval);", "public function set($index, $value)\n {\n $value = $this->cube($value);\n parent::set($index, $value);\n }", "#[\\ReturnTypeWillChange]\n public function offsetSet($index, $value)\n {\n }", "public function offsetSet($index, $newval)\n {\n }", "public function set($index, $v) {\n $i = ($this->top + $index) % $this->size;\n $this->buf[$i] = $v;\n }", "public function offsetSet($index, $newval)\n {\n parent::offsetSet($index, $newval & 0xff);\n }", "public function offsetSet($index, $value) {\n return;\n }", "public function offsetSet($index, $newval)\n\t{\n\t\tif ($index === null)\n\t\t{\n\t\t\t$this[] = $newval;\n\t\t}\n\t\telse\n\t\t{\n\t\t\tparent::offsetSet($index, $newval);\n\t\t}\n\t}", "public function __set($index, $value) {\n $this->vars[$index] = $value;\n }", "public function offsetSet($offset, $value)\r\n {\r\n $this->data[$offset] = $value;\r\n }", "public function setIndex($pValue) {\n\t\t$this->index = $pValue;\n\t}", "final public function __set($index, $value)\n {\n $this->_registry->$index = $value;\n }", "public function setElement(int $index, string $value): void {\n if($index >= $this->length()) {\n $this->elements[] = $value;\n } else {\n $this->elements[$index] = $value;\n }\n }", "public static function set($index, $value)\n {\n self::$registry[$index] = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->data[$offset] = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->data[$offset] = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->_data[$offset] = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->_data[$offset] = $value;\n }", "public function offsetSet($key, $value): void\n {\n if (is_array($this->_data)) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } elseif ($this->_data instanceof \\ArrayAccess) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } else {\n throw new \\Exception('Cannot use object of type ' . get_class($this->_data) . ' as array');\n }\n }", "public function offsetSet($offset,$value) {\n if (is_null($offset)) {\n current($this->_data)[] = $value;\n } else {\n current($this->_data)[$offset] = $value;\n }\n }", "public function offsetSet($offset, $value);", "public function offsetSet($offset, $value);", "public function __set($index, $value) {\n\n\t\tif ($this->_hasAdapter(get_class(), __FUNCTION__))\n\t\t\treturn $this->_callAdapter(get_class(), __FUNCTION__, $index, $value);\n\n\t\t$filtered = $this->_applyFilter(get_class(), __FUNCTION__, array(\n\t\t\t'index' => $index,\n\t\t\t'value' => $value\n\t\t), array('event' => 'args'));\n\t\t\n\t\t$index = $filtered['index'];\n\t\t$value = $filtered['value'];\n\n\t\tif ($this->_collection === null) {\n\t\t\t$this->_collection = new Collection();\n\t\t}\n\t\t$this->_collection->addWithName($index, $value);\n\t\t$this->_notify(get_class() . '::' . __FUNCTION__, $index, $value);\n\t}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($key, $value)\n {\n $this->setData($key, $value);\n }", "public function offsetSet($offset,$value) {\n if ($offset == \"\") {\n\t $this->_data[] = $value;\n\t}else {\n\t $this->_data[$offset] = $value;\n\t}\n }", "public function offsetSet($index, $object)\r\n\t{\r\n\t\tif( $index === null )\r\n\t\t{\r\n\t\t\t$index = $object->get($this->obj->primaryKey);\r\n\t\t}\r\n\r\n\t\tif( !isset($this->keyAssocation[$index]) )\r\n\t\t{\r\n\t\t\t$this->keyAssocation[$index] = $this->count++;\r\n\t\t}\r\n\r\n\t\t$this->elements[$this->keyAssocation[$index]] = $object;\r\n\t}", "public function offsetSet($offset, $value)\n {\n if (!is_null($offset)) {\n $this->data[$offset] = $value;\n }\n }", "public function setValue($value){\n if(is_array($value)){\n $this->_data = $value;\n }else{\n throw new SmartestException(\"SmartestArray::setValue() expects an array; \".gettype($value).\" given.\");\n }\n }", "public function setIndex(?int $value): void {\n $this->getBackingStore()->set('index', $value);\n }", "private function setStepValue(int $index, AliasedQueryField $field, array &$data, $value) {\n $finalStep = ($index == count($field->path));\n if($finalStep) {\n \t$data[$field->aliasedField->field->name] = $this->getSqlValueForModel($field->aliasedField->field, $value);\n } else {\n $step = $field->path[$index];\n if(!array_key_exists($step, $data)) {\n $data[$step] = array();\n }\n $this::setStepValue($index + 1, $field, $data[$step], $value);\n }\n }", "public function set($offset, $value);", "public function offsetSet($offset , $value) {\n $this->_items[$offset] = $value;\n }", "public function offsetSet($offset, $value) { }", "public function offsetSet($offset, $value)\n {\n if ($offset == null)\n {\n $this->data[] = $offset;\n }\n else\n {\n $this->data[$offset] = $value;\n }\n $this->size++;\n }", "function offsetSet($key, $value)\n\t{\n\t\t$this->fields[$key] = $value;\n\t}", "public function offsetSet($offset, $value)\n {\n $this->item[$offset] = $value;\n }", "public function set($index, $value)\n {\n\n if(($index < 0) || ($index >= $this->dim))\n {\n throw new VectorException(\"Index out of bounds\");\n }\n\n $this->vector[$index] = $value;\n }", "public function offsetSet( $offset, $value ) {\n\t\t// ...\n\t}", "public function set ($index, $item)\n {\n if (isset($this->data[$index])) {\n $buffer = $this->data[$index];\n $this->data[$index] = $item;\n } else {\n throw new IndexOutOfBoundsException();\n }\n return $buffer;\n }", "public function offsetSet( $key, $value );", "public final function offsetSet($index, $child) : void\n {\n $this->insert($index, $child, \\true);\n }", "public function offsetSet($key,$value)\n {\n if( !in_array($key,$this->_allowed_variables) )\n {\n\ttrigger_error('Modification of internal data is deprecated: '.$key,E_USER_NOTICE);\n }\n $this->_data[$key] = $value;\n }", "public function setData (array $data) : void {\n\t\t$this->data = $data;\n\t}", "public function offsetSet($offset, $value)\n {\n $this->getValue()[$offset] = $value;\n }", "public function offsetSet($key, $value) {}", "public function setData($key, $value);", "public function setData($key, $value);", "public function offsetSet($offset, $value): void;", "public /*void*/ function offsetSet(/*scalar*/ $offset, /*mixed*/ $value){}", "public function offsetSet($offset, $value) \n {\n }", "public function setIdx($value)\n {\n return $this->set(self::_IDX, $value);\n }", "public function setDataAtOffset($data, Array $offset = []);", "#[\\ReturnTypeWillChange]\n public function offsetSet($key, $value)\n {\n if (is_null($key)) {\n $this->data[] = $value;\n } else {\n $this->data[$key] = $value;\n }\n }", "public function offsetSet($offset, $value)\n {\n if (is_null($offset)) {\n $this->data[] = $value;\n } else {\n $this->data[$offset] = $value;\n }\n }", "public function offsetSet($offset, $value)\n {\n if (is_null($offset)) {\n $this->data[] = $value;\n } else {\n $this->data[$offset] = $value;\n }\n }", "public function offsetSet($offset, $value)\n {\n if ($offset === null) {\n $this->data[] = $value;\n } else {\n $this->data[$offset] = $value;\n }\n }", "protected function setData($key, $value)\n {\n $this->data[$key] = $value;\n }", "public function __set($key, $value) {\n $this->pos = 0;\n $this->data[$key] = $value;\n $this->keys = array_keys($this->data);\n }", "public function set_value($set_value = NULL,$index = NULL,$item = NULL){\n if(is_null($index)){\n $this->ini_file_array = $set_value;\n } else if(is_null($item)){\n $this->ini_file_array[\"$index\"] = $set_value;\n } else {\n $this->ini_file_array[\"$index\"][\"$item\"] = $set_value;\n }\n }", "public /*void*/ function offsetSet(/*scalar*/ $offset, /*mixed*/ $value)\n\t{\n\t\tif($offset === null) {\n\t\t\t$this->_data[] = $value;\n\t\t} else {\n\t\t\t$this->_data[$offset] = $value;\n\t\t}\n\t}", "public function offsetSet($key,$value){\n if(!array_key_exists($key,$this->definition)){\n throw new \\Disco\\exceptions\\Exception(\"Field `{$key}` is not defined by this data model\");\n }//if\n $this->data[$key] = $value;\n }", "public function offsetSet($index, $value):void {\n\t// Remove all elements in collection:\n\tfor($i = 0; $i < count($this->_elArray); $i++) {\n\t\t$this->offsetUnset($i);\n\t}\n\t$this->rewind();\n\n\t// Create empty array, fill with provided element(s):\n\t$this->_elArray = array();\n\n\tif(is_array($value)) {\n\t\t$this->_elArray = $value;\n\t}\n\telse if($value instanceof DomEl) {\n\t\t$this->_elArray[] = $value;\n\t}\n\telse if($value instanceof DomElCollection) {\n\t\tforeach ($value as $el) {\n\t\t\t$this->_elArray[] = $el;\n\t\t}\n\t}\n}", "public function setFromArray(array $data);", "public function setData($data, $key = null);", "public function offsetSet ($offset, $value) {\n $this->__set($offset, $value);\n }", "public function offsetSet($offset,$value)\n\t{\n\t\t$this->store()->offsetSet($offset,$value);\n\t}", "public function setData(array $data) {\n\t\t$this->_data = $data;\n\t}", "public function offsetSet($key, $value)\n {\n if (!(is_string($key) || is_int($key))) {\n throw new \\OutOfRangeException('Offset invalid or out of range');\n }\n\n if ($this->offsetExists($key)) {\n $this->elements[$key]->setValue($value);\n } else {\n $this->push($key, $value);\n }\n }", "public function setFromArray(array &$_data);", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($key, $value)\r\n {\r\n $this->set($key, $value);\r\n }", "public function offsetSet($offset, $value){\n\t\t$this->set($offset, $value);\n\t}", "public function offsetSet($offset, $value) {\n\t\tif(!array_key_exists($offset, $this->_data)) {\n\t\t\tthrow new \\Bedrock\\Model\\Record\\Exception('The specified column \"' . $offset . '\" is not a part of this record, the value was not assigned.');\n\t\t}\n\t\t\n\t\t$this->_data[$offset] = $value;\n\t}", "public function offsetSet(mixed $name, mixed $value) : void\n\t{\n\t\t$this->value($name, $value);\n\t}", "public function offsetSet($key, $value) {\n\t\t$this->set($key, $value);\n\t}", "public function offsetSet($id, $value): void\n {\n $this->values[$id] = $value;\n }", "public function offsetSet( $key, $value )\n\t{\n\t\t$this->set( $key, $value );\n\t}", "public function set($key,$value) {\n $this->_data[$key]=$value;\n }", "public function offsetSet($key, $value) {\n $this->setDatapoint($key, $value);\n }", "public function offsetSet($offset, $value)\n {\n }", "public function offsetSet($offset, $value)\n\t\t{\n\t\t\tif(!array_key_exists($offset, $this->_columns)) {\n\t\t\t\t$this->_columns[$offset]->setValue($value);\n\t\t\t}\n\t\t}", "public function offsetSet($offset, $value)\n {\n\n\n $this->__set($offset, $value);\n }", "public function offsetSet($offset, $value)\n {\n $this->elements[$offset] = $offset;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }" ]
[ "0.78856045", "0.7456961", "0.73021066", "0.7246528", "0.716867", "0.7123965", "0.7079868", "0.7055483", "0.6742065", "0.67026186", "0.6636163", "0.66285694", "0.662837", "0.6597968", "0.6587619", "0.65538555", "0.65538555", "0.6544865", "0.6544865", "0.65380365", "0.64611983", "0.64375055", "0.64375055", "0.64315766", "0.6386291", "0.63847744", "0.63847744", "0.63847744", "0.63496965", "0.63475746", "0.6342061", "0.63379115", "0.62917924", "0.6289045", "0.62841135", "0.62218946", "0.6207919", "0.620264", "0.6169238", "0.6165761", "0.61539", "0.614097", "0.6137233", "0.61368716", "0.61141443", "0.6077452", "0.6071528", "0.60701376", "0.60686255", "0.60672814", "0.6062655", "0.6062655", "0.6060046", "0.60578644", "0.605441", "0.6054286", "0.60471475", "0.6045042", "0.6040922", "0.6040922", "0.60382414", "0.6036798", "0.60367256", "0.6035236", "0.6034835", "0.6024529", "0.6008107", "0.6003497", "0.5992813", "0.598774", "0.5985644", "0.5982868", "0.59620595", "0.5948338", "0.5943274", "0.59419316", "0.5939791", "0.5936802", "0.59304315", "0.5930364", "0.59298915", "0.59294116", "0.5922262", "0.5900044", "0.5894167", "0.587628", "0.5871499", "0.5864619", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886", "0.58588886" ]
0.67364246
10
Setter for the request response data.
public function setResult($result) { $this->result = $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setResponse($data)\n {\n $this->data = $data;\n return $this;\n }", "public function setResponse() {\n }", "public function setData( ) {\r\n\t\t\tself::callEvent('response.setData', $this, func_get_args());\r\n\t\t}", "public function setResponseCustomData($value)\n {\n $this->_responseCustomData = $value;\n }", "public function setResponseData(array $data)\n {\n $this->responseData = json_encode($data);\n }", "public function set_response($response_data)\n\t{\n\t\t$this->response = (is_array($response_data))\n\t\t\t? json_encode($response_data)\n\t\t\t: $response_data;\n\t}", "public function set_response($response_data)\n\t{\n\t\t$this->response = (is_array($response_data))\n\t\t\t? $this->array2json($response_data)\n\t\t\t: $response_data;\n\t}", "public function setResponse(Response $response) {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "public function setResponse( $response ){\n \n $this->response = $response;\n \n }", "public function setResponse(Response $response) {\n $this->_response = $response;\n $this->_isHandled = true;\n }", "protected function setSessionData()\n {\n $responseData = $this->response->getBody();\n if (strlen($responseData) > 0) {\n $contents = str_replace('$SID', $this->session->getName() . '=' . $this->session->getId(), $responseData);\n $contents = str_replace('$SESSION_NAME', $this->session->getName(), $contents);\n $this->response->replaceBody(str_replace('$SESSION_ID', $this->session->getId(), $contents));\n }\n }", "public function getResponseData()\n {\n return $this->responseData;\n }", "protected function setResponse(Response $value)\n {\n $this->response = $value;\n }", "public function setResponse(Response $response)\n {\n $this->_response = $response;\n }", "public function setResponse($response)\n\t{\n\t\t$this->response = $response;\n\t}", "public function setResponse(Response $response) {\n $this->response = $response;\n }", "public function getResponseData();", "public function setResponse(Response $response)\n {\n $this->response = $response;\n }", "public function setResponse(Response $response)\n {\n $this->response = $response;\n }", "public function setData(array $data): Response {\n\t\t$this->data = $data;\n\n\t\treturn $this;\n\t}", "public function setResponse(array $response)\n {\n $this->response = $response;\n }", "public function getResponseData()\n {\n if($this->getHttpStatusCode() === 200){\n try{\n $resp = $this->getResponse();\n if(isset($resp->data)){\n $this->responseData = $resp->data;\n }\n }catch (Exception $e){\n\n }\n }\n return $this->responseData;\n }", "protected function response($data = NULL)\n {\n return API::response()->set_data($data);\n }", "public function setResponse(namespace\\Response $response)\n {\n $this->response = $response;\n }", "public function setResponseObject($obj)\n {\n $this->responseObject = $obj;\n }", "public function setResponseObject($obj)\n {\n $this->responseObject = $obj;\n }", "public function setResponseObject($obj)\n {\n $this->responseObject = $obj;\n }", "function updateResponse($name, $value) {\n\t\t\t$this->responseVar[$name] = $value;\n\t\t}", "public function setData($data)\n {\n return $this->set('data', $data);\n }", "private function setResponse($response)\n {\n if (!is_array($response) && !is_object($response)) {\n\n $this->response = json_decode((string) $response, true);\n }\n }", "public function setResponse(Response $response): void;", "public function getResponseCustomData()\n {\n return $this->_responseCustomData;\n }", "public function setResponse(Response $response)\n {\n $this->response = $response;\n \n $this->stopPropagation();\n }", "public function getResponseData()\n {\n return json_decode($this->responseData);\n }", "abstract protected function updateResponse(Model $data);", "public function setData() \n {\n $serverNames = [];\n foreach($this->_jsonRequestedArr as $k=>$obj) {\n $serverNames[] = $obj->s_system;\n }\n $this->_jsonResponseArr[\"server_list\"] = $serverNames;\n }", "public function amend_customize_save_response($data)\n {\n }", "public function amend_customize_save_response($data)\n {\n }", "public function __wakeup()\n {\n $this->response->setBody($this->body);\n }", "public function setResponse(Response $response)\n\t{\n\t\t$this->_output = $output = new Output;\n\t\t$response->setBodyGenerator(function() use($output)\n\t\t{\n\t\t\t$output->sendBody();\n\t\t});\n\t}", "function setResponseMessage($message) {\n $this->responseMessage = $message;\n }", "public function setJsonResponse()\n {\n $this->view->disable();\n\n $this->_isJsonResponse = true;\n $this->response->setContentType('application/json', 'UTF-8');\n }", "abstract protected function getReponseData() ;", "public function setResponse( Response $response )\n {\n $this->response = $response;\n \n # Return object to preserve method-chaining:\n return $this;\n }", "public function setResponse(Response $response)\n\t{\n\t\t$this->response = $response;\n\t\treturn $this;\n\t}", "public function setResponse(Response $response)\n\t{\n\t\t$this->response = $response;\n\t\treturn $this;\n\t}", "public function setResponseContent($responseContent)\n {\n $this->isPopulated = true;\n $this->responseContent = $responseContent;\n }", "private function setResponse($key, $value)\n {\n $this->response[$key] = $value;\n }", "public function setResponse($response)\r\n {\r\n $this->response = $response;\r\n\r\n return $this;\r\n }", "public function setResponse(array $response)\n\t{\n\t\t$this->response = \\Zend\\Json\\Encoder::encode($response);\n\t\treturn $this;\n\t}", "protected function parseResponse()\n {\n $data = simplexml_load_string($this->body);\n \n $this->data = $data;\n }", "public function setResponse(ResponseInterface $request);", "public function setData($data): ApiResponse\n {\n $this->data = $data;\n return $this;\n }", "public function setResponse($response)\n {\n $this->_response = $response;\n return $this;\n }", "function changeResponseModel(IResponseModel $responseModel) {\n $this->body = $responseModel;\n }", "private function setResponseObject($aResponse)\n {\n $this->aRepsonse = (array)$aResponse;\n }", "public function getData()\n {\n return (object) $this->_response;\n }", "protected function restoreResponse($response, $data)\n {\n foreach (['format', 'version', 'statusCode', 'statusText', 'content'] as $name) {\n $response->{$name} = $data[$name];\n }\n foreach (['headers', 'cookies'] as $name) {\n if (isset($data[$name]) && is_array($data[$name])) {\n $response->{$name}->fromArray(array_merge($data[$name], $response->{$name}->toArray()));\n }\n }\n if (!empty($data['dynamicPlaceholders']) && is_array($data['dynamicPlaceholders'])) {\n $response->content = $this->updateDynamicContent($response->content, $data['dynamicPlaceholders'], true);\n }\n $this->afterRestoreResponse(isset($data['cacheData']) ? $data['cacheData'] : null);\n }", "protected function _response() {}", "protected function bindResponse()\r\n {\r\n $responseArray = explode( '&', $this->responseString );\r\n \r\n foreach ( $responseArray as $value ){\r\n $pair = explode( '=', $value );\r\n $this->$pair[0] = $pair[1];\r\n }\r\n }", "public function __set($name, $value)\n {\n $this->response[$name] = $value;\n }", "protected function _setAnswer(Array $data)\n {\n foreach ($this->_response as $parameter => $value)\n {\n if (isset($data[$parameter]))\n {\n $this->_response[$parameter] = $data[$parameter];\n }\n }\n }", "public function setResponse($response)\n {\n $this->response = $response;\n return $this;\n }", "public function setData($data = []): JsonResponse\n {\n $this->setContent($data);\n\n return $this;\n }", "public function prepareResponse();", "public function setRequestData()\n {\n $this->setHeaderInformation();\n }", "public function setSessionData(): void\n {\n $this->response->getSession()->set(\n config('form.session_key'),\n [\n $this->form->getID() => [\n 'data' => $this->body,\n 'messages' => $this->errors\n ]\n ]\n );\n }", "protected function setResponse(Response $value)\n {\n $this->response = $value;\n\n return $this;\n }", "public function afterRestoreResponse($data)\n {\n }", "private function _setReponseArray() {\n try {\n $this->RESP = array(\n 'MSG' => $this->MSG,\n 'STATUS' => $this->STATUS\n );\n } catch (Exception $ex) {\n throw new Exception('Crud Model : Error in _setReponseArray function - ' . $ex);\n }\n }", "private function response() {\n if ($this->responseStatus !== 200) {\n $this->request['format'] = self::DEFAULT_RESPONSE_FORMAT;\n }\n $method = $this->request['format'] . 'Response';\n $this->response = array('status' => $this->responseStatus, 'body' => $this->$method());\n return $this;\n }", "public function setCorrectResponse($value) {\r\n $this->correctResponse = $value->value;\r\n }", "private function response($data) {\n\t\treturn json_decode($data);\n\t}", "protected function setGetData()\n\t{\n\t\t$this->request->addParams($this->query->getParams());\n\t}", "private static function response()\n {\n $response = self::$response;\n self::$response = [Key::STATUS => Key::FAILED, Key::CODE => '', Key::MESSAGE => '', Key::DATA => []];\n return $response;\n }", "public function set_response($response) : self\n {\n if (!isset($this->reponse)) {\n $this->response = $response;\n }\n return $this;\n }", "public function setResponse($response)\n {\n $this->response = $response;\n\n return $this;\n }", "public function setResponse($response)\n {\n $this->response = $response;\n\n return $this;\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function setRequestResponse($request_response)\r\n {\r\n $this->request_response = $request_response;\r\n\r\n return $this;\r\n }", "public function setResponse(\\Pop\\Http\\Response $response)\n {\n $this->response = $response;\n return $this;\n }", "public function setData() \n {\n // Empty, to be overridden \n }", "public function response()\n {\n return $this->response;\n }", "public function response()\n {\n return $this->response;\n }", "function response($code){\n $this->response_code = $code;\n }", "public function setJsonResponse()\n {\n $this->jsonResponse = true;\n return $this;\n }", "public function setResponse($var)\n {\n GPBUtil::checkString($var, True);\n $this->response = $var;\n\n return $this;\n }", "final public function setData($data) {\n $this->data = $data;\n }", "public function respond($data){\n\t\treturn $data;\n\t}", "public function response() {\n return json_decode($this->response);\n }", "public function set ($var, $val = null) {\n $this->response->set($var, $val);\n return $this;\n }", "public static function setData($data) {}", "public function set_data($data)\n {\n $this->data = $data;\n }", "public function setData($data)\r\n {\r\n }", "function get_response() {\n return $this->response;\n }" ]
[ "0.7057189", "0.6906759", "0.672676", "0.670948", "0.66523653", "0.6644643", "0.64952546", "0.64920646", "0.64062196", "0.64062196", "0.64062196", "0.64062196", "0.64062196", "0.6326301", "0.6245579", "0.620724", "0.6196949", "0.6165999", "0.6130629", "0.6117045", "0.61064154", "0.60429436", "0.6026306", "0.6026306", "0.60230273", "0.60210204", "0.60197365", "0.6006348", "0.6003367", "0.58620805", "0.58620805", "0.58620805", "0.5853254", "0.579068", "0.5779749", "0.5756703", "0.5734094", "0.5726887", "0.5715652", "0.5712241", "0.569356", "0.56918824", "0.56918824", "0.5681771", "0.567724", "0.5675456", "0.56580865", "0.56571716", "0.56342924", "0.562212", "0.562212", "0.5621276", "0.56156886", "0.5606929", "0.55921274", "0.5585543", "0.5585361", "0.5577969", "0.5571543", "0.5569155", "0.5565521", "0.5561611", "0.5556607", "0.5551799", "0.5546224", "0.5541854", "0.5537298", "0.5528919", "0.55217963", "0.55180824", "0.5515849", "0.55118746", "0.54872394", "0.54763865", "0.54745936", "0.543927", "0.54332626", "0.54321426", "0.5426543", "0.54172605", "0.54145133", "0.54096067", "0.54096067", "0.53868645", "0.53868645", "0.5382465", "0.53574204", "0.5356336", "0.5334966", "0.5334966", "0.53276426", "0.5319169", "0.5317642", "0.53172994", "0.5312482", "0.5309001", "0.5298685", "0.5298439", "0.529474", "0.5283334", "0.527708" ]
0.0
-1
Getter for the request response data.
public function getResult() { return $this->result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getResponseData()\n {\n return $this->responseData;\n }", "public function getResponseData()\n {\n if($this->getHttpStatusCode() === 200){\n try{\n $resp = $this->getResponse();\n if(isset($resp->data)){\n $this->responseData = $resp->data;\n }\n }catch (Exception $e){\n\n }\n }\n return $this->responseData;\n }", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "protected function getReponseData() {}", "public function getData()\n {\n return (object) $this->_response;\n }", "function getData() {\n return $this->body->getResponse();\n }", "public function getResponseData();", "public function getResponseData()\n {\n return json_decode($this->responseData);\n }", "public function getRequestResponse()\r\n {\r\n return $this->request_response;\r\n }", "private function getResponseData()\n {\n $response = Shopware()->Front()->Response();\n\n return array(\n 'Class' => get_class($response),\n 'Raw header' => $response->getRawHeaders(),\n 'Response code' => $response->getHttpResponseCode(),\n 'Exception' => $response->getException()\n );\n }", "public function getResponse() {\n\t\treturn $this->data->getResponse();\n\t}", "protected function getResponse()\n {\n return $this->response;\n }", "protected function getResponse()\n {\n return $this->response;\n }", "public function getResponseCustomData()\n {\n return $this->_responseCustomData;\n }", "public function getData()\n {\n return $this->data->reply;\n }", "function getResponse() {\n\t\treturn $this->Response;\n\t}", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }", "abstract protected function getReponseData() ;", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }", "public function getResponse() {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->get('response');\n }", "public function getResponse()\n {\n return $this->get('response');\n }", "public function getRequestData()\n {\n return json_decode($this->requestData);\n }", "public function getResponse(): mixed\n {\n return $this->response;\n }", "public function getResponse ()\n {\n return $this->response;\n }", "protected function getData()\n {\n return $this->data;\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function getResponse()\r\n {\r\n return $this->response;\r\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse()\n {\n return $this->response;\n }", "public function getResponse(){\n \n return $this->response;\n \n }", "public function response()\n {\n return $this->response;\n }", "public function response()\n {\n return $this->response;\n }", "public function getData()\n\t{\n if ( is_string($this->_data) ) {\n return $this->_data; \n }\n\t\telse \n return $this->_internal_request->to_postdata();\n\t}", "public function getData() {\r\n return $this->data;\r\n }", "public function getResponse() {\r\n\r\n return $this->response;\r\n\r\n }", "public function getResponse() {\n\t\treturn $this->response;\n\t}", "function get_response() {\n return $this->response;\n }", "public function getResponse() {\n return $this->_response;\n }", "public function getResponse() {\n\n return $this->response;\n }", "public function getData() {\n return $this->data;\n }", "public function getData() {\n return $this->data;\n }", "public function getData() {\n return $this->data;\n }", "public function getData() {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }", "public function getData()\n {\n return $this->data;\n }" ]
[ "0.83580416", "0.78542835", "0.78058815", "0.78058815", "0.78058815", "0.78058815", "0.78058815", "0.7741458", "0.76655674", "0.7561207", "0.746805", "0.7322797", "0.72867405", "0.72804654", "0.72486496", "0.72169244", "0.71974903", "0.71782905", "0.71314627", "0.7124275", "0.7124275", "0.7124275", "0.7117855", "0.7109675", "0.7109675", "0.7109675", "0.7109675", "0.7106635", "0.7106635", "0.7100658", "0.7099558", "0.709163", "0.7087651", "0.70866156", "0.70866156", "0.708525", "0.70799565", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078829", "0.7078635", "0.70716923", "0.70716923", "0.70342535", "0.7032466", "0.7030206", "0.70260566", "0.70260435", "0.70196044", "0.70175594", "0.70169646", "0.70169646", "0.70169646", "0.70169646", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994", "0.69912994" ]
0.0
-1
Setter for the error message of the request.
public function setMessage($message) { $this->message = $message; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setErrorMessage($message)\n {\n $this->message = $message;\n }", "public static function setError($message)\n {\n self::put(\"error\", $message);\n }", "public function setErrorMessage($var)\n {\n GPBUtil::checkString($var, True);\n $this->error_message = $var;\n\n return $this;\n }", "private static function setErrorMessage($message) {\n if (self::$_messages[self::$_inputElement][self::$_validationRule]) {\n $message = self::$_messages[self::$_inputElement][self::$_validationRule];\n }\n array_push(self::$_response, ucfirst($message));\n }", "public function setErrMsg($value) {\n return $this->set(self::ERR_MSG, $value);\n }", "public function get_error_message() {\n\t\treturn $this->error_message;\n\t}", "public function setError(string $value = ''): Response {\n\t\t$this->error = $value;\n\n\t\treturn $this;\n\t}", "protected function setErrorMessage(Message $msg) {\n $this->errors->clearContent()->append($msg);\n return $this;\n }", "public function setErrMsg(\\SKBuiltinString $value=null)\n {\n return $this->set(self::ERRMSG, $value);\n }", "public function setErrorMessage($e){\n //checks if error message is cause due to invalid characters\n if($e -> getMessage() == EnumStatus::$InvalidCharactersError){\n //if so those are removed.\n $this -> saveDisplayName = strip_tags($this -> saveDisplayName);\n $this -> saveUserName = strip_tags($this -> saveUserName);\n }\n $this -> message = $e -> getMessage();\n }", "function get_error_message() {\n return $this->error_msg;\n }", "public function setErrorResponse($message)\r\n {\r\n $this->setResponse(self::STATUS_CODE_ERROR, $message);\r\n }", "public function getErrorMessage()\n {\n // then re-apply the error code:\n if(($this->error_code !== 0) && empty($this->error_msg))\n {\n $this->setError($this->error_code);\n }\n return $this->error_msg;\n }", "public function setError($var)\n {\n GPBUtil::checkString($var, True);\n $this->error = $var;\n\n return $this;\n }", "public function setError($msg) {\n $this->__isError = true;\n $this->__errorMsg = $msg;\n }", "public function error(string $message): Message\n {\n $this->text = $this->filter($message);\n $this->type = \"button_error icon-error\";\n return $this;\n }", "public function setFailedMessage($val)\n {\n $this->_propDict[\"failedMessage\"] = $val;\n return $this;\n }", "public function setErrorMessage($errorMessage) {\n if (!($errorMessage instanceof Message)) {\n $errorMessage = new Message($errorMessage);\n }\n $this->errorMessage = $errorMessage;\n return $this;\n }", "protected function setError($msg)\n {\n }", "protected function setErrorMessage($message) {\n\t\t$this->lastError = $message;\n\t\treturn $this;\n\t}", "public function setMsgError($error) {\r\n $this->msg_error = $error;\r\n }", "public function setErrorMessage(?string $value): void {\n $this->getBackingStore()->set('errorMessage', $value);\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function setErrorMSG($errorMSG) {\n if(is_string($errorMSG)){\n switch ($errorMSG) {\n case \"nameError\":\n $this->nameError = \"<small class='error'>Invalid name: Name has to be longer than 2 character and only alphabetic or numeric character</small>\";\n break;\n case \"imageError\":\n $this->imageError = \"<small class='error'>Invalid picture: Picture must be smaller than 3MB and be of types JPG/JPEG, PNG or GIF</small>\";\n break;\n case \"priceError\":\n $this->priceError = \"<small class='error'>Invalid price: Price must be between 1 - 10000 and be of numeric characters</small>\";\n break;\n case \"descError\":\n $this->descError = \"<small class='error'>Invalid description: Description must be longer than 10 characters </small>\";\n break;\n default:\n break;\n }\n }\n }", "public function getMessage()\n {\n return $this->_error;\n }", "protected function _setError($msg)\n\t{\n\t\tValidator::ensureParameterIsString($msg);\n\t\t$this->_usrError = $msg;\n\t}", "function setError($message, $code)\n {\n $this->errorMsg\n = $this->errorMsg\n ? $this->errorMsg\n : $message;\n $this->errorIdentifier\n = $this->errorIdentifier\n ? $this->errorIdentifier\n : \"$this->moduleName / $code\";\n }", "public function setError($msg)\n {\n array_push($this->errors, $msg);\n }", "public function error($message = '')\n {\n $this->success = false;\n $this->message($message);\n\n return $this;\n }", "function setError($message) {\n global $error;\n $error = (object) array(\n 'message' => $message\n );\n }", "function setError ($msg) {\r\n $this->errors[]=$msg;\r\n }", "private function _setErrorMessage($errorCode = '')\n {\n $this->errorMessage = trans('evatr::messages.'.$errorCode);\n }", "public function getErrorMessage()\r\n {\r\n return $this->error_message;\r\n }", "public function getErrorMessage()\n {\n return $this->error_message;\n }", "public function setError($v)\n {\n if ($v !== null) {\n $v = (string) $v;\n }\n\n if ($this->error !== $v) {\n $this->error = $v;\n $this->modifiedColumns[OrdrhedTableMap::COL_ERROR] = true;\n }\n\n return $this;\n }", "public function error(string $message)\n {\n $this->message('error', $message);\n }", "public function message()\n {\n return $this->error_message;\n }", "public function setPropertyNotValidErrorMessage(string $errorMessage);", "public function setErrorMessage($errorMessage)\n\t{\n\t\t$this->errorMessage = $errorMessage;\n\t}", "public function message()\n {\n return $this->errorText;\n }", "public function setError(string $name, string $error): void\n {\n $this->getInputFilter()->setMessage($name, $error);\n }", "private function setErrorMessage(ServerRequest $request, $message)\n {\n $messages = (array)$request->getSession()->read('Flash.flash');\n $messages[] = [\n 'key' => 'flash',\n 'element' => 'Flash/error',\n 'params' => [],\n 'message' => $message,\n ];\n $request->getSession()->write('Flash.flash', $messages);\n }", "public function setErrorMessage($errorMessage)\n {\n $this->errorMessage = $errorMessage;\n }", "public function errorMessage() { return $this->errorMessage; }", "public function setMessage() {\n $numArgs = func_num_args();\n\n switch ($numArgs) {\n default:\n return false;\n break;\n\n // A global rule error message\n case 2:\n foreach ($this->post(null) as $key => $val) {\n $this->_errorPhraseOverrides[$key][func_get_arg(0)] = func_get_arg(1);\n }\n break;\n\n // Field specific rule error message\n case 3:\n $this->_errorPhraseOverrides[func_get_arg(1)][func_get_arg(0)] = func_get_arg(2);\n break;\n }\n\n return true;\n }", "public function getErrorMessage() {\n return $this->errorMessage;\n }", "public function SetError($msg=null) {\n if ($msg==null) { return $this->SetError(\"No message set\"); }\n $this->error_msg = $msg;\n return false;\n }", "public function message()\n {\n return \"Ошибочное значение\";\n }", "public function message()\n {\n return 'The validation error messagess.';\n }", "protected function setError($message, $code)\n\t{\n\t\t$this->error = true;\n\t\t$this->errorMessage = $message;\n\t\t$this->errorCode = $code;\n\t}", "function getErrorMessage()\n\t{\n\t\t// Ah, we have a custom message, use that.\n\t\tif ($this->errorMessage) {\n\t\t\treturn $this->errorMessage;\n\t\t}\n\t\t\n\t\t// Field is required, but empty, so return a fill in this form message.\n\t\telse if ($this->required && $this->value == false) \n\t\t\treturn sprintf($this->getTranslationString(\"Please fill in the required '%s' field.\"), $this->label);\n\t\n\t\t// Have we got an empty error message? Create a default one\n\t\telse if (!$this->errorMessage) {\n\t\t\treturn sprintf($this->getTranslationString(\"There's a problem with value for '%s'.\"), $this->label);\n\t\t} \n\t}", "public function message(): string\n {\n return $this->errorMessage;\n }", "public static function setErrorMessage($msg){\n $_SESSION[UtilMessage::ERROR_REGISTER] = $msg;\n }", "protected function setError($msg)\n {\n $this->error_count++;\n if ($this->Mailer == 'smtp' and !is_null($this->smtp)) {\n $lasterror = $this->smtp->getError();\n if (!empty($lasterror['error'])) {\n $msg .= $this->lang('smtp_error') . $lasterror['error'];\n if (!empty($lasterror['detail'])) {\n $msg .= ' Detail: '. $lasterror['detail'];\n }\n if (!empty($lasterror['smtp_code'])) {\n $msg .= ' SMTP code: ' . $lasterror['smtp_code'];\n }\n if (!empty($lasterror['smtp_code_ex'])) {\n $msg .= ' Additional SMTP info: ' . $lasterror['smtp_code_ex'];\n }\n }\n }\n $this->ErrorInfo = $msg;\n }", "public function message()\n {\n return 'Invalid message mark up.';\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function setError($message, $key = null) {\n if (!is_null($key))\n $this->errors[$key] = $message;\n else\n $this->errors[] = $message;\n }", "public function error($message) {}", "public static function setError($message) {\n self::$_class = \"Example\\\\Excel\\\\Controllers\\\\Error\";\n throw new \\Exception($message);\n }", "function setFailMsg($msg) { $this->_failMsg = $msg; }", "public function setError($error = null)\n {\n // validation for constraint: string\n if (!is_null($error) && !is_string($error)) {\n throw new \\InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($error, true), gettype($error)), __LINE__);\n }\n if (is_null($error) || (is_array($error) && empty($error))) {\n unset($this->error);\n } else {\n $this->error = $error;\n }\n return $this;\n }", "function getMessage()\n {\n return ($this->error_message_prefix . $this->message);\n }", "public function getErrorText(){\n return $this->error;\n }", "function error() {\n return $this->error_message;\n }", "public function getMessage()\n {\n return sprintf('The field `%s` should be a valid url!', $this->inputName);\n }", "public function getMessage()\n {\n return self::getMessageForError($this->value);\n }", "public function getErrorMessage()\n\t{\n\t\treturn $this->errorMessage;\n\t}", "public function getErrorMessage() : string\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function setErrorMessage($errorMessage): void\n {\n $this->errorMessage = $errorMessage;\n }", "public function message()\n {\n return __(\"validation.{$this->error}\", ['attribute' => 'nomor sampel']);\n }", "public function setMessage($val)\n {\n $this->_propDict[\"message\"] = $val;\n return $this;\n }", "public function setErrorMessage($errorMessage)\n {\n $this->errorMessage = $errorMessage;\n return $this;\n }", "protected function getErrorMessage(): string\n\t{\n\t\tif($this->input !== null)\n\t\t{\n\t\t\t$errorMessage = $this->input->getErrorMessage();\n\t\t}\n\n\t\treturn $errorMessage ?? $this->defaultErrorMessage;\n\t}", "public function testSetMessageWithUnknownParam()\n {\n $this->_validator->setMessage(\n 'Your value is too long, and btw, %shazam%!',\n Zend_Validate_StringLength::TOO_LONG\n );\n\n $inputInvalid = 'abcdefghij';\n $this->assertFalse($this->_validator->isValid($inputInvalid));\n $messages = $this->_validator->getMessages();\n $this->assertEquals('Your value is too long, and btw, %shazam%!', current($messages));\n }", "public function errorMessage($requestType, $message){\n throw new Zend_Service_Exception('An error occurred making '. $requestType .' request. Message: ' . $message);\n }", "protected function set_error( $code, $message) {\n\t\t$this->errors->add($code, $message);\n\t}", "public function setError($name, $error)\n {\n if (!$this->getInputFilter() instanceof ErrorMessageInterface) {\n throw new NotSupportedException(sprintf(\n 'Method %s::%s() is not supported.',\n get_class($this->getInputFilter()),\n __FUNCTION__\n ));\n }\n $this->getInputFilter()->setMessage($name, $error);\n return $this;\n }", "public function setError($status, string $message = null)\n {\n $this->setDot('json.error', $status);\n\n if (!is_null($message)) {\n $this->setDot('json.message', $message);\n }\n\n return $this;\n }", "public function getErrorMessage() {\n return '';\n }", "public function message()\n {\n return $this->getError();\n }", "public function setErrorName($error_name){\n $this->error_name = $error_name;\n return $this;\n }", "public function errorMessage() {\n\t\t\treturn $this->strError; \n\t\t}", "public function setError($value) {\n return $this->set(self::ERROR, $value);\n }", "public function setError($value) {\n return $this->set(self::ERROR, $value);\n }", "public function errorMessage()\n {\n $errorMsg = '<strong>' . $this->getMessage() . \"</strong><br />\\n\";\n return $errorMsg;\n }", "public function setError($err);", "public function message()\n {\n if ($this->error['type'] === 'custom') {\n return $this->error['message'];\n }\n\n $messages = null;\n\n if ($this->request) {\n $messages = $this->request->messages();\n }\n\n $message = $messages[\"{$this->error['attribute']}.check_file_{$this->error['type']}\"] ??\n trans(\"validation.check_file_{$this->error['type']}\");\n\n [$keys, $values] = Arr::divide($this->error['payload'] ?? []);\n\n $keys = \\array_map(function (string $key) {\n return \":{$key}\";\n }, $keys);\n\n return \\str_replace($keys, $values, $message);\n }", "public function message()\n {\n return $this->errorMsg;\n }" ]
[ "0.70196766", "0.68773913", "0.6723925", "0.6573697", "0.6528886", "0.64550316", "0.64394414", "0.64194375", "0.641526", "0.63873845", "0.6387179", "0.6356192", "0.6323535", "0.63085884", "0.6308522", "0.62914616", "0.62890977", "0.62883675", "0.6284402", "0.6244223", "0.6236712", "0.6219433", "0.61683947", "0.61683947", "0.61683947", "0.61683947", "0.61683947", "0.61683947", "0.6126288", "0.61119884", "0.6101332", "0.6098545", "0.6074088", "0.60532594", "0.603731", "0.6031976", "0.60309553", "0.6030337", "0.60222524", "0.60122365", "0.6009213", "0.6008646", "0.6004602", "0.6004408", "0.60006267", "0.59801435", "0.59740657", "0.59696645", "0.59677577", "0.5962394", "0.59566265", "0.5952364", "0.5942579", "0.59397894", "0.59331113", "0.59216225", "0.591854", "0.59110045", "0.59057146", "0.5903356", "0.58680826", "0.58680826", "0.58680826", "0.58680826", "0.58680826", "0.58680826", "0.58680826", "0.5867345", "0.58492273", "0.58425456", "0.58208525", "0.57991856", "0.5780243", "0.5762208", "0.57619524", "0.5759647", "0.5753801", "0.57463986", "0.5741007", "0.5727884", "0.5727884", "0.57254857", "0.5724302", "0.57194656", "0.571646", "0.57106644", "0.5710152", "0.5707927", "0.5705863", "0.56957424", "0.5692275", "0.56873006", "0.5678751", "0.5675694", "0.5674868", "0.56747156", "0.56747156", "0.5665265", "0.56607217", "0.5658222", "0.56461006" ]
0.0
-1
Getter for the error message of the request.
public function getMessage() { return $this->message; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get_error_message() {\n\t\treturn $this->error_message;\n\t}", "public function getMessage()\n {\n return $this->_error;\n }", "public function getErrorMessage()\n {\n return $this->error_message;\n }", "function get_error_message() {\n return $this->error_msg;\n }", "public function message()\n {\n return $this->error_message;\n }", "public function message()\n {\n return $this->errorText;\n }", "public function getErrorMessage()\r\n {\r\n return $this->error_message;\r\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage() {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n {\n return $this->errorMessage;\n }", "public function message()\n {\n return $this->getError();\n }", "public function message(): string\n {\n return $this->errorMessage;\n }", "function getMessage()\n {\n return ($this->error_message_prefix . $this->message);\n }", "public function getMessage()\n {\n return self::getMessageForError($this->value);\n }", "public function getErrorMessage() : string\n {\n return $this->errorMessage;\n }", "public function getErrorMessage()\n\t{\n\t\treturn $this->errorMessage;\n\t}", "public function getErrorMessage()\n {\n // then re-apply the error code:\n if(($this->error_code !== 0) && empty($this->error_msg))\n {\n $this->setError($this->error_code);\n }\n return $this->error_msg;\n }", "protected function getErrorMessage(): string\n\t{\n\t\tif($this->input !== null)\n\t\t{\n\t\t\t$errorMessage = $this->input->getErrorMessage();\n\t\t}\n\n\t\treturn $errorMessage ?? $this->defaultErrorMessage;\n\t}", "public function message()\n {\n return $this->errorMsg;\n }", "public function getErrMsg() {\n return $this->get(self::ERR_MSG);\n }", "function error() {\n return $this->error_message;\n }", "public function getErrorMessage()\n {\n return $this->singleValue('//i:errorMessage');\n }", "public function getErrMsg()\n {\n return $this->get(self::ERRMSG);\n }", "public function getErrorMessage()\n\t{\n\t\treturn $this->_errorMessage;\n\t}", "public function getError(): string\n {\n return $this->error;\n }", "public function getMessage(): string\n\t{\n\t\treturn $this->err->getMessage();\n\t}", "public function message()\n {\n if ($this->error['type'] === 'custom') {\n return $this->error['message'];\n }\n\n $messages = null;\n\n if ($this->request) {\n $messages = $this->request->messages();\n }\n\n $message = $messages[\"{$this->error['attribute']}.check_file_{$this->error['type']}\"] ??\n trans(\"validation.check_file_{$this->error['type']}\");\n\n [$keys, $values] = Arr::divide($this->error['payload'] ?? []);\n\n $keys = \\array_map(function (string $key) {\n return \":{$key}\";\n }, $keys);\n\n return \\str_replace($keys, $values, $message);\n }", "public function getMessage()\n {\n return isset($this->data->failure_msg) ? $this->data->failure_msg : '';\n }", "public function errorMessage() { return $this->errorMessage; }", "public function getError(): string\n {\n return $this->Error;\n }", "public function getError() {\n return $this->get(self::ERROR);\n }", "public function getError() {\n return $this->get(self::ERROR);\n }", "public function errorMessage()\n {\n return $this->error;\n }", "public function getError()\n {\n\n if (!$this->getResponse()) {\n return null;\n }\n\n if ($this->isOK()) {\n return null;\n }\n\n $message = ($this->getResponse()->getStatusCode() ? $this->getResponse()->getStatusCode() . ' ' : '') .\n ($this->getResponse()->getReasonPhrase() ? $this->getResponse()->getReasonPhrase() : 'Unknown response reason phrase');\n\n try {\n\n $data = $this->getJson();\n\n if (!empty($data->message)) {\n $message = $data->message;\n }\n\n if (!empty($data->error_description)) {\n $message = $data->error_description;\n }\n\n if (!empty($data->description)) {\n $message = $data->description;\n }\n\n } catch (Exception $e) {\n }\n\n return $message;\n\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "public function message()\n {\n return 'The validation error message.';\n }", "function getErrorMessage()\n\t{\n\t\t// Ah, we have a custom message, use that.\n\t\tif ($this->errorMessage) {\n\t\t\treturn $this->errorMessage;\n\t\t}\n\t\t\n\t\t// Field is required, but empty, so return a fill in this form message.\n\t\telse if ($this->required && $this->value == false) \n\t\t\treturn sprintf($this->getTranslationString(\"Please fill in the required '%s' field.\"), $this->label);\n\t\n\t\t// Have we got an empty error message? Create a default one\n\t\telse if (!$this->errorMessage) {\n\t\t\treturn sprintf($this->getTranslationString(\"There's a problem with value for '%s'.\"), $this->label);\n\t\t} \n\t}", "public function errorMessage()\n {\n return $this->provider->errorMessage;\n }", "final public function error_get() : string{\r\n return (string) ($this->code != 0) ? \"[<b>{$this->code}</b>]: \".$this->message : $this->message;\r\n }", "public function message()\n {\n return $this->doorman->error;\n }", "public function getMsgError() {\r\n return $this->msg_error;\r\n }", "public function getErrorMessage() {\n return '';\n }", "public function getError() : string\r\n {\r\n return $this->strError;\r\n }", "function getErrorMsg() {\n\t\treturn $this->errorMsg;\n\t}", "public function getErrorMessage();", "public function getErrorMessage();", "public function getErrorMessage(): string\n {\n if ($this->getSuccess()) {\n return '';\n }\n\n return (string) $this->errorMessage;\n }", "public function getError(){\n if (empty($this->getErrorCode())) {\n return null;\n }\n return $this->getErrorCode().': '.$this->getErrorMessage();\n }", "public function getErrorMessage() {\n return curl_error($this->curl_handle);\n }", "public function message()\n {\n return 'The validation error messagess.';\n }", "public function getErrorMessage(): ?string {\n\t\t// 1. a string with an error message (e.g. `{\"error\":{\"code\":404,\"errors\":\"invalid token\"},\"success\":false}`)\n\t\t// 2. an object (e.g. `{\"error\":{\"code\":120,\"errors\":{\"name\":\"payload\",\"reason\":\"required\"}},\"success\":false}`)\n\t\t//\n\t\t// Below is an attempt to make sense of such craziness.\n\t\t$error = $this->getValue('[error][errors]');\n\t\tif ($error === null) {\n\t\t\treturn null;\n\t\t}\n\n\t\tif (!is_array($error)) {\n\t\t\t$error = [\n\t\t\t\t'name' => 'generic',\n\t\t\t\t'reason' => $error,\n\t\t\t];\n\t\t}\n\n\t\treturn sprintf(\n\t\t\t'name=%s, reason=%s',\n\t\t\t(array_key_exists('name', $error) ? $error['name'] : 'missing'),\n\t\t\t(array_key_exists('reason', $error) ? $error['reason'] : 'missing')\n\t\t);\n\t}", "public function getErrorMessage()\n {\n return $this->applyTemplate();\n }", "public function errorMessage()\n\t{\n\t\treturn $this->_source->errorMessage();\n\t}", "public function getErrorText(){\n return $this->error;\n }", "public function getError() {\n return $this->error;\n }", "public function getError() {\n return $this->error;\n }", "public function getError() {\n return $this->error;\n }", "public function getMessage(): string\n {\n return $this->requireString('message');\n }", "public function getErrorMessage()\n {\n return $this->streamErrorMessage;\n }", "public function getError() {\r\n return $this->error;\r\n }", "public function getErrorMsg()\n\t{\n\t\treturn $this->error;\n\t}", "public function errorMessage() {\n\t\t\treturn $this->strError; \n\t\t}", "public function getError() {\n\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getError()\n {\n return $this->error;\n }", "public function getMessage()\n {\n return $this -> message;\n }", "public function errorMessage()\n {\n $errorMsg = '<strong>' . $this->getMessage() . \"</strong><br />\\n\";\n return $errorMsg;\n }", "public function getMessage()\n {\n return $this->msg;\n }", "function errorMsg() {\r\n return \r\n $this->resultError;\r\n }", "public function getError() {\n\t\treturn $this->error;\n\t}", "public function getError() {\n\t\treturn $this->error;\n\t}", "public function getError() {\n\t\treturn $this->error;\n\t}", "public final function last_error_message()\n {\n return isset($this->error) ? $this->error['message'] : '';\n }", "public function error(): string\n {\n return $this->error;\n }" ]
[ "0.8135691", "0.8099314", "0.79699486", "0.7960823", "0.79389495", "0.7930202", "0.7919277", "0.7837841", "0.7837841", "0.78227603", "0.77868533", "0.77868533", "0.77868533", "0.77868533", "0.77868533", "0.77868533", "0.77868533", "0.777723", "0.77749425", "0.77377737", "0.76718843", "0.7668456", "0.7646986", "0.7613598", "0.7599487", "0.7570973", "0.75533867", "0.75327784", "0.75266165", "0.75203425", "0.751111", "0.7497795", "0.74821407", "0.74790454", "0.74633276", "0.74107426", "0.7392197", "0.7383523", "0.7383523", "0.73796636", "0.7378963", "0.73633206", "0.73633206", "0.73633206", "0.73633206", "0.73633206", "0.73633206", "0.73594695", "0.73216116", "0.7248333", "0.72312826", "0.723063", "0.72183627", "0.7210268", "0.7208896", "0.720355", "0.720355", "0.71841383", "0.7173339", "0.71719986", "0.7157708", "0.7157584", "0.71542704", "0.71527535", "0.71522784", "0.7150543", "0.7150543", "0.7150543", "0.7146626", "0.7141357", "0.7141284", "0.7131897", "0.7129226", "0.7126751", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7105631", "0.7093546", "0.70802855", "0.70547444", "0.70513856", "0.7033858", "0.7033858", "0.7033858", "0.7032697", "0.70319533" ]
0.0
-1
Getter for the request response as JSON.
public function getJsonResult($assoc = false) { return json_decode($this->result, $assoc); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getJsonResponse() {\n return \\Lib\\Format::forge($this->_response)->to_json();\n }", "public function json() {\n return json_encode($this->response);\n }", "private function jsonResponse() {\n return json_format($this->response, $this->pretty);\n }", "public function getJson()\r\n {\r\n return $this->response;\r\n }", "public function toJSON () {\r\n \treturn json_encode($this->_response);\r\n }", "public function getResponseJSON()\n {\n return $this->response_json;\n }", "private function getJSON(){\n return json_encode($this->getResponseStructure());\n }", "public function responseJson() {\n return Response::json($this->_responseData, $this->_responseCode);\n }", "public function toJson(): mixed\n {\n $this->buildResponse();\n\n return json_decode($this->response->getBody()->getContents());\n }", "public function getJson() {\n\n $output = false;\n\n if ($this->response) {\n\n $json = json_decode($this->response);\n\n if (is_object($json) || is_array($json)) {\n\n $output = $json;\n }\n }\n\n return $output;\n }", "public function json()\n {\n if (! $this->decoded) {\n $this->decoded = json_decode($this->response, true);\n }\n\n return $this->decoded;\n }", "public function json()\n {\n $code = 200;\n\n if (!Request::has(\"no_response_code\") || Request::input('no_response_code') != \"yes\") {\n $code = $this->getCode();\n }\n\n return response()->json($this->getResponse(), $code);\n }", "public function __toString()\n {\n return $this->response->get('json');\n }", "public function response() {\n return json_decode($this->response);\n }", "private function json()\n {\n return json_encode($this->data);\n }", "public function json()\n {\n return json_encode(\n [\n 'errors' => $this->error,\n 'success' => $this->ok,\n 'debug' => $this->debug,\n\n ]\n );\n }", "private function json() {\n if( $this->format === 'application/hal+json' ) {\n header('Content-Type: application/hal+json; charset=utf-8', TRUE, $this->status);\n $hal_response = (new Resource())\n ->setURI(\"/{$this->resource}\". (isset($this->filters['id']) ? $this->filters['id'] : ''))\n ->setLink($this->resource, new Link(\"/{$this->resource}\"))\n ->setData($this->content);\n\n $writer = new Hal\\JsonWriter(true);\n return $writer->execute($hal_response);\n } else {\n header('Content-Type: application/json; charset=utf-8', TRUE, $this->status);\n return json_encode($this->content, JSON_NUMERIC_CHECK);\n }\n }", "public function return_json(){\n\t\t$this->output\n\t ->set_content_type('application/json')\n\t ->set_output(json_encode($this->response));\n\t}", "public function jsonSerialize()\n {\n return $this->getBody(true);\n }", "public function jsonResponse(): string {\n\n header_remove();\n http_response_code(200);\n header('Content-Type: application/json');\n header('Status: 200');\n $response = [\n 'visited' => $this->visited,\n 'cleaned' => $this->cleaned,\n 'final' => $this->final,\n 'battery' => $this->battery\n ];\n\n return json_encode($response,JSON_PRETTY_PRINT);\n }", "public function toJson() : string\n {\n return json_encode($this->toArray(), http_response_code(200));\n }", "public function getJson()\n {\n return $this->Json;\n }", "public function get_json()\n {\n return $this->_json;\n }", "public function getJSON()\r\n\t{\r\n\t\treturn $this->getJSONString();\r\n\t}", "public function getJsonString(){\n\t\treturn json_encode(array($this->getRequestData()));\n\t}", "public function to_string() {\n\n\t\treturn $this->raw_response_json;\n\t}", "public function getSerializeResponse() {\n return \\Lib\\Format::forge($this->_response)->to_serialized();\n }", "public function getJson()\n {\n return $this->_json;\n }", "protected function _getJSONEncodedResponse()\n {\n if (function_exists('__json_encode'))\n {\n return json_encode($this->_Response);\n }\n else\n {\n return $this->_prepareJSONToEval($this->_jsonEncode($this->_Response));\n }\n\n }", "public function getJSON()\n {\n return json_encode($this->getJSONObject());\n }", "public function getJSON(){\n\t\treturn $this->json;\n\t}", "public function toPrettyJSON() {\r\n \treturn json_encode($this->_response, JSON_PRETTY_PRINT);\r\n }", "protected function getControllerJsonResponse()\n {\n return $this->jsonParam;\n }", "public function getJson(){\n\t\treturn $this->json;\n\t}", "public function toJSON()\n\t{\n\t\treturn $this->json;\n\t}", "public function toJSON()\n {\n return json_encode([\n 'statusCode' => $this->getStatusCode(),\n 'timestamp' => $this->getTimestamp(),\n 'date' => $this->getDate(),\n 'baseCurrency' => $this->getBaseCurrency(),\n 'rates' => $this->getRates()\n ]);\n }", "function json_response() {\n return app(JsonResponse::class);\n }", "public function response()\n {\n $metadata = $this->metadata;\n $tmp = array();\n \n if ($this->showConfigRoot != false) {\n $tmp['root'] = $metadata['root'];\n $tmp['totalProperty'] = $metadata['totalProperty'];\n $tmp['successProperty'] = $metadata['successProperty'];\n $tmp['messageProperty'] = $metadata['messageProperty'];\n }\n \n $tmp[$metadata['root']] = (empty($this->data)) ? array() : $this->data;\n $tmp[$metadata['successProperty']] = $this->success;\n \n // if metadata Is String return as Raw else create new array\n if ($this->showMetaData != false)\n if ($metadata['onlyRaw'] === true) {\n $tmp['metaData'] = \"|1|2|3|4|5|...5|||\";\n } else {\n $tmp['metaData'] = $this->metadata;\n }\n $rawJson = json_encode($tmp);\n if ($metadata['onlyRaw'] === true) {\n return str_replace('\"|1|2|3|4|5|...5|||\"', $metadata['raw'], $rawJson);\n }\n \n return $rawJson;\n }", "public function getRequestJson(){\n $requestArray = $this->prepareRequestContent($this->prepareRequestMeta());\n \n return json_encode($requestArray);\n }", "public function getJSON()\n {\n if ($this->json) {\n return $this->json;\n }\n\n $this->json = @json_decode($this->rawBody);\n\n return $this->json;\n }", "public function jsonSerialize()\n {\n $this->present();\n\n return $this->data;\n }", "public function getRawJson()\n {\n return response()->json($this->callApi());\n }", "public function jsonAction()\n {\n $response = new Response(json_encode(['name' => 'John Doe']));\n $response->headers->set('Content-Type', 'application/json');\n\n return $response;\n }", "public function json() \n\t{\n return json_encode($this);\n\t}", "public function jsonSerialize()\n {\n $jsonObject = parent::jsonSerialize();\n $jsonObject->result = $this->information[ self::INFORMATION_RESULT ];\n\n return $jsonObject;\n }", "public function toJson(): string\n {\n $is_success = $this->errors ? false : true;\n\n return json_encode([\n 'status' => $is_success ? 'success' : 'fail',\n 'data' => $this->data,\n 'errors' => $this->errors\n ]);\n }", "public function serialize()\r\n\t{\r\n\t\treturn $this->getJSONString();\r\n\t}", "public function jsonSerialize()\n {\n return [\n \"url\" => $this->url,\n \"method\" => $this->method,\n \"payload\" => $this->render(),\n \"headers\" => $this->headers\n ];\n }", "public function to_json()\n {\n return json_encode($this->body);\n\t}", "public function get_json()\n {\n return json_encode($this);\n }", "public function jsonSerialize()\n {\n return $this->get();\n }", "public function toJson(){\n $info = array(\n \"status\" => $this->status,\n \"authorizedAmount\" => $this->authorizedAmount,\n \"lastFour\" => $this->lastFour,\n \"cardType\" => $this->cardType,\n \"currency\" => $this->currency,\n \"paymentProfileId\" => $this->paymentProfileId\n );\n\n $error = array(\n \"status\" => \"Server returned a \" . $this->status . \"status code.\",\n \"body\" => \"Response Body: <pre>\" . print_r($this->respBody,true) . \"</pre>\",\n \"curlInfo\" => \"Curl Info: <pre>\" . print_r($this->log,true) . \"</pre>\"\n );\n\n return json_encode($this->hasError ? $error : $info);\n }", "public function renderAsJson(): JsonResponse;", "public function jsonSerialize()\n {\n return $this->toJson();\n }", "public function jsonSerialize()\n {\n $json = array();\n $json['request'] = $this->request;\n $json['response'] = $this->response;\n $json['session_token'] = $this->sessionToken;\n $json['tags'] = $this->tags;\n $json['user_id'] = $this->userId;\n $json['company_id'] = $this->companyId;\n $json['metadata'] = $this->metadata;\n\n return $json;\n }", "public function jsonSerialize()\n {\n return $this->getValue();\n }", "public function response($format) {\n switch(strtolower($format)) {\n case \"json\":\n case \"js\":\n default:\n return json_encode($this -> response);\n }\n }", "public function Get(){\n return $this->json;\n }", "public function jsonString(){\n return json_encode($this->createRequestsArray());\n }", "private function _createJson()\n {\n return new SlimBootstrap\\ResponseOutputWriter\\Json(\n $this->_request,\n $this->_response,\n $this->_headers,\n $this->_shortName\n );\n }", "protected function _getJson()\n {\n if ($this->_json) {\n return $this->_json;\n }\n\n return $this->_json = json_decode($this->_getBody(), true);\n }", "private function respond()\n {\n $this->response->header('Content-Type', 'application/json');\n return $this->response;\n }", "public function json(){ return json_encode( $this->objectify() ); }", "public function getJSON()\n {\n return json_encode($this->getVars());\n }", "public function jsonSerialize()\n {\n return array('headers' => $this->headers, 'body' => $this->body);\n }", "public function jsonSerialize()\n {\n return $this->toWei();\n }", "public function getResponse(){\n switch($this->format){\n case 'json':\n $this->response_type = 'application/json';\n return $this -> getJSON();\n break;\n case 'xml':\n $this->response_type = 'text/xml';\n return $this -> getXML();\n break;\n default:\n $this->response_type = 'application/json';\n return $this -> getJSON();\n break;\n }\n }", "public function jsonSerialize()\n {\n return $this->jsonObjectSerialize()->jsonSerialize();\n }", "public function makeJSON()\n {\n return(json_encode($this));\n }", "public function makeJSON()\n {\n return(json_encode($this));\n }", "public function toJson()\n {\n return json_encode($this->jsonSerialize(), JSON_THROW_ON_ERROR);\n }", "public function json();", "public function toJson()\n {\n return json_encode($this->data);\n }", "public function toJson() {\n return $this->jsonSerialize();\n }", "public function toResponse()\n\t{\n\t\treturn $this->toArray();\n\t}", "public function toJson(): string;", "public function toJson(): string;", "public function toJson()\n\t{\n\t\treturn json_encode($this->data());\n\t}", "public function JSONreturn()\n\t{\n\t\techo json_encode( $this->json_return );\n\t}", "public function GetJson(): string\n {\n $json = json_encode($this->GetArray());\n if ($json == false) Error(\"GetJson failed\");\n\n return $json;\n }", "public function toJson() {\n return json_encode($this->data);\n }", "public function getJson() {\n\t\t\treturn json_encode($this->getIterator());\n\t\t}", "public function getJson() {\n\t\t\treturn json_encode($this->getIterator());\n\t\t}", "public function getJson() {\n\t\t\treturn json_encode($this->getIterator());\n\t\t}", "public function toJson() {\n\t\treturn json_encode($this->jsonSerialize());\n\t}", "public function response()\n {\n return $this->response;\n }", "public function response()\n {\n return $this->response;\n }", "protected function asObject()\n\t{\n\t\treturn \\json_decode($this->response);\n\t}", "public function getJsonData()\n {\n $code = ApiReturnCode::SUCCESS;\n return $this->Api->response($code, [\n 'foo' => 'bar',\n 'baz' => 'buff'\n ]);\n }", "public function jsonSerialize()\n {\n return ['environment' => $this->environment,'stepResults' => $this->stepResults, 'duration' => number_format($this->duration,2),'message' => $this->message];\n }", "function jsonSerialize()\n {\n return $this->jsonObjectSerialize()->jsonSerialize();\n }", "public function toJson()\n {\n $array = [];\n if(count($this->_headers))\n {\n $array['Header'] = [\n 'context' => [\n '_jsns' => 'urn:zimbra',\n ],\n ];\n foreach ($this->_headers as $name => $value)\n {\n $array['Header']['context'][$name] = array('_content' => $value);\n }\n }\n if($this->_request instanceof Request)\n {\n $reqArray = $this->_request->toArray();\n $reqName = $this->_request->requestName();\n $array['Body'][$reqName] = $reqArray[$reqName];\n }\n return json_encode((object) $array);\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function response()\r\n {\r\n return $this->response;\r\n }", "public function getResultsInJSON(): string {\n return json_encode($this->getResults());\n }", "public function jsonSerialize() {\n return json_encode($this->value);\n }", "public function jsonSerialize()\n {\n return [\n 'status' => $this->status,\n 'time' => $this->time,\n 'payment' => $this->payment\n ];\n }", "public function jsonize()\n {\n return json_encode($this->toArray());\n }", "public function getJSON(){\n return '{\"tag\":\"'.$this->getTag().'\" , \"name\":\"'.$this->getName().'\" , \"donations\":\"'.$this->getDonations().'\", \n \"received\":\"'.$this->getReceived().',\"tagClan\":\"'.$this->getTagClan().'\"}' ;\n }", "public function getJsonString() {\n return json_encode([\n 'net' => $this->net,\n 'tax' => $this->tax,\n ]);\n }", "public function toJSON() {\n return json_encode($this->data);\n }" ]
[ "0.84805304", "0.8468048", "0.84634763", "0.82887495", "0.8213227", "0.82001394", "0.8115699", "0.791851", "0.7824767", "0.7765755", "0.7735122", "0.75751626", "0.75422025", "0.75387865", "0.7479465", "0.74781424", "0.744064", "0.74295664", "0.7382529", "0.73624605", "0.73566914", "0.7344763", "0.7337252", "0.73330224", "0.7324261", "0.73064107", "0.73020804", "0.72858036", "0.72749555", "0.72500867", "0.72219205", "0.72128576", "0.71979153", "0.7166146", "0.7147957", "0.7135783", "0.7133728", "0.71248794", "0.71166205", "0.71118087", "0.7107245", "0.7106534", "0.70705587", "0.70545584", "0.7049631", "0.70234144", "0.70221525", "0.70091075", "0.70074666", "0.70039296", "0.69975406", "0.69475037", "0.69007957", "0.6897298", "0.6889017", "0.6881621", "0.6872306", "0.68647516", "0.6850558", "0.68494016", "0.68301064", "0.68208", "0.6814955", "0.681394", "0.68126196", "0.6791147", "0.6779774", "0.6778345", "0.6778004", "0.6778004", "0.6759257", "0.67540544", "0.67349607", "0.67337054", "0.6732726", "0.67292666", "0.67292666", "0.6726608", "0.6724484", "0.6722905", "0.6712053", "0.67106694", "0.67106694", "0.67106694", "0.6705406", "0.6703809", "0.6703809", "0.67029744", "0.6702263", "0.66970295", "0.669576", "0.66816986", "0.66808075", "0.66808075", "0.66700625", "0.66529113", "0.66477126", "0.6640795", "0.66397804", "0.6639034", "0.6632121" ]
0.0
-1
Setter for the request response headers.
public function setHeaders($headers) { $this->headers = $headers; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setResponseHeaders($headers)\n { \n // parse the given headers. \n $headers = $this->parseResponseHeaders($headers);\n \n // lowercase all keys in the array.\n $headers = Arrays::normalize($headers);\n if (is_array($this->responseHeaders)) {\n $headers = array_merge_recursive($this->responseHeaders, $headers);\n }\n \n $this->responseHeaders = $headers;\n }", "protected static function get_response_headers()\n {\n }", "protected function outputHeaders() {\n $controlFlags = [];\n if (!$this->cacheable) {\n $controlFlags[] = 'no-store';\n $controlFlags[] = 'no-cache';\n } else {\n if ($this->revalidate) {\n $controlFlags[] = 'no-cache';\n $controlFlags[] = 'must-revalidate';\n }\n $controlFlags[] = $this->private ? 'private' : 'public';\n if ($this->age > 0) {\n $controlFlags[] = 'max-age=' . (int)round($this->age);\n }\n if (!empty($this->ETag)) {\n $this->setHeader('ETag', $this->ETag);\n }\n if (!is_null($this->modifiedDate)) {\n $this->setHeader('Last-Modified', $this->httpUtils->formatDateTime($this->modifiedDate));\n }\n }\n if (!empty($controlFlags)) {\n $this->setHeader('Cache-Control', implode(', ', $controlFlags));\n }\n parent::outputHeaders();\n }", "public function setResponseHeaders(array $headers)\n {\n $this->responseHeaders = $headers;\n }", "protected function sendHeaders()\n {\n http_response_code($this->response_status_code);\n\n // collect current headers into array\n $headers = headers_list();\n\n foreach ($headers as $h) {\n $h_parts = explode(\":\", $h);\n\n if (array_key_exists($h_parts[0], $this->response_headers)) {\n continue;\n }\n\n $this->response_headers[$h_parts[0]] = $h_parts[1];\n }\n\n // response type\n $this->response_headers[\"Content-Type\"] = $this->response_content_type;\n\n if (!is_null($this->response_content_charset)) {\n $this->response_headers[\"Content-Type\"] .= \"; charset=\" . $this->response_content_charset;\n }\n\n // by default remove php version\n unset($this->response_headers[\"X-Powered-By\"]);\n\n // put own headers\n header_remove();\n\n foreach ($this->response_headers as $key => $value) {\n header($key . \":\" . $value);\n }\n\n return;\n }", "public static function set_headers()\n {\n }", "public function setHttpHeaders() {\n $this->_httpHeaders[] = \"Content-Type: application/json\";\n parent::setHttpHeaders();\n }", "public function setHeaders() {\r\n\t\t$this->resource->setHeaders();\r\n\t}", "public function setHeaders()\n {\n }", "abstract public function SetHeaders();", "public function outputRegularHeaders()\n {\n if (headers_sent()) {\n // headers have already been sent - this is an error\n $this->logger->error(\"Headers already sent!\");\n return;\n }\n\n\n if (!$this->client) {\n // client hasn't been used\n $this->logger->error(\"Client not used? (\" . __METHOD__ . \")\");\n return;\n }\n\n\n $response = $this->client->getResponse();\n\n // response code header\n header(\"HTTP/1.1 \" . $response->getResponseCode(), true );\n\n // Set-Cookie: headers if present\n if ($response->hasHeaders() ) {\n foreach ($response->getHeaders() as $name => $value) {\n\t //$this->logger->debug(\" >>\" . $name . \": \" . $value);\n \tif( $name != \"Set-Cookie\" && ( $name == \"Cache-Control\" || $name == \"Expires\" ) ) {\n \t\t// we process cookies separately, due to there being multiple headers\n\t\t\t\t\t$this->logger->debug(\"Setting header: \" . $name . \": \" . $value);\n\t\t\t\t\t//error_log( \"Setting header: \" . $name . \": \" . $value);\n\t\t\t\t\theader($name . \": \" . $value, true);\n \t}\n }\n }\n\n\n $this->outputCookieHeaders();\n\n // Location: header if required (if this is a redirect)\n if ($response->isRedirect() && $response->hasHeader(\"Location\")) {\n header(\"Location: \" . $response->getHeader(\"Location\"), true);\n }\n }", "public function outputHeaders()\n {\n if (headers_sent()) {\n // headers have already been sent - this is an error\n $this->logger->error(\"Headers already sent!\");\n return;\n }\n\n\n if (!$this->client) {\n // client hasn't been used\n $this->logger->error(\"Client not used? (\" . __METHOD__ . \")\");\n return;\n }\n\n\n $response = $this->client->getResponse();\n\n // response code header\n header(\"HTTP/1.1 \" . $response->getResponseCode(), true );\n\n // Set-Cookie: headers if present\n if ($response->hasHeaders() ) {\n foreach ($response->getHeaders() as $name => $value) {\n \tif( $name != \"Set-Cookie\" ) {\n \t\t// we process cookies separately, due to there being multiple headers\n\t\t\t\t\t//$this->logger->debug($name . \": \" . $value);\n\t\t\t\t\theader($name . \": \" . $value);\n \t}\n }\n }\n\n $this->outputCookieHeaders();\n\n // Location: header if required (if this is a redirect)\n if ($response->isRedirect() && $response->hasHeader(\"Location\")) {\n header(\"Location: \" . $response->getHeader(\"Location\"), true);\n }\n }", "private function setHeaders($response)\n {\n $dispositionHeader = $response->headers->makeDisposition(\n ResponseHeaderBag::DISPOSITION_ATTACHMENT,\n $this->filename\n );\n $response->headers\n ->set('Content-Type', 'text/' . ($this->isCSVExport() ? 'csv' : 'vnd.ms-excel') . '; charset=utf-8');\n $response->headers->set('Pragma', 'public');\n $response->headers->set('Cache-Control', 'maxage=1');\n $response->headers->set('Content-Disposition', $dispositionHeader);\n }", "private function _initializeResponseHeaders()\n {\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_CONTENTTYPE] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_CONTENTLENGTH] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_ETAG] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_CACHECONTROL] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_LASTMODIFIED] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_LOCATION] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_STATUS] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_STATUS_CODE] = null;\n $this->_headers[ODataConstants::HTTPRESPONSE_HEADER_STATUS_DESC] = null;\n $this->_dataServiceVersion = null;\n }", "function setHeaders()\n {\n header('Content-type: application/json');\n\n // Calculate Expires Headers if set to > 0\n $expires = $this->grav['config']->get('system.pages.expires');\n if ($expires > 0) {\n $expires_date = gmdate('D, d M Y H:i:s', time() + $expires) . ' GMT';\n header('Cache-Control: max-age=' . $expires);\n header('Expires: '. $expires_date);\n }\n }", "public function setHttpHeaders() {\n $this->_httpHeaders[] = \"Content-Type: application/x-yaml\";\n parent::setHttpHeaders();\n }", "function _setHeaders(){\n header(\"HTTP/1.1 \" . $this->CodeHTTP . \" \" . $this->_getStatusMessage());\n header(\"Content-Type: $this->ContentType\");\n }", "public function setHeaders() : void {\n $this->setCacheHeaders();\n }", "public function sendHeaders(): void\n\t{\n\t\tif ($this->httpResponse === null) {\n\t\t\tthrow new InvalidStateException(sprintf('Cannot send response without %s', Response::class));\n\t\t}\n\n\t\t// Send status code\n\t\t$this->httpResponse->setCode($this->getStatusCode());\n\n\t\t// Send headers\n\t\tforeach ($this->getHeaders() as $name => $values) {\n\t\t\tforeach ($values as $value) {\n\t\t\t\t$this->httpResponse->setHeader($name, $value);\n\t\t\t}\n\t\t}\n\t}", "public function getResponseHeaders()\r\r\n {\r\r\n return $this->responseHeaders;\r\r\n }", "public function getResponseHeaders() {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders()\n {\n return $this->responseHeaders;\n }", "public function getResponseHeaders();", "protected function adjustResponseHeaders($response)\n {\n $requestsRemaining = $this->config['limit'] - $this->cache->get($this->config['keys']['requests']);\n\n if ($requestsRemaining < 0) {\n $requestsRemaining = 0;\n }\n\n $response->headers->set('X-RateLimit-Limit', $this->config['limit']);\n $response->headers->set('X-RateLimit-Remaining', $requestsRemaining);\n $response->headers->set('X-RateLimit-Reset', $this->cache->get($this->config['keys']['reset']));\n\n return $response;\n }", "private static function setHeaders()\n {\n header('X-Powered-By: Intellivoid-API');\n header('X-Server-Version: 2.0');\n header('X-Organization: Intellivoid Technologies');\n header('X-Author: Zi Xing Narrakas');\n header('X-Request-ID: ' . self::$ReferenceCode);\n }", "protected function output_headers()\n\t{\n\t\t$this->add_header('Content-type', $this->content_type);\n\t\tforeach ($this->_headers as $k=>$v) header($k.': '.$v);\n\t}", "public function addHeaders(Response $response = null);", "public function headers($key = null, $value = null)\n {\n $result = $this->_response->headers($key, $value);\n\n if (!$result instanceof Response)\n return $result;\n\n return $this;\n }", "public function registerHeaders(Zend_Controller_Response_Http $response,\n Zend_View_Abstract $view)\n {\n \n }", "protected function setHeaders(): void\n {\n if (empty($this->headers) === false || empty($this->data) === true) {\n return;\n }\n\n $headers = array_keys(reset($this->data));\n\n array_walk($headers, fn(&$header) => $header = ucwords(str_replace(\"_\", \" \", $header)));\n\n $this->headers = $headers;\n }", "public function setHeader($name, $value) {}", "function setResponse(){\n\t// Set the response message header\n\t// This example just sets a basic header response but you may need to \n\t// add some more checks, authentication, etc \n\t$header = array(\n\t\t'status'\t=> 'ok',\n\t\t'message'\t=> 'Service call was successful'\n\t);\n\t\n\treturn $header; \n}", "public function onKernelResponse(ResponseEvent $event): void\n {\n if (!$event->isMainRequest()) {\n return;\n }\n\n $event->getResponse()->headers->set($this->headerName, $this->requestIdProvider->getCurrentRequestId());\n }", "private function setHeaders()\n\t{\n\t\theader(\"Cache-Control: must-revalidate, max-age=12000\");\n\t\theader(\"Vary: Accept-Encoding\");\n\t\theader('Content-Type: text/plain; charset=utf-8');\n\t}", "public function sendHeaders() {\n\n\t\t\tif($this->getHeadersIsSent()) {\n\t\t\t\ttrigger_error(\n\t\t\t\t\t'http response headers already sent, sending again',\n\t\t\t\t\tE_USER_WARNING\n\t\t\t\t);\n\t\t\t}\n\t\t\tforeach($this->getHeadersArray() as $header => $value) {\n\t\t\t\theader($header . ': ' . (string)$value);\n\t\t\t}\n\t\t\t$this->setHeadersIsSent();\n\t\t\treturn $this;\n\n\t\t}", "private function setHeaders(){\n header('Cache-Control: no-cache, must-revalidate');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');\n header('Content-type: application/json charset=utf8');\n }", "public function getResponseHeaders()\r\n\t{\r\n\t\treturn $this->headers;\r\n\t}", "protected function sendHeaders()\n {\n $statusCode = $this->getStatusCode();\n $this->swoole_http_response->status($statusCode);\n if ($this->_headers) {\n $headers = $this->getHeaders();\n foreach ($headers as $name => $values) {\n // Swoole底层不允许设置相同$key的Http头\n $this->swoole_http_response->header($name, end($values));\n }\n }\n $this->sendCookies();\n }", "public function getHeaders() {\n\t\treturn $this->response_headers;\n\t}", "public function setHeaders(array $header) {}", "protected function sendHeaders()\n {\n // setup response code\n http_response_code($this->code);\n\n // send stored cookies\n foreach ($this->cookies as $cookie) {\n call_user_func_array('setcookie', array_values($cookie));\n }\n\n // send stored headers\n foreach ($this->headers as $key => $value) {\n header($key .': '. join(', ', $value));\n }\n }", "public function setHeader($name, $value);", "public function setHeader($name, $value);", "public function setHeader($key,$val){ return $this->headers->set($key,$val); }", "public function setHeader($var)\n {\n GPBUtil::checkMessage($var, \\Etcdserverpb\\ResponseHeader::class);\n $this->header = $var;\n\n return $this;\n }", "public function dumpHeaders(): self\n {\n dump($this->response->getHeaders());\n\n return $this;\n }", "function headers()\n {\n foreach ($this->headers as $rule => $arg) {\n header($rule . ': ' . $arg);\n }\n }", "public function set_headers($headers)\n {\n }", "public function set_headers($headers)\n {\n }", "private function setBaseHeaders(Response $response)\n {\n $response->headers->set('Content-Type', 'application/json');\n $response->headers->set('Access-Control-Allow-Origin', '*');\n\n return $response;\n }", "private function setBaseHeaders(Response $response)\n {\n $response->headers->set('Content-Type', 'application/json');\n $response->headers->set('Access-Control-Allow-Origin', '*');\n\n return $response;\n }", "public function getResponseHeaders(): array\n {\n return $this->responseHeaders;\n }", "public function setHeaders(array $headers): Response {\n\t\t$this->headers = $headers;\n\n\t\treturn $this;\n\t}", "protected function sendHeaders()\n {\n if (headers_sent()) {\n return;\n }\n $headers = $this->getHeaders();\n foreach ($headers as $name => $values) {\n $name = str_replace(' ', '-', ucwords(str_replace('-', ' ', $name)));\n // set replace for first occurrence of header but false afterwards to allow multiple\n// $replace = true;\n foreach ($values as $value) {\n $this->responseBySwoole->header($name,$value);\n// header(\"$name: $value\", $replace);\n// $replace = false;\n }\n }\n $statusCode = $this->getStatusCode();\n// $this->responseBySwoole->header(\"HTTP/{$this->version} {$statusCode} {$this->statusText}\");\n $this->sendCookies();\n }", "protected function setHeader(){\n $this->header = [\n 'Auth-id' => $this->username,\n 'Auth-token' => $this->generateToken(),\n 'Timestamp' => time()\n ];\n }", "public function enableViaHeaders()\n {\n $this->typeResponseCode = true;\n\t}", "protected function cleanHeaders()\n {\n //Clean up header\n $this->headers = ['Accept' => 'application/json'];\n }", "protected function setErrorHeader() {\n\t\tif ($this->response_code >= 400 && $this->response_code < 500) {\n\t\t\theader('HTTP/1.1 ' . $this->response_code . \" \" . SVException::g($this->response_code));\n\t\t\texit(0);\n\t\t}\n\t}", "public function alter_header()\n\t{\n\t\theader(\"HTTP/1.0 $this->code $this->title\");\n\t}", "protected function send_headers() {\n header('Cache-Control: private, must-revalidate, pre-check=0, post-check=0, max-age=0');\n header('Expires: '. gmdate('D, d M Y H:i:s', 0) .' GMT');\n header('Pragma: no-cache');\n header('Accept-Ranges: none');\n }", "public function send_headers()\n\t{\n\t\tif ( ! headers_sent())\n\t\t{\n\t\t\tif (isset($_SERVER['SERVER_PROTOCOL']))\n\t\t\t{\n\t\t\t\t// Use the default server protocol\n\t\t\t\t$protocol = $_SERVER['SERVER_PROTOCOL'];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// Default to using newer protocol\n\t\t\t\t$protocol = 'HTTP/1.1';\n\t\t\t}\n\n\t\t\t// HTTP status line\n\t\t\theader($protocol.' '.$this->status.' '.Request::$messages[$this->status]);\n\n\t\t\tforeach ($this->headers as $name => $value)\n\t\t\t{\n\t\t\t\tif (is_string($name))\n\t\t\t\t{\n\t\t\t\t\t// Combine the name and value to make a raw header\n\t\t\t\t\t$value = \"{$name}: {$value}\";\n\t\t\t\t}\n\n\t\t\t\t// Send the raw header\n\t\t\t\theader($value, TRUE);\n\t\t\t}\n\t\t}\n\n\t\treturn $this;\n\t}", "public function setHeaders($headers)\r\n {\r\n $this->_headers = $headers;\r\n }", "public function sendHttpHeaders() {}", "protected function setRequestHeaders() \n {\n $headers = [];\n\n foreach ($this->headerManager->get() as $key => $value) {\n $headers[] = $key . ': ' . $value;\n }\n\n $this->optionManager->set('HTTPHEADER', $headers);\n\n return $this;\n }", "protected function set_headers()\n\t{\n\t\tif($this->headers_required) { \n\n\t\t\t$this->headers = [\n\t\t\t \n\t\t\t\t'Authorization: '. $_SESSION['token'] .'',\n\t\t\t];\n\n\t\t}\n\n\t}", "protected function setAuthenticationHeader($response, $token = null)\n {\n if ($response instanceof Response) {\n // $token = $token ?: $this->auth->refresh();\n // $response->headers->set('Authorization', 'Bearer ' . $token);\n $response->headers->set('Fromlin', 'it works');\n }\n return $response;\n }", "public function clearHttpHeaders()\n {\n $this->headers = array();\n }", "function setHeaders($headers){\n\t\tforeach($headers as $name => $value){\n\t\t\t$this->setHeader($name,$value);\n\t\t}\n\t}", "function setHeaders(&$headers) {\n\t\t$this->setData('headers', $headers);\n\t}", "public function testHttpResponseHeadersGetSet(UnitTester $I)\n {\n $headers = new Headers();\n\n $headers->set('Content-Type', 'text/html');\n\n $I->assertSame(\n 'text/html',\n $headers->get('Content-Type')\n );\n }", "public function sendHeaders()\n {\n\n $httpCodeSent = false;\n\n foreach ($this->_headersRaw as $header) {\n if (!$httpCodeSent && $this->_httpResponseCode) {\n echo \"HTTP/1.1 \" . $this->_httpResponseCode . \"\\n\"; // we don't actually sent the status code name\n echo $header . \"\\n\";\n $httpCodeSent = true;\n } else {\n echo $header . \"\\n\";\n }\n }\n\n foreach ($this->_headers as $header) {\n if (!$httpCodeSent && $this->_httpResponseCode) {\n echo \"HTTP/1.1 \" . $this->_httpResponseCode . \"\\n\";\n echo $header['name'] . ': ' . $header['value'] . \"\\n\"; // the \"replace\" value is ignored\n $httpCodeSent = true;\n } else {\n echo $header['name'] . ': ' . $header['value'] . \"\\n\"; // the \"replace\" value is ignored\n }\n }\n\n if (!$httpCodeSent) {\n echo \"HTTP/1.1 \" . $this->_httpResponseCode . \"\\n\";\n $httpCodeSent = true;\n }\n\n echo \"\\n\";\n\n return $this;\n }", "public function configureHeaders ()\n {\n $config = $this->app->config('github');\n\n $headers = array(\n 'Accept: application/vnd.github.v3+json',\n sprintf('User-Agent: %s', $config['handle'])\n );\n\n $this->addHeaders($headers);\n }", "public function get_response_headers()\n\t{\n\t\tif ( !$this->executed ) {\n\t\t\tthrow new \\Exception( _t( 'Unable to fetch response headers for a pending request.' ) );\n\t\t}\n\n\t\treturn $this->response_headers;\n\t}", "public function set_header($header, $value);", "public function setHeaders(){\n header('Content-Type: text/cache-manifest');\n header('Cache-Control: no-cache');\n }", "public function set_headers($headers, $override = \\true)\n {\n }", "private function addCommonHeader()\r\n {\r\n $this->response->headers['Allow'] = 'OPTIONS,GET,HEAD,POST,PATCH';\r\n $this->response->headers['Access-Control-Allow-Methods']='OPTIONS,GET,HEAD,POST,PATCH';\r\n $this->response->headers['Access-Control-Allow-Origin']='*';\r\n $this->response->headers['Access-Control-Allow-Headers']= 'Origin, X-Requested-With, Content-Type, Accept, Entity-Length, Offset';\r\n $this->response->headers['Access-Control-Expose-Headers']= 'Location, Range, Content-Disposition, Offset';\r\n }", "public function set_header($key, $value)\n {\n }", "public function setHeader($headerName, $headerValue): void {\n\t\t$this->_responseHeaders[$headerName] = $headerValue;\n\t\theader($headerName . ': ' . $headerValue);\n\t}", "public function populate_headers() {\n // If header is already defined, return it immediately\n if (!empty($this->headers)) {\n return;\n }\n\n // In Apache, you can simply call apache_request_headers()\n if (function_exists('apache_request_headers')) {\n $this->headers = apache_request_headers();\n } else {\n isset($_SERVER['CONTENT_TYPE']) && $this->headers['Content-Type'] = $_SERVER['CONTENT_TYPE'];\n\n foreach ($_SERVER as $key => $val) {\n if (sscanf($key, 'HTTP_%s', $header) === 1) {\n // take SOME_HEADER and turn it into Some-Header\n $header = str_replace('_', ' ', strtolower($header));\n $header = str_replace(' ', '-', ucwords($header));\n\n $this->headers[$header] = $val;\n $this->header_map[strtolower($header)] = $header;\n }\n }\n }\n\n }", "public function getHttpHeaders()\n {\n return [\n 'Content-type' => 'application/json',\n ];\n }", "function setHeaders(array $headers) {\n\t\t$this->_headers = $headers;\n\t}", "public function buildHeaders()\n {\n if ($this->use_cors) {\n if (strlen($this->cors_allow_origin) > 0) {\n header(\"Access-Control-Allow-Origin: $this->cors_allow_origin\");\n }\n if ($this->cors_with_credentials) {\n header('Access-Control-Allow-Credentials: true');\n } else {\n header('Access-Control-Allow-Credentials: false');\n }\n }\n\n // Cache Control RFC: https://tools.ietf.org/html/rfc7234\n if ($this->nb_request instanceof CNabuHTTPRequest &&\n ($nb_site_target = $this->nb_request->getSiteTarget()) instanceof CNabuSiteTarget\n ) {\n if (($max_age = $nb_site_target->getDynamicCacheEffectiveMaxAge()) !== false) {\n $expire_date = gmdate(\"D, d M Y H:i:s\", time() + $max_age);\n $this->setHeader('Expires', $expire_date . 'GMT');\n $this->setHeader('Cache-Control', \"max-age=$max_age\");\n $this->setHeader('User-Cache-Control', \"max-age=$max_age\");\n $this->setHeader('Pragma', 'cache');\n } else {\n $this->setHeader('Expires', 'Thu, 1 Jan 1981 00:00:00 GMT');\n $this->setheader('Cache-Control', 'no-store, no-cache, must-revalidate');\n $this->setHeader('Pragma', 'no-cache');\n }\n if ($nb_site_target->getAttachment() === 'T') {\n if (is_string($this->attachment_filename) && strlen($this->attachment_filename) > 0) {\n $this->setHeader('Content-Disposition', 'attachment; filename=' . $this->attachment_filename);\n } else {\n $this->setHeader('Content-Disposition', 'attachment');\n }\n }\n }\n\n if (($frame_options = $this->calculateFrameOptions()) !== null) {\n $this->setHeader('X-Frame-Options', $frame_options);\n }\n\n if (count($this->header_list) > 0) {\n foreach ($this->header_list as $name => $value) {\n header(\"$name: $value\");\n }\n }\n }", "public function testMultipleHttpHeaders(UnitTester $I)\n {\n $response = $this->getResponseObject();\n $response->resetHeaders();\n $response->setStatusCode(200, 'OK');\n $response->setStatusCode(404, 'Not Found');\n $response->setStatusCode(409, 'Conflict');\n\n $expected = Headers::__set_state(\n [\n 'headers' => [\n 'HTTP/1.1 409 Conflict' => '',\n 'Status' => '409 Conflict',\n ],\n ]\n );\n $actual = $response->getHeaders();\n $I->assertEquals($expected, $actual);\n }", "public function getHttpHeaders()\n {\n return $this->headers;\n }", "protected function setHeaders() {\n\t\tif(!self::$headerIncluded) {\n\n\t\t\tif($this->settings['includes']['jquery'])\n\t\t\t\t$this->response->addAdditionalHeaderData('<script type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js\"></script>');\n\n if($this->settings['includes']['mediaelement'])\n\t\t\t $this->response->addAdditionalHeaderData('<script type=\"text/javascript\" src=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/Vibeo/mediaelement-and-player.min.js\"></script>');\n\n\t\t\tif($this->settings['includes']['jquery-resize'])\n\t\t\t\t$this->response->addAdditionalHeaderData('<script type=\"text/javascript\" src=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/Vibeo/jquery.ba-resize.min.js\"></script>');\n\t\t\tif($this->settings['includes']['modernizr'])\n\t\t\t\t$this->response->addAdditionalHeaderData('<script type=\"text/javascript\" src=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/Vibeo/modernizr-2.5.3.js\"></script>');\n\t\t\t\t\t\t\n\t\t\tif($this->settings['includes']['css'])\n\t\t\t\t$this->response->addAdditionalHeaderData('<link rel=\"stylesheet\" href=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/CSS/tx-vibeo.css\" />');\n\n if($this->settings['includes']['mediaelement-css'])\n\t\t\t $this->response->addAdditionalHeaderData('<link rel=\"stylesheet\" href=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/Vibeo/mediaelementplayer.css\" />');\n\n if($this->settings['includes']['mediaelement-skin-css'])\n $this->response->addAdditionalHeaderData('<link rel=\"stylesheet\" href=\"'.t3lib_extMgm::siteRelPath($this->extKey).'Resources/Public/Vibeo/skin-gray.css\" />');\n\n\t\t\tself::$headerIncluded = true;\n\t\t}\n\t}", "public function setHttpHeader($name, $value = null);", "public function response_headers($header_name=null) {\n $headers = null;\n if(is_array($this->response_headers)) {\n $header_name = strtolower($header_name);\n if($header_name===null) {\n $headers = $this->response_headers;\n } else {\n $headers = key_exists($header_name, $this->response_headers)\n ? $this->response_headers[$header_name]\n : null;\n }\n }\n return $headers;\n }", "protected function setCORSHeaders($response) {\n $response->headers->set('Access-Control-Allow-Origin', '*');\n $response->headers->set('Access-Control-Allow-Methods', 'GET,POST,PUT,PATCH,DELETE,OPTIONS');\n $response->headers->set('Access-Control-Allow-Headers', 'Authorization, Origin, Accept, Content-Type, X-CSRF-Token');\n $response->headers->set('Access-Control-Allow-Credentials', 'true');\n }", "public function headers() {\n return $this->headers;\n }", "public function getResponseHeaders() {\n return array(\n \"Content-Type: application/json\",\n \"Access-Control-Allow-Origin: *\",\n \"Access-Control-Allow-Methods: GET, POST, PUT, DELETE, OPTIONS\",\n \"Access-Control-Allow-Headers: Origin, Accept, Content-Type, X-Requested-With, X-CSRF-Token\"\n );\n }", "protected function setHeader($name, $value) {\n\t\t$this->cw_response[$name] = $value;\n\t\treturn true;\n\t}", "public function getOutputHeaders()\n {\n }", "public function headers()\r\n {\r\n return $this->headers;\r\n }", "public function headers()\r\n {\r\n return $this->headers;\r\n }" ]
[ "0.7077322", "0.6806114", "0.6771351", "0.6756909", "0.672327", "0.6702502", "0.67018044", "0.6695784", "0.6681595", "0.6608086", "0.6590742", "0.6590528", "0.656844", "0.65461016", "0.65438455", "0.65194446", "0.6497636", "0.6470956", "0.64410096", "0.6436197", "0.64017344", "0.63842297", "0.63842297", "0.63842297", "0.63842297", "0.63842297", "0.63842297", "0.63704234", "0.63091433", "0.6286246", "0.6238298", "0.6207769", "0.6206221", "0.6193909", "0.617768", "0.6176768", "0.61686593", "0.6165546", "0.6158526", "0.6129476", "0.6115939", "0.61079174", "0.60738677", "0.60630846", "0.60582656", "0.6049542", "0.6035409", "0.6035409", "0.60225475", "0.60221153", "0.59780127", "0.5972262", "0.59546715", "0.5953773", "0.5949396", "0.5949396", "0.5930581", "0.59302074", "0.5929169", "0.59273034", "0.592104", "0.5899819", "0.58946836", "0.5893322", "0.5885393", "0.58755445", "0.58455586", "0.5836437", "0.58351207", "0.5833024", "0.5832453", "0.5827054", "0.5818427", "0.5811884", "0.58091164", "0.5800748", "0.57969475", "0.5790813", "0.57871807", "0.5783191", "0.57746166", "0.5773344", "0.5761554", "0.5757737", "0.57553065", "0.5753634", "0.57500297", "0.574818", "0.5745466", "0.5738812", "0.5729315", "0.572326", "0.57198495", "0.5716819", "0.57156026", "0.5715211", "0.57143277", "0.57063586", "0.57058364", "0.57058364" ]
0.57106644
97
Returns the http request response code.
public function getCode() { $matches = array(); if (isset($this->headers) && isset($this->headers[0])) preg_match('|HTTP/\d\.\d\s+(\d+)\s+.*|', $this->headers[0], $matches); return isset($matches[1]) ? (int)$matches[1] : 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getResponseHTTPCode()\n {\n return $this->httpCode;\n }", "public function getResponseCode();", "public function getResponseCode();", "function http_headers_get_response_code() {\n\t\treturn $this->http_response_code;\n\t}", "function get_http_response_code()\n\t{\n\t\t//最后一个收到的HTTP代码\n\t\treturn curl_getinfo($this->ch, CURLINFO_HTTP_CODE);\n\t}", "public function get_response_code() {\n return $this->response_code;\n }", "public function getResponseCode(){\n\t\treturn $this->response->getCode();\n\t}", "public function getResponseCode()\n {\n return $this->response_code;\n }", "public function getResponseCode() {\n return $this->response_code;\n }", "public function getResponseCode() {\n return $this->response->getResponseCode();\n }", "public function getHttpResponseCode()\n {\n return $this->_httpResponseCode;\n }", "public function getResponseCode()\n {\n return $this->responseCode;\n }", "public function getResponseCode()\r\n {\r\n return $this->responseCode;\r\n }", "public static function getStatusCode(): int;", "public function getStatusCode()\n {\n return \\http_response_code();\n }", "public static function getStatus() {\n\t\treturn http_response_code();\n\t}", "function getHttpCode();", "public function getResponseCode() {\n return $this->client->getHttpStatusCode();\n }", "function responseCode() {\n return $this->responseCode;\n }", "public function getStatusCode(){\n return $this->httpResponseCode;\n }", "public function getStatusCode(): int;", "public function getStatusCode(): int;", "public function getStatusCode(): int;", "public function getStatusCode(): int;", "public function getResponseCode()\r\n {\r\n return $this->getData('response_code');\r\n }", "public function getHttpStatus(): int\n {\n\n return http_response_code();\n\n }", "public function getHttpCode()\n {\n return $this->http_code;\n }", "protected final function responseCode(): int\n {\n return $this->responseCode;\n }", "public function getCode()\n {\n return $this->response_code;\n }", "public function getHttpCode()\r\n {\r\n return $this->http_code;\r\n }", "public function getStatusCode(): int\n {\n return $this->response->getStatusCode();\n }", "public function getResponseCode() {\n return nullInt($this->settings['status'], 200);\n }", "public function getHttpCode(): int\n {\n return $this->httpCode;\n }", "public function getResponseCode()\n {\n }", "public function getResponseStatusCode()\n {\n return $this->responseCode;\n }", "public function getStatusCode(): int\n {\n return (int) $this->response->getStatusCode();\n }", "public function getResponseStatusCode()\r\n\t{\r\n\t\treturn (int) $this->statusCode;\r\n\t}", "public function getHttpCode()\n {\n return $this->code;\n }", "public function getStatusCode(): int\n {\n return $this->code ;\n }", "public function code() {\n return $this->info['http_code'];\n }", "function getStatusCode();", "public function getStatusCode() {\n return $this->getResponse()->statuscode;\n }", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getResponseCode()\n {\n return 200;\n }", "public function getHttpCode()\n {\n return $this->information[ self::INFORMATION_HTTP_CODE ];\n }", "public function getHttpCode()\n {\n return $this->_httpCode;\n }", "public function getHttpCode()\n {\n return $this->httpCode;\n }", "public function getHttpCode() {\n return $this->httpCode;\n }", "public function getCode()\n\t{\n\t\treturn (int)$this->statusCode;\n\t}", "public function getHttpCode() {\n return $this->httpCode;\n }", "public function status()\n {\n return (int)$this->response->getStatusCode();\n }", "public function getHTTPStatusCode() { return $this->status; }", "protected function _getCode()\n {\n // filter code from response\n return (int)substr($this->_getServerResponse(), 0, 3);\n }", "public function getStatusCode() : int\n {\n return $this->statusCode;\n }", "public function getStatusCode() : int\n {\n return $this->statusCode;\n }", "function http_response_code($response_code = 0) { \r\n \r\n if($response_code)\r\n Pancake\\vars::$Pancake_request->answerCode = $response_code;\r\n return Pancake\\vars::$Pancake_request->answerCode;\r\n }", "public function getStatusCode(): int\n {\n return $this->statusCode;\n }", "public function getStatusCode(): int\n {\n return $this->statusCode;\n }", "public function getStatusCode(): int\n {\n return $this->statusCode;\n }", "public function getStatusCode(): int\n {\n return $this->statusCode;\n }", "public function getStatusCode(): int\n {\n return $this->statusCode;\n }", "private function getHttpCode() {\n return $this->httpCode;\n }", "public function getStatusCode()\n {\n return (int) $this->getReturnVal();\n }", "public function getStatusCode(): int\r\n {\r\n return $this->_statusCode;\r\n }", "function http_response_code($newcode = NULL)\n\t\t{\n\t\t\tstatic $code = 200;\n\t\t\tif($newcode !== NULL)\n\t\t\t{\n\t\t\t\theader('X-PHP-Response-Code: '.$newcode, true, $newcode);\n\t\t\t\tif(!headers_sent())\n\t\t\t\t\t$code = $newcode;\n\t\t\t}\n\t\t\treturn $code;\n\t }", "public function getStatusCode()\r\n\t{\r\n\t\treturn $this->m_code;\r\n\t}", "function getStatusCode($response){\n\tif(preg_match(\"~HTTP/1\\.1 (\\d+)~\", $response, $match)){\n\t\treturn $match[1];\n\t}\n\n\t_log(\"getStatusCode: invalid response from server\", true);\n\treturn false;\n}", "public function getStatusCode()\n {\n return $this->httpStatusCode;\n }", "public function getStatusCode(): int {\n\t\treturn $this->statusCode;\n\t}", "public function getStatusCode(): int {\n\t\treturn $this->statusCode;\n\t}", "public function getResponseStatusCode()\n {\n return $this->response_status_code;\n }", "public function GetCode()\n {\n if($this->_correctHttpLine != null)\n {\n preg_match(\"|^HTTP/[\\d\\.x]+ (\\d+)|\", $this->_correctHttpLine, $m);\n if (isset($m[1])) { return (int)$m[1]; }\n }\n\n return false;\n }", "public function get_status_code(): int {\n if (empty($this->status_code)) {\n throw new RuntimeException(\"HTTP Response is missing a status code\");\n }\n\n return $this->status_code;\n }", "public function getStatusCode() {}", "function getHttpCode() {\n return $this->httpCode;\n }", "function get_http_response_code($url) {\n $headers = get_headers($url);\n return substr($headers[0], 9, 3);\n\t}", "public function getStatusCode(): int\n {\n return $this->status;\n }", "public function getStatusCode()\n {\n return (int) $this->statusCode;\n }", "public function getStatusCode()\n {\n return $this->statusCode ?: 200;\n }", "function get_http_response_code($url) {\n $headers = get_headers($url);\n return substr($headers[0], 9, 3);\n}", "public function getStatusCode() {\n\n return $this->result->status_code;\n }", "public function getStatusCode()\n {\n \treturn $this->statusCode;\n }", "public function getStatusCode(): int\n {\n return $this->meta['status_code'];\n }", "public function getHttpStatusCode()\n {\n return $this->statusCode;\n }", "public function getHttpStatusCode()\n {\n return $this->httpStatusCode;\n }", "public function getHttpStatusCode()\n {\n return $this->httpStatusCode;\n }", "public function getResponseHttpStatusCode()\r\r\n {\r\r\n return $this->responseHttpStatusCode;\r\r\n }", "public function getStatusCode()\n {\n return isset($this->headers['statusCode']) ? $this->headers['statusCode']: 500;\n }", "public function getHttpStatusCode()\n {\n return $this->response->getHttpStatusCode();\n }", "public function statusCode()\n {\n return $this->meta['http_code'];\n }", "public function getStatusCode()\n {\n return static::STATUS_CODE;\n }" ]
[ "0.83842814", "0.83313215", "0.83313215", "0.8315438", "0.8268095", "0.8263525", "0.822558", "0.81907964", "0.8146212", "0.8117727", "0.81101686", "0.8103304", "0.8071433", "0.80207676", "0.80026793", "0.796544", "0.7956017", "0.7929202", "0.7928828", "0.7919654", "0.790013", "0.790013", "0.790013", "0.790013", "0.7891493", "0.7861802", "0.78501886", "0.7848062", "0.7837602", "0.78369427", "0.78346306", "0.7829286", "0.7828463", "0.7809101", "0.78088075", "0.78005654", "0.77999586", "0.77879626", "0.77786803", "0.77674603", "0.7766638", "0.77421", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77338755", "0.77252185", "0.76891047", "0.7676417", "0.76626617", "0.7611864", "0.75987196", "0.7579008", "0.7560857", "0.75439894", "0.753996", "0.752961", "0.752961", "0.752249", "0.75220764", "0.75220764", "0.75220764", "0.75220764", "0.75220764", "0.75193846", "0.750894", "0.75082827", "0.75071895", "0.7493199", "0.7492923", "0.7486491", "0.74842584", "0.74842584", "0.7467817", "0.7461027", "0.74606246", "0.7446427", "0.74328655", "0.743233", "0.7427861", "0.7422855", "0.74172014", "0.7417037", "0.74129707", "0.7412763", "0.74063325", "0.7393642", "0.7381943", "0.7381943", "0.73812556", "0.7370601", "0.73417526", "0.7339599", "0.73367023" ]
0.76652706
55
Returns the raw http request response status string.
public function getRawStatus() { return (isset($this->headers) && isset($this->headers[0])) ? $this->headers[0] : ''; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function getStatus() {\n\t\treturn http_response_code();\n\t}", "protected function httpStatusLine()\r\n {\r\n return sprintf('HTTP/%s %s', $this->protocol_version, $this->status);\r\n }", "public function getResponseStatus()\n\t\t{\n\t\t\treturn $this->getHeader( \"status\" );\n\t\t}", "public function status() {\r\n\t\treturn self::request(self::HTTP_GET, 'status');\r\n\t}", "public function status_header() {\n return 'HTTP/1.1 ' . $this->status_code . ' ' . $this->status_meaning();\n }", "public function getResponseStatus() {\n return $this->response_status;\n }", "public function getResponseStatus() {\n return $this->response_status;\n }", "public function apiStatus(): string\n {\n return $this->request('apiStatus', 'GET');\n }", "public function __toString() {\n return sprintf('HTTP/1.1 %d %s', $this->getStatus(), $this->getDescription());\n }", "public function getFirstResponseStatus(): string\n {\n $responseStatus = $this->getAllHeaders()[0] ?? '';\n\n //200 OK, protocol signature varies, HTTP 1.1/1.0, etc.\n if (preg_match('/200 OK/i', $responseStatus) === 1) {\n return self::STATUS_OK;\n }\n\n if (preg_match('/404 Not Found/i', $responseStatus) === 1) {\n return self::STATUS_NOT_FOUND;\n }\n\n return self::STATUS_OTHER;\n }", "public function getResponseStatus()\n {\n return $this->ResponseStatus;\n }", "public function httpStatus() {\n return $this->_http_status;\n }", "public function getStatusText()\n {\n return $this->statusText;\n }", "public function getStatusText()\n {\n return $this->statusText;\n }", "public function getStatusText()\n {\n return $this->statusText;\n }", "public function status()\n {\n return $this->response->getStatusCode();\n }", "public function getStatus()\n {\n return (int)substr($this->response, 9, 3);\n }", "private function getStatusMessage(){\n\t\t$status = array(\n\t\t\t\t100 => 'Continue', \n\t\t\t\t101 => 'Switching Protocols', \n\t\t\t\t200 => 'OK',\n\t\t\t\t201 => 'Created', \n\t\t\t\t202 => 'Accepted', \n\t\t\t\t203 => 'Non-Authoritative Information', \n\t\t\t\t204 => 'No Content', \n\t\t\t\t205 => 'Reset Content', \n\t\t\t\t206 => 'Partial Content', \n\t\t\t\t300 => 'Multiple Choices', \n\t\t\t\t301 => 'Moved Permanently', \n\t\t\t\t302 => 'Found', \n\t\t\t\t303 => 'See Other', \n\t\t\t\t304 => 'Not Modified', \n\t\t\t\t305 => 'Use Proxy', \n\t\t\t\t306 => '(Unused)', \n\t\t\t\t307 => 'Temporary Redirect', \n\t\t\t\t400 => 'Bad Request', \n\t\t\t\t401 => 'Unauthorized', \n\t\t\t\t402 => 'Payment Required', \n\t\t\t\t403 => 'Forbidden', \n\t\t\t\t404 => 'Not Found', \n\t\t\t\t405 => 'Method Not Allowed', \n\t\t\t\t406 => 'Not Acceptable', \n\t\t\t\t407 => 'Proxy Authentication Required', \n\t\t\t\t408 => 'Request Timeout', \n\t\t\t\t409 => 'Conflict', \n\t\t\t\t410 => 'Gone', \n\t\t\t\t411 => 'Length Required', \n\t\t\t\t412 => 'Precondition Failed', \n\t\t\t\t413 => 'Request Entity Too Large', \n\t\t\t\t414 => 'Request-URI Too Long', \n\t\t\t\t415 => 'Unsupported Media Type', \n\t\t\t\t416 => 'Requested Range Not Satisfiable', \n\t\t\t\t417 => 'Expectation Failed', \n\t\t\t\t500 => 'Internal Server Error', \n\t\t\t\t501 => 'Not Implemented', \n\t\t\t\t502 => 'Bad Gateway', \n\t\t\t\t503 => 'Service Unavailable', \n\t\t\t\t504 => 'Gateway Timeout', \n\t\t\t\t505 => 'HTTP Version Not Supported');\n\t\treturn ($status[$this->_code]) ? $status[$this->_code] : $status[500];\n\t}", "public function getStatus(): string\n {\n return $this->status;\n }", "public function getStatus(): string\n {\n return $this->status;\n }", "public function getStatus(): string\n {\n return $this->status;\n }", "public function getStatus(): string\n {\n return $this->status;\n }", "public function getStatusString()\n {\n return $this->statuses[$this->statusId];\n }", "public function getHTTPStatusCode() { return $this->status; }", "public function status()\n {\n return (int)$this->response->getStatusCode();\n }", "public function getStatusAsString()\n {\n $list = self::getStatusList();\n if (isset($list[$this->status]))\n return $list[$this->status];\n\n return 'Unknown';\n }", "public function httpStatus()\n {\n return $this->provider->httpStatus;\n }", "public function getHttpStatusMessage()\r\n\t{\r\n\t return $this->_solrResponse->getHttpStatusMessage();\r\n\t}", "public function __toString() {\n\t\tforeach ($this->headers as $header) {\n\t\t\theader($header, true);\n\t\t}\n\t\thttp_response_code($this->statusCode);\n\n\t\treturn $this->content ?: '';\n\t}", "public function getResponseStatusMessage()\r\n\t{\r\n\t\treturn $this->statusMessage;\r\n\t}", "public function getStatusAsString(){\r\n $list = self::getStatusList();\r\n if (isset($list[$this->status]))\r\n return $list[$this->status];\r\n \r\n return 'Unknown';\r\n }", "public function getResponseInfo()\n\t\t{\n\t\t\treturn $this->getHeader( \"statusinfo\" );\n\t\t}", "public function getStatus()\n { \n return ! empty($this->result) ? $this->result->getStatus() : '';\n }", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode()\n {\n return \\http_response_code();\n }", "public function status(): string\n {\n return $this->status;\n }", "function _getStatusMessage(){\n $status = array(\n 200 => 'Ok' ,\n 201 => 'Created' ,\n 202 => 'deleted' ,\n 204 => 'No Content' ,\n 400 => 'Bad Request',\n 404 => 'Not Found' ,\n 405 => 'Not Allowed' ,\n 406 => 'Not Acceptable',\n\n );\n return ($status[$this->CodeHTTP] ? $status[$this->CodeHTTP] : $status[500]);\n }", "function getStatusMessage() \r\n\t{\r\n\t\treturn $this->replyString;\r\n\t}", "public function getStatus()\n {\n $rtn = $this->data['status'];\n\n return $rtn;\n }", "public function getStatusCode() {\n return $this->getResponse()->statuscode;\n }", "protected function getStatus()\n {\n switch (true) {\n case ($this->code >= self::HTTP_OK and $this->code < self::HTTP_MULTIPLE_CHOICES):\n $status = 'success';\n break;\n case ($this->code >= self::HTTP_BAD_REQUEST and $this->code < self::HTTP_INTERNAL_SERVER_ERROR):\n $status = 'fail';\n break;\n default:\n $status = 'error';\n break;\n }\n\n return $status;\n }", "public function statusStr()\n {\n return Status::get($this->publish_status);\n }", "public function getStatus()\n {\n return isset($this->status) ? $this->status : '';\n }", "public function getStatusCode() {}", "public function getStatus()\n {\n return $this->_makeCall('status');\n }", "function getStatusCode();", "public function getStatusCodeMsg(): string\r\n {\r\n return $this->_statusCodeMsg;\r\n }", "public function getStatusCode()\n {\n return $this->status;\n }", "public function getStatusText()\r\n {\r\n return $this->status_text;\r\n }", "public function getStatusString()\r\n {\r\n return $GLOBALS['TICKETSTATUS_DESC'][$this->status];\r\n }", "public function getFormattedStatus(): string;", "public function getStatus()\n {\n return $this->result->getStatus();\n }", "public function getHttpStatusMessage() {\n\t}", "function getStatusString() {\n\t\tswitch ($this->getData('status')) {\n\t\t\tcase THESIS_STATUS_INACTIVE:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status.inactive';\n\t\t\tcase THESIS_STATUS_ACTIVE:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status.active';\n\t\t\tdefault:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status';\n\t\t}\n\t}", "public static function getStatusCode(): int;", "public function getStatusCode() {\n\n return $this->result->status_code;\n }", "public function getStatusCode() {\n\t\treturn $this->status['code'];\n\t}", "public function getResponseStatusCode()\n {\n return $this->get('ResponseStatusCode');\n }", "public function getResponseStatusCode()\n {\n return $this->get('ResponseStatusCode');\n }", "public function getResponseStatusCode()\n {\n return $this->get('ResponseStatusCode');\n }", "public function getResponseStatusCode()\n {\n return $this->get('ResponseStatusCode');\n }", "public function getResponseStatusCode()\n {\n return $this->get('ResponseStatusCode');\n }", "public function getStatusCode(){\n return $this->httpResponseCode;\n }", "function getStatusMessage(){\n\t\tif($this->_StatusMessage){ return $this->_StatusMessage; }\n\n\t\t//cerpano z\n\t\t//http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html\n\t\t$status = array(\n\t\t\t// Successful 2xx\n\t\t\t\"200\" => \"OK\",\n\t\t\t\"201\" => \"Created\",\n\t\t\t\"202\" => \"Accepted\",\n\t\t\t\"203\" => \"Non-Authoritative Information\",\n\t\t\t\"204\" => \"No Content\",\n\t\t\t\"205\" => \"Reset Content\",\n\t\t\t\"206\" => \"Partial Content\",\n\t\t\t// Redirection 3xx\n\t\t\t\"300\" => \"Multiple Choices\",\n\t\t\t\"301\" => \"Moved Permanently\",\n\t\t\t\"302\" => \"Found\",\n\t\t\t\"303\" => \"See Other\",\n\t\t\t\"304\" => \"Not Modified\",\n\t\t\t\"305\" => \"Use Proxy\",\n\t\t\t// (306 Unused)\n\t\t\t\"307\" => \"Temporary Redirect\",\n\t\t\t// Client Error 4xx\n\t\t\t\"400\" => \"Bad Request\",\n\t\t\t\"401\" => \"Unauthorized\",\n\t\t\t\"402\" => \"Payment Required\",\n\t\t\t\"403\" => \"Forbidden\",\n\t\t\t\"404\" => \"Not Found\",\n\t\t\t\"405\" => \"Method Not Allowed\",\n\t\t\t\"406\" => \"Not Acceptable\",\n\t\t\t\"407\" => \"Proxy Authentication Required\",\n\t\t\t\"408\" => \"Request Timeout\",\n\t\t\t\"409\" => \"Conflict\",\n\t\t\t\"410\" => \"Gone\",\n\t\t\t\"411\" => \"Length Required\",\n\t\t\t\"412\" => \"Precondition Failed\",\n\t\t\t\"413\" => \"Request Entity Too Large\",\n\t\t\t\"414\" => \"Request-URI Too Long\",\n\t\t\t\"415\" => \"Unsupported Media Type\",\n\t\t\t\"416\" => \"Requested Range Not Satisfiable\",\n\t\t\t\"417\" => \"Expectation Failed\",\n\t\t\t\"418\" => \"I'm a teapot\",\n\t\t\t// Server Error 5xx\n\t\t\t\"500\" => \"Internal Server Error\",\n\t\t\t\"501\" => \"Not Implemented\",\n\t\t\t\"502\" => \"Bad Gateway\",\n\t\t\t\"503\" => \"Service Unavailable\",\n\t\t\t\"504\" => \"Gateway Timeout\",\n\t\t\t\"505\" => \"HTTP Version Not Supported\",\n\t\t\t\"506\" => \"Variant Also Negotiates\",\n\t\t\t\"507\" => \"Insufficient Storage\",\n\t\t);\n\t\treturn isset($status[\"$this->_StatusCode\"]) ? $status[\"$this->_StatusCode\"] : \"Unknown\";\n\t}", "public function getResponseStatusCode()\n {\n return $this->response_status_code;\n }", "public function status(): string;", "public function getResponseCode() {\n return nullInt($this->settings['status'], 200);\n }", "public function getResponseAsString(): string;", "public function rawResponse() {\n\t\treturn $this->raw_response;\n\t}", "public function getStatus()\n {\n return 'OK';\n }", "public function getRawResponse() {\n\t}", "public function getStatusCode()\n {\n return $this->status_code;\n }", "public function getStatus(){\n $this->client->request('GET','/session/status');\n $status_message = $this->getJsonResponse();\n return $status_message;\n }", "public function responseStatus() {\n if( ! property_exists($this->response(), 'status') ) return null;\n\n return $this->response()->status;\n }", "public function canonicalStatus() : string;", "public function getStatusCode()\n {\n return $this->httpStatusCode;\n }", "public function getRawResponse();", "public function getHttpStatus()\n {\n return $this->httpStatus;\n }", "public function status_header( $status ) {\n\t\tif ( substr( php_sapi_name(), 0, 3 ) === 'cgi' ) {\n\t\t\treturn str_replace( 'HTTP/1.1', 'Status:', $status );\n\t\t}\n\n\t\treturn $status;\n\t}", "public function getHttpStatus(): int\n {\n\n return http_response_code();\n\n }", "public function getHttpStatus()\n {\n return $this->http_status;\n }", "public function statusMessage(): string;", "public function getStatus()\n {\n return $this->data['status'];\n }", "public function getStatusCode()\n {\n return static::STATUS_CODE;\n }", "public function statusCode()\n {\n return Lastus::getStatusCode(static::class, $this->status);\n }", "public function getStatus() {\n if (isset(self::getArrayStatus()[$this->status])) {\n return self::getArrayStatus()[$this->status];\n }\n return '';\n }", "public function getStatus() {\n return isset($this->data['request']['status']) ? $this->data['request']['status'] : null;\n }", "private function _getStatusCodeMessage($status){\n\t\t// via parse_ini_file()... however, this will suffice\n\t\t// for an example\n\t\t$codes = Array(\n\t\t\t200 => 'OK',\n\t\t\t400 => 'Bad Request',\n\t\t\t401 => 'Unauthorized',\n\t\t\t402 => 'Payment Required',\n\t\t\t403 => 'Forbidden',\n\t\t\t404 => 'Not Found',\n\t\t\t500 => 'Internal Server Error',\n\t\t\t501 => 'Not Implemented',\n\t\t);\n\t\treturn (isset($codes[$status])) ? $codes[$status] : '';\n\t}", "public function getStatusCode()\n {\n }", "public function getHttpStatus()\n {\n return curl_getinfo($this->curl, CURLINFO_HTTP_CODE);\n }", "public function getStatusCode(): int;" ]
[ "0.747659", "0.7338915", "0.72885865", "0.7229605", "0.72246015", "0.7130166", "0.7130166", "0.70649326", "0.7020941", "0.70006806", "0.6997883", "0.6986414", "0.69494677", "0.6917115", "0.6915716", "0.68983614", "0.6888168", "0.68615156", "0.68483233", "0.68483233", "0.68483233", "0.68483233", "0.6828063", "0.6805086", "0.6792516", "0.6787686", "0.678178", "0.67734236", "0.67454094", "0.6742506", "0.6736743", "0.67329186", "0.672489", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6697908", "0.6683044", "0.66811335", "0.6675475", "0.6626284", "0.6620035", "0.66073895", "0.6606287", "0.6597214", "0.6589307", "0.6588682", "0.6588334", "0.6574208", "0.6550458", "0.65417266", "0.65275043", "0.6516056", "0.6507452", "0.6495361", "0.6485391", "0.647959", "0.64441", "0.64391446", "0.6414905", "0.63979053", "0.63979053", "0.63970804", "0.63965833", "0.63965833", "0.63941014", "0.6388894", "0.63851964", "0.6379212", "0.63759315", "0.6368512", "0.6359163", "0.6351885", "0.63492763", "0.63442534", "0.6339445", "0.63390005", "0.633858", "0.6337141", "0.633678", "0.6330822", "0.633014", "0.63286453", "0.63096434", "0.62961006", "0.62860805", "0.62820953", "0.6279161", "0.62757427", "0.627553", "0.6275064", "0.6274044", "0.6271962", "0.6260421" ]
0.7926654
0
Muestra ficheros dentro de directorio
public function showList($userId) { $ds = new DataSource(); $array = array($userId); $sql = sprintf("SELECT * from %s where %s=?", self::_TABLE, self::USER); $dirFileList = "<h2>Listado de Reservas</h2>"; foreach ($ds->fetchAll($sql, $array) as $row) { $id = $row['id']; $dirFileList .= "- " . $id . "&nbsp;<a href='" . $_SERVER['PHP_SELF'] . "?section=reserves&delete=".$id." '>Borrar</a>&nbsp;|&nbsp;<a href='" . $_SERVER['PHP_SELF'] . "?section=reserves&watch=$id'>Ver</a>|&nbsp;<a href='" . $_SERVER['PHP_SELF'] . "?section=reserves&edit=$id'>Editar</a><br>"; } $ds->close(); return $dirFileList; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function copiar ($desde, $hasta){ \n mkdir($hasta, 0777); \n $this_path = getcwd(); \n if(is_dir($desde)) { \n chdir($desde); \n $handle=opendir('.'); \n while(($file = readdir($handle))!==false){ \n if(($file != \".\") && ($file != \"..\")){ \n if(is_dir($file)){ \n copiar($desde.$file.\"/\", $hasta.$file.\"/\"); \n chdir($desde); \n } \n if(is_file($file)){ \n copy($desde.$file, $hasta.$file); \n } \n } \n } \n closedir($handle); \n } \n}", "public function getFileDirectory();", "function files_management($inputFile, $files){\n \n if($inputFile == \"./\"){\n $inputFile = \".\";\n } \n rtrim($inputFile, '\\\\/'); //odstranenie prebytocneho lomitka na konci \n $tmp_files = array();\n \n if(is_file($inputFile)){ //je to citatelny subor s priponou h\n if(is_readable($inputFile)){\n if(pathinfo($inputFile, PATHINFO_EXTENSION) == 'h'){\n array_push($files, $inputFile); //pridame ho do pola\n } \n }\n }\n elseif(is_dir($inputFile)){ //jedna sa o adresar\n $tmp_files = scandir($inputFile); //nacitame si vsetky subory v adresari\n foreach($tmp_files as $tmp){\n if($tmp != \".\" && $tmp != \"..\"){ //vynechame aktualny a nadradeny adresar\n if(is_dir($inputFile.'/'.$tmp.'/')){ //rekurzivne zanorenie v pripade, ze tu mame dalsi adresar\n if(is_readable($inputFile.'/'.$tmp)){\n files_management($inputFile.'/'.$tmp.'/', $files);\n }\n else{ //v adresari nemame pravo na citanie => chyba\n fprintf(STDERR, \"Adresar nie je mozne prehladavat.\");\n exit(2); \n } \n }\n elseif(is_file($inputFile.'/'.$tmp)){ //citatelny hlavickovy subor pridame do pola\n if(is_readable($inputFile.'/'.$tmp)){\n if(pathinfo($inputFile.'/'.$tmp, PATHINFO_EXTENSION) == 'h'){\n array_push($files, $inputFile.'/'.$tmp);\n }\n }\n }\n else{\n fprintf(STDERR, \"Zadana cesta nie je ani subor, ani adresar.\");\n exit(2);\n }\n }\n } \n \n \n }\n else{\n fprintf(STDERR, \"Zadana cesta nie je ani subor, ani adresar.\");\n exit(2);\n } \n \n return $files;\n}", "function buscar($dir,&$archivo_buscar) \n{ // Funcion Recursiva \n // Autor DeeRme \n // http://deerme.org \n if ( is_dir($dir) ) \n { \n // Recorremos Directorio \n $d=opendir($dir); \n while( $archivo = readdir($d) ) \n { \n if ( $archivo!=\".\" AND $archivo!=\"..\" ) \n { \n \n if ( is_file($dir.'/'.$archivo) ) \n { \n // Es Archivo \n if ( $archivo == $archivo_buscar ) \n { \n return ($dir.'/'.$archivo); \n } \n \n } \n \n if ( is_dir($dir.'/'.$archivo) ) \n { \n // Es Directorio \n // Volvemos a llamar \n $r=buscar($dir.'/'.$archivo,$archivo_buscar); \n if ( basename($r) == $archivo_buscar ) \n { \n return $r; \n } \n \n \n } \n \n \n \n \n \n } \n \n } \n \n } \n return FALSE; \n}", "function AnalizeDir(){\n\t\t$directorio=$this->getNameXML();\n\t\t$i=0;\n\t\t$archivosnom='';\n\t\tif (is_dir($directorio)) {\n\t\t if ($dh = opendir($directorio)) {\n\t\t while (($file = readdir($dh)) !== false) {\n\t\t\t\t\tif($file!='.' || $file!='..' || $file!='...'){\n\t\t\t\t\t\t$archivosnom[$i]=$file;\n\t\t\t\t\t}\n\t\t\t $i++;\n\t\t }\n\t\t closedir($dh);\n\t\t }\n\t\t}\n\t\telse{\n\t\t\tdie(\"El directorio no existe\");\n\t\t}\n\t\treturn $archivosnom;\n\t}", "function leer_archivos_y_directorios($ruta) {\r\n\t$total = 0;\r\n if (is_dir($ruta))\r\n {\r\n // Abrimos el directorio y comprobamos que\r\n if ($aux = opendir($ruta))\r\n {\r\n while (($archivo = readdir($aux)) !== false)\r\n {\r\n if ($archivo!=\".\" && $archivo!=\"..\")\r\n {\r\n $ruta_completa = $ruta . '/' . $archivo;\r\n if (is_dir($ruta_completa))\r\n {\r\n }\r\n else\r\n {\r\n\t\t\t\t\t\t$total;\r\n\t\t\t\t\t\t$total++;\r\n //echo '<br />' . $archivo . '<br />';\r\n }\r\n }\r\n }\r\n closedir($aux);\r\n }\r\n }\r\n else\r\n {\r\n echo $ruta;\r\n echo \"<br />No es ruta valida\";\r\n }\r\n\treturn($total);\r\n}", "function listar_directorios_ruta($ruta, $vlpadre){\n if (is_dir($ruta)) { \n if ($dh = opendir($ruta)) { \n\t\t$tmstmp = time();\n\t\t $rutabase = \"../docs/\".$_POST[\"idcliente\"].\"/\";\n\t\tmkdir($rutabase, 0777); \n\t\t \n while (($file = readdir($dh)) !== false) { \n //esta l�nea la utilizar�amos si queremos listar todo lo que hay en el directorio \n //mostrar�a tanto archivos como directorios \n //echo \"<br>Nombre de archivo: $file : Es un: \" . filetype($ruta . $file); \n if (is_dir($ruta . $file) && $file!=\".\" && $file!=\"..\"){ \n //solo si el archivo es un directorio, distinto que \".\" y \"..\" \n echo \"<br>Directorio: \".$ruta.\" --\".$file; \n\t\t\t\t$carpeta = creacarpetacliente($_POST[\"idcliente\"], substr($ruta,2).$file, $vlpadre );\n\t\t\t\t//print \"<br>EL Id de carpeta es: \".$carpeta;\n\t\t\t\t//exit;\n\t\t\t\tmkdir($rutabase.$carpeta, 0777);\n listar_directorios_ruta($ruta . $file . \"/\", $carpeta); \n } elseif($file!=\".\" && $file!=\"..\" && $file!=\"cmasivo.php\" && $file!=\"proceso.php\"){\n\t\t\t$arrfile =split(\"/\",substr($ruta,1).$file );\n\t\t\t\t$totarr = count($arrfile)-1;\n\n\t\t\t\t$tamano= filesize($rutabase.$vlpadre.\"/\".$arrfile[$totarr]);\n\t\t\t\tcopy($ruta.$file , $rutabase.$vlpadre.\"/\".$arrfile[$totarr] );\n\t\t\t\t echo \"<br>Copiar y subir a BD Archivo: $ruta$file\".\" -- \".$rutabase.$vlpadre.\"/\".$arrfile[$totarr];\n\t\t\t\t$pathtofile = $_POST[\"idcliente\"].\"/\".$vlpadre.\"/\".$arrfile[$totarr];\n\t\t\t\tinsertaarchivobd($_POST[\"idcliente\"], substr($ruta,1).$file, $pathtofile, $vlpadre, $tamano );\n\t\t\t\t\n\t\t\t}\n } \n closedir($dh); \n } \n }else \n echo \"<br>No es ruta valida\"; \n}", "private function cleanupFiles() {\n\t\t$this -> loadModel('Archivo');\n\t\t$items = $this -> Archivo -> find('all');\n\t\t$db_files = array();\n\t\tforeach ($items as $key => $item) {\n\t\t\t$db_files[] = $item['Archivo']['ruta'];\n\t\t}\n\t\t$dir_files = array();\n\t\t$dir_path = APP . 'webroot/files/uploads/solicitudesTitulacion';\n\t\tif ($handle = opendir($dir_path)) {\n\t\t\twhile (false !== ($entry = readdir($handle))) {\n\t\t\t\tif ($entry != 'empty' && is_file($dir_path . DS . $entry))\n\t\t\t\t\t$dir_files[] = 'files/uploads/solicitudesTitulacion/' . $entry;\n\t\t\t}\n\t\t\tclosedir($handle);\n\t\t}\n\t\tforeach ($dir_files as $file) {\n\t\t\tif (!in_array($file, $db_files)) {\n\t\t\t\t$file = explode('/', $file);\n\t\t\t\t$file = $file[count($file) - 1];\n\t\t\t\t$tmp_file_path = $dir_path . DS . $file;\n\t\t\t\tunlink($tmp_file_path);\n\t\t\t}\n\t\t}\n\t}", "abstract protected function getFilesDestination();", "function eliminarDirectorio($directorio){\n foreach(glob($directorio . \"/*\") as $archivos_carpeta){\n if (is_dir($archivos_carpeta)){\n eliminarDirectorio($archivos_carpeta);\n }\n else{\n unlink($archivos_carpeta);\n }\n }\n rmdir($directorio);\n}", "function borrarCarpeta($carpeta) {\r\n foreach(glob($carpeta . \"/*\") as $archivos_carpeta){ \r\n if (is_dir($archivos_carpeta)){\r\n if($archivos_carpeta != \".\" && $archivos_carpeta != \"..\") {\r\n borrarCarpeta($archivos_carpeta);\r\n }\r\n } else {\r\n unlink($archivos_carpeta);\r\n }\r\n }\r\n rmdir($carpeta);\r\n}", "private function createFileDir()\n\t{\n\t\t$this->fileDir = IMAGES.'uploads'.DS.$this->model.DS.$this->modelId;\n\t\t$this->imgDir = 'uploads/'.$this->model.'/'.$this->modelId;\n\t}", "function recursiveDirectory($directory){\n foreach(glob(\"{$directory}/*\") as $file)\n {\n //echo \"recorriendo el FICHERO $file<br>\";\n\n if(is_dir($file)) {\n //echo \"directorio $directory fichero $file<br>\";\n anadirImagen($file);\n recursiveDirectory($file);\n } else {\n\n anadirImagen($file);\n\n }\n }\n anadirImagen($directory);\n $parent = dirname($directory);\n while (strcmp($parent, 'Repositorio') != 0) {\n anadirImagen($parent);\n $parent = dirname($parent);\n }\n}", "public function moveFontelloFiles() {\n\n $this->_clearDirectory(array(\n 'assets/fontello',\n 'fontello'\n ));\n\n foreach (glob($this->_fontelloStorage . 'fontello-*/*', GLOB_NOSORT) as $file) {\n if (str_contains($file, 'config.json')) {\n if (\\File::exists(public_path('fontello/') . 'config.json')) {\n \\File::delete(public_path('fontello/') . 'config.json');\n }\n \\File::move($file, public_path('fontello/') . 'config.json');\n }\n if (is_dir($file)) {\n foreach (glob($file) as $index => $path) {\n $fileName = explode('/', $path);\n \\File::move($path, public_path('assets/fontello/') . end($fileName));\n }\n }\n }\n \\File::deleteDirectory($this->_fontelloStorage);\n }", "public function directory();", "public static function listDirectoriesForRoute($ruta)\n {\n if (is_dir($ruta)) {\n\n if ($dh = opendir($ruta)) {\n while (($file = readdir($dh)) !== false) {\n //esta línea la utilizaríamos si queremos listar todo lo que hay en el directorio\n //mostraría tanto archivos como directorios\n if (is_dir($ruta . $file) && $file != \".\" && $file != \"..\") {\n self::listDirectoriesForRoute($ruta . $file . \"/\");\n } else {\n $mime = File::mimeType($ruta . $file);\n $originalSize = File::size($ruta . $file);\n usleep(600000);\n if (strcasecmp($mime, 'image/png') == 0) {\n try {\n if (self::tinify) {\n self::compress_with_tinify($ruta, $file);\n } else {\n self::compress_with_pngquant($ruta . $file);\n }\n $newSize = File::size($ruta . $file);\n $compressRatio = $originalSize * 100 / $newSize;\n self::echoFileInformation($ruta, $file, '<span style=\"color:green\"> ' . $compressRatio . '% OK</span>');\n } catch (\\Exception $ex) {\n self::echoFileInformation($ruta, $file, '<span style=\"color:red\">FAIL</span>');\n }\n } else if (strcasecmp($mime, 'image/jpg') == 0 || (strcasecmp($mime, 'image/jpeg') == 0)) {\n try {\n self::compress_with_jpegtran($ruta . $file);\n $newSize = File::size($ruta . $file);\n $compressRatio = $originalSize * 100 / $newSize;\n self::echoFileInformation($ruta, $file, '<span style=\"color:green\"> ' . $compressRatio . '% OK</span>');\n } catch (\\Exception $ex) {\n self::echoFileInformation($ruta, $file, '<span style=\"color:red\">FAIL</span><br>' . $ex->getMessage());\n //self::echoFileInformation($ruta, $file, '<span style=\"color:red\">FAIL</span>');\n }\n }\n }\n }\n closedir($dh);\n }\n } else\n return -1;\n }", "public function reescalarPerfil(){\n// $directorio = '/files/fotos_perfil';\n $path = public_path().'/files/actividades/';\n $ficheros = scandir($path);\n// foreach ($ficheros as $file){\n//// $rutaComp = $path.$file;\n// echo $file.'<br>';\n//// $image = new ImageResize($rutaComp);\n//// $image->resizeToWidth(1200);\n//// $image->save($rutaComp);\n// }\n for($i=2;$i<count($ficheros);$i++){\n echo $ficheros[$i].'<br>';\n $rutaComp = $path.$ficheros[$i];\n $image = new ImageResize($rutaComp);\n $image->resizeToWidth(1200);\n $image->save($rutaComp);\n }\n\n }", "public function salvarArquivo()\n {\n $caminho = dirname($this->arquivo);\n if (!is_dir($caminho)) {\n mkdir($caminho, '0775', true);\n }\n // grava o arquivo\n file_put_contents($this->arquivo, $this->conteudo);\n }", "public function getDir();", "private function convertFiles(){\n\n\t\t//Create folder in tmp for files\n\t\tmkdir('./tmp/course_files');\n\t\t$sectionCounter = 0;\n\t\n\t\t//Add section to manifest\n\t\tHelper::addIMSSection($this->manifest, $this->currentSectionCounter, $this->identifierCounter, 'Documents');\n\n\t\t$section = $this->manifest->organizations->organization->item->item[$this->currentSectionCounter];\n\t\t\n\t\t//Find all folders and documents\n\t\t$query = \"SELECT document.`path`,document.`filename`,document.`format`,document.`title` FROM document WHERE document.`course_id`=\".$this->course_id.\" ORDER BY path;\";\n\t\t$result = mysqli_query($this->link,$query);\n\t\t\n\t\twhile($data = $result->fetch_assoc())\n\t\t{\n\t\t\t//Find item level\n\t\t\t$level = substr_count($data['path'], '/') - 1;\n\n\t\t\t//If it is a file\n\t\t\tif($data['format']!='.dir')\n\t\t\t{\n\t\t\t\t$s_filename = Helper::sanitizeFilename($data['filename']);\n\t file_put_contents('./tmp/course_files/'.$s_filename, fopen($this->host.'/courses/'.$this->course['code'].'/document'.$data['path'], 'r'));\n\t\t\t\tHelper::addIMSItem($section, $this->manifest, $sectionCounter, $this->identifierCounter, $this->resourceCounter, 'file', $data, $level); \n\t\t\t}\n\t\t\t//If it is a directory\n\t\t\telse if($data['format']=='.dir')\n\t\t\t{\n\t\t\t\tHelper::addIMSLabel($section, $sectionCounter, $this->identifierCounter, $data['filename'], $level);\n\t\t\t}\n\t\t}\n\n\t\t//Proceed to next section\n\t\t$this->currentSectionCounter++;\n\t}", "public function getFilesDirectoryPath();", "function listar_directorios_ruta($ruta){\n\t\t$directorios = array();\n\t\tif(is_dir($ruta)){ \n\t if($dh = opendir($ruta)){ \n\t while(($file = readdir($dh)) !== false){ \n\t //esta línea la utilizaríamos si queremos listar todo lo que hay en el directorio \n\t //mostraría tanto archivos como directorios \n\t //echo \"<br>Nombre de archivo: $file : Es un: \" . filetype($ruta . $file); \n\t if (is_dir($ruta . $file) && $file!=\".\" && $file!=\"..\"){ \n\t //solo si el archivo es un directorio, distinto que \".\" y \"..\" \n\t $directorios[] = $ruta.$file;\n\t //echo \"<br>Directorio: $ruta$file\"; \n\t $directorio[] = listar_directorios_ruta($ruta . $file . \"/\"); \n\t } \n\t } \n\t \tclosedir($dh); \n\t } \n\t }\n\t return $directorios;\n\t }", "function retornaArquivosDir($diretorio){\n if (is_dir($diretorio)){\n $dir = dir($diretorio);\n try {\n while(($arquivo = $dir->read()) !== false) {\n yield $arquivo;\n }\n } finally {\n $dir->close();\n }\n } else {\n throw new Exception('Diretório inválido');\n }\n}", "public function files();", "public function files();", "public function files();", "protected function getFilesInDirCreateTestDirectory() {}", "function getFiles(){\r\n\r\n global $dirPtr, $theFiles;\r\n \r\n chdir(\".\");\r\n $dirPtr = openDir(\".\");\r\n $currentFile = readDir($dirPtr);\r\n while ($currentFile !== false){\r\n $theFiles[] = $currentFile;\r\n $currentFile = readDir($dirPtr);\r\n } // end while\r\n \r\n}", "public static function getFilesPath() {\n return Site::getRelativePath() . Config::get('media.files_dir');\n }", "protected function getUploadFotoDir() {\n return 'uploads/produtos/produto/';\n }", "function GetDir($dir_path) {\n $files = array_slice(scandir($dir_path), 2);\n\n foreach($files as $file)\n {\n if(is_dir($dir_path.\"/\".$file))\n {\n $dir[] = $file;\n }\n else\n { \n $file1[] = \"-\".$file;\n }\n }\n $dir = array_merge($dir,$file1);\n return $dir;\n}", "public function getFiles();", "public function getFiles();", "public function getFiles();", "function expand()\r\n\t{\r\n\t\t$this->subfoldersCollection = new Collection ( );\r\n\r\n\t\tif( $handle = opendir( $this->path ) )\r\n\t\t{\r\n\r\n\t\t\twhile($file = readdir($handle))\r\n\t\t\t{\r\n\t\t\t\tif( !is_file( $this->path . \"/\" . $file ) && $file!='.' && $file!='..' )\r\n\t\t\t\t{\r\n\r\n\t\t\t\t\t$this->subfoldersCollection->add( new Folder( $this->path . '/' . $file ) );\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\ttrigger_error( \"houve algum erro na tentativa de abrir a pasta para manipulação\" );\r\n\t\t}\r\n\t}", "public function move_arquivos($imagem, $dir) {\n App::uses('File', 'Utility');\n $arquivo = new File($imagem['tmp_name']);\n $arquivo->copy($dir . $imagem['name']);\n $arquivo->close();\n }", "abstract protected function getFileWithPath();", "public function getFiles ();", "function juntarArquivos($file, $arquivos, $separacao = '', $function = NULL) {\n\t// Verifica se o arquivo existe\n\tif(file_exists($file))\n\t\treturn true;\n\t\n\tif(!is_dir(dirname($file)))\n\t\tmkdir(dirname($file), 0777, true);\n\t\n\t// Carregar todos os conteudos dos arquivos\n\t$f = fopen($file, 'w+');\n\t\n\t$file = '';\n\tforeach($arquivos as $name => $value) {\n\t\t$return = '';\n\t\tif(substr($value, 0, 2) == '//')\n\t\t\t$value = 'http:'. $value;\n\t\t\n\t\t// Carregar o conteudo\n\t\t$ch = curl_init();\n\t\tcurl_setopt($ch, CURLOPT_URL, $value);\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n\t\tcurl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);\n\t\t$content = curl_exec($ch);\n\t\t$http_code = curl_getinfo($ch, CURLINFO_HTTP_CODE);\n\t\tcurl_close($ch);\n\t\t\n\t\tif($http_code == 200) {\n\t\t\t$file .= $content . $separacao;\n\t\t}\n\t}\n\t\n\t// Verificar se tem alguma função de compactação\n\tif(function_exists($function)) {\n\t\t$file = call_user_func($function, $file);\n\t}\n\t\n\tfwrite($f, $file);\n\tfclose($f);\n}", "public function move_arquivos($imagem, $dir)\r\n\t{\r\n\t\tApp::uses('File', 'Utility');\r\n\t\t$arquivo = new File($imagem['tmp_name']);\r\n\t\t$arquivo->copy($dir.$imagem['name']);\r\n\t\t$arquivo->close();\r\n\t}", "public function getFiles() {}", "protected function getUploadRootDir()\n {\n \t// guardar los archivos cargados\n \treturn 'uploads/registros/';\n }", "static function getArchivosDirectorio($admitir, $directorio) {\n $items = scandir($directorio);\n $archivos = array();\n foreach ($items as $item) {\n /* Esta instruccion descarta las 2 primeras posiciones del arreglo\n ya que estan traen como dato '.' y '..' */\n //Tambien se descartar los .svn\n if ($item != '.' && $item != '..' && $item != '.svn') {\n $nombre = explode('_', $item); //Separa el nombre del archivo por cada '_'\n if ($nombre[0] == $admitir) {\n $archivos[] = $item;\n } else {\n //Con este if se devuelven la imagenes q no tengan prefijo\n if ($admitir == null && $nombre[0] != 'P') {\n $archivos[] = $item;\n }\n }\n }\n }\n return $archivos;\n }", "function borrarDirecctorio($dir) {\r\n\t\tarray_map('unlink', glob($dir.\"/*.*\"));\t\r\n\t\r\n\t}", "function arquivos() {\n\t\t$this->validate();\n\t\t$this->setupTemplate(true);\n\t\t$templateMgr =& TemplateManager::getManager();\n\n\t\t//carregar lista de arquivos:\n\t\t$templateMgr->assign('files', $this->listar());\n\t\t$templateMgr->display('files/files.tpl');\n\t}", "function moveFilesToDocs($src){\n // Get array of all source files\n $files = scandir($src);\n // Identify directories\n $source = $src . \"/\";\n $files = glob($source . \"*.html\");\n //echo $source;\n $dest = \"../docs/\";\n // Cycle through all source files\n foreach ($files as $fname) {\n if($fname != '.' && $fname != '..') {\n rename($fname, $dest.$fname);\n echo \"moving $dest.$fname \\n\";\n }\n }\n}", "public function getPathToFile(): string;", "public function mostrarRutasArchivosGenerados($pedido_id){\n $pedido = Pedido::where('id', $pedido_id)->first();\n $sales = sales::select()->where('pedido_id', '=', $pedido_id)->first();\n set_time_limit(0);\n $dt_empres = Empresaa::select()->first();\n\n $rutai = public_path();\n $ruta = str_replace(\"\\\\\", \"//\", $rutai);\n $rout = $this->makeDir('firmados');\n $rout = $this->makeDir('noautorizados');\n $rout = $this->makeDir('autorizados');\n $rout = $this->makeDir('temp');\n $rout = $this->makeDir('pdf');\n \n $rutafiles['autorizados'] = $ruta . '//archivos//' . 'autorizados' . '//';\n $rutafiles['enviados'] = $ruta . '//' . 'enviados' . '//';\n $rutafiles['firmados'] = $ruta . '//archivos//firmados//';\n $rutafiles['generados'] = $ruta . '/archivos//generados' . '/';\n $rutafiles['noautorizados'] = $ruta . '//archivos//' . 'noautorizados' . '//';\n $rutafiles['certificado'] = $ruta . '//archivos//certificado//';\n\n $rutafirma = $dt_empres->pathcertificate;\n $passcertificate = $dt_empres->passcertificate;\n $pass = '\"' . $passcertificate . '\"';\n $rutafiles['pathfirma'] = '\"' . $rutafiles['certificado'] . $rutafirma . '\"';\n $rutafiles['xml'] = $sales['claveacceso'] . '.xml';\n $rutafiles['pathsalida'] = $rutafiles['firmados'];\n $rutafiles['pathgenerado'] = $rutafiles['generados'] . $sales['claveacceso'] . '.xml';\n dd( $rutafiles );\n }", "function getFilesInDir($dirname, $path_return = ''){\n if( !is_dir($dirname) ){\n return false;\n }\n // On ouvre le dossier\n $dir = opendir($dirname);\n // Init du tableau\n $files = array();\n // On liste les fichier\n while($file = readdir($dir)){\n if($file != '.' && $file != '..' && !is_dir($dirname.$file) && $file != ' '){\n $files[$file] = $path_return . $file;\n }\n }\n // On ferme le dossier\n closedir($dir);\n // On retourne les fichiers\n return $files;\n}", "public function getFileBaseDir()\n {\n return Mage::getBaseDir('media').DS.'family'.DS.'file';\n }", "public function findFiles();", "private function read_directory(){\n $rdi = new RecursiveDirectoryIterator(ABSPATH);\n $rii = new RecursiveIteratorIterator($rdi);\n foreach($rii as $name => $obj){\n $dir_file = $obj->getRealPath(); \n\n if( strcmp(str_replace(\"\\\\\", \"/\", $dir_file),str_replace(\"\\\\\", \"/\", MD5_HASHER_DIR.$this->file_check)) <> 0 \n && strcmp(str_replace(\"\\\\\", \"/\", $dir_file), str_replace(\"\\\\\", \"/\", MD5_HASHER_DIR.$this->file_change)) <> 0){\n\n if(is_readable($dir_file)){\n $hash_key = @md5_file($dir_file);\n $this->md5_gen_output[$dir_file] = array(\n 'md5' => $hash_key,\n 'filename' => $obj->getFilename(),\n 'real_path' => $dir_file\n );\n\n $file_ext = substr(strrchr($obj->getFilename(),'.'),1);\n\n if(!isset($this->md5_gen_old[$dir_file]->md5)){\n // new file\n $this->md5_changed_output[$dir_file] = array(\n 'md5' => $hash_key,\n 'ext' => $file_ext,\n 'filename' => $obj->getFilename(),\n 'real_path' => $dir_file,\n 'modified' => 'new'\n );\n }else if($this->md5_gen_old[$dir_file]->md5 !== $this->md5_gen_output[$dir_file]['md5']){\n // modified file\n $this->md5_changed_output[$dir_file] = array(\n 'md5' => $hash_key,\n 'ext' => $file_ext,\n 'filename' => $obj->getFilename(),\n 'real_path' => $dir_file,\n 'modified' => 'edited'\n ); \n }\n }\n }\n }\n }", "function folder_zip($main_folder)\r\n{\r\n\t\r\n\t$rootPath = realpath($main_folder);\r\n\t\r\n\t$zip = new ZipArchive();\r\n $zip->open($rootPath.'.zip', ZipArchive::CREATE | ZipArchive::OVERWRITE);\r\n\r\n $files = new RecursiveIteratorIterator(\r\n new RecursiveDirectoryIterator($rootPath),\r\n RecursiveIteratorIterator::LEAVES_ONLY);\r\n\r\nforeach ($files as $name => $file)\r\n{\r\n // Skip directories (they would be added automatically)\r\n if (!$file->isDir())\r\n {\r\n // Get real and relative path for current file\r\n $filePath = $file->getRealPath();\r\n $relativePath = substr($filePath, strlen($rootPath) + 1);\r\n $zip->addFile($filePath, $relativePath);\r\n }\r\n}\r\n$zip->close();\r\n}", "public function getContenidoDir($base){\n\t\t\t$anterior= substr($base, 0, strrpos($base, \"/\"));\n\t\t\t$files= array();\n\t\t\t$folders= array();\n\t\t\tif ($handle = opendir($base)){\n\t\t\t\twhile (false !== ($entry = readdir($handle))){\n\t\t\t\t\t//No muestro los archivos que son de versionado de 14d .ver14\n\t\t\t\t\tif($this->archivoValido($entry)){\n\t\t\t\t\t\t$fecha = date('l jS \\of F Y h:i:s A',stat($base.\"/\".$entry)[9]);\n\t\t\t\t\t\tif ($entry != \".\" && $entry != \"..\" ){\n\t\t\t\t\t\t\tif ( is_dir($base.\"/\".$entry) ){\n\t\t\t\t\t\t\t\t$folders[] = array(\"dir\"=>$base.\"/\".$entry,\"liga\"=>base_url().\"/navegador?dir=\".$base.\"/\".$entry,\"nombre\"=>$entry,\"fecha\"=>$fecha,\"itemid\"=>$this->getId($base,$entry));\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\t$files[] = array(\"dir\"=>$base.\"/\".$entry,\"liga\"=>base_url().\"/\".$base.\"/\".$entry,\"nombre\"=>$entry,\"fecha\"=>$fecha,\"size\"=>human_filesize(filesize($base.\"/\".$entry)),\"itemid\"=>$this->getId($base,$entry));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\tif ( $entry == \"..\" && $base != $this->archivoDirRoot){\n\t\t\t\t\t\t\t\t$folders[] = array(\"dir\"=>$base.\"/\".$entry,\"liga\"=>base_url().\"/navegador?dir=\".$anterior,\"nombre\"=>\"..\",\"fecha\"=>$fecha,\"itemid\"=>$this->getId($base,$entry));\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\t\n\t\t\t\t\t}\n\t\t\t\t}\t\n\t\t\t}\n\t\t\tclosedir($handle);\n\n\t\t\treturn array(\"files\"=> $files,\"folders\"=>$folders);\n\t\t}", "public function getDestFiles($lang)\n\t{\n\t\t// set dest path by $lang e.g. /path/to/dest/{en}/\n\t\t$destDirs = $this->config['dest'];\n\n\t\t// replace path with $lang\n\t\tforeach ($destDirs as $i => $dir) {\n\t\t\t$destDirs[$i] = str_replace(\"{lang}\", $lang, $dir);\n\t\t}\n\n\t\t// get files in dir\n\t\treturn $destDirs;\n\t}", "protected function getUploadRootDirImg() {\n // guardar los archivos cargados\n return __DIR__ . '/../../../../web/uploads/portafolios/' . $this->getId() . '/img';\n }", "function subidaFichero($bd,$usuario,$entrada){\n if(isset($_FILES['imagen']['name']) && strlen ($_FILES['imagen']['name'])>0) {\n $dir_subida = $usuario . \"/\";\n ///////////NO TENGO PERMISOS DE CREAR CARPETAS!!!!!!!\n if ( !is_dir($dir_subida) && is_writable(\"../redsocial\")) {\n mkdir($dir_subida,0755, true);\n }else\n $dir_subida=\"img/\";\n $path = $_FILES['imagen']['name'];\n $ext = pathinfo($path, PATHINFO_EXTENSION);\n $fichero_subido = $dir_subida . $usuario . date(\"Ymd_Hm\").\".\".$ext;\n /////NO TENGO PERMISOS PARA SUBIR ARCHIVOS!!!!\n if(is_writable($dir_subida)) {\n if (!move_uploaded_file($_FILES['imagen']['tmp_name'], $fichero_subido)) {\n echo \"Problema de ataque de subida de ficheros!.\\n\";\n }\n }\n $imagen = new Imagen(null, $fichero_subido, $entrada->getId());\n $daoImagenes = new Imagenes($bd);\n $daoImagenes->addImagen($imagen, $entrada);\n return $fichero_subido;\n }\n\n}", "private function getAllThemeFiles(){\n\t\t$themeFolder = zweb.\"themes/\";\n\t\t$files = scandir($themeFolder.$this->theme);\n\n\t\tif(gettype($files) != \"array\") $files = array();\n\t\tforeach($files as $file){\n\t\t\tif(!is_dir($themeFolder.$file)){\n\t\t\t\t$info = pathinfo($themeFolder.$file);\n\t\t\t\t$this->$info['filename'] = $this->getThemeFile($info['filename'], @$info['extension']);\n\t\t\t}\n\t\t}\n\t}", "function outputFiles($path){\n // Check directory exists or not\n if(file_exists($path) && is_dir($path)){\n // Scan the files in this directory\n $result = scandir($path);\n \n // Filter out the current (.) and parent (..) directories\n $files = array_diff($result, array('.', '..'));\n \n if(count($files) > 0){\n // Loop through retuned array\n foreach($files as $file){\n if(is_file(\"$path/$file\")){\n \t// Display filename\n \techo $file . \"<br>\";\n \t} else if(is_dir(\"$path/$file\")){\n \t // Recursively call the function if directories found\n \toutputFiles(\"$path/$file\");\n \t}\n \t}\n \t} else{\n \t\techo \"ERROR: No files found in the directory.\";\n \t}\n \t\t} else {\n \techo \"ERROR: The directory does not exist.\";\n \t\t}\n\t}", "function subir_img($directorio,$name){\n move_uploaded_file($_FILES['imagen']['tmp_name'],\"$directorio/$name\");\n}", "public function get_files_directory() {\n return '../data/files/' . hash_secure($this->name);\n }", "private function listFolderFiles($dir){\n $children = false;\n $isRoot = false;\n if($dir==$this->file_storage){\n $isRoot = true;\n }\n\n $folderName = $this->getFolderName($dir);\n if(!$isRoot){\n //$this->info('Directory Name: '.$folderName['child']);\n //$this->info('Parent Name: '.$folderName['parent']);\n }\n\n //$this->info('Folder: '.$dir);\n\n foreach (new \\DirectoryIterator($dir) as $fileInfo) {\n if (!$fileInfo->isDot()) {\n if ($fileInfo->isDir()) {\n $this->listFolderFiles($fileInfo->getPathname());\n }else{\n $rename = false;\n //$this->info('File: '.$fileInfo->getFilename());\n //$info = new SplFileInfo($dir.'/'.$fileInfo->getFilename());\n $ext = \".\".pathinfo($fileInfo->getFilename(), PATHINFO_EXTENSION);\n //$ext = \".\"$info->getExtension();\n //$this->info('File: extension '.$ext);\n $filebreak = str_replace($ext,\"\",$fileInfo->getFilename());\n if (strpos($filebreak, '.') !== false || strpos($filebreak, \"'\") !== false || strpos($filebreak, \"#\") !== false) {\n $rename = true;\n }\n if($rename){\n $replace = array(\".\", \"'\", \"#\", \";\", \"/\", \"?\", \":\", \"@\", \"=\", \"&\", \",\");\n //“;”, “/”, “?”, “:”, “@”, “=” and “&\n $fileraw = str_replace($replace,\" \",$filebreak);\n //$this->info('File: raw '.$fileraw);\n $newfilename = $fileraw . $ext;\n //$this->info('File: new '.$newfilename);\n $prod_filename = $newfilename;\n rename($dir.'/'.$fileInfo->getFilename(),$dir.'/'.$newfilename);\n }else{\n $prod_filename = $fileInfo->getFilename();\n }\n $this->checkFileExtension($dir.'/'.$prod_filename, $prod_filename, $dir);\n }\n $children = true;\n }else{\n $children = false;\n }\n }\n //$this->info('Children: '.$children);\n\n if(!$isRoot){\n $this->folders[$this->count]['name'] \t\t\t= $folderName['child'];\n $this->folders[$this->count]['parent'] \t\t= $folderName['parent'];\n $this->folders[$this->count]['full_path']\t= $dir;\n $this->folders[$this->count]['children']\t= $children;\n $this->count++;\n }\n //$this->info('#################');\n }", "protected function getUploadRootDir() {\n // guardar los archivos cargados\n return __DIR__ . '/../../../../web/uploads/portafolios/' . $this->getId();\n }", "public function getFilepath();", "function Directorios($ruta) {\r\n $respuesta = array();\r\n /**\r\n * Valida se existe una ruta\r\n */\r\n if (is_dir($ruta)) {\r\n /**\r\n * Abre la carpetas\r\n */\r\n if ($aux = opendir($ruta)) {\r\n /**\r\n * recorre la carpeta\r\n */\r\n while (($archivo = readdir($aux)) !== false) {\r\n /**\r\n * No tome directorios superiores\r\n */\r\n if ($archivo != \".\" && $archivo != \"..\") {\r\n $ruta_completa = $ruta . '/' . $archivo;\r\n\r\n\r\n if (is_dir($ruta_completa)) {\r\n $otro[] = $ruta_completa;\r\n } else {\r\n $archivos[\"nombre\"] = $archivo;\r\n $archivos[\"size\"] = filesize($ruta_completa);\r\n $archivos[\"fecha\"] = date('Y-m-d H:i:s', filemtime($ruta_completa));\r\n $archivos[\"ruta\"] = $ruta_completa;\r\n\r\n $respuesta[] = $archivos;\r\n }\r\n }\r\n }\r\n closedir($aux);\r\n return $respuesta;\r\n }\r\n } else {\r\n\r\n return false;\r\n }\r\n }", "public function move_to_slideshow_dir()\n\t{\n\t\t\n\t\t$file_name = substr($this->file_handler[\"name\"], 0, strrpos($this->file_handler[\"name\"], \".\"));\n\t\t$file_name = $file_name . \"-\" . time();\n\t\t$file_name = $file_name . \".\" . pathinfo($this->file_handler['name'], PATHINFO_EXTENSION);\n\t\t$file_name = strtolower($file_name);\n\t\t\n\t\t$new_file_name = $this->base_path . $file_name;\n\n\t\t\n\t\tif(move_uploaded_file($this->file_handler[\"tmp_name\"], $new_file_name))\n\t\t\treturn $this->relative_path . $file_name;\n\t\telse\n\t\t\treturn false;\n\t}", "public function getConcatenateFiles() {}", "public function getFileBaseDir()\n {\n return Mage::getBaseDir('media').DS.'invitationstatus'.DS.'file';\n }", "function get_dir_content($in_dir,$in_args=array()){\r\n $dir = rtrim($in_dir, '\\\\/');\r\n $args = array_merge(array(\r\n 'recursive' => false,\r\n 'keep_structure' => false,\r\n 'name_pattren' => false,\r\n 'extension' => false,\r\n 'size_greater_than' => false,\r\n 'size_less_than' => false,\r\n 'type' => 'file',//can be dir also\r\n ),$in_args);\r\n \r\n if(!is_dir($dir)){\r\n lako::get('exception')->raise(\"Unable to read files from '{$dir}' as this is not a DIR.\");\r\n return false;\r\n }\r\n \r\n $files = array_diff(scandir($dir), array('..', '.'));\r\n $send_files = array();\r\n foreach($files as $key => $file){\r\n $send_file = array(\r\n 'name' => $file,\r\n 'path' => $dir.'/'.$file,\r\n );\r\n $send_file['type'] = is_dir($send_file['path'])? 'dir': 'file';\r\n \r\n \r\n if($args['type'] != $send_file['type'])\r\n continue;\r\n \r\n if(($send_file['type'] == 'file') && $args['extension'])\r\n if($this->get_extension($file) != $args['extension'])\r\n continue;\r\n \r\n $send_files[] = $send_file;\r\n }\r\n \r\n return $send_files;\r\n }", "public function dir_rewinddir() {}", "public function getUploadDir()\n {\n // image profile should be saved\n return __DIR__.'/../../../../web/uploads/evento/'.$this->id;\n }", "public function testReadingFiles()\n {\n $dir = __DIR__;\n $f = $this->adapter->java('java.io.File', $dir);\n $paths = $f->listFiles();\n foreach ($paths as $path) {\n self::assertFileExists((string) $path);\n }\n }", "function addFiles($files /*Only Pass Array*/) {\t\t\n\t\t$dirs = array();\n\t\t$directory = 'Plugins/';\n\t\tif ($handle = opendir($directory)) {\n\t\t\twhile (false !== ($file = readdir($handle))) {\n\t\t\t\tif ($file != '.' and $file != '..' and is_dir($directory.$file)) {\n\t\t\t\t\t$dirs[] = $file;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tclosedir($handle);\n\n\t\tforeach($files as $file) {\n\t\t\tif (is_file($file)) { //directory check\n\t\t\t\tforeach($dirs as $dir) {\n\t\t\t\t\t$dirName = 'Plugins/' . $dir;\n\t\t\t\t\t$fileName = substr($file, 0, -3);\n\t\t\t\t\t\n\t\t\t\t\tif($dirName == $fileName) {\n\t\t\t\t\t\t$this->zipDirectory($dirName,$dirName);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$data = implode(\"\",file($file));\n\t\t\t\t$this->addFile($data,$file);\n\t\t\t}\n }\n }", "protected function removeFiles() {}", "public abstract function getDirectory();", "public static function folderPath(){\n\t\treturn DATA.static::$folderPrefix.'files/';\n\t}", "function getFiles($path, $extra = \"\") {\n // check for needed slash at the end\n\t\t$length = strlen($path);\n\t\tif ($path{$length-1}!='/') { \n $path.='/';\n }\n \n $imagetypes = $this->conf[\"filetypes\"] ? explode(',', $this->conf[\"filetypes\"]) : array(\n 'jpg',\n 'jpeg',\n 'gif',\n 'png'\n );\n\n if($dir = dir($path)) {\n $files = Array();\n\n while(false !== ($file = $dir->read())) {\n if ($file != '.' && $file != '..') {\n $ext = strtolower(substr($file, strrpos($file, '.')+1));\n if (in_array($ext, $imagetypes)) {\n array_push($files, $extra . $file);\n }\n else if ($this->conf[\"recursive\"] == '1' && is_dir($path . \"/\" . $file)) {\n $dirfiles = $this->getFiles($path . \"/\" . $file, $extra . $file . \"/\");\n if (is_array($dirfiles)) {\n $files = array_merge($files, $dirfiles);\n }\n }\n }\n }\n\n $dir->close();\n #$files = shuffle($files);\n #echo t3lib_div::view_array($files);\n return $files;\n }\n }", "protected function getUploadDir()\n {\n return 'uploads/serie';\n }", "protected function createDir()\n\t\t{\n\t\t\t//si no existe la carpeta la creamos\n\t\t\tif (!file_exists($this->ruta))\n\t\t\t{\n\t\t\t\tmkdir($this->ruta,0777,true);\t\n\t\t\t}\n\t\t\t\n\t\t\tif (!file_exists($this->rutaMini))\n\t\t\t{\n\t\t\t\tmkdir($this->rutaMini,0777,true);\t\t\n\t\t\t}\t\n\t\t\t\t\n\t\t}", "function eliminar_archivos($dir)\n{\n\tif (is_dir($dir)) {\n\t\t$directorio = opendir($dir);\n\t\twhile ($archivo = readdir($directorio)) {\n\t\t\tif ($archivo != '.' and $archivo != '..') {\n\t\t\t\t@unlink($dir . $archivo);\n\t\t\t}\n\t\t}\n\t\tclosedir($directorio);\n\t\t@rmdir($dir);\n\t}\n}", "public function guardarMatriz($nombreArchivo,$idUsuario,$contenidoArchivo){\n $path=\"../../reportesUsuario/\".$nombreArchivo.\".html\"; \n if(is_dir($path)){\n echo \"procedimiento para guardar\";\n $gestor=fopen($path,\"r+\");\n }else{\n echo \"El directorio especificado no es un Directorio Valido\";\n }\n }", "public function getDirectory();", "public function getDirectory();", "protected function getUploadRootDir()\n {\n \t// guardar los archivos cargados\n \treturn 'uploads/registros/labels';\n }", "public static function modificar_archivos_copiados($id, $ruta_base){\r\n\t $dir = opendir($ruta_base.$id);\r\n\t // Leo todos los ficheros\r\n\t while ($template = readdir($dir)){\r\n\t // Reemplazamos el campo id en los templates\r\n\t if( $template != \".\" && $template != \"..\"){\r\n\t \t$nuevas_lineas = self::reemplazar_lineas($ruta_base.$id.\"/\".$template, $id);\r\n\t self::reescribir_archivo($ruta_base.$id.\"/\".$template, $nuevas_lineas);\r\n\t }\r\n\t }\r\n\t}", "private function apagarFotos($id_pessoa){\n $pasta = \"../uploads/empresa/\";\n if (is_dir($pasta)) {\n $diretorio = dir($pasta);\n\n while ($arquivo = $diretorio->read()) {\n if ($arquivo != \".\" && $arquivo != \"..\") {\n $nome = pathinfo($pasta.$arquivo,PATHINFO_FILENAME);\n if($nome == strval($id_pessoa)){\n unlink($pasta.$arquivo);\n }\n\n }\n }\n $diretorio->close();\n }else{\n return false;\n }\n }", "function moveFiles($src, $dest)\n{\n if (!is_dir($src)) {\n return false;\n }\n\n // If the destination directory does not exist create it\n if (!is_dir($dest)) {\n if (!mkdir($dest)) {\n // If the destination directory could not be created stop processing\n return false;\n }\n }\n\n // Open the source directory to read in files\n $i = new DirectoryIterator($src);\n foreach ($i as $f) {\n if ($f->isFile()) {\n rename($f->getRealPath(), \"$dest/\" . $f->getFilename());\n } else {\n if (!$f->isDot() && $f->isDir()) {\n rmDirRecursive($f->getRealPath(), \"$dest/$f\");\n unlink($f->getRealPath());\n }\n }\n }\n unlink($src);\n}", "function scanFiles($dir){\n $path = __DIR__ . DIRECTORY_SEPARATOR . $dir; /** Nurodomas kelias iki jsons folderio */\n $files = scandir($path); /** Nuskenuoja folderi pagal kelia($path) ir grazina esanciu failu masyva */\n\n return $files;\n}", "function file_force_contents($dir, $contents){\n $parts = explode('/', $dir);\n $file = array_pop($parts);\n $dir = '';\n foreach($parts as $part)\n if(!is_dir($dir .= \"/$part\")) mkdir($dir);\n file_put_contents(\"$dir/$file\", $contents);\n }", "private function exportFilesAndClear()\n {\n foreach (File::allFiles(Auth()->user()->getPublicPath()) as $file) {\n if (strpos($file, \".jpg\") !== false || strpos($file, \".png\") !== false) {\n $name = $this->reformatName($file);\n File::move($file, Auth()->user()->getPublicPath() . '/' . $name);\n }\n }\n $files = scandir(Auth()->user()->getPublicPath());\n foreach ($files as $key => $file) {\n if (is_dir(Auth()->user()->getPublicPath() . '/' . $file)) {\n if ($file[0] != '.') {\n File::deleteDirectory(Auth()->user()->getPublicPath() . '/' . $file);\n }\n } else {\n if (strpos($file, \".jpg\") === false && strpos($file, \".png\") === false) {\n File::delete(Auth()->user()->getPublicPath() . '/' . $file);\n }\n }\n }\n return null;\n }", "function getAllFiles($dirName){\n $files = [];\n try{\n $dirHandle = opendir( appDir($dirName));\n while($fileOrDir = readdir($dirHandle)){\n if(is_dir($fileOrDir)){\n continue;\n }\n $files[] = $dirName.'/'.$fileOrDir;\n }\n closedir($dirHandle);\n }catch(\\Exception $ex){\n echo $ex->getMessage();\n exit;\n }\n return $files;\n}", "function dest_path_and_file()\r\n{ \r\n global $xoopsDB, $xoopsUser;\r\n \r\n // Initialize magic_number. This number is used to create unique file names in order to guarantee that 2 file names\r\n // will not be identical if 2 users upload a file at the exact same time. 100000 will allow almost 100000 users to use\r\n // this system. Ok, the odds of this happening are slim; but, I want the odds to be zero.\r\n $magic_number = 100000; \r\n \r\n // Get the location of the document repository\r\n $query = \"SELECT data from \".$xoopsDB->prefix(\"dms_config\").\" WHERE name='doc_path'\";\r\n $file_sys_root = mysql_result(mysql_query($query),'data');\r\n \r\n // Get the current value of max_file_sys_counter\r\n $query = \"SELECT data from \".$xoopsDB->prefix(\"dms_config\").\" WHERE name='max_file_sys_counter'\";\r\n $max_file_sys_counter = (integer) mysql_result(mysql_query($query),'data');\r\n \r\n // Determine the path and filename of the new file\r\n $query = \"SELECT * from \".$xoopsDB->prefix(\"dms_file_sys_counters\");\r\n $dms_file_sys_counters = mysql_fetch_array(mysql_query($query));\r\n \r\n $file_sys_dir_1 = $dms_file_sys_counters['layer_1'];\r\n $file_sys_dir_2 = $dms_file_sys_counters['layer_2'];\r\n $file_sys_dir_3 = $dms_file_sys_counters['layer_3'];\r\n $file_sys_file = $dms_file_sys_counters['file'];\r\n $file_sys_file_name = ($file_sys_file * $magic_number) + $xoopsUser->getVar('uid');\r\n \r\n $dir_path_1 = $file_sys_root.\"/\".$file_sys_dir_1;\r\n $dir_path_2 = $file_sys_root.\"/\".$file_sys_dir_1.\"/\".$file_sys_dir_2;\r\n $dir_path_3 = $file_sys_root.\"/\".$file_sys_dir_1.\"/\".$file_sys_dir_2.\"/\".$file_sys_dir_3;\r\n \r\n //$doc_path = $file_sys_root.\"/\".$file_sys_dir_1.\"/\".$file_sys_dir_2.\"/\".$file_sys_dir_3;\r\n $path_and_file = $file_sys_dir_1.\"/\".$file_sys_dir_2.\"/\".$file_sys_dir_3.\"/\".$file_sys_file_name;\r\n //$dest_path_and_file = $doc_path.\"/\".$file_sys_file_name;\r\n \r\n //print $path_and_file;\r\n //exit(0);\r\n \r\n // Determine the next file system counter values and save them for future use.\r\n $file_sys_file++;\r\n if ($file_sys_file > $max_file_sys_counter) \r\n {\r\n\t$file_sys_file = 1;\r\n\t$file_sys_dir_3++;\r\n\t} \r\n \r\n if ($file_sys_dir_3 > $max_file_sys_counter)\r\n {\r\n\t$file_sys_dir_3 = 1;\r\n\t$file_sys_dir_2++;\r\n\t}\r\n\t\r\n if ($file_sys_dir_2 > $max_file_sys_counter)\r\n {\r\n\t$file_sys_dir_2 = 1;\r\n\t$file_sys_dir_1++;\r\n\t}\r\n\t\r\n $query = \"UPDATE \".$xoopsDB->prefix(\"dms_file_sys_counters\").\" SET \";\r\n $query .= \"layer_1 = '\".(integer) $file_sys_dir_1.\"', \";\r\n $query .= \"layer_2 = '\".(integer) $file_sys_dir_2.\"', \";\r\n $query .= \"layer_3 = '\".(integer) $file_sys_dir_3.\"', \";\r\n $query .= \"file = '\".(integer) $file_sys_file. \"' \";\r\n \r\n mysql_query($query); \r\n\r\n // Ensure that the final destination directories exist...if not, then create the directory or directories.\r\n if (!is_dir($dir_path_1)) \r\n {\r\n\tmkdir($dir_path_1,0775);\r\n chmod($dir_path_1,0777);\r\n\t}\r\n \r\n if (!is_dir($dir_path_2))\r\n {\r\n\tmkdir($dir_path_2,0775); \r\n chmod($dir_path_2,0777);\r\n }\r\n\t\r\n if (!is_dir($dir_path_3)) \r\n {\r\n\tmkdir($dir_path_3,0775);\r\n chmod($dir_path_3,0777);\r\n\t}\r\n\t\r\n return($path_and_file);\r\n}", "function zipFile($nomDossier) {\n /*\n * récupère la liste des fichiers d'un dossier puis les mets dans une liste.\n */\n $path = 'PageStorage/'.$nomDossier.'/';\n $fileList = glob($path.'*');\n $listeFichiers = array();\n $size = strlen('PageStorage/') + strlen($nomDossier)+1;\n\n foreach($fileList as $filename){\n $filename = substr($filename, $size);\n array_push($listeFichiers, $filename);\n }\n /*\n *Creation du zip avec les fichiers a l'interieur\n */\n $zip = new ZipArchive;\n $tmp_file = 'PageStorage/'.$nomDossier.'.zip';\n if ($zip->open($tmp_file, ZipArchive::CREATE)) {\n foreach($listeFichiers as $fichier){\n $zip->addFile($path.$fichier, $fichier);\n }\n $zip->close();\n } else {\n echo 'Failed!';\n }\n }", "public function vaciar_temporales()\n\t{\n\t\t$directorio = $_SERVER['DOCUMENT_ROOT'].Yii::app()->request->baseUrl.\"/images/tmp/\"; \n\t\t/**\n\t\t*\tRecorre el directorio y borra los archivos que contiene\n\t\t*/\n\t\t$handle = opendir($directorio); \n\t\twhile ($file = readdir($handle)) { \n\t\t\tif (is_file($directorio.$file)) { \n\t\t\t\tunlink($directorio.$file); \n\t\t\t}\n\t\t}\n\t}", "function generate_directory($id){\n $filename = \"intranet/usuarios/\" . $id . \"/uploads/\";\n if (!file_exists($filename)) {\n mkdir($filename, 0777, true);\n }\n }", "public function createFolderPath()\n {\n return \"uploads/\".date('Y').\"/\".date('m').\"/\";\n }", "function newsItem_CreateDirektori( \n\t \t$tanggalhariini\n\t){\n \t\t$direktoribuat = \"filemodul/news/\" . \"file_item/\" . $tanggalhariini . \"/\";\n\t\t\t mkdir( $direktoribuat,'0777',true); \n\t\t\t chmod( $direktoribuat, 0777);\n\t\treturn $direktoribuat;\n\t}", "private static function defaultFiles($dir){\n\n //gerando o model\n $model = \"<?php\\nnamespace modules\\\\\".strtolower(self::$pathName).\"\\\\model;\\n\\nclass \".self::$pathName.\"s implements \\\\libs\\\\database\\\\model\\n{\\n\\tpublic function create()\\n\\t{\\n\\t\\treturn array(\\n\\n);\\t\\n}\\n}\\n\";\n \\libs\\kernel\\File::newFile($dir.\"/model/\".self::$pathName.\"s.php\", $model);\n \n \n //gerando o controller\n $controller = \"<?php\\nnamespace modules\\\\\".strtolower(self::$pathName).\"\\\\controller;\\nuse \\\\libs\\\\kernel\\\\ControllerBase as CB;\\n\\nclass Controller\".self::$pathName.\" extends CB{\\n\\n\\tpublic function index(\\$app, \\$response){\\n // resposta que vem do servidor => \\$response. \\n // url onde esta o arquivo que vai ser renderizado. \\n // argumento a serem passados para a pagina. => \\$args \\n\\n return \\$app->view->render(\\$response, \\\"/\".ucfirst(self::$pathName).\"/index.php\\\");\\n\\t}\\n}\";\n \\libs\\kernel\\File::newFile($dir.\"/controller/Controller\".self::$pathName.\".php\", $controller);\n\n //gerando o manifest json\n $manifestJson = \"{\\n\\\"dad\\\": \\\"this\\\",\\n\\\"dadsName\\\": \\\"master\\\",\\n\\\"acessLevel\\\": \\\"0\\\",\\n\\\"title\\\": \\\"\".self::$pathName.\"\\\",\\n\\\"url\\\": \".strtolower(self::$pathName).\"\\\",\\n\\\"submenu\\\": []\\n}\";\n \\libs\\kernel\\File::newFile($dir.\"/manifest.json\", $manifestJson);\n \n \n //gerando o index\n \\libs\\kernel\\File::newFile($dir.\"/index.php\", \"\");\n }", "private function save_file_to_path($file){\n\t\tif(!is_dir($this->_mainFolder)){\n\t\t\tmkdir($this->_mainFolder);\n\t\t}\n\n\t\t//After making sure the main folder is created, another folder is created, with the idNews as name.\n\t\t//This just making sure no file is overwritten over time, also for making file order clear.\n\t\t$newFolder = $this->_mainFolder.'/'.$this->id;\n\t\tif(!is_dir($newFolder)){\n\t\t\tmkdir($newFolder);\n\t\t}\n\n\t\t//And now proceed to save the file to path.\n\t\t$f = $file['file'];\n\t\t$n = $file['name'];\n\n\n\t\tlist($type, $f) = explode(';', $f);\n\t\tlist(, $f) = explode(',', $f);\n\t\t$f = base64_decode($f);\n\t\tfile_put_contents($newFolder.'/'.$n, $f);\n\n\t\t//After saving the file, the name of the file is stored, just in case the path changes, we still have the name of the file.\n\t\t$query = \"INSERT INTO files (idNew, file) VALUES(\".$this->id.\", '\".$n.\"')\";\n\t\t$this->_db->query($query);\n\t}", "public function browse_files()\n {\n // Scan file directory, render the images.\n if (is_dir($this->file_path)) {\n $files = preg_grep('/^([^.])/', scandir($this->file_path));\n return $files;\n }\n \n }", "function destDir($src_file) {\n\t\t$dir = basename($src_file, \".zip\");\n\t\treturn $dir;\n\t}" ]
[ "0.67081237", "0.6289419", "0.622388", "0.6188249", "0.6159224", "0.61251", "0.60876733", "0.6058366", "0.60258204", "0.60101086", "0.59935665", "0.5954322", "0.594558", "0.59088653", "0.5904281", "0.5892897", "0.58758783", "0.587188", "0.5796606", "0.5776349", "0.5773177", "0.573942", "0.57351935", "0.56999606", "0.56999606", "0.56999606", "0.5680479", "0.5653197", "0.5650865", "0.5636782", "0.5634314", "0.56275505", "0.56275505", "0.56275505", "0.5613918", "0.5612486", "0.5612431", "0.5611143", "0.55917335", "0.5577982", "0.5570384", "0.5558609", "0.55582917", "0.5552185", "0.5548745", "0.5539249", "0.5538112", "0.5533648", "0.5511529", "0.5507343", "0.5505865", "0.5494261", "0.5489817", "0.5487949", "0.54666334", "0.546196", "0.5452213", "0.54493797", "0.5445315", "0.5444459", "0.5439687", "0.5429054", "0.54266804", "0.5425077", "0.5422985", "0.5420512", "0.5414969", "0.5408927", "0.54005", "0.5398573", "0.53900063", "0.53783643", "0.5370238", "0.536808", "0.53634346", "0.535605", "0.53545177", "0.5348782", "0.5344475", "0.5335041", "0.532689", "0.5314974", "0.5314974", "0.53127086", "0.531253", "0.5308538", "0.5305201", "0.5298776", "0.5289351", "0.52891254", "0.52876425", "0.52871263", "0.5286475", "0.52703005", "0.52630454", "0.5262505", "0.52565306", "0.5235494", "0.52345717", "0.5234249", "0.5231291" ]
0.0
-1
Loop through `users` table, and find the duplicated. Increment the number after the slug, to keep the first and lastname. The slug is the lookup column.
protected static function boot(){ parent::boot(); static::creating(function($model){ // Make a slug for the user ex: firstname.lastname.xx $slug = $maybe_slug = strtolower(str_slug($model->firstname) . '.' . str_slug($model->lastname)); $next = 2; while (User::where('slug', '=', $slug)->first()) { $slug = "{$maybe_slug}.{$next}"; $next++; } $model->slug = $slug; return true; }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isUserDuplicate(){\n\n\t\t$today = Carbon::today();\n\n\t\t$user = User::on('bk')\n\t\t\t\t\t->where('created_at', '>=', $today)\n\t\t\t\t\t->select('id')\n\t\t\t\t\t->get();\n\n\t\t$str1 = '( ';\n\t\t$str2 = '( ';\n\t\tforeach ($user as $key) {\n\t\t\t// $user_id_arr .= $key->id.\",\";\n\t\t\t$str1 .= 'id = '.$key->id.\" OR \";\n\t\t\t$str2 .= 'u1.id = '.$key->id.\" OR \";\n\t\t}\n\n\t\t$str1 = rtrim($str1, \"OR \");\n\t\t$str2 = rtrim($str2, \"OR \");\n\n\t\t$str1 .= ')';\n\t\t$str2 .= ')';\n\n\t\t$qry_str = \"Select u1.id,\n\t\t\t\t\tif(u1.id in \n\t\t\t\t\t (Select max(u2.id)\n\t\t\t\t\t from users u2\n\t\t\t\t\t where is_ldy = 0\n\t\t\t\t\t and is_plexuss = 0 \n\t\t\t\t\t and email REGEXP '^[A-Z0-9._%-]+@[A-Z0-9.-]+\\.[A-Z]{2,4}$'\n\t\t\t\t\t and email not like '%test%'\n\t\t\t\t\t and fname not like '%test'\n\t\t\t\t\t and email not like '%nrccua%'\n\t\t\t\t\t and \".$str1.\"\n\t\t\t\t\t\t group by email)\n\t\t\t\t\t, 0, 1) as 'is_duplicate'\n\t\t\t\t\tfrom users u1\n\t\t\t\t\twhere is_ldy = 0\n\t\t\t\t\tand is_plexuss = 0 \n\t\t\t\t\tand email REGEXP '^[A-Z0-9._%-]+@[A-Z0-9.-]+\\.[A-Z]{2,4}$'\n\t\t\t\t\tand email not like '%test%'\n\t\t\t\t\tand fname not like '%test'\n\t\t\t\t\tand email not like '%nrccua%'\n\t\t\t\t\tand \".$str2.\";\";\n\n\t\t$qry = DB::connection('bk')->select($qry_str);\n\n\t\tforeach ($qry as $key) {\n\t\t\tif ($key->is_duplicate == 1) {\n\t\t\t\t$attr = array('user_id' => $key->id);\n\t\t\t\t$val = array('user_id' => $key->id, 'is_duplicate' => $key->is_duplicate);\n\n\t\t\t\tEmailLogicHelper::updateOrCreate($attr, $val);\n\t\t\t}\n\t\t}\n\t}", "public function parseNameSlug($text)\n\t{\n\t\t$text = preg_replace('~[^\\pL\\d]+~u', '', $text);\n\n\t\t// trim\n\t\t$trim = trim($text, ' ');\n\n\t\t$text = strtolower($text);\n\n\t\t$table = \"users\"; \n\t\t$column = \"nameSlug\";\n\n\t\t$name_slug_exists = $this->check_for_duplicate_entry($table, $column, $text);\n\n\t\tif(!$name_slug_exists)\n\t\t{\t\n\t\t\tfor ($i=0; $i < 9999 ; $i++) { \n\t\t\t\t\n\t\t\t\tif($this->check_for_duplicate_entry($table, $column, $text . $i))\n\t\t\t\t{\n\t\t\t\t\t$text = $text . $i;\n\t\t\t\t\tbreak;\n\t\t\t\t}\t\t\n\t\t\t}\n\t\t}\n\n\n\t\treturn $text;\n\t}", "public function generateSlug()\n {\n if ($this->slug != str_slug($this->title)) {\n $this->slug = str_slug($this->title);\n }\n\n while ($count = self::where(['slug' => $this->slug])->where('id', '!=', $this->id)->count()) {\n $this->slug .= '-' . $count;\n }\n }", "private function makeUnique($slugs, $relatedSlug)\n {\n $exists = $this->getLocaleDifferences($slugs, $relatedSlug);\n\n foreach ($exists as $key => $value) {\n $array = explode('-', $value);\n\n //Get incement of index\n $index = last($array);\n\n //If slug has no increment yet\n if (! is_numeric($index) || count($array) == 1) {\n $index = 1;\n $withoutIndex = $array;\n } else {\n $withoutIndex = array_slice($array, 0, -1);\n }\n\n //Add unique increment into slug\n $this->incrementSlug($slugs, $key, $index, $withoutIndex);\n }\n\n return array_filter($slugs);\n }", "private static function createUniqueSlug($value) {\n\t\t$original = Str::slug($value);\n\t\t$slug = $original;\n\n\t\t$i = 2;\n\t\t// Check if there is any entry for the current slug.\n\t\twhile(News::where('slug', '=', $slug)->count() > 0) {\n\t\t\t// Concatenate the value with the incremental variable, so we may get a unique name\n\t\t\t$slug = $original .'-'. $i;\n\t\t\t$i++;\n\t\t}\n\n\t\t// Finally, we have a unique slug!\n\t\treturn $slug;\n\t}", "private function check_for_duplicate_user_ids() {\n foreach($this->data as $course => $rows) {\n $user_ids = null;\n $d_rows = null;\n // Returns FALSE (as in there is an error) when duplicate IDs are found.\n // However, a duplicate ID does not invalidate a course. Instead, the\n // first enrollment is accepted, the other enrollments are discarded,\n // and the event is logged.\n if (validate::check_for_duplicate_user_ids($rows, $user_ids, $d_rows) === false) {\n foreach($d_rows as $user_id => $userid_rows) {\n $length = count($userid_rows);\n for ($i = 1; $i < $length; $i++) {\n unset($this->data[$course][$userid_rows[$i]]);\n }\n }\n\n $msg = \"Duplicate user IDs detected in {$course} data: \";\n $msg .= implode(\", \", $user_ids);\n $this->log_it($msg);\n }\n }\n\n return true;\n }", "private function is_duplicate () {\n $email = $this->payload['email'];\n $facebook_id = '0';\n if (!empty($this->payload['facebook_id'])) {\n $facebook_id = $this->payload['facebook_id'];\n }\n $sql = \"SELECT id FROM users WHERE email='$email' OR facebook_id='$facebook_id'\";\n $sql = $this->conn->query($sql);\n\n return $sql->num_rows > 0;\n }", "private function checkUpdatingSlug($slug)\n {\n if ($this->id >= 1) {\n\n $found = false;\n foreach ($this->uniqueModels() as $class) {\n\n // find entries matching slug, exclude updating entry\n $builder = $this->eloqent($class)->where('slug', $slug);\n\n // same model - exlude check\n if ($class == self::class) {\n $builder = $builder->where('id', '!=', $this->id);\n }\n\n // found same slug - break, need new slug\n if ($found = $builder->first()) {\n break;\n }\n }\n\n // save to use current slug for update\n if ($found == false || $found == null) {\n return $slug;\n }\n }\n\n // new unique slug needed\n return false;\n }", "protected static function createNewSlug()\n {\n do {\n $slug = substr(str_shuffle(str_repeat('0123456789abcdefghijklmnopqrstuvwxyz', 10)), 0, random_int(5, 10));\n } while (self::where('slug', $slug)->count());\n\n return $slug;\n }", "public function makeUniqueSlug(Model $model, $slug = '') {\n\t\t$settings = $this->settings[$model->alias];\n\t\t$conditions = array();\n\t\tif ($settings['unique'] === true) {\n\t\t\t$conditions[$model->alias . '.' . $settings['slug']] = $slug;\n\t\t} else if (is_array($settings['unique'])) {\n\t\t\tforeach ($settings['unique'] as $field) {\n\t\t\t\t$conditions[$model->alias . '.' . $field] = $model->data[$model->alias][$field];\n\t\t\t}\n\t\t\t$conditions[$model->alias . '.' . $settings['slug']] = $slug;\n\t\t}\n\n\t\tif (!empty($model->id)) {\n\t\t\t$conditions[$model->alias . '.' . $model->primaryKey . ' !='] = $model->id;\n\t\t}\n\n\t\t$conditions = array_merge($conditions, $settings['scope']);\n\n\t\t$duplicates = $model->find('all', array(\n\t\t\t'recursive' => -1,\n\t\t\t'conditions' => $conditions,\n\t\t\t'fields' => array($settings['slug'])));\n\n\t\tif (!empty($duplicates)) {\n\t\t\t$duplicates = Set::extract($duplicates, '{n}.' . $model->alias . '.' . $settings['slug']);\n\t\t\t$startSlug = $slug;\n\t\t\t$index = 1;\n\n\t\t\twhile ($index > 0) {\n\t\t\t\tif (!in_array($startSlug . $settings['separator'] . $index, $duplicates)) {\n\t\t\t\t\t$slug = $startSlug . $settings['separator'] . $index;\n\t\t\t\t\t$index = -1;\n\t\t\t\t}\n\t\t\t\t$index++;\n\t\t\t}\n\t\t}\n\n\t\treturn $slug;\n\t}", "public function uniqueSlug($value)\n {\n $slug = str_slug($value);\n\n $count = static::whereRaw(\"slug RLIKE '^{$slug}(-[0-9]+)?$'\")->count();\n\n return $count ? \"{$slug}-{$count}\" : $slug;\n }", "protected function generateUniqueSlug($baseSlug, $iteration)\n {\n if (is_callable($this->uniqueSlugGenerator))\n {\n return call_user_func($this->uniqueSlugGenerator, $baseSlug, $iteration, $this->owner);\n } else\n {\n return $baseSlug . '-' . ($iteration + 1);\n }\n }", "function sf_create_slugs()\n{\n\tglobal $wpdb;\n\n\t# forums\n\t$records=$wpdb->get_results(\"SELECT forum_id, forum_name, forum_slug FROM \".SFFORUMS);\n\tif($records)\n\t{\n\t\tforeach($records as $record)\n\t\t{\n\t\t\t$title = sf_create_slug($record->forum_name, 'forum');\n\t\t\tif(empty($title))\n\t\t\t{\n\t\t\t\t$title = 'forum-'.$record->forum_id;\n\t\t\t}\n\t\t\t$wpdb->query(\"UPDATE \".SFFORUMS.\" SET forum_slug='\".$title.\"' WHERE forum_id=\".$record->forum_id);\n\t\t}\n\t}\n\n\t# topics\n\t$records=$wpdb->get_results(\"SELECT topic_id, topic_name, topic_slug FROM \".SFTOPICS);\n\tif($records)\n\t{\n\t\tforeach($records as $record)\n\t\t{\n\t\t\t$title = sf_create_slug($record->topic_name, 'topic');\n\t\t\tif(empty($title))\n\t\t\t{\n\t\t\t\t$title = 'topic-'.$record->topic_id;\n\t\t\t}\n\t\t\t$wpdb->query(\"UPDATE \".SFTOPICS.\" SET topic_slug='\".$title.\"' WHERE topic_id=\".$record->topic_id);\n\t\t}\n\t}\n\treturn;\n}", "private function incrementSlug(&$slugs, string $key, $index, $withoutIndex)\n {\n $newSlug = implode('-', $withoutIndex);\n\n $column = $this->hasLocalizedSlug() ? 'JSON_EXTRACT(slug, \"$.'.$key.'\")' : 'slug';\n\n $i = 1;\n\n //Return original slugs\n do {\n $slugs[$key] = $newSlug.'-'.($index + $i);\n\n $i++;\n } while ($this->where(function ($query) {\n if ($this->exists) {\n $query->where($this->getTable().'.'.$this->getKeyName(), '!=', $this->getKey());\n }\n })->whereRaw($column.' = ?', $slugs[$key])->withoutGlobalScopes()->count() > 0);\n }", "private function makeSlugUnique($slug)\n {\n $slug = \\Illuminate\\Support\\Str::slug($slug);\n\n // check updating\n $slugUpdate = $this->checkUpdatingSlug($slug);\n\n if ($slugUpdate !== false) {\n return $slugUpdate;\n }\n\n // get existing slugs\n $list = $this->getExistingSlugs($slug);\n\n if ($list->count() === 0) {\n return $slug;\n }\n\n // generate unique suffix\n return $this->generateSuffix($slug, $list);\n }", "function wp_unique_post_slug($slug, $post_id, $post_status, $post_type, $post_parent)\n {\n }", "public function test_create_user_duplicated()\n {\n $last_data=User::latest()->first();\n $response = $this->json('POST', \n '/user_create', \n [\n 'name' => $this->fullname, \n 'email' => $last_data['email'], \n 'password' => $this->password]);\n $response\n ->assertStatus(200)\n ->assertJson([\n $this->all_message => $this->user_create_duplicated,\n ]);\n }", "function _acf_apply_unique_field_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug)\n{\n}", "public function uniqueSlug($slug)\n\t{\n\t\t$slug_attempt = $slug;\n\t\t\n\t\t// build slug/number combos until an unused slug is found\n\t\tfor($i = 1; in_array($slug_attempt, $this->layouts); $i++)\n\t\t{\n\t\t\t$slug_attempt = $slug.'-'.$i;\n\t\t}//end while\n\t\t\n\t\t// when we get to here, a valid slug was built. Assign to slug.\n\t\t$slug = $slug_attempt;\n\t\t\n\t\t// unset temp variable\n\t\tunset($slug_attempt);\n\t\t\n\t\treturn $slug;\n\t}", "private function checkUsernameDuplicating($username)\n\t{\n\t\t$checkUsernameDuplicateQuery = $this->db->get_where('Users', array('username' => $username), 1);\n\t\tif ($checkUsernameDuplicateQuery->num_rows() > 0)\n\t\t\treturn false;\n\t\treturn true;\n\n\t}", "private function slug_generator($slug)\n\t\t{\n\t\t\tif(!$this->slug_exists($slug))\n\t\t\t\treturn $slug;\n\n\t\t\t$slug = $slug.'-0';\n\n\t\t\twhile($this->slug_exists($slug))\n\t\t\t\t$slug++;\n\n\t\t\treturn $slug;\n\t\t}", "function cjpopups_create_unique_username($user_login_string, $separator = '', $first = 1){\n\tif(strpos($user_login_string, '@')){\n\t $user_login = explode('@', $user_login_string);\n\t $user_login = $user_login[0];\n }else{\n \t$user_login = str_replace('-', '_', sanitize_title($user_login_string));\n }\n if(!username_exists($user_login)){\n return $user_login;\n }else{\n preg_match('/(.+)'.$separator.'([0-9]+)$/', $user_login, $match);\n $new_user_login = isset($match[2]) ? $match[1].$separator.($match[2] + 1) : $user_login.$separator.$first;\n if(!username_exists( $new_user_login )){\n \treturn $new_user_login;\n }else{\n \treturn cjpopups_create_unique_username($new_user_login, $separator = '', $first = 1);\n }\n }\n}", "public function testGenerateSlugIfItWillCreateUniqueSlug()\n {\n factory(Product::class)->create()->each(function ($product) {\n $expectedSlug = $product->slug . '-2';\n $returnedSlug = Product::generateSlug($product->title);\n\n $this->assertEquals($expectedSlug, $returnedSlug);\n });\n }", "private function generateSlug($data) {\n\n $slug = Str::slug($data[\"title\"], '-'); // titolo-articolo-3\n\n // chiamata query al db, settiamo con la variabile existingslug il primo slug del db che non ammetterà duplicati\n $existingPost = Post::where('slug', $slug)->first();\n // dd($existingPost);\n\n // se lo slug esiste già, dobbiamo rigenerarlo. possiamo aggiungere allo slug doppione un trattino e un numero. per farlo usiamo un ciclo while che si interrompe quando la condizione di uscita viene soddisfatta\n $slugBase = $slug;\n $counter = 1;\n\n while($existingPost) {\n $slug = $slugBase . \"-\" . $counter;\n\n // istruzioni per terminare il ciclo, riverifico con una nuova query l'esistenza dello slug. Se esiste il ciclo riparte con l'incremento, se non esiste la condizione del while è falsa ed esco dal ciclo.\n $existingPost = Post::where('slug', $slug)->first(); \n // incremento \n $counter++;\n }\n\n // salvo lo slug\n return $slug;\n }", "public function cleanDuplicates( );", "public static function createUniqueUsername($firstName,$lastName)\n {\n $username = str_slug(trim($firstName).\" \".trim($lastName).\" \".rand(0,99));\n\n $userNameNotUnique = true;\n\n while ($userNameNotUnique) {\n $users = static::withTrashed()->whereName($username)->get();\n if ($users->count() == 0) {\n $userNameNotUnique = false;\n }else {\n $username.= rand(0,9);\n }\n }\n\n return $username;\n }", "function get_duplicates($lastname, $firstname, $middlename)\r\n {\r\n \r\n $this->db->from($this->table);\r\n $this->db->where('lastname',$lastname);\r\n $this->db->where('firstname',$firstname);\r\n $this->db->where('middlename',$middlename);\r\n\r\n $query = $this->db->get();\r\n\r\n return $query;\r\n }", "public function generateIdSlug()\n {\n $slug = Slug::fromId($this->getKey() ?? rand());\n\n // Ensure slug is unique (since the fromId() algorithm doesn't produce unique slugs)\n $attempts = 10;\n while ($this->isExistingSlug($slug)) {\n if ($attempts <= 0) {\n throw new UnableToCreateSlugException(\n \"Unable to find unique slug for record '{$this->getKey()}', tried 10 times...\"\n );\n }\n\n $slug = Slug::random();\n $attempts--;\n }\n\n $this->setSlugValue($slug);\n }", "protected function filter_unique_slug( $context = null )\n\t{\n\t\tif ( ! in_array( $context, [ 'save', 'update' ] ) ) {\n\t\t\t$context = 'save';\n\t\t}\n\n\t\t// Since Charcoal doesn't provide a copy of the previous data,\n\t\t// import the existing data and do some comparisons.\n\t\tif ( 'update' === $context ) {\n\t\t\t$old = Charcoal::obj( get_class($this) )->load( $this->id() );\n\t\t}\n\t\telse {\n\t\t\t$old = false;\n\t\t}\n\n\t\tif ( ! $this->p('slug')->l10n() ) {\n\t\t\t$this->slug = [ $this->lang() => $this->slug ];\n\t\t}\n\n\t\tforeach ( $this->slug as $lang => &$slug ) {\n\t\t\tif (\n\t\t\t\t! $old ||\n\t\t\t\tempty( $slug ) ||\n\t\t\t\tpreg_match( '#[\\p{Z}\\p{Lu}\\p{M}]#u', $slug ) ||\n\t\t\t\tfalse !== strpos( $slug, ' ' ) ||\n\t\t\t\t(\n\t\t\t\t\t( $old instanceof Charcoal_Object ) &&\n\t\t\t\t\t( ( $old->p('slug')->text([ 'lang'=> $lang ]) ) !== $slug )\n\t\t\t\t)\n\t\t\t) {\n\t\t\t\t$slug = generate_unique_object_ident( $this->p('slug'), $slug, [ 'lang' => $lang ] );\n\t\t\t}\n\t\t}\n\n\t\tif ( ! $this->p('slug')->l10n() ) {\n\t\t\t$this->slug = reset($this->slug);\n\t\t}\n\t}", "public function chkUserDuplicate() {\n $this->load->model('register_model');\n $user_name = $this->input->post('user_name');\n $table_to_pass = 'mst_users';\n $fields_to_pass = array('user_id', 'user_name');\n $condition_to_pass = array(\"user_name\" => $user_name);\n $arr_login_data = $this->register_model->getUserInformation($table_to_pass, $fields_to_pass, $condition_to_pass, $order_by_to_pass = '', $limit_to_pass = '', $debug_to_pass = 0);\n if (count($arr_login_data)) {\n echo 'false';\n } else {\n echo 'true';\n }\n }", "public function makeSlug($text)\n {\n $slugs = [];\n\n $text = $this->setEmptySlugs($text);\n\n //Bind translated slugs\n foreach ($text as $key => $value) {\n $slugs[$key] = $this->toSlug($value);\n }\n\n //Checks if some of localized slugs in database exists in other rows\n $row = $this->getConnection()->table($this->getTable())->where(function ($query) use ($slugs) {\n //Multilanguages slug\n if ($this->hasLocalizedSlug()) {\n $i = 0;\n foreach ($slugs as $key => $value) {\n if (! $value) {\n continue;\n }\n\n $query->{ $i == 0 ? 'whereRaw' : 'orWhereRaw' }('JSON_EXTRACT(slug, \"$.'.$key.'\") = ?', $value);\n $i++;\n }\n\n }\n\n //If is simple string slug\n else {\n $query->where('slug', $slugs[0]);\n }\n })->limit(1);\n\n //If models exists, then skip slug owner\n if ($this->exists) {\n $row->where($this->getKeyName(), '!=', $this->getKey());\n }\n\n $row = $row->get(['slug']);\n\n //If new slugs does not exists, then return new generated slug\n if ($row->count() == 0) {\n return $this->castSlug(array_filter($slugs, function($item){\n return $this->isValidSlug($item);\n }));\n }\n\n //Generate new unique slug with increment\n $unique_slug = $this->makeUnique($slugs, $row->first()->slug);\n\n //If slug exists, then generate unique slug\n return $this->castSlug($unique_slug);\n }", "function cjpopups_create_unique_record($string, $db_table, $column){\n\tglobal $wpdb;\n\t$check_existing = $wpdb->get_row(\"SELECT * FROM $db_table WHERE $column = '{$string}'\");\n\tif(is_null($check_existing)){\n\t\treturn $string;\n\t}else{\n\t\tpreg_match('/(.+)([0-9]+)$/', $string, $match);\n $string = isset($match[2]) ? $match[1].($match[2] + 1) : $string.rand(10000,99999);\n $check_existing = $wpdb->get_row(\"SELECT * FROM $db_table WHERE $column = '{$string}'\");\n if(is_null($check_existing)){\n \treturn $string;\n }else{\n \treturn cjpopups_create_unique_record($string, $db_table, $column);\n }\n\t}\n}", "function sf_create_message_slugs()\n{\n\tglobal $wpdb;\n\n\t# remove all single quotes\n\t$messages = $wpdb->get_results(\"SELECT message_id, title FROM \".SFMESSAGES);\n\tif($messages)\n\t{\n\t\tforeach($messages as $message)\n\t\t{\n\t\t\t$title = stripslashes($message->title);\n\t\t\t$title = str_replace (\"'\", \"\", $title);\n\t\t\t$wpdb->query(\"UPDATE \".SFMESSAGES.\" SET title = '\".$title.\"' WHERE message_id=\".$message->message_id);\n\t\t}\n\t}\n\n\t# perform slug creation\n\t$found = true;\n\twhile($found)\n\t{\n\t\t$message = sf_grab_slugless_messages();\n\t\tif($message)\n\t\t{\n\t\t\t$slug = sf_create_slug($message->title, 'pm');\n\t\t\t# if not created force change of title\n\t\t\tif($slug)\n\t\t\t{\n\t\t\t\t$wpdb->query(\"UPDATE \".SFMESSAGES.\" SET message_slug = '\".$slug.\"' WHERE title='\".$message->title.\"';\");\n\t\t\t} else {\n\t\t\t\t$wpdb->query(\"UPDATE \".SFMESSAGES.\" SET title = 'Untitled' WHERE message_id = \".$message->message_id);\n\t\t\t}\n\t\t} else {\n\t\t\t$found = false;\n\t\t}\n\t}\n\n\treturn;\n}", "public static function generateUniqueSlug($model, $slug, $id = null)\n {\n $slug = str_slug($slug);\n $currentSlug = '';\n if ($id) {\n $currentSlug = $model->where('id', '=', $id)->value('slug');\n }\n\n if ($currentSlug && $currentSlug === $slug) {\n return $slug;\n } else {\n $slugList = $model->where('slug', 'LIKE', $slug . '%')->pluck('slug');\n if ($slugList->count() > 0) {\n $slugList = $slugList->toArray();\n if (!in_array($slug, $slugList)) {\n return $slug;\n }\n $newSlug = '';\n for ($i = 1; $i <= count($slugList); $i++) {\n $newSlug = $slug . '-' . $i;\n if (!in_array($newSlug, $slugList)) {\n return $newSlug;\n }\n }\n return $newSlug;\n } else {\n return $slug;\n }\n }\n }", "function duplicateName(){\n $dup = $this->app['db']->fetchColumn('SELECT id from worlds where name=?', array($this->name));\n if($dup == $this->id || !$dup){\n return false;\n }\n $this->validation_errors[] = 'Name is a duplicate';\n return true;\n }", "public function generateSlug()\n {\n $this->slug = str_slug($this->name) . '-' . $this->id;\n\n $this->save();\n }", "function _acf_apply_unique_field_group_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug)\n{\n}", "function wp_unique_term_slug($slug, $term)\n {\n }", "function checkForDuplicateUnique(){\n $_ufields_arr = explode(\",\", $this->listSettings->GetItem(\"MAIN\", \"UNIQUE_FIELDS\"));\n $check_fields = true;\n for ($i = 0; $i < sizeof($_ufields_arr); $i ++) {\n list ($_field[$i], $_value[$i]) = explode(\"=\", $_ufields_arr[$i]);\n if (strlen($_value[$i])) {\n $check_fields = false;\n $_query_arr[$_field[$i]] = $_value[$i];\n if ($this->_data[$_field[$i]] == $_value[$i]) {\n $check_fields = true;\n }\n }\n else {\n $_query_arr[$_field[$i]] = $this->_data[$_field[$i]];\n }\n }\n if ($check_fields) {\n $_data = $this->Storage->GetByFields($_query_arr, null);\n }\n else {\n $_data = array();\n }\n if (! empty($_data)) {\n if (($this->item_id != $_data[$this->key_field])) {\n if ($this->Kernel->Errors->HasItem($this->library_ID, \"RECORD_EXISTS\")) {\n $_error_section = $this->library_ID;\n }\n else {\n $_error_section = \"GlobalErrors\";\n }\n $this->validator->SetCustomError($_ufields_arr, \"RECORD_EXISTS\", $_error_section);\n }\n }\n }", "private function createSlug() {\r\n \r\n $proposal = !empty($this->subject) ? substr(create_slug($this->subject), 0, 60) : $this->id;\r\n \r\n $result = $this->db->fetchAll(\"SELECT post_id FROM nuke_bbposts_text WHERE url_slug = ?\", $proposal); \r\n \r\n if (count($result)) {\r\n $proposal .= count($result);\r\n }\r\n \r\n $this->url_slug = $proposal;\r\n \r\n }", "function updateSlug($table_name, $title, $id){\n\n\t\t$slug = str_slug($title, '-');\n\t\t//check current slug is exist\n\t\t$count_exist = DB::table($table_name)->where('slug', $slug)->where('id', '<>', $id)->get();\n\t\tif(count($count_exist) > 0){\n\t\t\t$related_post = getRelatedPostBySlug($table_name, $slug, $id);\n\t\t\tif(count($related_post) > 0){\n\t\t\t\tfor($i = 1; $i <= 10; $i++){\n\t\t\t\t\t$newSlug = $slug . '-' . $i;\n\t\t\t\t\t$releated_inLoop = getRelatedPostBySlug($table_name, $newSlug, $id);\n\t\t\t\t\tif(count($releated_inLoop) == 0){\n\t\t\t\t\t\t$slug = $newSlug;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tDB::table($table_name)->where('id', $id)->update(['slug' => $slug]);\n\t\treturn $slug;\n\t}", "protected function addSlug()\n {\n $slugSource = $this->generateSlugFrom();\n\n $slug = $this->generateUniqueSlug($slugSource);\n\n $this->slug = $slug;\n }", "private function getUniqueSlug(Model $model)\n {\n $slug = Str::slug($model->title);\n $slugCount = count($model->whereRaw(\"slug REGEXP '^{$slug}(-[0-9]+)?$' and id != '{$model->id}'\")->get());\n\n return ($slugCount > 0) ? \"{$slug}-{$slugCount}\" : $slug;\n }", "public function sluggable()\n {\n $array = $this->attributes;\n\n $slugcolumn = $this->getProperty('sluggable');\n\n //Set slug\n if (array_key_exists($slugcolumn, $array))\n {\n //If dynamic slugs are turned off\n if ( $this->slug_dynamic === false && $this->slug ) {\n //If does exists row, and if has been changed\n if (\n $this->exists\n && $this->isAllowedHistorySlugs()\n && ($original = $this->getOriginal('slug'))\n && $this->slug !== $original ) {\n $this->slugSnapshot($original);\n }\n }\n\n //If is available slug column value\n else if ( mb_strlen($array[$slugcolumn], 'UTF-8') > 0 ) {\n $slug = $this->makeSlug($array[$slugcolumn]);\n\n //If slug has been changed, then save previous slug state\n if (\n $this->exists\n && $this->isAllowedHistorySlugs()\n && str_replace('\": \"', '\":\"', $attributes['slug'] ?? '') != $slug\n ) {\n $this->slugSnapshot();\n }\n\n $this->attributes['slug'] = $slug;\n }\n }\n }", "function isUsernameUsed($username) {\r\n $users = retrieveUsers(0);\r\n\r\n // Check if username already exist\r\n foreach ($users as $user) {\r\n if($user['username'] == $username) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}", "function checkDuplication($oSubscriber)\n\t\t{\n\n\t\t\t$sSQL_username\t=\t\"select * from tbl_member \n\t\t\twhere user_name='\".$oSubscriber->user_name.\"'\";\n\t\t\t$rs_username\t=\t$this->Execute($sSQL_username);\n\t\t\tif($rs_username->RecordCount()) {\n\t\t\t\treturn \"username\";\n\t\t\t}\t\t\t\n\n\t\t\t$sSQL_Email\t=\t\"select * from tbl_member \n\t\t\twhere email='\".$oSubscriber->email.\"' and isActive != 'd'\";\n\t\t\t$rs_Email\t=\t$this->Execute($sSQL_Email);\n\t\t\tif($rs_Email->RecordCount()) {\n\t\t\t\treturn \"email\";\n\t\t\t}\n\t\t\t\n\t\t\treturn \"notfound\";\n\t\t}", "public function run()\n {\n User::all()->each(function ($item) {\n $slug = SlugService::createSlug(User::class, 'slug', $item->name);\n\n $item->update([\n 'slug' => $slug,\n ]);\n });\n }", "public function beforeValidate()\n\t\t\t\t{\n if (!$this->exists && !$this->slug)\n $this->slug = Str::slug($this->firstname.\" \".$this->middlename.\" \".$this->lastname);\n\t\t\t\t}", "public function generateSlug();", "function wp_filter_wp_template_unique_post_slug($override_slug, $slug, $post_id, $post_status, $post_type)\n {\n }", "public function calculateSlug() {\n $this->slug = strtolower(str_replace(array(\" \", \"_\"), array(\"-\", \"-\"), $this->nombre)).rand(1, 100);\n }", "private function ValidSlug($slug = '')\n\t{\t$rawslug = $slug = $this->TextToSlug($slug);\n\t\twhile ($this->SlugExists($slug))\n\t\t{\t$slug = $rawslug . ++$count;\n\t\t}\n\t\treturn $slug;\n\t}", "public function sluggable() {\n return [\n 'username' => [\n 'source' => 'first_name'\n ]\n ];\n }", "public function createSlug($slug){\n $next = 1;\n while(Band::where('band_slug', '=', $slug)->first()) { \n $pos = strrpos($slug, \"_\");\n $digit = substr($slug, -1);\n $digit = intval($digit);\n if($digit == 0){\n $i = 1;\n $slug = $slug.'-'.$i;\n \n }else{\n $slug = substr($slug, 0, -2);\n $slug = $slug.'-'.$next;\n $next++;\n } \n }\n return $slug;\n }", "private function getUniqueExists($uniques, $table, $column)\n {\n\n }", "public static function findBySlug(string $slug, array $columns = ['*']);", "private function getExistingSlugs($slug)\n {\n $list = collect();\n foreach ($this->uniqueModels() as $class) {\n\n // get entries matching slug\n $slugs = $this->eloqent($class)\n ->whereRaw(\"slug LIKE '$slug%'\")\n ->withTrashed()// trashed, when entry gets activated\n ->get()\n ->pluck('slug');\n\n $list = $list->merge($slugs);\n }\n\n return $list;\n }", "public function is_duplicate() {\n\n\t\t$post = $this->input->post();\n\n\t\t// Filter by name.\n\t\t$this->db->where( 'name', trim( $post['name'] ) );\n\n\t\t// Filter by church.\n\t\t$this->db->where( 'church', (int) $post['church'] );\n\n\t\t// Filter by age.\n\t\tif ( ! empty( $post['age'] ) ) {\n\t\t\t$this->db->where( 'age', (int) $post['age'] );\n\t\t}\n\n\t\t// Filter by gender.\n\t\tif ( ! empty( $post['gender'] ) ) {\n\t\t\t$this->db->where( 'gender', $post['gender'] );\n\t\t}\n\n\t\t$query = $this->db->get( 'registration' );\n\n\t\treturn $query->num_rows() > 0;\n\n\t}", "public function addOrUpdateUser($arr, $slug){\n // return $arr;\n $user = User::updateOrCreate(['slug'=>$slug],$arr);\n if(!$user){\n return $this->fail('Cannot Add or Update user','AddUser');\n }\n return $this->success('Company updated successfully', $user);\n }", "private static function _createUniqueTitle($title) {\n while (($p = get_page_by_title($title)) && $p->post_title === $title) {\n if (preg_match('#(.*\\s)(\\d+)$#', $title, $match)) {\n $new_title = $match[1] . ($match[2] + 1);\n if ($title === $new_title) {\n break;\n }\n $title = $new_title;\n } else {\n $title = $title . ' 1';\n }\n }\n return $title;\n }", "function checkDuplication($oAffiliate)\n\t\t{\n\t\t\t$sSQL_username\t=\t\"select * from tbl_member \n\t\t\twhere user_name='\".$oAffiliate->username.\"'\";\n\t\t\t$rs_username\t=\t$this->Execute($sSQL_username);\n\t\t\tif($rs_username->RecordCount()) {\n\t\t\t\treturn \"username\";\n\t\t\t}\t\t\t\n\t\t\t\n\t\t\t$sSQL_Email\t=\t\"select * from tbl_member \n\t\t\twhere email='\".$oAffiliate->email.\"' and isActive !='d'\";\n\t\t\t$rs_Email\t=\t$this->Execute($sSQL_Email);\n\t\t\tif($rs_Email->RecordCount()) {\n\t\t\t\treturn \"email\";\n\t\t\t}\n\t\t\t\n\t\t\t$sSQL_Promo\t=\t\"select * from tbl_affiliate aff, tbl_member mem\n\t\t\t\t\t\t\t \twhere aff.affiliate_id = mem.member_id and \n\t\t\t\t\t\t\t\taff.promo_code='\".$oAffiliate->promo_code.\"' \n\t\t\t\t\t\t\t\tand mem.isActive !='d'\";\n\t\t\t\n\t\t\t$rs_Promo\t=\t$this->Execute($sSQL_Promo);\t\t\t\n\t\t\tif($rs_Promo->RecordCount()) {\n\t\t\t\treturn \"promo_code\";\n\t\t\t}\n\n\t\t\t\n\t\t\t\n\t\t\treturn \"notfound\";\n\t\t}", "public function getUnique($title, $table, $field, $i = 0)\n {\n $check = ($i > 0) ? $title . '-' . $i : $title;\n\n if (DB::table($table)->where($field, $check)->exists()) {\n\n $check = $this->getUnique($title, $table, $field, $i + 1);\n\n }\n\n return $check;\n }", "public function generateTitleSlug(array $fields)\n {\n static $attempts = 0;\n\n $titleSlug = Slug::fromTitle(implode('-', $this->getTitleFields($fields)));\n\n // This is not the first time we've attempted to create a title slug, so - let's make it more unique\n if ($attempts > 0) {\n $titleSlug . \"-{$attempts}\";\n }\n\n $this->setSlugValue($titleSlug);\n\n $attempts++;\n }", "function is_unique_username($username, $current_id=null) {\n $users_result = find_users_by_username($username);\n // Loop through all results, return false if username is in use\n while($user = db_fetch_assoc($users_result)) {\n // Make sure username isn't in use by our current user.\n // Use (int) to make sure we are comparing two integers.\n if((int) $user['id'] != (int) $current_id) {\n return false; // username is being used by someone else\n }\n }\n // Returns true at the end, but only if the loop had no records\n // to loop through or if the loop never returned false.\n return true; // username is not used by anyone\n }", "function addUser( $name, $email, $pw, $fullname, $organization ) {\n $d = loadDB();\n \n $found = false;\n $highestID = 0;\n foreach ($d['users'] as $user) {\n if ($name == $user['name']) {\n audit( \"addUser\", \"Error: \".$name.\" \".$email.\" \".$fullname.\" \".$organization.\" a user identified by this name exists already\" );\n $found = true;\n }\n if ($email == $user['email']) {\n audit( \"addUser\", \"Error: \".$name.\" \".$email.\" \".$fullname.\" \".$organization.\" a user identified by this email exists already\" );\n $found = true;\n }\n if ($user['id'] > $highestID)\n $highestID = $user['id'];\n }\n $highestID++;\n if (!$found) {\n array_push( $d['users'], array( \"name\" => $name, \"id\" => $highestID, \"password\" => $pw, \"email\" => $email, \"fullname\" => $fullname, \"organization\" => $organization, \"roles\" => array() ) );\n saveDB( $d );\n } else {\n $highestID = -1; // indicate error\n }\n audit( \"addUser\", $name.\" \".$email.\" \".$fullname.\" \".$organization );\n return $highestID;\n }", "public function uniqueName($name)\n\t{\n\t\t$name_attempt = $name;\n\t\t$match = true;\n\t\t\n\t\t// build slug/number combos until an unused slug is found\n\t\tfor($i = 1; $match; $i++)\n\t\t{\n\t\t\t$match = false;\n\t\t\t\n\t\t\tif($i > 1) $name_attempt = $name.' ('.$i.')';\n\t\t\telse $name_attempt = $name;\n\t\t\t\n\t\t\tforeach($this->layouts as $layout)\n\t\t\t{\n\t\t\t\tif($this->$layout->name == $name_attempt)\n\t\t\t\t{\n\t\t\t\t\t$match = true;\n\t\t\t\t}//end if\n\t\t\t}//end if\n\t\t}//end while\n\t\t\n\t\t// when we get to here, a valid slug was built. Assign to slug.\n\t\t$name = $name_attempt;\n\t\t\n\t\t// unset temp variable\n\t\tunset($name_attempt);\n\t\t\n\t\treturn $name;\n\t}", "function auth_register_user($user){\n $users = json_read('data/users.json');\n $max = -1;\n foreach($users as $user_max){\n if($user_max->id > $max) $max = $user_max->id;\n }\n $new_id = $max + 1;\n $user->id = $new_id;\n $user->pword = password_hash($user->pword1, PASSWORD_DEFAULT);\n $user->pword1 = $user->pword2 = '';\n $users->$new_id = $user;\n json_write('data/users.json', $users);\n\n return $new_id;\n}", "public function deleteDuplicate() {\n\t\t$sql = \"DELETE FROM reestr_distinct\";\n\t\t$this->query_data($sql);\n\t\t$sql = \"INSERT INTO reestr_distinct SELECT DISTINCT col1, col2, col3, col4, col5, col6, col7, col8, col9, col10, col11, col12, col13, col14, col15, col16, col17, now(),NULL,'Бессрочно' FROM reestr\";\n\t\t$this->query_data($sql);\n\t\treturn 0;\n\t}", "protected static function getHashIdPrefixColumn()\n {\n return 'slug';\n }", "public static function get_slug($tbl, $col, $val, $except_id = 0){\n\t\t$slug = Str::slug($val);\n\t\t$check_slug = DB::table($tbl)->where(\"{$col}\",'like',\"%{$val}%\")->where('id', '<>', $except_id)->count();\n\t\tif($check_slug != 0) $slug .= ++$check_slug;\n\t\treturn $slug;\n\t}", "public function slugs();", "public function testUpdateUniqueColumn() {\n $this->loadFixtures('Users');\n\n $first = User::select()->orderBy('_id', 'asc')->first();\n\n $user = new User();\n $user->id = $first->_id;\n $user->username = 'batman'; // name already exists\n\n try {\n $this->assertEquals(1, $user->save());\n $this->assertTrue(false);\n } catch (Exception $e) {\n $this->assertTrue(true);\n }\n }", "function sf_precreate_sflast()\n{\n\tglobal $wpdb;\n\n\t$users = $wpdb->get_results(\"SELECT ID FROM \".SFUSERS);\n\tif($users)\n\t{\n\t\tforeach($users as $user)\n\t\t{\n\t\t\t$check = $wpdb->get_var(\"SELECT umeta_id FROM \".SFUSERMETA.\" WHERE meta_key='\".$wpdb->prefix.\"sflast' AND user_id=\".$user->ID);\n\t\t\tif(!$check)\n\t\t\t{\n\t\t\t\tsf_set_last_visited($user->ID);\n\t\t\t}\n\t\t}\n\t}\n\treturn;\n}", "public function check_duplicate() {\n $this->db->where ( 'orderID', trim ( $this->input->post ( 'orderID' ) ) );\n\n if ($this->db->count_all_results ( $this->table ))\n echo \"1\"; // duplicate\n else\n echo \"0\";\n }", "private function duplicateCount() {\n try {\n $duplicates = $this->database->query(\n \"select wsd.value as uid,\n ws.entity_id,\n count(*) as duplicates\n from {webform_submission} ws\n left join {webform_submission_data} wsd on ws.sid = wsd.sid AND wsd.name = :wsd_name\n where ws.webform_id = :webform_id\n group by wsd.value, ws.entity_id\n having duplicates > :duplicate_level\n order by created asc\",\n [\n ':wsd_name' => 'student_id',\n ':webform_id' => 'tutorial',\n ':duplicate_level' => 1,\n ]\n )->fetchAll();\n } catch (DatabaseExceptionWrapper $e) {\n $this->logger->error('<pre>%e<br>%t</pre>',\n [\n '%e' => $e->getMessage(),\n '%t' => $e->getTraceAsString(),\n ]\n );\n $duplicates = [];\n }\n return count($duplicates);\n }", "protected function _makeUniqueSlug(EntityManager $em, $entity)\n {\n $entityClass = get_class($entity);\n $meta = $em->getClassMetadata($entityClass);\n $config = $this->getConfiguration($em, $entityClass);\n $preferedSlug = $meta->getReflectionProperty($config['slug'])->getValue($entity);\n\n // search for similar slug\n $qb = $em->createQueryBuilder();\n $qb->select('rec.' . $config['slug'])\n ->from($entityClass, 'rec')\n ->add('where', $qb->expr()->like(\n 'rec.' . $config['slug'],\n $qb->expr()->literal($preferedSlug . '%'))\n );\n // include identifiers\n $entityIdentifiers = $meta->getIdentifierValues($entity);\n foreach ($entityIdentifiers as $field => $value) {\n if (strlen($value)) {\n $qb->add('where', 'rec.' . $field . ' <> ' . $value);\n }\n }\n $q = $qb->getQuery();\n $q->setHydrationMode(Query::HYDRATE_ARRAY);\n $result = $q->execute();\n\n if (is_array($result) && count($result)) {\n $generatedSlug = $preferedSlug;\n $sameSlugs = array();\n foreach ($result as $list) {\n $sameSlugs[] = $list['slug'];\n }\n\n $i = 0;\n if (preg_match(\"@{$config['separator']}\\d+$@sm\", $generatedSlug, $m)) {\n $i = abs(intval($m[0]));\n }\n while (in_array($generatedSlug, $sameSlugs)) {\n $generatedSlug = $preferedSlug . $config['separator'] . ++$i;\n }\n\n $mapping = $meta->getFieldMapping($config['slug']);\n $needRecursion = false;\n if (strlen($generatedSlug) > $mapping['length']) {\n $needRecursion = true;\n $generatedSlug = substr(\n $generatedSlug,\n 0,\n $mapping['length'] - (strlen($i) + strlen($config['separator']))\n );\n $generatedSlug .= $config['separator'] . $i;\n }\n\n $meta->getReflectionProperty($config['slug'])->setValue($entity, $generatedSlug);\n if ($needRecursion) {\n $generatedSlug = $this->_makeUniqueSlug($em, $entity);\n }\n $preferedSlug = $generatedSlug;\n }\n return $preferedSlug;\n }", "public function validate_uniqueUsername($value, $input, $args){\n\t\t$user = $this->user->where('username', $value);\n\n\t\t//ignore current username when updating if the same username is passed\n\t\tif($this->auth && $this->auth->username === $value){\n\t\t\treturn true;\n\t\t}\n\n\t\treturn ! (bool) $user->count();\n\t}", "private function getValidSlug($inputSlug)\n {\n $validSlug = false;\n $i = 0;\n do {\n $inputSlug .= $i;\n $sql = \"SELECT COUNT(*) AS count FROM content WHERE slug = ?\";\n $res = $this->db->executeFetchAll($sql, [$inputSlug]);\n //print_r($count);\n $validSlug = ($res[0]->count == 0) ? true : false;\n } while (!$validSlug);\n return $inputSlug;\n }", "protected function ensureSlugIsUnique($model)\n {\n if (! $model->isDirty('slug') || empty($model->slug)) {\n return;\n }\n\n // If the user has provided an slug manually, we have to make sure\n // that that slug is unique. If it is not, the SlugService class\n // will append an incremental suffix to ensure its uniqueness.\n $model->slug = SlugService::createSlug($model, 'slug', $model->slug, []);\n }", "function db_duplicate($table, $id) {\r\n\r\n\t$fieldQuery = db_query(\"DESCRIBE $table\");\r\n\t\r\n\tif (db_numrows($fieldQuery) > 1) {\r\n\t\r\n\t\t$sourceQuery = db_query(\"SELECT * FROM $table WHERE id=\".escapeValue($id));\r\n\t\t\r\n\t\tif (db_numrows($sourceQuery) == 1) {\r\n\t\r\n\t\t\t$sourceResult = db_fetch($sourceQuery);\r\n\t\t\t$sql = \"UPDATE $table SET \";\r\n\t\t\t$first = 1;\r\n\t\r\n\t\t\twhile ($fieldResult = db_fetch($fieldQuery)) {\r\n\t\t\r\n\t\t\t\tif (strtolower($fieldResult[\"Field\"]) != \"id\") {\r\n\t\t\t\t\r\n\t\t\t\t\tif (!$first) $sql .= \",\";\r\n\t\t\t\t\tif (substr(strtolower($fieldResult[\"Type\"]),0,7) == \"varchar\" || strtolower($fieldResult[\"Type\"]) == \"text\")\r\n\t\t\t\t\t\t$sql .= $fieldResult[\"Field\"].\"=\".escapeQuote($sourceResult[$fieldResult[\"Field\"]],0);\r\n\t\t\t\t\telse\t\t\t\t\r\n\t\t\t\t\t\t$sql .= $fieldResult[\"Field\"].\"=\".escapeValue($sourceResult[$fieldResult[\"Field\"]]);\r\n\t\t\t\t\t$first = 0;\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//echo $sql;\r\n\t\t\t//exit;\r\n\t\t\t$newId = db_insert($table);\r\n\t\t\tdb_query($sql.\" WHERE id=$newId\");\t\r\n\t\t\treturn $newId;\r\n\r\n\t\t} else return 0;\r\n\r\n\t} else return 0;\r\n\t\r\n}", "public function checkDuplicates(){\n\t\t$db = new database();\n\t\t$gebruiker = $db->select(\"*\", \"klant\", 1, ['this'=>\"gebruikersnaam\", \"that\"=>$this->gebruikersnaam]);\n\t\t//var_dump($gebruiker);\n\t\tif(!empty($gebruiker[0])){\n\t\t\treturn true;\n\t\t}\n\n\t}", "private function slugify($text, $exists = null)\n {\n $text = Helper::formatSlug($text);\n $set = $this->findBySlug($text);\n $unique = false;\n\n if (!$set || $set->id === $exists) {\n $unique = true;\n\n return $text;\n }\n\n $i = 0;\n\n while (!$unique) {\n $i++;\n $set = $this->findBySlug($text.'-'.$i);\n\n if (!$set || $set->id === $exists) {\n $unique = true;\n }\n }\n\n return $text.'-'.$i;\n }", "public function bySlug($slug);", "function getUniqueUsername($username)\n\t\t{\n\t\t\t//getting all email id from database\n\t\t\t$allUser = $this->manageContent->getValue('user_credentials','username');\n\t\t\t//initializing a parameter\n\t\t\t$userCounter = 0;\n\t\t\tforeach($allUser as $allUsers)\n\t\t\t{\n\t\t\t\tif($allUsers['username'] == $username)\n\t\t\t\t{\n\t\t\t\t\t$userCounter = 1;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\techo $userCounter;\n\t\t}", "public static function findBySlugOrFail(string $slug, array $columns = ['*']);", "private function duplicate_mapel()\n {\n // UNLESS it's the email for the current user\n \n $id = $this->input->post('haknilai_id');\n $this->db->where('haknilai_kelas', $this->input->post('haknilai_kelas'));\n $this->db->where('haknilai_mapel', $this->input->post('haknilai_mapel'));\n !$id || $this->db->where('haknilai_id !=', $id);\n $this->db->where('haknilai_tahunajaran =', $this->konfigurasi_m->konfig_tahun());\n //$this->db->where('haknilai_semester =', $this->konfigurasi_m->konfig_semester());\n $duplicate_mapel = $this->hakmapel_m->get();\n \n return $duplicate_mapel;\n }", "function has_unique_username($username/*, $current_id=\"0\"*/) {\r\n global $db;\r\n\r\n $sql = \"SELECT * FROM admins \";\r\n $sql .= \"WHERE username='\" . $db->real_escape_string($username) . \"';\";\r\n //$sql .= \"AND id != '\" . $db->real_escape_string($current_id) . \"'\";\r\n\r\n $result = $db->query($sql);\r\n $user_count = $result->num_rows;\r\n $result->free_result();\r\n\r\n return $user_count === 0;\r\n}", "private function check_username_exists( $data ) {\n\t\tglobal $coauthors_plus;\n\t\t$user_id = username_exists( $data['user-name'] );\n\t\tif (!$user_id) {\n\n\t\t\tif ( null != $coauthors_plus) {\n\n\t\t\t\t$guest_author = array();\n\t\t\t\t$guest_author['ID'] = '';\n\t\t\t\t$guest_author['display_name'] = $data['display-name'];\n\t\t\t\t$guest_author['first_name'] = $data['first-name'];\n\t\t\t\t$guest_author['last_name'] = $data['last-name'];\n\t\t\t\t$guest_author['user_login'] = $data['user-name'];\n\t\t\t\t$guest_author['user_email'] = $data['email'];\n\t\t\t\t$guest_author['description'] = $data['bio'];\n\t\t\t\t$guest_author['jabber'] = '';\n\t\t\t\t$guest_author['yahooim'] = '';\n\t\t\t\t$guest_author['aim'] = '';\n\t\t\t\t$guest_author['website'] = $data['website'];\n\t\t\t\t$guest_author['linked_account'] = '';\n\t\t\t\t$guest_author['website'] = $data['website'];\n\t\t\t\t$guest_author['company'] = $data['company'];\n\t\t\t\t$guest_author['title'] = $data['title'];\n\t\t\t\t$guest_author['google'] = $data['google'];\n\t\t\t\t$guest_author['twitter'] = $data['twitter'];\n\n\t\t\t\t$retval = $coauthors_plus->guest_authors->create( $guest_author );\n\t\t\t\tif( is_wp_error( $retval ) ) {\n\t\t\t\t\t$author = $coauthors_plus->guest_authors->get_guest_author_by( 'user_login', $data['user-name'] );\n\t\t\t\t\tif (null != $author){\n\t\t\t\t\t\t$user_id = 'guest-'.$author->ID;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t$user_id = 'guest-'.$retval;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\n\t\t\t\n\t\t}\n\t\treturn $user_id;\n\t}", "public function generateUsername( $base ) {\r\n $result = self::$database->query(\"SELECT username FROM `users` WHERE username like CONCAT('%', ?, '%') order by username desc limit 1\", strtolower($base));\r\n if ($result) {\r\n // User already exists\r\n preg_match('/'.$base.'(\\d+)/', $result[0]->username, $match);\r\n if (isset($match[1])) {\r\n $username=$base.((int)$match[1]+1);\r\n } else {\r\n $username=$base.'2';\r\n }\r\n } else {\r\n $username=$base;\r\n }\r\n $username=preg_replace('/[\\.\\/]/', \"\", stripslashes($username)); // remove dots and back/forward slashes\r\n return $username;\r\n }", "function sf_check_all_display_names()\n{\n\tglobal $wpdb;\n\n\t$users = $wpdb->get_results(\"SELECT ID, user_login, display_name FROM \".SFUSERS.\" WHERE display_name=''\");\n\tif($users)\n\t{\n\t\tforeach($users as $user)\n\t\t{\n\t\t\t$wpdb->query(\"UPDATE \".SFUSERS.\" SET display_name='\".$user->login_name.\"' WHERE ID=\".$user->ID);\n\t\t}\n\t}\n\treturn;\n}", "public function isUnique();", "public function chkEditUsernameDuplicate() {\r\n\r\n if ($this->input->post('user_name') == $this->input->post('user_name_old')) {\r\n echo 'true';\r\n } else {\r\n $table_to_pass = 'mst_users';\r\n $fields_to_pass = array('user_id', 'user_name');\r\n $condition_to_pass = array(\"user_email\" => $this->input->post('user_name'));\r\n $arr_login_data = $this->user_model->getUserInformation($table_to_pass, $fields_to_pass, $condition_to_pass, $order_by_to_pass = '', $limit_to_pass = '', $debug_to_pass = 0);\r\n if (count($arr_login_data)) {\r\n echo 'false';\r\n } else {\r\n echo 'true';\r\n }\r\n }\r\n }", "function checkDuplicates($self, $loggedData){\n $duplicates = array();\n $userMatch = false; # usermatch and emailmatch initially set to false\n $emailMatch = false;\n $username = trim($_POST['username']);\n $email = trim($_POST['email']);\n foreach ($loggedData as $key => $value) { #loop through text file data\n $loggedData = explode(',', $value); # explode at comma\n $loggedData[0] = trim($loggedData[0]); #trim data\n $loggedData[5] = trim($loggedData[5]);\n if ($loggedData[0] == $username){ # username is at index [0] of the text file data\n $userMatch = true;\n }\n if($loggedData[5] == $email){ # email value will be at index [5]\n $emailMatch = true; # change emailmatch to true if match found\n }\n }\n if($emailMatch== true){\n $duplicates['email'] = 'This email is already in use'; #adding data to a duplicates array if match is true\n }\n if($userMatch== true){\n $duplicates['username'] = 'This username is already in use';\n }\n\n return $duplicates; # the duplicates array gets represnted to the user on the add user page\n}", "function tptn_clean_duplicates( $daily = false ) {\n\tglobal $wpdb;\n\n\t$table_name = $wpdb->base_prefix . 'top_ten';\n\tif ( $daily ) {\n\t\t$table_name .= '_daily';\n\t}\n\n\t$wpdb->query( 'CREATE TEMPORARY TABLE ' . $table_name . '_temp AS SELECT * FROM ' . $table_name . ' GROUP BY postnumber' ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching, WordPress.DB.PreparedSQL.NotPrepared, WordPress.DB.DirectDatabaseQuery.SchemaChange\n\t$wpdb->query( \"TRUNCATE TABLE $table_name\" ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching, WordPress.DB.PreparedSQL.InterpolatedNotPrepared\n\t$wpdb->query( 'INSERT INTO ' . $table_name . ' SELECT * FROM ' . $table_name . '_temp' ); // phpcs:ignore WordPress.DB.DirectDatabaseQuery.DirectQuery, WordPress.DB.DirectDatabaseQuery.NoCaching, WordPress.DB.PreparedSQL.NotPrepared\n}", "public static function findOrCreateBySlug(string $slug, array $values = []);", "public function generateSlug()\n {\n $strategy = $this->slugStrategy();\n\n if (in_array($strategy, ['uuid', 'id'])) {\n $this->generateIdSlug();\n } elseif ($strategy != 'id') {\n $this->generateTitleSlug((array) $strategy);\n }\n }", "public function countOfRealurlAliasMigrations(): int\n {\n $elementCount = 0;\n // Check if table 'tx_realurl_uniqalias' exists\n /** @var QueryBuilder $queryBuilder */\n $queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)\n ->getQueryBuilderForTable('tx_realurl_uniqalias');\n $schemaManager = $queryBuilder->getConnection()->getSchemaManager();\n if ($schemaManager->tablesExist(['tx_realurl_uniqalias']) === true) {\n // Count valid aliases for news\n $queryBuilder->getRestrictions()->removeAll();\n $elementCount = $queryBuilder->selectLiteral('COUNT(DISTINCT ' . $this->tableName . '.uid)')\n ->from('tx_realurl_uniqalias')\n ->join(\n 'tx_realurl_uniqalias',\n $this->tableName,\n $this->tableName,\n $queryBuilder->expr()->eq(\n 'tx_realurl_uniqalias.value_id',\n $queryBuilder->quoteIdentifier($this->tableName . '.uid')\n )\n )\n ->where(\n $queryBuilder->expr()->andX(\n $queryBuilder->expr()->orX(\n $queryBuilder->expr()->eq(\n $this->tableName . '.' . $this->slugFieldName,\n $queryBuilder->createNamedParameter('', \\PDO::PARAM_STR)\n ),\n $queryBuilder->expr()->isNull($this->tableName . '.' . $this->slugFieldName)\n ),\n $queryBuilder->expr()->eq(\n $this->tableName . '.sys_language_uid',\n 'tx_realurl_uniqalias.lang'\n ),\n $queryBuilder->expr()->eq(\n 'tx_realurl_uniqalias.tablename',\n $queryBuilder->createNamedParameter($this->tableName, \\PDO::PARAM_STR)\n ),\n $queryBuilder->expr()->orX(\n $queryBuilder->expr()->eq(\n 'tx_realurl_uniqalias.expire',\n $queryBuilder->createNamedParameter(0, \\PDO::PARAM_INT)\n ),\n $queryBuilder->expr()->gte(\n 'tx_realurl_uniqalias.expire',\n $queryBuilder->createNamedParameter($GLOBALS['ACCESS_TIME'], \\PDO::PARAM_INT)\n )\n )\n )\n )\n ->execute()->fetchColumn(0);\n }\n return $elementCount;\n }", "public function performRealurlAliasMigration(): array\n {\n $databaseQueries = [];\n\n // Check if table 'tx_realurl_uniqalias' exists\n /** @var QueryBuilder $queryBuilderForRealurl */\n $queryBuilderForRealurl = GeneralUtility::makeInstance(ConnectionPool::class)\n ->getQueryBuilderForTable('tx_realurl_uniqalias');\n $schemaManager = $queryBuilderForRealurl->getConnection()->getSchemaManager();\n if ($schemaManager->tablesExist(['tx_realurl_uniqalias']) === true) {\n /** @var Connection $connection */\n $connection = GeneralUtility::makeInstance(ConnectionPool::class)\n ->getConnectionForTable($this->tableName);\n $queryBuilder = $connection->createQueryBuilder();\n\n // Get entries to update\n $statement = $queryBuilder\n ->selectLiteral(\n 'DISTINCT ' . $this->tableName . '.uid, tx_realurl_uniqalias.value_alias, ' . $this->tableName . '.uid'\n )\n ->from($this->tableName)\n ->join(\n $this->tableName,\n 'tx_realurl_uniqalias',\n 'tx_realurl_uniqalias',\n $queryBuilder->expr()->eq(\n $this->tableName . '.uid',\n $queryBuilder->quoteIdentifier('tx_realurl_uniqalias.value_id')\n )\n )\n ->where(\n $queryBuilder->expr()->andX(\n $queryBuilder->expr()->orX(\n $queryBuilder->expr()->eq(\n $this->tableName . '.' . $this->slugFieldName,\n $queryBuilder->createNamedParameter('', \\PDO::PARAM_STR)\n ),\n $queryBuilder->expr()->isNull($this->tableName . '.' . $this->slugFieldName)\n ),\n $queryBuilder->expr()->eq(\n $this->tableName . '.sys_language_uid',\n 'tx_realurl_uniqalias.lang'\n ),\n $queryBuilder->expr()->eq(\n 'tx_realurl_uniqalias.tablename',\n $queryBuilder->createNamedParameter($this->tableName, \\PDO::PARAM_STR)\n ),\n $queryBuilder->expr()->orX(\n $queryBuilder->expr()->eq(\n 'tx_realurl_uniqalias.expire',\n $queryBuilder->createNamedParameter(0, \\PDO::PARAM_INT)\n ),\n $queryBuilder->expr()->gte(\n 'tx_realurl_uniqalias.expire',\n $queryBuilder->createNamedParameter($GLOBALS['ACCESS_TIME'], \\PDO::PARAM_INT)\n )\n )\n )\n )\n ->execute();\n\n // Update entries\n while ($record = $statement->fetch()) {\n $slug = (string)$record['value_alias'];\n $queryBuilder = $connection->createQueryBuilder();\n $queryBuilder->update($this->tableName)\n ->where(\n $queryBuilder->expr()->eq(\n 'uid',\n $queryBuilder->createNamedParameter($record['uid'], \\PDO::PARAM_INT)\n )\n )\n ->set($this->slugFieldName, $slug);\n $databaseQueries[] = $queryBuilder->getSQL();\n $queryBuilder->execute();\n }\n }\n\n return $databaseQueries;\n }", "public function duplicated()\r\n {\r\n // Fetch participant users relation before resetting id!\r\n $this->participantUsers;\r\n $this->id = null;\r\n $this->isNewRecord = true;\r\n $this->date = null;\r\n }", "function validate_user_unique(string $field_input, array &$field): bool\n{\n if (App::$db->getRowWhere('users', ['email' => $field_input])) {\n $field['error'] = 'User already exists';\n\n return false;\n }\n\n return true;\n}" ]
[ "0.59821504", "0.55866885", "0.5552416", "0.5497419", "0.5417848", "0.5415143", "0.53913385", "0.53178173", "0.5302348", "0.52973294", "0.5213175", "0.52051747", "0.51948917", "0.51559395", "0.51239604", "0.50736296", "0.50525063", "0.5051309", "0.5042046", "0.50399995", "0.50333697", "0.5026151", "0.5004354", "0.4994117", "0.4982081", "0.4954828", "0.4935087", "0.4926482", "0.48994225", "0.48927724", "0.48922974", "0.4890043", "0.4858284", "0.48361537", "0.4833908", "0.482998", "0.48266995", "0.48168153", "0.4808204", "0.48061055", "0.48006248", "0.47977322", "0.47862524", "0.47861266", "0.47731978", "0.47693822", "0.47684115", "0.47575584", "0.47569332", "0.4747086", "0.4746746", "0.47411388", "0.47031227", "0.47021598", "0.47012925", "0.4699688", "0.4698976", "0.46982494", "0.46829093", "0.46816984", "0.46760106", "0.46706992", "0.4666159", "0.4652311", "0.4651469", "0.46407157", "0.46368656", "0.46359944", "0.4633965", "0.46322834", "0.46143004", "0.46061954", "0.4602637", "0.45964304", "0.45919842", "0.45793167", "0.45748433", "0.45744178", "0.45731142", "0.45672575", "0.45593944", "0.45580348", "0.45558572", "0.45551422", "0.45498532", "0.4549611", "0.45437214", "0.45432884", "0.45408806", "0.45402133", "0.45368937", "0.4533767", "0.45304602", "0.45303544", "0.45238745", "0.45128256", "0.4512619", "0.45096838", "0.45037374", "0.44993782" ]
0.4634077
68
Insted of ID, use the slug column for lookup
public function getRouteKeyName() { return 'slug'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function slugStrategy()\n {\n return 'id';\n }", "function getSlugFromId($id='') {\n\t\tif(!$id) return '';\n\t\t$result = $this->select('slug',\"`store_id` = '\".$this->store_id.\"' AND id = '$id'\");\n\t\tif($result) return $result[0]['slug'];\n\t\treturn '';\n\t}", "public function getSlug()\n {\n return $this->slug ?? $this->id;\n }", "function slugify ($str) { // turn name into slug for ID\r\n\t$slug = str_replace(' ','-',strtolower($str));\r\n\treturn $slug;\t\r\n}", "function ss_get_slug( $id ) {\r\n\tif ( $id==null ) $id=$post->ID;\r\n\t$post_data = get_post( $id, ARRAY_A );\r\n\t$slug = $post_data['post_name'];\r\n\treturn $slug;\r\n}", "public function slug();", "public function slug();", "public function getIdentifier()\n {\n return $this->slug ?: $this->id;\n }", "public function getSlugFromResourceId(int $id): string;", "public function getSlug();", "public function getSlug();", "public function getSlug();", "public function getSlug();", "public function getBySlug()\n {\n }", "public function getFieldSlug();", "function get_id_from_blogname($slug)\n {\n }", "public function bySlug($slug);", "public function getSlugKey()\n {\n return 'slug';\n }", "function getIdFromSlug($slug='') {\n\t\tif(!$slug) return 0;\n\t\t$result = $this->select('id',\"`store_id` = '\".$this->store_id.\"' AND slug = '$slug'\");\n\t\tif($result) return $result[0]['id'];\n\t\treturn 0;\n\t}", "public function get_slug(){ return $this->slug; }", "public function getSlugKeyName(): string;", "function updateSlug($table_name, $title, $id){\n\n\t\t$slug = str_slug($title, '-');\n\t\t//check current slug is exist\n\t\t$count_exist = DB::table($table_name)->where('slug', $slug)->where('id', '<>', $id)->get();\n\t\tif(count($count_exist) > 0){\n\t\t\t$related_post = getRelatedPostBySlug($table_name, $slug, $id);\n\t\t\tif(count($related_post) > 0){\n\t\t\t\tfor($i = 1; $i <= 10; $i++){\n\t\t\t\t\t$newSlug = $slug . '-' . $i;\n\t\t\t\t\t$releated_inLoop = getRelatedPostBySlug($table_name, $newSlug, $id);\n\t\t\t\t\tif(count($releated_inLoop) == 0){\n\t\t\t\t\t\t$slug = $newSlug;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tDB::table($table_name)->where('id', $id)->update(['slug' => $slug]);\n\t\treturn $slug;\n\t}", "protected static function getHashIdPrefixColumn()\n {\n return 'slug';\n }", "public function generateSlug()\n {\n if ($this->slug != str_slug($this->title)) {\n $this->slug = str_slug($this->title);\n }\n\n while ($count = self::where(['slug' => $this->slug])->where('id', '!=', $this->id)->count()) {\n $this->slug .= '-' . $count;\n }\n }", "public function slug($slug);", "public static function get_slug($tbl, $col, $val, $except_id = 0){\n\t\t$slug = Str::slug($val);\n\t\t$check_slug = DB::table($tbl)->where(\"{$col}\",'like',\"%{$val}%\")->where('id', '<>', $except_id)->count();\n\t\tif($check_slug != 0) $slug .= ++$check_slug;\n\t\treturn $slug;\n\t}", "public function getSlug()\n {\n return $this\n ->hasOne(Slug::class, ['id' => 'slugId']);\n }", "function idOrSlug(array $resource): string\n{\n global $config;\n return htmlspecialchars($config[\"use_url_rewrite\"] ? $resource[\"slug\"] : $resource[\"id\"]);\n}", "public function sluggable()\n {\n $array = $this->attributes;\n\n $slugcolumn = $this->getProperty('sluggable');\n\n //Set slug\n if (array_key_exists($slugcolumn, $array))\n {\n //If dynamic slugs are turned off\n if ( $this->slug_dynamic === false && $this->slug ) {\n //If does exists row, and if has been changed\n if (\n $this->exists\n && $this->isAllowedHistorySlugs()\n && ($original = $this->getOriginal('slug'))\n && $this->slug !== $original ) {\n $this->slugSnapshot($original);\n }\n }\n\n //If is available slug column value\n else if ( mb_strlen($array[$slugcolumn], 'UTF-8') > 0 ) {\n $slug = $this->makeSlug($array[$slugcolumn]);\n\n //If slug has been changed, then save previous slug state\n if (\n $this->exists\n && $this->isAllowedHistorySlugs()\n && str_replace('\": \"', '\":\"', $attributes['slug'] ?? '') != $slug\n ) {\n $this->slugSnapshot();\n }\n\n $this->attributes['slug'] = $slug;\n }\n }\n }", "public function generateSlug();", "public function getSlugAttribute()\n\t{\n\t\treturn $this->getOriginal('slug') ?: $this->id;\n\t}", "public function slug(): string;", "public function generateSlug()\n {\n $this->slug = str_slug($this->name) . '-' . $this->id;\n\n $this->save();\n }", "public function slug() {\n\t\treturn $this->createSlug($this->title);\n\t}", "private function slug_get($id)\n\t\t{\n\t\t\t$where = '@id=\"'.utf8_encode($id).'\"';\n\t\t\t$node = $this->xml->xpath('/post/friendly/url['.$where.']');\n\n\t\t\tif($node==array())\n\t\t\t\treturn false;\n\n\t\t\treturn $node[0]->getAttribute('slug');\n\t\t}", "public function getSlugKey(): string|null;", "public static function getIDFromSlug($slug) {\r\n \r\n $Database = (new AppCore)->getDatabaseConnection(); \r\n \r\n if (filter_var($slug, FILTER_VALIDATE_INT)) {\r\n return $slug; \r\n }\r\n \r\n $query = \"SELECT id FROM image_competition WHERE slug = ?\";\r\n $tempid = $Database->fetchOne($query, $slug);\r\n \r\n if (filter_var($tempid, FILTER_VALIDATE_INT)) {\r\n return $tempid;\r\n }\r\n \r\n $query = \"SELECT ID from image_competition WHERE title = ?\";\r\n return $Database->fetchOne($query, $slug);\r\n \r\n }", "public function initializeSlug(){\n if(empty($this->slug)){\n $slugify = Slugify::create();\n $this->slug = $slugify->slugify($this->title);\n }\n }", "private function createSlug() {\r\n \r\n $proposal = !empty($this->subject) ? substr(create_slug($this->subject), 0, 60) : $this->id;\r\n \r\n $result = $this->db->fetchAll(\"SELECT post_id FROM nuke_bbposts_text WHERE url_slug = ?\", $proposal); \r\n \r\n if (count($result)) {\r\n $proposal .= count($result);\r\n }\r\n \r\n $this->url_slug = $proposal;\r\n \r\n }", "public function scopeSlug($query, $id)\n {\n return $query->where('slug', $id)->first();\n }", "public function calculateSlug() {\n $this->slug = strtolower(str_replace(array(\" \", \"_\"), array(\"-\", \"-\"), $this->nombre)).rand(1, 100);\n }", "public function getSlug()\n\t{\n\t\treturn self::buildSlug();\n\t}", "function slug($object)\n {\n $id = isset($object->id)?$object->id:'';\n $title = isset($object->title)?$object->title:'';\n return str_slug($id.'-'.$title);\n }", "public function get_slug()\n {\n return $this->slug;\n }", "public static function getSlugField()\n {\n return 'slug';\n }", "public function getSlug(): string\n {\n return $this->slug;\n }", "public function initializeSlug() {\n if(empty($this->slug)) {\n $slugify = new Slugify();\n $this->slug = $slugify->slugify($this->nomhotel);\n }\n }", "public function makeslug()\n {\n echo $this->blog_articles_model->make_slug();\n }", "public function get_slug() {\n\t\treturn $this->slug;\n\t}", "public static function slug($slug);", "protected function addSlug()\n {\n $slugSource = $this->generateSlugFrom();\n\n $slug = $this->generateUniqueSlug($slugSource);\n\n $this->slug = $slug;\n }", "public function getSlugAttribute()\n {\n return new Slug($this->attributes[$this->slugField()]);\n }", "public function get_source_slug();", "function article_slug() {\n return Registry::prop('article', 'slug');\n}", "public function generateSlug()\n {\n $strategy = $this->slugStrategy();\n\n if (in_array($strategy, ['uuid', 'id'])) {\n $this->generateIdSlug();\n } elseif ($strategy != 'id') {\n $this->generateTitleSlug((array) $strategy);\n }\n }", "function gimme_an_id($slug) {\n\n\t$mytermID = get_term_by( 'name', $slug, 'category' );\n\treturn (int)$mytermID->term_id;\n}", "private function generateSlug($data) {\n\n $slug = Str::slug($data[\"title\"], '-'); // titolo-articolo-3\n\n // chiamata query al db, settiamo con la variabile existingslug il primo slug del db che non ammetterà duplicati\n $existingPost = Post::where('slug', $slug)->first();\n // dd($existingPost);\n\n // se lo slug esiste già, dobbiamo rigenerarlo. possiamo aggiungere allo slug doppione un trattino e un numero. per farlo usiamo un ciclo while che si interrompe quando la condizione di uscita viene soddisfatta\n $slugBase = $slug;\n $counter = 1;\n\n while($existingPost) {\n $slug = $slugBase . \"-\" . $counter;\n\n // istruzioni per terminare il ciclo, riverifico con una nuova query l'esistenza dello slug. Se esiste il ciclo riparte con l'incremento, se non esiste la condizione del while è falsa ed esco dal ciclo.\n $existingPost = Post::where('slug', $slug)->first(); \n // incremento \n $counter++;\n }\n\n // salvo lo slug\n return $slug;\n }", "protected function generateSlugFrom()\n {\n $slugFields = static::$slugFieldsFrom;\n\n $slugSource = collect($slugFields)\n ->map(function (string $fieldName) {\n return data_get($this, $fieldName, '');\n })\n ->implode('-');\n\n return substr($slugSource, 0, 100);\n }", "function get_english_post_id( string $slug )\n{\n\n return [\n\n\t\t'agile-framework' => 54907,\n\t\t'blog' => 16636,\n\t\t'cta-building-bricks' => 60772,\n\t\t'customer-success-metrics-continental' => 60849,\n\t\t'customer-success-metrics-dubai' => 60859,\n\t\t'customer-success-metrics-nc-state' => 60860,\n\t\t'customer-success-metrics-solomon-group' => 60847,\n\t\t'events' => 29360,\n\t\t'hero-newsroom' => 61349,\n\t\t'hero-cloud' => 61349,\n\t\t'homepage-block-ctas' => 54984,\n\t\t'homepage' => 12357, \n\t\t'insurance' => 60943,\n\t\t'logo-ticker-mx-world-2020' => 57127,\n\t\t'low-code-guide' => 59648,\n\t\t'low-code-news' => 59151,\n\t\t'makeshift' => 56033,\n\t\t'media-coverage' => 30061,\n\t\t'mendix-values' => 56025,\n\t\t'mxw-agenda' => 56708,\n\t\t'mxw-home' => 56707,\n\t\t'press-releases' => 30062,\n\t\t'you-build-with-mendix' => 60894,\n\n\t][$slug];\n}", "public function getSlug()\n {\n return $this->sSlug;\n }", "abstract public static function slug(): string;", "public function makeSlug($text)\n {\n $slugs = [];\n\n $text = $this->setEmptySlugs($text);\n\n //Bind translated slugs\n foreach ($text as $key => $value) {\n $slugs[$key] = $this->toSlug($value);\n }\n\n //Checks if some of localized slugs in database exists in other rows\n $row = $this->getConnection()->table($this->getTable())->where(function ($query) use ($slugs) {\n //Multilanguages slug\n if ($this->hasLocalizedSlug()) {\n $i = 0;\n foreach ($slugs as $key => $value) {\n if (! $value) {\n continue;\n }\n\n $query->{ $i == 0 ? 'whereRaw' : 'orWhereRaw' }('JSON_EXTRACT(slug, \"$.'.$key.'\") = ?', $value);\n $i++;\n }\n\n }\n\n //If is simple string slug\n else {\n $query->where('slug', $slugs[0]);\n }\n })->limit(1);\n\n //If models exists, then skip slug owner\n if ($this->exists) {\n $row->where($this->getKeyName(), '!=', $this->getKey());\n }\n\n $row = $row->get(['slug']);\n\n //If new slugs does not exists, then return new generated slug\n if ($row->count() == 0) {\n return $this->castSlug(array_filter($slugs, function($item){\n return $this->isValidSlug($item);\n }));\n }\n\n //Generate new unique slug with increment\n $unique_slug = $this->makeUnique($slugs, $row->first()->slug);\n\n //If slug exists, then generate unique slug\n return $this->castSlug($unique_slug);\n }", "protected function refreshSlug() {\n $slug = $this->slugify($this->getTitle());\n $this->setSlug($slug);\n }", "public function getCanonicalSlug()\n {\n return $this\n ->hasOne(Slug::class, ['id' => 'canonicalSlugId']);\n }", "public function initializeSlug()\n {\n if (empty($this->slug)) {\n\n $slugify = new Slugify();\n $this->slug = $slugify->slugify($this->firstName . ' ' . $this->lastName);\n }\n }", "protected function slugField()\n {\n return 'slug';\n }", "public function initializeSlug()\n {\n if (empty($this->slug)) {\n $slugify = new Slugify();\n $this->slug = $slugify->slugify($this->name);\n }\n }", "public function showPostBySlug($slug)\n{\n \n $sql = \"SELECT p.ID, p.media_id, p.post_author,\n p.post_date, p.post_modified, p.post_title,\n p.post_slug, p.post_content, p.post_summary, \n p.post_keyword, p.post_tags,\n p.post_status, p.post_type, p.comment_status, u.user_login\n FROM tbl_posts AS p\n INNER JOIN tbl_users AS u ON p.post_author = u.ID\n WHERE p.post_slug = :slug AND p.post_type = 'blog'\";\n\n $this->setSQL($sql);\n\n $postBySlug = $this->findRow([':slug' => $slug]);\n\n return (empty($postBySlug)) ?: $postBySlug;\n \n}", "function _acf_apply_unique_field_slug($slug, $post_ID, $post_status, $post_type, $post_parent, $original_slug)\n{\n}", "public function createSlug()\n {\n $slug = new Slugify();\n $this->slug = $slug->slugify($this->title);\n }", "protected function getSlug(){\n $this->Name = UrlUtils::getSlug($this->FriendlyName);\n return $this->Name;\n }", "public function getSlug(ContentfulEntry $contentfulEntry): string;", "public function makeSlug () {\n\t\tif(empty($this->slug)) {\n\t\t\t$this->slug = UTF8::slugify($this->name);\n\t\t}\n\t\treturn $this->slug;\n\t}", "public function initializeSlug()\n {\n if (empty($this->slug)) {\n $slugify = new Slugify();\n $this->slug = $slugify->slugify($this->titre);\n }\n }", "public function slug()\n\t{\n\t\treturn $this->slug;\n\t}", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->slug;\n }", "public function getSlug()\n {\n return $this->provider .'-'. str_replace('_', '-', $this->postId);\n }", "function get_the_slug( $id=null ){\n if( empty($id) ):\n global $post;\n if( empty($post) )\n return ''; // No global $post var available.\n $id = $post->ID;\n endif;\n $slug = basename( get_permalink($id) );\n return $slug;\n}", "public function getBySlug(string $slug);", "public function getSlug()\n {\n return $this->__get(self::FIELD_SLUG);\n }", "public function findBySlug(string $slug);", "public function findBySlug(string $slug);", "public function getByIdOrSlug($id, $data = null)\n {\n $data = $this->includeEverything($data);\n return parent::getById($id, $data);\n }", "public function generateIdSlug()\n {\n $slug = Slug::fromId($this->getKey() ?? rand());\n\n // Ensure slug is unique (since the fromId() algorithm doesn't produce unique slugs)\n $attempts = 10;\n while ($this->isExistingSlug($slug)) {\n if ($attempts <= 0) {\n throw new UnableToCreateSlugException(\n \"Unable to find unique slug for record '{$this->getKey()}', tried 10 times...\"\n );\n }\n\n $slug = Slug::random();\n $attempts--;\n }\n\n $this->setSlugValue($slug);\n }", "public function modelSlug($model);", "public function getSlugSourceColumn()\n {\n return 'title';\n }", "protected function getSlug($slug_data){\n return str_replace(' ', '-', $slug_data);\n }", "public function slugs();", "public function getSlug()\n\t{\n\t\treturn $this->slug;\n\t}", "public function getSlug()\n\t{\n\t\treturn $this->slug;\n\t}", "public function getSlug()\n\t{\n\t\treturn $this->slug;\n\t}", "public function getRouteKey()\n {\n \t$this->slug;\n }", "public function getIdentityField() \n {\n return self::FIELD_SLUG;\n }", "public function getTypeSlugByID ($id_type = '') {\n $this->connection->where('id_type', $id_type);\n $result = $this->connection->select('slug', 'types');\n\n if ($result && $result->num_rows > 0) {\n while ($row = $result->fetch_assoc()) {\n return $row['slug'];\n }\n }\n else {\n return NULL;\n }\n }", "public function getSlug()\n {\n if ($this->hasLocalizedSlug()) {\n //Cast model slug to propert type\n $slug = $this->getValue('slug');\n $slug = is_array($slug) ? $slug : (array) json_decode($slug);\n\n $lang = Localization::get();\n\n //Return selected language slug\n if (array_key_exists($lang->slug, $slug) && $slug[$lang->slug]) {\n return $slug[$lang->slug];\n }\n\n $default = Localization::getFirstLanguage();\n\n //Return default slug value\n if ($default->getKey() != $lang->getKey() && array_key_exists($default->slug, $slug) && $slug[$default->slug]) {\n return $slug[$default->slug];\n }\n\n //Return one of set slug from any language\n foreach (Localization::getLanguages() as $lang) {\n if (array_key_exists($lang->slug, $slug) && $slug[$lang->slug]) {\n return $slug[$lang->slug];\n }\n }\n\n //If languages has been hidden, and no slug has been defined from any known language\n //we can return any existing\n return array_values($slug)[0] ?? null;\n }\n\n return $this->slug;\n }", "private function slug_add($id, $slug)\n\t\t{\n\t\t\treturn $this->xml->friendly->addGodChild('url', array('id'=>$id, 'slug'=>$slug));\n\t\t}" ]
[ "0.7202142", "0.71720445", "0.709589", "0.70832187", "0.6857748", "0.68518704", "0.68518704", "0.684782", "0.6822132", "0.6769565", "0.6769565", "0.6769565", "0.6769565", "0.6730011", "0.6719865", "0.6703005", "0.65604615", "0.6531188", "0.6528298", "0.6528233", "0.65169084", "0.6516474", "0.6486785", "0.64761347", "0.6473422", "0.6443316", "0.6435961", "0.6422377", "0.6421352", "0.64202857", "0.6414498", "0.63964134", "0.6389194", "0.6340717", "0.6334253", "0.6319505", "0.6292861", "0.6282954", "0.6277066", "0.62727696", "0.62608767", "0.62281305", "0.62148535", "0.6206834", "0.6203868", "0.6196696", "0.61913234", "0.61771965", "0.6161836", "0.6158498", "0.6155931", "0.61401486", "0.6138839", "0.6137583", "0.6133388", "0.61265016", "0.6116633", "0.6108504", "0.61026365", "0.609952", "0.60994303", "0.60891473", "0.60748637", "0.6065257", "0.60651916", "0.60595125", "0.60428923", "0.6036043", "0.6029378", "0.60214996", "0.60189825", "0.60186744", "0.6009088", "0.60025316", "0.6002195", "0.60020775", "0.60020775", "0.60020775", "0.60020775", "0.60020775", "0.60020775", "0.5998841", "0.5997735", "0.5988948", "0.59758794", "0.5961934", "0.5961934", "0.5956755", "0.5954916", "0.59503573", "0.59459794", "0.5938788", "0.59381914", "0.5931315", "0.5931315", "0.5931315", "0.5924044", "0.59222496", "0.59025973", "0.5901434", "0.58938205" ]
0.0
-1
A user has many posts
public function post(){ return $this->hasMany(Post::class); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function posts(){\n // get all the posts by this user\n return $this->hasMany('cms\\Post');\n }", "public function posts()\n {\n return $this->hasManyThrough(Post::class, User::class);\n }", "public function posts() {\n return $this->hasMany('App\\Post','user_id', 'id');\n }", "public function posts(){\n // Will go the posts table and get all posts that have the user ud in a column named `user_id`\n // This will also work: `$this->hasMany('App\\Post', 'user_id');`\n return $this->hasMany('App\\Post');\n }", "public function posts() {\n // LARAVEL IS AUTOMATICALLY LOOKING FOR COUNTRY ID\n return $this->hasManyThrough('App\\Post', 'App\\User');\n }", "public function posts()\n\t{\n\t\t// drugi argument stupac u bazi preko kojeg radimo relaciju\n\t\treturn $this->hasMany(static::$postModel, 'user_id');\n\t}", "public function getPosts()\n {\n return $this->hasMany(Post::class, ['author_id' => 'id'])->inverseOf('user');\n }", "public function posts()\n {\n \treturn $this->hasMany(Post::class);\n \t//Con esto podemos acceder a todos los posts de un usuario\n \t//$posts = User::find(1)->comments()->where()->first()\n \t//Para acceder al usuario de un post debemos definir la relacion inversa\n }", "public function getPosts()\n {\n return $this->hasMany(Post::className(), ['usuario_id' => 'id'])->inverseOf('usuario');\n }", "public function posts()\n {\n //hasMany(Modelo a comparar) ira a buscar todos los post que concuerden con el id del usuario en la tabla posts\n return $this->hasMany('App\\Models\\Post', 'user_id', 'id');\n\n //return $this->hasMany('Modelo a cruzar con el actual', 'llave foranea a comprar', 'llave del modelo actual');\n }", "public function posts()\n {\n return $this->hasMany(Post::class, 'created_by');\n }", "public function posts() {\n return $this->hasMany('Marcosricardoss\\Restful\\Model\\Post', 'created_by');\n }", "public function posts()\n {\n return $this->hasMany('App\\Post', 'author_id', 'id');\n }", "public function posts()\n {\n return $this->hasMany(Post::class, 'owner_id');\n }", "public function posts()\n {\n return $this->hasMany(Models\\Post::class, 'account_id');\n }", "public function authored_posts() {\n return $this->hasMany(Post::class, 'user_id');\n }", "public function posts()\n {\n return $this->hasMany(Post::class, 'post_author');\n }", "public function posts() {\n return $this->hasMany('App\\Post');\n }", "public function posts() {\n return $this->hasMany('App\\Post');\n }", "public function posts(){\n\t\treturn $this->hasMany('Post');\n\t}", "public function posts() {\n return $this->hasMany('App\\Post');\n }", "public function posts()\n {\n return $this->hasMany(ExamplePost::class, 'author_id');\n }", "public function posts()\n {\n return $this->hasMany('App\\Post');\n }", "public function posts()\n {\n return $this->hasMany('App\\Post');\n }", "public function posts()\n {\n return $this->hasMany('App\\Post');\n }", "public function posts(){\n return $this->hasMany('App\\Models\\Post');\n }", "public function posts()\n {\n return $this->hasMany('App\\Models\\Post');\n }", "public function posts()\n {\n return $this->hasMany('App\\Models\\Post');\n }", "public function textPosts()\n {\n return $this->hasMany('App\\TextPost', 'user-id');\n }", "public function post() {\n\t\treturn $this->hasMany(Post::class);\n\t}", "public function posts()\n\t{\n\t\treturn $this->hasMany('App\\Post');\n\t}", "public function posts()\n\t{\n\t\treturn $this->hasMany('Post');\n\t}", "public function posts(){\n return $this->hasMany('App\\Posts');\n }", "public function posts() {\n return $this->hasMany(Post::class);\n }", "public function posts(){\n return $this->hasMany(Post::class);\n }", "public function posts(){\n return $this->hasMany(Post::class);\n }", "public function post(){\n return $this->hasMany('App\\Post');\n }", "public function videoPosts()\n {\n return $this->hasMany('App\\VideoPost', 'user-id');\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function posts()\n {\n return $this->hasMany(Post::class);\n }", "public function post(){\n // will go to post table and look for user_id automatically if want to specify different column then can specify as a second param in hasOne\n // get post by this user\n return $this->hasOne('cms\\Post');\n }", "public function post(){\n return $this->hasMany(Post::class);\n \n }", "public function posts()\n {\n return $this->hasMany(\\App\\Models\\Post::class);\n }", "public function posts(): Relation\n {\n return $this->hasMany(Post::class, 'post_author');\n }", "public function posts()\n {\n return $this->belongsToMany('App\\Post');\n }", "public function posts()\n {\n return $this->belongsToMany('App\\Post');\n }", "public function posts()\n {\n return $this->belongsToMany('App\\Post');\n }", "public function posts()\n {\n return $this->belongsToMany('App\\Post');\n }", "public function getAllPostWithUserId(){\n $query = Post::orderBy('id','desc')->with('user')->paginate(5);\n return $query;\n }", "public function posts(): HasMany // return type as of php 7.1 - use it!\n {\n return $this->hasMany(Post::class, 'author_id'); // foreign key naming specified here, because Post wants to have this rather than default 'user_id'; MUST ALLWAYS DO THIS ON 'BOTH SIDES'\n }", "public function posts()\n {\n return $this->belongsToMany('Modules\\Meeting\\Entities\\Post')->withTimestamps();\n }", "function get_all_user_posts(){\n\treturn query(\"SELECT * FROM posts WHERE user_id = \".loggedInUserId().\"\");\n}", "public function posts()\n {\n return $this\n ->hasMany('App\\Post', 'artist')\n ->selectRaw('*, name as author')\n ->join('users', 'users.id', '=', 'posts.author')\n ->orderBy('posts.created_at', 'desc');\n }", "public function run()\n {\n $user = \\App\\User::first();\n\n $user->posts()->saveMany(factory(App\\Post::class, 50)->make());\n }", "public function posts(){\n return $this->hasMany('App\\Post');\n // $this->hasMany(Post::class)\n }", "public function posts()\n {\n return $this->belongsToMany(Post::class);\n }", "public function posts()\n {\n return $this->belongsToMany(Post::class);\n }", "public function posts()\n {\n return $this->belongsToMany(Post::class);\n }", "public function posts()\n\t{\n\t\treturn $this->hasMany('App\\GroupPost');\n\t}", "public function posts(User $user)\n {\n return $user->posts()->with('user')\n ->latest()\n ->simplePaginate(30);\n }", "public function countUserPosts(){\n\n return $this->getModel()->where('user_id', '=', Auth::id())->count();\n }", "public function posts(){\n // Note that Post::class == string 'App\\Post'\n\n #? When this is called as a property, not a method, Laravel will know to 'eager-load' the relationship\n return $this->hasMany(Post::class);\n\n }", "function getPostOfUser($idUser)\n {\n }", "public function posts(){\n // A single category has many posts\n return $this->hasMany('App\\models\\post');\n }", "public function getRelatedPosts() {}", "public function post()\n {\n return $this->hasMany('App\\Models\\Blog\\PostModel', 'category_id', 'category_id');\n }", "public function posts()\n\t{\n\t\t//return $this->hasMany('Post', 'tags');\n\t\treturn $this->belongsToMany('Post');\n\t}", "public function posts()\n {\n return $this->hasMany('Lwv\\NewsModule\\Post\\PostModel', 'category_id');\n }", "public function posts() {\n\t\treturn $this->belongsToMany('Post', 'posts_medias', 'media_id', 'post_id');\n\t}", "public function posts()\n {\n \treturn $this->morphedByMany(Post::class, 'videoable');\n }", "private function getUserPosts($user)\n {\n $this->db->select('*');\n $this->db->from('Post');\n $this->db->where('creatorEmail', $this->session->userdata('email'));\n $query = $this->db->get();\n\n $allUserRelatedPostResults = $query->result();\n\n $homePosts = array();\n\n if ($query->num_rows() > 0) {\n foreach ($allUserRelatedPostResults as $post) {\n $postObj = new Post();\n // Each post result is represented by a Post object\n $postObj->setPostId($post->postId);\n $postObj->setPostContent($post->postContent);\n $postObj->setCreatorEmail($post->creatorEmail);\n $postObj->setPostTimeStamp($post->postTimestamp);\n $postObj->setCreatorId($user->getUserId());\n $postObj->setCreatorFirstName($user->getFirstName());\n $postObj->setCreatorLastName($user->getLastName());\n $postObj->setCreatorProfilePicture($user->getProfilePicture());\n\n array_push($homePosts, $postObj);\n }\n }\n\n return $this->getFollowingUserEmails($homePosts, $user);\n }", "public function posts() {\n return $this->belongsTo('Post','post_id');\n }", "public function highschoolProfilePosts()\n\t{\n\t\treturn $this->morphMany('Post', 'postable');\n\t}", "public function user_posts($id)\n {\n $posts = Posts::where('author_id',$id)->where('active',1)->orderBy('created_at','desc')->paginate(5);\n $title = User::find($id)->name;\n\n return view('home')->withPosts($posts)->withTitle($title);\n }", "function get_all_user_posts(){\n return query(\"SELECT * FROM posts WHERE user_id = '\" . loggedInUserId() .\"'\");\n}", "public function posts()\n {\n return $this->hasMany(Post::class, 'category_id');\n }", "public function posts()\n {\n return $this->hasMany('Efed\\Models\\ForumPost', 'topic_id', 'id');\n }", "public function user_post() {\n $this->loadModel('Image');\n $id = $this->Auth->user('id');\n $this->layout = 'front_end';\n $allImage = $this->Image->getAllimage($id);\n $data = $this->User->userData($id);\n $this->loadModel('Post');\n $post = $this->Post->postList();\n $this->set('image', $allImage);\n $this->set('user', $data);\n $this->set('post', $post);\n $this->render('/Users/user_post');\n }", "public function posts()\n {\n return $this->belongsToMany('App\\Post', 'tags_posts', 'tag_id', 'post_id');\n }", "public function getPosts()\n {\n return $this->hasMany(Post::className(), ['category_id' => 'id']);\n }", "public function posts(){\n return $this->belongsToMany('Post', 'post_tag', 'tag_id', 'post_id');\n }", "public function posts(){\n\t\treturn $this->belongsToMany('Post', 'topics_posts');\n\t}", "public function posts()\n {\n return $this->morphedByMany(App\\Post::class, 'mediable');\n }", "public function get_user_posts($user_id){\n\t\t$this->db->order_by('posts.id', 'DESC');\n\t\t$this->db->where('posts.user_id', $user_id);\n\t\t$this->db->join('categories', 'categories.id = posts.category_id');\n\t\t$query = $this->db->get('posts');\n\t\treturn $query->result_array();\n\t}", "public function create(User $user, Post $post);", "public function posts()\n {\n return $this->morphedByMany(\n Post::class,\n 'metable',\n 'metables',\n 'meta_id',\n );\n }", "public function posts() {\n return $this->belongsTo('Post','likes')\n ->withTimestamps();\n }", "public function post()\n {\n return $this->hasOne('App\\post');\n }", "public function posts()\n {;\n return post::with('user','like','comment')->orderBy('created_at','DESC')->take(4)->get();\n }", "public function getPosts()\n {\n return $this->hasMany(Post::class, ['fk_thread' => 'id'])->orderBy('id ASC');\n }", "public function listPostsAction() {\n $this->session->start();\n if ($this->session->get('user_id') != NULL) {\n $vars = $this->getUserLoggedInformation();\n $user = Users::findFirstByUser_id($this->session->get('user_id'));\n if ($user->user_type_id < 3) {\n $posts = Posts::find(array(\n \"order\" => \"post_date_posted DESC\"\n ));\n }\n elseif ($user->user_type_id == 3) {\n $usr = Users::find(array(\n \"conditions\" => \"user_type_id > :user_type_id: OR user_id = :user_id: \",\n \"bind\" => array(\n \"user_type_id\" => $user->user_type_id,\n \"user_id\" => $user->user_id\n )\n ));\n foreach ($usr as $u) {\n $arr_id_users[] = $u->user_id;\n }\n $string_users = implode(\",\", $arr_id_users);\n $posts = Posts::find(array(\n \"conditions\" => \"post_author IN ({$string_users})\",\n \"order\" => \"post_date_posted DESC\"\n ));\n }\n else {\n $posts = Posts::findByPost_author($user->user_id);\n }\n $vars['menus'] = $this->getSideBarMenus();\n $vars['posts'] = $posts;\n $vars['categories'] = $this->getCategoriesByPost($posts);\n\n $this->view->setVars($vars);\n $this->view->render(\"post\", \"listPosts\");\n }\n else {\n $this->response->redirect(URL_PROJECT . 'admin');\n }\n }", "public function my_post()\n {\n// $post = $this->postModel->getPostById($id);\n//\n// if($post->user_id != $_SESSION['user_id']) {\n// redirect('posts');\n// }\n\n $userPosts = $this->postModel->postByUser($_SESSION['user_id']);\n\n $data = [\n 'userPosts' => $userPosts\n ];\n\n $this->view('posts/user_posts', $data);\n }", "public function likes()\n {\n return $this->hasMany('Model\\PostLike');\n }", "public function post()\n {\n \treturn $this->belongsTo(\"Models\\Post\", \"post_id\", \"id\");\n }" ]
[ "0.8116754", "0.80539685", "0.7954885", "0.76771873", "0.75815684", "0.75721455", "0.75676996", "0.747593", "0.732506", "0.72226685", "0.7189527", "0.7095446", "0.706392", "0.70137566", "0.70118207", "0.6997965", "0.69483495", "0.69158614", "0.6900541", "0.6861167", "0.68322206", "0.68168986", "0.681046", "0.681046", "0.681046", "0.6802327", "0.67918956", "0.67918956", "0.67807853", "0.6777381", "0.67705995", "0.67516744", "0.6750383", "0.67464656", "0.6710939", "0.6710939", "0.66898507", "0.6687899", "0.6679889", "0.6679889", "0.6679889", "0.6679889", "0.6679889", "0.6679889", "0.6679889", "0.6679889", "0.6676306", "0.6660323", "0.65899104", "0.65727824", "0.65344507", "0.65344507", "0.65344507", "0.65344507", "0.65325123", "0.6521194", "0.6504147", "0.6497428", "0.64494", "0.6445215", "0.6441492", "0.6424525", "0.6424525", "0.6424525", "0.64205235", "0.64103574", "0.638342", "0.63538903", "0.63502854", "0.63292974", "0.6320117", "0.6319047", "0.6313048", "0.62772423", "0.6262495", "0.622506", "0.61991256", "0.61904615", "0.618395", "0.6180667", "0.6147726", "0.6143621", "0.61044925", "0.6093008", "0.60893816", "0.60847086", "0.608297", "0.60789895", "0.6078811", "0.6066608", "0.6057698", "0.60458356", "0.60385185", "0.60382545", "0.6034191", "0.60245234", "0.6018221", "0.6009384", "0.6002742", "0.6000522" ]
0.6641424
48
A user has many comments
public function comment(){ return $this->hasMany(Comment::class); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function comments() {\n return $this->hasMany(Comment::class); // this (User) has many instances of the Comment\n }", "public function comment()\n {\n return $this->hasMany('Modules\\Comment\\Model\\Comment','user_id');\n }", "public function comments(){\n return $this->hasMany(Comment::class, \"authenticatedUser_id\");\n }", "public function comment(){\n return $this->hasMany(User::class);\n }", "public function comments() {\n return $this->hasMany('\\Veer\\Models\\Comment', 'users_id');\n }", "public function comments(): Relation\n {\n return $this->hasMany(Comment::class, 'user_id');\n }", "public function comments()\n {\n return $this->hasMany(ExampleComment::class, 'from_user');\n }", "public function comments() \n {\n \treturn $this->hasMany('App\\Comment');\n }", "public function comments() {\n\t\t// hasMany(RelatedModel, foreignKeyOnRelatedModel = image_id, localKey = id)\n\t\treturn $this->hasMany('App\\Comment')->with('user')->orderBy('id', 'desc');\n\t}", "public function comments()\n {\n return $this->hasMany('App\\Comment', 'author_id', 'id');\n }", "public function comments(){\n \treturn $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments() {\n return $this->hasMany('App\\Comment');\n }", "public function comments() {\n return $this->hasMany('App\\Comment');\n }", "public function comments(){\n return $this->hasMany('Corp\\Models\\Comment');\n }", "public function comments()\n\t{\n\t\treturn $this->hasMany('Comment');\n\t}", "public function comments()\n\t{\n\t\treturn $this->hasMany('Comment');\n\t}", "public function comments()\n\t{\n\t\treturn $this->hasMany('Comment');\n\t}", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n \treturn $this->hasMany(Comment::class);\n }", "public function comments()\n {\n // check if user is already loaded, if not, we fetch it from database\n if ($this->_comments) {\n return $this->_comments;\n } else {\n $comments = new Application_Model_DbTable_Comments();\n\n foreach ($comments->findAllBy('post_id', $this->_id) as $comment) {\n $this->_comments[] = $comment ;\n }\n return $this->_comments;\n }\n }", "public function comments()\n {\n return $this->hasMany('App\\Models\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Models\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Models\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Models\\Comment');\n }", "public function comment()\n {\n \treturn $this->hasMany('App\\Model\\Comment');\n }", "public function comments(){\n return $this->hasMany(Comment::class);\n }", "public function comment(){\n return $this->hasMany('App\\Comment');\n }", "public function comments() {\n return $this->hasMany(Comment::class);\n }", "public function getComments()\n {\n return $this->hasMany(Comment::class, ['created_by' => 'id']);\n }", "public function comment()\n {\n return $this->hasMany('App\\Comment');\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany(Comment::class);\n }", "public function comment()\n {\n return $this->hasMany('App\\Models\\Comment');\n }", "public function comments()\n {\n return $this->hasMany('App\\Comment', 'id_comment', 'id');\n }", "public function comments()\n {\n return $this->hasMany('VideoBlog\\Comment');\n }", "public function Comments() {\n return $this->hasMany(Comment::class);\n }", "public function comments() {\n\n\t\treturn $this->hasMany(Comment::class);\n\t}", "public function comments()\n {\n return $this->hasMany('App\\NoteComment');\n }", "public function comments(): HasMany\n {\n return $this->hasMany(Comment::class);\n }", "public function comments(): HasMany\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany('App\\Forum_Models\\Comment');\n }", "public function comments()\n {\n return $this->hasMany(PhotoComment::class);\n }", "public function comment()\n {\n return $this->hasMany(Comment::class);\n }", "public function comments()\n {\n return $this->hasMany('Model\\PostComment');\n }", "public function comments()\n {\n return $this->hasMany(Comment::class, 'subject_id', 'id')->where('comments.subject_type', Wiki::class)->with(['user', 'likes']);\n }", "public function comments() {\n return $this->hasMany('App\\Models\\Comment', 'post_id');\n }", "public function comments()\n\t{\n\t\treturn $this->has_many('comment');\n\t}", "public function testUserCommentsMethod()\n {\n $user = factory(User::class)->create();\n $user->comments()->save(factory(Comment::class)->create());\n\n $this->assertDatabaseHas('comments', [\n 'user_id' => $user->id,\n ]);\n }", "public function comments()\n {\n \treturn $this->hasMany(Comment::class, 'article_id');\n }", "public function comments(){\n return $this->morphMany(Comment::class, 'commentable');\n }", "public function comments(){\n return $this->hasMany('App\\Models\\Comments', 'article_id');\n }", "public function getUserCommentsAttribute()\n {\n return $this->commentsByType('user')\n ->get();\n }", "public function comments()\n {\n return $this->hasMany(Comment::class, 'post_id');\n }", "public function allComments() {\n\t\treturn $this->hasMany('NGiraud\\News\\Models\\Comment');\n\t}", "public function comments()\n {\n return $this->hasMany(CitationComment::class);\n }", "public function comment()\n {\n \treturn $this->hasMany('App\\Comment','idTinTuc','id');\n }", "public function comments(){\n\t\t// Comment, 'foreign_key', 'local_key'\n\t\treturn $this->hasMany(Comment::class, 'post_id', 'id');\n\t}", "public function commentor()\n {\n return $this->belongsTo(get_class(Base::user()), 'user_id', 'id');\n }", "function comments()\n {\n return $this->morphMany('App\\Comments', 'commentable');\n }", "public function getUserComments($userId) {\n\n\t\t$sql = \"SELECT comment_id, comment_text FROM comments\n\t\t\t\t WHERE comment_author = ?\";\n\t\t$data = [$userId];\n\t\t//create stdStatemment object | call to Model method from core/Database.php\n\t\treturn $this->setStatement($sql,$data);\n\t}", "public function comments() {\n\t\treturn $this->hasMany('NGiraud\\News\\Models\\Comment')->where('parent_id', 0)->orderBy('updated_at', 'desc');\n\t}", "public function comments(): HasMany\n {\n return $this->posts()\n ->where('is_private', false)\n ->whereNull('hidden_at')\n ->where('type', 'comment');\n }", "public function comments()\n {\n return $this->hasMany(Comment::class)->dernier();\n }", "public function getCommentators()\n {\n return $users = User::select('users.*')\n ->distinct()\n ->join('comments', 'comments.user_id', '=', 'users.id')\n ->where('comments.image_id', $this->id)\n ->get();\n }", "public function comments()\n {\n return $this->belongsToMany('App\\Comments')->withTimestamps();\n }", "public function getComentarios()\n {\n return $this->hasMany(CommentModel::className(), ['createdBy' => 'id'])->inverseOf('usuario');\n }", "public function comments(){\n // Note that Comment::class == string 'App\\Comment'\n\n #? When this is called as a property, not a method, Laravel will know to 'eager-load' the relationship\n return $this->hasMany(Comment::class);\n\n }", "public function getComments() {\n return $this->hasMany(Comment::class, ['post_id' => 'id']);\n }", "public function getComments() \n {\n return $this->hasMany(Comment::className(), [\n 'post_id' => 'id',\n ]);\n }", "public function getUserComments(): array {\n $query = \"SELECT * \n FROM Comments \n WHERE toUserID = :userID OR fromUserID = :userID\";\n \n $stmt = $this->_db->prepare ( $query );\n $stmt->bindValue ( ':userID', $this->_userID );\n $stmt->execute ();\n $objects = [];\n while ( $row = $stmt->fetch ( PDO::FETCH_ASSOC ) ) {\n $comment = new Comment ( $this->_db );\n $comment->commentID = $row ['commentID'];\n $comment->get();\n $objects [] = $comment;\n }\n \n return $objects;\n }", "public function getUserPostComment($user_id)\n {\n return Comment::find()->with('user')->with('post')->where(['user_id' => $user_id,'status' => '1','parent_comment_id'=>'0'])->orderBy(['created_date'=>SORT_DESC])->all();\n \n }", "public function comments()\n {\n return $this->morphMany('App\\Comment', 'commentable');\n }", "public function comments()\n {\n return $this->morphMany('App\\Comment', 'commentable');\n }", "public function comments()\n {\n return $this->morphMany('App\\Comment', 'commentable');\n }", "public function comments2(){\n\t\treturn $this->hasManyThrough('Comment', 'BlogPost', 'posted_by_id', 'blog_post_id');\n\t}", "public function comments()\n {\n return $this->morphToMany(Comment::class, 'commentable', 'commentable');\n }", "public function getUserComments($userId) {\n $result = $this->WIdb->select(\n \"SELECT * FROM `WI_comments` WHERE `posted_by` = :id\",\n array (\"id\" => $userId)\n );\n\n return $result;\n }", "public function comments(){\n return $this->hasMany('App\\TextPostComment', 'post_id');\n }", "public function comments()\n {\n return $this->morphedByMany('App\\Comment', 'likeable');\n }", "public function comments() {\n return $this->morphMany(Comment::class,'commentable', 'parent_type', 'parent_id')->orderBy('created_at', 'ASC');\n }", "public function comments()\n {\n return $this->morphToMany(Comment::class, 'commentable');\n }", "public function comments()\n {\n return $this->morphMany(Comment::class, 'commentable');\n }", "public function comments()\n {\n return $this->morphMany(Comment::class, 'commentable');\n }" ]
[ "0.77945316", "0.7709733", "0.7692938", "0.7630128", "0.761769", "0.7514656", "0.74429554", "0.7206785", "0.7193547", "0.7144631", "0.71420354", "0.71198976", "0.71171296", "0.71093804", "0.7096177", "0.70413965", "0.70413965", "0.70413965", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.7040707", "0.70112365", "0.6976385", "0.6958482", "0.6958482", "0.6958482", "0.6958482", "0.69404787", "0.69356906", "0.690679", "0.687977", "0.6869002", "0.6859498", "0.685354", "0.685354", "0.685354", "0.685354", "0.685354", "0.685354", "0.685354", "0.685354", "0.6817078", "0.6815205", "0.6780659", "0.6767783", "0.67672426", "0.6754577", "0.67338854", "0.67338854", "0.67285955", "0.67056304", "0.6701214", "0.6667827", "0.6583919", "0.6582654", "0.65600425", "0.65363115", "0.65170044", "0.65015155", "0.64993185", "0.64849436", "0.6482552", "0.6481937", "0.6471224", "0.64405656", "0.64389974", "0.64356667", "0.6405604", "0.6390802", "0.63821036", "0.6374565", "0.6366107", "0.63374025", "0.63347137", "0.63208205", "0.6319659", "0.631838", "0.62994194", "0.62985504", "0.62895805", "0.6280658", "0.6280658", "0.6280658", "0.62551063", "0.62211365", "0.6217439", "0.6212729", "0.62094593", "0.62000203", "0.6198928", "0.6196914", "0.6196914" ]
0.6748788
55
A user has many sign in IP's
public function ip(){ return $this->hasMany(Ip::class); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function beLoginLinkIPList() {}", "public function isUserIPAddressAllowedAccess()\n\t{\n\t\ttry\n {\n $IpBin = new IpBin();\n return $IpBin->isUserIPAddressAllowedAccess($this->getSiteUser()->getId());\n }\n catch(\\Whoops\\Example\\Exception $e)\n {\n Log::error(\"Could not check if ip address is allowed access for user [\" . $this->getSiteUser()->getId() . \"]. \" . $e);\n return FALSE;\n }\n\t}", "public function getModelIps(){\n\t\treturn $this->hasMany(Ip::className(), ['subnet' => 'id']);\n\t}", "public function addwhitelistip() \n\t{\n\t\tUserModel::authentication();\n\t\t\n\t\tSecurityModel::add_ip_whitelist();\n }", "function user_log_allowed($ip_address) {\n\n\t\t//invalid ip address\n\t\tif (!filter_var($ip_address, FILTER_VALIDATE_IP)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t//check to see if the address was authenticated successfully\n\t\t$sql = \"select count(user_log_uuid) \";\n\t\t$sql .= \"from v_user_logs \";\n\t\t$sql .= \"where remote_address = :remote_address \";\n\t\t$sql .= \"and result = 'success' \";\n\t\t$sql .= \"and timestamp > NOW() - INTERVAL '8 days' \";\n\t\t$parameters['remote_address'] = $ip_address; \n\t\t$database = new database;\n\t\t$user_log_count = $database->select($sql, $parameters, 'column');\n\t\tunset($database);\n\n\t\t//debug info\n\t\tif ($debug) {\n\t\t\techo \"address \".$ip_address.\" count \".$user_log_count.\"\\n\";\n\t\t}\n\n\t\t//default authorized to false\n\t\t$allowed = false;\n\n\t\t//use the ip address to get the authorized nodes\n\t\tif ($user_log_count > 0) {\n\t\t\t$allowed = true;\n\t\t}\n\n\t\t//return\n\t\treturn $allowed;\n\t}", "public function GetIp()\n {\t\n\t$q = Doctrine_Query::create()\n\t\t\t\t\t\t->select('*')\n\t\t\t\t\t\t->from('Users')\n\t\t\t\t\t\t->where('id = ?',$this->getUser()->getId());\n\t$result =$q->FetchOne();\n\treturn $result->getUserIp();\n }", "static function isUserIPInList($ipAddress){\n\t\t//IP list of specific anonymous users\n\t\t$ini = eZINI::instance('ssoip.ini');\n \t$ipList = $ini->variable('AuthSettings', 'IP');\n \t if ( $ipAddress && is_array( $ipList ) ){\n\t\t\t//If IP address of current user exists and IP list available\n \t\tforeach( $ipList as $itemToMatch => $id ){\n \t\tif ( ip_in_range($ipAddress, $itemToMatch) ){\n \t\t\treturn $id;\n \t\t}\n \t}\n }\n\t\t//Current user not identified as specific anonymous user\n \treturn false;\n \t}", "public function get_all_hotspot_user(){\n return $this->query('/ip/hotspot/user/getall');\n }", "function getIPs() {\r\n $ip = $_SERVER[\"REMOTE_ADDR\"];\r\n if (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) {\r\n \t$ip .= '_'.$_SERVER['HTTP_X_FORWARDED_FOR'];\r\n }\r\n if (isset($_SERVER['HTTP_CLIENT_IP'])) {\r\n \t$ip .= '_'.$_SERVER['HTTP_CLIENT_IP'];\r\n }\r\n return $ip;\r\n}", "public static function bootUserIp()\n {\n static::updating(function ($model) {\n $model->user_ip = \\Request::ip();\n });\n\n static::creating(function ($model) {\n $model->user_ip = \\Request::ip();\n }); \n }", "public static function ipLoginAttempts($ip = null)\r\n {\r\n if (!filter_var($ip, FILTER_VALIDATE_IP)) {\r\n $ip = Help::getIp();\r\n }\r\n $return = App::$db->\r\n create('SELECT count(user_id) as attempts FROM user_logs WHERE ip = :ip AND `timestamp` > :timenow AND `action` = :action AND `what` = :what')->\r\n bind($ip, 'ip')->\r\n bind(time() - 1200, 'timenow')->\r\n bind('FAILLOGIN', 'action')->\r\n bind('A', 'what')->\r\n execute();\r\n\r\n return $return[0]['attempts'];\r\n }", "function handleSSOLogin()\n {\n\t\tif (isset($_SERVER['HTTP_X_FORWARDED_FOR'])){\n \t\t\t$ipAddress = $_SERVER['HTTP_X_FORWARDED_FOR'];\n\t\t}else{\n \t\t\t$ipAddress = $_SERVER['REMOTE_ADDR'];\n\t\t}\n\t\t$pos = strripos( $ipAddress, ',');\n\t\tif ($pos === false) {\n \t\t\t//nothing to do\t\n\t\t}else{\n\t\t\t$ipAddress=trim(str_replace(\",\",\"\",strrchr($ipAddress,\",\")));\n\t\t}\n\t\t$id = self::isUserIPInList($ipAddress);\n\t\t\n\t\t$ini = eZINI::instance('ssoip.ini');\n \t$debug = $ini->variable('AuthSettings', 'Debug');\n\t\tif ($debug == 'enabled'){\n\t\t\teZLog::write(\"$ipAddress -----> id= $id\",'sso.log');\n\t\t}\n\t\tif ( $id !== false ){\n\t\t\t$user = eZUser::fetch( $id );\n\t\t\tif ( is_object( $user ) ){\n\t\t\t\treturn $user;\n\t\t }\n\t\t}\n return false;\n }", "private function getAllowedIPs()\n {\n $ips_config = $this->config->get('restrict_login.ips');\n\n return !is_array($ips_config) ? array() : array_keys($ips_config);\n }", "function getIps() {\n\t\treturn $this->findParentsOfClass('Ip');\n\t}", "public function getMyConnectionList(){\n return $this->belongsTo(User::class, 'req_user_id');\n }", "public function getIpAdress(){\n return $this->auth['ip_adress'];\n }", "public function getClientIps()\n {\n $clientIps = array();\n $ip = $this->server->get('REMOTE_ADDR');\n if (!$this->isFromTrustedProxy()) {\n return array($ip);\n }\n if (self::$trustedHeaders[self::HEADER_FORWARDED] && $this->headers->has(self::$trustedHeaders[self::HEADER_FORWARDED])) {\n $forwardedHeader = $this->headers->get(self::$trustedHeaders[self::HEADER_FORWARDED]);\n preg_match_all('{(for)=(\"?\\[?)([a-z0-9\\.:_\\-/]*)}', $forwardedHeader, $matches);\n $clientIps = $matches[3];\n } elseif (self::$trustedHeaders[self::HEADER_CLIENT_IP] && $this->headers->has(self::$trustedHeaders[self::HEADER_CLIENT_IP])) {\n $clientIps = array_map('trim', explode(',', $this->headers->get(self::$trustedHeaders[self::HEADER_CLIENT_IP])));\n }\n $clientIps[] = $ip; // Complete the IP chain with the IP the request actually came from\n $ip = $clientIps[0]; // Fallback to this when the client IP falls into the range of trusted proxies\n foreach ($clientIps as $key => $clientIp) {\n // Remove port (unfortunately, it does happen)\n if (preg_match('{((?:\\d+\\.){3}\\d+)\\:\\d+}', $clientIp, $match)) {\n $clientIps[$key] = $clientIp = $match[1];\n }\n if (IpUtils::checkIp($clientIp, self::$trustedProxies)) {\n unset($clientIps[$key]);\n }\n }\n // Now the IP chain contains only untrusted proxies and the client IP\n return $clientIps ? array_reverse($clientIps) : array($ip);\n }", "public function probe_ip($ip)\n {\n return $this->connection->query_select('posts', array('DISTINCT uid AS id'), array('ipaddress' => $ip));\n }", "function event_guard_log_allowed($ip_address) {\n\n\t\t//invalid ip address\n\t\tif (!filter_var($ip_address, FILTER_VALIDATE_IP)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t//get the access control allowed nodes\n\t\t$sql = \"select count(event_guard_log_uuid) \";\n\t\t$sql .= \"from v_event_guard_logs \";\n\t\t$sql .= \"where ip_address = :ip_address \";\n\t\t$sql .= \"and log_status = 'unblocked' \";\n\t\t$parameters['ip_address'] = $ip_address; \n\t\t$database = new database;\n\t\t$user_log_count = $database->select($sql, $parameters, 'column');\n\t\tunset($database);\n\n\t\t//debug info\n\t\tif ($debug) {\n\t\t\techo \"address \".$ip_address.\" count \".$user_log_count.\"\\n\";\n\t\t}\n\n\t\t//default authorized to false\n\t\t$allowed = false;\n\n\t\t//use the ip address to get the authorized nodes\n\t\tif ($user_log_count > 0) {\n\t\t\t$allowed = true;\n\t\t}\n\n\t\t//return\n\t\treturn $allowed;\n\t}", "public function getUsuariosVotos()\n {\n return $this->hasMany(User::className(), ['id' => 'usuario_id'])->via('votos');\n }", "function get_user_ip()\n{\n if (empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {\n return$_SERVER['REMOTE_ADDR'];\n }\n $ip = explode(',', $_SERVER['HTTP_X_FORWARDED_FOR']);\n return $ip[0];\n}", "public function add_user($ip){\n\t\t$query = \"INSERT INTO nodes(\n user_ip,\n\t\t\tuser_join_time) \n\t\t\tVALUES(?, NOW()) \n ON DUPLICATE KEY UPDATE user_ip = ?, user_join_time = NOW();\n\t\t\";\n\t\t\t\n\t\t$stmt = $this->prepare_statement($query);\n if(!$stmt)\n return NULL;\n\t\t$bind = $stmt->bind_param(\"ss\", $ip, $ip);\n\t\tif(!$bind)\n\t\t\treturn NULL;\n\t\t\n\t\t$exec = $stmt->execute();\n\t\tif(!$exec)\n\t\t\treturn NULL;\n\t\t\t\n\t\treturn $stmt->insert_id;\n\t}", "private function getIp()\n\t {\n\t \n\t if (isset($_SERVER['HTTP_X_FORWARDED_FOR']) &&( $_SERVER['HTTP_X_FORWARDED_FOR'] != '' ))\n\t {\n\t $client_ip =\n\t ( !empty($_SERVER['REMOTE_ADDR']) ) ?\n\t $_SERVER['REMOTE_ADDR']\n\t :\n\t ( ( !empty($_ENV['REMOTE_ADDR']) ) ?\n\t $_ENV['REMOTE_ADDR']\n\t :\n\t \"unknown\" );\n\t \n\t // los proxys van añadiendo al final de esta cabecera\n\t // las direcciones ip que van \"ocultando\". Para localizar la ip real\n\t // del usuario se comienza a mirar por el principio hasta encontrar\n\t // una dirección ip que no sea del rango privado. En caso de no\n\t // encontrarse ninguna se toma como valor el REMOTE_ADDR\n\t \n\t $entries = split('[, ]', $_SERVER['HTTP_X_FORWARDED_FOR']);\n\t \n\t reset($entries);\n\t while (list(, $entry) = each($entries))\n\t {\n\t $entry = trim($entry);\n\t if ( preg_match(\"/^([0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)/\", $entry, $ip_list) )\n\t {\n\t // http://www.faqs.org/rfcs/rfc1918.html\n\t $private_ip = array(\n\t '/^0\\./',\n\t '/^127\\.0\\.0\\.1/',\n\t '/^192\\.168\\..*/',\n\t '/^172\\.((1[6-9])|(2[0-9])|(3[0-1]))\\..*/',\n\t '/^10\\..*/');\n\t \n\t $found_ip = preg_replace($private_ip, $client_ip, $ip_list[1]);\n\t \n\t if ($client_ip != $found_ip)\n\t {\n\t $client_ip = $found_ip;\n\t break;\n\t }\n\t }\n\t }\n\t }\n\t else\n\t {\n\t $client_ip =\n\t ( !empty($_SERVER['REMOTE_ADDR']) ) ?\n\t $_SERVER['REMOTE_ADDR']\n\t :\n\t ( ( !empty($_ENV['REMOTE_ADDR']) ) ?\n\t $_ENV['REMOTE_ADDR']\n\t :\n\t \"unknown\" );\n\t }\n\t \n\t return $client_ip;\n\t \n\t}", "public function identities() {\n return $this->hasMany('App\\SocialIdentity');\n }", "function mswIPAddresses() {\n $ip = array();\n if (!empty($_SERVER['HTTP_CLIENT_IP'])) {\n $ip[] = $_SERVER['HTTP_CLIENT_IP'];\n } elseif (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {\n if (strpos($_SERVER['HTTP_X_FORWARDED_FOR'],',')!==FALSE) {\n $split = explode(',',$_SERVER['HTTP_X_FORWARDED_FOR']);\n foreach ($split AS $value) {\n $ip[] = $value;\n }\n } else {\n $ip[] = $_SERVER['HTTP_X_FORWARDED_FOR'];\n }\n } else {\n $ip[] = (isset($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : '');\n }\n return (!empty($ip) ? implode(', ',$ip) : '');\n}", "public function getIps()\n {\n return $this->ips;\n }", "public function user()\n\t{\n\t\treturn $this->belongsToMany('Trip');\n\t}", "private function checkIp(){\n\t\tif( !$this->isAuth() ){\n\t\t\treturn false;\n\t\t}\n\t\treturn ( $_SESSION['userIp'] == $_SERVER['REMOTE_ADDR'] );\n\t}", "function ipRange($ip){\n\n $ipArray = [];\n\n $ipadd = explode(\".\", $ip);\n\n #For loop that traverses the closely matching objects in the db\n #to check if it is composed of a range (specified with a \"-\" or a \"~\")\n for ($i = 0; $i < sizeof($ipadd); $i++){\n \tif(strpos(($ipadd[$i]), \"-\") == true){\n \t$octet = $i;\n $iprange = explode(\"-\",$ipadd[$i]);\n $min = $iprange[0];\n $max = $iprange[1]; \n \t}\n \telse if(strpos(($ipadd[$i]), \"~\") == true){\n \t$octet = $i;\n $iprange = explode(\"~\",$ipadd[$i]);\n $min = $iprange[0];\n $max = $iprange[1]; \n \t}\n\n }\n\n\n for($i = $min; $i <= $max; $i++){\n $ipadd[$octet] = $i;\n \n for ($j = 0; $j < sizeof($ipadd); $j++){\n\n $address = implode(\".\", $ipadd);\n }\n \n $ipArray[] = $address;\n \n }\n\n #Return the list of all IP addresses in the range\n return $ipArray;\n\n }", "public function checkUserIp(GetResponseEvent $event) {\n //The method to determine the user's IP may different from across environments and if VPN/CDN is used.\n //use a switch statement that defaults to getClientIp() method\n $ip = $event->getRequest()->getClientIp();\n\n //TODO: Logic to get User ID may need to be it's own Service\n $current_user = \\Drupal::currentUser();\n $user = \\Drupal\\user\\Entity\\User::load($current_user->id());\n $uid = $user->id();\n\n $known_ipv4 = \\Drupal::config('ip_ranger.settings')->get('ip_ranger_ipv4');\n $known_ipv6 = \\Drupal::config('ip_ranger.settings')->get('ip_ranger_ipv6');\n $known_ipv4_cidrs = \\Drupal::config('ip_ranger.settings')->get('ip_ranger_ipv4_cidrs');\n $known_ipv6_cidrs = \\Drupal::config('ip_ranger.settings')->get('ip_ranger_ipv6_cidrs');\n\n $ip_service = \\Drupal::service('ip_ranger.iputils');\n $ip4_array = $ip_service::getArrayOfIps($known_ipv4);\n $ip6_array = $ip_service::getArrayOfIps($known_ipv6);\n $ip4_cidrs_array = $ip_service::getArrayOfIps($known_ipv4_cidrs);\n $ip6_cidrs_array = $ip_service::getArrayOfIps($known_ipv6_cidrs);\n\n //check if ip is in array\n $network_status_array = [];\n $network_status_array['ipv4'] = (in_array($ip, $ip4_array))?1:0;\n $network_status_array['ipv6'] = (in_array($ip, $ip6_array))?1:0;\n\n //check to see if IP address are in the given CIDR range\n $ip_v4_cidr_matches = $ip_service::isIpInCidrRange($ip, $ip4_cidrs_array);\n $ip_v6_cidr_matches = $ip_service::isIpInCidrRange($ip, $ip6_cidrs_array);\n\n //count($array) should return empty when there is a match or populate array with matched ranges\n $network_status_array['ipv4cidr'] = (!count($ip_v4_cidr_matches))?1:0;\n $network_status_array['ipv6cidr'] = (!count($ip_v6_cidr_matches))?1:0;\n\n $in_network_status = \"FALSE\";\n if( in_array(1, $network_status_array)) {\n $in_network_status = \"TRUE\";\n }\n\n $request = \\Drupal::request();\n $session = $request->getSession();\n $session->set('ip_ranger_is_in_network', $in_network_status);\n\n //current network status\n $ip_network_status = $session->get('ip_ranger_is_in_network');\n //todo: refactor IpRangerSettingsForms.php validation helper functions to utilize Custom/IpUtils helper functions\n\n }", "public function handle($request, Closure $next)\n{\n\nforeach ($request->getClientIps() as $ip) {\nif (! $this->isValidIp($ip) && ! $this->isValidIpRange($ip)) {\n Log::info('Invalid access by:' . $ip);\nreturn redirect('/');\n}\n}\nreturn $next($request);\n}", "public function getInversionesUser()\n {\n return $this->belongsTo('App\\Models\\User', 'iduser', 'id');\n }", "public static function invalidateIp($ip) {\n\t\t$votes=Vote::findAllBy(\"ip\",$ip);\n\t\tforeach ($votes as $vote) {\n\t\t\t$vote->valid=FALSE;\n\t\t\t$vote->save();\n\t\t}\n\t}", "public function users(){\n\t\treturn $this->belongsToMany('Alsaudi\\\\Eloquent\\\\UserRelation',\n\t\t\t'trip_user','trip_id','user_id');\n\t}", "public function loginUserConditionMatchesMultipleLoggedInUsers() {}", "public function loginUserConditionMatchesMultipleLoggedInUsers() {}", "static function preventMultipleRegister($username)\r\n\t{\r\n\t\tsetcookie(\"flirt48_activated\", $username, time()+60*60*24*30*365, \"/\");//, \".yourbuddy24.com\", 1, true);\r\n\t\t$ip = funcs::getRealIpAddr();\r\n\t\t$sql = \"UPDATE \".TABLE_MEMBER.\" SET ip_address='\".$ip.\"'\r\n\t\t\t\t\t\tWHERE \".TABLE_MEMBER_USERNAME.\"='\".$username.\"' LIMIT 1\";\r\n\t\tDBconnect::execute($sql);\r\n\t}", "function get_user_identification($obj, $return_type)\n{\n\t$ipaddress = $obj->input->ip_address();\n\t$value = ($obj->session->userdata($return_type))?$obj->session->userdata($return_type):$ipaddress;\n\t\n\treturn $value;\n}", "public function getSeguidoresUser()\n {\n return $this->hasMany(User::className(), ['id' => 'user_id'])->via('seguidores');\n }", "function check_login_IP($id = '')\n\t{ $this->db->where('ip_address', $_SERVER['REMOTE_ADDR']); if($id != '') $this->db->where('id !=', $id);\n\t$query = $this->db->get('login_history'); if ($query->num_rows() > 0) { return FALSE; } else { return TRUE; }\t}", "public static function getIPs(): array\n {\n return self::$ips;\n }", "public function __construct($user, $ip)\n {\n $this->user = $user;\n $this->ip = $ip;\n }", "public function checkLockToIP() {}", "function user_ip () {\r\n\treturn $_SERVER['REMOTE_ADDR'];\r\n}", "public function access()\n {\n return $this->hasManyThrough('App\\Protocol', 'App\\ProtocolAccess', 'user_id', 'id', 'id', 'protocol_id');\n }", "function current_ip_in_network() {\r\n return ip_in_network(current_user_ip());\r\n}", "function getRealIpUser(){\r\n \r\n switch(true){\r\n \r\n case(!empty($_SERVER['HTTP_X_REAL_IP'])) : return $_SERVER['HTTP_X_REAL_IP'];\r\n case(!empty($_SERVER['HTTP_CLIENT_IP'])) : return $_SERVER['HTTP_CLIENT_IP'];\r\n case(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) : return $_SERVER['HTTP_X_FORWARDED_FOR'];\r\n \r\n default : return $_SERVER['REMOTE_ADDR'];\r\n \r\n }\r\n \r\n}", "public function Persona (){ \n\n $this->ip=$this->getIP();\n }", "public function all_user_connected() {\n try\n {\n $max_last_ping = time() - 31;\n $stmt = $this->db->prepare(\"SELECT * FROM connected_user WHERE last_ping > :last_ping\");\n $stmt->execute(array(\n 'last_ping' => $max_last_ping\n ));\n\n while($result = $stmt->fetch()) {\n $listid[] = $result['id_user'];\n }\n \n return $listid;\n }\n catch(PDOException $e) {\n die('<h1>ERREUR LORS DE LA CONNEXION A LA BASE DE DONNEE. <br />REESAYEZ ULTERIEUREMENT</h1>');\n }\n }", "public function get_usercode()\n\t{\n\t\t$ly = new cls_layer(); \n\t\t$ip = $ly->getRealIpAddr(); //get new user's ip address\n\t\treturn array(\"thisUser\" => $ip . \":\" . $_SESSION['logged-user'],\n\t\t\t\t\t\"layerUsers\" => $this->get_subscription_string());\n\t}", "public static function validIpDataProvider() {}", "public function logUser()\n {\n if (!$this->limpid->visitCounterManager->getEntry($_SERVER['REMOTE_ADDR']))\n $this->limpid->visitCounterManager->logUser($_SERVER['REMOTE_ADDR']);\n else\n $this->limpid->visitCounterManager->editEntry($_SERVER['REMOTE_ADDR'], ['last_visit' => date('Y-m-d H:i:s')]);\n }", "public function ObtenerIp()\n { \n\n return str_replace(\".\",\"\",$this->getIP()); //Funcion que quita los puntos de la IP\n\n }", "public function users()\n {\n return $this->hasManyThrough(User::class, UserConfig::class);\n }", "public function isRegisterdIP()\n\t{\t\n\t\t$IPs = (array) $this->getIPs();\n\t\treturn in_array($this->IP, $IPs);\n\t}", "function getRealIpUser(){\n\n switch(true){\n\n case(!empty($_SERVER['HTTP_X_REAL_IP'])) : return $_SERVER['HTTP_X_REAL_IP'];\n case(!empty($_SERVER['HTTP_CLIENT_IP'])) : return $_SERVER['HTTP_CLIENT_IP'];\n case(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) : return $_SERVER['HTTP_X_FORWARDED_FOR'];\n\n default : return $_SERVER['REMOTE_ADDR'];\n }\n\n}", "public function loadClientUsers()\n {\n $user = $this->checkUser();\n if (!$user) {\n return;\n }\n\n //for API_KEY based connection\n if($user instanceof \\Symfony\\Component\\Security\\Core\\User\\User){\n $user = $this->container->get('doctrine')->getManager()->getRepository('OjsUserBundle:User')->findOneBy(['username'=>$user->getUsername()]);\n }\n\n $clients = $this->container->get('doctrine')->getManager()->getRepository('OjsUserBundle:Proxy')->findBy(\n array('proxyUserId' => $user->getId())\n );\n $this->session->set('userClients', $clients);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "public function setUserIP($value)\n {\n return $this->set('UserIP', $value);\n }", "private function registerIpList()\n {\n $this->app->singleton('firewall.iplist', function () {\n return new IpList($this->getFirewallModel());\n });\n }", "public function getUserimages()\n {\n return $this->hasMany(Userimage::className(), ['user_id' => 'id']);\n }", "public function validate_session_other_device($user, $ip)\n {\n if ($this->db->from('ec_client')->where(array('email' => $user, 'status' => 1, 'ip' => $ip))->count_all_results() > 0){\n return TRUE;\n }else if ($this->db->from('ec_client')->where(array('email' => $user, 'status' => 0, 'ip' => ''))->count_all_results() > 0) {\n return TRUE;\n } else {\n return FALSE;\n }\n }", "function forwarded_ip() {\n\n $server=array(\n 'HTTP_X_FORWARDED_FOR'=>'123.123.123.123.',\n );\n\n\n $keys = array(\n 'HTTP_X_FORWARDED_FOR',\n 'HTTP_X_FORWARDED',\n 'HTTP_FORWARDED_FOR',\n 'HTTP_FORWARDED',\n 'HTTP_CLIENT_IP',\n 'HTTP_X_CLUSTER_CLIENT_IP',\n );\n\n foreach($keys as $key) {\n if(isset($server[$key])) {\n $ip_array = explode(',', $server[$key]);\n foreach($ip_array as $ip) {\n $ip = trim($ip);\n if(validateIp($ip)){\n return $ip;\n }\n\n }\n }\n }\n return '';\n }", "private function subscribeToVip($request)\n {\n $user = User::byEmail($request->input('email'));\n if($user){\n $vip = VipListMember::create($request->all());\n $user->vip()->save($vip);\n return $vip;\n }else{\n $vip = VipListMember::create($request->all());\n return $vip;\n }\n }", "public function find_users_ip(){\n\t\tif ( ! empty( $_SERVER['HTTP_CLIENT_IP'] ) ) {\n\t\t\t//check ip from share internet\n\t\t\t$ip = $_SERVER['HTTP_CLIENT_IP'];\n\t\t} elseif ( ! empty( $_SERVER['HTTP_X_FORWARDED_FOR'] ) ) {\n\t\t\t//to check ip is pass from proxy\n\t\t\t$ip = $_SERVER['HTTP_X_FORWARDED_FOR'];\n\t\t} else {\n\t\t\t$ip = $_SERVER['REMOTE_ADDR'];\n\t\t}\n\t\treturn $ip;\n\t}", "public function checkIPs () {\n\n\t\t$validation = true;\n\n\t\tforeach ($this->allow as $key => $ip) {\n\t\t\t\n\t\t\tif ($this->matchIP($ip)) {\n \n return true;\n \n }\n\n\t\t}\n\n\t\treturn false;\n\n\t}", "public function onLogin($event)\n {\n $user_ip = $this->getUserIP();\n $ips = $this->getAllowedIPs();\n\n // No IP address has been added yet, allow login from anywhere.\n if (count($ips) === 0) {\n return;\n }\n\n // Check if user's IP is allowed\n if (!$this->checkIP($user_ip, $ips)) {\n $u = $event->getUserObject();\n\n $u->logout();\n\n Redirect::to('/login')->send();\n }\n }", "function o1_check_session_ip( $user_id ) {\n\n if ( false !== $user_id ) {\n\n // @fjarrett helped\n $sessions = WP_Session_Tokens::get_instance( $user_id );\n $session = $sessions->get( wp_get_session_token() );\n if ( empty( $session )\n || empty( $session['ip'] )\n || empty( $_SERVER['REMOTE_ADDR'] )\n || $session['ip'] !== $_SERVER['REMOTE_ADDR']\n ) {\n // User's IP address has changed, log him out\n add_action( 'init', 'wp_destroy_current_session', 0 );\n error_log( 'Destroying session for user #' . $user_id );\n }\n }\n\n return $user_id;\n}", "public function getIpAddress();", "public function userJoin() {\n return $this->belongsToMany('App\\Model\\User', 'trip_users');\n }", "public function deleteipwhitelist($ip = null) \n\t{\n\t\tUserModel::authentication();\n\t\t\n\t\t//get user's infp\n $user = UserModel::user();\n\n\t\t//new list\n $newwhitelist = str_replace($ip, \"\", $user->user_ipwhitelist);\n \n\t\t//update new ip whitelist\n\t\tSecurityModel::updatenewwhitelist($newwhitelist);\n }", "function getIP(){\r\n$ip = $_SERVER['REMOTE_ADDR'];\r\n\t//lay IP neu user truy cap qua Proxy\r\n if (!empty($_SERVER['HTTP_CLIENT_IP'])) {\r\n $ip = $_SERVER['HTTP_CLIENT_IP'];\r\n } else if (!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) {\r\n $ip = $_SERVER['HTTP_X_FORWARDED_FOR'];\r\n }\r\nreturn $ip;\r\n}", "public function getUserIp()\n {\n return $this->remoteAddress->getRemoteAddress();\n }", "function getRealIpUser()\r\n\t{\r\n\t\tswitch(true)\r\n\t\t{\r\n\t\t\tcase(!empty($_SERVER['HTTP_X_REAL_IP'])) : return $SERVER['HTTP_X_REAL_IP'];\r\n\t\t\tcase(!empty($_SERVER['HTTP_CLIENT_IP'])) : return $SERVER['HTTP_CLIENT_IP'];\r\n\t\t\tcase(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) : return $SERVER['HTTP_X_FORWARDED_FOR'];\r\n\r\n\t\t\tdefault : return $_SERVER['REMOTE_ADDR'];\r\n\t\t\t \r\n\t\t}\r\n\t}", "protected function getUserIp(pclib\\AuthUser $user)\n{\n\t$ip = ip2long($this->app->request->getClientIp());\n\tif ($ip != $user->values['IP']) {\n\t\t$this->log('AUTH_NOTICE', 'Access from different ip-address.', $user->values['ID']);\n\t}\n\treturn $ip;\n}" ]
[ "0.62348485", "0.5848797", "0.57623976", "0.5744963", "0.5669535", "0.5661536", "0.55875164", "0.55772877", "0.552688", "0.55173653", "0.546303", "0.54510534", "0.5440554", "0.54095995", "0.5392626", "0.52679634", "0.5262802", "0.521243", "0.52095884", "0.51835513", "0.5170072", "0.515497", "0.5151797", "0.51459765", "0.5145174", "0.5141227", "0.51396495", "0.5132512", "0.5124907", "0.5120801", "0.5105169", "0.51031333", "0.50821835", "0.5074279", "0.50390875", "0.5038153", "0.50366306", "0.50350827", "0.5017574", "0.5012966", "0.5009213", "0.50031465", "0.4999761", "0.4996247", "0.49763742", "0.49671873", "0.4962236", "0.49609923", "0.4958637", "0.49513343", "0.4942552", "0.49402398", "0.49397013", "0.49347827", "0.49269965", "0.4918618", "0.48989028", "0.48959923", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48957482", "0.48947385", "0.48947385", "0.48947385", "0.48947385", "0.48947385", "0.48947385", "0.48947385", "0.48947385", "0.4888254", "0.48837513", "0.48699757", "0.4856904", "0.48564163", "0.4851487", "0.48435152", "0.4837711", "0.4837145", "0.4829594", "0.48259026", "0.48190793", "0.4817895", "0.48107222", "0.48047417", "0.48044115" ]
0.6326377
0
/ | | Default Home Controller | | | You may wish to use controllers instead of, or in addition to, Closure | based routes. That's great! Here is an example controller method to | get you started. To route to this controller, just add the route: |
public function index() { $roundNo = e(Input::get('round')); $id = e(Route::input('id')); if(strlen($roundNo) == 0) { $roundNo = e(Route::input('round')); if($roundNo == null) $roundNo = 1; } $round = Round::where('EventID', '=', $id)->where('RoundNumber', '=', $roundNo)->firstOrFail(); $roundsForEvent = Round::where('EventID', '=', $id)->orderBy('RoundNumber')->get(); $roundsForEventSelect = array(); foreach($roundsForEvent as $r) { $coursename = $r->course !== null ? $r->course->Name : '[deleted course]'; $roundsForEventSelect[$r->RoundNumber] = $r->RoundNumber . ': ' . $coursename; } $event = CyclingEvent::find($id); $results = DB::table('results') ->select(DB::raw('results.*, duration + timepenalty as TotalTime,divisions.DivisionID,divisions.DivisionName, teams.Name as TeamName,teams.Colour,concat(lower(countries.code), ".png")')) ->leftJoin('eventrider', function($join) { $join->on('results.ridername', '=', 'eventrider.ridername') ->on('results.eventid', '=', 'eventrider.eventid'); }) ->leftJoin('divisions', 'eventrider.divisionid', '=', 'divisions.divisionid') ->leftJoin('teamrider', function($join) { $join->on('results.ridername', '=', 'teamrider.ridername') ->on('results.eventid','=','teamrider.eventid'); }) ->leftJoin('teams', 'teamrider.teamid', '=', 'teams.teamid') ->leftJoin('profiledata', 'profiledata.fullname', '=', 'results.ridername') ->leftJoin('countries', 'countries.name', '=', 'profiledata.country') ->where('roundid', '=', $round->RoundID) ->orderByRaw('Duration + TimePenalty, AvSpeed desc') ->get(); return View::make('results', array('results' => $results, 'event' => $event, 'round' => $round, 'roundsForEvent' => $roundsForEventSelect)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n\t{\n\t\t//echo 'Hello from the index action in the Home controller!';\n\t\t\n\t\t/*View::render('Home' . DS . 'index.php', [\n\t\t\t\"name\" => \"Laura\",\n\t\t\t\"colours\" => [\"red\", \"green\", \"blue\"]\n\t\t]);*/\n\t\t\n\t\t// View::renderTemplate('Home' . DS . 'index.html', [\n\t\t// \t\"name\" => \"Laura\",\n\t\t// \t\"colours\" => [\"red\", \"green\", \"blue\"]\n // ]);\n \n\t\t$this->showRouteParams();\n\t\t// echo \"Hello, World!\";\n }", "public function indexRoute()\n {\n }", "public function route_home() {\n\t\techo '<h1>It wurks!</h1>';\n\t}", "public function index() {\r\n\t\t\t\r\n\t\t\t$url = substr( $_SERVER['REQUEST_URI'], 1 );\r\n\t\t\t$requestParams = explode( '/', $url );\r\n\t\t\t$controller = $requestParams[0];\r\n\r\n\t\t\t// If the URL has a bad controller and more than 2 params redirect to 404 page;\r\n\t\t\tif(empty($controller) && count($requestParams) > 1){\r\n\t\t\t\trequire_once( './app/Views/RouteNotFound.php' );\r\n\t\t\t\tdie();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t/* If no controller is passed in the url, load home page */\r\n\t\t\tif ( empty( $controller ) ) {\r\n\t\t\t\t$homepage = new HomeController();\r\n\t\t\t\t$homepage->homepage();\r\n\t\t\t\tdie();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t/* If a controller is passed in the url, but no method is given, load view*/\r\n\t\t\tif ( count( $requestParams ) == 1 ) {\r\n\t\t\t\t$view = ucfirst( $requestParams[0] );\r\n\t\t\t\trequire_once( './app/Views/' . $view . '.php' );\r\n\t\t\t\tdie();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t/* If the url doesn't respect domain/controller/method?params logic, load 404 view*/\r\n\t\t\tif ( count( $requestParams ) > 2 ) {\r\n\t\t\t\trequire_once( './app/Views/RouteNotFound.php' );\r\n\t\t\t\tdie();\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t/* Get the method passed in the url */\r\n\t\t\t$requestAux = explode( '?', $requestParams[1] );\r\n\t\t\t$method = $requestAux[0];\r\n\t\t\t\r\n\t\t\t/* Check if params are passed through url */\r\n\t\t\tif ( isset( $requestAux[1] ) ) {\r\n\t\t\t\t$params = $requestAux[1];\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t/* Create new instance of the controller given through url */\r\n\t\t\t$auxController = ucfirst( $controller ) . 'Controller';\r\n\t\t\t$appController = new $auxController();\r\n\t\t\t\r\n\t\t\t/*\r\n\t\t\t *\r\n\t\t\t * If method isset and exists in the controller\r\n\t\t\t * call the method ( with params optionally),\r\n\t\t\t * else render the view\r\n\t\t\t *\r\n\t\t\t * */\r\n\t\t\tif ( isset( $method ) && ! empty( $method ) && method_exists( $appController, $method ) ) {\r\n\t\t\t\tif ( isset( $params ) && ! empty( $params ) ) {\r\n\t\t\t\t\t$appController->$method( $params );\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$appController->$method();\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\t$appController->createView( $controller );\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}", "public function index() {\n\n\t\t$data['content'] = 'Homepage';\n\t\t$this->flexi->title('Homepage')\n\t\t\t\t\t->make('home', $data);\n\n\t}", "public function index() {\n $this->home(); \n }", "public function indexAction(){\n\t\techo \"Welcome malt api controller\";\n\t\texit;\n\t}", "public function index()\n\t{\n\t\treturn view('home');\n\t}", "public function index()\n\t{\n\t\treturn view('home');\n\t}", "public function index() {\n\n\t\tif(!empty($_GET['page'])) {\n\t\t\tif($_GET['page'] == 'home') {\n\t\t\t\t(new HomeController)->home();\n\t\t\t} elseif($_GET['page'] == 'about-me') {\n\t\t\t\t(new HomeController)->aboutMe();\n\t\t\t}\n\t\t} else {\n\t\t\t(new HomeController)->home();\n\t\t}\n\t}", "public function index()\n {\n //return view('home');\n }", "public function index()\n {\n return view('/home');\n }", "public function index()\n {\n return view('/home');\n }", "public function routeController()\n { }", "public function controller(){\n route('start')->onMessageText('/start');\n route('add')->onMessageText('/add');\n route('list')->onMessageText('/list');\n route('delete')->onMessageText('/delete');\n route('clear')->onMessageText('/clear');\n route('about')->onMessageText('/about');\n }", "public function index(){ return view('home'); }", "public function index()\n {\n return view(\"home\");\n }", "public function home()\n {\n return view(\"index\");\n }", "public function index()\n\t{\n\t\t$this->load->view('home');\n\t}", "public function index()\n {\n echo \"hola\";\n }", "function index() {\n\n // This page cannot be accessed without providing a page\n // the routes.php file will not allow the page to be accessed\n // $route['pages/(:any)'] = 'pages/view/$';\n redirect('/', 'refresh');\n\n }", "public function index()\n { \n \n return view('home');\n }", "public function home()\n\t{\n\n\t\tView::show(\"home.php\", \"Accueil Mon MVC !\");\n\t}", "public function indexAction() {\r\n\r\n// NSP::$app->registry->view->welcome = 'Welcome to NSP MVC';\r\n//\r\n// /*** load the index template ***/\r\n NSP::$app->view->viewVar = 'Rest controller';\r\n NSP::$app->registry->get('view')->show('index');\r\n }", "public function home(){\n \treturn view('welcome');\t\n }", "public function index()\n {\n return view('home'); \n }", "public function index()\n {\n return view('home'); \n }", "public function index()\r\n {\r\n View::render('home');\r\n }", "public function index()\n { \n return view('home');\n }", "public function index()\n {\n\n \t\t\n return view('home');\n }", "public function index()\n {\n $route = Route::getFacadeRoot()->current()->uri();;\n\n return view(\"home\", compact('route'));\n }", "public function index()\n\t{\n\t\treturn view('pages/home');\n\t}", "public function index()\n\t{\n\t\treturn view(\"welcome\");\n\t}", "public function index()\n {\n // return view('welcome');\n }", "public function index()\n {\n \n\n return view('home');\n }", "public function index()\n { \n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index() \n\t{\n\t\tredirect('home');\n\t}", "public function index()\n\t{\n return View::make('home');\n\t}", "public function index()\n {\n return \"hello world\";\n }", "public function home()\n {\n return view(\"home\");\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n\t{\n\t\treturn view('home' , ['setClass' => 'grayBody']);\n\t}", "public function index()\n {\n return View(\"pages.home\");\n }", "public function index()\n {\n echo 'hello';\n }", "public function index()\n {\n return view('home');\n }", "public static function route()\n {\n return 'index';\n }", "public function index()\n {\n $this->breadcrumbs->add('Home', '/');\n $this->breadcrumbs->add('Dashboard', '/dashboard');\n $this->breadcrumbs->add('Customer', '/dashboard/customer');\n\n // Render the breadcrumbs and pass them to the view\n $data['breadcrumbs'] = $this->breadcrumbs->render();\n\n // Load the view and pass the data\n return view('home', $data);\n }", "public function index() \n\t{\n\t\t$this->_render_hod_view('home');\n\t}", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }", "public function index()\n {\n return view('home');\n }" ]
[ "0.7126961", "0.6884877", "0.6857406", "0.68264675", "0.68193334", "0.6802348", "0.6789021", "0.6751206", "0.6751206", "0.6747353", "0.67451143", "0.67434067", "0.67434067", "0.6735617", "0.67169195", "0.6705626", "0.66658235", "0.66505617", "0.664817", "0.664135", "0.6593809", "0.6590978", "0.6587677", "0.65845704", "0.65825474", "0.65734994", "0.65734994", "0.65686166", "0.65634453", "0.65563655", "0.6555249", "0.6551245", "0.65452206", "0.65346926", "0.6530844", "0.6529075", "0.6520002", "0.6516054", "0.651411", "0.6512947", "0.6505727", "0.65036255", "0.65033567", "0.649963", "0.64937764", "0.64907", "0.6490523", "0.6487483", "0.6481045", "0.6472062", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668", "0.6470668" ]
0.0
-1
echo "sono il costruttore: " . __CLASS__ . " " . __FUNCTION__ . '';
public function __construct() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function toString()\n {\n return __CLASS__;\n }", "function getClassName(){\n echo __CLASS__ . \"<br><br>\"; \n }", "public function __toString()\r\n {\r\n return __CLASS__;\r\n }", "public function __toString()\r\n {\r\n return __CLASS__;\r\n }", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString() {\n return __CLASS__ . \" Class\";\n }", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}" ]
[ "0.7157011", "0.7151732", "0.7116236", "0.7116236", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7085101", "0.7064072", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776", "0.70397776" ]
0.0
-1
echo "sono il metodo tutti: " . __CLASS__ . " " . __FUNCTION__ . '';
public function tutti() { $utentiDao = new AutoreDao(); $res = $utentiDao->read(); $view = new ViewCore(); echo $view->render( 'gestione_utenti\tutti_gli_utenti.html', ['autori' => $res] ); //print_r($twig); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getClassName(){\n echo __CLASS__ . \"<br><br>\"; \n }", "function classname()\n\t\t{\n\t\t\techo \"</br>constructor with name of class \";\n\t\t\t\n\t\t}", "public function toString()\n {\n return __CLASS__;\n }", "public function __toString()\n\t{\n\t\treturn \"This is the function that is called when you try to use print or echo or a variable that holds an instance of this class.\";\n\t}", "public function __toString() {\n return __CLASS__ . \" Class\";\n }", "function abc(){\n return __FUNCTION__;\n}", "function test(){ \n //print the function name i.e; test. \n echo 'The function name is '. __FUNCTION__ . \"<br><br>\"; \n }", "public function __toString()\r\n {\r\n return __CLASS__;\r\n }", "public function __toString()\r\n {\r\n return __CLASS__;\r\n }", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "public function __toString()\r\n\t{\r\n\t\treturn __CLASS__;\r\n\t}", "function jtp(){\n echo \"Trait name = \",__TRAIT__;\n\t\t\techo \"<br><br>\";\n\t\t\techo \"Class Name = \".__CLASS__;\n }", "public function getName(): string\n {\n return __CLASS__;\n }", "public function __construct()\n\t{\n\t\techo __METHOD__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}", "public function __toString()\n\t{\n\t\treturn __CLASS__;\n\t}" ]
[ "0.7082097", "0.6870194", "0.67867225", "0.67241275", "0.6666639", "0.6665208", "0.6636922", "0.66219294", "0.66219294", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65779114", "0.65688705", "0.6532457", "0.6530045", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719", "0.6525719" ]
0.0
-1
Run the database seeds.
public function run() { factory(App\Business::class, 25)->create()->each(function ($u) { $faker = Faker\Factory::create(); for ($i=0; $i < 7; $i++) { if ($value = rand(0,3) != 3) { $opening = $faker->time($format = 'H:i:s', $max = '10:00:00'); OperatingHour::create([ 'opening_time' => $opening, 'closing_time' => $faker->time($format = 'H:i:s', $min = $opening), 'day' => $i, 'entry_type' => 'App\Business', 'entry_id' => $u->id, ]); } } for ($j=0; $j < mt_rand(1,4); $j++) { $u->tags()->save(factory(App\Tag::class)->make()); } for ($k=0; $k < mt_rand(1,4); $k++) { $u->menus()->save(factory(App\Menu::class)->make())->each(function ($x) { $faker = Faker\Factory::create(); $menuitem = MenuItem::create([ 'price' => $faker->numberBetween(10, 20), 'discount' => $faker->numberBetween(1, 10), 'name' => $faker->word(), 'description' => $faker->paragraph(), 'category' => 'test-cat', 'image_path' => '739aaf363bbfa91612f09ac9cee380e0', 'menu_id' => $x->id, ]); for ($c=0; $c < 3; $c++) { MenuExtra::create([ 'name' => $faker->word(), 'price' => mt_rand(0, 5), 'menu_item_id' => $menuitem->id, 'menu_extra_category_id' => 0, ]); } }); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n // $this->call(UserTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(TagTableSeeder::class);\n // $this->call(PostTagTableSeeder::class);\n\n /*AB - use faker to populate table see file ModelFactory.php */\n factory(App\\Editeur::class, 40) ->create();\n factory(App\\Auteur::class, 40) ->create();\n factory(App\\Livre::class, 80) ->create();\n\n for ($i = 1; $i < 41; $i++) {\n $number = rand(2, 8);\n for ($j = 1; $j <= $number; $j++) {\n DB::table('auteur_livre')->insert([\n 'livre_id' => rand(1, 40),\n 'auteur_id' => $i\n ]);\n }\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('post')->insert(\n [\n 'title' => 'Test Post1',\n 'desc' => str_random(100).\" post1\",\n 'alias' => 'test1',\n 'keywords' => 'test1',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post2',\n 'desc' => str_random(100).\" post2\",\n 'alias' => 'test2',\n 'keywords' => 'test2',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post3',\n 'desc' => str_random(100).\" post3\",\n 'alias' => 'test3',\n 'keywords' => 'test3',\n ]\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n\n factory('App\\User', 10 )->create();\n\n $users= \\App\\User::all();\n $users->each(function($user){ factory('App\\Category', 1)->create(['user_id'=>$user->id]); });\n $users->each(function($user){ factory('App\\Tag', 3)->create(['user_id'=>$user->id]); });\n\n\n $users->each(function($user){\n factory('App\\Post', 10)->create([\n 'user_id'=>$user->id,\n 'category_id'=>rand(1,20)\n ]\n );\n });\n\n $posts= \\App\\Post::all();\n $posts->each(function ($post){\n\n $post->tags()->attach(array_unique([rand(1,20),rand(1,20),rand(1,20)]));\n });\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => '[email protected]', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n UsersLevel::create([\n 'name' => 'Administrator'\n ]);\n\n UsersLevel::create([\n 'name' => 'User'\n ]);\n\n User::create([\n 'username' => 'admin',\n 'password' => bcrypt('admin123'),\n 'level_id' => 1,\n 'fullname' => \"Super Admin\",\n 'email'=> \"[email protected]\"\n ]);\n\n\n \\App\\CategoryPosts::create([\n 'name' =>'Paket Trip'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' =>'Destinasi Kuliner'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Event'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Profil'\n ]);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n $faker = Faker::create('id_ID');\n /**\n * Generate fake author data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('author')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Generate fake publisher data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('publisher')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Seeding payment method\n */\n DB::table('payment')->insert([\n ['name' => 'Mandiri'],\n ['name' => 'BCA'],\n ['name' => 'BRI'],\n ['name' => 'BNI'],\n ['name' => 'Pos Indonesia'],\n ['name' => 'BTN'],\n ['name' => 'Indomaret'],\n ['name' => 'Alfamart'],\n ['name' => 'OVO'],\n ['name' => 'Cash On Delivery']\n ]);\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n // MyList::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 3; $i++) {\n MyList::create([\n 'title' => 'List-'.($i+1),\n 'color' => $faker->sentence,\n 'icon' => $faker->randomDigitNotNull,\n 'index' => $faker->randomDigitNotNull,\n 'user_id' => 1,\n ]);\n }\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Products::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few products in our database:\n for ($i = 0; $i < 50; $i++) {\n Products::create([\n 'name' => $faker->word,\n 'sku' => $faker->randomNumber(7, false),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Pablo Rosales',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'status' => 1,\n 'role_id' => 1,\n 'movil' => 0\n ]);\n\n User::create([\n 'name' => 'Usuario Movil',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'status' => 1,\n 'role_id' => 3,\n 'movil' => 1\n ]);\n\n Roles::create([\n 'name' => 'Administrador'\n ]);\n Roles::create([\n 'name' => 'Operaciones'\n ]);\n Roles::create([\n 'name' => 'Comercial'\n ]);\n Roles::create([\n 'name' => 'Aseguramiento'\n ]);\n Roles::create([\n 'name' => 'Facturación'\n ]);\n Roles::create([\n 'name' => 'Creditos y Cobros'\n ]);\n\n factory(App\\Customers::class, 100)->create();\n }", "public function run()\n {\n // php artisan db:seed --class=StoreTableSeeder\n\n foreach(range(1,20) as $i){\n $faker = Faker::create();\n Store::create([\n 'name' => $faker->name,\n 'desc' => $faker->text,\n 'tags' => $faker->word,\n 'address' => $faker->address,\n 'longitude' => $faker->longitude($min = -180, $max = 180),\n 'latitude' => $faker->latitude($min = -90, $max = 90),\n 'created_by' => '1'\n ]);\n }\n\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => '[email protected]',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create([\n 'name' => 'Qwerty',\n 'email' => '[email protected]',\n 'password' => bcrypt('secretpassw'),\n ]);\n\n factory(User::class, 59)->create([\n 'password' => bcrypt('secretpassw'),\n ]);\n\n for ($i = 1; $i < 11; $i++) {\n factory(Category::class)->create([\n 'name' => 'Category ' . $i,\n ]);\n }\n\n for ($i = 1; $i < 101; $i++) {\n factory(Product::class)->create([\n 'name' => 'Product ' . $i,\n ]);\n }\n }", "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> '[email protected]',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1,5) as $index) {\n Lista::create([\n 'name' => $faker->sentence(2),\n 'description' => $faker->sentence(10), \n ]);\n } \n\n foreach (range(1,20) as $index) {\n $n = $faker->sentence(2);\n \tTarea::create([\n \t\t'name' => $n,\n \t\t'description' => $faker->sentence(10),\n 'lista_id' => $faker->numberBetween(1,5),\n 'slug' => Str::slug($n),\n \t\t]);\n } \n }", "public function run()\n {\n $faker = Faker::create('lt_LT');\n\n DB::table('users')->insert([\n 'name' => 'user',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n DB::table('users')->insert([\n 'name' => 'user2',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n\n foreach (range(1,100) as $val)\n DB::table('authors')->insert([\n 'name' => $faker->firstName(),\n 'surname' => $faker->lastName(),\n \n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n Flight::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 100; $i++) {\n\n\n Flight::create([\n 'flightNumber' => $faker->randomNumber(5),\n 'depAirport' => $faker->city,\n 'destAirport' => $faker->city,\n 'reservedWeight' => $faker->numberBetween(1000 - 10000),\n 'deptTime' => $faker->dateTime('now'),\n 'arrivalTime' => $faker->dateTime('now'),\n 'reservedVolume' => $faker->numberBetween(1000 - 10000),\n 'airlineName' => $faker->colorName,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(UserSeeder::class);\n\n Medicamento::factory(50)->create();\n Reporte::factory(5)->create();\n Cliente::factory(200)->create();\n Asigna_valor::factory(200)->create();\n Carga::factory(200)->create();\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n TicketSeeder::class\n ]);\n\n DB::table('departments')->insert([\n 'abbr' => 'IT',\n 'name' => 'Information Technologies',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'email_verified_at' => Carbon::now(),\n 'password' => Hash::make('admin'),\n 'department_id' => 1,\n 'avatar' => 'default.png',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => 1,\n 'user_id' => 1\n ]);\n }", "public function run()\n {\n \\App\\Models\\Article::factory(20)->create();\n \\App\\Models\\Category::factory(5)->create();\n \\App\\Models\\Comment::factory(40)->create();\n\n \\App\\Models\\User::create([\n \"name\"=>\"Alice\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n \\App\\Models\\User::create([\n \"name\"=>\"Bob\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class,3)->create()->each(\n \tfunction($user)\n \t{\n \t\t$user->questions()\n \t\t->saveMany(\n \t\t\tfactory(App\\Question::class, rand(2,6))->make()\n \t\t)\n ->each(function ($q) {\n $q->answers()->saveMany(factory(App\\Answer::class, rand(1,5))->make());\n })\n \t}\n );\n }\n}", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "public function run()\n\t{\n\t\tDB::table('libros')->truncate();\n\n\t\t$faker = Faker\\Factory::create();\n\n\t\tfor ($i=0; $i < 10; $i++) { \n\t\t\tLibro::create([\n\n\t\t\t\t'titulo'\t\t=> $faker->text(40),\n\t\t\t\t'isbn'\t\t\t=> $faker->numberBetween(100,999),\n\t\t\t\t'precio'\t\t=> $faker->randomFloat(2,3,150),\n\t\t\t\t'publicado'\t\t=> $faker->numberBetween(0,1),\n\t\t\t\t'descripcion'\t=> $faker->text(400),\n\t\t\t\t'autor_id'\t\t=> $faker->numberBetween(1,3),\n\t\t\t\t'categoria_id'\t=> $faker->numberBetween(1,3)\n\n\t\t\t]);\n\t\t}\n\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('libros')->insert($libros);\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 10)->create()->each(function ($user) {\n // Seed the relation with 5 purchases\n // $videos = factory(App\\Video::class, 5)->make();\n // $user->videos()->saveMany($videos);\n // $user->videos()->each(function ($video){\n // \t$video->videometa()->save(factory(App\\VideoMeta::class)->make());\n // \t// :( \n // });\n factory(App\\User::class, 10)->create()->each(function ($user) {\n\t\t\t factory(App\\Video::class, 5)->create(['user_id' => $user->id])->each(function ($video) {\n\t\t\t \tfactory(App\\VideoMeta::class, 1)->create(['video_id' => $video->id]);\n\t\t\t // $video->videometa()->save(factory(App\\VideoMeta::class)->create(['video_id' => $video->id]));\n\t\t\t });\n\t\t\t});\n\n });\n }", "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "public function run()\n {\n $this->call([\n CountryTableSeeder::class,\n ProvinceTableSeeder::class,\n TagTableSeeder::class\n ]);\n\n User::factory()->count(10)->create();\n Category::factory()->count(5)->create();\n Product::factory()->count(20)->create();\n Section::factory()->count(5)->create();\n Bundle::factory()->count(20)->create();\n\n $bundles = Bundle::all();\n // populate bundle-product table (morph many-to-many)\n Product::all()->each(function ($product) use ($bundles) {\n $product->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray(),\n ['default_quantity' => rand(1, 10)]\n );\n });\n // populate bundle-tags table (morph many-to-many)\n Tag::all()->each(function ($tag) use ($bundles) {\n $tag->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray()\n );\n });\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker=Faker\\Factory::create();\n\n for($i=0;$i<100;$i++){\n \tApp\\Blog::create([\n \t\t'title' => $faker->catchPhrase,\n 'description' => $faker->text,\n 'showns' =>true\n \t\t]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(PermissionsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n $this->call(BusinessTableSeeder::class);\n $this->call(PrinterTableSeeder::class);\n factory(App\\Tag::class,10)->create();\n factory(App\\Category::class,10)->create();\n factory(App\\Subcategory::class,50)->create();\n factory(App\\Provider::class,10)->create();\n factory(App\\Product::class,24)->create()->each(function($product){\n\n $product->images()->saveMany(factory(App\\Image::class, 4)->make());\n\n });\n\n\n factory(App\\Client::class,10)->create();\n }", "public function run()\n {\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'name' => $faker->sentence,\n 'sku' => $faker->paragraph,\n 'price' => $faker->number,\n ]);\n }\n }", "public function run()\n {\n Storage::deleteDirectory('public/products');\n Storage::makeDirectory('public/products');\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n $this->call(ProductSeeder::class);\n Order::factory(4)->create();\n Order_Detail::factory(4)->create();\n Size::factory(100)->create();\n }", "public function run()\n {\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Doctor::factory(25)->create();\n Patient::factory(50)->create();\n Status::factory(3)->create();\n Appointment::factory(100)->create();\n }", "public function run()\n\t{\n\t\t\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$faker = \\Faker\\Factory::create();\n\n\t\tTodolist::truncate();\n\n\t\tforeach(range(1, 50) as $index)\n\t\t{\n\n\t\t\t$user = User::create([\n\t\t\t\t'name' => $faker->name,\n\t\t\t\t'email' => $faker->email,\n\t\t\t\t'password' => 'password',\n\t\t\t\t'confirmation_code' => mt_rand(0, 9),\n\t\t\t\t'confirmation' => rand(0,1) == 1\n\t\t\t]);\n\n\t\t\t$list = Todolist::create([\n\t\t\t\t'name' => $faker->sentence(2),\n\t\t\t\t'description' => $faker->sentence(4),\n\t\t\t]);\n\n\t\t\t// BUILD SOME TASKS FOR EACH LIST ITEM\n\t\t\tforeach(range(1, 10) as $index) \n\t\t\t{\n\t\t\t\t$task = new Task;\n\t\t\t\t$task->name = $faker->sentence(2);\n\t\t\t\t$task->description = $faker->sentence(4);\n\t\t\t\t$list->tasks()->save($task);\n\t\t\t}\n\n\t\t}\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1'); \n\n\t}", "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n \\App\\User::create([\n 'name'=>'PAPE SAMBA NDOUR',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('Admin1122'),\n ]);\n\n $faker = Faker::create();\n\n for ($i = 0; $i < 100 ; $i++)\n {\n $firstName = $faker->firstName;\n $lastName = $faker->lastName;\n $niveau = \\App\\Niveau::inRandomOrder()->first();\n \\App\\Etudiant::create([\n 'prenom'=>$firstName,\n 'nom'=>$lastName,\n 'niveau_id'=>$niveau->id\n ]);\n }\n\n\n }", "public function run()\n {\n //\n DB::table('foods')->delete();\n\n Foods::create(array(\n 'name' => 'Chicken Wing',\n 'author' => 'Bambang',\n 'overview' => 'a deep-fried chicken wing, not in spicy sauce'\n ));\n\n Foods::create(array(\n 'name' => 'Beef ribs',\n 'author' => 'Frank',\n 'overview' => 'Slow baked beef ribs rubbed in spices'\n ));\n\n Foods::create(array(\n 'name' => 'Ice cream',\n 'author' => 'Lou',\n 'overview' => ' A sweetened frozen food typically eaten as a snack or dessert.'\n ));\n\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 3)->create();\n factory(App\\Models\\Category::class, 3)\n ->create()\n ->each(function ($u) {\n $u->courses()->saveMany(factory(App\\Models\\Course::class,3)->make())->each(function ($c){\n $c->exams()->saveMany(factory(\\App\\Models\\Exam::class,3)->make())->each(function ($e){\n $e->questions()->saveMany(factory(\\App\\Models\\Question::class,4)->make())->each(function ($q){\n $q->answers()->saveMany(factory(\\App\\Models\\Answer::class,4)->make())->each(function ($a){\n $a->correctAnswer()->save(factory(\\App\\Models\\Correct_answer::class)->make());\n });\n });\n });\n });\n\n });\n\n }", "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n UserSeeder::class,\n ]);\n\n \\App\\Models\\Category::factory(4)->create();\n \\App\\Models\\View::factory(6)->create();\n \\App\\Models\\Room::factory(8)->create();\n \n $rooms = \\App\\Models\\Room::all();\n // \\App\\Models\\User::all()->each(function ($user) use ($rooms) { \n // $user->rooms()->attach(\n // $rooms->random(rand(1, \\App\\Models\\Room::max('id')))->pluck('id')->toArray()\n // ); \n // });\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => '[email protected]']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'[email protected]',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','[email protected]')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => '[email protected]']);\n\n factory(Category::class, 5)->create();\n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n \n User::factory(1)->create([\n 'rol'=>'EPS'\n ]);\n Person::factory(10)->create();\n $this->call(EPSSeeder::class);\n $this->call(OfficialSeeder::class);\n $this->call(VVCSeeder::class);\n $this->call(VaccineSeeder::class);\n }", "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "public function run()\n {\n $this->call([\n LanguagesTableSeeder::class,\n ListingAvailabilitiesTableSeeder::class,\n ListingTypesTableSeeder::class,\n RoomTypesTableSeeder::class,\n AmenitiesTableSeeder::class,\n UsersTableSeeder::class,\n UserLanguagesTableSeeder::class,\n ListingsTableSeeder::class,\n WishlistsTableSeeder::class,\n StaysTableSeeder::class,\n GuestsTableSeeder::class,\n TripsTableSeeder::class,\n ReviewsTableSeeder::class,\n RatingsTableSeeder::class,\n PopularDestinationsTableSeeder::class,\n ImagesTableSeeder::class,\n ]);\n\n // factory(App\\User::class, 5)->states('host')->create();\n // factory(App\\User::class, 10)->states('hostee')->create();\n\n // factory(App\\User::class, 10)->create();\n // factory(App\\Models\\Listing::class, 30)->create();\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "public function run()\n {\n\n $this->call(UserSeeder::class);\n factory(Empresa::class,10)->create();\n factory(Empleado::class,50)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => '[email protected]',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Russell'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Bitfumes'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Paul'\n ]);\n }", "public function run()\n {\n $user_ids = [1,2,3];\n $faker = app(\\Faker\\Generator::class);\n $posts = factory(\\App\\Post::class)->times(50)->make()->each(function($post) use ($user_ids,$faker){\n $post->user_id = $faker->randomElement($user_ids);\n });\n \\App\\Post::insert($posts->toArray());\n }", "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "public function run()\n\t{\n\t\t$this->call(ProductsTableSeeder::class);\n\t\t$this->call(CategoriesTableSeeder::class);\n\t\t$this->call(BrandsTableSeeder::class);\n\t\t$this->call(ColorsTableSeeder::class);\n\n\t\t$products = \\App\\Product::all();\n \t$categories = \\App\\Category::all();\n \t$brands = \\App\\Brand::all();\n \t$colors = \\App\\Color::all();\n\n\t\tforeach ($products as $product) {\n\t\t\t$product->colors()->sync($colors->random(3));\n\n\t\t\t$product->category()->associate($categories->random(1)->first());\n\t\t\t$product->brand()->associate($brands->random(1)->first());\n\n\t\t\t$product->save();\n\t\t}\n\n\t\t// for ($i = 0; $i < count($products); $i++) {\n\t\t// \t$cat = $categories[rand(0,5)];\n\t\t// \t$bra = $brands[rand(0,7)];\n\t\t// \t$cat->products()->save($products[$i]);\n\t\t// \t$bra->products()->save($products[$i]);\n\t\t// }\n\n\t\t// $products = factory(App\\Product::class)->times(20)->create();\n\t\t// $categories = factory(App\\Category::class)->times(6)->create();\n\t\t// $brands = factory(App\\Brand::class)->times(8)->create();\n\t\t// $colors = factory(App\\Color::class)->times(15)->create();\n\t}", "public function run()\n {\n /*$this->call(UsersTableSeeder::class);\n $this->call(GroupsTableSeeder::class);\n $this->call(TopicsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);*/\n DB::table('users')->insert([\n 'name' => 'pkw',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'type' => '1'\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = Faker::create();\n foreach (range(1,200) as $index) {\n DB::table('users')->insert([\n 'name' => $faker->name,\n 'email' => $faker->email,\n 'phone' => $faker->randomDigitNotNull,\n 'address'=> $faker->streetAddress,\n 'password' => bcrypt('secret'),\n ]);\n }\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n echo PHP_EOL , 'seeding roles...';\n\n Role::create(\n [\n 'name' => 'Admin',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Principal',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Teacher',\n 'deletable' => false,\n ]\n );\n\n Role::create(\n [\n 'name' => 'Student',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Parents',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Accountant',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Librarian',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Receptionist',\n 'deletable' => false,\n ]\n );\n\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 5; $i++) {\n Runner::create([\n 'external_id' => $faker->uuid,\n 'name' => $faker->name,\n 'race_id' =>rand(1,5),\n 'age' => rand(30, 45),\n 'sex' => $faker->randomElement(['male', 'female']),\n 'color' => $faker->randomElement(['#ecbcb4', '#d1a3a4']),\n ]);\n }\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "public function run()\n {\n Eloquent::unguard();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // $this->call([\n // CountriesTableSeeder::class,\n // ]);\n\n factory(App\\User::class, 100)->create();\n factory(App\\Type::class, 10)->create();\n factory(App\\Item::class, 100)->create();\n factory(App\\Order::class, 1000)->create();\n\n $items = App\\Item::all();\n\n App\\Order::all()->each(function($order) use ($items) {\n\n $n = rand(1, 10);\n\n $order->items()->attach(\n $items->random($n)->pluck('id')->toArray()\n , ['quantity' => $n]);\n\n $order->total = $order->items->sum(function($item) {\n return $item->price * $item->pivot->quantity;\n });\n\n $order->save();\n\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'izzanni',\n \n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'aina',\n\n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'sab',\n\n ]\n );\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n //Acá se define lo que el seeder va a hacer.\n //insert() para insertar datos.\n //Array asociativo. La llave es el nombre de la columna.\n// DB::table('users')->insert([\n// //Para un solo usuario.\n// 'name' => 'Pedrito Perez',\n// 'email' => '[email protected]',\n// 'password' => bcrypt('123456')\n// ]);//Se indica el nombre de la tabla.\n\n //Crea 50 usuarios (sin probar)\n// factory(App\\User::class, 50)->create()->each(function($u) {\n// $u->posts()->save(factory(App\\Post::class)->make());\n// });\n\n factory(App\\User::class, 10)->create(); //Así se ejecuta el model factory creado en ModelFactory.php\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n //nhập liệu mẫu cho bảng users\n DB::table('users')->insert([\n \t['id'=>'1001', 'name'=>'Phan Thị Hiền', 'email'=>'[email protected]', 'password'=>'123456', 'isadmin'=>1],\n \t['id'=>'1002', 'name'=>'Phan Thị Hà', 'email'=>'[email protected]', 'password'=>'111111', 'isadmin'=>0]\n ]);\n\n\n //nhập liệu mẫu cho bảng suppliers\n DB::table('suppliers')->insert([\n \t['name'=>'FPT', 'address'=>'151 Hùng Vương, TP. Đà Nẵng', 'phonenum'=>'0971455395'],\n \t['name'=>'Điện Máy Xanh', 'address'=>'169 Phan Châu Trinh, TP. Đà Nẵng', 'phonenum'=>'0379456011']\n ]);\n\n\n //Bảng phiếu bảo hành\n }", "public function run()\n {\n \t// DB::table('categories')->truncate();\n // factory(App\\Models\\Category::class, 10)->create();\n Schema::disableForeignKeyConstraints();\n Category::truncate();\n $faker = Faker\\Factory::create();\n\n $categories = ['SAMSUNG','NOKIA','APPLE','BLACK BERRY'];\n foreach ($categories as $key => $value) {\n Category::create([\n 'name'=>$value,\n 'description'=> 'This is '.$value,\n 'markup'=> rand(10,100),\n 'category_id'=> null,\n 'UUID' => $faker->uuid,\n ]);\n }\n }" ]
[ "0.8013876", "0.79804534", "0.7976992", "0.79542726", "0.79511505", "0.7949612", "0.794459", "0.7942486", "0.7938189", "0.79368967", "0.79337025", "0.78924936", "0.78811055", "0.78790957", "0.78787595", "0.787547", "0.7871811", "0.78701615", "0.7851422", "0.7850352", "0.7841468", "0.7834583", "0.7827792", "0.7819104", "0.78088796", "0.7802872", "0.7802348", "0.78006834", "0.77989215", "0.7795819", "0.77903426", "0.77884805", "0.77862066", "0.7778816", "0.7777486", "0.7765202", "0.7762492", "0.77623445", "0.77621746", "0.7761383", "0.77606887", "0.77596676", "0.7757001", "0.7753607", "0.7749522", "0.7749292", "0.77466977", "0.7729947", "0.77289546", "0.772796", "0.77167094", "0.7714503", "0.77140456", "0.77132195", "0.771243", "0.77122366", "0.7711113", "0.77109736", "0.7710777", "0.7710086", "0.7705484", "0.770464", "0.7704354", "0.7704061", "0.77027386", "0.77020216", "0.77008796", "0.7698617", "0.76985973", "0.76973504", "0.7696405", "0.7694293", "0.7692694", "0.7691264", "0.7690576", "0.76882726", "0.7687433", "0.7686844", "0.7686498", "0.7685065", "0.7683827", "0.7679184", "0.7678287", "0.76776296", "0.76767945", "0.76726556", "0.76708084", "0.76690495", "0.766872", "0.76686716", "0.7666299", "0.76625943", "0.7662227", "0.76613766", "0.7659881", "0.7656644", "0.76539344", "0.76535016", "0.7652375", "0.7652313", "0.7652022" ]
0.0
-1
Add a [oxy_soundcloud] shortcode to WordPress
function add_shortcode( $atts, $content = null, $name = null ) { if ( ! $this->validate_shortcode( $atts, $content, $name ) ) { return ''; } $options = $this->set_options( $atts ); ob_start(); ?><div id="<?php echo esc_attr($options['selector']); ?>" class="<?php echo esc_attr($options['classes']); ?>" <?php do_action("oxygen_vsb_component_attr", $options, $this->options['tag']); ?>><iframe scrolling="no" frameborder="no" src="https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/tracks/<?php echo $options["soundcloud_track_id"]; ?>&amp;color=<?php echo urlencode($options["soundcloud_color"]); ?>&amp;auto_play=<?php echo urlencode($options["soundcloud_auto_play"]); ?>&amp;hide_related=<?php echo urlencode($options["soundcloud_hide_related"]); ?>&amp;show_comments=<?php echo urlencode($options["soundcloud_show_comments"]); ?>&amp;show_user=true&amp;show_reposts=false&amp;show_teaser=true&amp;visual=true"></iframe></div><?php return ob_get_clean(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function add_oembed_soundcloud(){\n\twp_oembed_add_provider( 'http://soundcloud.com/*', 'http://soundcloud.com/oembed' );\n}", "function sp_soundcloud($url , $autoplay = 'false' ) {\n\treturn '<iframe width=\"100%\" height=\"166\" scrolling=\"no\" frameborder=\"no\" src=\"https://w.soundcloud.com/player/?url='.$url.'&amp;auto_play='.$autoplay.'&amp;show_artwork=true\"></iframe>';\n}", "function track_shortcode($atts, $content=null){\n\textract(shortcode_atts(array(\n\t\t'kind' => '',\n\t\t'src' => '',\n\t\t'srclang' => '',\n\t\t'label' => '',\n\t\t'default' => ''\n\t), $atts));\n\t\n\tif($kind)\n\t\t$kind = \" kind='\" . $kind . \"'\";\n\t\n\tif($src)\n\t\t$src = \" src='\" . $src . \"'\";\n\t\n\tif($srclang)\n\t\t$srclang = \" srclang='\" . $srclang . \"'\";\n\t\n\tif($label)\n\t\t$label = \" label='\" . $label . \"'\";\n\t\n\tif($default == \"true\" || $default == \"default\")\n\t\t$default = \" default\";\n\telse\n\t\t$default = \"\";\n\t\n\t$track = \"\n\t\t<track\" . $kind . $src . $srclang . $label . $default . \" />\n\t\";\n\t\n\treturn $track;\n}", "function lapindos_tag_cloud($content=\"\"){\r\n\r\n $pattern = get_shortcode_regex(array('tags'));\r\n $content = preg_replace_callback( '/' . $pattern . '/s',\r\n\r\n create_function('$matches', '\r\n \r\n\t $atts = shortcode_parse_atts( $matches[3] );\r\n\r\n\t\t$type = \\'WP_Widget_Tag_Cloud\\';\r\n\t\t$args = array(\r\n\t\t\t\\'before_widget\\' => \\'<div class=\"widget widget_tag_cloud\">\\',\r\n\t\t\t\\'after_widget\\' => \\'</div>\\',\r\n\t\t\t\\'before_title\\' => \\'<div class=\"widget-title\">\\',\r\n\t\t\t\\'after_title\\' => \\'</div>\\'\r\n\t\t\t);\r\n\r\n\t\tob_start();\r\n\t\tthe_widget( $type, $atts, $args );\r\n\t\t$content = ob_get_clean();\r\n\r\n\t return $content;\r\n '),\r\n $content);\r\n\r\n return $content;\r\n}", "function full_soundcloud_player($link, $title, $soundcloud_color = \"\") {\n\techo '<div class=\"full-width-soundcloud\" data-sc-color=\"' . $soundcloud_color . '\"><a href=\"' . $link . '\" class=\"sc-player\">' . $title . '</a></div>';\n}", "function audio_logger_shortcode($atts = [], $content = null){\n\n ob_start();\n\n\n require_once(plugin_dir_path(__FILE__) . '/audio-logger-scripts.php');\n\n $output = ob_get_clean();\n $run_shortcodes = do_shortcode($output);\n return $run_shortcodes;\n}", "function sp_audio_sc( $atts ) {\n\n\textract( shortcode_atts( array(\n\t\t'mp3' => '',\n\t\t'ogg' => '',\n\t\t'width' => '',\n\t\t'height' => '',\n\t\t'preload' => false,\n\t\t'autoplay' => false,\n\t), $atts ) );\n\n\tglobal $post;\n\n\tif ( $mp3 )\n\t\t$mp3 = '<source src=\"' . $mp3 . '\" type=\"audio/mp3\" />';\n\n\tif ( $ogg )\n\t\t$ogg = '<source src=\"' . $ogg . '\" type=\"audio/ogg\" />';\n\n\tif ( $preload )\n\t\t$preload = 'preload=\"' . $preload . '\"';\n\n\tif ( $autoplay )\n\t\t$autoplay = 'autoplay';\n\n\t$output = \"<audio id='AudioPlayerV1-id-$post->ID' class='AudioPlayerV1' width='100%' height='29' controls {$preload} {$autoplay} data-fallback='\" . SP_BASE_URL . \"js/audioplayerv1.swf'>\n\t\t\t\t\t{$mp3}\n\t\t\t\t\t{$ogg}\n\t\t\t\t</audio>\";\n\n\treturn $output;\n\n}", "function vicuna_widget_tag_cloud($args) {\n\textract($args);\n\t$options = get_option('widget_tag_cloud');\n\t$title = empty($options['title']) ? __('Tag Cloud', 'vicuna') : $options['title'];\n\n\techo $before_widget;\n\techo $before_title . $title . $after_title;\n\tvicuna_tag_cloud();\n\techo $after_widget;\n}", "public function wpdocs_add_custom_shortcode() {\n\t\t\tadd_shortcode( 'fitts_quiz', array( $this, 'fitts_plugin_shortcode' ) );\n\t\t}", "function audio_shortcode_infinite() {\n\t\t// only try to load if a shortcode has been called\n\t\tif( self::$add_script ) {\n\t\t\t$script_url = json_encode( esc_url_raw( plugins_url( 'js/audio-shortcode.js', __FILE__ ) ) );\n\n\t\t\t// if the script hasn't been loaded, load it\n\t\t\t// if the script loads successfully, fire an 'as-script-load' event\n\t\t\techo <<<SCRIPT\n\t\t\t\t<script type='text/javascript'>\n\t\t\t\t//<![CDATA[\n\t\t\t\tif ( typeof window.audioshortcode === 'undefined' ) {\n\t\t\t\t\tvar wp_as_js = document.createElement( 'script' );\n\t\t\t\t\twp_as_js.type = 'text/javascript';\n\t\t\t\t\twp_as_js.src = $script_url;\n\t\t\t\t\twp_as_js.async = true;\n\t\t\t\t\twp_as_js.onload = function() {\n\t\t\t\t\t\tjQuery( document.body ).trigger( 'as-script-load' );\n\t\t\t\t\t};\n\t\t\t\t\tdocument.getElementsByTagName( 'head' )[0].appendChild( wp_as_js );\n\t\t\t\t} else {\n\t\t\t\t\tjQuery( document.body ).trigger( 'as-script-load' );\n\t\t\t\t}\n\t\t\t\t//]]>\n\t\t\t\t</script>\nSCRIPT;\n\t\t}\n\t}", "function audio_shortcode( $atts ) {\n\t\tglobal $ap_playerID;\n\t\tglobal $post;\n\t\tif ( ! is_array( $atts ) ) {\n\t\t\treturn '<!-- Audio shortcode passed invalid attributes -->';\n\t\t}\n\n\t\tif ( ! isset( $atts[0] ) ) {\n\t\t\tif ( isset( $atts['src'] ) ) {\n\t\t\t\t$atts[0] = $atts['src'];\n\t\t\t\tunset( $atts['src'] );\n\t\t\t} else {\n\t\t\t\treturn '<!-- Audio shortcode source not set -->';\n\t\t\t}\n\t\t}\n\n\t\t// add the special .js\n\t\twp_enqueue_script(\n\t\t\t'audio-shortcode',\n\t\t\tplugins_url( 'js/audio-shortcode.js', __FILE__ ),\n\t\t\tarray( 'jquery' ),\n\t\t\t'1.1',\n\t\t\ttrue);\n\n\t\t// alert the infinite scroll renderer that it should try to load the script\n\t\tself::$add_script = true;\n\t\t$atts[0] = strip_tags( join( ' ', $atts ) );\n\t\t$src = ltrim( $atts[0], '=' );\n\t\t$ap_options = apply_filters(\n\t\t\t'audio_player_default_colors',\n\t\t\tarray(\n\t\t\t\t\"bg\" => \"0xF8F8F8\",\n\t\t\t\t\"leftbg\" => \"0xEEEEEE\",\n\t\t\t\t\"lefticon\" => \"0x666666\",\n\t\t\t\t\"rightbg\" => \"0xCCCCCC\",\n\t\t\t\t\"rightbghover\" => \"0x999999\",\n\t\t\t\t\"righticon\" => \"0x666666\",\n\t\t\t\t\"righticonhover\" => \"0xFFFFFF\",\n\t\t\t\t\"text\" => \"0x666666\",\n\t\t\t\t\"slider\" => \"0x666666\",\n\t\t\t\t\"track\" => \"0xFFFFFF\",\n\t\t\t\t\"border\" => \"0x666666\",\n\t\t\t\t\"loader\" => \"0x9FFFB8\"\n\t\t\t) );\n\n\t\tif ( ! isset( $ap_playerID ) ) {\n\t\t\t$ap_playerID = 1;\n\t\t} else {\n\t\t\t$ap_playerID++;\n\t\t}\n\n\t\tif ( ! isset( $load_audio_script ) ) {\n\t\t\t$load_audio_script = true;\n\t\t}\n\n\t\t// prep the audio files\n\t\t$src = trim( $src, ' \"' );\n\t\t$options = array();\n\t\t$data = preg_split( \"/\\|/\", $src );\n\t\t$sound_file = $data[0];\n\t\t$sound_files = explode( ',', $sound_file );\n\n\t\tif ( is_ssl() ) {\n\t\t\tfor ( $i = 0; $i < count( $sound_files ); $i++ ) {\n\t\t\t\t$sound_files[ $i ] = preg_replace( '#^http://([^.]+).files.wordpress.com/#', 'https://$1.files.wordpress.com/', $sound_files[ $i ] );\n\t\t\t}\n\t\t}\n\n\t\t$sound_files = array_map( 'trim', $sound_files );\n\t\t$sound_files = array_map( array( $this, 'rawurlencode_spaces' ), $sound_files );\n\t\t$sound_files = array_map( 'esc_url_raw', $sound_files ); // Ensure each is a valid URL\n\t\t$num_files = count( $sound_files );\n\t\t$sound_types = array(\n\t\t\t'mp3' => 'mpeg',\n\t\t\t'wav' => 'wav',\n\t\t\t'ogg' => 'ogg',\n\t\t\t'oga' => 'ogg',\n\t\t\t'm4a' => 'mp4',\n\t\t\t'aac' => 'mp4',\n\t\t\t'webm' => 'webm'\n\t\t);\n\n\t\tfor ( $i = 1; $i < count( $data ); $i++ ) {\n\t\t\t$pair = explode( \"=\", $data[$i] );\n\t\t\tif ( strtolower( $pair[0] ) != 'autostart' ) {\n\t\t\t\t$options[$pair[0]] = $pair[1];\n\t\t\t}\n\t\t}\n\n\t\t// Merge runtime options to default colour options\n\t\t// (runtime options overwrite default options)\n\t\tforeach ( $ap_options as $key => $default ) {\n\t\t\tif ( isset( $options[$key] ) ) {\n\t\t\t\tif ( preg_match( '/^(0x)?[a-f0-9]{6}$/i', $default ) && !preg_match( '/^(0x)?[a-f0-9]{6}$/i', $options[$key] ) ) {\n\t\t\t\t\t// Default is a hex color, but input is not\n\t\t\t\t\t$options[$key] = $default;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$options[$key] = $default;\n\t\t\t}\n\t\t}\n\t\t$options['soundFile'] = join( ',', $sound_files ); // Rebuild the option with our now sanitized data\n\t\t$flash_vars = array();\n\t\tforeach ( $options as $key => $value ) {\n\t\t\t$flash_vars[] = rawurlencode( $key ) . '=' . rawurlencode( $value );\n\t\t}\n\t\t$flash_vars = implode( '&amp;', $flash_vars );\n\t\t$flash_vars = esc_attr( $flash_vars );\n\n\t\t// extract some of the options to insert into the markup\n\t\tif ( isset( $options['bgcolor'] ) && preg_match( '/^(0x)?[a-f0-9]{6}$/i', $options['bgcolor'] ) ) {\n\t\t\t$bgcolor = preg_replace( '/^(0x)?/', '#', $options['bgcolor'] );\n\t\t\t$bgcolor = esc_attr( $bgcolor );\n\t\t} else {\n\t\t\t$bgcolor = '#FFFFFF';\n\t\t}\n\n\t\tif ( isset( $options['width'] ) ) {\n\t\t\t$width = intval( $options['width'] );\n\t\t} else {\n\t\t\t$width = 290;\n\t\t}\n\n\t\t$loop = '';\n\t\t$script_loop = 'false';\n\t\tif ( isset( $options['loop'] ) && 'yes' == $options['loop'] ) {\n\t\t\t$script_loop = 'true';\n\t\t\tif ( 1 == $num_files ) {\n\t\t\t\t$loop = 'loop';\n\t\t\t}\n\t\t}\n\n\t\t$volume = 0.6;\n\t\tif ( isset( $options['initialvolume'] ) &&\n\t\t\t\t0.0 < floatval( $options['initialvolume'] ) &&\n\t\t\t\t100.0 >= floatval( $options['initialvolume'] ) ) {\n\n\t\t\t$volume = floatval( $options['initialvolume'] )/100.0;\n\t\t}\n\n\t\t$file_artists = array_pad( array(), $num_files, '' );\n\t\tif ( isset( $options['artists'] ) ) {\n\t\t\t$artists = preg_split( '/,/', $options['artists'] );\n\t\t\tforeach ( $artists as $i => $artist ) {\n\t\t\t\t$file_artists[$i] = esc_html( $artist ) . ' - ';\n\t\t\t}\n\t\t}\n\n\t\t// generate default titles\n\t\t$file_titles = array();\n\t\tfor ( $i = 0; $i < $num_files; $i++ ) {\n\t\t\t$file_titles[] = 'Track #' . ($i+1);\n\t\t}\n\n\t\t// replace with real titles if they exist\n\t\tif ( isset( $options['titles'] ) ) {\n\t\t\t$titles = preg_split( '/,/', $options['titles'] );\n\t\t\tforeach ( $titles as $i => $title ) {\n\t\t\t\t$file_titles[$i] = esc_html( $title );\n\t\t\t}\n\t\t}\n\n\t\t// fallback for the fallback, just a download link\n\t\t$not_supported = '';\n\t\tforeach ( $sound_files as $sfile ) {\n\t\t\t$not_supported .= sprintf(\n\t\t\t\t__( 'Download: <a href=\"%s\">%s</a><br />', 'jetpack' ),\n\t\t\t\tesc_url( $sfile ),\n\t\t\t\tesc_html( basename( $sfile ) ) );\n\t\t}\n\n\t\t// HTML5 audio tag\n\t\t$html5_audio = '';\n\t\t$all_mp3 = true;\n\t\t$add_audio = true;\n\t\t$num_good = 0;\n\t\t$to_remove = array();\n\t\tforeach ( $sound_files as $i => $sfile ) {\n\t\t\t$file_extension = pathinfo( $sfile, PATHINFO_EXTENSION );\n\t\t\tif ( ! preg_match( '/^(mp3|wav|ogg|oga|m4a|aac|webm)$/i', $file_extension ) ) {\n\t\t\t\t$html5_audio .= '<!-- Audio shortcode unsupported audio format -->';\n\t\t\t\tif ( 1 == $num_files ) {\n\t\t\t\t\t$html5_audio .= $not_supported;\n\t\t\t\t}\n\n\t\t\t\t$to_remove[] = $i; // make a note of the bad files\n\t\t\t\t$all_mp3 = false;\n\t\t\t\tcontinue;\n\t\t\t} elseif ( ! preg_match( '/^mp3$/i', $file_extension ) ) {\n\t\t\t\t$all_mp3 = false;\n\t\t\t}\n\n\t\t\tif ( 0 == $i ) { // only need one player\n\t\t\t\t$html5_audio .= <<<AUDIO\n\t\t\t\t<span id=\"wp-as-{$post->ID}_{$ap_playerID}-container\">\n\t\t\t\t\t<audio id='wp-as-{$post->ID}_{$ap_playerID}' controls preload='none' $loop style='background-color:$bgcolor;width:{$width}px;'>\n\t\t\t\t\t\t<span id=\"wp-as-{$post->ID}_{$ap_playerID}-nope\">$not_supported</span>\n\t\t\t\t\t</audio>\n\t\t\t\t</span>\n\t\t\t\t<br />\nAUDIO;\n\t\t\t}\n\t\t\t$num_good++;\n\t\t}\n\n\t\t// player controls, if needed\n\t\tif ( 1 < $num_files ) {\n\t\t\t$html5_audio .= <<<CONTROLS\n\t\t\t\t<span id='wp-as-{$post->ID}_{$ap_playerID}-controls' style='display:none;'>\n\t\t\t\t\t<a id='wp-as-{$post->ID}_{$ap_playerID}-prev'\n\t\t\t\t\t\thref='javascript:audioshortcode.prev_track( \"{$post->ID}_{$ap_playerID}\" );'\n\t\t\t\t\t\tstyle='font-size:1.5em;'>&laquo;</a>\n\t\t\t\t\t|\n\t\t\t\t\t<a id='wp-as-{$post->ID}_{$ap_playerID}-next'\n\t\t\t\t\t\thref='javascript:audioshortcode.next_track( \"{$post->ID}_{$ap_playerID}\", true, $script_loop );'\n\t\t\t\t\t\tstyle='font-size:1.5em;'>&raquo;</a>\n\t\t\t\t</span>\nCONTROLS;\n\t\t}\n\t\t$html5_audio .= \"<span id='wp-as-{$post->ID}_{$ap_playerID}-playing'></span>\";\n\n\t\tif ( is_ssl() )\n\t\t\t$protocol = 'https';\n\t\telse\n\t\t\t$protocol = 'http';\n\n\t\t$swfurl = apply_filters(\n\t\t\t'jetpack_static_url',\n\t\t\t\"$protocol://en.wordpress.com/wp-content/plugins/audio-player/player.swf\" );\n\n\t\t// all the fancy javascript is causing Google Reader to break, just include flash in GReader\n\t\t// override html5 audio code w/ just not supported code\n\t\tif ( is_feed() ) {\n\t\t\t$html5_audio = $not_supported;\n\t\t}\n\n\t\tif ( $all_mp3 ) {\n\t\t\t// process regular flash player, inserting HTML5 tags into object as fallback\n\t\t\t$audio_tags = <<<FLASH\n\t\t\t\t<object id='wp-as-{$post->ID}_{$ap_playerID}-flash' type='application/x-shockwave-flash' data='$swfurl' width='$width' height='24'>\n\t\t\t\t\t<param name='movie' value='$swfurl' />\n\t\t\t\t\t<param name='FlashVars' value='{$flash_vars}' />\n\t\t\t\t\t<param name='quality' value='high' />\n\t\t\t\t\t<param name='menu' value='false' />\n\t\t\t\t\t<param name='bgcolor' value='$bgcolor' />\n\t\t\t\t\t<param name='wmode' value='opaque' />\n\t\t\t\t\t$html5_audio\n\t\t\t\t</object>\nFLASH;\n\t\t} else { // just HTML5 for non-mp3 versions\n\t\t\t$audio_tags = $html5_audio;\n\t\t}\n\n\t\t// strip out all the bad files before it reaches .js\n\t\tforeach ( $to_remove as $i ) {\n\t\t\tarray_splice( $sound_files, $i, 1 );\n\t\t\tarray_splice( $file_artists, $i, 1 );\n\t\t\tarray_splice( $file_titles, $i, 1 );\n\t\t}\n\n\t\t// mashup the artist/titles for the script\n\t\t$script_titles = array();\n\t\tfor ( $i = 0; $i < $num_files; $i++ ) {\n\t\t\t$script_titles[] = $file_artists[$i] . $file_titles[$i];\n\n\t\t}\n\n\t\t// javacript to control audio\n\t\t$script_files = json_encode( $sound_files );\n\t\t$script_titles = json_encode( $script_titles );\n\t\t$script = <<<SCRIPT\n\t\t\t<script type='text/javascript'>\n\t\t\t//<![CDATA[\n\t\t\t(function() {\n\t\t\t\tvar prep = function() {\n\t\t\t\t\tif ( 'undefined' === typeof window.audioshortcode ) { return; }\n\t\t\t\t\taudioshortcode.prep(\n\t\t\t\t\t\t'{$post->ID}_{$ap_playerID}',\n\t\t\t\t\t\t$script_files,\n\t\t\t\t\t\t$script_titles,\n\t\t\t\t\t\t$volume,\n\t\t\t\t\t\t$script_loop\n\t\t\t\t\t);\n\t\t\t\t};\n\t\t\t\tif ( 'undefined' === typeof jQuery ) {\n\t\t\t\t\tif ( document.addEventListener ) {\n\t\t\t\t\t\twindow.addEventListener( 'load', prep, false );\n\t\t\t\t\t} else if ( document.attachEvent ) {\n\t\t\t\t\t\twindow.attachEvent( 'onload', prep );\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tjQuery(document).on( 'ready as-script-load', prep );\n\t\t\t\t}\n\t\t\t})();\n\t\t\t//]]>\n\t\t\t</script>\nSCRIPT;\n\n\t\t// add the special javascript, if needed\n\t\tif ( 0 < $num_good && ! is_feed() ) {\n\t\t\t$audio_tags .= $script;\n\t\t}\n\n\t\treturn \"<span style='text-align:left;display:block;'><p>$audio_tags</p></span>\";\n\t}", "function html5_shortcode_demo( $atts, $content = null ) {\n return '<div class=\"shortcode-demo\">' . do_shortcode( $content ) . '</div>'; // do_shortcode allows for nested Shortcodes\n}", "function opening_times_media_sample_shortcode( $atts, $content = null ) {\n $atts = shortcode_atts( array(\n\t\t'class' => '',\n\t\t'id' => '',\n 'media' => '',\n 'position' => 'bottom',\n\t), $atts, 'sample' );\n \n $return = '<span';\n \n $attributes = array( 'class', 'id' );\n $data_attributes = array( 'media', 'position' );\n \n foreach ( $attributes as $attribute ) {\n if ( !empty( $atts[$attribute] ) ) {\n $return .= ' ' . $attribute . '=\\''. esc_attr( $atts[$attribute] ) .'\\'';\n }\n }\n \n foreach ( $data_attributes as $data_attribute ) {\n if ( ! empty( $atts[$data_attribute] ) ) {\n $return .= ' data-' . $data_attribute . '=\"'. esc_html( $atts[$data_attribute] ) .'\"';\n }\n }\n \n $return .= '>' . $content . '</span>';\n \n return $return;\n}", "function html5_shortcode_demo($atts, $content = null)\n{\n return '<div class=\"shortcode-demo\">' . do_shortcode($content) . '</div>'; // do_shortcode allows for nested Shortcodes\n}", "function mp3_func( $atts ) {\n $a = shortcode_atts( array(\n 0 => 'http://missing'\n ), $atts );\n\n\t$mp3url = str_replace(\"www.dropbox\", \"dl.dropbox\", str_replace(\"?dl=0\", \"?\", $a[0]));\n return \"<audio controls style='width: 100%'><source src='{$mp3url}' type='audio/mpeg'>Your browser does not support the audio element.</audio>\";\n}", "function initialize_shortcode() {\n\tif ( ! ( shortcode_exists( shortcode_slug ) ) ) {\n\t\tadd_shortcode( shortcode_slug, __NAMESPACE__ . '\\\\replacement' );\n\t}\n}", "function podigee_player( $atts ) {\n\n\t// Attributes\n\t$atts = shortcode_atts(\n\t\tarray(\n\t\t\t'url' => '',\n\t\t),\n\t\t$atts\n\t);\n\n\treturn '<script class=\"podigee-podcast-player\" src=\"https://cdn.podigee.com/podcast-player/javascripts/podigee-podcast-player.js\" data-configuration=\"' . $atts['url'] . '/embed?context=external\"></script>';\n\n}", "function THEME_QuickTags() {\n if ( ! wp_script_is('quicktags') )\n return;\n ?>\n <script type=\"text/javascript\">\n QTags.addButton( 'embed_tag', 'embed', '<embed>', '</embed>', 'o', 'Make Embed Tag', 777 );\n </script>\n\n <script type=\"text/javascript\">\n QTags.addButton( 'spoiler_tag', 'spoiler', '<div class=\"spoiler Spoiler\"><div class=\"spoiler_head ToggleSpoiler\"><span class=\"spoiler_title\">Click for spoiler</span><span class=\"nice_svg tiny\"><svg><use href=\"#arrow_down\"></use></svg></span></div><div class=\"spoiler_content\">', '</div><div class=\"spoiler_footer click_able ToggleSpoiler\"><span class=\"nice_svg small\"><svg><use href=\"#arrow_down\"></use></svg></span></div></div>', 'o', 'Make Embed Tag', 777 );\n </script>\n <?php\n}", "function quasar_call_portfolio_shortcode($atts=null){\n\t\tif(!$atts) return;\n\t\t\n\t\tif(!function_exists('rockthemes_make_swiperslider_shortcode') && $atts['use_swiper_for_thumbnails'] === 'true'){\n\t\t\t$atts['use_swiper_for_thumbnails'] = 'false';\n\t\t}\n\t\t\n\t\tif(function_exists('rockthemes_shortcode_make_portfolio')){\n\t\t\techo rockthemes_shortcode_make_portfolio($atts);\n\t\t}\n\t\t\n\t\treturn;\n\t}", "function generate_fake_shortcode($args) {\n\t\treturn str_replace('tw-slider','gallery',$this->generate_shortcode($args));\n\t}", "function soundcloud_player($link, $title) {\n\techo '<a href=\"' . $link . '\" class=\"sc-player\">' . $title . '</a>';\n}", "function add_shortcode( $atts, $content, $name ) {\n\n\t\tif ( ! $this->validate_shortcode( $atts, $content, $name ) ) {\n return '';\n }\n\n\t\t$options = $this->set_options( $atts );\n\n\t\tob_start();\n\n\t\t?><div id=\"<?php echo esc_attr($options['selector']); ?>\" class=\"<?php if(isset($options['classes'])) echo esc_attr($options['classes']); ?>\" <?php do_action(\"oxygen_vsb_component_attr\", $options, $this->options['tag']); ?>><?php echo do_shortcode( $content ); ?></div><?php\n\n\t\treturn ob_get_clean();\n\t}", "function add_shortcode($tag, $callback)\n {\n }", "public function render($atts, $content = null) {\n $default_atts = array(\n 'playlist_type' => 'sound-cloud',\n 'playlist_url' => '',\n 'playlist_skin' => '',\n 'playlist_id' => '',\n 'playlist_color' => ''\n );\n\n $params = shortcode_atts($default_atts, $atts);\n $playlist_type = $params['playlist_type'];\n $playlist_id = $params['playlist_id'];\n $playlist_color = $params['playlist_color'];\n $playlist_skin = $params['playlist_skin'];\n $playlist_url = $params['playlist_url'];\n\n if ($playlist_type == \"sound-cloud\") {\n $playlist_id_url = \"https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/playlists/\";\n if ($playlist_id !== '') {\n $playlist_id_url .= $playlist_id;\n }\n if ($playlist_color !== '') {\n $playlist_color = substr($playlist_color, 1);\n $playlist_id_url .= \"&amp;color=\".$playlist_color;\n }\n\n $params['playlist_id_url'] = $playlist_id_url;\n }\n\n\n if ($playlist_type == \"spotify\") {\n if ($playlist_skin == \"light\"){\n $playlist_url .= \"&theme=white\";\n $params['playlist_url'] = $playlist_url;\n }\n }\n\n if ($playlist_type == \"bandcamp\") {\n $playlist_id_url = \"https://bandcamp.com/EmbeddedPlayer/album=\";\n if ($playlist_id !== '') {\n $playlist_id_url .= $playlist_id;\n }\n if ($playlist_skin == \"light\"){\n $playlist_id_url .= \"/bgcol=ffffff\";\n }\n else {\n $playlist_id_url .= \"/bgcol=333333\";\n }\n\n $playlist_id_url .= \"/size=large\";\n\n if ($playlist_color !== '') {\n $playlist_color = substr($playlist_color, 1);\n $playlist_id_url .= \"/linkcol=\".$playlist_color;\n }\n\n $params['playlist_id_url'] = $playlist_id_url.\"/artwork=small/transparent=true/\";\n }\n\n return mixtape_qodef_get_shortcode_module_template_part('templates/'.$playlist_type.'-playlist-template', 'audio-playlist', '', $params);\n }", "function shortcode_insert_button()\n {\n $this->config['name']\t\t\t= __('Carousel With Thumbnails', 'swedenWp' );\n $this->config['tab']\t\t\t= __('Content Elements', 'swedenWp' );\n $this->config['icon']\t\t\t= swedenBuilder::$path['imagesURL'].\"sc-postslider.png\";\n $this->config['order']\t\t\t= 2;\n $this->config['target']\t\t\t= 'avia-target-insert';\n $this->config['shortcode'] \t\t= 'sw_thumb_nav_carousel';\n $this->config['shortcode_nested'] = array('sw_thumb_carousel_slide');\n $this->config['tooltip'] \t = __('Display a carousel element with thumb navigation', 'swedenWp' );\n }", "function bandcamp_embed($atts) {\n extract(shortcode_atts(array(\n 'albumid' => '',\n 'trackid' => '',\n 'id' => '',\n 'link' => '',\n 'title' => '',\n ), $atts));\n\n // Is it a track?\n if (! $trackid) {\n $trackid = get_post_custom_values('trackid')[0];\n }\n if ($trackid) {\n $albumid = $trackid;\n $type = 'track';\n } else {\n $type = 'album';\n }\n\n // Try to get id from alternate attribute\n if (! $albumid) {\n $albumid = $id;\n }\n\n // Try to get values from custom fields\n if (! $albumid) {\n $albumid = get_post_custom_values('albumid')[0];\n }\n if (! $link) {\n $link = get_post_custom_values('albumlink')[0];\n }\n if (! $title) {\n $title = get_post_custom_values('albumalt')[0];\n }\n\n ob_start();\n require('parts/embed.php');\n return ob_get_clean();\n}", "function shortcode ( $content ) {\n return short_code ( $content );\n}", "function crumble_stdDrop($atts, $content = null) {\r\n\treturn '<span class=\"dropcap\">' . do_shortcode ( $content ) . '</span>';\r\n}", "function wpaddons_shortcode( $atts ) {\n\n\t// Register and enqueues styles\n\tadd_action( 'wp_enqueue_scripts', array( 'WP_Addons_IO', 'enqueue_styles' ) );\n\n\t$atts = shortcode_atts(\n\t\tarray(\n\t\t\t'debug_mode' => 0,\n\t\t\t'plugin' => '',\n\t\t\t'view' => 'cover-grid-third',\n\t\t),\n\t\t$atts,\n\t\t'wpaddons'\n\t);\n\n\t// Load wpAddons SDK\n\t//require_once plugin_dir_path( __FILE__ ) . '/wpaddons-io-sdk/wpaddons-io-sdk.php';\n\n\t// Set addon parameters\n\t$plugin_data = array(\n\t\t'parant_plugin_slug' => $atts['plugin'],\n\t\t'view' => plugin_dir_path( __FILE__ ) . 'wpaddons-io-sdk/view/' . $atts['view'] . '.php',\n\t);\n\n\t// Initiate addons\n\tnew WP_Addons_IO( $plugin_data );\n\n}", "function sparkplug( $args = array() ) {\n\tif ( !isset( $args['before'] ) )\n\t\t$args['before'] = '';\n\tif ( !isset( $args['after'] ) )\n\t\t$args['after'] = '';\n\twidget_sparkplug( $args );\n}", "function add_shortcode( $atts, $content, $name ) {\n\n\t\tif (! $this->validate_shortcode( $atts, $content, $name ) ) {\n return '';\n }\n\n\t\t$options = $this->set_options( $atts );\n\n\t\tob_start();\n\n\t\tif ( is_active_sidebar( $options[\"sidebar_id\"] ) ) {\n\t\t\tdynamic_sidebar( $options[\"sidebar_id\"] );\n\t\t}\n\t\telse {\n\t\t\techo \"No active \\\"\".$options[\"sidebar_id\"].\"\\\" sidebar\";\n\t\t}\n\n\t\treturn ob_get_clean();\n\t}", "function enhance_wp_tag_cloud($content) {\r\n\treturn '<p align=\"center\">' . $content . '</p>';\r\n}", "function sp_one_third_sc( $atts, $content = null ) {\n\n\t\treturn '<div class=\"one-third\">' . do_shortcode( $content ) . '</div>';\n\n\t}", "function sp_one_third_sc( $atts, $content = null ) {\n\n\t\treturn '<div class=\"one_third\">' . do_shortcode( $content ) . '</div>';\n\n\t}", "function flex_video_shortcode($atts, $content = NULL) {\n $a = shortcode_atts( array(\n 'aspect' => ''\n ), $atts );\n $aspect = ($a['aspect'] == 'standard') ? '' : 'widescreen';\n $content = '<div class=\"flexvideo '.$aspect.'\">'.$content.'</div>';\n return $content;\n}", "function shortcode_karaja( $atts, $content = null ) {\n return '<div class=\"lingua-kr\">'.$content.'</div>';\n}", "function inline_play_graphic( $atts, $content = null ) {\n\t\t\t\n\t\t\tif ( !$this->external_call && (is_home() || is_archive()) && $this->theSettings['player_onblog'] == \"false\" ) { \n\t\t\t\treturn; \n\t\t\t}\n\t\t\t$id = $this->Player_ID;\t\t\t\n\t\t\textract(shortcode_atts(array( // Defaults\n\t\t\t\t'bold' => 'y',\n\t\t\t\t'track' => '',\n\t\t\t\t'caption' => '',\n\t\t\t\t'flip' => 'r',\n\t\t\t\t'title' => '#USE#',\n\t\t\t\t'ind' => 'y',\n\t\t\t\t'autoplay' => $this->theSettings['auto_play'],\n\t\t\t\t'loop' => 'false',\n\t\t\t\t'vol' => $this->theSettings['initial_vol'],\n\t\t\t\t'flow' => 'n'\n\t\t\t), $atts));\n\t\t\t\t\t\n\t\t\tif ( $track == \"\" ) { // Auto increment \n\t\t\t\tif ( !$this->has_fields || $this->external_call ) { return; }\n\t\t\t\t$track = ++$this->single_autocount;\n\t\t\t\t$arb = \"\";\n\t\t\t}\n\t\t\telseif ( is_numeric($track) ) { // Has a track number\n\t\t\t\tif ( !$this->has_fields || $this->external_call ) { return; }\n\t\t\t\t$arb = \"\";\n\t\t\t}\n\t\t\telse { // Has arbitrary file/uri\t\t\t\t\n\t\t\t\tif ( !$this->string_pushto_playlist( $track, $caption, \"1\" ) ) { return; }\n\t\t\t\t$track = $this->InlinePlaylist['count'];\t\t\t\t\t\n\t\t\t\t$arb = \"arb\";\n\t\t\t}\n\t\t\t\n\t\t\t$divO = \"\";\n\t\t\t$divC = \"\";\n\t\t\tif ( $flow == \"n\" || $this->external_call ) {\n\t\t\t\t$divO = \"<div style=\\\"font-size:14px; line-height:22px !important; margin:0 !important;\\\">\";\n\t\t\t\t$divC = \"</div>\";\n\t\t\t}\n\t\t\t\n\t\t\t$playername = ( $arb != \"\" ) ? \"foxInline\" : $this->has_fields;\n\t\t\t\n\t\t\t// Set font weight\n\t\t\t$b = ( $bold == \"false\" || $bold == \"N\" || $bold == \"n\" ) ? \" style=\\\"font-weight:500;\\\"\" : \" style=\\\"font-weight:700;\\\"\";\n\t\t\t// Prep title\n\t\t\t$customtitle = ( $title == \"#USE#\" ) ? \"\" : $title;\n\t\t\t// tell js it's graphics buttons\n\t\t\t$play = \"#USE_G#\";\n\t\t\t\n\t\t\t// Make id'd span elements\n\t\t\t$openWrap = $divO . \"<span id=\\\"playpause_wrap_mp3j_\" . $id . \"\\\" class=\\\"wrap_inline_mp3j\\\"\" . $b . \">\";\n\t\t\t$pos = \"<span class=\\\"bars_mp3j\\\"><span class=\\\"loadB_mp3j\\\" id=\\\"load_mp3j_\" . $id . \"\\\"></span><span class=\\\"posbarB_mp3j\\\" id=\\\"posbar_mp3j_\" . $id . \"\\\"></span></span>\";\n\t\t\t$play_h = \"<span class=\\\"buttons_mp3j\\\" id=\\\"playpause_mp3j_\" . $id . \"\\\">&nbsp;</span>\";\n\t\t\t$spacer = \"\";\n\t\t\t$title_h = ( $title == \"#USE#\" || $title != \"\" ) ? \"<span class=\\\"T_mp3j\\\" id=\\\"T_mp3j_\" . $id . \"\\\">\" . $customtitle . \"</span>\" : \"\";\n\t\t\t$indi_h = ( $ind != \"y\" ) ? \"<span style=\\\"display:none;\\\" id=\\\"indi_mp3j_\" . $id . \"\\\"></span>\" : \"<span class=\\\"indi_mp3j\\\" id=\\\"indi_mp3j_\" . $id . \"\\\"></span>\";\n\t\t\t\n\t\t\t// TODO: SHOULD THIS GO SOMEWHERE IN SPAN FORMAT??\n\t\t\t$vol_h = \"<div class=\\\"vol_mp3j\\\" id=\\\"vol_mp3j_\" . $id . \"\\\"></div>\";\n\n\t\t\t// Assemble them\t\t\n\t\t\t$html = ( $flip == \"r\" ) ? $openWrap . \"<span class=\\\"group_wrap\\\">\" . $pos . $title_h . $indi_h . \"</span>\" . $play_h . \"</span>\" . $divC : $openWrap . $play_h . \"&nbsp;<span class=\\\"group_wrap\\\">\" . $pos . $title_h . $indi_h . \"</span></span>\" . $divC;\n\t\t\t\n\t\t\t// Add title to js footer string if needed \n\t\t\tif ( $title_h != \"\" && $title == \"#USE#\" ) {\n\t\t\t\t$this->Footerjs .= \"jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append(\" . $playername . \"[\" . ($track-1) . \"].name);\\n\";\n\t\t\t\t//$this->Footerjs .= \"jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append('<span style=\\\"font-size:.7em;\\\"> - '+\" . $playername . \"[\" . ($track-1) . \"].artist+'</span>');\\n\";\n\t\t\t\t$this->Footerjs .= \"if (\" . $playername . \"[\" . ($track-1) . \"].artist !==''){ jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append('<span style=\\\"font-size:.75em;\\\"> - '+\" . $playername . \"[\" . ($track-1) . \"].artist+'</span>'); }\\n\";\n\t\t\t}\n\t\t\t// Add info to js info array\n\t\t\t//$autoplay = ( $autoplay != \"false\" ) ? \"true\" : \"false\";\n\t\t\t$autoplay = ( $autoplay == \"true\" || $autoplay == \"y\" || $autoplay == \"1\" ) ? \"true\" : \"false\";\n\t\t\t$loop = ( $loop != \"false\" ) ? \"true\" : \"false\";\n\t\t\t$this->jsInfo[] = \"\\n { list:\" . $playername . \", type:'single', tr:\" . ($track-1) . \", lstate:'', loop:\" . $loop . \", play_txt:'\" . $play . \"', pause_txt:'\" . $stop . \"', pp_title:'', autoplay:\" . $autoplay . \", has_ul:0, transport:'playpause', status:'basic', download:false, vol:\" . $vol . \", height:'' }\";\n\t\t\t\n\t\t\t$this->write_jp_div();\n\t\t\t$this->Player_ID++;\n\t\t\treturn $html;\n\t\t}", "function Kaya_dropcap( $atts, $content = null ) {\r\n return '<span class=\"dropcap\">' . do_shortcode($content) . '</span>';\r\n}", "function epsw_shortcode( $args )\n{\n\t// User uploaded icon url\n\t$wp_upload_dir = wp_upload_dir();\n\t$iconurl = $wp_upload_dir['baseurl'] . '/epsocial_icons/';\n\t$icondir = $wp_upload_dir['basedir'] . '/epsocial_icons/';\n\n\t// Plugin path\n\t$plugin_path = WP_PLUGIN_DIR . DIRECTORY_SEPARATOR . str_replace( basename( __FILE__ ), '', plugin_basename( __FILE__ ) );\n\n\t$html = '<ul class=\"ep_social_widget\" id=\"epSW_shortcode\">';\n\tforeach ( $args as $network => $link )\n\t{\n\t\tif ( $network === 'rss' )\n\t\t{\n\t\t\tif ( $link === '1' )\n\t\t\t{\n\t\t\t\t$html .= '<li>';\n\t\t\t\t\t$html .= '<a href=\"' . get_bloginfo( \"rss2_url\" ) . '\" target=\"_blank\" title=\"RSS\"><img src=\"' . plugins_url( \"icons/rss.svg\", __FILE__ ) . '\" alt=\"RSS\" width=\"26\" height=\"26\" /></a>';\n\t\t\t\t$html .= '</li>';\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$pattern1 = '/^http:\\/\\//';\n\t\t\t$pattern2 = '/^https:\\/\\//';\n\n\t\t\t$l = strip_tags( $link );\n\t\t\tif ( preg_match( $pattern1, $l ) || preg_match( $pattern2, $l ) )\n\t\t\t{\n\t\t\t\t$link = $l;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$link = 'http://'.$l;\n\t\t\t}\n\n\t\t\t$html .= '<li>';\n\n\t\t\tif ( file_exists( $plugin_path . '/icons/' . $network . '.svg' ) )\n\t\t\t{\n\t\t\t\t$html .= '<a href=\"' . $link . '\" target=\"_blank\" title=\"' . $network . '\"><img src=\"'.plugins_url( \"icons/\" . $network . \".svg\", __FILE__ ).'\" alt=\"' . $network . '\" width=\"26\" height=\"26\" /></a>';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tif ( ! file_exists( $icondir ) )\n\t\t\t\t{\n\t\t\t\t\t$icons = NULL;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$icons = scandir( $icondir );\n\t\t\t\t}\n\n\t\t\t\tif ( $icons )\n\t\t\t\t{\n\t\t\t\t\tforeach ( $icons as $icon )\n\t\t\t\t\t{\n\t\t\t\t\t\t$ext = pathinfo( $icon, PATHINFO_EXTENSION );\n\t\t\t\t\t\t$name = str_replace( 'icon-', '', str_replace( '.' . $ext, '', $icon ) );\n\n\t\t\t\t\t\tif ( $name == $network )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$html .= '<a href=\"' . $link . '\" target=\"_blank\" title=\"' . $network . '\"><img src=\"' . $iconurl . 'icon-' . $network . '.' . $ext . '\" alt=\"' . $network . '\" width=\"26\" height=\"26\" /></a>';\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$html .= '</li>';\n\n\t\t}\n\t}\n\t$html .= '</ul>';\n\n\treturn $html;\n}", "function ms_slideshare_shortcode_handler( $atts ) {\n extract(shortcode_atts( array(\n 'url' => 'http://www.slideshare.net/',\n ), $atts));\n $pluginurl = plugin_dir_url(__FILE__);\n\n return '<a href=\"'.$url.'\"><img style=\"height: 1em; padding: 0; margin: 0;\" src=\"'.$pluginurl.'/slideshare-32x32.png\" alt=\"link to slideshare\" /></a>';\n}", "function roots_caption($output, $attr, $content) {\n if (is_feed()) {\n return $output;\n }\n\n $defaults = array(\n 'id' => '',\n 'align' => 'alignnone',\n 'width' => '',\n 'caption' => '',\n 'align' => 'alignnone'\n );\n\n $attr = shortcode_atts($defaults, $attr);\n\n // If the width is less than 1 or there is no caption, return the content wrapped between the [caption] tags\n if ($attr['width'] < 1 || empty($attr['caption'])) {\n return $content;\n }\n\n // Set up the attributes for the caption <figure>\n $attributes = (!empty($attr['id']) ? ' id=\"' . esc_attr($attr['id']) . '\"' : '' );\n $attributes .= ' class=\"wp-caption ' . esc_attr($attr['align']) . '\"';\n $output = '<figure' . $attributes .' style=\"max-width: ' . $attr['width']. 'px;\">';\n /* Check if it is an attacment */\n if( !empty($attr['id']) ){\n $output .= xo_responsive_image($attr, $content);\n } else {\n $output .= do_shortcode($content);\n }\n $output .= '<figcaption class=\"caption wp-caption-text\">' . $attr['caption'] . '</figcaption>';\n $output .= '</figure>';\n\n return $output;\n}", "function addYouTube($atts, $content = null)\n{\n extract(shortcode_atts(array(\"id\" => ''), $atts));\n return '<p style=\"text-align:center\"> \\\n <a href=\"http://www.youtube.com/v/' . $id . '\"> \\\n <img src=\"http://img.youtube.com/vi/' . $id . '/0.jpg\" width=\"400\" height=\"300\" class=\"aligncenter\" /> \\\n <span>Watch the video</span></a></p>';\n}", "public function add_short_code()\n {\n add_shortcode('colorYourLife', array($this, 'generate_short_code_content'));\n }", "public abstract function do_shortcode( $atts, $content, $tag );", "private function wrap_in_shortcode ($content, $atts)\n {\n $params = empty ($atts['params']) ? '' : \" params=\\\"{$atts['params']}\\\"\";\n $params .= empty ($atts['stringparams']) ? '' : \" stringparams=\\\"{$atts['stringparams']}\\\"\";\n return \"[{$this->shortcode} xml=\\\"{$atts['xml']}\\\" xslt=\\\"{$atts['xslt']}\\\"$params]\\n\" .\n \"$content\\n[/{$this->shortcode}]\";\n }", "function unique_register_shortcodes() {\r\n\r\n\t/* Adds the [entry-mood] shortcode. */\r\n\tadd_shortcode( 'entry-mood', 'unique_entry_mood_shortcode' );\r\n\r\n\t/* Adds the [entry-views] shortcode. */\r\n\tadd_shortcode( 'entry-views', 'unique_entry_views_shortcode' );\r\n}", "function uams_pubmed_shortcode( $atts ) {\n\twp_enqueue_script( 'pubmed-api' );\n\n\t$atts = shortcode_atts( array(\n\t\t'terms' => '',\n\t\t'count' => '20',\n\t), $atts, 'pubmed' );\n\treturn \"<ul class=\\\"pubmed-list\\\" data-terms=\\\"{$atts['terms']}\\\" data-count=\\\"{$atts['count']}\\\"></ul>\";\n}", "function wp_super_emoticons_shortcode ($attr, $content = null ) {\n\t$attr = shortcode_atts(array(\n\t\t'file' => 'file',\n\t\t'title' => 'title'\n\t\t), $attr);\n\t\t\t\t\t\t\t\t \n\treturn '<img class=\"superemotions\" title=\"' . $attr['title'] . '\" alt=\"' . $attr['title'] . '\" border=\"0\" src=\"' . get_bloginfo('wpurl') . '/wp-includes/images/smilies/' . $attr['file'] . '\" />';\n}", "function tz_one_third( $atts, $content = null ) {\n return '<div class=\"one_third\">' . do_shortcode($content) . '</div>';\n}", "function kw_youtube_short( $atts, $content = null )\r\n{\r\n\r\n extract( shortcode_atts( array(\r\n 'id' => '',\r\n ), $atts ) );\r\n\t \r\n\t$id = trim($id);\r\n\t$kw_spaces = get_option(\"kw_spaces\");\r\n\t$kw_spaces = stripslashes($kw_spaces);\r\n\t$kw_width = get_option(\"kw_width\");\r\n\t$kw_width = stripslashes($kw_width);\r\n\t$kw_height = get_option(\"kw_height\");\r\n\t$kw_height = stripslashes($kw_height);\r\n\t$kw_bgcolor = get_option(\"kw_bgcolor\");\r\n\t$kw_bgcolor = stripslashes($kw_bgcolor);\r\n\t$kw_api = get_option(\"kw_api\");\r\n\t$kw_api = stripslashes($kw_api);\r\n \r\nreturn ''.$kw_spaces.'<object width=\"'.$kw_width.'\" height=\"'.$kw_height.'\"><param name=\"movie\" value=\"http://www.youtube.com/v/'.$id.''.$kw_api.'\" /><param name=\"allowFullScreen\" value=\"true\" /><param name=\"allowscriptaccess\" value=\"always\" /><param name=\"bgcolor\" value=\"'.$kw_bgcolor.'\"><embed type=\"application/x-shockwave-flash\" width=\"'.$kw_width.'\" height=\"'.$kw_height.'\" src=\"http://www.youtube.com/v/'.$id.''.$kw_api.'\" bgcolor=\"'.$kw_bgcolor.'\" allowscriptaccess=\"always\" allowfullscreen=\"true\"></embed></object>'.$kw_spaces.'';\r\n}", "function plugin_starter_shortcode_1() {\r\n\t// This is just for showing that the shortcut works\r\n\treturn '<div class=\"starter-test\">This is the output of this shortcode</div>';\r\n}", "function wpestate_shortcodes(){\n wpestate_register_shortcodes();\n wpestate_tiny_short_codes_register();\n add_filter('widget_text', 'do_shortcode');\n}", "public function convert_shortcodes( $content ) {\n\t\t// Override Jetpack shortcodes\n\t\tadd_shortcode( 'youtube', function( $atts ) {\n\t\t\treturn $this->hugo_shortcode( 'youtube', jetpack_get_youtube_id( $atts[0] ) );\n\t\t} );\n\n\t\tadd_shortcode( 'vimeo', function( $atts ) {\n\t\t\t$id = isset( $atts['id'] ) ? $atts['id'] : jetpack_shortcode_get_vimeo_id( $atts );\n\t\t\treturn $this->hugo_shortcode( 'vimeo', $id );\n\t\t} );\n\n\t\t// Use `<blockquote>` which then gets coverted to `> Lorem ipsum` by Markdownify\n\t\tadd_shortcode( 'quote', function( $atts ) {\n\t\t\t$id = isset( $atts['id'] ) ? $atts['id'] : $this->id;\n\t\t\t$pullquote = get_post_meta( $id, 'quote', true );\n\t\t\tif ( empty( $pullquote ) ) {\n\t\t\t\treturn '';\n\t\t\t}\n\t\t\treturn '<blockquote>' . esc_html( $pullquote ) . '</blockquote>';\n\t\t} );\n\n\t\tadd_shortcode( 'caption', function( $atts, $content ) {\n\t\t\t$args = $this->parse_hugo_figure_args( $content );\n\t\t\treturn $this->hugo_figure( $args );\n\t\t} );\n\n\t\tadd_shortcode( 'googlemaps', function( $atts ) {\n\t\t\t$url = urldecode( $atts[0] );\n\t\t\t$url = preg_replace( '/&w=\\d+&h=\\d+]/', ']', $url );\n\t\t\treturn '{{< iframe src=\"' . $url . '\" width=\"100%\" height=\"250px\" >}}';\n\t\t} );\n\n\t\t$content = do_shortcode( $content );\n\t\treturn $content;\n\t}", "function abc_speakers_for_shortcode( $speakers_array, $atts ) {\n\t $output = null;\n\n\t// Bail if there are no speakers to show.\n\tif ( empty( $speakers_array ) ) {\n\t\treturn '';\n\t}\n\n\t$speaker_args = array(\n\t\t'post_type' => 'special_speaker',\n\t\t'post_status' => 'publish',\n\t\t'posts_per_page' => -1,\n\t\t'post__in' => $speakers_array,\n\t\t'order' => 'ASC',\n\t\t'orderby' => 'meta_value',\n\t\t'meta_key' => 'sort_order',\n\t\t'cache_results' => true,\n\t\t'update_post_meta_cache' => true,\n\t\t'update_post_term_cache' => true,\n\t);\n\n\t$special_speaker_query = new WP_Query( $speaker_args );\n\n\tif ( $special_speaker_query->have_posts() ) {\n\t\twhile ( $special_speaker_query->have_posts() ) {\n\t\t\t$special_speaker_query->the_post();\n\t\t\t$output .= '<figure class=\"wp-caption align' . $atts['align'] . '\">\n\t\t\t\t' . get_the_post_thumbnail( get_the_ID(), 'faculty', array( 'class' => 'align' . $atts['align'] ) ) . '\n\t\t\t\t<figcaption class=\"wp-caption-text\">' . get_the_title();\n\t\t\tif ( $atts['show_bio'] ) {\n\t\t\t\t$output .= '<br/>' . get_the_content();\n\t\t\t}\n\t\t\t$output .= '</figcaption></figure>';\n\t\t}\n\t}\n\n\twp_reset_postdata();\n\n\treturn $output;\n}", "function ejos_register_social_share_shortcode() {\n add_shortcode( 'social_share', 'ejos_social_share_shortcode' );\n}", "function do_shortcode($content, $ignore_html = \\false)\n {\n }", "function lambert_custom_tag_cloud_widget($args) {\n // $args['largest'] = 18; //largest tag\n // $args['smallest'] = 10; //smallest tag\n // $args['unit'] = 'px'; //tag font unit\n $args['format'] = 'list'; //ul with a class of wp-tag-cloud\n return $args;\n}", "function saju_jukebox_shortcode_jukebox( $atts ) {\n\n\tsaju_jukebox_enqueue_scripts();\n\n\twp_localize_script( 'saju-js', 'saju_js_options', array(\n\t\t'api_url' => admin_url( 'admin-ajax.php?action=wl_sparql&slug=' ),\n\t\t'event_url' => get_option( SAJU_JUKEBOX_SETTINGS_FIELD_EVENT_URL ),\n\t\t'dataset_url' => get_option( SAJU_JUKEBOX_SETTINGS_FIELD_DATASET_URL )\n\t) );\n\n\t// Get the HTML fragment from the file.\n\treturn file_get_contents( dirname( __FILE__ ) . '/html/jukebox.html' );\n\n}", "function add_shortcode() {\n\t\tadd_shortcode( 'contact-form', array( 'Grunion_Contact_Form', 'parse' ) );\n\t\tadd_shortcode( 'contact-field', array( 'Grunion_Contact_Form', 'parse_contact_field' ) );\n\t}", "function ts_run_shortcode( $content ) {\r\r\n global $shortcode_tags;\r\r\n \r\r\n // Backup current registered shortcodes and clear them all out\r\r\n $orig_shortcode_tags = $shortcode_tags;\r\r\n remove_all_shortcodes();\r\r\n \r\r\n add_shortcode('accordions', 'ts_accordions');\r\r\n\tadd_shortcode('accordion', 'ts_accordion');\r\r\n\t\r\r\n\tadd_shortcode('one_half', 'ts_one_half');\r\r\n\tadd_shortcode('one_third', 'ts_one_third');\r\r\n\tadd_shortcode('one_fourth', 'ts_one_fourth');\r\r\n\tadd_shortcode('one_fifth', 'ts_one_fifth');\r\r\n\tadd_shortcode('one_sixth', 'ts_one_sixth');\r\r\n\t\r\r\n\tadd_shortcode('two_third', 'ts_two_third');\r\r\n\tadd_shortcode('two_fourth', 'ts_two_fourth');\r\r\n\tadd_shortcode('two_fifth', 'ts_two_fifth');\r\r\n\tadd_shortcode('two_sixth', 'ts_two_sixth');\r\r\n\t\r\r\n\t\r\r\n\tadd_shortcode('three_fourth', 'ts_three_fourth');\r\r\n\tadd_shortcode('three_fifth', 'ts_three_fifth');\r\r\n\tadd_shortcode('three_sixth', 'ts_three_sixth');\r\r\n\t\r\r\n\tadd_shortcode('four_fifth', 'ts_four_fifth');\r\r\n\tadd_shortcode('four_sixth', 'ts_four_sixth');\r\r\n\t\r\r\n\tadd_shortcode('five_sixth', 'ts_five_sixth');\r\r\n\t\r\r\n\tadd_shortcode('content_box', 'ts_content_box');\r\r\n\t\r\r\n\tadd_shortcode('content_highlight', 'ts_content_highlight');\r\r\n\t\r\r\n\tadd_shortcode( 'dropcap', 'ts_dropcap' );\r\r\n\t\r\r\n\tadd_shortcode( 'highlight', 'ts_highlight' );\r\r\n\t\r\r\n\tadd_shortcode('pre', 'ts_pre');\r\r\n\t\r\r\n\tadd_shortcode( 'pullquote', 'ts_pullquote' );\r\r\n\tadd_shortcode( 'blockquote', 'ts_blockquote' );\r\r\n\t\r\r\n\tadd_shortcode( 'recent_posts', 'ts_recentposts' );\r\r\n\t\r\r\n\tadd_shortcode('separator', 'ts_separator');\r\r\n\tadd_shortcode('clear', 'ts_clearfloat');\r\r\n\tadd_shortcode('clearfix', 'ts_clearfixfloat');\r\r\n\t\r\r\n\tadd_shortcode('social', 'ts_socialshortcode');\r\r\n\t\r\r\n\tadd_shortcode('tabs', 'ts_tab');\r\r\n\t\r\r\n\tadd_shortcode('toggles', 'ts_toggles');\r\r\n\tadd_shortcode('toggle', 'ts_toggle');\r\r\n \r\r\n // Do the shortcode (only the one above is registered)\r\r\n $content = do_shortcode( $content );\r\r\n \r\r\n // Put the original shortcodes back\r\r\n $shortcode_tags = $orig_shortcode_tags;\r\r\n \r\r\n return $content;\r\r\n}", "function mattu_portfolio_register_shortcodes() {\n\tadd_shortcode('portfolio_items', 'mattu_portfolio_items_shortcode' );\n}", "function shortcode_template( $atts, $content = null ) {\r\n\t\t\tglobal $mpc_ma_options;\r\n\t\t\tif ( ! defined( 'MPC_MASSIVE_FULL' ) || ( defined( 'MPC_MASSIVE_FULL' ) && $mpc_ma_options[ 'single_js_css' ] !== '1' ) ) {\r\n\t\t\t\t$this->enqueue_shortcode_scripts();\r\n\t\t\t}\r\n\r\n\t\t\t$atts = shortcode_atts( array(\r\n\t\t\t\t'class' => '',\r\n\t\t\t\t'preset' => '',\r\n\t\t\t\t'content_preset' => '',\r\n\t\t\t\t'style' => 'horizontal',\r\n\t\t\t\t'space' => '',\r\n\t\t\t\t'fullwidth' => '',\r\n\r\n\t\t\t\t'padding_css' => '',\r\n\t\t\t\t'margin_css' => '',\r\n\t\t\t\t'border_css' => '',\r\n\r\n\t\t\t\t'icon_type' => 'icon',\r\n\t\t\t\t'icon' => '',\r\n\t\t\t\t'icon_character' => '',\r\n\t\t\t\t'icon_image' => '',\r\n\t\t\t\t'icon_image_size' => 'thumbnail',\r\n\t\t\t\t'icon_preset' => '',\r\n\t\t\t\t'icon_color' => '#333333',\r\n\t\t\t\t'icon_size' => '',\r\n\r\n\t\t\t\t'icon_margin_css' => '',\r\n\t\t\t\t'icon_animation' => 'none',\r\n\r\n\t\t\t\t'background_type' => 'color',\r\n\t\t\t\t'background_color' => '',\r\n\t\t\t\t'background_image' => '',\r\n\t\t\t\t'background_image_size' => 'large',\r\n\t\t\t\t'background_repeat' => 'no-repeat',\r\n\t\t\t\t'background_size' => 'initial',\r\n\t\t\t\t'background_position' => 'middle-center',\r\n\t\t\t\t'background_gradient' => '#83bae3||#80e0d4||0;100||180||linear',\r\n\r\n\t\t\t\t'animation_in_type' => 'none',\r\n\t\t\t\t'animation_in_duration' => '300',\r\n\t\t\t\t'animation_in_delay' => '0',\r\n\t\t\t\t'animation_in_offset' => '100',\r\n\r\n\t\t\t\t'animation_loop_type' => 'none',\r\n\t\t\t\t'animation_loop_duration' => '1000',\r\n\t\t\t\t'animation_loop_delay' => '1000',\r\n\t\t\t\t'animation_loop_hover' => '',\r\n\t\t\t), $atts );\r\n\r\n\t\t\t$styles = $this->shortcode_styles( $atts );\r\n\t\t\t$css_id = $styles[ 'id' ];\r\n\r\n\t\t\t$icon = MPC_Parser::icon( $atts );\r\n\t\t\t$animation = MPC_Parser::animation( $atts );\r\n\r\n\t\t\t$classes = $animation != '' ? ' mpc-animation' : '';\r\n\t\t\t$classes .= $atts[ 'fullwidth' ] != '' ? ' mpc-fullwidth' : '';\r\n\t\t\t$classes .= $atts[ 'style' ] == 'horizontal' ? ' mpc-style--horizontal' : ' mpc-style--vertical';\r\n\t\t\t$classes .= ' ' . esc_attr( $atts[ 'class' ] );\r\n\r\n\t\t\t$separator_classes = $icon[ 'class' ] == '' && $icon[ 'content' ] == '' ? ' mpc-empty' : '';\r\n\r\n\t\t\tglobal $mpc_button_separator;\r\n\t\t\t$mpc_button_separator = '<span class=\"mpc-button-separator-wrap\"><span class=\"mpc-button-separator-box\"><span class=\"mpc-button-separator ' . $icon[ 'class' ] . $separator_classes . '\">' . $icon[ 'content' ] . '</span></span></span>';\r\n\r\n\t\t\t$return = '<div id=\"' . $css_id . '\" class=\"mpc-button-set mpc-init' . $classes . '\"' . $animation . ( $atts[ 'icon_animation' ] != 'none' ? ' data-animation=\"' . esc_attr( $atts[ 'icon_animation' ] ) . '\"' : '' ) . '>';\r\n\t\t\t\t$return .= do_shortcode( $content );\r\n\t\t\t$return .= '</div>';\r\n\r\n\t\t\t$mpc_button_separator = null;\r\n\r\n\t\t\tglobal $mpc_frontend;\r\n\t\t\tif ( $mpc_frontend ) {\r\n\t\t\t\t$return .= '<style>' . $styles[ 'css' ] . '</style>';\r\n\t\t\t}\r\n\r\n\t\t\treturn $return;\r\n\t\t}", "function dm_case_studies_shortcode($atts, $content=null) {\n\tglobal $post;\n\n\textract(shortcode_atts(array(\n\t\t'title' => 'View Case Studies:',\n\t\t'post_id' => $post->ID,\n\t\t'limit' => 1,\n\t), $atts));\n\n\t$solution_ids = dm_get_post_term_ids($post_id, 'solutions');\n\n\t$args = array(\n\t\t'post_status' => 'publish',\n\t\t'post_type' => 'library_documents',\n\t\t'posts_per_page' => $limit,\n\t\t'tax_query' => array(\n\t\t\t'relation' => 'AND',\n\t\t\tarray(\n\t\t\t\t'taxonomy' => 'library_categories',\n\t\t\t\t'field' => 'slug',\n\t\t\t\t'terms' => array( 'case-studies' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'taxonomy' => 'solutions',\n\t\t\t\t'field' => 'id',\n\t\t\t\t'terms' => $solution_ids,\n\t\t\t),\n\t\t),\n\t);\n\n\t$query = new WP_Query($args);\n\n\tif (!$query->have_posts()) {\n\t\treturn '';\n\t}\n\n\tob_start();\n?>\n\t<div class=\"sidebar_secondary_links\">\n\t\t<h4><?php echo $title; ?></h4>\n\n\t\t<ul>\n\t\t\t<?php while ($query->have_posts()): $query->the_post(); ?>\n\t\t\t\t<li>\n\t\t\t\t\t<a href=\"<?php echo get_permalink($post->ID); ?>\">\n\t\t\t\t\t\t<?php the_title(); ?>\n\t\t\t\t\t</a>\n\t\t\t\t</li>\n\t\t\t<?php endwhile; ?>\n\t\t</ul>\n\t</div>\n<?php\n\t$output = ob_get_clean();\n\treturn $output;\n}", "function kstFilterShortcodeCaptionAndWpCaption($attr, $content = null) {\n $output = apply_filters('kst_wp_caption_shortcode', '', $attr, $content);\n\n if ( $output != '' )\n return $output;\n\n extract(shortcode_atts(array(\n 'id'\t=> '',\n 'align'\t=> '',\n 'width'\t=> '',\n 'caption' => ''\n ), $attr));\n\n if ( $id )\n $id = 'id=\"' . $id . '\" ';\n\n if (!empty($width) )\n\n $width = ( !empty($width) )\n ? ' style=\"width: ' . ((int) $width) . 'px\" '\n : '';\n\n $better = '<div ' . $id . $width . 'class=\"wp_attachment\">';\n $better .= do_shortcode( $content );\n if ( !empty($caption) )\n $better .= '<div class=\"wp_caption\">' . $caption .'</div>';\n $better .= '</div>';\n\n return $better;\n }", "function _sp_custom_box_carousel_shortcode( $post ) {\n\n\t$output = '';\n\n\t$output .= '<div class=\"settings-container\">' . PHP_EOL;\t\n\t$output .= sp_get_slider_shortcode( $post->ID ) . PHP_EOL;\n\t$output .= '<p class=\"howto\">' . __( 'Paste this shortcode on the page you want this carousel slider to show.', 'sp-theme' ) . '</p>' . PHP_EOL;\t\n\t$output .= '</div>' . PHP_EOL;\n\n\techo $output;\n}", "function crumble_list_shortcode($atts, $content = null) {\r\n\textract( shortcode_atts( \r\n\t\tarray( \r\n\t\t\t\"style\" => '1',\r\n\t\t\t\"underline\" => '1' \r\n\t\t), $atts));\r\n\t\r\n\t$code = '';\r\n\t$list_type = '';\r\n\t\r\n\tswitch ($style) {\r\n\t case 1:\r\n\t\t\t$list_type = 'unordered';\r\n\t\t\tbreak;\r\n\t case 2:\r\n\t \t\t$list_type = 'ordered';\r\n\t\t\tbreak;\r\n\r\n\t case 3:\r\n\t \t\t$list_type = 'square';\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t case 4:\r\n\t \t\t$list_type = 'circle';\r\n\t\t\tbreak;\r\n\r\n\t case 5:\r\n\t \t\t$list_type = 'bullets';\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t case 6:\r\n\t \t\t$list_type = 'arrow';\r\n\t\t\tbreak;\r\n\r\n\t case 7:\r\n\t \t\t$list_type = 'arrow2';\r\n\t\t\tbreak;\r\n\t\t\r\n\t}\r\n\t\r\n\tif( $underline == \"1\" ) {\r\n\t\t$code = '<ul class=\"list '.$list_type.' underline\">' . do_shortcode ( $content ) . '</ul>';\r\n\t} else {\r\n\t\t$code = '<ul class=\"list '.$list_type.'\">' . do_shortcode ( $content ) . '</ul>';\r\n\t}\r\n\t\r\n\treturn $code;\r\n\t\r\n}", "function lc_shortcode_twitter($atts, $content = null) {\n \tglobal $post;\n \textract(shortcode_atts(array(\t'url' => '',\n \t\t\t\t\t\t\t\t\t'style' => '',\n \t\t\t\t\t\t\t\t\t'source' => '',\n \t\t\t\t\t\t\t\t\t'text' => '',\n \t\t\t\t\t\t\t\t\t'related' => '',\n \t\t\t\t\t\t\t\t\t'lang' => '',\n \t\t\t\t\t\t\t\t\t'float' => 'left',\n \t\t\t\t\t\t\t\t\t'use_post_url' => 'false',\n \t\t\t\t\t\t\t\t\t'recommend' => '',\n \t\t\t\t\t\t\t\t\t'hashtag' => '',\n \t\t\t\t\t\t\t\t\t'size' => '',\n \t\t\t\t\t\t\t\t\t ), $atts));\n\t$output = '';\n\n\tif ( $url )\n\t\t$output .= ' data-url=\"' . esc_url( $url ) . '\"';\n\n\tif ( $source )\n\t\t$output .= ' data-via=\"' . esc_attr( $source ) . '\"';\n\n\tif ( $text )\n\t\t$output .= ' data-text=\"' . esc_attr( $text ) . '\"';\n\n\tif ( $related )\n\t\t$output .= ' data-related=\"' . esc_attr( $related ) . '\"';\n\n\tif ( $hashtag )\n\t\t$output .= ' data-hashtags=\"' . esc_attr( $hashtag ) . '\"';\n\n\tif ( $size )\n\t\t$output .= ' data-size=\"' . esc_attr( $size ) . '\"';\n\n\tif ( $lang )\n\t\t$output .= ' data-lang=\"' . esc_attr( $lang ) . '\"';\n\n\tif ( $style != '' ) {\n\t\t$output .= 'data-count=\"' . esc_attr( $style ) . '\"';\n\t}\n\n\tif ( $use_post_url == 'true' && $url == '' ) {\n\t\t$output .= ' data-url=\"' . get_permalink( $post->ID ) . '\"';\n\t}\n\n\t$output = '<div class=\"woo-sc-twitter ' . esc_attr( $float )\n . '\"><a href=\"' . esc_url( 'https://twitter.com/share' )\n . '\" class=\"twitter-share-button\"'. $output .'>'\n . __( 'Tweet', 'woothemes' )\n . '</a><script type=\"text/javascript\" src=\"'\n . esc_url ( 'https://platform.twitter.com/widgets.js' )\n . '\"></script></div>';\n\treturn $output;\n\n}", "function add_shortcode_for_our_plugin ($attr , $content = null ){\n\t\textract(shortcode_atts(array(\n\t\t\t'post_type'=>'post',\n\t\t\t'posts_per_page'=>2,\n\t\t\t\n\t\t\t\n\t\t\n\t\t), $attr,'our_shortcode' ));\n\t\n\t$query = new WP_Query(array(\n\t\t'post_type'=>$post_type,\n\t\t'posts_per_page'=>$posts_per_page,\n\t\n\t));\n\t\n\tif($query->have_posts()):\n\t\t$output = '<div class=\"recent_posts\"><ul>';\n\t\t$i=0;\n\t\twhile($query->have_posts()){\n\t\t\t\n\t\t\t$query->the_post();\n\t\t\tif($i == 0):\n\t\t\t$output .= '<li><a href=\"'.get_the_permalink().'\" style=\"color:red;\" >'.get_the_title().'</a></li>';\n\t\t\telse:\n\t\t\t$output .= '<li><a href=\"'.get_the_permalink().'\">'.get_the_title().'</a></li>';\n\t\t\tendif;\n\t\t\t\n\t\t\t\n\t\t$i++; }\n\t\twp_reset_postdata();\n\t$output .= '</ul></div>';\n\treturn $output;\n\telse:\n\t return 'no post found';\n\t\n\tendif;\n\t\n\t\n\t\n\t\n\t\n\t\n}", "function gallery_section_shortcode( $atts, $content = null ) {\t\n\t$output = '<li>';\n\t$output .= do_shortcode($content);\n\t$output .= '</li>';\n\treturn $output;\n}", "function sp_two_third_sc( $atts, $content = null ) {\n\n\t\treturn '<div class=\"two_third\">' . do_shortcode( $content ) . '</div>';\n\n\t}", "function utcw_init() {\n\twp_enqueue_script('utcw-js');\n\twp_enqueue_style('utcw-css');\n\t\n\tadd_shortcode('utcw', 'do_utcw_shortcode');\n}", "function custom_shortcode_slider() \n {\n require_once(TEMPLATEPATH.'/shortcode/shortcode.php');\n }", "function acf_shortcode($atts)\n{\n}", "public function shortcode($atts) {\n global $wpdb;\n if (isset($atts['slug'])) {\n $q=$wpdb->prepare(\n \"SELECT id \".\n \"FROM {$wpdb->prefix}h5p_contents \".\n \"WHERE slug=%s\",\n $atts['slug']\n );\n $row=$wpdb->get_row($q,ARRAY_A);\n\n if ($wpdb->last_error) {\n return sprintf(__('Database error: %s.', $this->plugin_slug), $wpdb->last_error);\n }\n\n if (!isset($row['id'])) {\n return sprintf(__('Cannot find H5P content with slug: %s.', $this->plugin_slug), $atts['slug']);\n }\n\n $atts['id']=$row['id'];\n }\n\n $id = isset($atts['id']) ? intval($atts['id']) : NULL;\n $content = $this->get_content($id);\n if (is_string($content)) {\n // Return error message if the user has the correct cap\n return current_user_can('edit_h5p_contents') ? $content : NULL;\n }\n\n // Log view\n new H5P_Event('content', 'shortcode',\n $content['id'],\n $content['title'],\n $content['library']['name'],\n $content['library']['majorVersion'] . '.' . $content['library']['minorVersion']);\n\n return $this->add_assets($content);\n }", "public static function exampleShortcode($atts, $content = null){\n\t\treturn '<div class=\"example-shortcode\">' . do_shortcode($content) . '</div>';\n\t}", "public function shortcode( $attrs, $content = '' ) {\n\t\trequire_once( dirname( __FILE__ ) . '/vendor/autoload.php' );\n\n\t\tif ( $content === '' ) {\n\t\t\t$content = empty($attrs) ? '' : implode( ' ', array_values( $attrs ) );\n\t\t}\n\n\t\t$cow = \\Cowsayphp\\Farm::create( \\Cowsayphp\\Farm\\Cow::class );\n\t\treturn '<pre class=\"wp-cowsay\">' . $cow->say($content) . '</pre>';\n\t}", "function sp_two_third_sc( $atts, $content = null ) {\n\n\t\treturn '<div class=\"two-third\">' . do_shortcode( $content ) . '</div>';\n\n\t}", "function mkdf_twitter_include_shortcodes_file() {\n\t\tforeach ( glob( MIKADO_TWITTER_SHORTCODES_PATH . '/*/load.php' ) as $shortcode_load ) {\n\t\t\tinclude_once $shortcode_load;\n\t\t}\n\t\t\n\t\tdo_action( 'mkdf_twitter_action_include_shortcodes_file' );\n\t}", "function tweetbutton_shortcode($atts) {\r\n\tglobal $tweetbutton_defaults;\r\n\t$args = shortcode_atts($tweetbutton_defaults, $atts);\r\n\treturn get_tweetbutton_button($args);\r\n}", "function handle_shortcode( ) {\n\n\tenqueue_files();\n\n\treturn get_location_content( );\n\n}", "function bbboing_oik_add_shortcodes() { \r\n bw_add_shortcode( 'bbboing', 'bbboing_sc', oik_path( \"bbboing.inc\", \"bbboing\" ), false );\r\n}", "function custom_shortcode_blogslider() \n {\n require_once(TEMPLATEPATH.'/shortcode/shortcode1.php');\n }", "function wpse_74735_caption_shortcode( $attr, $content = NULL )\n{\n $caption = img_caption_shortcode( $attr, $content );\n $caption = str_replace( '<p class=\"wp-caption\"></p>', '<span class=\"wp-caption-text my_new_class', $caption );\n return $caption;\n}", "function themesflat_shortcode_register_assets() {\t\t\n\t\twp_enqueue_style( 'vc_extend_shortcode', plugins_url('assets/css/shortcodes.css', __FILE__), array() );\t\n\t\twp_enqueue_style( 'vc_extend_style', plugins_url('assets/css/shortcodes-3rd.css', __FILE__),array() );\n\t\twp_register_script( 'themesflat-carousel', plugins_url('assets/3rd/owl.carousel.js', __FILE__), array(), '1.0', true );\n\t\twp_register_script( 'themesflat-flexslider', plugins_url('assets/3rd/jquery.flexslider-min.js', __FILE__), array(), '1.0', true );\t\t\n\t\twp_register_script( 'themesflat-manific-popup', plugins_url('assets/3rd/jquery.magnific-popup.min.js', __FILE__), array(), '1.0', true );\t\t\n\t\twp_register_script( 'themesflat-counter', plugins_url('assets/3rd/jquery-countTo.js', __FILE__), array(), '1.0', true );\n\t\twp_enqueue_script( 'flat-shortcode', plugins_url('assets/js/shortcodes.js', __FILE__), array(), '1.0', true );\n\t\twp_register_script( 'themesflat-google', 'https://maps.googleapis.com/maps/api/js?key=AIzaSyCIm1AxfRgiI_w36PonGqb_uNNMsVGndKo&v=3.7', array(), '1.0', true );\n\t\twp_register_script( 'themesflat-gmap3', plugins_url('assets/3rd/gmap3.min.js', __FILE__), array(), '1.0', true );\t\n\t}", "function register_shortcodes() {\n\tadd_shortcode('gallery1', 'gallery1_callback');\n}", "function vslider_short_code($atts) {\r\n\tob_start();\r\n extract(shortcode_atts(array(\r\n\t\t\"name\" => ''\r\n\t), $atts));\r\n\tvslider($name);\r\n\t$output = ob_get_clean();\r\n\treturn $output;\r\n}", "function jetpack_shortcode_instagram( $atts ) {\n\tglobal $wp_embed;\n\n\tif ( empty( $atts['url'] ) ) {\n\t\treturn '';\n\t}\n\n\treturn $wp_embed->shortcode( $atts, $atts['url'] );\n}", "function quasar_call_gallery_shortcode($atts=null){\n\t\tif(!$atts) return;\n\t\t\n\t\tif(!function_exists('rockthemes_make_swiperslider_shortcode') && $atts['use_swiper_for_thumbnails'] === 'true'){\n\t\t\t$atts['use_swiper_for_thumbnails'] = 'false';\n\t\t}\n\t\t\n\t\tif(function_exists('rockthemes_shortcode_make_gallery')){\n\t\t\techo rockthemes_shortcode_make_gallery($atts);\n\t\t}\n\t\t\n\t\treturn;\n\t}", "function sp_three_four_sc( $atts, $content = null ) {\n\n\t\treturn '<div class=\"three_fourth\">' . do_shortcode( $content ) . '</div>';\n\n\t}", "function sp_framework_toggle_content_sc( $atts, $content = null ) {\n\n\t\textract( shortcode_atts( array(\n\t\t\t'title' => ''\n\t\t), $atts ) );\n\t\t\n\t\t$output = '<div class=\"toggle-wrap\">';\n\t\t$output .= '<span class=\"trigger\"><a href=\"#\">' . esc_attr( $title ) . '</a></span><div class=\"toggle-container\">';\n\t\t$output .= $content; \n\t\t$output .= '</div></div>';\n\n\t\treturn $output;\n\t\n\t}", "function xcontent_tag_block_cloud_show($options)\n{\n include_once XOOPS_ROOT_PATH.\"/modules/tag/blocks/block.php\";\n return tag_block_cloud_show($options, $module_dirname);\n}", "function hello_shortcode($atts, $content = null, $tag){\n //put $atts in $a..\n $a = shortcode_atts(array(\n 'class' => 'no_class'\n ), $atts);\n\n return \"<div class='small=12 panel rounded \" . $a['class'] . \"'>\" . $content . \"</div>\";\n}", "function uvasomcme_register_shortcodes(){\n add_shortcode( 'uvasomcmecourselist', 'uvasomcmecourses_do_loop' );\n add_shortcode('uvasomcmecourse','uvasomcmecourse_single');\n}", "function x_add_social_sharing ( $content ) {\n\t\n if ( is_singular('post') ) {\n\t \n echo do_shortcode('[share title=\"Share this Post\" facebook=\"true\" twitter=\"true\" google_plus=\"true\" linkedin=\"true\" pinterest=\"false\" reddit=\"false\" email=\"true\"]');\n \n }\n}", "function inline_play_handler( $atts, $content = null ) {\n\t\t\t\n\t\t\tif ( !$this->external_call && (is_home() || is_archive()) && $this->theSettings['player_onblog'] == \"false\" ) { \n\t\t\t\treturn; \n\t\t\t}\n\t\t\t$id = $this->Player_ID;\t\t\t\n\t\t\textract(shortcode_atts(array( // Defaults\n\t\t\t\t'bold' => 'y',\n\t\t\t\t'play' => 'Play',\n\t\t\t\t'track' => '',\n\t\t\t\t'caption' => '',\n\t\t\t\t'flip' => 'l',\n\t\t\t\t'title' => '#USE#',\n\t\t\t\t'stop' => 'Stop',\n\t\t\t\t'ind' => 'y',\n\t\t\t\t'autoplay' => $this->theSettings['auto_play'],\n\t\t\t\t'loop' => 'false',\n\t\t\t\t'vol' => $this->theSettings['initial_vol'],\n\t\t\t\t'flow' => 'n'\n\t\t\t), $atts));\n\t\t\t\t\t\n\t\t\tif ( $track == \"\" ) { // Auto increment \n\t\t\t\tif ( !$this->has_fields || $this->external_call ) { return; }\n\t\t\t\t$track = ++$this->single_autocount;\n\t\t\t\t$arb = \"\";\n\t\t\t} \n\t\t\telseif ( is_numeric($track) ) { // Has a track number\n\t\t\t\tif ( !$this->has_fields || $this->external_call ) { return; }\n\t\t\t\t$arb = \"\";\n\t\t\t} \n\t\t\telse { // Has arbitrary file/uri\t\t\t\t\n\t\t\t\tif ( !$this->string_pushto_playlist( $track, $caption, \"1\" ) ) { return; }\n\t\t\t\t$track = $this->InlinePlaylist['count'];\t\t\t\t\t\n\t\t\t\t$arb = \"arb\";\n\t\t\t}\n\t\t\t\n\t\t\t$divO = \"\";\n\t\t\t$divC = \"\";\n\t\t\tif ( $flow == \"n\" || $this->external_call ) {\n\t\t\t\t$divO = \"<div style=\\\"font-size:14px; line-height:22px !important; margin:0 !important;\\\">\";\n\t\t\t\t$divC = \"</div>\";\n\t\t\t}\n\t\t\t\n\t\t\t$playername = ( $arb != \"\" ) ? \"foxInline\" : $this->has_fields;\n\t\t\t\n\t\t\t// Set font weight\n\t\t\t$b = ( $bold == \"false\" || $bold == \"0\" || $bold == \"n\" ) ? \" style=\\\"font-weight:500;\\\"\" : \" style=\\\"font-weight:700;\\\"\";\n\t\t\t\n\t\t\t// Set spacer between elements depending on play/stop/title\n\t\t\tif ( $play != \"\" && $title != \"\" ){\t\n\t\t\t\t$spacer = \"&nbsp;\"; \n\t\t\t} else {\n\t\t\t\t$spacer = \"\";\n\t\t\t\tif ( $play == \"\" && $stop != \"\" ) { $stop = \" \" . $stop; }\n\t\t\t}\n\t\t\t// Prep title\n\t\t\t$customtitle = ( $title == \"#USE#\" ) ? \"\" : $title;\n\t\t\t\n\t\t\t// Make id'd span elements\n\t\t\t$openWrap = $divO . \"<span id=\\\"playpause_wrap_mp3j_\" . $id . \"\\\" class=\\\"wrap_inline_mp3j\\\"\" . $b . \">\";\n\t\t\t//$pos = \"<span class=\\\"bars_mp3j\\\"><span class=\\\"load_mp3j\\\" id=\\\"load_mp3j_\" . $id . \"\\\" style=\\\"background:\" . $this->Colours['loadbar_colour'] . \";\\\"></span><span class=\\\"posbar_mp3j\\\" id=\\\"posbar_mp3j_\" . $id. \"\\\"></span></span>\";\n\t\t\t$pos = \"<span class=\\\"bars_mp3j\\\"><span class=\\\"load_mp3j\\\" id=\\\"load_mp3j_\" . $id . \"\\\"></span><span class=\\\"posbar_mp3j\\\" id=\\\"posbar_mp3j_\" . $id. \"\\\"></span></span>\";\n\t\t\t//$play_h = \"<span class=\\\"textbutton_mp3j\\\" id=\\\"playpause_mp3j_\" . $id . \"\\\" style=\\\"color:\" . $this->Colours['list_current_colour'] . \";\\\">\" . $play . \"</span>\";\n\t\t\t$play_h = \"<span class=\\\"textbutton_mp3j\\\" id=\\\"playpause_mp3j_\" . $id . \"\\\">\" . $play . \"</span>\";\n\t\t\t$title_h = ( $title == \"#USE#\" || $title != \"\" ) ? \"<span class=\\\"T_mp3j\\\" id=\\\"T_mp3j_\" . $id . \"\\\">\" . $customtitle . \"</span>\" : \"\";\n\t\t\t$closeWrap = ( $ind != \"y\" ) ? \"<span style=\\\"display:none;\\\" id=\\\"indi_mp3j_\" . $id . \"\\\"></span></span>\" . $divC : \"<span class=\\\"indi_mp3j\\\" id=\\\"indi_mp3j_\" . $id . \"\\\"></span></span>\" . $divC;\n\t\t\t\n\t\t\t// SHOULD THIS GO SOMEWHERE IN SPAN FORMAT??\n\t\t\t$vol_h = \"<div class=\\\"vol_mp3j\\\" id=\\\"vol_mp3j_\" . $id . \"\\\"></div>\";\n\t\t\t\n\t\t\t// Assemble them\t\t\n\t\t\t$html = ( $flip != \"l\" ) ? $openWrap . $pos . $title_h . $spacer . $play_h . $closeWrap : $openWrap . $pos . $play_h . $spacer . $title_h . $closeWrap;\n\t\t\t\n\t\t\t// Add title to js footer string if needed \n\t\t\tif ( $title_h != \"\" && $title == \"#USE#\" ) {\n\t\t\t\t$this->Footerjs .= \"jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append(\" . $playername . \"[\" . ($track-1) . \"].name);\\n\";\n\t\t\t\t//$this->Footerjs .= \"jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append('<span style=\\\"font-size:.7em;\\\"> - '+\" . $playername . \"[\" . ($track-1) . \"].artist+'</span>');\\n\";\n\t\t\t\t$this->Footerjs .= \"if (\" . $playername . \"[\" . ($track-1) . \"].artist !==''){ jQuery(\\\"#T_mp3j_\" . $id . \"\\\").append('<span style=\\\"font-size:.75em;\\\"> - '+\" . $playername . \"[\" . ($track-1) . \"].artist+'</span>'); }\\n\";\n\t\t\t}\n\t\t\t// Add info to js info array\n\t\t\t$autoplay = ( $autoplay == \"true\" || $autoplay == \"y\" || $autoplay == \"1\" ) ? \"true\" : \"false\";\n\t\t\t$loop = ( $loop != \"false\" ) ? \"true\" : \"false\";\n\t\t\t$this->jsInfo[] = \"\\n { list:\" . $playername . \", type:'single', tr:\" . ($track-1) . \", lstate:'', loop:\" . $loop . \", play_txt:'\" . $play . \"', pause_txt:'\" . $stop . \"', pp_title:'', autoplay:\" . $autoplay . \", has_ul:0, transport:'playpause', status:'basic', download:false, vol:\" . $vol . \", height:'' }\";\n\t\t\t\n\t\t\t$this->write_jp_div();\n\t\t\t$this->Player_ID++;\n\t\t\treturn $html;\n\t\t}", "function launchpad_caption_shortcode($attr, $content) {\n\tpreg_match_all('/<img.*?src=\"(.*?)\".*?>/', $content, $imgs);\n\tpreg_match_all('/<a.*?href=\"(.*?)\".*?>/', $content, $links);\n\t\n\t$content = preg_replace('/^.*?</', '<', $content);\n\tif(preg_match('/^<a/', $content)) {\n\t\t$content = preg_replace('/^<a.*?>.*?<\\/a>/', '', $content);\n\t} else {\n\t\t$content = preg_replace('/^<img.*?>/', '', $content);\n\t}\n\t\n\t$return = '<figure class=\"wp-caption';\n\tif($attr['align']) {\n\t\t$return .= ' ' . $attr['align'];\n\t}\n\t$return .= '\"';\n\tif($attr['width']) {\n\t\t$return .= ' style=\"width: ' . $attr['width'] . 'px;\"';\n\t}\n\t$return .= '>';\n\tif(isset($links[0][0])) {\n\t\t$return .= $links[0][0];\n\t}\n\tif(isset($imgs[0][0])) {\n\t\t$return .= $imgs[0][0];\n\t}\n\tif(isset($links[0][0])) {\n\t\t$return .= '</a>';\n\t}\n\t$return .= '<figcaption>' . $content . '</figcaption>';\n\t$return .= '</figure>';\n\t\n\treturn $return;\n}", "public function run_shortcode($content)\n {\n }", "public function owlslider_shortcode( $atts = array() ) {\r\n return $this->owlslider( $atts, false );\r\n }", "function button_shortcode($atts, $content = NULL) {\n $a = shortcode_atts( array(\n 'class' => ''\n ), $atts );\n $content = '<span class=\"button '.$class.'\">'.$content.'</span>';\n return $content;\n}", "function opening_times_pull_quote( $atts, $content = null ) {\n\treturn '<span class=\"pullquote\">' . do_shortcode($content) . '</span>';\n}" ]
[ "0.7614931", "0.7126833", "0.6748385", "0.6513087", "0.64038557", "0.6395242", "0.63543874", "0.6254899", "0.6220431", "0.61593246", "0.60787284", "0.60710824", "0.60671663", "0.60114527", "0.59701157", "0.59552765", "0.59158665", "0.5895689", "0.5885345", "0.5867948", "0.5840124", "0.58221096", "0.58113724", "0.58085066", "0.57990783", "0.57698536", "0.5761913", "0.57380444", "0.5732356", "0.572122", "0.57156813", "0.57155097", "0.5700341", "0.56972504", "0.5677733", "0.56774074", "0.56724024", "0.56682163", "0.56635654", "0.56518966", "0.56326455", "0.5629106", "0.56273586", "0.5623651", "0.5591545", "0.55774176", "0.5568149", "0.55470455", "0.5546544", "0.55430174", "0.5541955", "0.55379754", "0.55357236", "0.5527447", "0.55255145", "0.5517819", "0.5515951", "0.5506424", "0.5502468", "0.5501875", "0.54961693", "0.54940414", "0.5492255", "0.5490754", "0.54899746", "0.54850656", "0.54801816", "0.54745185", "0.5471957", "0.54681915", "0.54664725", "0.5459935", "0.5453788", "0.544987", "0.54406214", "0.54366493", "0.5430652", "0.5411473", "0.5403706", "0.54020435", "0.5397867", "0.53905", "0.53857523", "0.5384517", "0.53820246", "0.5379942", "0.5378663", "0.5376323", "0.5376141", "0.53743625", "0.5371484", "0.53686", "0.5366958", "0.5360422", "0.53543246", "0.5351728", "0.5344046", "0.53434634", "0.5338379", "0.53348005" ]
0.7011954
2
InviteHistoryHandler::buildConditionQuery() To set sql query condition
public function buildConditionQuery() { $this->sql_condition = ' user_id='.$this->CFG['user']['user_id']; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function setConditions() {\r\n if( count($this->sqlConditions) ) {\r\n $this->sql .= ' WHERE ' . $this->sqlStrConditions;\r\n }\r\n }", "protected function buildQuery()\n\t{\n\t\t$this->query = count($this->conditions) ? 'WHERE ' . implode(' AND ', $this->conditions) : '';\n\t}", "private function getSQLCondition() {\n\t\t// the manager can see everyone in the department\n\t\t// the admin and everybody else can see everyone in the company.\n\t\tswitch ($this->page->config['user_level']) {\n\t\t\tcase lu_manager:\n\t\t\tcase lu_employee:\n\t\t\tcase lu_admin:\n\t\t\t\t$sql = 'WHERE 1 = 2';\n\t\t\t\tbreak;\t//nobody below GM can access this subject\n\t\t\tcase lu_gm:\n\t\t\tcase lu_owner:\n\t\t\t\t$sql = ' WHERE c.company_id = '.$this->page->company['company_id'];\n\t\t}\n\t\treturn $sql;\n\t}", "private function getSQLCondition() {\n\t\t// the manager can see everyone in the department\n\t\t// the admin and everybody else can see everyone in the company.\n\t\tswitch ($this->page->config['user_level']) {\n\t\t\tcase lu_manager:\n\t\t\tcase lu_employee:\n\t\t\tcase lu_admin:\n\t\t\tcase lu_gm:\n\t\t\tcase lu_owner:\n\t\t\t\t$sql = ' WHERE l.company_id = '.$this->page->company['company_id'];\n\t\t}\n\t\treturn $sql;\n\t}", "public function getCondition() {\n\n \t$condition = array();\n \t$this->getQueryString(\"keyword\", $condition);\n \t$this->getQueryString(\"activityId\", $condition);\n \t$this->getQueryString(\"activityIds\", $condition);\n \t$this->getQueryString(\"activityType\", $condition);\n $this->getQueryString(\"state\", $condition);\n $this->getQueryString(\"orderDateStart\", $condition);\n $this->getQueryString(\"orderDateEnd\", $condition);\n $this->getQueryString(\"deliveryDateStart\", $condition);\n $this->getQueryString(\"deliveryDateEnd\", $condition);\n $this->getQueryString(\"serial\", $condition);\n $this->getQueryString(\"consumerId\", $condition);\n $this->getQueryString(\"payDateTimeStart\", $condition);\n $this->getQueryString(\"payDateTimeEnd\", $condition);\n $this->getQueryString(\"productId\", $condition);\n $this->getQueryString(\"deliveryId\", $condition);\n $this->getQueryString(\"productArray\", $condition);\n \n \treturn $condition;\n }", "protected function _buildCondition(){\n \t$aryCondition = array();\n \t\n \tif(!empty($this->postData)){\n \t\t //search\n\t\t\t \t\t\t\n\t\t\tif($this->postData['title']!=''){\n \t\t \t$aryCondition['like'][] = array(\"mt.title\"=>$this->postData['title']);\n \t\t }\t\t\t\n\t\t\tif($this->postData['page']!=''){\n \t\t \t$aryCondition['and'][] = array(\"mt.page\"=>$this->postData['page']);\n \t\t }\t\t\t\n\t\t\tif($this->postData['code']!=''){\n \t\t \t$aryCondition['like'][] = array(\"mt.code\"=>$this->postData['code']);\n \t\t }\t\t\t\n\t\t\tif($this->postData['status']!=''){\n \t\t \t$aryCondition['and'][] = array(\"mt.status\"=>$this->postData['status']);\n \t\t }\t\t\t\n\n \t}\n \treturn $aryCondition;\n }", "protected function _buildWhere(&$query)\r\n {\r\n\r\n\r\n \t//if($this->_checkin!=null)\r\n \t//{\r\n \t//\t$query->where('ltap.ltap_qdatu = \"'.$this->_confdate.'\"');\r\n \t//}\r\n return $query;\r\n }", "protected function construct_where_clause() {\n\t\t\t$whereclause = $this->get_where_clause();\n\t\t\tif ( '' !== $whereclause ) {\n\t\t\t\t$this->where = '' === $this->where ? \" where ($whereclause) \" : \" {$this->where} and ($whereclause) \";\n\t\t\t}\n\t\t}", "function get_condition()\r\n {\r\n $owner = $this->owner;\r\n\r\n $conds = array();\r\n $parent = $this->parent;\r\n $category = $parent->get_parameter(WeblcmsManager :: PARAM_CATEGORY);\r\n $category = $category ? $category : 0;\r\n $conds[] = new EqualityCondition(ContentObjectPublication :: PROPERTY_CATEGORY_ID, $category, ContentObjectPublication :: get_table_name());\r\n\r\n $type_cond = array();\r\n $types = array(Assessment :: get_type_name(), Survey :: get_type_name(), Hotpotatoes :: get_type_name());\r\n foreach ($types as $type)\r\n {\r\n $type_cond[] = new EqualityCondition(ContentObject :: PROPERTY_TYPE, $type);\r\n }\r\n $conds[] = new OrCondition($type_cond);\r\n $c = Utilities :: query_to_condition($this->query);\r\n if (! is_null($c))\r\n {\r\n $conds[] = $c;\r\n }\r\n return new AndCondition($conds);\r\n }", "protected function getWhereClause() {}", "function makeTriggerSQL($condition_ix)\n{\n $triggerSQLs = array();\n $joins = array();\n foreach($this->triggers as $trg_ix => $triggerFields){\n $defSnips = array();\n foreach($triggerFields as $triggerField){\n $def = $triggerField->getDef();\n $defSnips[] = $def['snippet'];\n $joins = array_merge($joins, $def['joins']);\n }\n $SQL = \"CASE WHEN \";\n $SQL .= join(' AND ', $defSnips);\n //$SQL .= \" THEN 1 ELSE NULL END\";\n $SQL .= \" THEN 'C{$condition_ix}Tr{$trg_ix}' ELSE NULL END\";\n $triggerSQLs[] = $SQL;\n }\n\n if(count($this->triggers) > 1){\n //$SQL = \"COALESCE(\".join(',', $triggerSQLs).\")\";\n $SQL = \"CONCAT_WS(',', \".join(',', $triggerSQLs).\")\";\n }\n $SQL .= \" AS Condition_$condition_ix\";\n return array('triggerExpr' => $SQL, 'joins' => $joins);\n}", "private function buildWhere()\n {\n $query = array();\n\n // Make sure there's something to do\n if (isset($this->query['where']) and count($this->query['where'])) {\n foreach ($this->query['where'] as $group => $conditions) {\n $group = array(); // Yes, because the $group above is not used, get over it.\n foreach ($conditions as $condition => $value) {\n // Get column name\n $cond = explode(\" \", $condition);\n $column = str_replace('`', '', $cond[0]);\n $safeColumn = $this->columnName($column);\n\n // Make the column name safe\n $condition = str_replace($column, $safeColumn, $condition);\n\n // Add value to the bind queue\n $valueBindKey = str_replace(array('.', '`'), array('_', ''), $safeColumn);\n\n if (!empty($value) or $value !== null) {\n $this->valuesToBind[$valueBindKey] = $value;\n }\n\n // Add condition to group\n $group[] = str_replace(\"?\", \":{$valueBindKey}\", $condition);\n }\n\n // Add the group\n $query[] = \"(\" . implode(\" AND \", $group) . \")\";\n }\n\n // Return\n return \"WHERE \" . implode(\" OR \", $query);\n }\n }", "protected function user_where_clause() {}", "function sql_condition_statemment(array $criteria, int $totalCount)\n {\n // Init\n $sql = \"\";\n\n // Rendr base on condition\n $count = 0;\n foreach ($criteria as $filter => $value) {\n\n $str = (is_array($value)) \n ? objectSearchHandle($filter, $value)\n : \"$filter = '$value'\";\n \n $is_not_last = ($totalCount - 1 != $count);\n\n if($str):\n $sql .= $str;\n $sql .= ($is_not_last) ? \" AND \" : \"\";\n endif;\n\n $count ++;\n }\n // Return\n return $sql;\n }", "protected function buildWhereClause() {\r\n\t\t$sql='';\r\n\t\tif (count($this->_salt_wheres)>0) {\r\n\t\t\t$sql.=' WHERE '.implode(' ', $this->_salt_wheres);\r\n\t\t}\r\n\t\treturn $sql;\r\n\r\n\t}", "public function condition()\n {\n $op = $this->getDefaultOperator();\n $params = func_get_args();\n \n switch (count($params)) {\n case 1:\n if (is_string($params[0])) {\n $this->addCondition('literal', [$params[0]]);\n } elseif (is_array($params[0])) {\n $combination = $this->getDefaultOperator();\n \n /**\n * The code within the foreach is an extraction of Zend\\Db\\Sql\\Select::where()\n */\n foreach ($params[0] as $pkey => $pvalue) {\n if (is_string($pkey) && strpos($pkey, '?') !== false) {\n # ['id = ?' => 1]\n # ['id IN (?, ?, ?)' => [1, 3, 4]]\n $predicate = new ZfPredicate\\Expression($pkey, $pvalue);\n } elseif (is_string($pkey)) {\n if ($pvalue === null) {\n # ['name' => null] -> \"ISNULL(name)\"\n $predicate = new ZfPredicate\\IsNull($pkey, $pvalue);\n } elseif (is_array($pvalue)) {\n # ['id' => [1, 2, 3]] -> \"id IN (1, 2, 3)\"\n $predicate = new ZfPredicate\\In($pkey, $pvalue);\n } else {\n # ['id' => $id] -> \"id = 15\"\n $predicate = new ZfPredicate\\Operator($pkey, ZfPredicate\\Operator::OP_EQ, $pvalue);\n }\n } elseif ($pvalue instanceof ZfPredicate\\PredicateInterface) {\n $predicate = $pvalue;\n } else {\n # ['id = ?'] -> \"id = ''\"\n # ['id = 1'] -> literal.\n $predicate = (strpos($pvalue, Expression::PLACEHOLDER) !== false)\n ? new ZfPredicate\\Expression($pvalue) : new ZfPredicate\\Literal($pvalue);\n }\n $this->getCurrentPredicate()->addPredicate($predicate, $combination);\n }\n }\n break;\n \n case 2:\n # $rel->where('foo = ? AND id IN (?) AND bar = ?', [true, [1, 2, 3], false]);\n # If passing a non-array value:\n # $rel->where('foo = ?', 1);\n # But if an array is to be passed, must be inside another array\n # $rel->where('id IN (?)', [[1, 2, 3]]);\n if (!is_array($params[1])) {\n $params[1] = [$params[1]];\n }\n $this->expandPlaceholders($params[0], $params[1]);\n $this->addCondition('expression', [$params[0], $params[1]]);\n break;\n \n case 3:\n # $rel->where('id', '>', 2);\n $this->getCurrentPredicate()->addPredicate(\n new ZfPredicate\\Operator($params[0], $params[1], $params[2])\n );\n break;\n \n default:\n throw new Exception\\BadMethodCallException(\n sprintf(\n \"One to three arguments are expected, %s passed\",\n count($params)\n )\n );\n }\n \n return $this;\n }", "private function addConditionToQuery($sqlPart) {\n if (empty($sqlPart)) {\n return;\n }\n $this->sql .= $sqlPart;\n }", "function build_sql_conditions( $args = array() ){\r\n\t\tglobal $wpdb;\r\n\t\t$events_table = $wpdb->prefix . EM_EVENTS_TABLE;\r\n\t\t$locations_table = $wpdb->prefix . EM_LOCATIONS_TABLE;\r\n\t\t\r\n\t\t$conditions = parent::build_sql_conditions($args);\r\n\t\t//eventful locations\r\n\t\tif( true == $args['eventful'] ){\r\n\t\t\t$conditions[] = \"{$events_table}.event_id IS NOT NULL\";\r\n\t\t}elseif( true == $args['eventless'] ){\r\n\t\t\t$conditions[] = \"{$events_table}.event_id IS NULL\";\r\n\t\t}\r\n\t\treturn $conditions;\r\n\t}", "public function buildWhereClause()\n {\n $criterias = $this->bean->ownCriteria;\n if (empty($criterias)) {\n return '1';\n }// find all because there are no criterias\n $where = array();\n $this->filter_values = array();\n //$mask = \" %s %s %s\"; // login, field, op (with masked value)\n $n = 0;\n foreach ($criterias as $id=>$criteria) {\n if (! $criteria->op) {\n continue;\n } // skip all entries that say any!\n if ($criteria->value === null || $criteria->value === '') {\n continue;\n } // skip all empty\n $n++;\n $logic = 'AND ';//$criteria->logic;\n if ($n == 1) {\n $logic = '';\n }\n $where[] = $logic.$criteria->makeWherePart($this);\n }\n\n if (empty($where)) {\n return '1';\n }// find all because there was no active criteria\n\n $where = implode(' ', $where);\n return $where;\n }", "protected function getQueryCondition()\n {\n $parts = [];\n foreach ($this->fields as $field) {\n $parts[] = \"{$field} LIKE :pattern\";\n }\n return implode(' AND ', $parts);\n }", "public function build()\n {\n return empty($this->conditions) ? '' : ' WHERE '.implode(' AND ', $this->conditions);\n }", "function channel_entries_sql_where($sql, &$channel)\n\t{\n\n\t\tif ( is_string( $this->EE->extensions->last_call ) === TRUE )\n\t\t{\n\t\t\t$sql\t= $this->EE->extensions->last_call;\n\t\t}\n\n\t\t/** ----------------------------------------\n\t\t/**\tShould we proceed?\n\t\t/** ----------------------------------------*/\n\n\t\tif ( $this->EE->TMPL->fetch_param('date_field') === FALSE OR $this->EE->TMPL->fetch_param('date_field') == '' )\n\t\t{\n\t\t\treturn $sql;\n\t\t}\n\n\t\tif ( ( $this->EE->TMPL->fetch_param('date_field_start') === FALSE OR $this->EE->TMPL->fetch_param('date_field_start') == '' ) AND ( $this->EE->TMPL->fetch_param('date_field_stop') === FALSE OR $this->EE->TMPL->fetch_param('date_field_stop') == '' ) )\n\t\t{\n\t\t\treturn $sql;\n\t\t}\n\n\t\tif ( empty( $this->EE->TMPL->site_ids ) )\n\t\t{\n\t\t\treturn $sql;\n\t\t}\n\n\t\t/** ----------------------------------------\n\t\t/**\tLoop for site ids and add DB queries\n\t\t/** ----------------------------------------*/\n\n\t\t$sql_a\t= array();\n\n\t\tforeach ( $this->EE->TMPL->site_ids as $site_id )\n\t\t{\n\t\t\tif ( ! empty( $channel->dfields[$site_id][ $this->EE->TMPL->fetch_param('date_field') ] ) )\n\t\t\t{\n\t\t\t\t$field_id\t= $channel->dfields[$site_id][ $this->EE->TMPL->fetch_param('date_field') ];\n\n\t\t\t\t$sql_b\t= array();\n\n\t\t\t\tif ( $this->EE->TMPL->fetch_param('date_field_start') != '' )\n\t\t\t\t{\n\t\t\t\t\t$sql_b[]\t= \" ( wd.field_id_{$field_id} >= '\".$this->EE->localize->string_to_timestamp( $this->EE->db->escape_str( $this->EE->TMPL->fetch_param('date_field_start') ) ).\"' AND wd.site_id = \" . $this->EE->db->escape_str( $site_id ) . \" )\";\n\n\t\t\t\t}\n\n\t\t\t\tif ( $this->EE->TMPL->fetch_param('date_field_stop') != '' )\n\t\t\t\t{\n\t\t\t\t\t$sql_b[]\t= \" ( wd.field_id_{$field_id} < '\".$this->EE->localize->string_to_timestamp( $this->EE->db->escape_str( $this->EE->TMPL->fetch_param('date_field_stop') ) ).\"' AND wd.site_id = \" . $this->EE->db->escape_str( $site_id ) . \" )\";\n\t\t\t\t}\n\n\t\t\t\t$sql_a[]\t= implode( ' AND ', $sql_b );\n\t\t\t}\n\t\t}\n\n\t\tif ( ! empty( $sql_a ) )\n\t\t{\n\t\t\t/** ----------------------------------------\n\t\t\t/**\tPrepare the necessary DB join\n\t\t\t/** ----------------------------------------*/\n\n\t\t\tif ( strpos($sql, 'LEFT JOIN exp_channel_data') === FALSE )\n\t\t\t{\n\t\t\t\t$sql = str_replace( 'LEFT JOIN exp_members', 'LEFT JOIN exp_channel_data AS wd ON wd.entry_id = t.entry_id LEFT JOIN exp_members', $sql );\n\t\t\t}\n\n\t\t\t/** ----------------------------------------\n\t\t\t/**\tAdd our new conditions\n\t\t\t/** ----------------------------------------*/\n\n\t\t\t$sql\t.= \" AND ( \" . implode( ' OR ', $sql_a ) . \" )\";\n\t\t}\n\n\t\t/*\n\t\tif ( $SESS->userdata('group_id') == '1' )\n\t\t{\n\t\t\techo \"Visible only to Super Admins<br /><br />\";\n\t\t\tprint_r( $sql );\n\t\t\techo \"<br /><br />Visible only to Super Admins\";\n\t\t}\n\t\t*/\n\t\treturn $sql;\n\t}", "public function addCondition($condition);", "public function appendConditions( $criteria, $condition, $params )\n {\n\n\n // append codition if the query has a default filter\n if( $this->condition )\n {\n if( ctype_digit($this->condition) )\n {\n $criteria->where( 'project_task.rowid = '.$this->condition );\n }\n else if( is_string($this->condition) )\n {\n $criteria->where( $this->condition );\n }\n else if( is_array($this->condition) )\n {\n $this->checkConditions( $criteria, $this->condition );\n }\n }\n\n if( $condition )\n {\n if( ctype_digit($condition ) )\n {\n $criteria->where( 'project_task.rowid = '.$condition );\n }\n else if( is_string($condition) )\n {\n $criteria->where( $condition );\n }\n else if( is_array($condition) )\n {\n $this->checkConditions( $criteria, $condition );\n }\n }\n\n\n if( $params->begin )\n {\n $this->checkCharBegin( $criteria, $params );\n }\n\n }", "protected function _whereCondition($condition) \n\t{\n\t\t$result = 'WHERE ';\n\n\t\tforeach ($condition as $key => $value) {\n\t\t\tif (in_array($key, $this->_fields)) {\n\t\t\t\tif (!is_array($value)) {\n\t\t\t\t\t$this->_stringData($condition);\n\t\t\t\t\t$result .= \"`\" . $key . \"`=\" . $value. ' AND ';\n\t\t\t\t} else {\n\t\t\t\t\t$result .= $this->_moreWhere($key, $value);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t//substr last 'and'\n\t\t$result = substr($result, 0, -5);\n\n\t\treturn $result;\n\t}", "static function add_condition($where=array(),$cond='',$key=NULL,$value=NULL) {\n\tif ($cond) $where['cond'][]=$cond;\n\t$args=func_get_args();\n\tfor ($i=2; $i<count($args); $i=$i+2) {\n\t\tif (isset($args[$i])) $where['value'][$args[$i]]=isset($args[$i+1])?$args[$i+1]:NULL;\n\t}\n\treturn $where;\n}", "private static function buildCondition($params)\n {\n if (isset($params['where'])) {\n $conditions = [];\n foreach ($params['where'] as $field => $value) {\n $conditions[] = \"{$field}='{$value}'\";\n }\n\n return ' where ' . implode(' and ', $conditions);\n }\n\n return '';\n }", "function s_m_put_get_condition($ref_id_db_arr, $ref_data){\r\n $where = \"\";\r\n for($i = 0; $i < count($ref_id_db_arr); $i++){\r\n $where .= $ref_id_db_arr[$i] . \"='\" . $ref_data[$i] . \"'' AND \";\r\n }\r\n return substr($where, 0, strlen($where) - 5);\r\n}", "public function getJoinCondition() {}", "function getJoinCondition() ;", "private function appendWhere()\n\t{\n\t\t$whereCount = count($this->where);\n\n\t\tfor($i = 0; $i < $whereCount; $i++)\n\t\t{\n\t\t\t$where = $this->where[$i];\n\n\t\t\tif($i == 0)\n\t\t\t{\n\t\t\t\t$this->queryString .= self::WHERE;\n\t\t\t}\n\n\t\t\t$this->queryString .= $where->getCondition();\n\n\t\t\tif($i < $whereCount-1)\n\t\t\t{\n\t\t\t\t$this->queryString .= \" \" . $where->getOperator() . \" \";\n\t\t\t}\n\t\t}\n\t}", "protected function getGeneralWhereClause() {}", "function getSQLWhereCondition($query_header, $post, $config_language_id)\n {\n $sql = \" WHERE pd.language_id = '\" . (int) $config_language_id . \"' \";\n\n // Filter by categories\n if (isset($post['categories'])) {\n $category_ids = array_map('intval', $post['categories']);\n $category_ids = implode(\",\", $category_ids);\n\n $sql .= \" AND p2c.category_id IN (\" . $category_ids . \") \";\n }\n\n // Filter by manufacturers\n if (isset($post['manufacturers'])) {\n $manufacturer_ids = array_map('intval', $post['manufacturers']);\n $manufacturer_ids = implode(\",\", $manufacturer_ids);\n\n $sql .= \" AND p.manufacturer_id IN (\" . $manufacturer_ids . \") \";\n }\n\n // Filter by special_groups\n if (isset($post['special_groups'])) {\n $special_groups_ids = array_map('intval', $post['special_groups']);\n $special_groups_ids = implode(\",\", $special_groups_ids);\n\n $sql .= \" AND ps.product_special_group_id IN (\" . $special_groups_ids . \") \";\n }\n\n // Attach additional chosen products\n if (isset($post['products'])) {\n $product_ids = array_map('intval', $post['products']['id']);\n\n $sql .= \" UNION \" . $query_header;\n $sql .= \" WHERE ps.product_id IN (\" . implode(\",\", $product_ids) . \") AND pd.language_id = '\" . (int) $config_language_id . \"' \";\n }\n\n return $sql;\n }", "function addConditionalsToQuery($query, $filledFormFields) {\n\t// Testing if we have to fill the conditional of our SQL statement\n\tif(count($filledFormFields) > 0) {\n\t\t$query .= \" WHERE \";\n\n\n\t\t// Adding the conditionals to the query\n\t\t$i = 0;\n\t\tforeach($filledFormFields as $fieldKey => $fieldValue) {\n\t\t\t// Appending the new conditional\n\t\t\t$queryAppendage = $fieldKey . \" LIKE :\" . $fieldKey . \" \";\n\n\t\t\t$query .= $queryAppendage;\n\t\t\t\n\t\t\t// If there's more conditionals after this, append an \"AND\" as well.\n\t\t\tif($i < count($filledFormFields) - 1) \n\t\t\t\t$query .= \" AND \";\n\n\t\t\t$i++;\n\t\t}\n\t}\n\n\treturn $query;\n}", "private function getQueryConditions($sql, $profileIsp, $profileItemCond, $typeFieldName)\n {\n $itemDataType = $profileIsp['item_data_type'];\n if ($itemDataType == 'S') {\n $ispCatArray = array_column($profileIsp['category_type'], 'value');\n $inString = \"'\" . implode(\"','\", $ispCatArray) . \"'\";\n $this->query[] = $sql . \" (\" . $typeFieldName . \" = \" . $profileIsp['id'] . \" AND metadata_value IN (\" . $inString . \") $profileItemCond ) \";\n } elseif ($itemDataType == 'D') {\n $this->query[] = $sql . \" (\" . $typeFieldName . \" = \" . $profileIsp['id'] . \" AND STR_TO_DATE(metadata_value, \\\"%m/%d/%Y\\\") >= '\" . $profileIsp['start_date'] . \"' AND STR_TO_DATE(metadata_value, \\\"%m/%d/%Y\\\") <= '\" . $profileIsp['end_date'] . \"' $profileItemCond ) \";\n } elseif ($itemDataType == 'N') {\n if ($profileIsp['is_single']) {\n $this->query[] = $sql . \" (\" . $typeFieldName . \" = \" . $profileIsp['id'] . \" AND metadata_value = '\" . $profileIsp['single_value'] . \"' $profileItemCond ) \";\n } else {\n $this->query[] = $sql . \" (\" . $typeFieldName . \" = \" . $profileIsp['id'] . \" AND metadata_value >= \" . $profileIsp['min_digits'] . \" AND metadata_value <= \" . $profileIsp['max_digits'] . \" $profileItemCond) \";\n }\n }\n }", "function db_where($where, $join_and = true) {\n $where_clause = array();\n\n if (is_array($where)) {\n foreach ($where as $key => $value) {\n if (is_numeric($key)) {\n $where_clause[] = $value;\n } else {\n if (db_where_key_has_condition($key)) {\n // if has condition with it?\n // i.e array('name =' => $var) or array('age >' => $int)\n $where_clause[] = \" {$key} \\\"\".mres($value).\"\\\" \";\n } else {\n $where_clause[] = \" {$key} = \\\"\".mres($value).\"\\\" \";\n }\n }\n }\n } else {\n $where_clause[] = $where;\n }\n\n return '('.join($join_and ? ' AND ' : ' OR ', $where_clause).')';\n}", "function buildQuery(){\n\t\t$r = ($this->fieldName == \"\") ? \"SELECT * FROM \" . $this->tableName . \";\" : \"SELECT * FROM \" . $this->tableName . \" WHERE \" . $this->fieldName . \" = \" . $this->fieldValue . \";\";\n\t\t//print \"executing $r <br/>\";\n\t\treturn $r;\n\t}", "public function addConditionToQuery($query, array $condition)\n\t{\n\t\t$value = trim(array_get($condition, 'value'));\n\t\t$field = array_get($condition, 'field');\n\t\t\n\t\tif ('xref_id' == $field) {\n\t\t\t$field = 'objectID';\n\t\t}\n\t\t\n\t\tif (array_get($condition, 'filter')) {\n\t\t\tif (is_numeric($value)) {\n\t\t\t\t$query['query']['numericFilters'][] = \"{$field}={$value}\";\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$query['query']['facetFilters'][] = \"{$field}:{$value}\";\n\t\t\t}\n\t\t}\n\t\telse if (array_get($condition, 'lat')) {\n\t\t\t$query['query']['aroundLatLng'] = array_get($condition, 'lat') . ',' . array_get($condition, 'long');\n\t\t\t$query['query']['aroundRadius'] = array_get($condition, 'distance');\n\t\t}\n\t\telse {\n\t\t\t$query['terms'] .= ' ' . $value;\n\t\t\t\n\t\t\tif (!empty($field) && '*' !== $field) {\n\t\t\t\t$field = is_array($field) ? $field : array($field);\n\t\t\t\t$query['query']['restrictSearchableAttributes'] = implode(',', $field);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $query;\n\t}", "public static function build_sql_conditions( $args = array() ){\n\t\t$conditions = apply_filters( 'em_bookings_build_sql_conditions', parent::build_sql_conditions($args), $args );\n\t\tif( is_numeric($args['status']) ){\n\t\t\t$conditions['status'] = 'booking_status='.$args['status'];\n\t\t}elseif( self::array_is_numeric($args['status']) && count($args['status']) > 0 ){\n\t\t\t$conditions['status'] = 'booking_status IN ('.implode(',',$args['status']).')';\n\t\t}elseif( !is_array($args['status']) && preg_match('/^([0-9],?)+$/', $args['status']) ){\n\t\t\t$conditions['status'] = 'booking_status IN ('.$args['status'].')';\n\t\t}\n\t\tif( is_numeric($args['person']) ){\n\t\t\t$conditions['person'] = EM_BOOKINGS_TABLE.'.person_id='.$args['person'];\n\t\t}\n\t\tif( EM_MS_GLOBAL && !empty($args['blog']) && is_numeric($args['blog']) ){\n\t\t\tif( is_main_site($args['blog']) ){\n\t\t\t\t$conditions['blog'] = \"(\".EM_EVENTS_TABLE.\".blog_id={$args['blog']} OR \".EM_EVENTS_TABLE.\".blog_id IS NULL)\";\n\t\t\t}else{\n\t\t\t\t$conditions['blog'] = \"(\".EM_EVENTS_TABLE.\".blog_id={$args['blog']})\";\n\t\t\t}\n\t\t}\n\t\tif( empty($conditions['event']) && $args['event'] === false ){\n\t\t $conditions['event'] = EM_BOOKINGS_TABLE.'.event_id != 0';\n\t\t}\n\t\tif( is_numeric($args['ticket_id']) ){\n\t\t $EM_Ticket = new EM_Ticket($args['ticket_id']);\n\t\t if( $EM_Ticket->can_manage() ){\n\t\t\t\t$conditions['ticket'] = EM_BOOKINGS_TABLE.'.booking_id IN (SELECT booking_id FROM '.EM_TICKETS_BOOKINGS_TABLE.\" WHERE ticket_id='{$args['ticket_id']}')\";\n\t\t }\n\t\t}\n\t\treturn apply_filters('em_bookings_build_sql_conditions', $conditions, $args);\n\t}", "function defineCriterias($criterio,$PreparedStatement){\n\t\t\tif(isset ($criterio[\"consumo_id\"]) && trim($criterio[\"consumo_id\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND consumo_id = \".Connection::inject($criterio[\"consumo_id\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"socio_id\"]) && trim($criterio[\"socio_id\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND socio_id = \".Connection::inject($criterio[\"socio_id\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"nro_medidor\"]) && trim($criterio[\"nro_medidor\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND nro_medidor LIKE '%\".Connection::inject($criterio[\"nro_medidor\"]).\"%'\";\n\t\t\t}\n\t\t\tif(isset ($criterio[\"fecha_lectura\"]) && trim($criterio[\"fecha_lectura\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND fecha_lectura = \".Connection::inject($criterio[\"fecha_lectura\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"fecha_emision\"]) && trim($criterio[\"fecha_emision\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND fecha_emision = \".Connection::inject($criterio[\"fecha_emision\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"periodo_mes\"]) && trim($criterio[\"periodo_mes\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND periodo_mes = \".Connection::inject($criterio[\"periodo_mes\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"periodo_anio\"]) && trim($criterio[\"periodo_anio\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND periodo_anio = \".Connection::inject($criterio[\"periodo_anio\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"consumo_total_lectura\"]) && trim($criterio[\"consumo_total_lectura\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND consumo_total_lectura = \".Connection::inject($criterio[\"consumo_total_lectura\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"consumo_por_pagar\"]) && trim($criterio[\"consumo_por_pagar\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND consumo_por_pagar = \".Connection::inject($criterio[\"consumo_por_pagar\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"costo_consumo_por_pagar\"]) && trim($criterio[\"costo_consumo_por_pagar\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND costo_consumo_por_pagar = \".Connection::inject($criterio[\"costo_consumo_por_pagar\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"estado\"]) && trim($criterio[\"estado\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND estado = '\".Connection::inject($criterio[\"estado\"]).\"'\";\n\t\t\t}\n\t\t\tif(isset ($criterio[\"fecha_hora_pago\"]) && trim($criterio[\"fecha_hora_pago\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND fecha_hora_pago = \".Connection::inject($criterio[\"fecha_hora_pago\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"usuario_pago\"]) && trim($criterio[\"usuario_pago\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND usuario_pago = \".Connection::inject($criterio[\"usuario_pago\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"monto_pagado\"]) && trim($criterio[\"monto_pagado\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND monto_pagado = \".Connection::inject($criterio[\"monto_pagado\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"pagado_por\"]) && trim($criterio[\"pagado_por\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND pagado_por = \".Connection::inject($criterio[\"pagado_por\"]);\n\t\t\t}\n\t\t\tif(isset ($criterio[\"ci_pagado_por\"]) && trim($criterio[\"ci_pagado_por\"]) != \"0\"){\n\t\t\t\t$PreparedStatement .=\" AND ci_pagado_por = \".Connection::inject($criterio[\"ci_pagado_por\"]);\n\t\t\t}\n\t\t\treturn $PreparedStatement;\n\t\t}", "public function getWhereSQL()\n {\n return \" AND \" . $this->field_where_name . \" LIKE '%\" . $this->field_row->criteria . \"%' \";\n \n }", "public function setCondition($condition);", "public function buildConditionAction()\n {\n /** @var Form $form */\n $form = $this->formRepository->findByIdentifier($this->powermailArguments['mail']['form']);\n $this->setTextFields($form);\n\n /** @var ConditionContainer $conditionContainer */\n $conditionContainer = $this->containerRepository->findOneByForm($form);\n if ($conditionContainer !== null) {\n $arguments = $conditionContainer->applyConditions($form, $this->powermailArguments);\n SessionUtility::setSession($arguments);\n ArrayUtility::unsetByKeys($arguments, ['backup', 'field']);\n return json_encode($arguments);\n }\n return null;\n }", "public function testConditionClause()\n {\n $condition = $this->getConnection()\n ->condition()\n (\"WHERE blog_id = :id\");\n return $this->assertEquals($condition, \"WHERE blog_id = :id\");\n }", "function makeTargetSQL($condition_ix)\n{\n $targetSQLs = array();\n $joins = array();\ntrace($this->targets, 'makeTargetSQL targets');\n foreach($this->targets as $tgt_ix => $target){\n $defSnips = array();\n $def = $target->getDef();\n $defSnips[] = $def['snippet'];\n if(isset($def['joins'])){\n $joins = array_merge($joins, $def['joins']);\n }\n\n $SQL = \"CASE WHEN \";\n $SQL .= join(' AND ', $defSnips);\n $SQL .= \" THEN 1 ELSE NULL END\";\n //$SQL .= \" AS Target_$tgt_ix\";\n $SQL .= \" AS C{$condition_ix}Ta{$tgt_ix}\";\n $targetSQLs[$tgt_ix] = $SQL;\n }\n\n return array('selects' => $targetSQLs, 'joins' => $joins);\n}", "private function _buildWhereClause($select)\n {\n global $zdb, $login;\n\n try {\n if ( $this->_start_date_filter != null ) {\n $d = new \\DateTime($this->_start_date_filter);\n $select->where('date_debut_cotis >= ?', $d->format('Y-m-d'));\n }\n\n if ( $this->_end_date_filter != null ) {\n $d = new \\DateTime($this->_end_date_filter);\n $select->where('date_debut_cotis <= ?', $d->format('Y-m-d'));\n }\n\n if ( $this->_payment_type_filter != null ) {\n $select->where('type_paiement_cotis = ?', $this->_payment_type_filter);\n }\n\n if ( $this->_from_transaction !== false ) {\n $select->where(\n Transaction::PK . ' = ?',\n $this->_from_transaction\n );\n }\n\n if ( $this->_max_amount !== null && is_int($this->_max_amount)) {\n $select->where(\n '(montant_cotis <= ' . $this->_max_amount .\n ' OR montant_cotis IS NULL)'\n );\n }\n $sql = $select->__toString();\n\n if ( !$login->isAdmin() && !$login->isStaff() ) {\n //non staff members can only view their own contributions\n $select->where('p.' . Adherent::PK . ' = ?', $login->id);\n } else if ( $this->_filtre_cotis_adh != null ) {\n $select->where('p.' . Adherent::PK . ' = ?', $this->_filtre_cotis_adh);\n }\n if ( $this->_filtre_transactions === true ) {\n $select->where('a.trans_id ?', new \\Zend_Db_Expr('IS NULL'));\n }\n $qry = $select->__toString();\n Analog::log(\n \"Query was:\\n\" . $qry,\n Analog::DEBUG\n );\n } catch (\\Exception $e) {\n /** TODO */\n Analog::log(\n __METHOD__ . ' | ' . $e->getMessage(),\n Analog::WARNING\n );\n }\n }", "public function where(string $condition): SQL\n {\n $this->condition[] = $condition;\n return $this;\n }", "private function conditions(DBConnection $conn, Peer $peer) {\n $cond= '';\n foreach ($this->conditions as $condition) $cond.= $condition->asSql($conn, $peer).' and ';\n return substr($cond, 0, -5);\n }", "function plain_where($base) {\r\n for($i=1; $i<=$this->conditions; $i++) {\r\n ## Only create conditions for used input fields\r\n if ($GLOBALS[$base][\"input_\".$i] == \"\")\r\n continue;\r\n\r\n ## If necessary, add conjunction\r\n if ($q != \"\")\r\n $q .= sprintf(\" %s \", $GLOBALS[$base][\"conj_\".$i]);\r\n \r\n ## Handle \"like\"\r\n if ($GLOBALS[$base][\"comp_\".$i] == \"like\")\r\n $v = \"%\".$GLOBALS[$base][\"input_\".$i].\"%\";\r\n else\r\n $v = $GLOBALS[$base][\"input_\".$i];\r\n\r\n ## Create subcondition\r\n $q .= sprintf(\"%s %s '%s'\",\r\n $GLOBALS[$base][\"sel_\".$i],\r\n $GLOBALS[$base][\"comp_\".$i],\r\n $v);\r\n }\r\n \r\n if (!$q) {\r\n $q = \"1=0\";\r\n }\r\n \r\n return \"( $q )\";\r\n }", "function _add_where_clause($where_clauses, $join)\n {\n foreach ($where_clauses as $clause) {\n // $clause => array(\n // 'column' => 'ID',\n // 'value' =>\t1210,\n // 'compare' => '='\n // )\n // Determine where what the where clause is comparing\n switch ($clause['column']) {\n case 'author':\n case 'author_id':\n $this->object->_query_args['author'] = $clause['value'];\n break;\n case 'author_name':\n $this->object->_query_args['author_name'] = $clause['value'];\n break;\n case 'cat':\n case 'cat_id':\n case 'category_id':\n switch ($clause['compare']) {\n case '=':\n case 'BETWEEN':\n case 'IN':\n if (!isset($this->object->_query_args['category__in'])) {\n $this->object->_query_args['category__in'] = array();\n }\n $this->object->_query_args['category__in'][] = $clause['value'];\n break;\n case '!=':\n case 'NOT BETWEEN':\n case 'NOT IN':\n if (!isset($this->object->_query_args['category__not_in'])) {\n $this->object->_query_args['category__not_in'] = array();\n }\n $this->object->_query_args['category__not_in'][] = $clause['value'];\n break;\n }\n break;\n case 'category_name':\n $this->object->_query_args['category_name'] = $clause['value'];\n break;\n case 'post_id':\n case $this->object->get_primary_key_column():\n switch ($clause['compare']) {\n case '=':\n case 'IN':\n case 'BETWEEN':\n if (!isset($this->object->_query_args['post__in'])) {\n $this->object->_query_args['post__in'] = array();\n }\n $this->object->_query_args['post__in'][] = $clause['value'];\n break;\n default:\n if (!isset($this->object->_query_args['post__not_in'])) {\n $this->object->_query_args['post__not_in'] = array();\n }\n $this->object->_query_args['post__not_in'][] = $clause['value'];\n break;\n }\n break;\n case 'pagename':\n case 'postname':\n case 'page_name':\n case 'post_name':\n if ($clause['compare'] == 'LIKE') {\n $this->object->_query_args['page_name__like'] = $clause['value'];\n } elseif ($clause['compare'] == '=') {\n $this->object->_query_args['pagename'] = $clause['value'];\n } elseif ($clause['compare'] == 'IN') {\n $this->object->_query_args['page_name__in'] = $clause['value'];\n }\n break;\n case 'post_title':\n // Post title uses custom WHERE clause\n if ($clause['compare'] == 'LIKE') {\n $this->object->_query_args['post_title__like'] = $clause['value'];\n } else {\n $this->object->_query_args['post_title'] = $clause['value'];\n }\n break;\n default:\n // Must be metadata\n $clause['key'] = $clause['column'];\n unset($clause['column']);\n // Convert values to array, when required\n if (in_array($clause['compare'], array('IN', 'BETWEEN'))) {\n $clause['value'] = explode(',', $clause['value']);\n foreach ($clause['value'] as &$val) {\n if (!is_numeric($val)) {\n // In the _parse_where_clause() method, we\n // quote the strings and add slashes\n $val = stripslashes($val);\n $val = substr($val, 1, strlen($val) - 2);\n }\n }\n }\n if (!isset($this->object->_query_args['meta_query'])) {\n $this->object->_query_args['meta_query'] = array();\n }\n $this->object->_query_args['meta_query'][] = $clause;\n break;\n }\n }\n // If any where clauses have been added, specify how the conditions\n // will be conbined/joined\n if (isset($this->object->_query_args['meta_query'])) {\n $this->object->_query_args['meta_query']['relation'] = $join;\n }\n }", "public function getConditionsHook()\n\t{\n\t\t$conditions = array();\n\t\t\n\t\t$conditions['select'] = '`bid` AS id, `cid`, `type`, `name`, `alias`, `imptotal`, `impmade`, '\n\t\t\t\t\t\t\t\t\t\t\t\t\t.'`clicks`, `imageurl`, `clickurl`, `date`, `showBanner` AS state, `checked_out`, '\n\t\t\t\t\t\t\t\t\t\t\t\t\t.'`checked_out_time`, `editor`, `custombannercode`, `catid`, `description`, '\n\t\t\t\t\t\t\t\t\t\t\t\t\t.'`sticky`, `ordering`, `publish_up`, `publish_down`, `tags`, `params`'\t;\n\t\t\n\t\t$conditions['where'] = array();\n\t\t\n\t\treturn $conditions;\n\t}", "public function createWhere() {\n\t\tlist($where, $joins) = parent::createWhere();\n\t\tif (!($this->parent->parent instanceof QuerySet))\n\t\t\t$where = \" WHERE \" . $where;\n\t\telse\n\t\t\t$where = \" AND \" . $where;\n\t \n\t\treturn array($where, $joins);\n\t}", "function _parse_where_clause($condition)\n {\n $column = '';\n $operator = '';\n $value = '';\n $numeric = TRUE;\n // Substitute any placeholders\n global $wpdb;\n $binds = func_get_args();\n $binds = isset($binds[1]) ? $binds[1] : array();\n // first argument is the condition\n foreach ($binds as &$bind) {\n // A bind could be an array, used for the 'IN' operator\n // or a simple scalar value. We need to convert arrays\n // into scalar values\n if (is_object($bind)) {\n $bind = (array) $bind;\n }\n if (is_array($bind) && !empty($bind)) {\n foreach ($bind as &$val) {\n if (!is_numeric($val)) {\n $val = '\"' . addslashes($val) . '\"';\n $numeric = FALSE;\n }\n }\n $bind = implode(',', $bind);\n } else {\n if (is_array($bind) && empty($bind)) {\n $bind = 'NULL';\n } else {\n if (!is_numeric($bind)) {\n $numeric = FALSE;\n }\n }\n }\n }\n if ($binds) {\n $condition = $wpdb->prepare($condition, $binds);\n }\n // Parse the where clause\n if (preg_match(\"/^[^\\\\s]+/\", $condition, $match)) {\n $column = trim(array_shift($match));\n $condition = str_replace($column, '', $condition);\n }\n if (preg_match(\"/(NOT )?IN|(NOT )?LIKE|(NOT )?BETWEEN|[=!<>]+/i\", $condition, $match)) {\n $operator = trim(array_shift($match));\n $condition = str_replace($operator, '', $condition);\n $operator = strtolower($operator);\n $value = trim($condition);\n }\n // Values will automatically be quoted, so remove them\n // If the value is part of an IN clause or BETWEEN clause and\n // has multiple values, we attempt to split the values apart into an\n // array and iterate over them individually\n if ($operator == 'in') {\n $values = preg_split(\"/'?\\\\s?(,)\\\\s?'?/i\", $value);\n } elseif ($operator == 'between') {\n $values = preg_split(\"/'?\\\\s?(AND)\\\\s?'?/i\", $value);\n }\n // If there's a single value, treat it as an array so that we\n // can still iterate\n if (empty($values)) {\n $values = array($value);\n }\n foreach ($values as $index => $value) {\n $value = preg_replace(\"/^(\\\\()?'/\", '', $value);\n $value = preg_replace(\"/'(\\\\))?\\$/\", '', $value);\n $values[$index] = $value;\n }\n if (count($values) > 1) {\n $value = $values;\n }\n // Return the WP Query meta query parameters\n $retval = array('column' => $column, 'value' => $value, 'compare' => strtoupper($operator), 'type' => $numeric ? 'numeric' : 'string');\n return $retval;\n }", "protected function buildSql()\n {\n $this->selectSQL = ''; // reset query string\n\n $this->appendSql(\"SELECT \" . $this->buildFieldsList() . \" FROM \" . $this->fromTable)\n ->appendSql(!empty($this->joinsString) ? \" \" . $this->joinsString : \"\")\n ->appendSql(\" WHERE \" . (!empty($this->whereString) ? \" \" . $this->whereString : \" 1\"))\n ->appendSql(!empty($this->groupbyString) ? \" GROUP BY \" . $this->groupbyString : \"\")\n ->appendSql(!empty($this->orderbyString) ? \" ORDER BY \" . $this->orderbyString : \"\")\n ->appendSql(!empty($this->limitString) ? \" \" . $this->limitString : \"\");\n }", "function buildQuery () {\n $select = array();\n $from = array();\n $where = array();\n $join = '';\n $rowLimit = '';\n $tables = array();\n\n if (!empty ($this->checkTables)) {\n\n foreach ($this->checkTables as $table) {\n\n // only include tables that have selected columns\n $columns = self::getCheckTableColumns( $table );\n\n if (!empty ($columns)) {\n\n $tables[] = $this->removeQuotes($table);\n\n // Assign select and where clauses\n //go through each column\n foreach ($columns as $column) {\n //Add is column to constraint if selected\n if (!empty( $this->formTableColumnFilterHash[$table][$column]['checkColumn'] )) {\n $select[] = $this->removeQuotes($table) . \".\" . $this->removeQuotes($column);\n }\n\n self::getColumnFilter ( $where,\n $table,\n $column,\n $this->formTableColumnFilterHash[$table][$column]['selectMinOper'],\n $this->formTableColumnFilterHash[$table][$column]['textMinValue'],\n $this->formTableColumnFilterHash[$table][$column]['selectMaxOper'],\n $this->formTableColumnFilterHash[$table][$column]['textMaxValue']);\n } // foreach $column\n } //if (!empty ($columns))\n } // foreach $table\n } //if (!empty ($this->checkTables))\n\n // If there is only one table add from clause to that, otherwise only add the join table\n\n //Calculate joins before FROM\n $join = $this->joinTables($this->checkTables);\n\n $fromStatement = \"FROM \";\n $tblCounter = 0;\n $joinarray = array();\n $uniqueJoinArray= array_unique($this->JOINARRAY);\n $tblTotal = count($tables) - count($uniqueJoinArray);\n\n // build the FROM statement using all tables and not just tables that have selected columns\n foreach ($this->checkTables as $t) {\n $tblCounter++;\n\n # don't add a table to the FROM statement if it is used in a JOIN\n if(!(in_array($t, $this->JOINARRAY))){\n $fromStatement .= $t;\n\n //if($tblCounter < $tblTotal){\n $fromStatement .= \", \";\n //} // if\n\n } // if\n } // foreach tables\n\n $fromStatement = preg_replace(\"/\\,\\s*$/\",\"\",$fromStatement);\n $from[] = $fromStatement;\n\n // Add something if there are no columns selected\n if ( count( $select ) == 0 ) {\n $select[] = '42==42';\n }\n\n // Let's combine all the factors into one big query\n $query = \"SELECT \" . join(', ',$select) . \"\\n\" . join(', ', $from) . \"\\n\" . $join;\n\n # Case non-empty where clause\n if ( count( $where ) > 0 ) {\n $query .= 'WHERE ' . join( \" AND \", $where );\n $query .= \"\\n\";\n }\n\n // Add Row Limit\n if ( !empty( $this->selectRowLimit ) ) {\n $rowLimit = \"LIMIT \" . $this->selectRowLimit;\n $query .= $rowLimit;\n $query .= \"\\n\";\n }\n\n return $query;\n }", "function _prepareConditions($conditions, $pExtendingModuleID = null)\n{\n $debug_prefix = debug_indent(\"Module-_prepareConditions() {$this->ModuleID}:\");\n print \"$debug_prefix\\n\";\n $parentRecordConditions = array();\n $whereConditions = array();\n $protectJoinAliases = array();\n $SQL = '';\n\n $use_parent = true;\n if(empty($parentModuleID)){\n if(empty($this->parentModuleID)){\n $use_parent = false;\n } else {\n $parentModuleID = $this->parentModuleID;\n }\n }\n\n if($use_parent){\n $parentModule =& GetModule($parentModuleID);\n $parentPK = end($parentModule->PKFields);\n }\n\n if(! empty($pExtendingModuleID )){\n print \"extending module conditions: $pExtendingModuleID, {$this->ModuleID}\\n\";\n $extendingModule = GetModule($pExtendingModuleID);\n if(!empty( $extendingModule->extendsModuleFilterField )){\n $conditions[$extendingModule->extendsModuleFilterField] = $extendingModule->extendsModuleFilterValue;\n print \"added extended condition:\\n\";\n print_r($conditions);\n }\n }\n\n if(count($conditions) > 0){\n foreach($conditions as $conditionField => $conditionValue){\n print \"$debug_prefix Condition $conditionField => $conditionValue\\n\";\n\n $conditionModuleField = $this->ModuleFields[$conditionField];\n if(empty($conditionModuleField)){\n die(\"field {$this->ModuleID}.$conditionModuleField is empty\\n\");\n }\n $qualConditionField = $conditionModuleField->getQualifiedName($this->ModuleID);\n $conditionJoins = $conditionModuleField->makeJoinDef($this->ModuleID);\n if(count($conditionJoins) > 0){\n foreach(array_keys($conditionJoins) as $conditionJoinAlias){\n $protectJoinAliases[] = $conditionJoinAlias;\n }\n }\n\n if($use_parent){\n if(preg_match('/\\[\\*([\\w]+)\\*\\]/', $conditionValue, $match[1])){\n if($match[1][1] == $parentPK){\n $whereConditions[$qualConditionField] = '/**RecordID**/';\n } else {\n print \"SM found match $match[1][0]\\n\";\n $parentRecordConditions[$qualConditionField] = $match[1][1];\n }\n } else {\n $whereConditions[$qualConditionField] = $conditionValue;\n }\n } else {\n $whereConditions[$qualConditionField] = $conditionValue;\n }\n }\n }\n\n if($use_parent){\n $needParentSubselect = false;\n if(count($parentRecordConditions) > 0){\n foreach($parentRecordConditions as $localConditionField => $parentConditionField){\n $parentModuleField = $parentModule->ModuleFields[$parentConditionField];\n if(empty($parentModuleField)){\n die(\"field {$this->parentModuleID}.$parentConditionField is empty\\n\");\n }\n if(strtolower(get_class($parentModuleField)) != 'tablefield'){\n $needParentSubselect = true;\n }\n }\n if($needParentSubselect){\n $parentJoins = array();\n $parentSelects = array();\n foreach($parentRecordConditions as $localConditionField => $parentConditionField){\n $parentModuleField = $parentModule->ModuleFields[$parentConditionField];\n $parentSelects[] = $parentModuleField->makeSelectDef('iparent');\n $parentJoins = array_merge($parentJoins, $parentModuleField->makeJoinDef('iparent'));\n }\n\n $subSQL = 'SELECT ';\n $subSQL .= implode(\",\\n\", $parentSelects);\n $subSQL .= \"\\nFROM `{$this->parentModuleID}` AS `iparent`\\n\";\n $parentJoins = SortJoins($parentJoins);\n $subSQL .= implode(\"\\n \", $parentJoins);\n $subSQL .= \"\\nWHERE `iparent`.$parentPK = '/**RecordID**/' \\n\";\n\n $SQL = \"\\n INNER JOIN ($subSQL) AS `parent` ON (\\n\";\n $parentConditionStrings = array();\n foreach($parentRecordConditions as $localConditionField => $parentConditionField){\n $parentConditionStrings[] = \"`parent`.$parentConditionField = $localConditionField\";\n }\n $SQL .= implode(\"\\n AND \", $parentConditionStrings);\n $SQL .= \")\\n\";\n } else {\n $SQL = \"\\n INNER JOIN `{$this->parentModuleID}` AS `parent` ON (\\n\";\n $parentConditionStrings = array();\n foreach($parentRecordConditions as $localConditionField => $parentConditionField){\n $parentModuleField = $parentModule->ModuleFields[$parentConditionField];\n $qualParentConditionField = $parentModuleField->getQualifiedName('parent');\n $parentConditionStrings[] = \"$localConditionField = $qualParentConditionField\";;\n }\n $SQL .= implode(\"\\n AND \", $parentConditionStrings);\n $SQL .= \")\\n\";\n\n $whereConditions[\"`parent`.$parentPK\"] = '/**RecordID**/';\n }\n\n }\n }\n\n debug_unindent();\n return array(\n 'parentJoinSQL' => $SQL,\n 'whereConditions' => $whereConditions,\n 'protectJoinAliases' => $protectJoinAliases\n );\n}", "function _create_filter_sql () {\n\t\t$SF = &$_SESSION[$this->_filter_name];\n\t\tforeach ((array)$SF as $k => $v) {\n\t\t\t$SF[$k] = trim($v);\n\t\t}\n\t\t// Generate filter for the common fileds\n\t\tif ($SF[\"category_id\"])\t{\n\t\t \t$sql[] = \" AND category_id = \".intval($SF[\"category_id\"]).\" \";\n\t\t}\n\t\tif ($SF[\"user_id\"])\t{\n\t\t \t$sql[] = \" AND user_id = \".intval($SF[\"user_id\"]).\" \";\n\t\t}\n\t\tif (strlen($SF[\"admin_priority\"])) {\n\t\t \t$sql[] = \" AND admin_priority = \".intval($SF[\"admin_priority\"]).\" \";\n\t\t}\n\t\tif ($this->DEF_VIEW_STATUS || $SF[\"status\"]) {\n\t\t\t$status = $SF[\"status\"] ? $SF[\"status\"] : $this->DEF_VIEW_STATUS;\n\t\t\tif ($status == \"not_closed\") {\n\t\t\t \t$sql[] = \" AND status != 'closed' \";\n\t\t\t} else {\n\t\t\t \t$sql[] = \" AND status = '\"._es($SF[\"status\"]).\"' \";\n\t\t\t}\n\t\t}\n\t\tif (strlen($SF[\"subject\"])) {\n\t\t\t$sql[] = \" AND subject LIKE '\"._es($SF[\"subject\"]).\"%' \";\n\t\t}\n\t\tif (strlen($SF[\"message\"])) {\n\t\t\t$sql[] = \" AND message LIKE '\"._es($SF[\"message\"]).\"%' \";\n\t\t}\n\t\tif (!empty($SF[\"email\"])) {\n\t\t\t$sql[] = \" AND email LIKE '\"._es($SF[\"email\"]).\"%' \";\n\t\t}\n\t\tif ($SF[\"assigned_to\"])\t{\n\t\t \t$sql[] = \" AND assigned_to = \".intval($SF[\"assigned_to\"]).\" \";\n\t\t}\n\t\t// Add subquery to users table\n\t\tif (!empty($users_sql)) {\n\t\t\t$sql[] = \" AND user_id IN( SELECT id FROM \".db('user').\" WHERE 1=1 \".$users_sql.\") \";\n\t\t}\n\t\t// Default sorting\n\t\tif (!$SF[\"sort_by\"]) {\n\t\t\t$SF[\"sort_by\"]\t\t= \"opened_date\";\n\t\t\t$SF[\"sort_order\"]\t= \"DESC\";\n\t\t}\n\t\t// Sorting here\n\t\tif ($SF[\"sort_by\"]) {\n\t\t \t$sql[] = \" ORDER BY \".($this->_sort_by[$SF[\"sort_by\"]] ? $this->_sort_by[$SF[\"sort_by\"]] : $SF[\"sort_by\"]).\" \";\n\t\t\tif (strlen($SF[\"sort_order\"])) {\n\t\t\t\t$sql[] = \" \".$SF[\"sort_order\"].\" \";\n\t\t\t}\n\t\t}\n\t\t$sql = implode(\"\\r\\n\", (array)$sql);\n\t\treturn $sql;\n\t}", "function createWhere($sql) {\n $where = $this->where;\n if(!empty($where)) {\n $sql .= \" WHERE \";\n for($i = 0; $i < count($where); $i++) {\n $sql .= $where[$i]->key . \" \" . $where[$i]->operator . \" \" . $where[$i]->placeholder;\n $afterCon = $where[$i]->afterCondition;\n if(!is_null($afterCon)) {\n $sql .= \" \" . $afterCon . \" \";\n }\n }\n }\n\n return $sql;\n }", "public function __construct() {\n\t\tparent::__construct();\n\t\t\n\t\t$this->sqlConditionJoins = \", wcf\".WCF_N.\"_user_notification_event_to_user event_to_user\";\n\t\t$this->getConditionBuilder()->add(\"event_to_user.userID = user_table.userID\");\n\t}", "public function startCondition()\n {\n $conditionBuilder = new ConditionBuilder($this);\n $this->conditionBuilders[] = $conditionBuilder;\n return $conditionBuilder;\n }", "function _create_filter_sql () {\n\t\t$SF = &$_SESSION[$this->_filter_name];\n\t\tforeach ((array)$SF as $k => $v) $SF[$k] = trim($v);\n\t\t// Generate filter for the common fileds\n\t\tif (strlen($SF[\"text\"]))\t\t$sql .= \" AND text LIKE '%\"._es($SF[\"text\"]).\"%' \\r\\n\";\n\t\tif (strlen($SF[\"engine\"]))\t\t$sql .= \" AND engine=\".intval($SF[\"engine\"]).\" \\r\\n\";\n\t\treturn substr($sql, 0, -3);\n\t}", "protected abstract function getWhereClause(array $conditions);", "function _buildContentWhere()\n\t{\n\t\t$user = & JFactory::getUser() ;\t\t\n\t\t$hidePastEvents = EventBookingHelper::getConfigValue('hide_past_events');\n\t\t$where = array() ;\n\t\t$categoryId = JRequest::getInt('category_id', 0) ;\n\t\t$where[] = 'a.published = 1';\n\t\tif (version_compare(JVERSION, '1.6.0', 'ge')) {\n\t\t $where[] = ' a.access IN ('.implode(',', $user->getAuthorisedViewLevels()).')' ;\n\t\t} else {\n\t\t $gid\t\t= $user->get('aid', 0);\n\t\t $where[] = ' a.access <= '.(int)$gid ; \n\t\t}\t\t\n\t\tif ($categoryId) {\n\t\t\t//$where[] = ' a.category_id = '.$categoryId ;\t\t\t\t\t\t\n\t\t\t$where[] = ' a.id IN (SELECT event_id FROM #__eb_event_categories WHERE category_id='.$categoryId.')' ;\n\t\t}\n\t\tif ($hidePastEvents) {\n\t\t\t$where[] = ' DATE(a.event_date) >= CURDATE() ';\n\t\t}\n\t\t$where \t\t= ( count( $where ) ? ' WHERE '. implode( ' AND ', $where ) : '' );\t\t\n\t\treturn $where;\n\t}", "protected function _buildQueryWhere(KDatabaseQuery $query)\n\t{\n\t\tparent::_buildQueryWhere($query);\n\n\t\tif($this->_state->type) {\n\t\t\t$query->where('tbl.subscription_type', '=', $this->_state->type);\n\t\t} elseif($this->_state->type_name) {\n\t\t\t$table = $this->getService('com://admin/ninjaboard.database.table.watches');\n\t\t\t$query->where('tbl.subscription_type', '=', $table->getTypeIdFromName($this->_state->type_name));\n\t\t}\n\t\t\n\t\tif($this->_state->type_id) {\n\t\t\t$query->where('tbl.subscription_type_id', '=', $this->_state->type_id);\n\t\t}\n\t\t\n\t\tif($this->_state->by) {\n\t\t\t$query->where('tbl.created_by', '=', $this->_state->by);\n\t\t}\n\t}", "public function getCondition() { \n \t\treturn $this->condition . tx_newspaper::enableFields(tx_newspaper::getTable($this)); \n \t}", "function buildQuery () {\n $select = array();\n $from = array();\n $where = array();\n $join = '';\n $rowLimit = '';\n\n if (!empty ($this->checkTables)) {\n foreach ($this->checkTables as $table) {\n $columns = self::getCheckTableColumns( $table );\n //go through each column\n if (!empty ($columns)) {\n //try to join tables\n if ( count ($this->checkTables) > 1 && $this->checkTables[0] != $table) {\n // Add JOIN condition\n $join .= self::buildQueryJoin( $this->checkTables[0], $table );\n }\n\n // Assign select and where clauses\n foreach ($columns as $column) {\n //Add is column to constraint if selected\n if (!empty( $this->formTableColumnFilterHash[$table][$column]['checkColumn'] )) {\n $select[] = self::getTableAlias ($table).\".\".$column.\" AS \".self::getTableAlias ($table).\"_\".$column;\n }\n\n self::getColumnFilter ( $where,\n $table,\n $column,\n $this->formTableColumnFilterHash[$table][$column]['selectColumnLogicOper'],\n $this->formTableColumnFilterHash[$table][$column]['selectMinOper'],\n $this->formTableColumnFilterHash[$table][$column]['textMinValue'],\n $this->formTableColumnFilterHash[$table][$column]['selectRangeLogicOper'],\n $this->formTableColumnFilterHash[$table][$column]['selectMaxOper'],\n $this->formTableColumnFilterHash[$table][$column]['textMaxValue']);\n\n } // foreach $column\n } //if (!empty ($columns))\n } // foreach $table\n // If there is only one table add from cluase to that else just the join table\n\t $from[] = \" FROM \".$this->checkTables[0].\" AS \".self::getTableAlias($this->checkTables[0]).\" \\n\"; //assign single table\n } //if (!empty ($this->checkTables))\n\n\n\n if ( $this->radioSpacialConstraint == 'Cone') {\n $join .= self::getConeSearch ($this->textConeRa,\n $this->textConeDec,\n $this->textConeRadius,\n $this->selectConeUnits);\n } //if\n\n else if ($this->radioSpacialConstraint == 'Box') {\n $join .= self::getBoxSearch ($this->textBoxRa,\n $this->textBoxDec,\n $this->textBoxSize,\n $this->selectBoxUnits);\n } // if\n\n // Assign survey filter\n if ( isset( $this->selectSurvey ) && $this->selectSurvey > 0 ) {\n $surveyFilter = self::getSurveyFilter();\n if ( !empty( $surveyFilter ) )\n $where[] = self::getSurveyFilter();\n }\n // Figure out the Astro Filter join\n if (!empty( $this->checkAstroFilterIDs ) ) {\n $astroFilter = self::getAstroFilterJoin();\n if ( !empty( $astroFilter ) )\n $where[] = $astroFilter;\n }\n\n // Add Row Limit\n if ( !empty( $this->selectRowLimit ) ) {\n $rowLimit = \"TOP \".$this->selectRowLimit.\" \";\n }\n // Add something if there are no columns selected\n if ( count( $select ) == 0 ) {\n $select[] = '42==42';\n }\n\n // Let's combine all the factors into one big query\n $query = \"SELECT \".$rowLimit.join(', ',$select).\"\\n\".join(', ', $from).$join;\n\n # Case non-empty where clause\n if ( count( $where ) > 0 ) {\n #Get rid of the first columns that starts with a logical operator of AND/OR\n $where[0] = preg_replace('/^\\s*(AND)|(OR)|(\\^)/', '', $where[0]);\n $query .= ' WHERE '.join( \"\\n \",$where );\n }\n return $query;\n }", "public function buildSqlString()\n {\n $param = array();\n\n $join = '';\n $filter = '';\n $order = '';\n $limit = '';\n\n // Create the fieldprefix. If given as alias use this, otherwise we use the tablename\n $field_prefifx = !empty($this->alias) ? $this->alias : '{db_prefix}' . $this->tbl;\n\n // Biuld joins\n if (!empty($this->join))\n {\n $tmp = array();\n\n foreach ( $this->join as $def )\n $tmp[] = ' ' . $def['by'] . ' JOIN ' . '{db_prefix}' . (isset($def['as']) ? $def['tbl'] . ' AS ' . $def['as'] : $def['join']) . ' ON (' . $def['cond'] . ')';\n }\n\n $join = isset($tmp) ? implode(' ', $tmp) : '';\n\n // Create fieldlist\n if (!empty($this->fields))\n {\n // Add `` to some field names as reaction to those stupid developers who chose systemnames as fieldnames\n foreach ( $this->fields as $key_field => $field )\n {\n if (in_array($field, array('date', 'time')))\n $field = '`' . $field . '`';\n\n // Extend fieldname either by table alias or name when no dot as alias/table indicator is found.\n #if (strpos($field, '.') === false)\n # $field .= (!empty($this->alias) ? $this->alias : $this->tbl) . '.' . $field;\n\n $this->fields[$key_field] = $field;\n }\n\n $fieldlist = implode(', ', $this->fields);\n } else\n {\n $fieldlist = '*';\n }\n\n // Create filterstatement\n $filter = !empty($this->filter) ? ' WHERE ' . $this->filter : null;\n\n // Create group by statement\n $group_by = !empty($this->group_by) ? ' GROUP BY ' . $this->group_by : null;\n\n // Create having statement\n $having = !empty($this->having) ? ' HAVING ' . $this->having : null;\n\n // Create order statement\n $order = !empty($this->order) ? ' ORDER BY ' . $this->order : null;\n\n // Create limit statement\n if (!empty($this->limit))\n {\n $limit = ' LIMIT ';\n\n if (isset($this->limit['lower']))\n $limit .= $this->limit['lower'];\n\n if (isset($this->limit['lower']) && isset($this->limit['upper']))\n $limit .= ',' . $this->limit['upper'];\n }\n\n // We need a string for the table. if there is an alias, we have to set it\n $tbl = !empty($this->alias) ? $this->tbl . ' AS ' . $this->alias : $this->tbl;\n\n // Is this an distinct query?\n $distinct = $this->distinct ? 'DISTINCT ' : '';\n\n // Create sql statement by joining all parts from above\n $this->sql = 'SELECT ' . $distinct . $fieldlist . ' FROM {db_prefix}' . $tbl . $join . $filter . $group_by . $having . $order . $limit;\n\n return $this->sql;\n }", "protected function buildSql() {\r\n if( !$this->sql ) {\r\n $this->sql = $this->sqlAction;\r\n if( count($this->sqlFields) === 0 ) {\r\n $this->sqlFields[] = '*';\r\n }\r\n $this->sqlStrTables = join(', ', $this->sqlTables);\r\n $this->sqlStrFields = join(', ', $this->sqlFields);\r\n $this->sqlStrConditions = join(' ', $this->sqlConditions);\r\n switch ($this->sqlAction) {\r\n case 'SELECT': $this->buildSelectSql();\r\n break;\r\n case 'UPDATE': $this->buildUpdateSql();\r\n break;\r\n case 'INSERT': $this->buildInsertSql();\r\n break;\r\n case 'DELETE': $this->buildDeleteSql();\r\n break;\r\n }\r\n }\r\n }", "public function testConstructSQLClauseLikeValues()\n {\n $_SESSION['behat']['GenesisSqlExtension']['keywords'] = [];\n $_SESSION['behat']['GenesisSqlExtension']['notQuotableKeywords'] = [];\n\n // Prepare / Mock\n $glue = ' AND ';\n $columns = [\n 'firstname' => 'Bob',\n 'user_agent' => '%Firefox%'\n ];\n\n // Execute\n $result = $this->testObject->constructSQLClause($glue, $columns);\n\n $expected = \"firstname = 'Bob' AND user_agent LIKE '%Firefox%'\";\n\n // Assert Result\n $this->assertEquals($expected, $result);\n }", "private function buildQuery(): void\n {\n $this->query = self::CREATE_TABLE;\n\n if ($this->ifNotExists) {\n $this->query .= self::IF_NOT_EXISTS;\n }\n\n $this->query .= $this->table . self::OPENING_BRACKET;\n\n $this->query .= join(', ', $this->columns);\n\n if (!empty($this->keys)) {\n $this->query .= ',' . join(',', $this->keys);\n }\n\n $this->query .= self::CLOSING_BRACKET;\n\n if (!empty($this->engine)) {\n $this->query .= self::ENGINE . $this->engine;\n }\n\n if (!empty($this->charset)) {\n $this->query .= self::CHARSET . $this->charset;\n }\n }", "public function get_additional_conditions()\n {\n $l_type = (int) $_GET[C__GET__ID];\n\n if ($l_type > 0)\n {\n return ' AND cat_rel.isys_catg_its_type_list__isys_its_type__id = ' . $this->convert_sql_id($l_type) . ' ';\n } // if\n\n return '';\n }", "protected function createCondition($values) {\n $definition = $this->typedDataManager->createDataDefinition('condition');\n $values = $values + ['operator' => '='];\n return $this->typedDataManager->create($definition, $values);\n }", "private function buildWhereFragment($field, array $condition)\n {\n $result = '1=1';\n foreach ($condition as $key => $value) {\n if ($key == Operator::QUERY_BETWEEN) {\n $from = isset($value[0])?$this->escapeString($value[0]):0;\n $to = isset($value[1])?$this->escapeString($value[1]):0;\n $result = \"`{$field}` BETWEEN '{$from}' AND '{$to}'\";\n }\n elseif ($key == Operator::QUERY_NOT_IN || $key == Operator::QUERY_IN) {\n $type_temp = ltrim($key, '$');\n $output = array();\n $callback = function($value, $key) use (&$output)\n {\n $value = $this->escapeString($value);\n $output[$key] = \"'$value'\";\n };\n array_walk($value, $callback);\n $value_temp = implode(', ', $output);\n $result = \"`{$field}` {$type_temp} ({$value_temp})\";\n }\n elseif (in_array($key, array(Operator::QUERY_EQUAL, Operator::QUERY_GT, Operator::QUERY_GTE, Operator::QUERY_LT, Operator::QUERY_LTE, Operator::QUERY_NE))) {\n $type_temp = ltrim($key, '$');\n $result = \"`$field` {$type_temp} '{$value}'\";\n }\n elseif ($key == Operator::QUERY_LIKE) {\n $value = $this->escapeString($value);\n $result = \"`{$field}` LIKE '%{$value}%'\";\n }\n break;//只检查第一个元素\n }\n return $result;\n }", "function fn_product_condition_get_product_data($product_id, &$field_list, $join, $auth, $lang_code, $condition) {\r\n $field_list .= 'condition';\r\n}", "function add_condition($item) {\n\t\treturn $this->conditions[$this->prefix.$item['id']] = $item['condition'];\n\t}", "public function buildQueryLimits()\n\t{\n\t\tglobal $modSettings;\n\n\t\t$extra_where = [];\n\n\t\tif (!empty($this->_searchParams->_minMsgID) || !empty($this->_searchParams->_maxMsgID))\n\t\t{\n\t\t\t$extra_where[] = 'id >= ' . $this->_searchParams->_minMsgID . ' AND id <= ' . (empty($this->_searchParams->_maxMsgID) ? (int) $modSettings['maxMsgID'] : $this->_searchParams->_maxMsgID);\n\t\t}\n\n\t\tif (!empty($this->_searchParams->topic))\n\t\t{\n\t\t\t$extra_where[] = 'id_topic = ' . (int) $this->_searchParams->topic;\n\t\t}\n\n\t\tif (!empty($this->_searchParams->brd))\n\t\t{\n\t\t\t$extra_where[] = 'id_board IN (' . implode(',', $this->_searchParams->brd) . ')';\n\t\t}\n\n\t\tif (!empty($this->_searchParams->_memberlist))\n\t\t{\n\t\t\t$extra_where[] = 'id_member IN (' . implode(',', $this->_searchParams->_memberlist) . ')';\n\t\t}\n\n\t\treturn $extra_where;\n\t}", "function cond_to_sqladd($cond) {\n\t$s = '';\n\tif(!empty($cond)) {\n\t\t$s = ' WHERE ';\n\t\tforeach($cond as $k=>$v) {\n\t\t\tif(!is_array($v)) {\n\t\t\t\t$v = addslashes($v);\n\t\t\t\t$s .= \"$k = '$v' AND \";\n\t\t\t} else {\n\t\t\t\tforeach($v as $k1=>$v1) {\n\t\t\t\t\t$v1 = addslashes($v1);\n\t\t\t\t\t$k1 == 'LIKE' AND $v1 = \"%$v1%\";\n\t\t\t\t\t$s .= \"$k $k1 '$v1' AND \";\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$s = substr($s, 0, -4);\n\t}\n\treturn $s;\n}", "public function clearCondition(){\n\t\t$this->where=\"\";\n\t}", "protected function _buildWhere(&$query)\n {\n\n return $query;\n }", "private function _buildQuery($filters = array())\n\t{\n\t\t// var to hold conditions\n\t\t$where = array();\n\t\t$sql = '';\n\n\t\t// gidnumber\n\t\tif (isset($filters['gidNumber']))\n\t\t{\n\t\t\t$where[] = \"gidNumber=\" . $this->_db->quote($filters['gidNumber']);\n\t\t}\n\n\t\t// action\n\t\tif (isset($filters['action']))\n\t\t{\n\t\t\t$where[] = \"action=\" . $this->_db->quote($filters['action']);\n\t\t}\n\n\t\t// if we have and conditions\n\t\tif (count($where) > 0)\n\t\t{\n\t\t\t$sql = \" WHERE \" . implode(\" AND \", $where);\n\t\t}\n\n\t\tif (isset($filters['orderby']))\n\t\t{\n\t\t\t$sql .= \" ORDER BY \" . $filters['orderby'];\n\t\t}\n\n\t\treturn $sql;\n\t}", "function _create_filter_sql () {\n\t\t$SF = &$_SESSION[$this->_filter_name];\n\t\tforeach ((array)$SF as $k => $v) $SF[$k] = trim($v);\n\t\t// Generate filter for the common fileds\n\t\tif ($SF[\"id_min\"]) \t\t\t\t$sql .= \" AND id >= \".intval($SF[\"id_min\"]).\" \\r\\n\";\n\t\tif ($SF[\"id_max\"])\t\t\t \t$sql .= \" AND id <= \".intval($SF[\"id_max\"]).\" \\r\\n\";\n\t\tif ($SF[\"date_min\"]) \t\t\t$sql .= \" AND add_date >= \".strtotime($SF[\"date_min\"]).\" \\r\\n\";\n\t\tif ($SF[\"date_max\"])\t\t\t$sql .= \" AND add_date <= \".strtotime($SF[\"date_max\"]).\" \\r\\n\";\n\t\tif ($SF[\"user_id\"])\t\t\t \t$sql .= \" AND user_id = \".intval($SF[\"user_id\"]).\" \\r\\n\";\n\t\tif ($SF[\"cat_id\"])\t\t\t \t$sql .= \" AND cat_id = \".intval($SF[\"cat_id\"]).\" \\r\\n\";\n\t\tif (strlen($SF[\"title\"]))\t\t$sql .= \" AND title LIKE '\"._es($SF[\"title\"]).\"%' \\r\\n\";\n\t\tif (strlen($SF[\"summary\"]))\t\t$sql .= \" AND summary LIKE '\"._es($SF[\"summary\"]).\"%' \\r\\n\";\n\t\tif (strlen($SF[\"text\"]))\t\t$sql .= \" AND full_text LIKE '\"._es($SF[\"text\"]).\"%' \\r\\n\";\n\t\tif (!empty($SF[\"status\"]) && isset($this->_articles_statuses[$SF[\"status\"]])) {\n\t\t \t$sql .= \" AND status = '\"._es($SF[\"status\"]).\"' \\r\\n\";\n\t\t}\n\t\tif (strlen($SF[\"nick\"]) || strlen($SF[\"account_type\"])) {\n\t\t\tif (strlen($SF[\"nick\"])) \t$users_sql .= \" AND nick LIKE '\"._es($SF[\"nick\"]).\"%' \\r\\n\";\n\t\t\tif ($SF[\"account_type\"])\t$users_sql .= \" AND `group` = \".intval($SF[\"account_type\"]).\" \\r\\n\";\n\t\t}\n\t\t// Add subquery to users table\n\t\tif (!empty($users_sql)) {\n\t\t\t$sql .= \" AND user_id IN( SELECT id FROM \".db('user').\" WHERE 1=1 \".$users_sql.\") \\r\\n\";\n\t\t}\n\t\t// Sorting here\n\t\tif ($SF[\"sort_by\"])\t\t\t \t$sql .= \" ORDER BY \".$this->_sort_by[$SF[\"sort_by\"]].\" \\r\\n\";\n\t\tif ($SF[\"sort_by\"] && strlen($SF[\"sort_order\"])) \t$sql .= \" \".$SF[\"sort_order\"].\" \\r\\n\";\n\t\treturn substr($sql, 0, -3);\n\t}", "public function buildQuery() {\n\t\t$where = (sizeof($this->wheres) > 0) ? ' WHERE '.implode(\" \\n AND \\n\\t\", $this->wheres) : '';\n\t\t$order = (sizeof($this->orders) > 0) ? ' ORDER BY '.implode(\", \", $this->orders) : '' ;\n\t\t$group = (sizeof($this->groups) > 0) ? ' GROUP BY '.implode(\", \", $this->groups) : '' ;\n\t\t$query = 'SELECT '.implode(\", \\n\\t\", $this->fields).\"\\n FROM \\n\\t\".$this->class->table.\"\\n \".implode(\"\\n \", $this->joins).$where.' '.$group.' '.$order.' '.$this->limit;\n\t\treturn($query);\n\t}", "public function getWhereClauseCondition() {\n\n if (isset($this->whereClauseCondition)) {\n $setCondition = $this->whereClauseCondition;\n return $setCondition;\n } else {\n $defaultCondition = \"=\";\n return $defaultCondition;\n }\n }", "function _buildQuery()\n\t{\t\t\n\t\t// Get the WHERE and ORDER BY clauses for the query\n\t\t$where\t\t= $this->_buildContentWhere();\n\t\t$orderby\t= $this->_buildContentOrderBy();\n\t\t$query = 'SELECT a.*, DATEDIFF(a.early_bird_discount_date, NOW()) AS date_diff, c.name AS location_name, IFNULL(SUM(b.number_registrants), 0) AS total_registrants FROM #__eb_events AS a '\n\t\t\t. ' LEFT JOIN #__eb_registrants AS b '\n\t\t\t. ' ON (a.id = b.event_id AND b.group_id=0 AND (b.published = 1 OR (b.payment_method=\"os_offline\" AND b.published != 2))) '\n\t\t\t. ' LEFT JOIN #__eb_locations AS c '\n\t\t\t. ' ON a.location_id = c.id '\t\t\t\t\t\n\t\t\t. $where\t\t\n\t\t\t. ' GROUP BY a.id '\n\t\t\t. $orderby\n\t\t;\n\t\treturn $query;\n\t}", "public function condition()\n {\n if (!$this->condition) {\n $this->condition = array();\n foreach (monsterToCondition::select('ctype', 'condition')->where('mid', '=', $this->id)->get() as $r) {\n $this->condition[] = $r->condition;\n };\n }\n return $this->condition;\n }", "abstract protected function buildSQL(): string;", "function query_builder($model = NULL, $condition = NULL, $from_clause = NULL, $str_from = \"*\")\n {\n $condition = isset($condition) ? $condition : \"1\";\n $type = \"normal\";\n $str_from = isset($from_clause) ? $from_clause : $str_from;\n\n if ($this->relation_data && !empty($this->relation)) {\n if ($str_from == \"*\") {\n $str_from = $this->model2querystr($model);\n $sql_body = \"\";\n foreach ($this->relation as $key => $val) {\n $table = $this->model2table($key);\n $str_from .= \",\" . $this->model2querystr($key);\n $sql_body .= \" LEFT JOIN $table AS $key ON (\" . $model . \".\" . $val[\"nativekey\"] . \"=$key.\" . $val[\"neighborkey\"] . \") \";\n }\n }\n\n $sql = \"Select $str_from From \" . $this->model2table($model) . \" AS $model $sql_body WHERE $condition\";\n $type = \"relational\";\n }\n else {\n $sql = \"SELECT $str_from FROM \" . $this->model2table($from_clause) . \" WHERE $condition\";\n }\n\n return array(\"type\" => $type, \"SQL\" => $sql);\n }", "public function whereAND()\n {\n $this->where_clause .= \" AND \";\n }", "function _add_where_clause($where_clauses, $join)\n {\n $clauses = array();\n foreach ($where_clauses as $clause) {\n extract($clause);\n if ($this->object->has_column($column)) {\n $column = \"`{$column}`\";\n }\n if (!is_array($value)) {\n $value = array($value);\n }\n foreach ($value as $index => $v) {\n $v = $clause['type'] == 'numeric' ? $v : \"'{$v}'\";\n $value[$index] = $v;\n }\n if ($compare == 'BETWEEN') {\n $value = \"{$value[0]} AND {$value[1]}\";\n } else {\n $value = implode(', ', $value);\n if (strpos($compare, 'IN') !== FALSE) {\n $value = \"({$value})\";\n }\n }\n $clauses[] = \"{$column} {$compare} {$value}\";\n }\n $this->object->_where_clauses[] = implode(\" {$join} \", $clauses);\n }", "protected function getCondition(array $data) : string {\n\n\t\t\treturn implode(' AND ', array_filter($this->config->castArray($data, true)));\n\t\t}", "public function lteq(): WhereCondition\n {\n\n $this->_op = self::OP_TYPE_GL_EQ;\n\n return $this;\n\n }", "protected function build_sql() {\n\n\t\t$builder = new Builder();\n\n\t\t$select = $this->parse_select();\n\t\t$from = new From( $this->table->get_table_name( $GLOBALS['wpdb'] ), 'q' );\n\n\t\t$where = new Where( 1, true, 1 );\n\n\t\tif ( ( $id = $this->parse_id() ) !== null ) {\n\t\t\t$where->qAnd( $id );\n\t\t}\n\n\t\tif ( ( $transaction = $this->parse_transaction() ) !== null ) {\n\t\t\t$where->qAnd( $transaction );\n\t\t}\n\n\t\tif ( ( $customer = $this->parse_customer() ) !== null ) {\n\t\t\t$where->qAnd( $customer );\n\t\t}\n\n\t\tif ( ( $membership = $this->parse_membership() ) !== null ) {\n\t\t\t$where->qAnd( $membership );\n\t\t}\n\n\t\tif ( ( $seats = $this->parse_seats() ) !== null ) {\n\t\t\t$where->qAnd( $seats );\n\t\t}\n\n\t\tif ( ( $seats_gt = $this->parse_seats_gt() ) !== null ) {\n\t\t\t$where->qAnd( $seats_gt );\n\t\t}\n\n\t\tif ( ( $seats_lt = $this->parse_seats_lt() ) !== null ) {\n\t\t\t$where->qAnd( $seats_lt );\n\t\t}\n\n\t\tif ( ( $active = $this->parse_active() ) !== null ) {\n\t\t\t$where->qAnd( $active );\n\t\t}\n\n\t\t$order = $this->parse_order();\n\t\t$limit = $this->parse_pagination();\n\n\t\tif ( $this->args['return_value'] == 'relationships' ) {\n\n\t\t\t$match = new Where_Raw( 'r.purchase = q.id' );\n\t\t\t$match->qAnd( $where );\n\n\t\t\t$select = $this->parse_select( 'r' );\n\t\t\t$join = new Join( $from, $match );\n\n\t\t\t$from = new From(\n\t\t\t\tManager::get( 'itegms-relationships' )->get_table_name( $GLOBALS['wpdb'] ), 'r'\n\t\t\t);\n\t\t\t$where = $join;\n\t\t}\n\n\t\t$builder->append( $select );\n\t\t$builder->append( $from );\n\t\t$builder->append( $where );\n\t\t$builder->append( $order );\n\n\t\tif ( $limit !== null ) {\n\t\t\t$builder->append( $limit );\n\t\t}\n\n\t\treturn $builder->build();\n\t}", "public function andWhere() {\r\n\t\t$args = func_get_args();\r\n\t\t$statement = array_shift($args);\r\n\t\t//if ( (count($args) == 1) && (is_null($args[0])) ) {\r\n\t\t//\t$this->_wheres = array();\r\n\t\t//\treturn null;\r\n\t\t//}\r\n\t\t$criteria = new Dbi_Sql_Criteria($this, new Dbi_Sql_Expression($statement, $args));\r\n\t\t$this->_wheres[] = $criteria;\r\n\t\treturn $criteria;\r\n\t}", "function dblog_build_filter_query() {\n if (empty($_SESSION['dblog_overview_filter'])) {\n return;\n }\n\n $filters = dblog_filters();\n\n // Build query\n $where = $args = array();\n foreach ($_SESSION['dblog_overview_filter'] as $key => $filter) {\n $filter_where = array();\n foreach ($filter as $value) {\n $filter_where[] = $filters[$key]['where'];\n $args[] = $value;\n }\n if (!empty($filter_where)) {\n $where[] = '(' . implode(' OR ', $filter_where) . ')';\n }\n }\n $where = !empty($where) ? implode(' AND ', $where) : '';\n\n return array(\n 'where' => $where,\n 'args' => $args,\n );\n}", "function custom_conds( $conds = array())\n\t{\n\t\t// default where clause\n\t\tif ( !isset( $conds['no_publish_filter'] )) {\n\t\t\t$this->db->where( 'status', 1 );\n\t\t}\n\t\t\n\t\t// order by\n\t\tif ( isset( $conds['order_by'] )) {\n\t\t\t$order_by_field = $conds['order_by_field'];\n\t\t\t$order_by_type = $conds['order_by_type'];\n\t\t\t\n\t\t\t$this->db->order_by( 'rt_products.'.$order_by_field, $order_by_type);\n\t\t}\n\t\t// product id condition\n\t\tif ( isset( $conds['id'] )) {\n\t\t\t$this->db->where( 'id', $conds['id'] );\t\n\t\t}\n\n\t\t// category id condition\n\t\tif ( isset( $conds['cat_id'] )) {\n\t\t\t\n\t\t\tif ($conds['cat_id'] != \"\") {\n\t\t\t\tif($conds['cat_id'] != '0'){\n\t\t\t\t\t$this->db->where( 'cat_id', $conds['cat_id'] );\t\n\t\t\t\t}\n\n\t\t\t}\t\t\t\n\t\t}\n\n\t\t// sub category id condition \n\t\tif ( isset( $conds['sub_cat_id'] )) {\n\t\t\t\n\t\t\tif ($conds['sub_cat_id'] != \"\") {\n\t\t\t\tif($conds['sub_cat_id'] != '0'){\n\t\t\t\t\n\t\t\t\t\t$this->db->where( 'sub_cat_id', $conds['sub_cat_id'] );\t\n\t\t\t\t}\n\n\t\t\t}\t\t\t\n\t\t}\n\n\t\n\t\t// cat_ordering condition\n\t\tif ( isset( $conds['shop_id'] )) {\n\t\t\t$this->db->where( 'shop_id', $conds['shop_id'] );\n\t\t}\n\n\t\t// product_name condition\n\t\tif ( isset( $conds['name'] )) {\n\t\t\t$this->db->where( 'name', $conds['name'] );\n\t\t}\n\n\t\tif ( isset( $conds['desc'] )) {\n\t\t\t$this->db->where( 'description', $conds['desc'] );\n\t\t}\n\n\t\t// product keywords\n\t\tif ( isset( $conds['search_tag'] )) {\n\t\t\t$this->db->where( 'search_tag', $conds['search_tag'] );\n\t\t}\n\n\t\t// product highlight information condition\n\t\tif ( isset( $conds['info'] )) {\n\t\t\t$this->db->where( 'highlight_information', $conds['info'] );\n\t\t}\n\n\t\t// product code\n\t\tif ( isset( $conds['code'] )){\n\t\t\t$this->db->where( 'code', $conds['code'] );\n\t\t}\n\n\t\t// product unit_value condition\n\t\tif ( isset( $conds['product_unit_value'] )) {\n\t\t\t$this->db->where( 'product_unit_value', $conds['product_unit_value'] );\n\t\t}\n\n\t\t// product unit condition\n\t\tif ( isset( $conds['product_unit'] )) {\n\t\t\t$this->db->where( 'product_unit', $conds['product_unit'] );\n\t\t}\n\n\t\t// product minimum_order\n\t\tif ( isset( $conds['minimum_order'] )){\n\t\t\t$this->db->where( 'minimum_order', $conds['minimum_order'] );\n\t\t}\n\n\t\t// product maximum_order\n\t\tif ( isset( $conds['maximum_order'] )){\n\t\t\t$this->db->where( 'maximum_order', $conds['maximum_order'] );\n\t\t}\n\n\t\t// point condition\n\t\tif ( isset( $conds['price_min'] ) || isset( $conds['price_max'] )) {\n\t\t\t$this->db->where( 'unit_price >= ', $conds['price_min'] );\n\t\t\t$this->db->where( 'unit_price <= ', $conds['price_max'] );\n\t\t}\n\n\t\t// feature products\n\t\tif ( isset( $conds['is_featured'] )) {\n\t\t\t$this->db->where( 'is_featured', $conds['is_featured'] );\n\t\t}\n\n\t\t// rating condition\n\t\tif ( isset( $conds['rating_value'] ) ) {\n\t\t\t// For Rating value with comma 3,4,5\n\t\t\t// $rating_value = explode(',', $conds['rating_value']);\n\t\t\t// $this->db->where_in( 'overall_rating', $rating_value);\n\n\t\t\t// For single rating value\n\t\t\t$this->db->where( 'overall_rating >=', $conds['rating_value'] );\n\t\t}\n\t\t\n\t\t// discount products\n\t\tif ( $this->is_filter_discount( $conds )) {\n\t\t\t$this->db->where( 'is_discount', '1' );\t\n\t\t}\n\n\t\t// available products\n\t\tif ( isset( $conds['is_available'] )) {\n\t\t\t$this->db->where( 'is_available', $conds['is_available'] );\n\t\t}\n\n\t\t// searchterm\n\t\tif ( isset( $conds['searchterm'] )) {\n\t\t\t$this->db->like( 'name', $conds['searchterm'] );\n\t\t}\n\n\n\t\tif( isset($conds['min_price'])) {\n\n\t\t\t\n\t\t\tif( $conds['min_price'] != 0 ) {\n\t\t\t\t$this->db->where( 'unit_price >=', $conds['min_price'] );\n\t\t\t}\n\n\t\t}\n\n\t\tif( isset($conds['max_price'])) {\n\t\t\tif( $conds['max_price'] != 0 ) {\n\t\t\t\t$this->db->where( 'unit_price <=', $conds['max_price'] );\n\t\t\t}\t\n\n\t\t}\n\n\t\t// product shop_status\n\t\tif ( isset( $conds['shop_status'] )){\n\t\t\t$this->db->where( 'shop_status', $conds['shop_status'] );\n\t\t}\n\n\t\t$this->db->order_by('added_date', 'desc' );\n\n\n\t}", "protected function _filters_to_conditions($request_data = null){\n \n $conditions = array();\n //user has to have an active account\n $conditions['User.active'] = 1;\n \n if(empty($request_data)){\n return $conditions;\n }\n \n if(!empty($request_data['motive_id'])){\n $conditions['Experience.motive_id'] = $request_data['motive_id'];\n }\n if(!empty($request_data['department_id'])){\n $conditions['User.department_id'] = $request_data['department_id'];\n }\n if(!empty($request_data['school_id'])){\n $conditions['User.school_id'] = $request_data['school_id'];\n }\n if(!empty($request_data['key_word'])){\n $conditions['Experience.description LIKE'] = '%'.$request_data['key_word'].'%';\n }\n //now\n if(!empty($request_data['date_min']) && !empty($request_data['date_max']) && ($request_data['date_min'] === $request_data['date_max'])){\n $conditions['AND'] = array('Experience.dateEnd >=' => $request_data['date_min'],\n 'Experience.dateStart <=' => $request_data['date_max']);\n }\n else{\n //futur\n if(!empty($request_data['date_min'])){\n $conditions['Experience.dateStart >='] = $request_data['date_min'];\n }\n //past\n if(!empty($request_data['date_max'])){\n $conditions['Experience.dateStart <='] = $request_data['date_max'];\n }\n }\n if(!empty($request_data['city_id'])){\n $conditions['Experience.city_id'] = $request_data['city_id'];\n }\n if(!empty($request_data['city_name'])){\n $conditions['City.name'] = $request_data['city_name'];\n }\n if(!empty($request_data['country_id'])){\n $conditions['City.country_id'] = $request_data['country_id'];\n }\n if(!empty($request_data['user_name'])){\n //extracts first and last names\n $names = explode(' ',$request_data['user_name']);\n if(count($names) > 1){\n $conditions['AND']['User.firstname LIKE'] = '%'.$names[0].'%';\n $conditions['AND']['User.lastname LIKE'] = '%'.$names[1].'%';\n }\n //if only last or first name was entered\n else{\n $conditions['OR'] = array('User.firstname LIKE' => '%'.$request_data['user_name'].'%',\n 'User.lastname LIKE' => '%'.$request_data['user_name'].'%');\n }\n }\n return $conditions;\n }", "private function _buildQuery($filters = array())\n\t{\n\t\t// var to hold conditions\n\t\t$where = array();\n\t\t$sql = '';\n\n\t\t// scope\n\t\tif (isset($filters['scope']))\n\t\t{\n\t\t\t$where[] = \"scope=\" . $this->_db->quote($filters['scope']);\n\t\t}\n\n\t\t// scope_id\n\t\tif (isset($filters['scope_id']))\n\t\t{\n\t\t\t$where[] = \"scope_id=\" . $this->_db->quote($filters['scope_id']);\n\t\t}\n\n\t\t// calendar_id\n\t\tif (isset($filters['calendar_id']))\n\t\t{\n\t\t\tif ($filters['calendar_id'] == '0')\n\t\t\t{\n\t\t\t\t$where[] = \"(calendar_id IS NULL OR calendar_id=0)\";\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$where[] = \"calendar_id=\" . $this->_db->quote($filters['calendar_id']);\n\t\t\t}\n\t\t}\n\n\t\t// published\n\t\tif (isset($filters['state']) && is_array($filters['state']))\n\t\t{\n\t\t\t$where[] = \"state IN (\" . implode(',', $filters['state']) . \")\";\n\t\t}\n\n\t\t// publish up/down\n\t\tif (isset($filters['publish_up']) && isset($filters['publish_down']))\n\t\t{\n\t\t\t$q = \"(publish_up >=\" . $this->_db->quote($filters['publish_up']);\n\t\t\t$q .= \" OR (publish_down IS NOT NULL AND publish_down != '0000-00-00 00:00:00' AND publish_down <=\" . $this->_db->quote($filters['publish_down']) . \")\";\n\t\t\t$q .= \" OR (publish_up IS NOT NULL AND publish_up <= \" . $this->_db->quote($filters['publish_up']) . \" AND publish_down >=\" . $this->_db->quote($filters['publish_down']) . \"))\";\n\t\t\t$where[] = $q;\n\t\t}\n\n\t\t// repeating event?\n\t\tif (isset($filters['repeating']))\n\t\t{\n\t\t\t$where[] = \"(repeating_rule IS NOT NULL AND repeating_rule<>'')\";\n\t\t}\n\n\t\t// only non-repeating events?\n\t\tif (isset($filters['non_repeating']))\n\t\t{\n\t\t\t$where[] = \"(repeating_rule IS NULL OR repeating_rule = '')\";\n\t\t}\n\n\t\t// if we have and conditions\n\t\tif (count($where) > 0)\n\t\t{\n\t\t\t$sql .= \" WHERE \" . implode(\" AND \", $where);\n\t\t}\n\n\t\t// specify order?\n\t\tif (isset($filters['orderby']))\n\t\t{\n\t\t\t$sql .= \" ORDER BY \" . $filters['orderby'];\n\t\t}\n\n\t\t// limit and start\n\t\tif (isset($filters['limit']))\n\t\t{\n\t\t\t$start = (isset($filters['start'])) ? $filters['start'] : 0;\n\t\t\t$sql .= \" LIMIT \" . $start . \", \" . $filters['limit'];\n\t\t}\n\n\t\treturn $sql;\n\t}", "function getSql()\n{\n\textract($this->query, EXTR_SKIP);\n\t\n\tif (!$select or !$from) return '';\n\t\n\t$sql = 'SELECT '.implode(',', $select).' FROM '.$from;\n\tif ($where) $sql .= ' WHERE '.implode(' AND ', array_unique($where));\n\tif ($whereJoin) $sql .= ($where? ' AND ':' WHERE ').implode(' AND ', array_unique($whereJoin));\n\tif ($group) $sql .= ' GROUP BY '.$group;\n\tif ($having) $sql .= ' HAVING '.implode(' AND ', array_unique($having));\n\tif ($order) $sql .= ' ORDER BY '.implode(',', $order);\n\tif ($limit) $sql .= ' LIMIT '.$limit[0].' OFFSET '.$limit[1];\n\treturn $sql;\n}", "function simplenews_build_issue_filter_query(EntityFieldQuery $query) {\n if (isset($_SESSION['simplenews_issue_filter'])) {\n foreach ($_SESSION['simplenews_issue_filter'] as $key => $value) {\n switch ($key) {\n case 'list':\n case 'newsletter':\n if ($value != 'all') {\n list($key, $value) = explode('-', $value, 2);\n $query->fieldCondition(variable_get('simplenews_newsletter_field', 'simplenews_newsletter'), 'target_id', $value);\n }\n break;\n }\n }\n }\n}", "protected function getCondition($condition)\n {\n }" ]
[ "0.68864834", "0.68085957", "0.680683", "0.6734019", "0.6692721", "0.6644008", "0.6426997", "0.63803226", "0.6374544", "0.6348217", "0.62887436", "0.62869596", "0.6280701", "0.62404245", "0.6223", "0.62116224", "0.62072766", "0.6181086", "0.61724585", "0.61554337", "0.6152544", "0.6150844", "0.61346984", "0.61205035", "0.61174756", "0.6108321", "0.61061066", "0.6104373", "0.60932744", "0.6077669", "0.6076392", "0.6070162", "0.6051325", "0.6015215", "0.5975054", "0.59597236", "0.5957139", "0.59460187", "0.59258246", "0.5919493", "0.5918278", "0.5914601", "0.5911788", "0.590853", "0.5902756", "0.59009093", "0.5889213", "0.5877309", "0.58768827", "0.58716303", "0.5857263", "0.5847065", "0.5843588", "0.58368844", "0.58351535", "0.583115", "0.58290446", "0.58205986", "0.5802862", "0.5794726", "0.5791688", "0.57903457", "0.5785998", "0.578091", "0.5775248", "0.5773325", "0.57732457", "0.5772384", "0.5769183", "0.5757289", "0.5747086", "0.57365125", "0.572529", "0.5716308", "0.57146", "0.57080436", "0.57074195", "0.5699511", "0.5699234", "0.5690015", "0.5668914", "0.56649494", "0.5655407", "0.5654942", "0.56512034", "0.56508166", "0.5650134", "0.5645331", "0.5635673", "0.5628514", "0.56279457", "0.5624563", "0.5621051", "0.56192815", "0.56095976", "0.5609072", "0.56081283", "0.56070906", "0.56069076", "0.55994886" ]
0.80201805
0
InviteHistoryHandler::displayHistory() To set display values
public function displayHistory() { $data_arr = array(); $inc = 0; while($row = $this->fetchResultRecord()) { $uDetails = $this->isMemberJoined($row['email']); $statusClass = ''; $status = $this->LANG['invitation_history_email_status_not_joined']; if ($uDetails) { $status = $this->LANG['invitation_history_email_status_joined']; } $data_arr[$inc]['date_added'] = $row['date_added']; $data_arr[$inc]['attempts'] = $row['attempts']; $data_arr[$inc]['email'] = $row['email']; $data_arr[$inc]['class'] = ($uDetails)?'clsJoined':'clsNotJoined';; $data_arr[$inc]['status'] = $status; $data_arr[$inc]['remind_url'] = getUrl('invitationhistory', '?action=remind&id='.$row['invitation_id'].'&start='.$this->fields_arr['start'], '?action=remind&id='.$row['invitation_id'].'&start='.$this->fields_arr['start']); $data_arr[$inc]['delete_url'] = getUrl('invitationhistory', '?action=delete&id='.$row['invitation_id'].'&start'.$this->fields_arr['start'], '?action=delete&id='.$row['invitation_id'].'&start'.$this->fields_arr['start']); $data_arr[$inc]['check_box_value'] = $row['invitation_id']; $inc++; } return $data_arr; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(history $history)\n {\n //\n }", "public function actionHistory()\n {\n $model= User::findOne(['id' => Yii::$app->user->identity->getId()]);\n $orders = Order::find()->where(['id_user' => $model->id])->with('orderProds')->orderBy('date DESC')->all();\n return $this->render('history', [\n 'model' => $model,\n 'orders' => $orders,\n 'page' => SmapPages::find()->where(['id_class'=>4,'alias' => 'history'])->one()\n ]);\n }", "function simple_history_print_history($args = null) {\n\t\n\tglobal $simple_history;\n\t\n\t$arr_events = simple_history_get_items_array($args);\n\t#sf_d($arr_events);\n\t#sf_d($args);sf_d($arr_events);\n\t$defaults = array(\n\t\t\"page\" => 0,\n\t\t\"items\" => $simple_history->get_pager_size(),\n\t\t\"filter_type\" => \"\",\n\t\t\"filter_user\" => \"\",\n\t\t\"is_ajax\" => false\n\t);\n\n\t$args = wp_parse_args( $args, $defaults );\n\t$output = \"\";\n\tif ($arr_events) {\n\t\tif (!$args[\"is_ajax\"]) {\n\t\t\t// if not ajax, print the div\n\t\t\t$output .= \"<div class='simple-history-ol-wrapper'><ol class='simple-history'>\";\n\t\t}\n\t\n\t\t$loopNum = 0;\n\t\t$real_loop_num = -1;\n\t\tforeach ($arr_events as $one_row) {\n\t\t\t\n\t\t\t$real_loop_num++;\n\n\t\t\t$object_type = $one_row->object_type;\n\t\t\t$object_type_lcase = strtolower($object_type);\n\t\t\t$object_subtype = $one_row->object_subtype;\n\t\t\t$object_id = $one_row->object_id;\n\t\t\t$object_name = $one_row->object_name;\n\t\t\t$user_id = $one_row->user_id;\n\t\t\t$action = $one_row->action;\n\t\t\t$action_description = $one_row->action_description;\n\t\t\t$occasions = $one_row->occasions;\n\t\t\t$num_occasions = sizeof($occasions);\n\t\t\t$object_image_out = \"\";\n\n\t\t\t$css = \"\";\n\t\t\tif (\"attachment\" == $object_type_lcase) {\n\t\t\t\tif (wp_get_attachment_image_src($object_id, array(50,50), true)) {\n\t\t\t\t\t// yep, it's an attachment and it has an icon/thumbnail\n\t\t\t\t\t$css .= ' simple-history-has-attachment-thumnbail ';\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (\"user\" == $object_type_lcase) {\n\t\t\t\t$css .= ' simple-history-has-attachment-thumnbail ';\n\t\t\t}\n\n\t\t\tif ($num_occasions > 0) {\n\t\t\t\t$css .= ' simple-history-has-occasions ';\n\t\t\t}\n\t\t\t\n\t\t\t$output .= \"<li class='$css'>\";\n\n\t\t\t$output .= \"<div class='first'>\";\n\t\t\t\n\t\t\t// who performed the action\n\t\t\t$who = \"\";\n\t\t\t$user = get_user_by(\"id\", $user_id); // false if user does not exist\n\n\t\t\tif ($user) {\n\t\t\t\t$user_avatar = get_avatar($user->user_email, \"32\"); \n\t\t\t\t$user_link = \"user-edit.php?user_id={$user->ID}\";\n\t\t\t\t$who_avatar = sprintf('<a class=\"simple-history-who-avatar\" href=\"%2$s\">%1$s</a>', $user_avatar, $user_link);\n\t\t\t} else {\n\t\t\t\t$user_avatar = get_avatar(\"\", \"32\"); \n\t\t\t\t$who_avatar = sprintf('<span class=\"simple-history-who-avatar\">%1$s</span>', $user_avatar);\n\t\t\t}\n\t\t\t$output .= $who_avatar;\n\t\t\t\n\t\t\t// section with info about the user who did something\n\t\t\t$who .= \"<span class='who'>\";\n\t\t\tif ($user) {\n\t\t\t\t$who .= sprintf('<a href=\"%2$s\">%1$s</a>', $user->user_nicename, $user_link);\n\t\t\t\tif (isset($user->first_name) || isset($user->last_name)) {\n\t\t\t\t\tif ($user->first_name || $user->last_name) {\n\t\t\t\t\t\t$who .= \" (\";\n\t\t\t\t\t\tif ($user->first_name && $user->last_name) {\n\t\t\t\t\t\t\t$who .= esc_html($user->first_name) . \" \" . esc_html($user->last_name);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$who .= esc_html($user->first_name) . esc_html($user->last_name); // just one of them, no space necessary\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$who .= \")\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$who .= \"&lt;\" . __(\"Unknown or deleted user\", 'simple-history') .\"&gt;\";\n\t\t\t}\n\t\t\t$who .= \"</span>\";\n\n\t\t\t// what and object\n\t\t\tif (\"post\" == $object_type_lcase) {\n\t\t\t\t\n\t\t\t\t$post_out = \"\";\n\t\t\t\t\n\t\t\t\t// Get real name for post type (not just the slug for custom post types)\n\t\t\t\t$post_type_object = get_post_type_object( $object_subtype );\n\t\t\t\tif ( is_null($post_type_object) ) {\n\t\t\t\t\t$post_out .= esc_html__( ucfirst( $object_subtype ) );\n\t\t\t\t} else {\n\t\t\t\t\t$post_out .= esc_html__( ucfirst( $post_type_object->labels->singular_name ) );\n\t\t\t\t}\n\n\t\t\t\t$post = get_post($object_id);\n\n\t\t\t\tif (null == $post) {\n\t\t\t\t\t// post does not exist, probably deleted\n\t\t\t\t\t// check if object_name exists\n\t\t\t\t\tif ($object_name) {\n\t\t\t\t\t\t$post_out .= \" <span class='simple-history-title'>\\\"\" . esc_html($object_name) . \"\\\"</span>\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$post_out .= \" <span class='simple-history-title'>&lt;unknown name&gt;</span>\";\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\t#$title = esc_html($post->post_title);\n\t\t\t\t\t$title = get_the_title($post->ID);\n\t\t\t\t\t$title = esc_html($title);\n\t\t\t\t\t$edit_link = get_edit_post_link($object_id, 'display');\n\t\t\t\t\t$post_out .= \" <a href='$edit_link'>\";\n\t\t\t\t\t$post_out .= \"<span class='simple-history-title'>{$title}</span>\";\n\t\t\t\t\t$post_out .= \"</a>\";\n\t\t\t\t}\n\n\t\t\t\t$post_out .= \" \" . esc_html__($action, \"simple-history\");\n\t\t\t\t\n\t\t\t\t$post_out = ucfirst($post_out);\n\t\t\t\t$output .= $post_out;\n\n\t\t\t\t\n\t\t\t} elseif (\"attachment\" == $object_type_lcase) {\n\t\t\t\n\t\t\t\t$attachment_out = \"\";\n\t\t\t\t$attachment_out .= __(\"attachment\", 'simple-history') . \" \";\n\n\t\t\t\t$post = get_post($object_id);\n\t\t\t\t\n\t\t\t\tif ($post) {\n\n\t\t\t\t\t// Post for attachment was found\n\n\t\t\t\t\t$title = esc_html(get_the_title($post->ID));\n\t\t\t\t\t$edit_link = get_edit_post_link($object_id, 'display');\n\t\t\t\t\t$attachment_metadata = wp_get_attachment_metadata( $object_id );\n\t\t\t\t\t$attachment_file = get_attached_file( $object_id );\n\t\t\t\t\t$attachment_mime = get_post_mime_type( $object_id );\n\t\t\t\t\t$attachment_url = wp_get_attachment_url( $object_id );\n\n // Check that file exists. It may not due to local dev vs remove dev etc.\n $file_exists = file_exists($attachment_file);\n\n\t\t\t\t\t// Get attachment thumbnail. 60 x 60 is the same size as the media overview uses\n\t\t\t\t\t// Is thumbnail of object if image, is wp icon if not\n\t\t\t\t\t$attachment_image_src = wp_get_attachment_image_src($object_id, array(60, 60), true);\t\t\t\t\t\n if ($attachment_image_src && $file_exists) {\n\t\t\t\t\t\t$object_image_out .= \"<a class='simple-history-attachment-thumbnail' href='$edit_link'><img src='{$attachment_image_src[0]}' alt='Attachment icon' width='{$attachment_image_src[1]}' height='{$attachment_image_src[2]}' /></a>\";\n } else {\n $object_image_out .= \"<a class='simple-history-attachment-thumbnail' href='$edit_link'></a>\";\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t// Begin adding nice to have meta info about to attachment (name, size, mime, etc.)\t\t\t\t\t\n\t\t\t\t\t$object_image_out .= \"<div class='simple-history-attachment-meta'>\";\n\n\t\t\t\t\t// File name\n\n\t\t\t\t\t// Get size in human readable format. Code snippet from media.php\n\t\t\t\t\t$sizes = array( 'KB', 'MB', 'GB' );\n\n $attachment_filesize = \"\";\n if ( $file_exists ) {\n $attachment_filesize = filesize( $attachment_file );\n for ( $u = -1; $attachment_filesize > 1024 && $u < count( $sizes ) - 1; $u++ ) {\n $attachment_filesize /= 1024;\n }\n }\n\n if (empty($attachment_filesize)) {\n $str_attachment_size = \"<p>\" . __(\"File size: Unknown \", \"simple-history\") . \"</p>\";\n } else {\n $size_unit = ($u == -1) ? __(\"bytes\", \"simple-history\") : $sizes[$u];\n $str_attachment_size = sprintf('<p>%1$s %2$s %3$s</p>', __(\"File size:\", \"simple-history\"), round( $attachment_filesize, 0 ), $size_unit );\n\t\t\t\t\t}\n\n\t\t\t\t\t// File type\n\t\t\t\t\t$file_type_out = \"\";\n\t\t\t\t\tif ( preg_match( '/^.*?\\.(\\w+)$/', $attachment_file, $matches ) )\n\t\t\t\t\t\t$file_type_out .= esc_html( strtoupper( $matches[1] ) );\n\t\t\t\t\telse\n\t\t\t\t\t\t$file_type_out .= strtoupper( str_replace( 'image/', '', $post->post_mime_type ) );\n\t\t\t\n\t\t\t\t\t// Media size, width x height\n\t\t\t\t\t$media_dims = \"\";\n\t\t\t\t\tif ( ! empty( $attachment_metadata['width'] ) && ! empty( $attachment_metadata['height'] ) ) {\n\t\t\t\t\t\t$media_dims .= \"<span>{$attachment_metadata['width']}&nbsp;&times;&nbsp;{$attachment_metadata['height']}</span>\";\n\t\t\t\t\t}\n\n\t\t\t\t\t// Generate string with metainfo\n $object_image_out .= $str_attachment_size;\n $object_image_out .= sprintf('<p>%1$s %2$s</p>', __(\"File type:\"), $file_type_out );\n\t\t\t\t\tif ( ! empty( $media_dims ) ) $object_image_out .= sprintf('<p>%1$s %2$s</p>', __(\"Dimensions:\"), $media_dims );\t\t\t\t\t\n\t\t\t\t\tif ( ! empty( $attachment_metadata[\"length_formatted\"] ) ) $object_image_out .= sprintf('<p>%1$s %2$s</p>', __(\"Length:\"), $attachment_metadata[\"length_formatted\"] );\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t// end attachment meta info box output\n\t\t\t\t\t$object_image_out .= \"</div>\"; // close simple-history-attachment-meta\n\n\t\t\t\t\t$attachment_out .= \" <a href='$edit_link'>\";\n\t\t\t\t\t$attachment_out .= \"<span class='simple-history-title'>{$title}</span>\";\n\t\t\t\t\t$attachment_out .= \"</a>\";\n\t\t\t\t\t\n\t\t\t\t} else {\n\n\t\t\t\t\t// Post for attachment was not found\n\t\t\t\t\tif ($object_name) {\n\t\t\t\t\t\t$attachment_out .= \"<span class='simple-history-title'>\\\"\" . esc_html($object_name) . \"\\\"</span>\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$attachment_out .= \" <span class='simple-history-title'>&lt;deleted&gt;</span>\";\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t$attachment_out .= \" \" . esc_html__($action, \"simple-history\") . \" \";\n\t\t\t\t\n\t\t\t\t$attachment_out = ucfirst($attachment_out);\n\t\t\t\t$output .= $attachment_out;\n\n\t\t\t} elseif (\"user\" == $object_type_lcase) {\n\n\t\t\t\t$user_out = \"\";\n\t\t\t\t$user_out .= __(\"user\", 'simple-history');\n\t\t\t\t$user = get_user_by(\"id\", $object_id);\n\t\t\t\tif ($user) {\n\t\t\t\t\t$user_link = \"user-edit.php?user_id={$user->ID}\";\n\t\t\t\t\t$user_out .= \"<span class='simple-history-title'>\";\n\t\t\t\t\t$user_out .= \" <a href='$user_link'>\";\n\t\t\t\t\t$user_out .= $user->user_nicename;\n\t\t\t\t\t$user_out .= \"</a>\";\n\t\t\t\t\tif (isset($user->first_name) && isset($user->last_name)) {\n\t\t\t\t\t\tif ($user->first_name || $user->last_name) {\n\t\t\t\t\t\t\t$user_out .= \" (\";\n\t\t\t\t\t\t\tif ($user->first_name && $user->last_name) {\n\t\t\t\t\t\t\t\t$user_out .= esc_html($user->first_name) . \" \" . esc_html($user->last_name);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$user_out .= esc_html($user->first_name) . esc_html($user->last_name); // just one of them, no space necessary\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$user_out .= \")\";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$user_out .= \"</span>\";\n\t\t\t\t} else {\n\t\t\t\t\t// most likely deleted user\n\t\t\t\t\t$user_link = \"\";\n\t\t\t\t\t$user_out .= \" \\\"\" . esc_html($object_name) . \"\\\"\";\n\t\t\t\t}\n\n\t\t\t\t$user_out .= \" \" . esc_html__($action, \"simple-history\");\n\t\t\t\t\n\t\t\t\t$user_out = ucfirst($user_out);\n\t\t\t\t$output .= $user_out;\n\n\t\t\t} elseif (\"comment\" == $object_type_lcase) {\n\t\t\t\t\n\t\t\t\t$comment_link = get_edit_comment_link($object_id);\n\t\t\t\t$output .= ucwords(esc_html__(ucfirst($object_type))) . \" \" . esc_html($object_subtype) . \" <a href='$comment_link'><span class='simple-history-title'>\" . esc_html($object_name) . \"\\\"</span></a> \" . esc_html__($action, \"simple-history\");\n\n\t\t\t} else {\n\n\t\t\t\t// unknown/general type\n\t\t\t\t// translate the common types\n\t\t\t\t$unknown_action = $action;\n\t\t\t\tswitch ($unknown_action) {\n\t\t\t\t\tcase \"activated\":\n\t\t\t\t\t\t$unknown_action = __(\"activated\", 'simple-history');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase \"deactivated\":\n\t\t\t\t\t\t$unknown_action = __(\"deactivated\", 'simple-history');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase \"enabled\":\n\t\t\t\t\t\t$unknown_action = __(\"enabled\", 'simple-history');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase \"disabled\":\n\t\t\t\t\t\t$unknown_action = __(\"disabled\", 'simple-history');\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tdefault:\n\t\t\t\t\t\t$unknown_action = $unknown_action; // dah!\n\t\t\t\t}\n\t\t\t\t$output .= ucwords(esc_html__($object_type, \"simple-history\")) . \" \" . ucwords(esc_html__($object_subtype, \"simple-history\")) . \" <span class='simple-history-title'>\\\"\" . esc_html($object_name) . \"\\\"</span> \" . esc_html($unknown_action);\n\n\t\t\t}\n\t\t\t$output .= \"</div>\";\n\t\t\t\n\t\t\t// second div = when and who\n\t\t\t$output .= \"<div class='second'>\";\n\t\t\t\n\t\t\t$date_i18n_date = date_i18n(get_option('date_format'), strtotime($one_row->date), $gmt=false);\n\t\t\t$date_i18n_time = date_i18n(get_option('time_format'), strtotime($one_row->date), $gmt=false);\t\t\n\t\t\t$now = strtotime(current_time(\"mysql\"));\n\t\t\t$diff_str = sprintf( __('<span class=\"when\">%1$s ago</span> by %2$s', \"simple-history\"), human_time_diff(strtotime($one_row->date), $now), $who );\n\t\t\t$output .= $diff_str;\n\t\t\t$output .= \"<span class='when_detail'>\".sprintf(__('%s at %s', 'simple-history'), $date_i18n_date, $date_i18n_time).\"</span>\";\n\n\t\t\t// action description\n\t\t\tif ( trim( $action_description ) ) {\n\t\t\t\t$output .= sprintf(\n\t\t\t\t\t'\n\t\t\t\t\t<a href=\"#\" class=\"simple-history-item-description-toggler\">%2$s</a>\n\t\t\t\t\t<div class=\"simple-history-item-description-wrap\">\n\t\t\t\t\t\t<div class=\"simple-history-action-description\">%1$s</div>\n\t\t\t\t\t</div>\n\t\t\t\t\t',\n\t\t\t\t\tnl2br( esc_attr( $action_description ) ), // 2\n\t\t\t\t\t__(\"Details\", \"simple-history\") // 2\n\t\t\t\t);\n\t\t\t}\n\t\t\t\n\t\t\t$output .= \"</div>\";\n\n\t\t\t// Object image\n\t\t\tif ( $object_image_out ) {\n\n\t\t\t\t$output .= sprintf(\n\t\t\t\t\t'\n\t\t\t\t\t<div class=\"simple-history-object-image\">\n\t\t\t\t\t\t%1$s\n\t\t\t\t\t</div>\n\t\t\t\t\t',\n\t\t\t\t\t$object_image_out\n\t\t\t\t);\n\n\t\t\t}\n\n\t\t\t// occasions\n\t\t\tif ($num_occasions > 0) {\n\t\t\t\t$output .= \"<div class='third'>\";\n\t\t\t\tif ($num_occasions == 1) {\n\t\t\t\t\t$one_occasion = __(\"+ 1 occasion\", 'simple-history');\n\t\t\t\t\t$output .= \"<a class='simple-history-occasion-show' href='#'>$one_occasion</a>\";\n\t\t\t\t} else {\n\t\t\t\t\t$many_occasion = sprintf(__(\"+ %d occasions\", 'simple-history'), $num_occasions);\n\t\t\t\t\t$output .= \"<a class='simple-history-occasion-show' href='#'>$many_occasion</a>\";\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$output .= \"<ul class='simple-history-occasions hidden'>\";\n\t\t\t\tforeach ($occasions as $one_occasion) {\n\t\t\t\t\n\t\t\t\t\t$output .= \"<li>\";\n\t\t\t\t\n\t\t\t\t\t$date_i18n_date = date_i18n(get_option('date_format'), strtotime($one_occasion->date), $gmt=false);\n\t\t\t\t\t$date_i18n_time = date_i18n(get_option('time_format'), strtotime($one_occasion->date), $gmt=false);\t\t\n\t\t\t\t\n\t\t\t\t\t$output .= \"<div class='simple-history-occasions-one-when'>\";\n\t\t\t\t\t$output .= sprintf(\n\t\t\t\t\t\t\t__('%s ago (%s at %s)', \"simple-history\"), \n\t\t\t\t\t\t\thuman_time_diff(strtotime($one_occasion->date), $now), \n\t\t\t\t\t\t\t$date_i18n_date, \n\t\t\t\t\t\t\t$date_i18n_time\n\t\t\t\t\t\t);\n\t\t\t\t\t\n\t\t\t\t\tif ( trim( $one_occasion->action_description ) ) {\n\t\t\t\t\t\t$output .= \"<a href='#' class='simple-history-occasions-details-toggle'>\" . __(\"Details\", \"simple-history\") . \"</a>\";\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$output .= \"</div>\";\n\n\t\t\t\t\tif ( trim( $one_occasion->action_description ) ) {\n\t\t\t\t\t\t$output .= sprintf(\n\t\t\t\t\t\t\t'<div class=\"simple-history-occasions-one-action-description\">%1$s</div>',\n\t\t\t\t\t\t\tnl2br( esc_attr( $one_occasion->action_description ) )\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\n\n\t\t\t\t\t$output .= \"</li>\";\n\t\t\t\t}\n\n\t\t\t\t$output .= \"</ul>\";\n\n\t\t\t\t$output .= \"</div>\";\n\t\t\t}\n\n\t\t\t$output .= \"</li>\";\n\n\t\t\t$loopNum++;\n\n\t\t}\n\t\t\n\t\t// if $loopNum == 0 no items where found for this page\n\t\tif ($loopNum == 0) {\n\t\t\t$output .= \"noMoreItems\";\n\t\t}\n\t\t\n\t\tif ( ! $args[\"is_ajax\"] ) {\n\n\t\t\t// if not ajax, print the divs and stuff we need\n\t\t\t$show_more = \"<select>\";\n\t\t\t$show_more .= sprintf('<option value=5 %2$s>%1$s</option>', __(\"Show 5 more\", 'simple-history'), ($args[\"items\"] == 5 ? \" selected \" : \"\") );\n\t\t\t$show_more .= sprintf('<option value=15 %2$s>%1$s</option>', __(\"Show 15 more\", 'simple-history'), ($args[\"items\"] == 15 ? \" selected \" : \"\") );\n\t\t\t$show_more .= sprintf('<option value=50 %2$s>%1$s</option>', __(\"Show 50 more\", 'simple-history'), ($args[\"items\"] == 50 ? \" selected \" : \"\") );\n\t\t\t$show_more .= sprintf('<option value=100 %2$s>%1$s</option>', __(\"Show 100 more\", 'simple-history'), ($args[\"items\"] == 100 ? \" selected \" : \"\") );\n\t\t\t$show_more .= \"</select>\";\n\n\t\t\t$no_found = __(\"No matching items found.\", 'simple-history');\n\t\t\t$view_rss = __(\"RSS feed\", 'simple-history');\n\t\t\t$view_rss_link = simple_history_get_rss_address();\n\t\t\t$str_show = __(\"Show\", 'simple-history');\n\t\t\t$output .= \"</ol>\";\n\n\t\t\t$output .= sprintf( '\n\t\t\t\t\t<div class=\"simple-history-loading\">%2$s %1$s</div>\n\t\t\t\t\t', \n\t\t\t\t\t__(\"Loading...\", 'simple-history'), // 1\n\t\t\t\t\t\"<img src='\".site_url(\"wp-admin/images/loading.gif\").\"' width=16 height=16>\"\n\t\t\t\t);\n\n\t\t\t$output .= \"</div>\";\n\n\t\t\t$output .= \"\n\t\t\t\t<p class='simple-history-no-more-items'>$no_found</p>\t\t\t\n\t\t\t\t<p class='simple-history-rss-feed-dashboard'><a title='$view_rss' href='$view_rss_link'>$view_rss</a></p>\n\t\t\t\t<p class='simple-history-rss-feed-page'><a title='$view_rss' href='$view_rss_link'><span></span>$view_rss</a></p>\n\t\t\t\";\n\n\t\t}\n\n\t} else {\n\n\t\tif ($args[\"is_ajax\"]) {\n\t\t\t$output .= \"noMoreItems\";\n\t\t} else {\n\t\t\t$no_found = __(\"No history items found.\", 'simple-history');\n\t\t\t$please_note = __(\"Please note that Simple History only records things that happen after this plugin have been installed.\", 'simple-history');\n\t\t\t$output .= \"<p>$no_found</p>\";\n\t\t\t$output .= \"<p>$please_note</p>\";\n\t\t}\n\n\t}\n\treturn $output;\n}", "public function show($historyUser)\n {\n //\n }", "public function actionHistory()\n {\n $this->pageTitle = 'Your Viewing History';\n\n $data['pageHistory'] = History::model()->all('page');\n $data['pdfHistory'] = History::model()->all('pdf');\n\n $this->render('//content/history', $data);\n }", "public static function showList() {\n $template = file_get_contents(plugin_dir_path(__FILE__) . 'templates/login_history.html');\n\n $results = self::queryLoginHistories('desc', 25);\n $histories = '';\n foreach ($results as $history) {\n $histories .= '<tr><td>' . $history->logged_in_at. '</td><td>' . $history->user_login . '</td><td>' . $history->remote_ip . '</td><td>' . $history->user_agent . '</td></tr>';\n }\n\n $output = str_replace('%%page_title%%', get_admin_page_title(), $template);\n $output = str_replace('%%login_histories%%', $histories, $output);\n $output = str_replace('%%Recent%%', __('Recent', 'simple-login-history'), $output);\n $output = str_replace('%%record%%', __('record', 'simple-login-history'), $output);\n $output = str_replace('%%csv_download_link%%', plugin_dir_url(__FILE__) . 'download.php', $output);\n echo $output;\n }", "function parse_history_zone()\n\t\t{\n\t\t\tif ( (empty($this->display_history)) || (!($this->display_history)))\n\t\t\t{\n\t\t\t\t//hide the history zone\n\t\t\t\t$this->t->set_var(array( 'history' => ''));\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$inst_parser =& CreateObject('workflow.bo_uiinstance', $this->t);\n\t\t\t\t$inst_parser->t =& $this->t;\n\t\t\t\t$inst_parser->parse_instance_history($this->instance->workitems);\n\t\t\t\t$this->t->set_var('history', $this->t->parse('output', 'history_tpl'));\n\t\t\t}\n\t\t}", "public function canShowHistory() {}", "protected function showmyhistory() {\n global $USER, $PAGE;\n\n // Create a navigation cache so that we can store the history\n $cache = new navigation_cache('navigationhistory', 60*60);\n\n // If the user isn't logged in or is a guest we don't want to display anything\n if (!isloggedin() || isguestuser()) {\n return false;\n }\n\n // Check the cache to see if we have loaded my courses already\n // there is a very good chance that we have\n if (!$cache->cached('history')) {\n $cache->history = array();\n }\n $history = $cache->history;\n $historycount = count($history);\n\n // Find the initial active node\n $child = false;\n if ($PAGE->navigation->contains_active_node()) {\n $child = $PAGE->navigation->find_active_node();\n } else if ($PAGE->settingsnav->contains_active_node()) {\n $child = $PAGE->settingsnav->find_active_node();\n }\n // Check that we found an active child node\n if ($child!==false) {\n $properties = array();\n // Check whether this child contains another active child node\n // this can happen if we are looking at a module\n if ($child->contains_active_node()) {\n $titlebits = array();\n // Loop while the child contains active nodes and in each iteration\n // find the next node in the correct direction\n while ($child!==null && $child->contains_active_node()) {\n if (!empty($child->shorttext)) {\n $titlebits[] = $child->shorttext;\n } else {\n $titlebits[] = $child->text;\n }\n foreach ($child->children as $child) {\n if ($child->contains_active_node() || $child->isactive) {\n // We have found the active child or one of its parents\n // so break the foreach so we can proceed in the while\n break;\n }\n }\n }\n if (!empty($child->shorttext)) {\n $titlebits[] = $child->shorttext;\n } else {\n $titlebits[] = $child->text;\n }\n $properties['text'] = join(' - ', $titlebits);\n $properties['shorttext'] = join(' - ', $titlebits);\n } else {\n $properties['text'] = $child->text;\n $properties['shorttext'] = $child->shorttext;\n }\n $properties['action'] = $child->action;\n $properties['key'] = $child->key;\n $properties['type'] = $child->type;\n $properties['icon'] = $child->icon;\n\n // Create a new navigation node object free of the main structure\n // so that it is easily storeable and customised\n $child = new navigation_node($properties);\n\n // Check that this page isn't already in the history array. If it is\n // we will remove it so that it gets added at the top and we dont get\n // duplicate entries\n foreach ($history as $key=>$node) {\n if ($node->key == $child->key && $node->type == $child->type) {\n if ($node->action instanceof moodle_url && $child->action instanceof moodle_url && $node->action->compare($child->action)) {\n unset($history[$key]);\n } else if ($child->action instanceof moodle_url && $child->action->out_omit_querystring() == $node->action) {\n unset($history[$key]);\n } else if ($child->action == $node->action) {\n unset($history[$key]);\n }\n }\n }\n // If there is more than 5 elements in the array remove the first one\n // We want a fifo array\n if (count($history) > 5) {\n array_shift($history);\n }\n $child->nodetype = navigation_node::NODETYPE_LEAF;\n $child->children = array();\n // Add the child to the history array\n array_push($history,$child);\n }\n\n // If we have `more than nothing` in the history display it :D\n if ($historycount > 0) {\n // Add a branch to hold the users history\n $mymoodle = $PAGE->navigation->get('mymoodle', navigation_node::TYPE_CUSTOM);\n $myhistorybranch = $mymoodle->add(get_string('showmyhistorytitle', $this->blockname), null, navigation_node::TYPE_CUSTOM, null, 'myhistory');\n $mymoodle->get($myhistorybranch)->children = array_reverse($history);\n }\n\n // Cache the history (or update the cached history as it is)\n $cache->history = $history;\n\n return true;\n }", "public function clienthistoryAction()\n {\n // If no client ID was provided, bail out.\n if (!$this->_hasParam('id')) {\n throw new UnexpectedValueException('No client ID parameter provided');\n }\n\n $clientId = $this->_getParam('id');\n\n // Pass current and past client and household history.\n $service = new App_Service_Member();\n\n $this->view->pageTitle = 'View Household History';\n $this->view->client = $service->getClientById($clientId);\n $this->view->householders = $service->getHouseholdersByClientId($clientId);\n $this->view->history = $service->getClientHouseholdHistory($clientId);\n }", "function action_history()\n{\n\tglobal $pagestore, $page, $full, $HistMax;\n\n\t$history = $pagestore->history($page);\n\n\tgen_headers($history[0][0]);\n\n\n\t$text = '';\n\t$latest_auth = '';\n\t$previous_ver = 0;\n\t$is_latest = 1;\n\n\tfor($i = 0; $i < count($history); $i++)\n\t{\n\t\tif($latest_auth == '')\n\t\t{\n\t\t\t$latest_auth = ($history[$i][3] == '' ? $history[$i][1]\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t: $history[$i][3]);\n\t\t\t$latest_ver = $history[$i][2];\n\t\t}\n\n\t\tif($previous_ver == 0\n\t\t\t && $latest_auth != ($history[$i][3] == '' ? $history[$i][1]\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t : $history[$i][3]))\n\t\t\t{ $previous_ver = $history[$i][2]; }\n\n\t\tif($i < $HistMax || $full)\n\t\t{\n\t\t\t$text = $text . html_history_entry($page, $history[$i][2],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $history[$i][0], $history[$i][1],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $history[$i][3],\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $previous_ver == $history[$i][2] || !$full && $i == count($history)-1,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $is_latest, $history[$i][4]);\n\t\t}\n\n\t\t$is_latest = 0;\n\t}\n\n\tif($i >= $HistMax && !$full)\n\t\t{ $text = $text . html_fullhistory($page, count($history)); }\n\n\t$p1 = $pagestore->page($page);\n\t$p1->version = $previous_ver;\n\t$p2 = $pagestore->page($page);\n\t$p2->version = $latest_ver;\n\n\t$diff = diff_compute($p1->read(), $p2->read());\n\ttemplate_history(array('page' => $p2->as_array(),\n\t\t\t\t\t\t\t\t\t\t\t\t 'history' => $text,\n\t\t\t\t\t\t\t\t\t\t\t\t 'diff' => diff_parse($diff)));\n}", "public function history()\n\t{\n\t\t$migration = new \\Hubzero\\Content\\Migration();\n\t\t$history = $migration->history();\n\t\t$items = [];\n\t\t$maxFile = 0;\n\t\t$maxUser = 0;\n\t\t$maxScope = 0;\n\n\n\t\tif ($history && count($history) > 0)\n\t\t{\n\t\t\t$items[] = [\n\t\t\t\t'File',\n\t\t\t\t'By',\n\t\t\t\t'Direction',\n\t\t\t\t'Date'\n\t\t\t];\n\n\t\t\tforeach ($history as $entry)\n\t\t\t{\n\t\t\t\t$items[] = [\n\t\t\t\t\t$entry->scope . DS . $entry->file,\n\t\t\t\t\t$entry->action_by,\n\t\t\t\t\t$entry->direction,\n\t\t\t\t\t$entry->date\n\t\t\t\t];\n\t\t\t}\n\n\t\t\t$this->output->addTable($items, true);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->addLine('No history to display.');\n\t\t}\n\t}", "public function history()\n {\n $data['title'] = 'Cuci Sepatu | Kang Cuci';\n $data['user'] = $this->workerModel->datauser();\n\n $this->load->view('worker/worker_header', $data);\n $this->load->view('worker/panel/sepatu', $data);\n $this->load->view('worker/worker_footer');\n }", "public function viewHistory() {\n $historyRows = $this->db->query(\"SELECT * FROM history\");\n if (!$historyRows) die(\"Fatal Error.\");\n\n // Looping through all rows in the histoy table.\n $history = [];\n foreach($historyRows as $historyRow) {\n $regNr = htmlspecialchars($historyRow[\"regNr\"]);\n $ssNr = htmlspecialchars($historyRow[\"ssNr\"]);\n $checkOut = htmlspecialchars($historyRow[\"checkOutTime\"]);\n $checkIn = htmlspecialchars($historyRow[\"checkInTime\"]);\n $days = htmlspecialchars($historyRow[\"days\"]);\n $cost = htmlspecialchars($historyRow[\"cost\"]);\n\n // Setting 0 as default value on days and cost if car not checked in yet.\n if (!$checkIn) {\n $checkIn = \"Checked Out\";\n $days = 0;\n $cost = 0;\n }\n \n $histor = [\"regNr\" => $regNr,\n \"ssNr\" => $ssNr, \n \"checkOut\" => $checkOut,\n \"checkIn\" => $checkIn, \n \"days\" => $days,\n \"cost\" => $cost,\n \"days\" => $days];\n \n $history[] = $histor;\n }\n return $history;\n }", "public function action_chat_history() {\n\t\t$this->_template->set('page_title', 'All Messages');\n\t\t$this->_template->set('page_info', 'view and manage chat messages');\n\t\t$messages = ORM::factory('Message')->get_grouped_messages($this->_current_user->id);\n\t\t$this->_template->set('messages', $messages);\n\t\t$this->_set_content('messages');\n\t}", "public function action_index()\n{\n $history = Jelly::select( 'user_history' )\n ->where(':primary_key', '=', $this->user->id)\n ->limit( 25 )\n ->execute();\n\n $this->template->content = View::factory('history/index')\n ->set('history', $history);\n\n}", "public function getHistory(){\n \t$History = HPP::where([['hpp_kind','=','history'],['hpp_city_id','=',1]])->get();\n \treturn view('Admin.HistoryPlanPurpose.History' , compact('History'));\n }", "public function actionCron_jobs_history()\n {\n $request = Yii::app()->request;\n $model = new ConsoleCommandListHistory('search');\n $model->unsetAttributes();\n\n $model->attributes = (array)$request->getQuery($model->modelName, array());\n \n $this->setData(array(\n 'pageMetaTitle' => $this->data->pageMetaTitle . ' | '. Yii::t('cronjobs', 'View cron jobs history'),\n 'pageHeading' => Yii::t('cronjobs', 'View cron jobs history'),\n 'pageBreadcrumbs' => array(\n Yii::t('cronjobs', 'Cron jobs history'),\n )\n ));\n\n $this->render('cron-jobs-history', compact('model'));\n }", "private function showPage($records)\n {\n $this->data['histories'] = '';\n $this->data['histories'] = $records;\n\n $this->data['pagebody'] = 'History';\n $this->render();\n }", "function simple_history_management_page() {\n\n\tglobal $simple_history;\n\n\tsimple_history_purge_db();\n\n\t?>\n\n\t<div class=\"wrap simple-history-wrap\">\n\t\t<h2><?php echo __(\"History\", 'simple-history') ?></h2>\n\t\t<?php\t\n\t\tsimple_history_print_nav(array(\"from_page=1\"));\n\t\techo simple_history_print_history(array(\"items\" => $simple_history->get_pager_size(), \"from_page\" => \"1\"));\n\t\techo simple_history_get_pagination();\n\t\t?>\n\t</div>\n\n\t<?php\n\n}", "public function getHistory() {\n $rentalModel = new RentalModel($this->db);\n\n try {\n $rentals = $rentalModel->getAll();\n } catch (\\Exception $e) {\n $properties = ['errorMessage' => 'Error getting rental history.'];\n return $this->render('error.twig', $properties);\n }\n\n $properties = [\"rentals\" => $rentals];\n return $this->render('history.twig', $properties);\n }", "public function history()\n {\n $data['courses'] = $this->exchange_rates_model->get_courses();\n $data['title'] = 'History course';\n\n $this->load->view('templates/header', $data);\n $this->load->view('exchange_rates/history', $data);\n $this->load->view('templates/footer');\n }", "public function history()\n {\n $tittle['tittle'] = 'History Penjualan';\n\n $data = array(\n 'data_penjualan' => $this->penjualan->ambil_data_penjualan()->result_array(),\n 'data_detail_penjualan' => $this->penjualan->ambil_detail_penjualan(),\n 'user' => $this->db->get_where('user', ['username' =>\n $this->session->userdata('username')])->row_array()\n );\n\n //View dari Controller akuntansi/index\n $this->load->view('template/header', $tittle);\n $this->load->view('template/topbar', $data);\n $this->load->view('template/sidebar', $data);\n $this->load->view('transaksi/history', $data);\n $this->load->view('template/footer');\n }", "public function show(Histories $histories)\n {\n //\n }", "function history()\n {\n $data['tbl_history'] = $this->Tbl_history_model->get_tbl_history();\n \n if(isset($data['tbl_history']['id_history']))\n {\n if(isset($_POST) && count($_POST) > 0) \n { \n $params = array(\n 'history_desc_id' => $this->input->post('history_desc_id'),\n 'history_desc_en' => $this->input->post('history_desc_en'),\n );\n\n $this->Tbl_history_model->update_tbl_history($params); \n redirect('admin/history');\n }\n else\n {\n $data = array(\n \"site\" => $_SERVER['SERVER_NAME'],\n \"page\" => \"History\",\n \"tbl_history\" => $this->Tbl_history_model->get_tbl_history()\n );\n $this->load->view('layout/admin/header', $data);\n $this->load->view('edit_history',$data);\n $this->load->view('layout/admin/footer');\n }\n }\n else\n show_error('The tbl_home you are trying to edit does not exist.');\n }", "public function userHistory() {\n\t\t[ $response, $error ] = $this->api('user/history');\n\n\t\tif($error) return $this->response($response, $error);\n\n\t\treturn $this->response($response['links']);\n\t}", "public function history()\n\t{\n $orders = $this->history->get_history();\n foreach($orders as $order)\n {\n if($order->added_by=='customer')\n {\n $agency_id = $this->Common->get_details('agency_orders',array('order_id'=>$order->order_id))->row()->agency_id;\n $agency_check = $this->Common->get_details('agencies',array('agency_id'=>$agency_id));\n if($agency_check->num_rows()>0)\n {\n $order->agency = $agency_check->row()->agency_name;\n }\n else\n {\n $order->agency = '';\n }\n }\n }\n $data['orders'] = $orders;\n\t\t$this->load->view('admin/bill/history',$data);\n\t}", "public function attendance_list($history = false, $messages = array())\n {\n $data = array();\n\n // render to the view\n $this->view->set_data($data);\n $this->view->set_layout('layout');\n $this->view->set_template('attendance_list');\n $this->view->render();\n }", "public function getHistory()\n {\n return view('PagePersonal.history');\n }", "static function showHistory($ID_port) {\n global $DB,$LANG,$INFOFORM_PAGES,$CFG_GLPI;\n\n include (GLPI_ROOT . \"/plugins/fusioninventory/inc_constants/snmp.mapping.constant.php\");\n\n $CommonItem = new CommonItem;\n $np = new Netport;\n\n $query = \"\n SELECT * FROM(\n SELECT * FROM (\n SELECT ID, date as date, process_number as process_number,\n FK_port_source, FK_port_destination,\n creation as Field, NULL as old_value, NULL as new_value\n\n FROM glpi_plugin_fusioninventory_snmphistoryconnections\n WHERE `FK_port_source`='\".$ID_port.\"'\n OR `FK_port_destination`='\".$ID_port.\"'\n ORDER BY date DESC\n LIMIT 0,30\n )\n AS DerivedTable1\n UNION ALL\n SELECT * FROM (\n SELECT ID, date_mod as date, FK_process as process_number,\n FK_ports AS FK_port_source, NULL as FK_port_destination,\n Field, old_value, new_value\n\n FROM glpi_plugin_fusioninventory_snmphistories\n WHERE `FK_ports`='\".$ID_port.\"'\n ORDER BY date DESC\n LIMIT 0,30\n )\n AS DerivedTable2)\n AS MainTable\n ORDER BY date DESC, ID DESC\n LIMIT 0,30\";\n //echo $query.\"<br/>\";\n $text = \"<table class='tab_cadre' cellpadding='5' width='950'>\";\n\n $text .= \"<tr class='tab_bg_1'>\";\n $text .= \"<th colspan='8'>\";\n $text .= \"Historique\";\n $text .= \"</th>\";\n $text .= \"</tr>\";\n\n $text .= \"<tr class='tab_bg_1'>\";\n $text .= \"<th>\".$LANG['plugin_fusioninventory'][\"snmp\"][50].\"</th>\";\n $text .= \"<th>\".$LANG[\"common\"][1].\"</th>\";\n $text .= \"<th>\".$LANG[\"event\"][18].\"</th>\";\n $text .= \"<th></th>\";\n $text .= \"<th></th>\";\n $text .= \"<th></th>\";\n $text .= \"<th>\".$LANG[\"common\"][27].\"</th>\";\n $text .= \"</tr>\";\n\n if ($result=$DB->query($query)) {\n while ($data=$DB->fetch_array($result)) {\n $text .= \"<tr class='tab_bg_1'>\";\n if (!empty($data[\"FK_port_destination\"])) {\n // Connections and disconnections\n if ($data['Field'] == '1') {\n $text .= \"<td align='center'><img src='\".GLPI_ROOT.\"/plugins/fusioninventory/pics/connection_ok.png'/></td>\";\n } else {\n $text .= \"<td align='center'><img src='\".GLPI_ROOT.\"/plugins/fusioninventory/pics/connection_notok.png'/></td>\";\n }\n if ($ID_port == $data[\"FK_port_source\"]) {\n $np->getFromDB($data[\"FK_port_destination\"]);\n if (isset($np->fields[\"on_device\"])) {\n $CommonItem->getFromDB($np->fields[\"device_type\"],\n $np->fields[\"on_device\"]);\n $link1 = $CommonItem->getLink(1);\n $link = \"<a href=\\\"\" . $CFG_GLPI[\"root_doc\"] . \"/front/networking.port.php?ID=\" . $np->fields[\"ID\"] . \"\\\">\";\n if (rtrim($np->fields[\"name\"]) != \"\")\n $link .= $np->fields[\"name\"];\n else\n $link .= $LANG['common'][0];\n $link .= \"</a>\";\n $text .= \"<td align='center'>\".$link.\" \".$LANG['networking'][25].\" \".$link1.\"</td>\";\n } else {\n $text .= \"<td align='center'><font color='#ff0000'>\".$LANG['common'][28].\"</font></td>\";\n }\n\n } else if ($ID_port == $data[\"FK_port_destination\"]) {\n $np->getFromDB($data[\"FK_port_source\"]);\n if (isset($np->fields[\"on_device\"])) {\n $CommonItem->getFromDB($np->fields[\"device_type\"],\n $np->fields[\"on_device\"]);\n $link1 = $CommonItem->getLink(1);\n $link = \"<a href=\\\"\" . $CFG_GLPI[\"root_doc\"] . \"/front/networking.port.php?ID=\" . $np->fields[\"ID\"] . \"\\\">\";\n if (rtrim($np->fields[\"name\"]) != \"\")\n $link .= $np->fields[\"name\"];\n else\n $link .= $LANG['common'][0];\n $link .= \"</a>\";\n $text .= \"<td align='center'>\".$link.\" \".$LANG['networking'][25].\" \".$link1.\"</td>\";\n } else {\n $text .= \"<td align='center'><font color='#ff0000'>\".$LANG['common'][28].\"</font></td>\";\n }\n }\n $text .= \"<td align='center' colspan='4'></td>\";\n $text .= \"<td align='center'>\".convDateTime($data[\"date\"]).\"</td>\";\n\n } else {\n // Changes values\n $text .= \"<td align='center' colspan='2'></td>\";\n $text .= \"<td align='center'>\".$FUSIONINVENTORY_MAPPING[NETWORKING_TYPE][$data[\"Field\"]]['name'].\"</td>\";\n $text .= \"<td align='center'>\".$data[\"old_value\"].\"</td>\";\n $text .= \"<td align='center'>-></td>\";\n $text .= \"<td align='center'>\".$data[\"new_value\"].\"</td>\";\n $text .= \"<td align='center'>\".convDateTime($data[\"date\"]).\"</td>\";\n }\n $text .= \"</tr>\";\n }\n }\n\n /*\n $pthc = new PluginFusioninventorySnmphistoryconnection;\n\n $data_connections = $pthc->find('`FK_port_source`=\"'.$ID_port.'\"\n OR `FK_port_destination `=\"'.$ID_port.'\"',\n '`date` DESC',\n '0,30');\n $query = \"SELECT *\n FROM `glpi_plugin_fusioninventory_snmphistories`\n WHERE `FK_ports`='\".$ID_port.\"'\n ORDER BY `date_mod` DESC\n LIMIT 0,30;\";\n\n\n $text = \"<table class='tab_cadre' cellpadding='5' width='950'>\";\n\n $text .= \"<tr class='tab_bg_1'>\";\n $text .= \"<th colspan='8'>\";\n $text .= \"Historique\";\n $text .= \"</th>\";\n $text .= \"</tr>\";\n\n $text .= \"<tr class='tab_bg_1'>\";\n $text .= \"<th>\".$LANG['plugin_fusioninventory'][\"snmp\"][50].\"</th>\";\n $text .= \"<th>\".$LANG[\"common\"][1].\"</th>\";\n $text .= \"<th>\".$LANG[\"networking\"][15].\"</th>\";\n $text .= \"<th>\".$LANG[\"event\"][18].\"</th>\";\n $text .= \"<th></th>\";\n $text .= \"<th></th>\";\n $text .= \"<th></th>\";\n $text .= \"<th>\".$LANG[\"common\"][27].\"</th>\";\n $text .= \"</tr>\";\n\n if ($result=$DB->query($query)) {\n while ($data=$DB->fetch_array($result)) {\n $text .= \"<tr class='tab_bg_1'>\";\n\n if (($data[\"old_device_ID\"] != \"0\") OR ($data[\"new_device_ID\"] != \"0\")) {\n // Connections and disconnections\n if ($data[\"old_device_ID\"] != \"0\") {\n $text .= \"<td align='center'>\".$LANG['plugin_fusioninventory'][\"history\"][2].\"</td>\";\n $CommonItem->getFromDB($data[\"old_device_type\"],$data[\"old_device_ID\"]);\n $text .= \"<td align='center'>\".$CommonItem->getLink(1).\"</td>\";\n $text .= \"<td align='center'>\".$data[\"old_value\"].\"</td>\";\n } else if ($data[\"new_device_ID\"] != \"0\") {\n $text .= \"<td align='center'>\".$LANG['plugin_fusioninventory'][\"history\"][3].\"</td>\";\n $CommonItem->getFromDB($data[\"new_device_type\"],$data[\"new_device_ID\"]);\n $text .= \"<td align='center'>\".$CommonItem->getLink(1).\"</td>\";\n $text .= \"<td align='center'>\".$data[\"new_value\"].\"</td>\";\n }\n $text .= \"<td align='center' colspan='4'></td>\";\n $text .= \"<td align='center'>\".convDateTime($data[\"date_mod\"]).\"</td>\";\n\n } else if (($data[\"old_device_ID\"] == \"0\") AND ($data[\"new_device_ID\"] == \"0\") AND ($data[\"Field\"] == \"0\")) {\n // Unknown Mac address\n if (!empty($data[\"old_value\"])) {\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$LANG['plugin_fusioninventory'][\"history\"][2].\"</td>\";\n $CommonItem->getFromDB($data[\"old_device_type\"],$data[\"old_device_ID\"]);\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$CommonItem->getLink(1).\"</td>\";\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$data[\"old_value\"].\"</td>\";\n } else if (!empty($data[\"new_value\"])) {\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$LANG['plugin_fusioninventory'][\"history\"][3].\"</td>\";\n $CommonItem->getFromDB($data[\"new_device_type\"],$data[\"new_device_ID\"]);\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$CommonItem->getLink(1).\"</td>\";\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".$data[\"new_value\"].\"</td>\";\n }\n $text .= \"<td align='center' colspan='4' background='#cf9b9b' class='tab_bg_1_2'></td>\";\n $text .= \"<td align='center' background='#cf9b9b' class='tab_bg_1_2'>\".convDateTime($data[\"date_mod\"]).\"</td>\";\n } else {\n // Changes values\n $text .= \"<td align='center' colspan='3'></td>\";\n $text .= \"<td align='center'>\".$data[\"Field\"].\"</td>\";\n $text .= \"<td align='center'>\".$data[\"old_value\"].\"</td>\";\n $text .= \"<td align='center'>-></td>\";\n $text .= \"<td align='center'>\".$data[\"new_value\"].\"</td>\";\n $text .= \"<td align='center'>\".convDateTime($data[\"date_mod\"]).\"</td>\";\n }\n $text .= \"</tr>\";\n }\n }\n */\n $text .= \"<tr class='tab_bg_1'>\";\n $text .= \"<th colspan='8'>\";\n $text .= \"<a href='\".GLPI_ROOT.\"/plugins/fusioninventory/report/switch_ports.history.php?FK_networking_ports=\".$ID_port.\"'>Voir l'historique complet</a>\";\n $text .= \"</th>\";\n $text .= \"</tr>\";\n $text .= \"</table>\";\n return $text;\n }", "public static function history($request, $response)\n {\n $personal = false;\n if ($request->getUri() == \"/dashboard/history\") {\n $history = Requests::getPersonalHistory($_SESSION[\"username\"]);\n $personal = true;\n } else {\n $history = Requests::getAll();\n }\n return $response->render(\n __DIR__ . '/../Views/Dashboard/history.php',\n array(\n 'history' => $history,\n 'personal' => $personal\n )\n );\n }", "function get_history($id)\n\t{\n\t\tglobal $log;\n\t\t$log->debug(\"Entering get_history(\".$id.\") method ...\");\n\t\t$userNameSql = getSqlForNameInDisplayFormat(array('first_name'=>\n\t\t\t\t\t\t\t'vtiger_users.first_name', 'last_name' => 'vtiger_users.last_name'), 'Users');\n\t\t$query = \"SELECT vtiger_activity.activityid, vtiger_activity.subject, vtiger_activity.status\n\t\t\t, vtiger_activity.eventstatus,vtiger_activity.activitytype, vtiger_activity.date_start,\n\t\t\tvtiger_activity.due_date,vtiger_activity.time_start,vtiger_activity.time_end,\n\t\t\tvtiger_contactdetails.contactid, vtiger_contactdetails.firstname,\n\t\t\tvtiger_contactdetails.lastname, vtiger_crmentity.modifiedtime,\n\t\t\tvtiger_crmentity.createdtime, vtiger_crmentity.description,vtiger_crmentity.crmid,\n\t\t\tcase when (vtiger_users.user_name not like '') then $userNameSql else vtiger_groups.groupname end as user_name\n\t\t\t\tfrom vtiger_activity\n\t\t\t\tinner join vtiger_cntactivityrel on vtiger_cntactivityrel.activityid= vtiger_activity.activityid\n\t\t\t\tinner join vtiger_contactdetails on vtiger_contactdetails.contactid= vtiger_cntactivityrel.contactid\n\t\t\t\tinner join vtiger_crmentity on vtiger_crmentity.crmid=vtiger_activity.activityid\n\t\t\t\tleft join vtiger_seactivityrel on vtiger_seactivityrel.activityid=vtiger_activity.activityid\n left join vtiger_groups on vtiger_groups.groupid=vtiger_crmentity.smownerid\n\t\t\t\tleft join vtiger_users on vtiger_users.id=vtiger_crmentity.smownerid\n\t\t\t\twhere (vtiger_activity.activitytype != 'Emails')\n\t\t\t\tand (vtiger_activity.status = 'Completed' or vtiger_activity.status = 'Deferred' or (vtiger_activity.eventstatus = 'Held' and vtiger_activity.eventstatus != ''))\n\t\t\t\tand vtiger_cntactivityrel.contactid=\".$id.\"\n and vtiger_crmentity.deleted = 0\";\n\t\t//Don't add order by, because, for security, one more condition will be added with this query in include/RelatedListView.php\n\t\t$log->debug(\"Entering get_history method ...\");\n\t\treturn getHistory('Contacts',$query,$id);\n\t}", "function searchHistoryScreen($request) {\n\n DEFINE(\"RESULTS_ON_PAGE\", \"5\");\n \n $pageNumber = $request->form->get(\"pageNumber\", \"int\", 1);\n \n if( $pageNumber < 1 ) $pageNumber = 1;\n\n $searchHistory = new SearchLogList($request->config->mysqlConnection);\n $searchHistory->setOrder(\"search_date\");\n $searchHistory->setDirection(\"desc\");\n \n $pageCount = ceil($searchHistory->getCount()/RESULTS_ON_PAGE);\n \n $offset = (($pageNumber-1)*RESULTS_ON_PAGE);\n \n $searchHistory->setLimit($offset.\", \".RESULTS_ON_PAGE);\n \n $searchHistory->load();\n \n Leolos\\Status\\Status::OK();\n require_once \"templ/search_history.html\";\n return ;\n}", "function history() {\n if ($this->getRequestMethod() != \"GET\") {\n $this->response('', 406);\n }\n $id = (int)$this->_request['user_id'];\n $auth = $this->getAuthorization();\n if (!$this->validateAuthorization($id, $auth)) {\n $this->response('', 400);\n }\n\n if ($id > 0) {\n $query = \"select * from videos where id in (select video_id from history where user_id=$id group by video_id order by view_date desc);\"; \n $r = $this->conn->query($query) or die($this->conn->error.__LINE__);\n if($r->num_rows > 0) {\n $result = array();\n while ($row = $r->fetch_assoc()) {\n $result[] = $row;\n } \n $this->response(json_encode($result), 200); \n } else {\n $this->response('',204);\n }\n } else {\n $this->response('', 400);\n }\n }", "function simple_history_print_nav() {\n\n\tglobal $wpdb;\n\t$tableprefix = $wpdb->prefix;\n\t\n\t// fetch all types that are in the log\n\tif (isset($_GET[\"simple_history_type_to_show\"])) {\n\t\t$simple_history_type_to_show = $_GET[\"simple_history_type_to_show\"];\n\t} else {\n\t\t$simple_history_type_to_show = \"\";\n\t}\n\n\t// Get all object types and object subtypes\n\t// order by the number of times they occur\n\t$sql = \"SELECT \n\t\t\t\tcount(object_type) AS object_type_count,\n\t\t\t\tobject_type, object_subtype \n\t\t\tFROM {$tableprefix}simple_history \n\t\t\tGROUP BY object_type, object_subtype\n\t\t\tORDER BY object_type_count DESC, object_type, object_subtype\n\t\t\";\n\t$arr_types = $wpdb->get_results($sql);\n\n\t$css = \"\";\n\tif (empty($simple_history_type_to_show)) {\n\t\t$css = \"class='selected'\";\n\t}\n\n\t// Reload-button\n\t$str_reload_button = sprintf('<a class=\"simple-fields-reload\" title=\"%1$s\" href=\"#\"><span>Reload</span></a>', esc_attr__(\"Reload history\", \"simple-history\"));\n\techo $str_reload_button;\n\n\t// Begin select\n\t$str_types_select = \"\";\n\t$str_types_select .= \"<select name='' class='simple-history-filter simple-history-filter-type'>\";\n\n\t$total_object_num_count = 0;\n\tforeach ( $arr_types as $one_type ) {\n\t\t$total_object_num_count += $one_type->object_type_count;\n\t}\n\n\t// First filter is \"all types\"\n\t$link = esc_html(add_query_arg(\"simple_history_type_to_show\", \"\"));\n\t$str_types_desc = __(\"All types\", 'simple-history');\n\n\t$str_types_select .= sprintf('<option data-simple-history-filter-type=\"\" data-simple-history-filter-subtype=\"\" value=\"%1$s\">%2$s (%3$d)</option>', $link, esc_html($str_types_desc), $total_object_num_count );\n\n\t// Loop through all types\n\t// $one_type->object_type = user | post | attachment | comment | plugin | attachment | post | Reply | Topic | Widget | Wordpress_core\n\t// $one_type->object_subtype = page | nav_menu_item | ...\n\t#sf_d($arr_types);\n\tforeach ($arr_types as $one_type) {\n\n\t\t$css = \"\";\n\t\t$option_selected = \"\";\n\t\tif ($one_type->object_subtype && $simple_history_type_to_show == ($one_type->object_type.\"/\".$one_type->object_subtype)) {\n\t\t\t$css = \"class='selected'\";\n\t\t\t$option_selected = \" selected \";\n\t\t} elseif (!$one_type->object_subtype && $simple_history_type_to_show == $one_type->object_type) {\n\t\t\t$css = \"class='selected'\";\n\t\t\t$option_selected = \" selected \";\n\t\t}\n\n\t\t// Create link to filter this type + subtype\n\t\t$arg = \"\";\n\t\tif ($one_type->object_subtype) {\n\t\t\t$arg = $one_type->object_type.\"/\".$one_type->object_subtype;\n\t\t} else {\n\t\t\t$arg = $one_type->object_type;\n\t\t}\n\t\t$link = esc_html(add_query_arg(\"simple_history_type_to_show\", $arg));\n\n\t\t// Begin option\n\t\t$str_types_select .= sprintf(\n\t\t\t'<option %1$s data-simple-history-filter-type=\"%2$s\" data-simple-history-filter-subtype=\"%3$s\" value=\"%4$s\">',\n\t\t\t$option_selected, // 1\n\t\t\t$one_type->object_type, // 2\n\t\t\t$one_type->object_subtype, // 3\n\t\t\t$link // 4\n\t\t);\n\t\t\n\t\t// Some built in types we translate with built in translation, the others we use simple history for\n\t\t// TODO: use WP-function to get all built in types?\n\t\t$object_type_translated = \"\";\n\t\t$object_subtype_translated = \"\";\n\n\t\t// Get built in post types\n\t\t$arr_built_in_post_types = get_post_types( array(\"_builtin\" => true) );\n\n\t\t$object_type_translated = \"\";\n\t\t$object_subtype_translated = \"\";\n\n\t\t// For built in types\n\t\tif ( in_array( $one_type->object_type, $arr_built_in_post_types ) ) {\n\t\t\t\n\t\t\t// Get name of main type\n\t\t\t$object_post_type_object = get_post_type_object( $one_type->object_type );\n\t\t\t$object_type_translated = $object_post_type_object->labels->name;\n\t\t\t\n\t\t\t// Get name of subtype\n\t\t\t$object_subtype_post_type_object = get_post_type_object( $one_type->object_subtype );\n\t\t\tif ( ! is_null( $object_subtype_post_type_object ) ) {\n\t\t\t\t$object_subtype_translated = $object_subtype_post_type_object->labels->name;;\n\t\t\t}\n\n\t\t}\n\t\t\n\t\tif ( empty( $object_type_translated ) ) {\n\t\t\t$object_type_translated = ucfirst( esc_html__( $one_type->object_type, \"simple-history\") );\n\t\t}\n\n\t\tif ( empty( $object_subtype_translated ) ) {\n\t\t\t$object_subtype_translated = ucfirst( esc_html__( $one_type->object_subtype, \"simple-history\") );\n\t\t}\n\t\t\n\t\t// Add name of type (post / attachment / user / etc.)\n\t\t\n\t\t// built in types use only subtype\n\t\tif ( in_array( $one_type->object_type, $arr_built_in_post_types ) && ! empty($object_subtype_translated) ) {\n\n\t\t\t$str_types_select .= $object_subtype_translated;\n\n\t\t} else {\n\t\t\t\n\t\t\t$str_types_select .= $object_type_translated;\n\n\t\t\t// And subtype, if different from main type\n\t\t\tif ($object_subtype_translated && $object_subtype_translated != $object_type_translated) {\n\t\t\t\t$str_types_select .= \"/\" . $object_subtype_translated;\n\t\t\t}\n\n\t\t}\n\t\t// Add object count\n\t\t$str_types_select .= sprintf(' (%d)', $one_type->object_type_count);\n\t\t\n\t\t// Close option\n\t\t$str_types_select .= \"\\n</option>\";\n\t\t\n\t\t// debug\n\t\t#$str_types .= \" type: \" . $one_type->object_type;\n\t\t#$str_types .= \" type: \" . ucfirst($one_type->object_type);\n\t\t#$str_types .= \" subtype: \" . $one_type->object_subtype. \" \";\n\t\t\n\t} // foreach arr types\n\n\t$str_types_select .= \"\\n</select>\";\n\n\t// Output filters\n\tif ( ! empty( $arr_types ) ) {\n\t\t// echo $str_types;\n\t\techo $str_types_select;\n\t}\n\n\t// fetch all users that are in the log\n\t$sql = \"SELECT DISTINCT user_id FROM {$tableprefix}simple_history WHERE user_id <> 0\";\n\t$arr_users_regular = $wpdb->get_results($sql);\n\tforeach ($arr_users_regular as $one_user) {\n\t\t$arr_users[$one_user->user_id] = array(\"user_id\" => $one_user->user_id);\n\t}\n\t\n\tif ( ! empty( $arr_users ) ) {\n\t\n\t\tforeach ($arr_users as $user_id => $one_user) {\n\t\t\t$user = get_user_by(\"id\", $user_id);\n\t\t\tif ($user) {\n\t\t\t\t$arr_users[$user_id][\"user_login\"] = $user->user_login;\n\t\t\t\t$arr_users[$user_id][\"user_nicename\"] = $user->user_nicename;\n\t\t\t\tif (isset($user->first_name)) {\n\t\t\t\t\t$arr_users[$user_id][\"first_name\"] = $user->first_name;\n\t\t\t\t}\n\t\t\t\tif (isset($user->last_name)) {\n\t\t\t\t\t$arr_users[$user_id][\"last_name\"] = $user->last_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t}\n\n\tif (isset($arr_users) && $arr_users) {\n\n\t\tif (isset($_GET[\"simple_history_user_to_show\"])) {\n\t\t\t$simple_history_user_to_show = $_GET[\"simple_history_user_to_show\"];\n\t\t} else {\n\t\t\t$simple_history_user_to_show = \"\";\n\t\t}\n\n\t\t$str_users_select = \"\";\n\t\t$str_users_select .= \"<select name='' class='simple-history-filter simple-history-filter-user'>\";\n\n\t\t$css = \"\";\n\t\t$option_selected = \"\";\n\t\tif (empty($simple_history_user_to_show)) {\n\t\t\t$css = \" class='selected' \";\n\t\t\t$option_selected = \" selected \";\n\t\t}\n\n\t\t// All users\n\t\t$link = esc_html(add_query_arg(\"simple_history_user_to_show\", \"\"));\n\n\t\t$str_users_select .= sprintf(\n\t\t\t\t'<option data-simple-history-filter-user-id=\"%4$s\" value=\"%3$s\" %2$s>%1s</option>', \n\t\t\t\t__(\"By all users\", 'simple-history'), // 1\n\t\t\t\t$option_selected, // 2\n\t\t\t\t$link, // 3\n\t\t\t\t\"\" // 4\n\t\t\t);\n\n\t\tforeach ($arr_users as $user_id => $user_info) {\n\n\t\t\t$user = new WP_User($user_id);\n\t\t\tif ( ! $user->exists() ) continue;\n\n\t\t\t$link = esc_html(add_query_arg(\"simple_history_user_to_show\", $user_id));\n\t\t\t\n\t\t\t$css = \"\";\n\t\t\t$option_selected = \"\";\n\n\t\t\tif ($user_id == $simple_history_user_to_show) {\n\t\t\t\t$css = \" class='selected' \";\n\t\t\t\t$option_selected = \" selected \";\n\t\t\t}\n\n\t\t\t// all users must have username and email\n\t\t\t$str_user_name = sprintf('%1$s (%2$s)', esc_attr($user->user_login), esc_attr($user->user_email));\n\t\t\t// if ( ! empty( $user_info[\"first_name\"] ) $user_info[\"last_name\"] );\n\t\t\t\n\t\t\t$str_users_select .= sprintf(\n\t\t\t\t'<option data-simple-history-filter-user-id=\"%4$s\" %2$s value=\"%1$s\">%1$s</option>',\n\t\t\t\t$str_user_name, // 1\n\t\t\t\t$option_selected, // 2\n\t\t\t\t$link, // 3\n\t\t\t\t$user_id\n\t\t\t);\n\n\t\t}\n\n\t\t$str_users_select .= \"</select>\";\n\n\t\tif ( ! empty($str_users_select) ) {\n\t\t\techo $str_users_select;\n\t\t}\n\n\t}\n\t\n\t// search\n\t$str_search = __(\"Search\", 'simple-history');\n\t$search = \"<p class='simple-history-filter simple-history-filter-search'>\n\t\t<input type='text' />\n\t\t<input type='button' value='$str_search' class='button' />\n\t</p>\";\n\techo $search;\n\t\n}", "public function GetHistoryInfo()\n\t{\n\t if ($this->m_Stateless == \"Y\")\n\t return;\n\t if (!$this->m_NoHistoryInfo)\n\t {\n\t $histInfo[] = $this->m_RecordId;\n $histInfo[] = $this->m_CurrentPage;\n $histInfo[] = $this->m_SearchRule;\n $histInfo[] = $this->m_SortRule;\n\t return $histInfo;\n\t }\n\t return null;\n\t}", "function show_user_history() {\n if (!$this->session->userdata('logged_in')) {\n redirect('logout');\n }\n\n $id = $this->session->userdata('userid');\n $query = $this->db->get_where('tb_app_prev_info', array('app_id' => $id));\n if ($query->num_rows() == 1) {\n foreach ($query->result() as $ro) {\n $value1 = array(\n 'specializ' => $ro->specialization,\n 'high_edu' => $ro->high_edu_attained,\n 'institut' => $ro->institution,\n 'gradu_year' => $ro->year_of_gradu,\n 'gpa' => $ro->gpa,\n 'other_qualification' => $ro->other_qualification,\n 'dof' => $ro->dof,\n 'dot' => $ro->dot,\n 'responsibility' => $ro->nature_of_work,\n 'employer' => $ro->comp_employed,\n 'release' => $ro->comp_release_agre,\n 'position' => $ro->position\n );\n }\n unset($ro);\n return $value1;\n } else {\n $value1 = array(\n 'specializ' => '',\n 'high_edu' => '',\n 'institut' => '',\n 'gradu_year' => '',\n 'gpa' => '',\n 'other_qualification' => '',\n 'dof' => '',\n 'dot' => '',\n 'responsibility' => '',\n 'employer' => '',\n 'release' => '',\n 'position' => ''\n );\n return $value1;\n }\n }", "function learn_press_single_quiz_history() {\n\t\tlearn_press_get_template( 'content-quiz/history.php' );\n\t}", "public function get_history()\n {\n return view('content.history')\n ->with('pages', History::page_all())\n ->with('pdfs', History::pdf_all());\n }", "function display () {\n\t\t// So that if we're displaying a list of reports that are\n\t\t// available for editing, it's accurate.\n\t\t$this->_update_locked();\n\t\n\t\t$data = $this->_get_data_by_recent ();\n\t\t\n\t\t$this->render($data);\n\t\n\t}", "public function set_display()\n {\n if (isset($_GET['iDisplayStart']) && $_GET['iDisplayLength'] != '-1') {\n $this->sLimit = \"LIMIT \".mysql_real_escape_string($_GET['iDisplayStart']).\", \".\n mysql_real_escape_string($_GET['iDisplayLength']);\n }\n }", "public function show(HistoryCategory $historyCategory)\n {\n //\n }", "function mostrar_historial(){\n\t\tif (isset($_GET['id']) && $_GET['id']!=\"\"){\n\t\t\t$id=$_GET['id'];\n\t\t\t$sql=\"SELECT * FROM historial WHERE id_his='$id'\";\n\t\t\t$consulta=mysql_query($sql);\n\t\t\t$resultado = mysql_fetch_array($consulta);\n\t\t\t$this->tabla = $resultado['tabla_his'];\n\t\t\t$this->pertenece = $resultado['pertenece_his'];\n\t\t\t$this->asunto = $resultado['asunto_his'];\n\t\t\t$this->descripcion = $resultado['descripcion_his'];\n\t\t\t$this->fecha = $resultado['fecha_his'];\n\t\t\t$this->hora = $resultado['hora_his'];\n\t\t\t$this->fechamod= $resultado['fechamod_his'];\n\t\t\t\n\t\t} \n\t}", "public function show(Reporte_Historial $reporte_Historial)\n {\n //\n }", "protected function setDisplayData() {\n parent::setDisplayData();\n $this->template->setDisplayData( \"person_header\", $this->getTitle() );\n if ( !($form_link = $this->form_link)) {\n if ($this->module == 'I2CE') {\n $form_link = $this->page;\n } else {\n $form_link = $this->module .'/' . $this->page;\n }\n }\n $this->template->setDisplayData( \"person_form\", $form_link);\n }", "public function actionHistory()\n {\n /*$auditdata = AuditTrailSearch::find()\n ->select(['entry_id', 'model_id', 'user_id', 'created', 'old_value'])\n ->where([\n 'action' => 'DELETE',\n 'model' => 'backend\\models\\Event',\n ])\n ->andFilterWhere(['>', 'old_value', \"''\"])\n ->orderBy(['model_id' => SORT_DESC])\n ->all();*/\n// $historyData = \\yii\\helpers\\ArrayHelper::map($auditdata, 'model_id', 'old_value');\n// \\yii\\helpers\\VarDumper::dump($historyData);\n\n $searchModel = new AuditTrailSearch;\n $searchFilter = [\n 'AuditTrailSearch' => [\n 'action' => 'DELETE',\n 'model' => 'backend\\models\\Event'\n ]\n ];\n $dataProvider = $searchModel->search(\\yii\\helpers\\ArrayHelper::merge(Yii::$app->request->get(), $searchFilter));\n //var_dump(Yii::$app->request->get());\n //\\yii\\helpers\\VarDumper::dump($searchModel);\n $message = \"<ol>恢复操作指引<li><删除内容>中输入内容筛选</li><li>点击复选框选中需要恢复的记录</li><li>点击<恢复记录>按钮</li></ol>\";\n Yii::$app->session->setFlash('info', $message);\n return $this->render('history', [\n 'dataProvider' => $dataProvider,\n 'searchModel' => $searchModel,\n ]);\n }", "function bookcrossing_view_history($history) {\n $build = node_view($history['node'], 'history');\n global $user;\n $build = bookcrossing_prepare_book_view($build, $history, FALSE);\n\n drupal_set_title(t('Book history') . ' - ' . $history['node']->title);\n /**\n * Adding comment of the logged user to the output.\n */\n $isset = FALSE;\n $my_comment = '<div id=\"my-comment-text\">';\n if (isset($history['comments'][$user->uid])) {\n $my_comment .= $history['comments'][$user->uid];\n $isset = TRUE;\n }\n\n if (!$isset) {\n $query = db_select('bookcrossing_history', 'h');\n //$query->innerJoin('bookcrossing_books', 'b');\n $exist = $query\n ->fields('h', array('bid'))\n ->condition('h.uid', $user->uid, '=')\n ->condition('h.bid', $history['bid'], '=')\n ->execute()\n ->fetchField();\n\n if ($exist) {\n $my_comment .= t('Review wasnt added. You can add it by pressing \"change\" link.');\n }\n else {\n $my_comment .= t('You cant write reviews for book u didnt find.');\n }\n }\n \n $my_comment .= '</div>';\n\n $is_read_book = db_select('bookcrossing_history', 'h')\n ->fields('h', array('bid'))\n ->condition('uid', $user->uid, '=')\n ->condition('bid', $history['bid'], '=')\n ->execute()\n ->fetchField();\n\n $change_link = '';\n if ($is_read_book) {\n $change_link = l(t('(change)'), 'change-comment/' . $history['bid'], array('attributes' => array('class' => array('use-ajax'))));\n }\n $build['book_comment'] = array(\n '#markup' => '<div class=\"back-to-book\">' . l(t('<<back to book'), 'book/' . $history['bid']) . '</div><div class=\"my-comment\"><div class=\"my-comment-title\">' . t('My review') . $change_link . '</div>' . $my_comment . '</div>',\n );\n \n $build['author_and_year'] = array(\n '#markup' => bookcrossing_author_and_year($history),\n );\n\n /**\n * Generate output for history of the book.\n */\n $output = '<div class=\"history-wrapper\">';\n foreach ($history['places'] as $place) {\n $comment = isset($history['comments'][$place['user']->uid]) ? $history['comments'][$place['user']->uid] : '';\n $my_comment_class = $place['user']->uid == $user->uid ? ' m-c' : '';\n $user_link = '';\n $fbid = bookcrossing_load_fbid($place['user']->uid);\n if ($fbid) {\n $vars = array();\n $filepath = (isset($place['user']->picture->uri)) ? $place['user']->picture->uri : '';\n $name = !empty($place['user']->name) ? $place['user']->name : variable_get('anonymous', t('Anonymous'));\n $alt = t(\"@user's picture\", array('@user' => $name));\n $vars = array('path' => $filepath, 'alt' => $alt, 'title' => $alt);\n $vars['style_name'] = 'user-in-history';\n $image = theme('image_style', $vars);\n $user_link = l($image, 'http://www.facebook.com/profile.php?id=' . $fbid . '&sk=app_bookcrossing_by', array('html' => TRUE));\n }\n $output .= '<div class=\"place-wrapper clearfix\">\n <div class=\"history-comment' . $my_comment_class . '\">' . $comment . '</div>\n <div class=\"history-user-foto\">' . $user_link . '</div>\n <div class=\"history-user-info\">'\n . l($place['user']->name, $fbid ? 'http://www.facebook.com/profile.php?id=' . $fbid . '&sk=app_bookcrossing_by' : 'user/' . $place['user']->uid)\n . '<div class=\"history-places\">';\n\n if ($place['place']) {\n $output .= '<div class=\"place-found\">' . t('Found') . ':<div class=\"place-date-found\">' . format_date($place['found']) . ',' . $place['place']->name . '</div></div>';\n }\n\n if ($place['place_left']) {\n $output .= '<div class=\"place-left\">' . t('Released') . ':<div class=\"place-date-left\">' . format_date($place['time_left']) . ', ' . $place['place_left']->name . '</div></div>';\n }\n\n $output .= '</div></div></div>';\n }\n $output .= '</div>';\n\n $build['book_history'] = array(\n '#markup' => $output,\n );\n\n /**\n * Generate item list with status of the book.\n */\n $build['book_status'] = array(\n '#markup' => bookcrossing_book_status($history),\n );\n\n $build['history_pager'] = array(\n '#theme' => 'pager',\n );\n\n return $build;\n}", "public function getHistoryTpl(){\n return $this->templates['history'];\n }", "public function cmn_history()\r\n\t{\r\n $content = $this->input->get(\"content\") ? trim($this->input->get(\"content\", TRUE)) : \"\";\r\n $start = $this->input->get(\"start\") ? trim($this->input->get(\"start\", TRUE)) : \"\";\r\n $end = $this->input->get(\"end\") ? trim($this->input->get(\"end\", TRUE)) : \"\";\r\n $date_arr = \"\";\r\n if (! empty($start) || ! empty($end))\r\n {\r\n $this->load->helper(\"common\");\r\n $date_arr = make_date_start_before_end($start, $end);\r\n }\r\n\r\n\t\t$limit = $this->_get_limit();\r\n\t\t$history = $this->model->get_cmn_history($limit, $content, $date_arr);\r\n\r\n\t\tif ( empty($history))\r\n\t\t\t$this->meret(NULL, MERET_EMPTY);\r\n\t\telse\r\n\t\t\t$this->meret($history);\r\n\t}", "public static function getHTMLForHistory($history, $laptops = false)\n\t{\n\t\tglobal $issueTypes;\n\t\t$output = \"\";\n \n\t\tforeach ($history as $row)\n\t\t{\n $recorded_by = new Student($row['initiated_by']);\n $recorded_by_string = \"\";\n if ( !empty($row['initiated_by']) && $recorded_by )\n $recorded_by_string = \"- Recorded by \".$recorded_by->getProperty(\"name\");\n \n\t\t\tif ( $row['type'] == ACTION_CREATE )\n\t\t\t{\n\t\t\t\t$output .= \"<div class=\\\"alert action-info\\\"><strong>Created</strong><br>\";\n\t\t\t\t$output .= ($laptops?$laptops[$row['laptop']['id']]['assetTag']:\"This computer\").\" was added to the database.<br>\";\n\t\t\t\t$output .= \"<small>Recorded on \".date(\"M d, Y\", $row['timestamp']).\" at \".date(\"g:i A\", $row['timestamp']).\" \".$recorded_by_string.\"</small>\";\n\t\t\t\t$output .= \"</div>\";\n\t\t\t}\n\t\t\telse if ( $row['type'] == ACTION_UNASSIGN )\n\t\t\t{\n\t\t\t\t$output .= \"<div class=\\\"alert\\\"><strong>Returned</strong><br>\";\n\t\t\t\t$output .= ($laptops?$laptops[$row['laptop']['id']]['assetTag']:\"This computer\").\" was returned.<br>\";\n\t\t\t\t$output .= \"<small>Recorded on \".date(\"M d, Y\", $row['timestamp']).\" at \".date(\"g:i A\", $row['timestamp']).\" \".$recorded_by_string.\"</small>\";\n\t\t\t\t$output .= \"</div>\";\n\t\t\t}\n\t\t\telse if ( $row['type'] == ACTION_ASSIGN )\n\t\t\t{\n\t\t\t\t$output .= \"<div class=\\\"alert alert-success\\\"><strong>Assigned</strong><br>\";\n\t\t\t\t$output .= ($laptops?$laptops[$row['laptop']['id']]['assetTag']:\"This computer\").\" was assigned to <a href=\\\"../students/student.php?sid=\".$row['student'].\"\\\">\".$row['student'].\"</a><br>\";\n\t\t\t\t$output .= \"<small>Recorded on \".date(\"M d, Y\", $row['timestamp']).\" at \".date(\"g:i A\", $row['timestamp']).\" \".$recorded_by_string.\"</small>\";\n\t\t\t\t$output .= \"</div>\";\n\t\t\t}\n\t\t\telse if ( $row['type'] == HISTORYEVENT_SERVICE )\n\t\t\t{\n\t\t\t\t$output .= \"<div class=\\\"alert alert-info\\\"><strong>Service - \".$issueTypes[$row['subtype']].\"</strong><br>\";\n\t\t\t\t$output .= stripcslashes(nl_fix($row['body'])).\"<br>\";\n\t\t\t\t$output .= \"<small>Recorded on \".date(\"M d, Y\", $row['timestamp']).\" at \".date(\"g:i A\", $row['timestamp']).\" \".$recorded_by_string.\"</small>\";\n\t\t\t\t$output .= \"</div>\";\n\t\t\t}\n\t\t}\n\t\treturn $output;\n\t}", "public function getHistory()\r\r\n {\r\r\n return $this->history;\r\r\n }", "function getHistory() {\n\t\treturn db_query_params ('SELECT * FROM artifact_history_user_vw WHERE artifact_id=$1 ORDER BY entrydate DESC, id ASC',\n\t\t\t\t\tarray ($this->getID())) ;\n\t}", "public function initHistorys()\n\t{\n\t\t$this->collHistorys = array();\n\t}", "function FacilityHistory(&$user, $config, $dbh, $debug = 0)\n {\n #print(\"config - $config<br>\\n\");\n $this->FacilityHistoryBase($user, $config, $dbh, $debug);\n }", "function display_list(){\n\t\t\t$this->load->model('admin_career_event_model');\n\t\t\t$this->gen_contents['modal_path'] \t= '/career_event/class_details';\n\t\t\t$this->gen_contents['current_date']\t= $_POST['datecurrent'];\n \n $chp_list = $this->config->item('chapter_list');\n\t\t\t$this->gen_contents['arr_list'] \t= $this->admin_career_event_model->dbGetEventListWithSearchUser($_POST,$chp_list);\n\t\t\t$this->load->view('user/career_event/display_list_event',$this->gen_contents);\n\t\t}", "private static function showHistoryPage(SR_Player $player, $page)\n\t{\n// \t\t$bot = Shadowrap::instance($player);\n\t\t\n\t\tif (false === ($clan = SR_Clan::getByPlayer($player)))\n\t\t{\n\t\t\treturn self::rply($player, '1019');\n// \t\t\t$bot->reply('You don\\'t belong to a clan yet.');\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t$ipp = 5;\n\t\t$table = GDO::table('SR_ClanHistory');\n\t\t$where = 'sr4ch_cid='.$clan->getID();\n\t\t$nItems = $table->countRows($where);\n\t\t$nPages = GWF_PageMenu::getPagecount($ipp, $nItems);\n\t\tif ($page > $nPages)\n\t\t{\n\t\t\treturn self::rply($player, '1009');\n// \t\t\t$bot->reply('This page is empty.');\n\t\t\treturn false;\n\t\t}\n\t\t$from = GWF_PageMenu::getFrom($page, $ipp);\n\t\tif (false === ($result = $table->selectAll('sr4ch_time,sr4ch_pname,sr4ch_action,sr4ch_iname,sr4ch_amt', $where, 'sr4ch_time DESC', NULL, $ipp, $from, GDO::ARRAY_N)))\n\t\t{\n\t\t\t$player->message('DB ERROR');\n// \t\t\t$bot->reply('DB ERROR');\n\t\t\treturn false;\n\t\t}\n\n\t\t$b = 0;\n\t\t$out = array();\n\t\tforeach ($result as $row)\n\t\t{\n\t\t\t$b = 1 - $b;\n\t\t\t$b2 = $b === 0 ? '' : \"\\X02\";\n\t\t\t$out[] = $b2.SR_ClanHistory::getHistMessage($player, $row[0], $row[1], $row[2], $row[3], $row[4]).$b2;\n\t\t}\n\t\t\n\t\treturn self::rply($player, '5041', array($page, $nPages, implode(' ', $out)));\n// \t\t$message = sprintf('ClanHistory page %d/%d: %s', $page, $nPages, implode(' ', $out));\n// \t\treturn $bot->reply($message);\n\t}", "public function getHistoryFields()\n {\n $owner = $this->owner;\n if (!$owner->isLatestVersion()) {\n return null;\n }\n\n $config = GridFieldConfig_RecordViewer::create()\n ->removeComponentsByType([\n GridFieldToolbarHeader::class,\n GridFieldSortableHeader::class,\n GridFieldPaginator::class,\n GridFieldPageCount::class,\n GridFieldViewButton::class\n ])\n ->addComponent(new GridFieldTitleHeader)\n ->addComponent(new GridFieldHistoryButton);\n $config->getComponentByType(GridFieldDetailForm::class)\n ->setItemRequestClass(HistoryGridFieldItemRequest::class);\n $config->getComponentByType(GridFieldDataColumns::class)\n ->setDisplayFields([\n 'Version' => '#',\n 'LastEdited.Nice' => _t(__CLASS__ . '.WHEN', 'When'),\n 'Title' => _t(__CLASS__ . '.TITLE', 'Title'),\n 'Author.Name' => _t(__CLASS__ . '.AUTHOR', 'Author')\n ]);\n\n return FieldList::create(\n GridField::create(\n 'History',\n '',\n Versioned::get_all_versions(\n $owner->ClassName,\n $owner->ID\n )\n ->sort('Version', 'DESC'),\n $config\n )\n ->addExtraClass('grid-field--history')\n );\n }", "function get_history() {\n\t\treturn $this->history;\n\t}", "public function actionHistory($id)\n\t\t{\n\t\t\t\t$model = $this->findModel($id);\n\n\t\t\t\t$query = new Query();\n\t\t\t\t$orderHistory = new ActiveDataProvider([\n\t\t\t\t\t\t'query' => OrderHistory::find()->where([\n\t\t\t\t\t\t\t\t'order_id' => $model->order_id,\n\t\t\t\t\t\t\t\t// 'attribute' => 'order_status_id'\n\t\t\t\t\t\t]),\n\t\t\t\t\t\t'sort' => [\n\t\t\t\t\t\t\t\t'defaultOrder' => [\n\t\t\t\t\t\t\t\t\t\t// 'attribute' => SORT_ASC,\n\t\t\t\t\t\t\t\t\t\t'create_time' => SORT_ASC\n\t\t\t\t\t\t\t\t]\n\t\t\t\t\t\t],\n\t\t\t\t\t\t'pagination' => [\n\t\t\t\t\t\t\t\t'pageSize' => 20,\n\t\t\t\t\t\t],\n\t\t\t\t]);\n\n\t\t\t\treturn $this->render('history', [\n\t\t\t\t\t\t'model' => $model,\n\t\t\t\t\t\t'orderHistory' => $orderHistory,\n\t\t\t\t\t\t'subData' => $this->subData\n\t\t\t\t]);\n\t\t}", "public function getHistoryAdmin() {\r\n if (Session::has('adminSession')) {\r\n $objadmin = Session::get('adminSession');\r\n //var_dump($objadmin);\r\n $id = $objadmin[0]->id;\r\n //echo $id;\r\n $tblAdminModel = new tblAdminModel();\r\n $data = $tblAdminModel->selectHistoryAdmin($id, 5);\r\n //echo $data[0]->historyContent;\r\n //var_dump($data);\r\n $link = $data->links();\r\n return View::make('backend.admin.adminHistory')->with('arrHistory', $data)->with('link', $link);\r\n } else {\r\n return View::make('fontend.404')->with('thongbao', 'Ko co lich su');\r\n }\r\n }", "public function showHistory()\n {\n return view('customer.purchase-history', ['cart_items' => Cart::where('user_id', auth()->user()->id)->where('checkout_id', '!=', null)->simplePaginate(10)]);\n }", "public function display(){\n\t\t$item_name = $this->pdh->get('item', 'name', array($this->url_id));\n\n\t\tif ( empty($item_name) ){\n\t\t\tmessage_die($this->user->lang('error_invalid_item_provided'));\n\t\t}\n\n\t\t#search for the gameid\n\t\t$game_id = $this->pdh->get('item', 'game_itemid', array($this->url_id));\n\n\t\t//Sort\n\t\t$sort\t\t\t= $this->in->get('sort');\n\n\t\t$item_ids = array();\n\t\tif ($game_id > 1){\n\t\t\t$item_ids = $this->pdh->get('item', 'ids_by_ingameid', array($game_id));\n\t\t}else{\n\t\t\t$item_ids = $this->pdh->get('item', 'ids_by_name', array($item_name));\n\t\t}\n\t\t$counter = sizeof($item_ids);\n\n\t\t//default now col\n\t\t$colspan = ($this->config->get('infotooltip_use')) ? 1 : 0 ;\n\n\t\t#Itemhistory Diagram\n\t\tif ($this->config->get('pk_itemhistory_dia')){\n\t\t\t$colspan++;\n\t\t}\n\n\t\t//Comments\n\t\t$comm_settings = array('attach_id'=>md5(stripslashes($item_name)), 'page'=>'items');\n\t\t$this->comments->SetVars($comm_settings);\n\t\t$COMMENT = ($this->config->get('pk_enable_comments') == 1) ? $this->comments->Show() : '';\n\n\t\t//init infotooltip\n\t\tinfotooltip_js();\n\n\t\t$hptt_page_settings\t\t= $this->pdh->get_page_settings('viewitem', 'hptt_viewitem_buyerslist');\n\t\t$hptt\t\t\t\t\t= $this->get_hptt($hptt_page_settings, $item_ids, $item_ids, array('%raid_link_url%' => 'viewraid.php', '%raid_link_url_suffix%' => ''), $this->url_id);\n\n\t\t//linechart data\n\t\tif($this->config->get('pk_itemhistory_dia')) {\n\t\t\t$a_items = array();\n\t\t\tforeach($item_ids as $item_id) {\n\t\t\t\t$a_items[] = array('name' => $this->time->date(\"Y-m-d H:i:s\", $this->pdh->get('item', 'date', array($item_id))), 'value' => $this->pdh->get('item', 'value', array($item_id)));\n\t\t\t}\n\t\t}\n\t\t$this->tpl->assign_vars(array(\n\t\t\t'ITEM_STATS'\t\t\t\t=> $this->pdh->get('item', 'itt_itemname', array($this->url_id, 0, 1)),\n\t\t\t'ITEM_CHART'\t\t\t\t=> ($this->config->get('pk_itemhistory_dia') && count($a_items) > 1) ? $this->jquery->LineChart('item_chart', $a_items, '', 200, 500, '', false, true, 'date') : '',\n\t\t\t'ITEM_MODEL'\t\t\t\t=> (isset($model3d)) ? $model3d : false,\n\t\t\t'COMMENT'\t\t\t\t\t=> $COMMENT,\n\n\t\t\t'SHOW_ITEMSTATS'\t\t\t=> ($this->config->get('infotooltip_use')) ? true : false,\n\t\t\t'SHOW_ITEMHISTORYA'\t\t\t=> ($this->config->get('pk_itemhistory_dia') == 1 ) ? true : false,\n\t\t\t'SHOW_COLSPAN'\t\t\t\t=> $colspan,\n\t\t\t'BUYERS_TABLE'\t\t\t\t=> $hptt->get_html_table($sort, '&amp;i='.$this->url_id, 0, 100, sprintf($this->user->lang('viewitem_footcount'), $counter)),\n\t\t\t'L_PURCHASE_HISTORY_FOR'\t=> sprintf($this->user->lang('purchase_history_for'), stripslashes($item_name)),\n\t\t));\n\n\t\t$this->core->set_vars(array(\n\t\t\t'page_title'\t\t=> sprintf($this->user->lang('viewitem_title'), stripslashes($item_name)),\n\t\t\t'template_file'\t\t=> 'viewitem.html',\n\t\t\t'display'\t\t\t=> true)\n\t\t);\n\t}", "public function setEmployeeHistory()\n {\n \ttry {\n \n $this->employeeHistory->setEmployeeHistory($this->request->ipaddress, $this->request->url, $this->request->date);\n\n return json_encode(['status' => true, 'message' => 'Added a new Employee visited URL']);\n } catch(Exception $e) {\n // dd($e);\n return json_encode(['status' => false, 'message' => $e->getMessage()]);\n }\n }", "public function index()\n {\n $history = App\\Models\\history::latest()->first();\n return view('admin.history.view',compact('history'));\n }", "public function populateHistory()\n {\n $resultHistory = DB::select('select * from calculations order by created_at desc limit 10');\n return view('calculator', ['resultHistory' => $resultHistory]);\n }", "public function get_user_history(){\n \t$s = \"SELECT * FROM user_history WHERE username = ? group by ETF order by Date ASC\";\n \tif($stmt = $this->connection->prepare($s)){\n \t\t$stmt->bind_param(\"s\", $_SESSION['username']);\n \t\t$stmt->execute();\n \t\t$res = $stmt->get_result();\n \t\twhile($row = $res->fetch_object()){\n \t\t\t$history[] = $row;\n \t\t}\n \t\treturn $history;\n \t}\n \t \t\n }", "public function fetchHistory(): array;", "public function actionHistory()\n {\n $id = Yii::app()->request->getQuery('id');\n $model = Order::model()->findByPk($id);\n\n if (!$model)\n $this->error404(Yii::t('CartModule.admin', 'ORDER_NOT_FOUND'));\n if ($model->is_deleted)\n throw new CHttpException(404, Yii::t('CartModule.admin', 'ORDER_ISDELETED'));\n $this->render('_history', array(\n 'model' => $model\n ));\n }", "function list_history_lab()\r\n {\r\n $data['offline_mode']\t\t=\t$this->config->item('offline_mode');\r\n $data['debug_mode']\t\t =\t$this->config->item('debug_mode');\r\n\t\t$data['patient_id'] = $this->uri->segment(3);\r\n $data['patient_info'] = $this->memr_rdb->get_patient_details($data['patient_id']);\r\n $data['patient_info']['name'] = $data['patient_info']['patient_name'];\r\n \t\t$data['title'] = \"PR-\".$data['patient_info']['name'];\r\n $data['tests_list'] = $this->memr_rdb->get_recent_lab($data['patient_id']);\r\n\t\t$this->load->vars($data);\r\n\t\tif ($_SESSION['thirra_mode'] == \"ehr_mobile\"){\r\n $new_header = \"ehr/header_xhtml-mobile10\";\r\n $new_banner = \"ehr/banner_ehr_ovrvw_wap\";\r\n $new_sidebar= \"ehr/sidebar_ehr_patients_ovrvw_wap\";\r\n //$new_body = \"ehr/ehr_indv_list_history_vitals_wap\";\r\n $new_body = \"ehr/ehr_indv_list_history_lab_html\";\r\n $new_footer = \"ehr/footer_emr_wap\";\r\n\t\t} else {\r\n //$new_header = \"ehr/header_xhtml1-strict\";\r\n $new_header = \"ehr/header_xhtml1-transitional\";\r\n $new_banner = \"ehr/banner_ehr_ovrvw_html\";\r\n $new_sidebar= \"ehr/sidebar_ehr_patients_ovrvw_html\";\r\n $new_body = \"ehr/ehr_indv_list_history_lab_html\";\r\n $new_footer = \"ehr/footer_emr_html\";\r\n\t\t}\r\n\t\t$this->load->view($new_header);\t\t\t\r\n\t\t$this->load->view($new_banner);\t\t\t\r\n\t\t$this->load->view($new_sidebar);\t\t\t\r\n\t\t$this->load->view($new_body);\t\t\t\r\n\t\t$this->load->view($new_footer);\t\t\r\n\t\t\r\n }", "public function personHistoryView(){\n $this->view('auditor/personHistoryView');\n \n $this->view->render(); // This is how load the view\n }", "public function show(HistoricalCriterion $historicalCriterion)\n {\n //\n }", "public function getHistory()\n {\n return Wrapper\\Player\\Senior::history($this->getId());\n }", "public function payment_history() {\n\t\t$this->page_data['page_name'] = \"payment_history\";\n\t\t$this->page_data['page_title'] = 'Payment history';\n\t\t$this->page_data['page_view'] = 'user/payment_history';\n\n\t\t$this->page_data['payment_info_list'] = $this->crud_model->get_payment_info_list(\"OBJECT\", $this->session->userdata('user_id'), \"APPROVED\");\n\n// Retrieve enrollment history along with few course data\n\t\t$this->page_data['course_list'] = $this->crud_model->get_enrollment_info_by_user_id(\"OBJECT\", $this->session->userdata('user_id'), array(\n\t\t\t\"enrollment\" => array('id as enroll_id', 'enrolled_price'),\n\t\t\t\"course\" => array('id', 'title'),\n\t\t), null, null, \"SUM\");\n\n\t\tfor ($i = 0; $i < count($this->page_data['course_list']); $i++) {\n\t\t\t$this->page_data['course_list'][$i]->percentage_to_pay = -1;\n\t\t}\n\n\t\t$this->load->view('index', $this->page_data);\n\n\t}", "public function officerHistoryView(){\n $this->view('auditor/officerHistoryView');\n \n $this->view->render(); // This is how load the view\n }", "public function display(){}", "public function setHistory($var)\n {\n GPBUtil::checkMessage($var, \\Temporal\\Api\\History\\V1\\History::class);\n $this->history = $var;\n\n return $this;\n }", "function getHistory()\n\t{\n\t\tif (intval($this->id)==0) {\n\t\t\treturn null;\n\t\t}\n\n\t\t// $db = Zend_Registry::get('db');\n\t\t// $sql = sprintf('select * from object_history where link_to=%d and link_id=%d order by cts desc',$ot,$id);\n\t\t// $rs = $db->fetch_all($sql);\n\t\t// return $rs;\n\n\t\t$s = 'select id,auth_user_id,ctime,link,f,v0,v1 from base_diff ';\n\t\t$s.= sprintf(' where link = \\'%s\\' ',$this->link() );\n\t\t// $s.= ' order by ctime ';\n\t\t$s.= ' union all ';\n\t\t$s.= 'select id,auth_user_id,cts,link,\\'-None-\\',message,null from object_history ';\n\t\t$s.= sprintf(' where link = \\'%s\\' ',$this->link() );\n\t\t$s.= ' order by ctime desc ';\n\n\t\t// $s = $d->select();\n\t\t// $s->from('object_history');\n\t\t// $s->where('link = ?', $this->link() );\n\t\t// $s->order('cts');\n\t\t$r = SQL::fetch_all($s);\n\t\treturn $r;\n\t}", "public function CleanHistoryInfo()\n\t{\n\t $this->m_RecordId = null;\n $this->m_CurrentPage = 1;\n $this->m_SearchRule = null;\n $this->m_SortRule = null;\n $this->m_NoHistoryInfo = true;\n\t}", "public function alterDisplay(&$rows) {\n\n $entryFound = FALSE;\n //NYSS\n $display_flag = $prev_cid = $cid = 0;\n //CRM_Core_Error::debug($rows);\n foreach ($rows as $rowNum => $row) {\n //NYSS 3504 don't repeat contact details if its same as the previous row\n $rows[$rowNum]['hideTouched' ] = 0;\n if ( $this->_outputMode != 'csv' ) {\n if ( array_key_exists('civicrm_contact_touched_id', $row ) && !empty($row['civicrm_contact_touched_id']) ) {\n if ( $cid = $row['civicrm_contact_touched_id'] ) {\n if ( $rowNum == 0 ) {\n $prev_cid = $cid;\n }\n else {\n if( $prev_cid == $cid ) {\n $display_flag = 1;\n $prev_cid = $cid;\n }\n else {\n $display_flag = 0;\n $prev_cid = $cid;\n }\n }\n \n if ( $display_flag ) {\n $rows[$rowNum]['hideTouched' ] = 1;\n }\n }\n }\n }\n \n // convert display name to links\n if (array_key_exists('civicrm_contact_sort_name', $row) &&\n array_key_exists('civicrm_contact_id', $row)\n ) {\n $url = CRM_Utils_System::url('civicrm/contact/view',\n 'reset=1&cid=' . $row['civicrm_contact_id'],\n $this->_absoluteUrl\n );\n $rows[$rowNum]['civicrm_contact_sort_name_link'] = $url;\n $rows[$rowNum]['civicrm_contact_sort_name_hover'] = ts(\"View Contact details for this contact.\");\n $entryFound = TRUE;\n }\n \n //NYSS strip out the activity targets (could be multiple)\n if (array_key_exists('civicrm_activity_activity_type_id', $row) &&\n $row['civicrm_activity_activity_type_id'] != '' &&\n strpos( $row['civicrm_log_data'], 'target=' ) ) {\n // source, target, assignee are concatenated; we need to strip out the target\n $loc_target = strrpos( $row['civicrm_log_data'], 'target=' );\n $loc_assign = strrpos( $row['civicrm_log_data'], ', assignee=' );\n $str_target = substr( $row['civicrm_log_data'], $loc_target + 7, $loc_assign - $loc_target - 7 );\n //CRM_Core_Error::debug('lc', $loc_target);\n //CRM_Core_Error::debug('la', $loc_assign);\n //CRM_Core_Error::debug('st', $str_target);\n \n $targets = explode( ',', $str_target );\n //CRM_Core_Error::debug('at', $targets);\n \n // build links\n $atlist = array();\n foreach ( $targets as $target ) {\n $turl = CRM_Utils_System::url( 'civicrm/contact/view', 'reset=1&cid='.$target, $this->_absoluteUrl );\n $tc_params = array(\n 'version' => 3,\n 'id' => $target\n );\n $tc_contacts = civicrm_api('contact', 'getsingle', $tc_params);\n $atlist[] = '<a href=\"'.$turl.'\">'.$tc_contacts['display_name'].'</a>';\n }\n $stlist = implode( ', ', $atlist );\n //CRM_Core_Error::debug('stlist', $stlist);\n $rows[$rowNum]['civicrm_activity_targets_list'] = $stlist;\n \n }\n\n if (array_key_exists('civicrm_contact_touched_sort_name_touched', $row) &&\n array_key_exists('civicrm_contact_touched_id', $row) &&\n $row['civicrm_contact_touched_sort_name_touched'] !== ''\n ) {\n \n //NYSS add details about touched contact via API\n //Gender, DOB, ALL District Information.\n if ($row['civicrm_contact_touched_id']) {\n //get address, phone, email\n require_once 'api/api.php';\n \n $cid = $row['civicrm_contact_touched_id'];\n $params = array(\n 'version' => 3,\n 'id' => $cid,\n );\n $contact = civicrm_api('contact', 'getsingle', $params);\n //CRM_Core_Error::debug_var('$contact',$contact);\n\n $rows[$rowNum]['civicrm_contact_touched_phone'] =\n ( !empty($contact['phone']) ) ? '<li>'.$contact['phone'].'</li>' : '';\n\n $rows[$rowNum]['civicrm_contact_touched_email'] =\n ( !empty($contact['email']) ) ? '<li>'.$contact['email'].'</li>' : '';\n\n //setup address\n $addr = '';\n if ( !empty($contact['street_address']) ) {\n $addr = $contact['street_address'].'<br />';\n }\n if ( !empty($contact['city']) ) {\n $addr .= $contact['city'].', ';\n }\n if ( !empty($contact['state_province']) || !empty($contact['postal_code']) ) {\n $addr .= $contact['state_province'].' '.$contact['postal_code'];\n }\n if ( !empty($addr) ) {\n $rows[$rowNum]['civicrm_contact_touched_address'] = '<li>'.$addr.'</li>';\n }\n\n //setup demographics\n $diDemo = '';\n if ( $contact['gender'] ) $diDemo .= '<li>Gender: '.$contact['gender'].'</li>';\n if ( $contact['birth_date'] ) $diDemo .= '<li>Birthday: '.$contact['birth_date'].'</li>';\n $rows[$rowNum]['civicrm_contact_touched_demographics'] = $diDemo;\n }\n //NYSS end\n \n $url = CRM_Utils_System::url(\n 'civicrm/contact/view',\n 'reset=1&cid='.$row['civicrm_contact_touched_id'],\n $this->_absoluteUrl );\n $rows[$rowNum]['civicrm_contact_touched_display_name_touched_link' ] = $url;\n $rows[$rowNum]['civicrm_contact_touched_display_name_touched_hover'] =\n ts(\"View Contact details for this contact.\");\n $entryFound = true;\n }\n\n if (array_key_exists('civicrm_activity_subject', $row) &&\n array_key_exists('civicrm_activity_id', $row) &&\n $row['civicrm_activity_subject'] !== ''\n ) {\n $url = CRM_Utils_System::url('civicrm/contact/view/activity',\n 'reset=1&action=view&id=' . $row['civicrm_activity_id'] . '&cid=' .\n $row['civicrm_activity_source_contact_id'] . '&atype=' .\n $row['civicrm_activity_activity_type_id'],\n $this->_absoluteUrl\n );\n $rows[$rowNum]['civicrm_activity_subject_link'] = $url;\n $rows[$rowNum]['civicrm_activity_subject_hover'] = ts(\"View Contact details for this contact.\");\n $entryFound = TRUE;\n }\n\n if (array_key_exists('civicrm_activity_activity_type_id', $row)) {\n if ($value = $row['civicrm_activity_activity_type_id']) {\n $rows[$rowNum]['civicrm_activity_activity_type_id'] = $this->activityTypes[$value];\n }\n $entryFound = TRUE;\n }\n\n // skip looking further in rows, if first row itself doesn't\n // have the column we need\n if (!$entryFound) {\n break;\n }\n }\n }", "public function testHistoryPageDisplayed()\n {\n $user = factory(User::class)->make();\n\n $response = $this->actingAs($user)->get('/history');\n $response->assertStatus(200);\n\n $this->assertAuthenticatedAs($user);\n }", "public function ToString() {\n $limit = 7;\n \n // Have to call Result() to actually get the data proper\n $UserModel = new UserModel();\n $RecentlyActiveUsers = $UserModel->GetActiveUsers($limit)->Result();\n echo '<div id=\"RecentlyActive\" class=\"Box RecentlyActiveBox\">';\n echo '<ul class=\"PanelInfo PanelRecentlyActive\">';\n echo '<h4>';\n echo T('Recently Active Users');\n echo '</h4>';\n \n // Loop through the array of user objects\n foreach ($RecentlyActiveUsers as $User) {\n echo '<li><strong>';\n echo UserAnchor($User, 'UserLink'); // use the useranchor function to print a link to the profile with the name as the anchor text. The 'UserLink' is the css class to use for the a tag\n echo '</strong>';\n echo Gdn_Format::Seconds($User->DateLastActive); // the Seconds() method formats seconds in a human-readable way (ie. 45 seconds, 15 minutes, 2 hours, 4 days, 2 months, etc).\n echo '</li>';\n }\n echo '</ul></div>';\n }", "public function getStatusHistory()\n\t\t{\n\t\t\t$list = ECash::getFactory()->getModel(\"StatusHistoryList\");\n\t\t\t$list->loadBy(array(\"application_id\" => $this->application_id));\n\n\t\t\treturn $list->toList();\n\t\t}", "function historiqueResultatShow($cnx, $ref_dossier)\n{\n\t$RESULTAT = tab_resultats() ;\n\t$RESULTAT_IMG_CLASS = tab_resultats_img_class() ;\n\n\t$req = \"SELECT * FROM resultat_hist WHERE ref_dossier=\".$ref_dossier.\"\n\t\tORDER BY id_resultat_hist\" ;\n\t$res = mysqli_query($cnx, $req) ;\n\n\t$tab = \"\" ;\n\n\tif ( mysqli_num_rows($res) == 0 ) {\n\t\treturn $tab ;\n\t}\n\n\t$tab .= \"<div class='historique'><div>\" ;\n\n\t$tab .= \"<table class='petit' style='margin: 0'>\\n\" ;\n\t$tab .= \"<caption>Historique du résultat</caption>\\n\" ;\n\twhile ( $enr = mysqli_fetch_assoc($res) )\n\t{\n\t\t$tab .= \"<tr>\\n\" ;\n\t\t$tab .= \"<td>\".mysql2date($enr[\"date_resultat_hist\"]).\"</td>\\n\" ;\n\t\t$tab .= \"<td><span class='\".$RESULTAT_IMG_CLASS[$enr[\"resultat_hist\"]].\"'>\"\n\t\t\t. $RESULTAT[$enr[\"resultat_hist\"]]\n\t\t\t. \"</span></td>\\n\" ;\n\t\t$tab .= \"<td>\".$enr[\"resultat_par\"].\"</td>\\n\" ;\n\t\t$tab .= \"</tr>\\n\" ;\n\t}\n\t$tab .= \"</table>\\n\" ;\n\t$tab .= \"</div></div>\\n\" ;\n\treturn $tab ;\n}", "function list_history_social()\r\n {\r\n $data['offline_mode']\t\t=\t$this->config->item('offline_mode');\r\n $data['debug_mode']\t\t =\t$this->config->item('debug_mode');\r\n\t\t$data['patient_id'] = $this->uri->segment(3);\r\n $data['patient_info'] = $this->memr_rdb->get_patient_details($data['patient_id']);\r\n $data['patient_info']['name'] = $data['patient_info']['patient_name'];\r\n \t\t$data['title'] = \"PR-\".$data['patient_info']['name'];\r\n\t\t$data['history_list'] = $this->memr_rdb->get_history_social('List',$data['patient_id']);\r\n\t\t$this->load->vars($data);\r\n\t\tif ($_SESSION['thirra_mode'] == \"ehr_mobile\"){\r\n $new_header = \"ehr/header_xhtml-mobile10\";\r\n $new_banner = \"ehr/banner_ehr_ovrvw_wap\";\r\n $new_sidebar= \"ehr/sidebar_ehr_patients_ovrvw_wap\";\r\n $new_body = \"ehr/ehr_indv_list_history_social_html\";\r\n $new_footer = \"ehr/footer_emr_wap\";\r\n\t\t} else {\r\n //$new_header = \"ehr/header_xhtml1-strict\";\r\n $new_header = \"ehr/header_xhtml1-transitional\";\r\n $new_banner = \"ehr/banner_ehr_ovrvw_html\";\r\n $new_sidebar= \"ehr/sidebar_ehr_patients_ovrvw_html\";\r\n $new_body = \"ehr/ehr_indv_list_history_social_html\";\r\n $new_footer = \"ehr/footer_emr_html\";\r\n\t\t}\r\n\t\t$this->load->view($new_header);\t\t\t\r\n\t\t$this->load->view($new_banner);\t\t\t\r\n\t\t$this->load->view($new_sidebar);\t\t\t\r\n\t\t$this->load->view($new_body);\t\t\t\r\n\t\t$this->load->view($new_footer);\t\t\r\n\t\t\r\n }", "function listar_historial(){\n\t\tif (isset($_POST['buscar']))\n\t\t\t$_SESSION['buscar']=$_POST['buscar'];\n\t\t\n\t\t$sql=\"SELECT * FROM historial ORDER BY id_his\";\n\t\t\n\t\t$consulta=mysql_query($sql);\n\t\twhile ($resultado = mysql_fetch_array($consulta)){\n\t\t\t$this->mensaje=\"si\";\n\t\t\t$this->listado[] = $resultado;\n\t\t}\n\t}", "public function update_user_history() {\n\n\t\t// Grab user history from the current session\n\t\t$history = $this->get_user_history();\n\n\t\t// Add the current page to the user's history\n\t\t$protocol = ( isset( $_SERVER[\"HTTPS\"] ) && $_SERVER[\"HTTPS\"] == \"on\") ? \"https://\" : \"http://\";\n\t\t$page_url = $protocol . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];\n\t\t$history[] = array( 'url' => $page_url, 'time' => time() );\n\n\t\t// Push the updated history to the current session\n\t\tit_exchange_update_session_data( 'user_history', $history );\n\n\t}", "public function index()\n {\n $userId = auth()->user()->id;\n $donations = Histories::where('user_id','=',$userId)->where('activity_id','=',Lookup::DONATE)->get();\n $takes = Histories::where('user_id','=',$userId)->where('activity_id','=',Lookup::REQUEST)->get();\n\n return view('users.history',compact('donations','takes'));\n\n }", "public function index()\n {\n $historys = History::with('getApiKeys')\n ->with('getWorkflow')\n ->with('getStateFrom')\n ->with('getStateTo')\n ->with('getUserName')\n ->paginate(10);\n $now = Carbon::now();\n $dates = [];\n foreach($historys as $history)\n {\n $end = Carbon::parse($history->created_at);\n array_push($dates,$end->diffForHumans($now));\n }\n return view('workflow.history.index',compact('historys', 'dates'));\n }", "public function smsHistory()\n {\n return view('client.sms-history');\n }", "function payment_history()\n {\n $data['fetch_category'] = $this->Admin_model->category();\n $data['fetch_sub_category'] = $this->Admin_model->sub_category();\n $data['accepted_projects'] = $this->Admin_model->accepted_projects();\n\n $data['fetch_tags'] = $this->Admin_model->fetch_tags();\n $data['basic_info'] = $this->Admin_model->basic_info();\n\n //...........for view page.................//\n $data['payment_history'] = $this->Admin_model->payment_history();\n\n $this->load->view('include/header', $data);\n $this->load->view('payment_history', $data);\n $this->load->view('include/footer', $data);\n }", "public function actionHistory($id)\n {\n $searchModel = new ModelHistorySearch;\n\n $queryParams= Yii::$app->request->getQueryParams();\n $queryParams['ModelHistorySearch']['user_id'] = $id;\n $dataProvider = $searchModel->search($queryParams);\n\n return $this->render('model-history', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "function exam_history_list() {\n \n global $user;\n \n ExamInstance::storeMessage('Just before call to table sorter', 'exam_history_list');\n ExamInstance::addJQueryTablesorter();\n ExamInstance::storeMessage('Just after call to table sorter', 'exam_history_list');\n \n // This variable contains the number of columns\n // in the history list table. This is required\n // to support the colspan option in the first row\n // when there are no exams in the history yet.\n $vNumberOfColumns = '9';\n \n $vContent = '';\n \n // Note the unusual manner in which we calculate numberUnanswered.\n // The reason is to make sure we count the number unanswered for \n // both finished exams, which is stored in the question_instance\n // table, and unfinished exams, which is not stored in question_instance.\n $result = db_query(\n 'SELECT ei.exam_instance_id\n , ei.exam_id\n , ei.type\n , ei.exam_title\n , ei.grade\n , ei.graded\n , ei.totalQuestions\n , ei.numberCorrect\n , ei.numberWrong\n , (SELECT (COUNT(*)-COUNT(qi.selected_answer_number))\n FROM question_instance AS qi\n WHERE qi.exam_instance_id = ei.exam_instance_id) numberUnanswered\n , from_unixtime(ei.created) date_completed\n FROM exam_instance AS ei\n WHERE ei.user_id = :uid\n AND ei.showInHistory = 1 \n ORDER BY ei.created DESC',\n array(':uid' => $user->uid)\n ); \n \n $vContent = \"<hr/>\";\n \n $vContent .= '<table id=\"theTable\" class=\"tablesorter\" cellspacing=\"1\">'; // id and class required for tablesorter function\n \n $vContent .= '<thead>';\n $vContent .= '<tr>';\n $vContent .= '<th width=160>Exam title</th>';\n $vContent .= '<th>Grade</th>';\n $vContent .= '<th>Status</th>';\n $vContent .= '<th>Questions</th>';\n $vContent .= '<th>Correct</th>';\n $vContent .= '<th>Incorrect</th>';\n $vContent .= '<th>Unanswered</th>';\n $vContent .= '<th width=40>Started</th>';\n $vContent .= '<th>Delete</th>';\n $vContent .= '</tr>';\n $vContent .= '</thead>';\n \n $vContent .= '<tbody>';\n \n if ($result->rowCount() == 0) {\n $vContent .= '<tr><td colspan=' \n . $vNumberOfColumns \n . ' align=center>You have not yet completed any exams.<br>'\n . l('Click here to see a list of available exams.','exam/list')\n . '</td></tr>';\n }\n \n $vImageInfoIcon = array(\n 'path' => 'sites/all/modules/exam/images/icons/InfoMid.jpg'\n , 'alt' => 'Information about the exam'\n , 'title' => ''\n , 'attributes' => array('border' => '0')\n );\n $vImageContinueIcon = array(\n 'path' => 'sites/all/modules/exam/images/icons/ContinueMid.jpg'\n , 'alt' => 'Continue with the exam'\n , 'title' => '' \n , 'attributes' => array('border' => '0')\n );\n $vImageDeleteIcon = array(\n 'path' => 'sites/all/modules/exam/images/icons/DeleteIconMid.jpg'\n , 'alt' => 'Delete the exam'\n , 'title' => '' \n , 'attributes' => array('border' => '0')\n );\n \n foreach ($result as $row){ \n $vContent .= '<tr>';\n $vContent .= '<td class=exam_icon>' . $row->exam_title . '</td>';\n $vContent .= '<td class=exam_icon>' . $row->grade . '</td>'; \n $vContent .= '<td class=exam_icon>';\n if (!is_null($row->grade)) {\n $vContent .= '<a href=?q=exam/record/' . $row->exam_instance_id \n . ' alt=\"See details\">' . theme('image', $vImageInfoIcon) . '</a></td>';\n } else {\n $vContent .= '<a href=?q=exam/continue/' \n . ExamInstance::getExamTitleForURL($row->exam_title) \n . '/'. $row->exam_instance_id \n . ' alt=\"Continue taking exam\">'\n . theme('image', $vImageContinueIcon) . '</a></td>';\n }\n $vContent .= '<td class=exam_icon>' . $row->totalQuestions . '</td>';\n $vContent .= '<td class=exam_icon>' . $row->numberCorrect . '</td>';\n $vContent .= '<td class=exam_icon>' . $row->numberWrong . '</td>';\n $vContent .= '<td class=exam_icon>' . $row->numberUnanswered . '</td>';\n $vContent .= '<td class=exam_icon>' . $row->date_completed . '</td>';\n //$vContent .= '<td class=exam_icon>' . l('X','exam/history/removeOne/' . $row->exam_instance_id) . '</td>';\n $vContent .= '<td class=exam_icon>' . '<a href=?q=exam/history/removeOne/' . $row->exam_instance_id . ' alt=\"Delete the exam from your history\">' . theme('image', $vImageDeleteIcon) . '</a></td>';\n //$vContent .= '<td class=exam_icon>' . '<a class=tooltip href=exam/history/removeOne/' . $row->exam_instance_id . '><img src=sites/all/modules/exam/images/icons/DeleteIconMid.jpg border=0>' . '<span class=\"custom warning\"><img src=images/icons/Warning.jpg height=48 width=48/><em>Warning</em>This action will delete your exam from your history.</span>' . '</a>' . '</td>';\n $vContent .= '</tr>'; \n }\n \n $vContent .= '</tbody>';\n $vContent .= '</table>';\n \n return t($vContent);\n\n}", "public function actionDisplay() {\r\n global $mainframe, $user; \r\n $tourID = Request::getVar('tourID',0);\r\n $model = Tournament::getInstance();\r\n $tour_detail = $model->getItem($tourID);\r\n $lists = $model->getLists($tourID, $tour_detail); \r\n \r\n $this->addBarTitle(\"Tournament: <small>$tour_detail->name</small>\", \"tournaments\"); \r\n $this->addIconToolbar(\"Apply\", Router::buildLink(\"gamesport\", array(\"view\"=>\"tournament\", \"layout\" => \"save\",\"tourID\"=>$tourID)), \"apply\");\r\n addSubMenuGameSportTour('tournament');\r\n \r\n $this->render('teamjoined', array('tour_detail'=> $tour_detail,'lists' => $lists));\r\n }", "public function show()\n {\n return view('history');\n }", "function edithistory_info()\n{\n\treturn array(\n\t\t\"name\"\t\t\t\t=> \"Edit History Log\",\n\t\t\"description\"\t\t=> \"Allows you to log all edits made to posts.\",\n\t\t\"website\"\t\t\t=> \"http://galaxiesrealm.com/index.php\",\n\t\t\"author\"\t\t\t=> \"Starpaul20\",\n\t\t\"authorsite\"\t\t=> \"http://galaxiesrealm.com/index.php\",\n\t\t\"version\"\t\t\t=> \"1.2.2\",\n\t\t\"guid\"\t\t\t\t=> \"b8223bbc5a67bc02ea405bcc4101a56c\",\n\t\t\"compatibility\"\t\t=> \"16*\"\n\t);\n}", "static function getHistoryEntry($data) {\n\n switch ($data['linked_action'] - Log::HISTORY_PLUGIN) {\n case 0:\n return __('History from plugin example', 'example');\n }\n\n return '';\n }", "function site_statistics_history(&$args)\n{\n global $database;\n \n $statistics =& $args['statistics'];\n \n // NOTE: CACHING WILL BE HANDLED BY THE FUNCTION THAT CALLS THIS\n \n $total = $database->database_fetch_assoc($database->database_query(\"SELECT COUNT(historyentry_id) AS total FROM se_historyentries\"));\n $statistics['history'] = array(\n 'title' => 1500150,\n 'stat' => (int) ( isset($total['total']) ? $total['total'] : 0 )\n );\n \n /*\n $total = $database->database_fetch_assoc($database->database_query(\"SELECT COUNT(historysubscription_id) AS total FROM se_historysubscriptions\"));\n $statistics['historysubscriptions'] = array(\n 'title' => 1500151,\n 'stat' => (int) ( isset($total['total']) ? $total['total'] : 0 )\n );\n */\n}", "public function getHistory()\n {\n return $this->history;\n }", "function healthybackhabits()\n {\n $variables = array();\n\n $userdetails = $this->userInfo();\n $currentday = $this->getPaitentCurrentDay($this->userInfo('user_id'));\n \n $sql = \"SELECT \n patient_reminder_id,\n creation_date,\n status,\n AES_DECRYPT(UNHEX(reminder), '{$this->config['private_key']}') as reminder,\n scheduler_status,\n reminder_set\n FROM \n patient_reminder \n WHERE \n patient_id = '{$userdetails['user_id']}' and assignday='{$currentday}' ORDER BY patient_reminder_id DESC\";\n \n $reminders = $this->fetch_all_rows($this->execute_query($sql));\n\n foreach($reminders as $reminder)\n {\n $variables['reminders'] .= \"<li style=\\\"padding-left:12px\\\"><span class=\\\"desc\\\">\" . $reminder['reminder'] . \"</span> </li>\";\n }\n\n $this->output = $this->build_template($this->get_template('healthybackhabits'), $variables);\n }", "public function paymentHistory()\n {\n // if user is not logged in let him logged in or register\n if( ! Session::isLoggedIn() )\n {\n SCMUtility::frontRedirectTo('?page=scmCourseModule&state=Front&action=myAccount');\n return;\n }\n\n // get user's payment history\n $userPayments = Payment::OfStudent(Session::getCurrentUserID())->get();\n\n View::make('templates/front/payment-history.php',compact('userPayments'));\n }" ]
[ "0.66208935", "0.6466929", "0.6424235", "0.6414146", "0.6334227", "0.632705", "0.63133687", "0.6247761", "0.61642486", "0.6122847", "0.61162496", "0.6106598", "0.6073928", "0.6055157", "0.5997709", "0.59951407", "0.59410864", "0.5932784", "0.5884896", "0.5867076", "0.5835536", "0.581567", "0.5804803", "0.5768218", "0.5751375", "0.5735674", "0.57278365", "0.5704824", "0.56678116", "0.56655663", "0.56593233", "0.56323355", "0.56167364", "0.56064814", "0.560302", "0.55718774", "0.5550875", "0.55411917", "0.55058753", "0.5492039", "0.54776174", "0.546993", "0.54654413", "0.54646635", "0.546044", "0.5455721", "0.5442331", "0.54345775", "0.54341775", "0.54335237", "0.54125684", "0.54108423", "0.5406346", "0.53840786", "0.53787535", "0.53758806", "0.53726643", "0.5366514", "0.53618896", "0.53592736", "0.5357208", "0.5356623", "0.5351649", "0.53450423", "0.5332484", "0.53314537", "0.53299934", "0.53278166", "0.5325173", "0.5323918", "0.5316816", "0.5314701", "0.530729", "0.5304334", "0.5284801", "0.5284376", "0.52717626", "0.5260228", "0.52596784", "0.52549756", "0.52483755", "0.5246814", "0.52393997", "0.52368534", "0.5232147", "0.5224532", "0.5222463", "0.52202356", "0.5219327", "0.5218906", "0.52174705", "0.52155286", "0.5208036", "0.52050596", "0.5197419", "0.51946867", "0.51938957", "0.5191657", "0.51908314", "0.5188626" ]
0.7041204
0
InviteHistoryHandler::populateHiddenFormFields() To set the hidden form field values
public function populateHiddenFormFields($form_fields = array()) { $hiddenFormFields = array(); if (is_array($form_fields) and $form_fields) { $inc = 0; while($field = array_shift($form_fields)) { if (isset($this->fields_arr[$field])) { $hiddenFormFields[$inc]['field_name'] = $field; $hiddenFormFields[$inc]['field_value'] = $this->fields_arr[$field]; $inc++; } } return $hiddenFormFields; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function transactionFormGetHiddenFields ();", "function form_init_elements()\r\n {\r\n $this->add_hidden_element(\"swimmeetid\") ;\r\n\r\n // This is used to remember the action\r\n // which originated from the GUIDataList.\r\n \r\n $this->add_hidden_element(\"_action\") ;\r\n }", "public function populateForm() {}", "function prepare() {\n $this->addChild(new fapitng_FormHidden('form_build_id', array(\n 'value' => $this->build_id,\n )));\n $this->addChild(new fapitng_FormHidden('form_id', array(\n 'value' => $this->id,\n )));\n if ($this->token) {\n $this->addChild(new fapitng_FormHidden('form_token', array(\n 'value' => $this->token,\n )));\n }\n }", "function wyz_ajax_custom_business_fields_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\n\tupdate_option( 'wyz_business_custom_form_data', $form_data );\n\trequire_once( WYZI_PLUGIN_DIR . 'templates-and-shortcodes/business-filters/init-business-filters.php' );\n\twp_die();\n}", "public function setDispFields()\n {\n $backendUser = $this->getBackendUser();\n // Getting from session:\n $dispFields = $backendUser->getModuleData('list/displayFields');\n // If fields has been inputted, then set those as the value and push it to session variable:\n if (is_array($this->displayFields)) {\n reset($this->displayFields);\n $tKey = key($this->displayFields);\n $dispFields[$tKey] = $this->displayFields[$tKey];\n $backendUser->pushModuleData('list/displayFields', $dispFields);\n }\n // Setting result:\n $this->setFields = $dispFields;\n }", "function set_hidden_fields_arrays($posted_data = false) {\r\r\n\r\r\n if (!$posted_data) {\r\r\n $posted_data = WPCF7_Submission::get_instance()->get_posted_data();\r\r\n }\r\r\n\r\r\n $hidden_fields = json_decode(stripslashes($posted_data['_wpcf7cf_hidden_group_fields']));\r\r\n if (is_array($hidden_fields) && count($hidden_fields) > 0) {\r\r\n foreach ($hidden_fields as $field) {\r\r\n $this->hidden_fields[] = $field;\r\r\n if (wpcf7cf_endswith($field, '[]')) {\r\r\n $this->hidden_fields[] = substr($field,0,strlen($field)-2);\r\r\n }\r\r\n }\r\r\n }\r\r\n $this->hidden_groups = json_decode(stripslashes($posted_data['_wpcf7cf_hidden_groups']));\r\r\n $this->visible_groups = json_decode(stripslashes($posted_data['_wpcf7cf_visible_groups']));\r\r\n }", "function wyz_ajax_business_tabs_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_business_tabs_order_data', $form_data );\n\twp_die();\n}", "protected function addSecuredHiddenFieldsRenderedToViewHelperVariableContainer() {}", "function wyz_ajax_business_form_builder_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_business_form_builder_data', $form_data );\n\twp_die();\n}", "function dumpFormItems()\r\n {\r\n if($this->_onclick != null)\r\n {\r\n $hiddenwrapperfield = $this->readJSWrapperHiddenFieldName();\r\n echo \"<input type=\\\"hidden\\\" id=\\\"$hiddenwrapperfield\\\" name=\\\"$hiddenwrapperfield\\\" value=\\\"\\\" />\";\r\n }\r\n }", "function dumpFormItems()\r\n {\r\n if($this->_onclick != null)\r\n {\r\n $hiddenwrapperfield = $this->readJSWrapperHiddenFieldName();\r\n echo \"<input type=\\\"hidden\\\" id=\\\"$hiddenwrapperfield\\\" name=\\\"$hiddenwrapperfield\\\" value=\\\"\\\" />\";\r\n }\r\n }", "function wyz_ajax_registration_form_builder_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_registration_form_data', $form_data );\n\twp_die();\n}", "private function getHiddenInputFields()\r\n {\r\n $inputArray = array();\r\n $inputNodes = $this->scraper->xPathQuery(\"//form[@id='mainform']/div/input\");\r\n foreach ($inputNodes as $node) {\r\n $name = $node->getAttribute('name');\r\n $inputArray[$name] = $node->getAttribute('value');\r\n }\r\n\r\n return $inputArray;\r\n }", "public function GetFormPostedValues() {\n\t\t$req_fields=array(\"description\",\"date_open\",\"date_closed\");\n\n\t\tfor ($i=0;$i<count($req_fields);$i++) {\n\n\t\t\t//echo $_POST['application_id'];\n\t\t\tif (ISSET($_POST[$req_fields[$i]]) && !EMPTY($_POST[$req_fields[$i]])) {\n\t\t\t\t$this->SetVariable($req_fields[$i],EscapeData($_POST[$req_fields[$i]]));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t//echo \"<br>\".$this->req_fields[$i].\"<br>\";\n\t\t\t\t$this->$req_fields[$i]=\"\";\n\t\t\t}\n\t\t}\n\t}", "protected function renderHiddenReferrerFields() {}", "abstract public function get_gateway_form_fields();", "function cf7mls_validation_callback() {\r\r\n $this->set_hidden_fields_arrays($_POST);\r\r\n }", "public function afterFetch()\n {\n foreach ($this->formfields as $field) {\n $this->fields[$field->fieldKey] = $field->fieldName;\n }\n }", "protected function _readFormFields() {}", "public function testFormAllRequiredDataFieldsHidden() {\n $form = new RedirectForm();\n $form_state = [];\n $payment = $this->mockPayment([\n 'firstname' => 'First',\n 'lastname' => 'Last',\n 'address1' => 'Address1',\n 'city' => 'City',\n 'postcode' => 'TEST',\n 'country' => 'GB',\n ]);\n $element = $form->form([], $form_state, $payment);\n foreach (element_children($element['personal_data']) as $key) {\n $e = $element['personal_data'][$key];\n $this->assertFalse($e['#access'], \"Field $key should be hidden (#access = FALSE).\");\n }\n }", "function hidden_field($object, $field, $options = array()) {\n $form = new FormHelper($object, $field);\n return $form->to_input_field_tag(\"hidden\", $options);\n}", "function form_init_elements()\r\n {\r\n $this->add_hidden_element(\"swimmeetid\") ;\r\n\r\n // This is used to remember the action\r\n // which originated from the GUIDataList.\r\n \r\n $this->add_hidden_element(\"_action\") ;\r\n\r\n\t\t// Org Code field\r\n\r\n $orgcode = new FEListBox(\"Organization\", true, \"150px\");\r\n $orgcode->set_list_data(SDIFCodeTableMappings::GetOrgCodes()) ;\r\n $this->add_element($orgcode) ;\r\n\r\n\t\t// Meet Name field\r\n\r\n $meetname = new FEText(\"Meet Name\", true, \"300px\");\r\n $this->add_element($meetname) ;\r\n\r\n\t\t// Meet Address 1 field\r\n\r\n $meetaddress1 = new FEText(\"Meet Address 1\", false, \"300px\");\r\n $this->add_element($meetaddress1) ;\r\n\r\n\t\t// Meet Address 2 field\r\n\r\n $meetaddress2 = new FEText(\"Meet Address 2\", false, \"300px\");\r\n $this->add_element($meetaddress2) ;\r\n\r\n // Meet State\r\n\r\n $meetstate = new FEUnitedStates(\"Meet State\", FT_US_ONLY, \"150px\");\r\n $this->add_element($meetstate) ;\r\n\r\n\t\t// Meet Postal Code field\r\n\r\n $meetpostalcode = new FEText(\"Meet Postal Code\", false, \"200px\");\r\n $this->add_element($meetpostalcode) ;\r\n\r\n // Meet Country\r\n\r\n $meetcountry = new FEListBox(\"Meet Country\", true, \"250px\");\r\n $meetcountry->set_list_data(SDIFCodeTableMappings::GetCountryCodes()) ;\r\n $meetcountry->set_readonly(FT_US_ONLY) ;\r\n $this->add_element($meetcountry) ;\r\n\r\n\t\t// Meet Code field\r\n\r\n $meetcode = new FEListBox(\"Meet Code\", true, \"150px\");\r\n $meetcode->set_list_data(SDIFCodeTableMappings::GetMeetCodes()) ;\r\n $this->add_element($meetcode) ;\r\n\r\n // Meet Start Field\r\n\r\n $meetstart = new FEDate(\"Meet Start\", true, null, null,\r\n \"Fdy\", date(\"Y\") - 3, date(\"Y\") + 7) ;\r\n $this->add_element($meetstart) ;\r\n\r\n // Meet End Field\r\n\r\n $meetend = new FEDate(\"Meet End\", true, null, null,\r\n \"Fdy\", date(\"Y\") - 3, date(\"Y\") + 7) ;\r\n $this->add_element($meetend) ;\r\n\r\n\t\t// Pool Altitude field\r\n\r\n $poolaltitude = new FENumber(\"Pool Altitude\", true, \"150px\") ;\r\n $this->add_element($poolaltitude) ;\r\n\r\n\t\t// Course Code field\r\n\r\n $coursecode = new FEListBox(\"Course Code\", true, \"150px\");\r\n $coursecode->set_list_data(SDIFCodeTableMappings::GetCourseCodes()) ;\r\n $this->add_element($coursecode) ;\r\n }", "public static function convert_hidden_field() {\n\n\t\t// Create a new Hidden field.\n\t\tself::$field = new GF_Field_Hidden();\n\n\t\t// Add standard properties.\n\t\tself::add_standard_properties();\n\n\t}", "function give_checkout_hidden_fields( $form_id ) {\n\n\t/**\n\t * Fires while rendering hidden checkout fields, before the fields.\n\t *\n\t * @param int $form_id The form ID.\n\t *\n\t * @since 1.0\n\t *\n\t */\n\tdo_action( 'give_hidden_fields_before', $form_id );\n\n\tif ( is_user_logged_in() ) {\n\t\t?>\n\t\t<input type=\"hidden\" name=\"give-user-id\" value=\"<?php echo get_current_user_id(); ?>\"/>\n\t<?php } ?>\n\t<input type=\"hidden\" name=\"give_action\" value=\"purchase\"/>\n\t<input type=\"hidden\" name=\"give-gateway\" value=\"<?php echo give_get_chosen_gateway( $form_id ); ?>\"/>\n\t<?php\n\t/**\n\t * Fires while rendering hidden checkout fields, after the fields.\n\t *\n\t * @param int $form_id The form ID.\n\t *\n\t * @since 1.0\n\t *\n\t */\n\tdo_action( 'give_hidden_fields_after', $form_id );\n\n}", "private function _set_fields()\n {\n @$this->form_data->survey_id = 0;\n $this->form_data->survey_title = '';\n $this->form_data->survey_description = '';\n $this->form_data->survey_status = 'open';\n $this->form_data->survey_anms = 'yes';\n $this->form_data->survey_expiry_date = '';\n $this->form_data->question_ids = array();\n\n $this->form_data->filter_survey_title = '';\n $this->form_data->filter_status = '';\n }", "function wyz_ajax_claim_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\n\tupdate_option( 'wyz_claim_registration_form_data', $form_data );\n\twp_die();\n}", "protected function _prepareForm()\r\n {\r\n $form = new Varien_Data_Form(array(\r\n 'id' => 'edit_form',\r\n 'action' => $this->getUrl('*/*/save', array('id' => $this->getRequest()->getParam('id'))),\r\n 'method' => 'post',\r\n 'enctype' => 'multipart/form-data',\r\n )\r\n );\r\n\r\n $fieldSet = $form->addFieldset('magento_form', array('legend' => $this->helper->__('Webhook information')));\r\n\r\n $fieldSet->addField('code', 'select', array(\r\n 'label' => $this->helper->__('Code'),\r\n 'class' => 'required-entry',\r\n 'name' => 'code',\r\n 'values' => ApiExtension_Magento_Block_Adminhtml_Webhooks_Grid::getAvailableHooks()\r\n ));\r\n\r\n $fieldSet->addField('url', 'text', array(\r\n 'label' => $this->helper->__('Callback URL'),\r\n 'class' => 'required-entry',\r\n 'name' => 'url',\r\n ));\r\n\r\n $fieldSet->addField('description', 'textarea', array(\r\n 'label' => $this->helper->__('Description'),\r\n 'name' => 'description',\r\n ));\r\n\r\n $fieldSet->addField('data', 'textarea', array(\r\n 'label' => $this->helper->__('Data'),\r\n 'name' => 'data',\r\n ));\r\n\r\n $fieldSet->addField('token', 'text', array(\r\n 'label' => $this->helper->__('Token'),\r\n 'name' => 'token',\r\n ));\r\n\r\n $fieldSet->addField('active', 'select', array(\r\n 'label' => $this->helper->__('Active'),\r\n 'values' => ApiExtension_Magento_Block_Adminhtml_Webhooks_Grid::getOptionsForActive(),\r\n 'name' => 'active',\r\n ));\r\n\r\n if ($this->session->getWebhooksData()) {\r\n $form->setValues($this->session->getWebhooksData());\r\n $this->session->setWebhooksData(null);\r\n } elseif (Mage::registry('webhooks_data')) {\r\n $form->setValues(Mage::registry('webhooks_data')->getData());\r\n }\r\n\r\n $form->setUseContainer(true);\r\n $this->setForm($form);\r\n return parent::_prepareForm();\r\n }", "protected function removeSecuredHiddenFieldsRenderedFromViewHelperVariableContainer() {}", "function block_editor_meta_box_hidden_fields()\n {\n }", "public function set_fields() {\n $this->fields = apply_filters('wpucommentmetas_fields', $this->fields);\n foreach ($this->fields as $id => $field) {\n if (!is_array($field)) {\n $this->fields[$id] = array();\n }\n if (!isset($field['label'])) {\n $this->fields[$id]['label'] = ucfirst($id);\n }\n if (!isset($field['admin_label'])) {\n $this->fields[$id]['admin_label'] = $this->fields[$id]['label'];\n }\n if (!isset($field['type'])) {\n $this->fields[$id]['type'] = 'text';\n }\n if (!isset($field['help'])) {\n $this->fields[$id]['help'] = '';\n }\n if (!isset($field['required'])) {\n $this->fields[$id]['required'] = false;\n }\n if (!isset($field['admin_visible'])) {\n $this->fields[$id]['admin_visible'] = true;\n }\n if (!isset($field['admin_column'])) {\n $this->fields[$id]['admin_column'] = false;\n }\n if (!isset($field['admin_list_visible'])) {\n $this->fields[$id]['admin_list_visible'] = false;\n }\n if (!isset($field['display_hooks'])) {\n $this->fields[$id]['display_hooks'] = array(\n 'comment_form_logged_in_after',\n 'comment_form_after_fields'\n );\n }\n if (!is_array($this->fields[$id]['display_hooks'])) {\n $this->fields[$id]['display_hooks'] = array($this->fields[$id]['display_hooks']);\n }\n }\n }", "protected function createFormFields() {\n\t}", "public function MetadataEntryForm()\n {\n // NIWA are worried about parameter case and would like it case insensitive so convert all get vars to lower\n // I think this is because they are not 100% what case the parameters from oracle will be in.\n $params = array_change_key_case($this->getRequest()->getVars(), CASE_LOWER);\n\n // Check in the parameters sent to this page if there are certian fields needed to power the\n // functionality which emails project coordinators and if so get them as we will need to add\n // them to the bottom of the form as hidden fields, this way we can access them in the form\n // processing and send the email.\n $hiddenFields = array();\n\n // These 2 fields can be populated either by Project_Coordinator or Project_Administrator as Oracle actually\n // sends Project_Administrator. NIWA want to keep the field here called coordinator.\n if (!empty($params['project_coordinator'])) {\n $hiddenFields['_Project_Coordinator'] = $params['project_coordinator'];\n } else if (!empty($params['project_administrator'])) {\n $hiddenFields['_Project_Coordinator'] = $params['project_administrator'];\n }\n\n if (!empty($params['project_coordinator_email'])) {\n $hiddenFields['_Project_Coordinator_email'] = $params['project_coordinator_email'];\n } else if (!empty($params['project_administrator_email'])) {\n $hiddenFields['_Project_Coordinator_email'] = $params['project_administrator_email'];\n }\n\n if (!empty($params['project_manager'])) {\n $hiddenFields['_Project_Manager'] = $params['project_manager'];\n }\n\n if (!empty($params['project_code'])) {\n $hiddenFields['_Project_Code'] = $params['project_code'];\n }\n\n // Get the fields defined for this page, exclude the placeholder fields as they are not displayed to the user.\n $metadataFields = $this->Fields()->where(\"FieldType != 'PLACEHOLDER'\")->Sort('SortOrder', 'asc');\n\n // Create fieldfield for the form fields.\n $formFields = FieldList::create();\n $actions = FieldList::create();\n $requiredFields = array();\n\n // Push the required fields message as a literal field at the top.\n $formFields->push(\n LiteralField::create('required', '<p>* Required fields</p>')\n );\n\n if ($metadataFields->count()) {\n foreach($metadataFields as $field) {\n // Create a version of the label with spaces replaced with underscores as that is how\n // any paraemters in the URL will come (plus we can use it for the field name)\n $fieldName = str_replace(' ', '_', $field->Label);\n $fieldLabel = $field->Label;\n\n // If the field is required then add it to the required fields and also add an\n // asterix to the end of the field label.\n if ($field->Required) {\n $requiredFields[] = $fieldName;\n $fieldLabel .= ' *';\n }\n\n // Check if there is a parameter in the GET vars with the corresponding name.\n $fieldValue = null;\n\n if (isset($params[strtolower($fieldName)])) {\n $fieldValue = $params[strtolower($fieldName)];\n }\n\n // Define a var for the new field, means no matter the type created\n // later on in the code we can apply common things like the value.\n $newField = null;\n\n // Single line text field creation.\n if ($field->FieldType == 'TEXTBOX') {\n $formFields->push($newField = TextField::create($fieldName, $fieldLabel));\n } else if ($field->FieldType == 'TEXTAREA') {\n $formFields->push($newField = TextareaField::create($fieldName, $fieldLabel));\n } else if ($field->FieldType == 'KEYWORDS') {\n // If keywords then output 2 fields the textbox for the keywords and then also a\n // literal read only list of those already specified by the admin below.\n $formFields->push($newField = TextAreaField::create($fieldName, $fieldLabel));\n $formFields->push(LiteralField::create(\n $fieldName . '_adminKeywords',\n \"<div class='control-group' style='margin-top: -12px'>Already specified : \" . $field->KeywordsValue . \"</div>\"\n ));\n } else if ($field->FieldType == 'DROPDOWN') {\n // Some dropdowns have an 'other' option so must add the 'other' to the entries\n // and also have a conditionally displayed text field for when other is chosen.\n $entries = $field->DropdownEntries()->sort('SortOrder', 'Asc')->map('Key', 'Label');\n\n if ($field->DropdownOtherOption == true) {\n $entries->push('other', 'Other');\n }\n\n $formFields->push(\n $newField = DropdownField::create(\n $fieldName,\n $fieldLabel,\n $entries\n )->setEmptyString('Select')\n );\n\n if ($field->DropdownOtherOption == true) {\n $formFields->push(\n TextField::create(\n \"${fieldName}_other\",\n \"Please specify the 'other'\"\n )->hideUnless($fieldName)->isEqualTo(\"other\")->end()\n );\n\n //++ @TODO\n // Ideally if the dropdown is required then if other is selected the other field\n // should also be required. Unfortunatley the conditional validation logic of ZEN\n // does not work in the front end - so need to figure out how to do this.\n }\n }\n\n // If a new field was created then set some things on it which are common no matter the type.\n if ($newField) {\n // Set help text for the field if defined.\n if (!empty($field->HelpText)) {\n $newField->setRightTitle($field->HelpText);\n }\n\n // Field must only be made readonly if the admin specified that they should be\n // provided that a value was specified in the URL for it.\n if ($field->Readonly && $fieldValue) {\n $newField->setReadonly(true);\n }\n\n // Set the value of the field one was plucked from the URL params.\n if ($fieldValue) {\n $newField->setValue($fieldValue);\n }\n }\n }\n\n // Add fields to the bottom of the form for the user to include a message in the email sent to curators\n // this is entirely optional and will not be used in most cases so is hidden until a checkbox is ticked.\n $formFields->push(\n CheckboxField::create('AdditionalMessage', 'Include a message from me to the curators')\n );\n\n // For the email address, because its project managers filling out the form, check if the Project_Manager_email\n // has been specified in the URL params and if so pre-populate the field with that value.\n $formFields->push(\n $emailField = EmailField::create('AdditionalMessageEmail', 'My email address')\n ->setRightTitle('Please enter your email address so the curator knows who the message below is from.')\n ->hideUnless('AdditionalMessage')->isChecked()->end()\n );\n\n if (isset($params['project_manager_email'])) {\n $emailField->setValue($params['project_manager_email']);\n }\n\n $formFields->push(\n TextareaField::create('AdditionalMessageText', 'My message')\n ->setRightTitle('You can enter a message here which is appended to the email sent the curator after the record has successfully been pushed to the catalogue.')\n ->hideUnless('AdditionalMessage')->isChecked()->end()\n );\n\n // If there are any hidden fields then loop though and add them as hidden fields to the bottom of the form.\n if ($hiddenFields) {\n foreach($hiddenFields as $key => $val) {\n $formFields->push(\n HiddenField::create($key, '', $val)\n );\n }\n }\n\n // We have at least one field so set the action for the form to submit the entry to the catalogue.\n $actions = FieldList::create(FormAction::create('sendMetadataForm', 'Send'));\n } else {\n $formFields->push(\n ErrorMessage::create('No metadata entry fields have been specified for this page.')\n );\n }\n\n // Set up the required fields validation.\n $validator = ZenValidator::create();\n $validator->addRequiredFields($requiredFields);\n\n // Create form.\n $form = Form::create($this, 'MetadataEntryForm', $formFields, $actions, $validator);\n\n // Check if the data for the form has been saved in the session, if so then populate\n // the form with this data, if not then just return the default form.\n $data = Session::get(\"FormData.{$form->getName()}.data\");\n\n return $data ? $form->loadDataFrom($data) : $form;\n }", "function fill_in_additional_list_fields()\r\n\t{\r\n\t}", "function acf_get_hidden_input($attrs = array())\n{\n}", "public function add_edit_form_fields() {\r\n\r\n\t\t?>\r\n\r\n\t\t<input type=\"hidden\" name=\"yz_edit_activity_nonce\" value=\"<?php echo wp_create_nonce( 'youzer-edit-activity' ); ?>\">\r\n\r\n\t\t<?php\r\n\r\n\t}", "public function addHiddenField($name,$value) {\n $this->formLines[] = '<input type=\"hidden\" name=\"'.$name.'\" value=\"'.$value.'\">';\n }", "function bab_pm_makeform()\n{\n global $prefs;\n\n $bab_hidden_input = '';\n $event = gps('event');\n $step = gps('step');\n\n if (!$event) {\n $event = 'postmaster';\n }\n\n if (!$step) {\n $step = 'subscribers';\n }\n\n if ($step == 'subscribers') {\n $bab_columns = array(\n 'subscriberFirstName',\n 'subscriberLastName',\n 'subscriberEmail',\n 'subscriberLists',\n );\n\n for ($i = 1; $i <= BAB_CUSTOM_FIELD_COUNT; $i++) {\n $bab_columns[] = \"subscriberCustom{$i}\";\n }\n\n $bab_submit_value = 'Add Subscriber';\n $bab_prefix = 'new';\n $subscriberToEdit = gps('subscriber');\n\n if ($subscriberToEdit) {\n $bab_hidden_input = '<input type=\"hidden\" name=\"editSubscriberId\" value=\"' . doSpecial($subscriberToEdit) . '\">';\n $bab_prefix = 'edit';\n $bab_submit_value = 'Update Subscriber Information';\n\n $row = safe_row('*', 'bab_pm_subscribers', \"subscriberID=\" . doSlash($subscriberToEdit));\n $subscriber_lists = safe_rows('*', 'bab_pm_subscribers_list', \"subscriber_id = \" . doSlash($row['subscriberID']));\n $fname = doSpecial($row['subscriberFirstName']);\n $lname = doSpecial($row['subscriberLastName']);\n echo \"<fieldset id=bab_pm_edit><legend><span class=bab_pm_underhed>Editing Subscriber: $fname $lname</span></legend>\";\n } else {\n $subscriber_lists = array();\n }\n\n $lists = safe_rows('*', 'bab_pm_list_prefs', '1=1 order by listName');\n }\n\n if ($step == 'lists') {\n $bab_columns = array('listName', 'listAdminEmail','listDescription','listUnsubscribeUrl','listEmailForm','listSubjectLine');\n $bab_submit_value = 'Add List';\n $bab_prefix = 'new';\n\n if ($listToEdit = gps('list')) {\n $bab_hidden_input = '<input type=\"hidden\" name=\"editListID\" value=\"' . $listToEdit . '\">';\n $bab_prefix = 'edit';\n $bab_submit_value = 'Update List Information';\n $bab_prefix = 'edit';\n\n $row = safe_row('*', 'bab_pm_list_prefs', \"listID=\" . doSlash($listToEdit));\n echo \"<fieldset id=bab_pm_edit><legend>Editing List: $row[listName]</legend>\";\n }\n\n $form_prefix = $prefs[_bab_prefix_key('form_select_prefix')];\n\n $forms = safe_column('name', 'txp_form',\"name LIKE '\". doSlash($form_prefix) . \"%'\");\n $form_select = selectInput($bab_prefix.ucfirst('listEmailForm'), $forms, @$row['listEmailForm']);\n // replace class\n $form_select = str_replace('class=\"list\"', 'class=\"bab_pm_input\"', $form_select);\n }\n\n // build form\n\n echo '<form method=\"POST\" id=\"subscriber_edit_form\">';\n\n foreach ($bab_columns as $column) {\n echo '<dl class=\"bab_pm_form_input\"><dt>'.bab_pm_preferences($column).'</dt><dd>';\n $bab_input_name = $bab_prefix . ucfirst($column);\n\n switch ($column) {\n case 'listEmailForm':\n echo $form_select;\n break;\n case 'listSubjectLine':\n $checkbox_text = 'Use Article Title for Subject';\n case 'listUnsubscribeUrl':\n if (empty($checkbox_text)) {\n $checkbox_text = 'Use Default';\n }\n\n $checked = empty($row[$column]) ? 'checked=\"checked\" ' : '';\n $js = <<<eojs\n<script>\n$(document).ready(function () {\n $('#{$column}_checkbox').change(function(){\n if ($(this).is(':checked')) {\n $('input[name={$bab_input_name}]').attr('disabled', true).val('');\n }\n else {\n $('input[name={$bab_input_name}]').attr('disabled', false);\n }\n });\n});\n</script>\n\neojs;\n\n echo $js . '<input id=\"'.$column.'_checkbox\" type=\"checkbox\" class=\"bab_pm_input\" ' . $checked . '/>'.$checkbox_text.'</dd><dd>' .\n '<input type=\"text\" name=\"' . $bab_input_name . '\" value=\"' . doSpecial(@$row[$column]) . '\"' .\n (!empty($checked) ? ' disabled=\"disabled\"' : '') . ' />' .\n '</dd>';\n break;\n case 'subscriberLists':\n foreach ($lists as $list) {\n $checked = '';\n\n foreach ($subscriber_lists as $slist) {\n if ($list['listID'] == $slist['list_id']) {\n $checked = 'checked=\"checked\" ';\n break;\n }\n }\n\n echo '<input type=\"checkbox\" name=\"'. $bab_input_name .'[]\" value=\"'.$list['listID'].'\"' . $checked . '/>'\n . doSpecial($list['listName']) . \"<br>\";\n }\n break;\n default:\n echo '<input type=\"text\" name=\"' . $bab_input_name . '\" value=\"' . doSpecial(@$row[$column]) . '\" class=\"bab_pm_input\">';\n break;\n }\n\n echo '</dd></dl>';\n }\n\n echo $bab_hidden_input;\n echo '<input type=\"submit\" value=\"' . doSpecial($bab_submit_value) . '\" class=\"publish\">';\n echo '</form>';\n}", "public function get_submitted_edit_form_data()\n\t{\n\t\t$this->credits = $_POST['credits'];\n\t\t$this->levelID = $_POST['level'];\t\n\t}", "private function get_hidden_cashflow_fields(){\n\t\treturn $this->obj->get_values_as_array( get_class( $this->obj ) );\n\t}", "public function addHidden() {\n parent::createHiddenWithValidator(\"id\");\n }", "public function addHidden() {\n parent::createHiddenWithValidator(\"id\");\n }", "function chat_prepare_form_vars($chat = NULL) {\n\t$user = elgg_get_logged_in_user_entity();\n\n\t// input names => defaults\n\t$values = array(\n\t\t'title' => NULL,\n\t\t'description' => NULL,\n\t\t'access_id' => ACCESS_LOGGED_IN,\n\t\t'container_guid' => NULL,\n\t\t'guid' => NULL,\n\t\t'members' => NULL,\n\t);\n\n\tif ($chat) {\n\t\tforeach (array_keys($values) as $field) {\n\t\t\tif (isset($chat->$field)) {\n\t\t\t\t$values[$field] = $chat->$field;\n\t\t\t}\n\t\t}\n\t\t$values['members'] = $chat->getMemberGuids();\n\t}\n\n\tif (elgg_is_sticky_form('chat')) {\n\t\t$sticky_values = elgg_get_sticky_values('chat');\n\t\tforeach ($sticky_values as $key => $value) {\n\t\t\t$values[$key] = $value;\n\t\t}\n\n\t\t// This is not a property of chat so add separately\n\t\t$values['description'] = $sticky_values['message'];\n\t}\n\n\telgg_clear_sticky_form('chat');\n\n\treturn $values;\n}", "function build_hiddenprofilefield_cache()\n{\n\tglobal $vbulletin;\n\n\t$fields = $vbulletin->db->query_read(\"\n\t\tSELECT profilefieldid\n\t\tFROM \" . TABLE_PREFIX . \"profilefield AS profilefield\n\t\tWHERE hidden = 1\n\t\");\n\n\twhile ($field = $vbulletin->db->fetch_array($fields))\n\t{\n\t\t$hiddenfields .= \", '' AS field$field[profilefieldid]\";\n\t}\n\n\tbuild_datastore('hidprofilecache', $hiddenfields);\n}", "public function getHiddenInputField(){\n return $this->_hiddenInputField;\n }", "public function getHiddenFields()\n {\n return [\n 'createdAt',\n 'updatedAt',\n 'version',\n 'locale'\n ];\n }", "private function prepare_form_data()\n {\n $form_data = array(\n 'email' => array(\n 'name' => 'email',\n 'options' => array(\n '' => '--',\n ),\n 'extra' => array('id'=>'login-email', 'autofocus'=>''),\n ),\n 'password' => array(\n 'name' => 'password',\n 'options' => array(\n '' => '--',\n ),\n 'extra' => array('id'=>'login-password'),\n ),\n\n 'lbl-email' => array(\n 'target' => 'email',\n 'label' => 'E-mail Address',\n ),\n 'lbl-password' => array(\n 'target' => 'password',\n 'label' => 'Password',\n ),\n\n 'btn-submit' => array(\n 'value' => 'Login',\n 'extra' => array(\n 'class' => 'btn btn-primary',\n ),\n ),\n );\n\n return \\DG\\Utility::massage_form_data($form_data);\n }", "function populate() {\n // @todo We inject client input directly into the form. What about\n // security issues?\n if (isset($this->form->request['raw_input'][$this->attributes['name']])) {\n // Disabled input elements do not accept new input.\n if (!$this->disabled) {\n $this->value = $this->form->request['raw_input'][$this->attributes['name']];\n }\n }\n }", "abstract protected function getFormIntroductionFields();", "function FillActualFields($formname,$convert=true) // fuer die datenbank \n {\n $htmllist = &$this->FormList[$formname]->HTMLList;\n if($htmllist->items>0)\n {\n $field = &$htmllist->getFirst();\n for($i=0; $i <= $htmllist->items; $i++)\n {\n\t\n\tif($this->app->Secure->GetPOST($field->identifier)!=\"\")\n\t{\n\t $field->value = $this->app->Secure->GetPOST($field->identifier);\n\t}else\n\t{\n\t $field->value = $field->htmlobject->value;\n\t}\n\t\n\t\n\tif($field->value!=\"\" && $convert){\n\t $value = $this->app->String->Convert(\n\t //$field->value,$field->htmlformat,$field->dbformat);\n\t $field->value,$field->dbformat,$field->htmlformat);\n\t\n\t $value = $this->app->String->decodeText($value);\n\t $field->value = $value;\n\t} \n\n\tif(get_class($htmlobject)==\"blindfield\")\n\t $field->value=$field->htmlobject->value;\n \t\n\t\n\t$field->htmlobject->value=$field->value;\n\n\t\n\t$field = &$htmllist->getNext();\n }\n }\n }", "function wyz_ajax_business_sidebar_save_form() {\n\n\t$form_data = json_decode( stripslashes_deep( $_REQUEST['form_data'] ),true );\n\tif ( ! empty( $form_data ) && is_array( $form_data ) ) {\n\t\tforeach ( $form_data as $key => $value ) {\n\t\t\t$form_data[ $key ]['hidden'] = true;\n\t\t}\n\t}\n\tupdate_option( 'wyz_business_sidebar_order_data', $form_data ); \n\twp_die();\n}", "function _field_hidden($fval) \n {\n\n $myval = (empty($fval) && !empty($this->opts))? $this->opts : $fval;\n\n return sprintf(\"<input type=\\\"hidden\\\" name=\\\"%s\\\" id=\\\"%s\\\" class=\\\"%s\\\" value=\\\"%s\\\" />\",\n $this->fname,\n $this->fname,\n (!empty($this->attribs['class']))? $this->attribs['class'] : '',\n $this->_htmlentities($myval)\n ) ;\n }", "protected function renderHiddenFieldForEmptyValue() {}", "public function prepareForm()\n {\n // Searching for the data to populate the Form\n\n // Adding default value to the list\n\n // Setting the lists in $data array\n $data = [\n ];\n\n //dd($data);\n\n return $data;\n }", "function form_init_data()\r\n {\r\n $this->set_hidden_element_value('_action', FT_ACTION_UPDATE) ;\r\n $this->set_hidden_element_value('swimmeetid', $this->getSwimMeetId()) ;\r\n\r\n $swimmeet = new SwimMeet() ;\r\n $swimmeet->LoadSwimMeetById($this->getSwimMeetId()) ;\r\n\r\n $this->set_element_value('Organization', $swimmeet->getOrgCode()) ;\r\n $this->set_element_value('Meet Name', $swimmeet->getMeetName()) ;\r\n $this->set_element_value('Meet Address 1', $swimmeet->getMeetAddress1()) ;\r\n $this->set_element_value('Meet Address 2', $swimmeet->getMeetAddress2()) ;\r\n $this->set_element_value('Meet State', $swimmeet->getMeetState()) ;\r\n $this->set_element_value('Meet Postal Code', $swimmeet->getMeetPostalCode()) ;\r\n $this->set_element_value('Meet Country', $swimmeet->getMeetCountryCode()) ;\r\n $this->set_element_value('Meet Code', $swimmeet->getMeetCode()) ;\r\n $this->set_element_value('Pool Altitude', $swimmeet->getPoolAltitude()) ;\r\n $this->set_element_value('Course Code', $swimmeet->getCourseCode()) ;\r\n\r\n $date = $swimmeet->getMeetStart(false) ;\r\n $this->set_element_value('Meet Start', array('year' => substr($date, 4, 4),\r\n 'month' => substr($date, 0, 2), 'day' => substr($date, 2, 2))) ;\r\n\r\n $date = $swimmeet->getMeetEnd(false) ;\r\n $this->set_element_value('Meet End', array('year' => substr($date, 4, 4),\r\n 'month' => substr($date, 0, 2), 'day' => substr($date, 2, 2))) ;\r\n }", "function vc_infusion_settings_form_submit($form, $form_state) {\n $v = &$form_state['values'];\n variable_set('vc_infusion_appkey', $v['appkey']);\n variable_set('vc_infusion_appname', $v['appname']);\n variable_set('vc_infusion_template_firstname', $v['firstname']);\n variable_set('vc_infusion_template_lastname', $v['lastname']);\n variable_set('vc_infusion_template_email', $v['email']);\n}", "public function __construct ($formFields,$hiddenFormFields,$errorDetailsKey) \n {\n\t$this->formFields = $formFields;\n\t$this->hiddenFormFields = $hiddenFormFields;\n\t$this->actualFormFields = RegistrationEnums::$pageFields[$errorDetailsKey];\n\t$this->actualHiddenFormFields = RegistrationEnums::$pageHiddenFields[$errorDetailsKey];\n }", "protected function addFormObjectToViewHelperVariableContainer() {}", "protected function _prepareForm()\n {\n /**\n * @var $value \\Amasty\\Finder\\Model\\Value\n */\n $value = $this->_coreRegistry->registry('current_amasty_finder_value');\n $finder = $this->_coreRegistry->registry('current_amasty_finder_finder');\n $settingData = [];\n /** @var \\Magento\\Framework\\Data\\Form $form */\n $form = $this->_formFactory->create(\n [\n 'data' => [\n 'id' => 'edit_form',\n 'action' => $this->getUrl('amasty_finder/value/save', ['id' => $this->getRequest()->getParam('id'), 'finder_id'=>$finder->getId()]),\n 'method' => 'post',\n 'enctype' => 'multipart/form-data',\n ],\n ]\n );\n $form->setUseContainer(true);\n $this->setForm($form);\n\n $fieldset = $form->addFieldset('set', array('legend'=> __('General')));\n $fieldset->addField('sku', 'text', [\n 'label' => __('SKU'),\n 'title' => __('SKU'),\n 'name' => 'sku',\n ]);\n\n if($value->getId()) {\n $settingData['sku'] = $value->getSkuById($this->getRequest()->getParam('id'), $value->getId());\n }\n $currentId = $value->getId();\n\n\n $fields = [];\n while($currentId) {\n $alias_name = 'name_' . $currentId;\n $alias_label = 'label_'.$currentId;\n\n $model = clone $value;\n $model->load($currentId);\n $currentId = $model->getParentId();\n $dropdownId = $model->getDropdownId();\n $dropdown = $this->_objectManager->create('Amasty\\Finder\\Model\\Dropdown')->load($dropdownId);\n $dropdownName = $dropdown->getName();\n $settingData[$alias_name] = $model->getName();\n $fields[$alias_name] = [\n 'label' => __($dropdownName),\n 'title' => __($dropdownName),\n 'name' => $alias_label\n ];\n }\n\n $fields = array_reverse($fields);\n\n foreach($fields as $alias_name=>$fieldData) {\n $fieldset->addField($alias_name, 'text', $fieldData);\n }\n\n if(!$value->getId()) {\n $finder = $value->getFinder();\n\n foreach ($finder->getDropdowns() as $drop){\n $alias_name = 'name_'.$drop->getId();\n $alias_label = 'label_'.$drop->getId();\n $fieldset->addField($alias_name, 'text', [\n 'label' => __($drop->getName()),\n 'title' => __($drop->getName()),\n 'name' => $alias_label\n ]);\n }\n\n $fieldset->addField('new_finder', 'hidden', ['name' => 'new_finder']);\n $settingData['new_finder'] = 1;\n }\n\n\n //set form values\n $form->setValues($settingData);\n\n return parent::_prepareForm();\n }", "function my_module_hero_image_edit_form_submit($form, &$form_state) {\n $form_fields = array(\n 'title_text',\n 'title_heading',\n );\n foreach ($form_fields as $key) {\n $form_state['conf'][$key] = $form_state['values'][$key];\n }\n\n}", "function the_block_editor_meta_box_post_form_hidden_fields($post)\n {\n }", "private function _set_fields()\n {\n @$this->form_data->question_id = 0;\n\n $this->form_data->category_id = 0;\n $this->form_data->sub_category_id = 0;\n $this->form_data->sub_two_category_id = 0;\n $this->form_data->sub_three_category_id = 0;\n $this->form_data->sub_four_category_id = 0;\n\n $this->form_data->ques_text = '';\n $this->form_data->survey_weight = '';\n $this->form_data->ques_type = '';\n $this->form_data->qus_fixed = 0;\n $this->form_data->ques_expiry_date = '';\n\n\n $this->form_data->filter_question = '';\n $this->form_data->filter_category = 0;\n $this->form_data->filter_type = '';\n $this->form_data->filter_expired = '';\n }", "function form_init_data()\r\n {\r\n // Initialize the form fields\r\n\r\n $this->set_hidden_element_value(\"_action\", FT_ACTION_ADD) ;\r\n\r\n $this->set_element_value(\"Meet Start\", array(\"year\" => date(\"Y\"),\r\n \"month\" => date(\"m\"), \"day\" => date(\"d\"))) ;\r\n $this->set_element_value(\"Meet End\", array(\"year\" => date(\"Y\"),\r\n \"month\" => date(\"m\"), \"day\" => date(\"d\"))) ;\r\n\r\n // If the config is set to US only, initialize the country\r\n\r\n if (FT_US_ONLY)\r\n $this->set_element_value(\"Meet Country\",\r\n FT_SDIF_COUNTRY_CODE_UNITED_STATES_OF_AMERICA_VALUE) ;\r\n\r\n $this->set_element_value(\"Pool Altitude\", \"0\") ;\r\n }", "public function getFormFields()\n {\n $order_id = $this->getOrder()->getRealOrderId();\n $billing = $this->getOrder()->getBillingAddress();\n if ($this->getOrder()->getBillingAddress()->getEmail()) {\n $email = $this->getOrder()->getBillingAddress()->getEmail();\n } else {\n $email = $this->getOrder()->getCustomerEmail();\n }\n\n $params = array(\n 'merchant_fields' => 'partner',\n 'partner' => 'magento',\n 'pay_to_email' => Mage::getStoreConfig(Paynova_Paynovapayment_Helper_Data::XML_PATH_EMAIL),\n 'transaction_id' => $order_id,\n 'return_url' => Mage::getUrl('paynovapayment/processing/success', array('transaction_id' => $order_id)),\n 'cancel_url' => Mage::getUrl('paynovapayment/processing/cancel', array('transaction_id' => $order_id)),\n 'status_url' => Mage::getUrl('paynovapayment/processing/status'),\n 'language' => $this->getLocale(),\n 'amount' => round($this->getOrder()->getGrandTotal(), 2),\n 'currency' => $this->getOrder()->getOrderCurrencyCode(),\n 'recipient_description' => $this->getOrder()->getStore()->getWebsite()->getName(),\n 'firstname' => $billing->getFirstname(),\n 'lastname' => $billing->getLastname(),\n 'address' => $billing->getStreet(-1),\n 'postal_code' => $billing->getPostcode(),\n 'city' => $billing->getCity(),\n 'country' => $billing->getCountryModel()->getIso3Code(),\n 'pay_from_email' => $email,\n 'phone_number' => $billing->getTelephone(),\n 'detail1_description' => Mage::helper('paynovapayment')->__('Order ID'),\n 'detail1_text' => $order_id,\n 'payment_methods' => $this->_paymentMethod,\n 'hide_login' => $this->_hidelogin,\n 'new_window_redirect' => '1'\n );\n\n // add optional day of birth\n if ($billing->getDob()) {\n $params['date_of_birth'] = Mage::app()->getLocale()->date($billing->getDob(), null, null, false)->toString('dmY');\n }\n\n return $params;\n }", "function ProcessValuesAdd(&$values, &$pageObject)\n{\n\n\t\t\ncalendar_hideFields($pageObject);\n\n;\t\t\n}", "public function testInputFieldHidden()\n {\n $this->assertEquals(\n '<input type=\"hidden\" name=\"name\" value=\"val\" id=\"id\">',\n $this->fixture->inputFieldHidden('name', 'val', 'id')\n );\n $this->assertEquals(\n '<input type=\"hidden\" name=\"name\" value=\"val\">',\n $this->fixture->inputFieldHidden('name', 'val')\n );\n $this->assertEquals(\n '<input type=\"hidden\" name=\"name\" value=\"\">',\n $this->fixture->inputFieldHidden('name')\n );\n }", "function add_specific_form_fields() {\n\t\treturn false;\n\t}", "function vals_soc_invite_form($form, &$form_state, $org = '', $target = '', $show_action = 'administer', $type, $subtype = '') {\n include_once(_VALS_SOC_ROOT . '/includes/module/vals_soc.mail_messages.inc');\n $message = get_invite_email_body($org, $subtype, ($subtype == _STUDENT_TYPE) ? t('your institute') : '');\n\n $form = array(\n '#prefix' => \"<div id='vals_soc_entity_form_wrapper_$target'>\",\n '#suffix' => '</div>',\n );\n $form['email_contact_header'] = array(\n '#markup' => '<h2>' . tt('Invite new %1$s', $subtype) . '</h2><br/>'\n );\n $form['subject'] = array(\n '#type' => 'hidden',\n \"#default_value\" => t('Invitation to join the VALS Semester of code'),\n );\n $form['contact_email'] = array(\n \"#type\" => \"textfield\",\n '#title' => t('Email of the person to invite'),\n '#description' => t('This can be a comma-separated list of addresses'),\n \"#size\" => 100,\n '#required' => '1',\n \"#default_value\" => '',\n );\n $form['description'] = array(\n \"#type\" => \"textarea\",\n '#title' => t('Message'),\n //\"#size\" => 1024,\n \"#default_value\" => $message,\n );\n $form['submit'] = array(\n '#type' => 'submit',\n '#attributes' => array('onclick' => entityCall($type, $org, $target, $show_action, 'administration', 'send_invite_email')),\n '#value' => t('Send'),\n '#post_render' => array('vals_soc_fix_submit_button'),\n );\n $form['cancel'] = array(\n '#type' => 'button',\n '#value' => t('Cancel'),\n '#prefix' => '&nbsp; &nbsp; &nbsp;',\n '#attributes' => array('onClick' => 'location.reload(); return true;'),\n '#post_render' => array('vals_soc_fix_submit_button'),\n );\n $form['#vals_soc_attached']['js'] = array(\n array(\n 'type' => 'file',\n 'data' => '/includes/js/test_functions.js',\n ),\n );\n return $form;\n}", "function pixelgarage_preprocess_views_exposed_form(&$vars) {\n //\n // add placeholders to search exposed form items\n $form = &$vars['form'];\n if ($form['#id'] != 'views-exposed-form-blog-panel-pane-1') return;\n\n foreach ($form['#info'] as $id => $info) {\n // add the description as placeholder to the widget\n $field = $form[$info['value']];\n $field['#attributes']['placeholder'] = $info['description'];\n $field['#printed'] = false;\n\n // render widget again\n $vars['widgets'][$id]->widget = drupal_render($field);\n }\n\n}", "protected function addFormFieldNamesToViewHelperVariableContainer() {}", "public function getExtraFields()\n {\n $extraFields = new FieldList();\n\n $token = $this->getSecurityToken();\n if ($token) {\n $tokenField = $token->updateFieldSet($this->fields);\n if ($tokenField) {\n $tokenField->setForm($this);\n }\n }\n $this->securityTokenAdded = true;\n\n // add the \"real\" HTTP method if necessary (for PUT, DELETE and HEAD)\n if (strtoupper($this->FormMethod() ?? '') != $this->FormHttpMethod()) {\n $methodField = new HiddenField('_method', '', $this->FormHttpMethod());\n $methodField->setForm($this);\n $extraFields->push($methodField);\n }\n\n return $extraFields;\n }", "public function init_form_fields() {\n\t\t$this->form_fields = include( 'settings-xendit.php' );\n\t}", "public function init_form_fields(){\n \n\t\t$this->form_fields = array(\n\t\t\t'enabled' => array(\n\t\t\t\t'title' => 'Enable/Disable',\n\t\t\t\t'label' => 'Enable Vortex Gateway',\n\t\t\t\t'type' => 'checkbox',\n\t\t\t\t'description' => '',\n\t\t\t\t'default' => 'no'\n\t\t\t),\n\t\t\t'title' => array(\n\t\t\t\t'title' => 'Title',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'description' => 'This controls the title which the user sees during checkout.',\n\t\t\t\t'default' => 'Vortex Payment',\n\t\t\t\t'desc_tip' => true,\n\t\t\t),\n\t\t\t'description' => array(\n\t\t\t\t'title' => 'Description',\n\t\t\t\t'type' => 'textarea',\n\t\t\t\t'description' => 'This controls the description which the user sees during checkout.',\n\t\t\t\t'default' => 'Paga con Vortex Payment.',\n\t\t\t),\n\t\t\t'BID' => array(\n\t\t\t\t'title' => 'Business ID',\n\t\t\t\t'type' => 'text'\n\t\t\t)\n\n\t\t\t);\n \n\t \t}", "function insert_history_tracking_fields_to_master_view(Array $visible_columns):Array{\n if( !in_array($this->CI->grants->history_tracking_field($this->controller,'created_by'),$visible_columns) || \n !in_array($this->CI->grants->history_tracking_field($this->controller,'last_modified_by'),$visible_columns)\n \n ){\n array_push($visible_columns,$this->CI->grants->history_tracking_field($this->controller,'created_by'),\n $this->CI->grants->history_tracking_field($this->controller,'last_modified_by')); \n }\n\n return $visible_columns;\n }", "function workflow_hide_fields_form_preset_edit($form, &$form_state) {\r\n\r\n if (empty($form_state['preset'])) {\r\n $preset = workflow_hide_fields_preset_create();\r\n }\r\n else {\r\n $preset = $form_state['preset'];\r\n }\r\n\r\n // Title\r\n $form['title'] = array(\r\n '#type' => 'textfield',\r\n '#maxlength' => '255',\r\n '#title' => t('Title'),\r\n '#description' => t('A human-readable title for this option set.'),\r\n '#required' => TRUE,\r\n '#default_value' => $preset->title,\r\n );\r\n $form['name'] = array(\r\n '#type' => 'machine_name',\r\n '#maxlength' => '255',\r\n '#machine_name' => array(\r\n 'source' => array('title'),\r\n 'exists' => 'workflow_hide_fields_preset_exists',\r\n ),\r\n '#required' => TRUE,\r\n '#default_value' => $preset->name,\r\n );\r\n\r\n\r\n // Options Vertical Tab Group table\r\n $form['preset'] = array(\r\n '#type' => 'vertical_tabs',\r\n );\r\n\r\n $default_options = workflow_hide_fields_option_elements($preset->options);\r\n // Add the options to the vertical tabs section\r\n foreach ($default_options as $key => $value) {\r\n $form['options'][] = $value;\r\n }\r\n\r\n if (!empty($form_state['values']['nodeType'])) {\r\n $selected = $form_state['values']['nodeType'];\r\n\r\n // When the form is rebuilt during ajax processing, the $selected variable\r\n // will now have the new value and so the options will change. \r\n $form['options'][0]['fields']['fieldResponsible']['#options'] = _ajax_get_fields_options($selected);\r\n $form['options'][0]['fields']['fieldRating']['#options'] = _ajax_get_fields_options($selected);\r\n $form['options'][0]['fields']['fieldState']['#options'] = _ajax_get_fields_options($selected);\r\n $form['options'][0]['fields']['fieldsWritableOnlyOnCreation']['#options'] = _ajax_get_fields_options($selected);\r\n }\r\n else {\r\n $form['options'][0]['fields']['fieldResponsible']['#options'] = _ajax_get_fields_options($form['options'][0]['nodeType']['#default_value']);\r\n $form['options'][0]['fields']['fieldRating']['#options'] = _ajax_get_fields_options($form['options'][0]['nodeType']['#default_value']);\r\n $form['options'][0]['fields']['fieldState']['#options'] = _ajax_get_fields_options($form['options'][0]['nodeType']['#default_value']);\r\n $form['options'][0]['fields']['fieldsWritableOnlyOnCreation']['#options'] = _ajax_get_fields_options($form['options'][0]['nodeType']['#default_value']);\r\n }\r\n\r\n return $form;\r\n}", "protected function removeFormFieldNamesFromViewHelperVariableContainer() {}", "function dumpFormItems()\r\n {\r\n // Overriden to avoid printing a hidden field to get the value of the component.\r\n }", "function hidden() {\n\t\t$args = func_get_args();\n\n\t\twhile (list($name,$val) = each($args[0]))\n\t\t\t$this->buffer .= \"<input type=\\\"hidden\\\" name=\\\"$name\\\" value=\\\"$val\\\" id=\\\"$name\\\" />\";\n\n\t\treturn $this->output();\n\t}", "function steps_prepare_form_vars($Step = null, \n $item_guid = 0, \n $referrer = null, \n $description = null,\n\t \t\t\t\t\t\t\t$section = null) {\n\t// input names => defaults\n\tswitch ($section) {\n\t\tcase 'Summary':\n\t\t break;\n\t\tcase 'Details':\n\t\t break;\n\t\tcase 'Escallation':\n\t\t break;\n\t\tcase 'Ownership':\n\t\t break;\n\t\tcase 'Discussion':\n\t\t break;\n\t\tcase 'Gallery':\n\t\t break;\n\t\tdefault:\n\t\t\t$values = array(\n\t\t\t\t\t'title' => '',\n\t\t\t 'description' => $description,\n\t\t\t\t\t'step_type' => '',\n\t\t\t\t\t'step_number' => '',\n\t\t\t\t\t'observer' => '',\n\t\t\t\t\t'aspect' => 'Step',\n\t\t\t 'referrer' => $referrer,\n\t\t\t\t\t'access_id' => ACCESS_DEFAULT,\n\t\t\t\t\t'write_access_id' => ACCESS_DEFAULT,\n\t\t\t\t\t'tags' => '',\n\t\t\t\t\t'container_guid' => elgg_get_page_owner_guid(),\n\t\t\t\t\t'guid' => null,\n\t\t\t\t\t'entity' => $Step,\n\t\t\t\t\t'item_guid' => $item_guid,\n\t\t\t\t\t'asset' => get_entity($item_guid)->asset,\n\t\t\t\t);\n\t\t\tbreak;\n\t\t\n\t}\n\t\n if ($Step) {\n\t\tforeach (array_keys($values) as $field) {\n\t\t\tif (isset($Step->$field)) {\n\t\t\t\t$values[$field] = $Step->$field;\n\t\t\t}\n\t\t}\n\t}\n\n\tif (elgg_is_sticky_form('jot')) {\n\t\t$sticky_values = elgg_get_sticky_values('jot');\n\t\tforeach ($sticky_values as $key => $value) {\n\t\t\t$values[$key] = $value;\n\t\t}\n\t}\n\n//\telgg_clear_sticky_form('jot');\n\n\treturn $values;\n}", "public function init_form_fields() {\n\t\t$this->form_fields = include( 'data/data-settings.php' );\n\t}", "function print_hidden_settings_fields ()\n\t\t{\n\t\t\t$options = get_option('hs_settings');\n\n\t\t\t$hs_installed = ( isset($options['hs_installed']) ? $options['hs_installed'] : 1 );\n\t\t\t$hs_version = ( isset($options['hs_version']) ? $options['hs_version'] : HUBSPOT_TRACKING_CODE_PLUGIN_VERSION );\n\n\t\t\tprintf(\n\t\t\t\t\t'<input id=\"hs_installed\" type=\"hidden\" name=\"hs_settings[hs_installed]\" value=\"%d\"/>',\n\t\t\t\t\t$hs_installed\n\t\t\t);\n\n\t\t\tprintf(\n\t\t\t\t\t'<input id=\"hs_version\" type=\"hidden\" name=\"hs_settings[hs_version]\" value=\"%s\"/>',\n\t\t\t\t\t$hs_version\n\t\t\t);\n\t\t}", "function form_hidden($name, $value='', $arrayto='', $override = NULL) {\n\n\tif ($arrayto) {\n\t\t$name = $arrayto . \"[\" . $name . \"]\";\n\t}\n\n\t$value = html_form_escape($value, $override);\n\n\treturn \"<input type=\\\"hidden\\\" name=\\\"$name\\\" id=\\\"$name\\\" value=\\\"$value\\\" />\\n\";\n}", "function oncall_member_edit_form($form, &$form_state, $ocid = 0) {\n $oncall_user = oncall_user_settings($ocid);\n \n $form['oncall_name'] = array(\n '#type' => 'textfield', \n '#title' => t('Member Name'), \n '#default_value' => (isset($oncall_user->name)) ? $oncall_user->name : '', \n '#size' => 30, \n '#maxlength' => 15, \n '#description' => t('Enter a name for this team member. This name will be appended to team SMS messages, so ideally, it should be short.'),\n );\n \n $form['oncall_phone'] = array(\n '#type' => 'textfield', \n '#title' => t('Phone Number'), \n '#default_value' => (isset($oncall_user->phone)) ? $oncall_user->phone : '12065551212', \n '#size' => 30, \n '#maxlength' => 15, \n '#description' => t('Enter the phone number you\\'d like to have your OnCall SMS messages sent. Enter only numbers in this field, and include the country code. For US numbers, including the country code means starting with the number 1'),\n );\n \n $form['oncall_active'] = array(\n '#type' => 'radios',\n '#title' => t('On Call Availability'),\n '#default_value' => (isset($oncall_user->available)) ? $oncall_user->available : 1,\n '#options' => array(0 => t('Away'), 1 => t('Available')),\n '#description' => t('When set to \"Available\", sms messages from the On Call service may be sent to the telephone number given above.'),\n );\n\n $form['ocid'] = array(\n '#type' => 'value', \n '#value' => $ocid\n );\n\n $form['add_member'] = array(\n '#type' => 'submit', \n '#value' => t('Save Team Member'), \n );\n \n if ($ocid > 0) {\n $form['delete_member'] = array(\n '#type' => 'submit', \n '#value' => t('Remove Team Member'), \n '#submit' => array('oncall_member_remove'),\n );\n }\n\n return $form;\n}", "public static function wizard_mode_hidden_fields_action() {\n\t\t\techo '<input type=\"hidden\" name=\"pcor_wizard_mode\" value=\"from_scratch\" />';\n\t\t}", "function issues_prepare_form_vars($issue = null, \n $item_guid = 0, \n $referrer = null, \n $description = null) {\n\t// input names => defaults\n\t$values = array(\n\t\t'title' => '',\n\t\t'description' => '',\n\t\t'start_date' => '',\n\t\t'end_date' => '',\n\t\t'issue_type' => '',\n\t\t'issue_number' => '',\n\t\t'status' => '',\n\t\t'assigned_to' => '',\n\t\t'percent_done' => '',\n\t\t'work_remaining' => '',\n\t\t'aspect' => 'issue',\n 'referrer' => $referrer,\n 'description' => $description,\n\t\t'access_id' => ACCESS_DEFAULT,\n\t\t'write_access_id' => ACCESS_DEFAULT,\n\t\t'tags' => '',\n\t\t'container_guid' => elgg_get_page_owner_guid(),\n\t\t'guid' => null,\n\t\t'entity' => $issue,\n\t\t'item_guid' => $item_guid,\n\t);\n\n\tif ($issue) {\n\t\tforeach (array_keys($values) as $field) {\n\t\t\tif (isset($issue->$field)) {\n\t\t\t\t$values[$field] = $issue->$field;\n\t\t\t}\n\t\t}\n\t}\n\n\tif (elgg_is_sticky_form('jot')) {\n\t\t$sticky_values = elgg_get_sticky_values('jot');\n\t\tforeach ($sticky_values as $key => $value) {\n\t\t\t$values[$key] = $value;\n\t\t}\n\t}\n\n//\telgg_clear_sticky_form('jot');\n\n\treturn $values;\n}", "function form_hidden($field, $options) {\n $defaults = array(\n 'class' => array('input', 'hidden'),\n );\n\n $options = array_merge($defaults, $options);\n\n $field = strtolower($field);\n\n $output = '<input type=\"hidden\" name=\"' . $field . '\" id=\"' . form__field_id($field) . '\"';\n\n if(!empty($_POST[$field])) {\n $output .= ' value=\"'. $_POST[$field] . '\"';\n }\n\n $output .= ' />';\n\n return html__output($output);\n}", "function give_is_form_grid_page_hidden_field( $id, $args, $form ) {\n\techo '<input type=\"hidden\" name=\"is-form-grid\" value=\"true\" />';\n}", "function CollectInternalVars()\r\n {\r\n if(isset($this->formvars['sfm_form_page_num']) && \r\n is_numeric($this->formvars['sfm_form_page_num']))\r\n {\r\n $this->form_page_num = intval($this->formvars['sfm_form_page_num']);\r\n unset($this->formvars['sfm_form_page_num']);\r\n }\r\n }", "public function buildForm(array $form, FormStateInterface $form_state) {\n \t//Attaching js to the form\n $form['#attached']['library'][] = 'vizh5p/plotlylib';\n $form['#attached']['library'][] = 'vizh5p/Graph';\n \n //Select the database Service and get the table\n $db_logic = \\Drupal::service('vizh5p.db_logic');\n $data = $db_logic->get();\n $datauserarray = array();\n $datacidarray = array();\n $dataattemptarray = array();\n //Assign unique content ids\n foreach ($data as $d) {\n if(!in_array($d->content_id , $datacidarray))\n array_push($datacidarray , $d->content_id); \n }\n sort($datacidarray); //Sorting in ascending order\n \n //Creating form\n $form['content_id'] = array ( \n '#title' => t('Content-ID'),\n '#type' => 'select',\n '#description' => 'Select the content ID.',\n '#options' => $datacidarray,\n '#required' => TRUE,\n '#ajax' => array( //Ajax to dynamically load respective users using this content id\n 'event' => 'change',\n 'callback' => '::changeOptionsForUser',\n 'wrapper' => 'user',\n 'progress' => array(\n 'type' => 'throbber',\n 'message' => 'Finding Corresponding Users',\n ), \n )\n );\n \n //If the content id is selected then find the coresponding users\n if($form_state->hasValue('content_id')){ \n $contentid = $datacidarray[$form_state->getValue('content_id')];\n $datauserarray = array();\n foreach ($data as $d) \n if($contentid == $d->content_id)\n if(!in_array($d->actor , $datauserarray))\n array_push($datauserarray , $d->actor);\n sort($datauserarray);\n }\n $form['username'] = array (\n '#prefix' => '<div id=\"user\">', \n '#suffix' => '</div>',\n '#title' => t('Username'),\n '#type' => 'select',\n '#description' => 'Select the username.',\n '#options' => $datauserarray,\n '#required' => TRUE,\n '#ajax' => array( //Ajax call to change the options of number of attempts\n 'event' => 'change',\n 'callback' => '::changeOptionsForAttempt',\n 'wrapper' => 'attempt',\n 'progress' => array(\n 'type' => 'throbber',\n 'message' => 'Checking number of attempts',\n ), \n )\n );\n //If content id and username are selected then update the table\n if($form_state->hasValue('content_id') && $form_state->hasValue('username')) {\n $contentid = $datacidarray[$form_state->getValue('content_id')];\n $userid = $datauserarray[$form_state->getValue('username')];\n $i = 0;\n foreach ($data as $item) {\n if($contentid == $item->content_id && $userid == $item->actor && $item->verb == 'attempted') {\n $i++;\n array_push($dataattemptarray , $i);\n }\n }\n } \n else\n $dataattemptarray = array();\n $form['attempt'] = array (\n '#prefix' => '<div id=\"attempt\">', \n '#suffix' => '</div>',\n '#title' => t('Attempt Number'),\n '#type' => 'select',\n '#description' => 'Select the Attempt number.',\n '#options' => $dataattemptarray,\n '#required' => TRUE,\n '#ajax' => array( //Ajax call to change the table according to the content_id and username\n 'event' => 'change',\n 'callback' => '::changeTable',\n 'wrapper' => 'table',\n 'progress' => array(\n 'type' => 'throbber',\n 'message' => 'Fetching Table',\n ), \n )\n );\n $form['table'] = array(\n '#prefix' => '<div id=\"table\">', \n '#suffix' => '</div>',\n '#type' => 'table',\n '#caption' => $this->t('Table Data'),\n '#header' => array($this->t('Time'), $this->t('Content ID') ,$this->t('Actor'), $this->t('Verb')),\n );\n \n //If content id , username and attempt number are selected then update the table accordingly\n if($form_state->hasValue('content_id') && $form_state->hasValue('username') && $form_state->hasValue('attempt')){\n $contentid = $datacidarray[$form_state->getValue('content_id')];\n $userid = $datauserarray[$form_state->getValue('username')];\n $attempt = $dataattemptarray[$form_state->getValue('attempt')];\n $i = 0;\n foreach ($data as $item) {\n if($contentid == $item->content_id && $userid == $item->actor && $item->verb == 'attempted')\n $i++;\n if($contentid == $item->content_id && $userid == $item->actor && $i == $attempt) {\n $form['table'][] = array(\n 'time' => array(\n '#type' => 'markup',\n '#markup' => $item->time,\n ),\n \n 'content_id' => array(\n '#type' => 'markup',\n '#markup' => $item->content_id,\n ),\n \n 'actor' => array(\n '#type' => 'markup',\n '#markup' => $item->actor,\n ),\n \n 'verb' => array(\n '#type' => 'markup',\n '#markup' => $item->verb,\n ));\n }\n }\n } \n else\n $form['table'][] = array();\n \t//Container to display the graph\n $form['graph'] = array(\n \t'#markup' => '<div id=\"graph\"></div?>',\n );\n return $form;\n }", "public function setFormSessionData(): void\n {\n $session = (array) $this->request->getSession()->get(config('form.session_key'));\n\n $formId = $this->form->getID();\n if (array_key_exists($formId, $session)) {\n $data = $session[$formId];\n\n $this->data = array_key('data', $data, []);\n $this->errors = array_key('messages', $data, []);\n }\n array_map(\n function ($name, $message) {\n $this->form->getField($name)->setErrorMessage($message);\n },\n array_keys($this->errors),\n $this->errors\n );\n \n array_key_unset(config('form.csrf_field_name'), $this->data);\n \n $this->form->setValues($this->data);\n $this->removeSessionData();\n }", "function weldata_form_alter(&$form, &$form_state){\n\n}", "function populate_new_user_fields($form){\n\t\tif($form['title']!=self::FORM_USER_REGISTRATION) return $form;\n\n\t\tforeach ( $form['fields'] as $field )\n\t\t{\n\t\t\tif ( $field->type == 'select' and strpos( $field->cssClass,'student-cohorts' )!==false ) {\n\t\t\t \t$terms = get_terms(array('taxonomy' => 'user_cohort', 'lang' => 'en,es', 'hide_empty' => 0));\n\t\t\t \t//print_r($terms); die();\n\t\t\t \t$choices = array();\n\t\t\t\tforeach($terms as $term) if($term->parent!=0) $choices[] = array( 'text' => $term->name, 'value' => $term->term_id );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a cohort';\n\t\t\t}\n\t\t\telse if ( $field->type == 'select' and strpos( $field->cssClass,'available-courses' )!==false ) {\n\t\t\t \t$terms = get_terms( array( 'taxonomy' => 'course','hide_empty' => 0, 'parent'=>0));\n\t\t\t \t$choices = array();\n\t\t\t\tforeach($terms as $term) $choices[] = array( 'text' => $term->name, 'value' => $term->term_id );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a course';\n\t\t\t}\n\t\t\telse if ( $field->type == 'select' and strpos( $field->cssClass,'breathecode-location' )!==false ) {\n\t\t\t \t$locations = WPASThemeSettingsBuilder::getThemeOption('sync-bc-locations-api');\n\t\t\t\t$choices = [];\n\t\t\t\tforeach($locations as $loc) $choices[] = array( 'text' => $loc['name'], 'value' => $loc['slug'] );\n\t\t\t \t$field->choices = $choices;\n\t\t\t \t$field->placeholder = 'Select a location';\n\t\t\t}\n\t\t}\n\t\treturn $form;\n\t}", "function tpps_details_form_callback(array $form, array $form_state) {\n return array(\n 'details_type' => $form['details_type'],\n 'details_op' => $form['details_op'],\n 'details_value' => $form['details_value'],\n );\n}", "public function prepareVars()\n {\n if ($this->showLogRelations !== null) {\n $this->showLogRelations = (array) $this->showLogRelations;\n }\n\n $this->vars['name'] = $this->formField->getName();\n $this->vars['model'] = $this->model;\n $this->vars['showUndoChangesButton'] = $this->showUndoChangesButton;\n }", "public static function print_all_not_form_hidden($form_id, $exclude_params = array()){\n global $TFUSE;\n\n $forms_ids = (array)$form_id; // You can exclude params from multiple forms\n\n $forms = $TFUSE->get->ext_options($TFUSE->ext->seek->_the_class_name, 'forms');\n\n $items_options = $TFUSE->get->ext_options($TFUSE->ext->seek->_the_class_name, 'items');\n\n // convert to key array\n if(sizeof($exclude_params)){\n $new = array();\n foreach($exclude_params as $param){\n $new[ $param ] = '~';\n }\n $exclude_params = $new;\n unset($new);\n }\n\n $exclude_params[ self::get_search_parameter('form_id') ] = '~';\n\n $persistent_params = array();\n\n foreach($forms_ids as $form_id){\n\n if( !isset( $forms[$form_id] ) ){\n echo sprintf(__('Undefined seek form_id: %s, in ::print_all_not_form_hidden()', 'tfuse') . '<br/>\\n', esc_attr($form_id));\n return;\n }\n\n $form = &$forms[$form_id];\n\n if(sizeof($form['items'])){\n foreach($form['items'] as $item_id){\n\n if( !isset( $items_options[$item_id] ) ){\n echo sprintf(__('Undefined form item id: %s, in ::print_all_not_form_hidden()', 'tfuse') . '<br/>\\n', esc_attr($item_id));\n return;\n }\n\n $item = &$items_options[$item_id];\n\n if(!isset($item['settings']['persistent_parameter_name'])){\n $exclude_params[ $item['parameter_name'] ] = '~';\n } else {\n $persistent_params[ $item['parameter_name'] ] = '~';\n }\n }\n }\n }\n\n if(sizeof($persistent_params)){\n foreach($persistent_params as $name=>$val){\n unset($exclude_params[$name]);\n }\n }\n\n return self::print_all_hidden( array_keys($exclude_params) );\n }", "function load_from_form ($allowSensibleFields = false) {\n if (array_key_exists('title', $_POST)) {\n $this->title = $_POST['title'];\n }\n\n if ($allowSensibleFields) {\n if (array_key_exists('path', $_POST)) {\n $this->path = $_POST['path'];\n }\n if (array_key_exists('user_id', $_POST)) {\n $this->user_id = $_POST['user_id'];\n }\n if (array_key_exists('perso_id', $_POST)) {\n $this->perso_id = $_POST['perso_id'];\n }\n }\n }", "public function set_fields() {\n\n\t\t$this->fields = Pngx__Meta__Fields::get_fields();\n\t}", "function hidden ($nomes = '') {\n\tglobal $resultado;\n\t$nomes = explode(', ', $nomes);\n\t\n\tforeach ($nomes as $valor) {\n\t\tif (isset($resultado['variables'][$valor])) {\n\t\t\t$hidden .= '<input type=\"hidden\" name=\"'.$valor.'\" value=\"'.$resultado['variables'][$valor].'\" />';\n\t\t}\n\t}\n\treturn $hidden;\n}", "protected function renderHiddenSecuredReferrerField() {}", "function os2dagsorden_create_agenda_meeting_create_user_form($form, &$form_state) {\r\n $form_state['meeting_data'] = json_encode($form_state['values']);\r\n $form[] = array(\r\n '#markup' => '<h1 class=\"title\">' . t('External user') . '</h1>',\r\n );\r\n\r\n $form[] = array(\r\n '#markup' => '<div class=\"node\">',\r\n );\r\n $form['firstname'] = array(\r\n '#type' => 'textfield',\r\n '#title' => t('Firstname'),\r\n '#size' => 60,\r\n '#maxlength' => 128,\r\n '#required' => TRUE,\r\n );\r\n $form['lastname'] = array(\r\n '#type' => 'textfield',\r\n '#title' => t('Lastname'),\r\n '#size' => 60,\r\n '#maxlength' => 128,\r\n '#required' => TRUE,\r\n );\r\n $form['email'] = array(\r\n '#type' => 'textfield',\r\n '#title' => t('Email'),\r\n '#size' => 60,\r\n '#maxlength' => 128,\r\n '#required' => TRUE,\r\n '#element_validate' => array('_os2dagsorden_create_agenda_meeting_create_user_form_email_validate'),\r\n );\r\n $form['save_bullet_point'] = array(\r\n '#type' => 'submit',\r\n '#value' => t('Save'),\r\n '#submit' => array('_os2dagsorden_create_agenda_meeting_create_user_form_submit'),\r\n );\r\n $form[] = array(\r\n '#markup' => '</div>',\r\n );\r\n $form['#attached']['css'] = array(\r\n drupal_get_path('module', 'os2dagsorden_create_agenda') . '/css/form_theme.css',\r\n );\r\n return $form;\r\n}" ]
[ "0.65675426", "0.64753735", "0.590473", "0.5890775", "0.5793635", "0.5781936", "0.5767698", "0.57477486", "0.57398087", "0.5706359", "0.5687367", "0.5687367", "0.5663916", "0.5587671", "0.5568866", "0.5547855", "0.55431795", "0.553885", "0.5533969", "0.5517477", "0.5503451", "0.54924977", "0.5467197", "0.5462902", "0.5454293", "0.5445104", "0.5440013", "0.54252005", "0.54174864", "0.5401116", "0.54006314", "0.53817755", "0.5362897", "0.5351304", "0.5345704", "0.5344717", "0.5335899", "0.53280556", "0.53098536", "0.530834", "0.5265054", "0.5265054", "0.5263965", "0.525074", "0.5237725", "0.5216998", "0.52155614", "0.5202303", "0.5200803", "0.5198705", "0.5197309", "0.5195721", "0.51694787", "0.5156878", "0.51524585", "0.5148777", "0.51485574", "0.51346475", "0.5127679", "0.5113464", "0.5102864", "0.50978017", "0.50898165", "0.50887614", "0.508424", "0.50801843", "0.5056128", "0.5042327", "0.50367856", "0.5025701", "0.50099266", "0.5009285", "0.5002562", "0.49969435", "0.4993494", "0.49915618", "0.4991336", "0.49878946", "0.49665275", "0.49657953", "0.4962086", "0.49610353", "0.49601692", "0.49598303", "0.49555275", "0.49552423", "0.49542576", "0.49519196", "0.49290448", "0.49262503", "0.49246445", "0.49150106", "0.4901976", "0.49018815", "0.4899289", "0.48829633", "0.4876949", "0.48753962", "0.4868363", "0.48677772" ]
0.6567564
0
InviteHistoryHandler::removeInvitation() Remove the selected id values from the users invitation table
public function removeInvitation($id = 0) { $sql = 'DELETE FROM '.$this->CFG['db']['tbl']['users_invitation']. ' WHERE invitation_id='.$this->dbObj->Param($id); $stmt = $this->dbObj->Prepare($sql); $rs = $this->dbObj->Execute($stmt, array($id)); if (!$rs) trigger_db_error($this->dbObj); return ($this->dbObj->Affected_Rows()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete_invitation($invitation_id){\n if ($stmt = $this->connection->prepare('DELETE FROM device_invitations WHERE id = ?')) {\n $stmt->bind_param('i', $invitation_id);\n $status = $stmt->execute();\n $stmt->close();\n if($status === false){\n echo \"error\";\n $GLOBALS['error_message'] = \"SQL DELETE FAILED: [Device_Invitations] Delete Invitation\";\n return false;\n } \n return true;\n }\n else{\n $GLOBALS['error_message'] = \"Bad SQL Query: [Device_Invitations] Delete Invitation\";\n return false;\n }\n }", "public function deleted(Invitation $invitation)\n {\n //\n }", "public function deleted(Invitation $invitation)\n {\n //\n }", "public function remove() {\n\n // Updates DB (data & metadata)\n $this->attributes->removeAll($this->get(\"id\"));\n $this->db->delete(XCMS_Tables::TABLE_USERS, array(\n \"id\" => $this->get(\"id\")\n ));\n\n }", "public function invited_task_remove_people_post()\n {\n $id = $this->post('task_id');\n $user_id = $this->post('user_id');\n \n $array = array(\n 'is_removed' => 1\n );\n $this->db->where('taskId',$id);\n $this->db->where('user_id',$user_id);\n $this->db->update('invite_people',$array);\n \n $response = array('success'=>true,'message'=>'People Removed Successfully');\n echo json_encode($response);\n }", "public function removeUserFromGroup(){\n //Gets the id frim the input\n $removeId = $_GET[\"input\"];\n //This model removes the connection record from the table\n $this->individualGroupModel->removeUserFromTheGroup($removeId);\n }", "public function rejectInvitation()\n\t{\n\t\t$id = $this->request->data['id'];\n\t\t$invite['MeetingUser']['id'] = $id;\n\t\t//set status 1 as accepted\n\t\t$invite['MeetingUser']['is_accept'] = 2;\n\t\t$invite['MeetingUser']['is_read'] = 1;\n\t\t$invite['MeetingUser']['is_attend'] = 0;\n\t\t//set notification\n\t\t$oldCount1 = $this->Session->read('oldMeetingCount');\n\t\tif ($oldCount1>0) {\n\t\t\t$newCount1 = $oldCount1-1;\n\t\t\t$this->Session->write('oldMeetingCount',$newCount1);\n\t\t}\n\t\tif($this->MeetingUser->save($invite))\n\t\t\techo \"1\";\n\t\telse\n\t\t\techo \"0\";\n\t\texit;\n\t}", "public function unsubscribeInviteReminder(){\n\n\t\tif(null === $this->id){\n\t\t\t$this->load();\n\t\t}\n\n\t\t// unsubscribe only if the gift/email is still subscribed\n\t\tif($this->isSubscribedInviteReminder()) {\n\t\t\t// add an unsubscribe entry for this email/gift/template\n\t\t\t$worker = new inviteReminderUnsubscribeEmailWorker();\n\t\t\t$worker->send($this->id);\n\t\t}\n\n\t}", "public function rejectInvitation($id){\n\n $invite = Invitation::find($id);\n $invite->delete();\n return redirect()->back();\n }", "public function disinvite($user) {\n\t\t$invitation = $this->event->getInvitation($user);\n\t\t$this->event->removeInvitation($invitation); // this should also automatically remove the invitation from the database\t\t\n\t\t$this->event->save();\n\t}", "function removeuserfromteam(){\n $this->auth(COMP_ADM_LEVEL);\n $key_id = $this->uri->segment(3);\n $team_id = $this->uri->segment(4);\n $contest_id = $this->uri->segment(5);\n $this->m_key->removeUserByKeyId($key_id);\n $this->teamedit($team_id);\n }", "function disAgreeFriendHandler() {\n global $inputs;\n\n $sql = \"DELETE FROM `member_friend_apply` WHERE id = \" . $inputs['id'];\n execSql($sql);\n\n formatOutput(true, 'option success');\n}", "function do_remove_assign_user() {\r\n foreach(array(\"stream_id\",\"userid\") as $i)\r\n $$i=$this->input->post($i);\r\n $this->db->query(\"delete from `m_stream_users` where `stream_id`=? and `user_id`=?\",array($stream_id,$userid));\r\n }", "public function eliminarItemsVentas($id_unico){\n //echo($id_unico.\"---\");\n \n date_default_timezone_set('America/La_Paz');\n $fecha_actual = date(\"y-m-d H:i:s\");\n $datos['vent_prof_det_usr_baja'] = $_SESSION['login'];\n $datos['vent_prof_det_fech_hr_baja'] = $fecha_actual;\n $condicion = \"vent_prof_det_cod_unico='\".$id_unico.\"'\";\n return $this->mysql->update('vent_prof_det', $datos, $condicion);\n //$this->mysql->update('vent_prof_cab',$datos,'vent_prof_cab_cod_unico='.$id_unico.'');\n }", "public function reject() {\n\t\t$query = array(\n\t\t\t'group' => $this->group->createReference(),\n\t\t\t'invitee' => $this->candidate->createReference(),\n\t\t);\n\t\t$invite = EpicDb_Mongo::db('invitation')->fetchOne($query);\n\t\tif($invite) $invite->delete();\n\t\t// Reject this application\n\t\t$this->status = \"rejected\";\n\t\t$this->save();\n\t}", "public function user_remove_confirm_code($id){\n\t \t$data = array(\n\t \t\t'confirm_code' => ''\n\t \t);\n\t \t$this->db->where('id', $id);\n\t \t$this->db->update('users', $data);\n\t }", "public function rejectInvitation() {\n\t\t$this->autoRender = false;\n\t\t$communityId = $this->request->data['communityId'];\n\t\t$community = $this->Community->findById($communityId);\n\t\tif (!empty($community)) {\n\t\t\t$userId = $this->Auth->user('id');\n\t\t\t$this->CommunityMember->reject($communityId, $userId);\n\t\t\t//Community unfollow data\n\t\t\t$followCommunityData = array(\n\t\t\t\t'type' => FollowingPage::COMMUNITY_TYPE,\n\t\t\t\t'page_id' => $communityId,\n\t\t\t\t'user_id' => $userId\n\t\t\t);\n\t\t\t$this->FollowingPage->unFollowPage($followCommunityData);\n\t\t\t$this->Session->setFlash(__('The invitation has been rejected.'), 'success');\n\t\t} else {\n\t\t\t$this->Session->setFlash(__($this->invalidMessage), 'error');\n\t\t}\n\t}", "public function deleteSelected()\n {\n PatientRecord::whereIn('id', $this->selectedKeys())->delete();\n }", "public function remove_row() {\n\t\t\t$email = $this->input->post('email');\n\n\t\t\t$this->load->model('users_table');\n\t\t\t$data = $this->users_table->remove_row($email);\n\t\t}", "public function actionRemove_user($id) { // by anoop 15-11-18\n //redirect a user if not super admin\n if (!Yii::$app->CustomComponents->check_permission('assign_team')) {\n return $this->redirect(['site/index']);\n }\n\n if (!empty($id)) {\n // get User email\n $user_email = Yii::$app->db->createCommand(\"SELECT email FROM assist_users WHERE id = '$id' AND status = 1 \")->queryAll();\n $useremail = $user_email[0]['email'];\n\n Yii::$app->db->createCommand(\"UPDATE assist_user_meta SET meta_value = '' WHERE meta_key = 'team' AND uid = '$id' \")->execute();\n\n Yii::$app->session->setFlash('success', 'User with Email Address <u>' . $useremail . '</u> Successfully Removed.');\n return $this->redirect(['dv-users/assign_team']);\n //return $this->redirect(['view', 'id' => $user_id]);\n }\n }", "function action_remove() {\n\t\t\t$data = UTIL::get_post('data');\n\t\t\t$id = (int)$data['rem_id'];\n\t\t\t$table = $data['rem_table'];\n\t\t\t\n\t\t\t$choosen = $this->SESS->get('objbrowser', 'choosen');\n\t\t\tunset($choosen[$table][$id]);\n\t\t\tif (count($choosen[$table]) == 0) unset($choosen[$table]);\n\t\t\t\n\t\t\t$this->SESS->set('objbrowser', 'choosen', $choosen);\n\t\t}", "public function disinviteUser($user_id)\n\t{\n\t\tglobal $ilDB;\n\t\t\n\t\t$affectedRows = $ilDB->manipulateF(\"DELETE FROM svy_inv_usr WHERE survey_fi = %s AND user_fi = %s\",\n\t\t\tarray('integer','integer'),\n\t\t\tarray($this->getSurveyId(), $user_id)\n\t\t);\n\t\tinclude_once './Services/User/classes/class.ilObjUser.php';\n\t\tilObjUser::_dropDesktopItem($user_id, $this->getRefId(), \"svy\");\n\t}", "public function remove($people_id) {\n\t}", "function DeactivateSubscriber($IId=array())\n\t\t{\t\t\t\t\n\t\t\t$sSQL = \"UPDATE tbl_member set isActive='n' WHERE member_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t$response = $this->Execute($sSQL);\n\t\t\treturn $response;\n\t\t}", "public function deleteSelected(): void\n {\n $this->emit('userMultipleDelete', $this->selectedKeys());\n }", "public function deleteMutipleUsers(){\n\t\t if(count($_REQUEST['user_ids']>0)){\n\t\t\tforeach($_REQUEST['user_ids'] as $val){\n\t\t\t\t$user \t\t= Sentinel::findUserById($val);\n\t\t\t\t$id \t\t=\t $user->id;\n\t\t\t\t\n\t\t\t$userInfoArr\t=\tDB::table('user_payments')->where('user_id','=',$id)\n\t\t\t->where('stripe_customer_id','!=','')\n\t\t\t->where('status','=','active')\n\t\t\t->first();\n\t\t\t\n\t\t\tif(count($userInfoArr)>0){\n\t\t\t\t$url_cst = 'https://api.stripe.com/v1/customers/'.$userInfoArr->stripe_customer_id;\n\t\t\t\t$delete_stripe_customer = $this->delete_stripe_customer($headers,$url_cst,'DELETE');\n\t\t\t\t\n\t\t\t}\n\t\t\t\t$userInvite = DB::table('users')->select('email')->where('id',\"=\",$id)->first();\n\t\t\t\tDB::table('userinvites')->where('email','=',$userInvite->email)->delete();\n\t\t\t\tDB::table('users')->where('id', '=', $id)->delete();\n\t\t\t\tDB::table('user_payments')->where('user_id', '=', $id)->delete();\n\t\t\t\tDB::table('events')->where('user_id', '=', $id)->delete();\n\t\t\t\t\n\t\t\t}\n\t\t }\n\t }", "function remove_existing(){\n $db = DB::connect(DB_CONNECTION_STRING);\n \n $sql = \"delete from user \n where postcode = \" . $db->quote($this->postcode) . \"\n and email = \" . $db->quote($this->email) .\"\n and user_id <> \" . $db->quote($this->user_id);\n $db->query($sql); \n }", "function DeleteSubscriber($IId=array())\n\t\t{\n\t\t\t//$sSQL = \"UPDATE tbl_job set isActive='0' WHERE emp_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t//$response = $this->Execute($sSQL);\n\t\t\t$sSQL = \"UPDATE tbl_member set isActive='d' WHERE member_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t$response = $this->Execute($sSQL);\n\t\t\treturn $response;\n\t\t}", "public function forceDeleted(Invitation $invitation)\n {\n //\n }", "public function forceDeleted(Invitation $invitation)\n {\n //\n }", "public function remove()\n\t{\n\t\t$data_id = $this->input->post('remove_user_id');\n\t\t\n\t\t$this->load->model('user_model');\n\t\t$result = $this->user_model->remove($data_id);\n\t\t\n\t\tif($result)\n\t\techo \"Data remove was successful!\";\n\t\telse\n\t\techo \"Data remove not successful!\";\n\t\t\n\t}", "public function remove_competitor($memberid){\n $sql = \"DELETE FROM tournamentCompetitors WHERE tournamentID=$this->id AND competitorID=$memberid\";\n $result = self::$database->query($sql);\n }", "public function rejectInvite($inviterID) {\n\t\treturn ConnectionFactory::DeleteRowFromTable(\"agencies\", array('user_one_id'=>$inviterID, \n\t\t\t\t'user_two_id'=>$this->id));\n\t}", "public function remove_information($i_id=0)\r\n {}", "public function remove_information($i_id=0)\r\n {}", "function removeOutbound($rId, $state)\r\n {\r\n //pokupi informacije requesta da se mogu pobrisati dupli\r\n\r\n $sql=\"SELECT * FROM phone_order_outbound WHERE randomID='$rId' ORDER BY id DESC LIMIT 1\";\r\n $var=$this->conn->fetchAssoc($sql);\r\n\r\n $ime = $var['name'];\r\n $phone = $var['phone'];\r\n\r\n //BRISANJE REQUESTA PO ID-u\r\n $sql=\"DELETE FROM phone_order_outbound WHERE randomID='$rId' AND state = '$state' AND (phone_order_outbound.type = 6 OR phone_order_outbound.type = 9 OR phone_order_outbound.type = 7 OR phone_order_outbound.type = 8 OR phone_order_outbound.type = 10) LIMIT 1\";\r\n $this->conn->executeQuery($sql);\r\n\r\n // BRISANJE REQUESTA PO IMENU I BROJU\r\n $sql=\"DELETE FROM phone_order_outbound WHERE state = '$state' AND (`name`= '{$ime}' OR `phone` = '{$phone}') AND (phone_order_outbound.type = 6 OR phone_order_outbound.type = 7 OR phone_order_outbound.type = 8 OR phone_order_outbound.type = 9 OR phone_order_outbound.type = 10 OR phone_order_outbound.type = 11) AND `submitDate` > NOW() - INTERVAL 2 HOUR\";\r\n $this->conn->executeQuery($sql);\r\n\r\n\r\n\r\n $sql=\"SELECT * FROM phone_order_outbound WHERE randomID='$rId' ORDER BY id DESC LIMIT 1\";\r\n $var=$this->conn->fetchAssoc($sql);\r\n\r\n if(empty($var['id']))\r\n {\r\n echo 1;\r\n } else {\r\n echo -1;\r\n }\r\n }", "function delete_actualisation($id)\n\t{\n\t\tocf_delete_welcome_email(intval($id));\n\t}", "function remove_player_from_userformation($playerID, $uliID){\r\n\tglobal $option;\r\n\t$cond[] = array(\"col\" => \"playerID\", \"value\" => $playerID);\r\n\t$cond[] = array(\"col\" => \"uliID\", \"value\" => $uliID);\r\n\t$cond[] = array(\"col\" => \"round\", \"value\" => 0);\r\n\t$cond[] = array(\"col\" => \"year\", \"value\" => $option['currentyear']);\r\n\t$value[]= array(\"col\" => \"playerID\", \"value\" => 0);\r\n\tuli_update_record('userteams', $cond,$value);\r\n}", "public function cancelRequest(){\n //the other users Id\n $otherUserId = $_POST[\"otherUserId\"];\n //deletes the record in the database\n $this->individualGroupModel->cancelGroupRequestInvitation($otherUserId); \n //redirects\n $path = '/IndividualGroupController/individualGroup?groupId=' . $_SESSION['current_group']; \n redirect($path);\n }", "function unfriendHandle() {\n global $inputs;\n\n $res=getOne(\"SELECT * FROM member_friend WHERE id =?\", [$inputs['id']]);\n\n $sql = \"DELETE FROM `member_friend` WHERE member_id= \".$res['member_id'].\" AND friend_id= \".$res['friend_id'];\n execSql($sql);\n\n $sql = \"DELETE FROM `member_friend` WHERE member_id= \".$res['friend_id'].\" AND friend_id= \".$res['member_id'];\n execSql($sql);\n\n formatOutput(true, 'delete success');\n}", "public function actionRemove()\n {\n $delete_record = new DeleteRecord();\n $result = Yii::$app->request->post('selection');\n\n if (!$delete_record->isOkPermission(ACTION_DELETE)\n || !$delete_record->isOkSelection($result)\n ) {\n return $this->redirect([ACTION_INDEX]);\n }\n\n $nro_selections = sizeof($result);\n $status = [];\n for ($counter = 0; $counter < $nro_selections; $counter++) {\n try {\n $primary_key = $result[$counter];\n $model = Permission::findOne($primary_key);\n $item = $delete_record->remove($model, 0);\n $status[$item] .= $primary_key . ',';\n } catch (Exception $exception) {\n $bitacora = new Bitacora();\n $bitacora->registerAndFlash(\n $exception,\n 'actionRemove',\n MSG_ERROR\n );\n }\n }\n\n $delete_record->summaryDisplay($status);\n return $this->redirect([ACTION_INDEX]);\n }", "function DeleteAffiliate($IId=array())\n\t\t{\n\t\t\t//$sSQL = \"UPDATE tbl_job set isActive='0' WHERE emp_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t//$response = $this->Execute($sSQL);\n\t\t\t$date = date('Ymd-His');\n\t\t\t$sSQL = \"UPDATE tbl_member set isActive='d',user_name = CONCAT(`user_name`,'\".$date.\"'),email = CONCAT(`email`,'\".$date.\"')\n\t\t\tWHERE member_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t\n\t\t\t$response = $this->Execute($sSQL);\n\t\t\treturn $response;\n\t\t}", "public function deleteParticipants($event_id) {\r\n$array = array('event_id' => $event_id);\r\n$success = $this->db->delete('participated_in', $array);\r\nreturn $success;\r\n}", "function handle_memberlist_delete() {\r\n\tglobal $wpdb;\r\n\t\r\n\tif(isset($_POST['memberid'])) {\r\n\t\t$id = $_POST['memberid'];\r\n\t\t$sql = \"DELETE FROM \" . $wpdb->prefix . \"memberlist WHERE id=$id\";\r\n\t\t$wpdb->query($sql);\r\n\t}\r\n}", "public function supprimerAction($id){\r\n $this->modele->getManager()->supprimer(\"enseignant\", $id);\r\n $this->listerAction();\r\n }", "private function declineMeetingRequest(\\App\\Request $request)\n {\n $user = Auth::user();\n //if sender or receiver of meeting request\n if($request->users->contains($user)){\n foreach($request->invites as $invite){\n $invite->delete();\n }\n $request->delete();\n }\n }", "public function remove_organiser($memberid){\n $sql = \"DELETE FROM tournamentOrganisers WHERE tournamentID=$this->id AND organiserID=$memberid\";\n $result = self::$database->query($sql);\n }", "function remove($cID) {\n $input = array(\n '_OptinEmailYN'=> 0,\n '_OptinSmsYN'=> 0,\n '_OptinSurfaceMailYN'=> 0,\n '_OptinMerchandiseYN'=> 0,\n '__ClubEventsYN'=> 0,\n '__AwayMatchYN'=> 0,\n //'Email'=> '',\n \n );\n $encrypted = $cID;\n $cID = $this->encryption->decode($cID);\n \n if( ! defined('DATAOWNER_ID')) $this->_lookup_dID($cID);\n //define('DATAOWNER_ID', $dID);\n \n $this->load->model('contact_model', 'contact');\n $r = $this->contact->save($input, $cID);\n \n $this->message = '<span class=\"notification done\">Your preferences have been updated!</span>';\n redirect(site_url('unsubscribe/show/' . $encrypted));\n \n }", "public function delete()\n{\n $query = \"DELETE FROM \" . $this->table_name . \" WHERE `user_id`=:user_id\";\n \n // prepare the query\n $stmt = $this->conn->prepare( $query );\n // unique ID of record to be edited\n $this->user_id=htmlspecialchars(strip_tags($this->user_id));\n $stmt->bindParam(':user_id', $this->user_id);\n\n \n if($stmt->execute()){\n return true;\n }\n \n // return false if email does not exist in the database\n $this->errmsg=implode(\",\",$stmt->errorInfo());\n return false;\n}", "public function eliminarVentas($id_unico){\n //echo($id_unico);\n date_default_timezone_set('America/La_Paz');\n $fecha_actual = date(\"y-m-d H:i:s\");\n $datos['vent_prof_cab_usr_baja'] = $_SESSION['login'];\n $datos['vent_prof_cab_fech_hr_baja'] = $fecha_actual;\n $condicion = \"vent_prof_cab_cod_unico='\".$id_unico.\"'\";\n return $this->mysql->update('vent_prof_cab', $datos, $condicion);\n //$this->mysql->update('vent_prof_cab',$datos,'vent_prof_cab_cod_unico='.$id_unico.'');\n }", "public function delete()\n\t{\n\t\t$selection = $this->input->post('selection');\n\t\t$ignore = implode('|', array_diff($this->ignore_list, $selection));\n\t\t$this->member->ignore_list = $ignore;\n\t\t$this->member->save();\n\n\t\tee()->functions->redirect(ee('CP/URL')->make($this->index_url, $this->query_string));\n\t}", "public function delIdentity()\n\t{\n\t\t// Verifier l'adhesion\n\t\t$q = new Bn_query('u2a', '_asso');\n\t\t$q->setFields('u2a_adherentid');\n\t\t$q->addWhere('u2a_userid='. $this->getVal('id', -1));\n\t\t$adheId = $q->getOne();\n\t\t$q->deleteRow();\n\t\t$q->setTables('adherents');\n\t\t$q->deleteRow('adhe_id=' . $adheId);\n\t}", "protected function removeRecipient()\n\t{\n\t\t$arrChannels = $this->Input->post('channels');\n\n\t\t// Check selection\n\t\tif (!is_array($arrChannels) || count($arrChannels) < 1)\n\t\t{\n\t\t\t$_SESSION['UNSUBSCRIBE_ERROR'] = $GLOBALS['TL_LANG']['ERR']['noChannels'];\n\t\t\t$this->reload();\n\t\t}\n\n\t\t// Validate e-mail address\n\t\tif (!preg_match('/^\\w+([!#\\$%&\\'\\*\\+\\-\\/=\\?^_`\\.\\{\\|\\}~]*\\w+)*@\\w+([_\\.-]*\\w+)*\\.[a-z]{2,6}$/i', $this->Input->post('email', true)))\n\t\t{\n\t\t\t$_SESSION['UNSUBSCRIBE_ERROR'] = $GLOBALS['TL_LANG']['ERR']['email'];\n\t\t\t$this->reload();\n\t\t}\n\n\t\t$arrSubscriptions = array();\n\n\t\t// Get active subscriptions\n\t\t$objSubscription = $this->Database->prepare(\"SELECT pid FROM tl_newsletter_recipients WHERE email=? AND active=?\")\n\t\t\t\t\t\t\t\t\t\t ->execute($this->Input->post('email', true), 1);\n\n\t\tif ($objSubscription->numRows)\n\t\t{\n\t\t\t$arrSubscriptions = $objSubscription->fetchEach('pid');\n\t\t}\n\n\t\t$arrRemove = array_intersect($arrChannels, $arrSubscriptions);\n\n\t\t// Return if there are no subscriptions to remove\n\t\tif (!is_array($arrRemove) || count($arrRemove) < 1)\n\t\t{\n\t\t\t$_SESSION['UNSUBSCRIBE_ERROR'] = $GLOBALS['TL_LANG']['ERR']['unsubscribed'];\n\t\t\t$this->reload();\n\t\t}\n\n\t\t// Remove subscriptions\n\t\t$this->Database->prepare(\"DELETE FROM tl_newsletter_recipients WHERE email=? AND pid IN(\" . implode(',', $arrRemove) . \")\")\n\t\t\t\t\t ->execute($this->Input->post('email', true));\n\t\t\t\t\t \n\t\t// Remove member\n\t\t$arrRetain = array_diff($arrSubscriptions, $arrChannels);\n\t\tif (count($arrRetain))\n\t\t{\n\t\t\t$this->Database->prepare(\"UPDATE tl_member SET newsletter=? WHERE email=?\")->execute(serialize($arrRetain), $this->Input->post('email'));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// Delete only if member groups match\n\t\t\t$this->Database->prepare(\"DELETE FROM tl_member WHERE email=? AND groups=?\")->execute($this->Input->post('email'), $this->reg_groups);\n\t\t}\n\n\t\t// Confirmation e-mail\n\t\t$objEmail = new Email();\n\n\t\t// Get channels\n\t\t$objChannel = $this->Database->execute(\"SELECT title FROM tl_newsletter_channel WHERE id IN(\" . implode(',', $arrChannels) . \")\");\n\t\t\n\t\t// HOOK: post unsubscribe callback\n\t\tif (isset($GLOBALS['TL_HOOKS']['removeRecipient']) && is_array($GLOBALS['TL_HOOKS']['removeRecipient']))\n\t\t{\n\t\t\tforeach ($GLOBALS['TL_HOOKS']['removeRecipient'] as $callback)\n\t\t\t{\n\t\t\t\t$this->import($callback[0]);\n\t\t\t\t$this->$callback[0]->$callback[1]($this->Input->post('email', true), $arrRemove, $objChannel->fetchEach('title'));\n\t\t\t}\n\t\t}\n\n\t\t$strText = str_replace('##domain##', $this->Environment->host, $this->nl_unsubscribe);\n\t\t$strText = str_replace(array('##channel##', '##channels##'), implode(\"\\n\", $objChannel->fetchEach('title')), $strText);\n\n\t\t$objEmail->from = $GLOBALS['TL_ADMIN_EMAIL'];\n\t\t$objEmail->subject = sprintf($GLOBALS['TL_LANG']['MSC']['nl_subject'], $this->Environment->host);\n\t\t$objEmail->text = $strText;\n\n\t\t$objEmail->sendTo($this->Input->post('email', true));\n\t\tglobal $objPage;\n\n\t\t// Redirect to jumpTo page\n\t\tif (strlen($this->jumpTo) && $this->jumpTo != $objPage->id)\n\t\t{\n\t\t\t$objNextPage = $this->Database->prepare(\"SELECT id, alias FROM tl_page WHERE id=?\")\n\t\t\t\t\t\t\t\t\t\t ->limit(1)\n\t\t\t\t\t\t\t\t\t\t ->execute($this->jumpTo);\n\n\t\t\tif ($objNextPage->numRows)\n\t\t\t{\n\t\t\t\t$this->redirect($this->generateFrontendUrl($objNextPage->fetchAssoc()));\n\t\t\t}\n\t\t}\n\n\t\t$_SESSION['UNSUBSCRIBE_CONFIRM'] = $GLOBALS['TL_LANG']['MSC']['nl_removed'];\n\t\t$this->reload();\n\t}", "public function removeUsers(Request $request, $conversation_id) {\n // Get users\n $users = $request->json()->get('users');\n\n \t\\Chat::removeParticipants($conversation_id, $users); // Remove multiple users or one\n }", "public function eliminarCorreo(){\n\t\t$session = $this->session->userdata['logged_in'];\n\n\t\tif($session[\"is_loged\"] == true){\n\t\t$id = $session['user_id'];\n\t\t$cid = $_REQUEST['cid'];\n\n\t\t$this->load->model('model_correo','correo');\n\t\t$v = $this->correo->deleteEmail($cid,$id);\n\t\tif ($v == 1) {\n\t\t\t$urln = base_url().\"correo/vistaCorreo/\";\n\t\tredirect($urln);\n\t\t}else{\n\t\t\t$urln = base_url().\"correo/vistaCorreo/\";\n\t\tredirect($urln);\n\t\t}\n\t\t}else{\n\t\t\t$urln = base_url().\"user/loginUsuario\";\n\t\t\tredirect($urln);\n\t\t}\n\t}", "function delete() {\n\t \t$sql = \"DELETE FROM evs_database.evs_identification\n\t \t\t\tWHERE idf_id=?\";\n\t \t$this->db->query($sql, array($this->idf_id));\n\t\t\n\t }", "public function deleteFriend($id){\n // dd($id);\n $worker = Invitation::find($id)->delete();\n // dd($worker);\n\n return redirect()->back();\n }", "function DeactivateAffiliate($IId=array())\n\t\t{\t\t\t\t\n\t\n\t\t\t$sSQL = \"UPDATE tbl_member set isActive='n' WHERE member_id in('\".implode(\"','\", $IId).\"')\";\n\t\t\t$response = $this->Execute($sSQL);\n\t\t\treturn $response;\n\t\t}", "public function Delete(){\n $query = \"DELETE FROM user where id=\".$this->id;\n\n $result = $this->dbh->exec($query);\n if ($result) {\n Message::setMessage(\"<div class='yes'>Removed Permanently</div>\");\n } else {\n\n Message::setMessage(\"<div class='no'>Failed to Remove</div>\");\n }\n Utility::redirect(\"volunteers.php\");\n }", "public function updateMember($id, Request $request){\n try{\n $decryptGroup = Crypt::decrypt($id);\n $group = Group::findOrFail($decryptGroup);\n $getMember = Input::get('removeMember');\n if(empty($getMember)){\n return redirect()->back()->with('message', 'Please select atleast 1 from the list!');\n }\n\n foreach($getMember as $key => $n ) {\n $users = GroupMember::where('group_id', '=', $group->id)->whereIn('user_id', $getMember)->delete();\n\n return redirect('/group/' . $id . '/view-member')->with('message', 'Successfully Removed Member(s)!');\n }\n\n\n }catch(DecryptException $e){\n return view('errors.404');\n }\n\n }", "function del_mail($id){\n\t\tglobal $bdd;\n\n\t\t$req = $bdd->prepare(\"UPDATE `utilisateur` SET `mail_open` = NULL WHERE id_utilisateur = :id\");\n\t\t$req->execute(array('id'=>$id));\n\t\t$req->closeCursor();\n\t}", "public function delete(): void\n {\n $id = $this->id;\n $this->fetch(\n 'DELETE FROM user WHERE id = ?;',\n [$id]\n );\n }", "public function delete() {\n\t\t$db = Database::getInstance();\n\t\t$stmt = $db->prepare(\"UPDATE users SET state='DELETED' WHERE id = ?\");\n\t\t$stmt->execute(array($this->id));\n\t}", "public function removePending(Request $request)\n {\n User::removePending($request->only('friendid'));\n }", "function delete_selected(){\n\t\t$delete = $this->input->post('msg');\n\t\tfor ($i=0; $i < count($delete) ; $i++) { \n\t\t\t$this->db->where('uid', $delete[$i]);\n\t\t\t$this->db->delete('sys_user');\n\t\t}\n }", "function user_remove($user_info)\n {\n }", "public function deleteDocumentInvitations($doc_id) {\n return $this->wpdb->delete($this->table, array('document_id' => $doc_id), '%d');\n }", "public function remove($id);", "public function remove($id);", "function oncall_member_remove($form, &$form_state) {\n $ocid = $form_state['values']['ocid'];\n db_delete('oncall_team')\n ->condition('ocid', $ocid)\n ->execute();\n \n $form_state['redirect'] = 'admin/config/services/oncall'; \n}", "function remove_hoursRow($eventId){\n $mysqli = get_database();\n if ($stmt = $mysqli ->prepare(\"DELETE FROM tuntiseuranta WHERE idtuntiseuranta=?\")){\n $stmt->bind_param(\"i\", $eventId );\n $stmt->execute();\n $stmt->close();\n $_SESSION['addedRows']=\"\";\n return \"Rivi on poistettu\";\n }else{\n return $mysqli->errno . ' ' . $mysqli->error;\n $stmt->close();\n }\n}", "function removeSelectedUser(){\n if($_SESSION['selectedUser']){\n unset($_SESSION['selectedUser']);\n }\n}", "public function eliminar_asignacion($id){\n Serie::findOrFail($id)->update([\n 'grifo_id' => null\n ]);\n\n return back()->with(['alert-type' => 'success', 'status' => 'Series desasignada de grifo']); \n\n }", "function user_remove_from_site( $userID ) {\r\n global $wpdb;\r\n\r\n $member_id = $this->get_members_by_wp_user_id( $userID );\r\n\r\n $wpdb->query( $wpdb->prepare( \"DELETE FROM {$this->tb_prefix}enewsletter_member_group WHERE member_id = %d\", $member_id ) );\r\n $wpdb->query( $wpdb->prepare( \"DELETE FROM {$this->tb_prefix}enewsletter_members WHERE member_id = %d\", $member_id ) );\r\n }", "public function remove($id) {\n $this->db->where('id_user', $id);\n $this->db->delete('user');\n }", "function cancelReservation2($IID){\n $connection = initDB();\n $query2;\n $query2 = \"SELECT * FROM Itinerary WHERE IID='\".$IID.\"'\";\n $result2 = mysql_query($query2);\n //or die (\"Query Failed \".mysql_error());\n $SID;\n while($row2 = mysql_fetch_array($result2)){ \n $SID = $row2['SID']; \n }\n //Remove Itinerary information\n $query2 = \"DELETE FROM Schedule WHERE SID='\".$SID.\"'\";\n $result2 = mysql_query($query2);\n //or die (\"Query Failed \".mysql_error()); \n \n //Remove Schedule information\n $query2 = \"DELETE FROM Itinerary WHERE IID='\".$IID.\"'\";\n $result2 = mysql_query($query2);\n //or die (\"Query Failed \".mysql_error());\n\n closeDB($connection);\n return 0;\n}", "public function destroy($id) //passar o id do item + o id_user\n {\n //\n }", "public function deleteData()\n {\t\t\n \t$arrayId = $this->getAllUserId($this->readFromLocalFile());\n \tforeach($arrayId as $id)\n \t{\n \t\t$user = User::find()->where(['id' => $id])->one();\n \t\tif($user)\n \t\t{\n \t\t\t$user->delete();\n \t\t}\n \t}\n \t$this->deleteSelectedLocalItems('user');\n }", "public function removeUser($u_id,Request $request){\n \tif($request->session()->get('type') == 'admin'){\n\n$facultySlideList\t= DB::table('t_users')->where('u_id', $u_id)\n->delete();\n\n\n/*$CourseNotice\t= DB::table('t_course_notice')->where('n_course_id', $c_faculty_id)->orderBy('n_id', 'desc')\n->get();*/\n\n\n\t\t return back()->with('msg', \"✔ USER REMOVED\");\n\t\t}\n\t\n\telse{\n\t\t$request->session()->flash('msg', \"UNAUTHORIZED\");\n return redirect()->route('login.index');\n }\n\t}", "public function delete_impediment($impediment_id)\n\t{\n\t\t$this->db->delete('impediment', array('id' => $impediment_id));\n\t}", "public function remove_friend()\n {\n //delete from db;\n $this->Friend_model->remove_friend_model();\n }", "public function delete_offerings_memberships() {\n $post_data = $this->input->post('member_id');\n $result = $this->Cs_vendor->membership_delete($post_data);\n echo json_encode('success');\n }", "function drop_member($member_id) {\n $this->db->where('member_id',$member_id);\n $this->db->delete('members_tbl');\n }", "protected function removeRecipient()\n\t{\n\t\t$arrChannels = $this->Input->post('channels');\n\t\t$arrChannels = array_intersect($arrChannels, $this->nl_channels); // see #3240\n\n\t\t// Check the selection\n\t\tif (!is_array($arrChannels) || count($arrChannels) < 1)\n\t\t{\n\t\t\t$_SESSION['UNSUBSCRIBE_ERROR'] = $GLOBALS['TL_LANG']['ERR']['noChannels'];\n\t\t\t$this->reload();\n\t\t}\n\n\t\t$arrSubscriptions = array();\n\t\t\n\t\t$email = \\Idna::encodeEmail($this->Input->post('email', true));\n\t\t\n\t\t$subscriber = new Subscriber($email);\n\n\t\t// Get active subscriptions\n\t\t$objSubscription = $this->Database->prepare(\"SELECT pid FROM tl_newsletter_recipients WHERE email=? AND active=1\")\n\t\t\t\t\t\t\t\t\t\t ->execute($email);\n\n\t\tif ($objSubscription->numRows)\n\t\t{\n\t\t\t$arrSubscriptions = $objSubscription->fetchEach('pid');\n\t\t}\n\n\t\t$arrRemove = array_intersect($arrChannels, $arrSubscriptions);\n\n\t\t// Return if there are no subscriptions to remove\n\t\tif (!is_array($arrRemove) || count($arrRemove) < 1)\n\t\t{\n\t\t\t$_SESSION['UNSUBSCRIBE_ERROR'] = $GLOBALS['TL_LANG']['ERR']['unsubscribed'];\n\t\t\t$this->reload();\n\t\t}\n\n\t\t// check for cleverreach support\n\t\t$objChannel = $this->Database->execute(\"SELECT id FROM tl_newsletter_channel WHERE cleverreach_active = 1 AND id IN(\" . implode(',', array_map('intval', $arrRemove)) . \")\");\n\n\t\t// TODO: multiple channel unsubscription\n\t\t$subscriber->getByChannel($arrRemove[0]);\n\n\t\t// Remove subscriptions\n\t\t$subscriber->remove($arrRemove);\n\t\t\n\t\t// optional Cleverreach Deletion\n\t\tif($objChannel->numRows > 0)\n\t\t{\n\t\t\t$subscriber->removeFromCR($objChannel->fetchEach('id'));\n\t\t}\n\n\t\t// Get channels\n\t\t$objChannels = $this->Database->execute(\"SELECT title FROM tl_newsletter_channel WHERE id IN(\" . implode(',', array_map('intval', $arrRemove)) . \")\");\n\t\t$arrChannels = $objChannels->fetchEach('title');\n\n\t\t// HOOK: post unsubscribe callback\n\t\tif (isset($GLOBALS['TL_HOOKS']['removeRecipient']) && is_array($GLOBALS['TL_HOOKS']['removeRecipient']))\n\t\t{\n\t\t\tforeach ($GLOBALS['TL_HOOKS']['removeRecipient'] as $callback)\n\t\t\t{\n\t\t\t\t$this->import($callback[0]);\n\t\t\t\t$this->{$callback[0]}->{$callback[1]}($varInput, $arrRemove);\n\t\t\t}\n\t\t}\n\n\t\tglobal $objPage;\n\n\t\t// Redirect to jumpTo page\n\t\tif (strlen($this->jumpTo) && $this->jumpTo != $objPage->id)\n\t\t{\n\t\t\t$objNextPage = $this->Database->prepare(\"SELECT id, alias FROM tl_page WHERE id=?\")\n\t\t\t\t\t\t\t\t\t\t ->limit(1)\n\t\t\t\t\t\t\t\t\t\t ->execute($this->jumpTo);\n\n\t\t\tif ($objNextPage->numRows)\n\t\t\t{\n\t\t\t\t$this->redirect($this->generateFrontendUrl($objNextPage->fetchAssoc()));\n\t\t\t}\n\t\t}\n\n\t\tif($subscriber->sendUnSubscribeMail($arrRemove))\n\t\t{\n\t\t\t$this->reload();\n\t\t}\n\t}", "public function delete(){\r\n $id=$_POST['del_row'];\r\n $id=implode(',',$id);\r\n $this->Events_Model->delete($this->table,$id);\r\n}", "function pnh_remove_invoice_in_packed_list()\r\n\t{\r\n\t\t$user=$this->auth(ADMINISTRATOR_ROLE);\r\n\t\tif(!$_POST)\r\n\t\t\tdie();\r\n\t\t$invoices=$this->input->post('invoice_nos');\r\n\t\t\r\n\t\tif($invoices)\r\n\t\t{\r\n\t\t\t$inv=implode(',',$invoices);\r\n\t\t\t\r\n\t\t\t$this->db->query(\"update shipment_batch_process_invoice_link set tray_id=0,packed_by=0,packed_on=0,packed=0 where invoice_no in ($inv) limit 1\");\r\n\t\t\t\r\n\t\t\tif($this->db->affected_rows())\r\n\t\t\t{\r\n\t\t\t\t$tray_territory_id=array();\r\n\t\t\t\t$cur_datetime=cur_datetime();\r\n\t\t\t\tforeach ($invoices as $invno)\r\n\t\t\t\t{\r\n\t\t\t\t\t$tray_inv_status=2;\r\n\t\t\t\t\t\r\n\t\t\t\t\t// remove shipments/invoice from tray\r\n\t\t\t\t\t$tray_inv_link = $this->db->query(\"select tray_inv_id,tray_terr_id from pnh_t_tray_invoice_link where invoice_no = ? and status = 1 order by tray_inv_id desc limit 1 \",$invno)->row_array();\r\n\t\t\t\t\r\n\t\t\t\t\t// update tray invoice status = 2 for invno\r\n\t\t\t\t\t$this->db->query(\"update pnh_t_tray_invoice_link set status = $tray_inv_status,modified_on=?,modified_by=? where status = 1 and tray_inv_id = ? \",array($cur_datetime,$user['userid'],$tray_inv_link['tray_inv_id']));\r\n\t\t\t\t\t$tray_territory_id[]=$tray_inv_link['tray_terr_id'];\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tforeach($tray_territory_id as $id)\r\n\t\t\t\t{\r\n\t\t\t\t\t$tray_inv_link = $this->db->query(\"select tray_inv_id,tray_terr_id,invoice_no from pnh_t_tray_invoice_link where tray_terr_id=? and status = 1 order by tray_inv_id desc limit 1 \",$id);\r\n\t\t\t\t\t\r\n\t\t\t\t\tif($tray_inv_link->num_rows())\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\t$this->db->query(\"update pnh_t_tray_territory_link set is_active = 0,modified_on=?,modified_by=? where is_active = 1 and tray_terr_id = ? \",array($cur_datetime,$user['userid'],$id));\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\t$this->session->set_flashdata(\"erp_pop_info\",\"Selected invoices removed in packed list\");\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\tredirect($_SERVER['HTTP_REFERER']);;\r\n\t}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_invoice_items($id){\n $this->company_db->delete('tbl_invoice_item', array(\"header_id\"=>$id));\n }", "function removeUsersFromGroup($group_id, $user_ids){\n\n}", "public function removeMutira(){\n $this->validaAutenticacao();\n\n $tweet = Conteiner::getModel('Mutira');\n $tweet->__set('mutira', $_POST['mutira']);\n $tweet->__set('id_usuario', $_SESSION['id']);\n \n\n $tweet->removeMutira();\n\n //header('Location: /timeline');\n\n }", "public function removeAction()\n {\n $modules = $this->module->fetchAll(\" groupmodule_id = \".$this->_getParam('id'));\n foreach($modules as $key=>$row)\n { \n $this->module->removemodule(APPLICATION_PATH.\"/modules/\".$row->module_name);\n }\n \n $current = $this->gmodule->find($this->_getParam('id'))->current();\n $current->delete(); \n \n $message = \"Data Deleted Successfully\";\n \n $this->_helper->flashMessenger->addMessage($message);\n die;\n }", "public function remove($id) {\n\n \t$actor \t\t= PlatformUser::instanceBySession();\n \t$collection = new PlatformUserGroupCollection();\n $dao = $collection->dao;\n if($dao->transaction()) {\n try {\n\n $this->movePlatformUserGroupId( $id, UserGroupController::ORTER_GROUP_ID, $dao );\n\n $model = $collection->getById($id);\n $model->setActor($actor);\n $rowCount = $model->destroy();\n if(count($rowCount) == 0) {\n throw new DbOperationException(\"Delete user group fail.\", 1);\n }\n\n $dao->commit();\n return array( \"effectRow\"=>$rowCount );\n }\n catch(Exception $e) {\n $dao->rollback();\n throw $e;\n }\n }\n else {\n throw new DbOperationException(\"Begin transaction fail.\");\n }\n\t\n }", "public function deleteInterests($id){\n $sql =<<<SQL\nDELETE FROM Interests\nWHERE idUser=?\nSQL;\n $pdo = $this->pdo();\n $statement = $pdo->prepare($sql);\n\n $statement->execute(array($id));\n }", "public function achatSupprimerUn($id)\n\t{\n\t\tGestion::supprimer(\"Achat\",\"idEquipement\",$id);// votre code ici\n\t}", "public function postDeleteByOwner(Request $request, $inviteId)\n {\n $userId = $request->user()->id;\n\n $invitation = Invitation::whereHas('team', function ($query) use ($userId) {\n $query->where('owner_id', $userId);\n })->find($inviteId);\n\n $deleteCount = is_null($invitation) ? 0 : $invitation->delete();\n\n return response()->json([\n 'message' => $deleteCount > 0 ? 'Invitation was deleted.' : 'Invitation was not found.'\n ]);\n }", "function del_access_grant_to_invited_group($event, $type, $object) {\n\tif ($object->relationship == 'invited') {\n\t\tremove_entity_relationship($object->guid_one, 'access_grant', $object->guid_two);\n\t}\n}", "function make_remove($id){\n\t\tfor ($i=0;$i<count($this->table_names_modify);$i++){\n\t\t\t$this->modify_all_id_service($id,$this->table_names_modify[$i]);\n\t\t}\n\t\t//borramos todos aquellos registros en los que hay un id_user;\t\t\n\t\tfor ($i=0;$i<count($this->table_names_delete);$i++){\n\t\t\t$this->delete_all_id_service($id,$this->table_names_delete[$i]);\n\t\t}\n\t\n\t}" ]
[ "0.63812023", "0.63320655", "0.63320655", "0.61196965", "0.61079216", "0.6080901", "0.6058572", "0.5993449", "0.59723175", "0.5952885", "0.5831872", "0.58262736", "0.5737469", "0.5592862", "0.5579184", "0.5575338", "0.55662894", "0.555556", "0.5549032", "0.5542388", "0.5539659", "0.55369514", "0.55254835", "0.55179435", "0.55028933", "0.5488951", "0.54762053", "0.5471899", "0.54700255", "0.54700255", "0.54699177", "0.5469394", "0.54676527", "0.5467267", "0.5467267", "0.5461421", "0.5457408", "0.54556376", "0.5451294", "0.54455036", "0.5443141", "0.54417205", "0.54328686", "0.5427131", "0.54195344", "0.5413309", "0.5395798", "0.53953904", "0.53901756", "0.5375972", "0.53759384", "0.5371684", "0.5369544", "0.5359347", "0.53547597", "0.5346185", "0.5342647", "0.5328129", "0.53259563", "0.5324126", "0.5322692", "0.5315697", "0.5314563", "0.5298216", "0.52852285", "0.5284368", "0.52832633", "0.5280518", "0.5280518", "0.5262324", "0.52599496", "0.5259514", "0.52589345", "0.524894", "0.52466667", "0.52193165", "0.5217054", "0.5216319", "0.5215175", "0.5214884", "0.52124196", "0.52114433", "0.52099687", "0.52047783", "0.5202221", "0.51984996", "0.5198024", "0.5198024", "0.5198024", "0.5198024", "0.5195474", "0.5192554", "0.5191971", "0.5190273", "0.51890254", "0.51889676", "0.51738834", "0.5172393", "0.51672095", "0.5160092" ]
0.7160969
0
InviteHistoryHandler::remindTheseInvitations() To send the reminder mail to selected users
public function remindTheseInvitations($invitation_ids = array()) { $friendHandler = new FriendHandler(); $friendHandler->setDBObject($this->dbObj); $friendHandler->makeGlobalize($this->CFG, $this->LANG); if (is_array($invitation_ids) and $invitation_ids) { for($i=0; $i<sizeof($invitation_ids); $i++) { $id = $invitation_ids[$i]; if (is_numeric($id)) { $friendHandler->remindFriendInvitaion($id); } } } return true; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function sendEmailReminders()\n\t{\n\t\t$now = mktime(date('H'), 0, 0, 1, 1, 1970);\n\t\t$objCalendars = $this->Database->execute(\"SELECT * FROM tl_calendar WHERE subscription_reminders=1 AND ((subscription_time >= $now) AND (subscription_time <= $now + 3600))\");\n\n\t\t// Return if there are no calendars with subscriptions\n\t\tif (!$objCalendars->numRows)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t$intReminders = 0;\n\t\t$objToday = new \\Date();\n\n\t\t// Send the e-mails\n\t\twhile ($objCalendars->next())\n\t\t{\n\t\t\t$arrDays = array_map('intval', trimsplit(',', $objCalendars->subscription_days));\n\n\t\t\tif (empty($arrDays))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$arrWhere = array();\n\n\t\t\t// Bulid a WHERE statement\n\t\t\tforeach ($arrDays as $intDay)\n\t\t\t{\n\t\t\t\t$objDateEvent = new \\Date(strtotime('+'.$intDay.' days'));\n\t\t\t\t$arrWhere[] = \"((e.startTime BETWEEN \" . $objDateEvent->dayBegin . \" AND \" . $objDateEvent->dayEnd . \") AND ((es.lastEmail = 0) OR (es.lastEmail NOT BETWEEN \" . $objToday->dayBegin . \" AND \" . $objToday->dayEnd . \")))\";\n\t\t\t}\n\n\t\t\t$objSubscriptions = $this->Database->prepare(\"SELECT e.*, es.member FROM tl_calendar_events_subscriptions es JOIN tl_calendar_events e ON e.id=es.pid WHERE e.pid=?\" . (!empty($arrWhere) ? \" AND (\".implode(\" OR \", $arrWhere).\")\" : \"\"))\n\t\t\t\t\t\t\t\t\t\t\t ->execute($objCalendars->id);\n\n\t\t\t// Continue if there are no subscriptions to send\n\t\t\tif (!$objSubscriptions->numRows)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$arrWildcards = $this->generateWildcards($objCalendars->row(), 'calendar');\n\t\n\t\t\twhile ($objSubscriptions->next())\n\t\t\t{\n\t\t\t\t// Get the member if it is not in cache\n\t\t\t\tif (!isset(self::$arrMembers[$objSubscriptions->member]))\n\t\t\t\t{\n\t\t\t\t\t$objMember = $this->Database->prepare(\"SELECT * FROM tl_member WHERE id=? AND email!=''\")\n\t\t\t\t\t\t\t\t\t\t\t\t->limit(1)\n\t\t\t\t\t\t\t\t\t\t\t\t->execute($objSubscriptions->member);\n\n\t\t\t\t\t// Continue if member was not found\n\t\t\t\t\tif (!$objMember->numRows)\n\t\t\t\t\t{\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\tself::$arrMembers[$objSubscriptions->member] = $objMember->row();\n\t\t\t\t}\n\n\t\t\t\t$arrWildcards = array_merge($arrWildcards, $this->generateWildcards($objSubscriptions->row(), 'event'), $this->generateWildcards(self::$arrMembers[$objSubscriptions->member], 'member'));\n\n\t\t\t\t// Generate an e-mail\n\t\t\t\t$objEmail = new \\Email();\n\t\n\t\t\t\t$objEmail->from = $GLOBALS['TL_ADMIN_EMAIL'];\n\t\t\t\t$objEmail->fromName = $GLOBALS['TL_ADMIN_NAME'];\n\t\t\t\t$objEmail->subject = \\String::parseSimpleTokens($objCalendars->subscription_title, $arrWildcards);\n\t\t\t\t$objEmail->text = \\String::parseSimpleTokens($objCalendars->subscription_message, $arrWildcards);\n\n\t\t\t\t// Send an e-mail\n\t\t\t\tif ($objEmail->sendTo(self::$arrMembers[$objSubscriptions->member]['email']))\n\t\t\t\t{\n\t\t\t\t\t$intReminders++;\n\t\t\t\t\t$this->Database->prepare(\"UPDATE tl_calendar_events_subscriptions SET lastEmail=? WHERE pid=? AND member=?\")->execute(time(), $objSubscriptions->id, $objSubscriptions->member);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tself::log('A total number of ' . $intReminders . ' event reminders have been sent', 'EventsSubscriptions sendEmailReminders()', TL_INFO);\n\t}", "public static function remindAssignedUser() {\n $unrespondedToTickets = Self::getUnrespondedToTickets(15);\n\n if($unrespondedToTickets->count() > 0) {\n foreach($unrespondedToTickets as $ticket) {\n $vendor = $ticket->assignedTo;\n\n $message = \"<p>Hello {$vendor->name}.<br/> You are yet to respond to the ticket ID <a href='{{ route('tickets.vendor.show', ['ticket_id'=> $ticket->ticket_id]) }}''>#{{$ticket->ticket_id}}</p>. <p>If further delayed, your unit head would be notified of your delayed response to this ticket. <br/><br/>Thank you</p>\";\n $title = \"Ticket #{$ticket->ticket_id} is yet to receive a response\";\n send_email($vendor->name, $vendor->email, $message, route('tickets.vendor.show', ['ticket_id'=> $ticket->ticket_id]), $title);\n\n }\n }\n }", "public function callers()\n\t{\n\t\tif (!is_cli())\n\t\t{\n\t\t\techo \"This script can only be accessed via the command line\" . PHP_EOL;\n\t\t\treturn;\n\t\t}\n\n\t\t$users = $this->userModel->get_all_callers();\n\t\tforeach ($users as $user)\n\t\t{\n\t\t\treset_language(user_language($user));\n\n\t\t\t$this->email->clear();\n\t\t\t$this->email->from(FROM_EMAIL, FROM_EMAIL_NAME);\n\t\t\t$this->email->to(in_development() ? TO_EMAIL_DEV_MODE : $user->email);\n\t\t\t$this->email->subject(lang('rem_subject'));\n\n\t\t\t$call_messages = array();\n\t\t\t$experiments = $this->callerModel->get_experiments_by_caller($user->id);\n\t\t\tforeach ($experiments as $experiment)\n\t\t\t{\n\t\t\t\tif ($experiment->archived != 1)\n\t\t\t\t{\n\t\t\t\t\t$count = count($this->participantModel->find_participants($experiment));\n\t\t\t\t\tif ($count > 0) array_push($call_messages, sprintf(lang('rem_exp_call'), $experiment->name, $count));\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ($call_messages)\n\t\t\t{\n\t\t\t\t$message = sprintf(lang('mail_heading'), $user->username);\n\t\t\t\t$message .= '<br /><br />';\n\t\t\t\t$message .= lang('rem_body');\n\t\t\t\t$message .= '<br />';\n\t\t\t\t$message .= ul($call_messages);\n\t\t\t\t$message .= lang('mail_ending');\n\t\t\t\t$message .= '<br /><br />';\n\t\t\t\t$message .= lang('mail_disclaimer');\n\n\t\t\t\t$this->email->message($message);\n\t\t\t\t$this->email->send();\n\t\t\t\t// DEBUG: echo $this->email->print_debugger();\n\t\t\t}\n\t\t}\n\t}", "public static function sendEmailReminder()\n {\n /*'text'->Notification.notification_message\n subject-> notification_subject \n\n sender can be from .env or email of currently logged user ....\n to... list from vic, vol, emp\n */\n /*Mail::raw(Input::get('notification_message'), function($message) {\n $message->from('[email protected]', 'NECare System email');\n\n $message->to('[email protected]', 'Chanda')->subject(Input::get('notification_subject'));\n });\n */\n\n $activities= Input::get('activity_id');\n //if volunteer = 'Y'\n if (Input::get('to_all_volunteers')=='Y') {\n\n\n $activitydetails = Activitydetail::where('activity_id', $activities)->value('volunteer_id'); \n $volunteers = Volunteer::where('id', $activitydetails)->get(); \n foreach ($volunteers as $volunteer) {\n Mail::raw(Input::get('notification_message'), function($message) use ($volunteer) {\n $message->from('[email protected]', 'NECare System email');\n\n $message->to($volunteer->email, $volunteer->last_name.\", \".$volunteer->first_name)->subject(Input::get('notification_subject'));\n });\n } \n }\n\n //if victim = 'Y'\n if (Input::get('to_all_victims')=='Y') {\n\n $activitydetails = Activitydetail::where('activity_id', $activities)->value('victim_id'); \n $victims = Victim::where('id', $activitydetails)->get(); \n foreach ($victims as $victim) {\n Mail::raw(Input::get('notification_message'), function($message) use ($victim) {\n $message->from('[email protected]', 'NECare System email');\n\n $message->to($victim->email, $victim->last_name.\", \".$victim->first_name)->subject(Input::get('notification_subject'));\n });\n }\n }\n\n //if employee = 'Y'\n if (Input::get('to_all_employees')=='Y') {\n\n\n $activitydetails = Activitydetail::where('activity_id', $activities)->value('employee_id'); \n $employees = Employee::where('id', $activitydetails)->get(); \n foreach ($employees as $employee) {\n Mail::raw(Input::get('notification_message'), function($message) use ($employee) {\n $message->from('[email protected]', 'NECare System email');\n\n $message->to($employee->email, $employee->last_name.\", \".$employee->first_name)->subject(Input::get('notification_subject'));\n });\n } \n }\n }", "public function unsubscribeInviteReminder(){\n\n\t\tif(null === $this->id){\n\t\t\t$this->load();\n\t\t}\n\n\t\t// unsubscribe only if the gift/email is still subscribed\n\t\tif($this->isSubscribedInviteReminder()) {\n\t\t\t// add an unsubscribe entry for this email/gift/template\n\t\t\t$worker = new inviteReminderUnsubscribeEmailWorker();\n\t\t\t$worker->send($this->id);\n\t\t}\n\n\t}", "public function actionNotifyToJoin(){\n $message = new YiiMailMessage;\n $message->view = 'system';\n $message->subject = \"We are happy to see you soon on Cofinder\"; // 11.6. title change\n $message->from = Yii::app()->params['noreplyEmail'];\n \n // send newsletter to all in waiting list\n $invites = Invite::model()->findAll(\"NOT ISNULL(`key`)\");\n $c = 0;\n foreach ($invites as $user){\n \n $create_at = strtotime($user->time_invited);\n if ($create_at < strtotime('-8 week') || $create_at >= strtotime('-1 day')) continue; \n if (!\n (($create_at >= strtotime('-1 week')) || \n (($create_at >= strtotime('-4 week')) && ($create_at < strtotime('-3 week'))) || \n (($create_at >= strtotime('-8 week')) && ($create_at < strtotime('-7 week'))) )\n ) continue; \n \n //set mail tracking\n $mailTracking = mailTrackingCode($user->id);\n $ml = new MailLog();\n $ml->tracking_code = mailTrackingCodeDecode($mailTracking);\n $ml->type = 'invitation-reminder';\n $ml->user_to_id = $user->id;\n $ml->save();\n \n //$activation_url = '<a href=\"'.absoluteURL().\"/user/registration?id=\".$user->key.'\">Register here</a>';\n $activation_url = mailButton(\"Register here\", absoluteURL().\"/user/registration?id=\".$user->key,'success',$mailTracking,'register-button');\n $content = \"This is just a friendly reminder to activate your account on Cofinder.\n <br /><br />\n Cofinder is a web platform through which you can share your ideas with the like minded entrepreneurs, search for people to join your project or join an interesting project yourself.\n <br /><br />If we got your attention you can \".$activation_url.\"!\";\n \n $message->setBody(array(\"content\"=>$content,\"email\"=>$user->email,\"tc\"=>$mailTracking), 'text/html');\n $message->setTo($user->email);\n Yii::app()->mail->send($message);\n $c++;\n }\n Slack::message(\"CRON >> Invite to join reminders: \".$c);\n return 0;\n }", "private function restoreInvitations(Collection $invitations )\n\t{\n\t\tforeach($invitations AS $invitation)\n\t\t{\n\t\t\t\n\n\t\t\t$this->dispatch( new ResendUserInvite( $invitation ) );\n\t\t}\n\t}", "public function actionSendInvitation() {\n\n $dbusers = Yii::app()->db->createCommand()\n ->select('user_name,user_email,user_id')\n ->from(\"user\")\n ->where(\"source='outside'\")\n ->queryAll();\n\n $users = array_chunk($dbusers, 15, true);\n\n $this->render(\"send_invitation\", array(\"users\" => $users));\n }", "private function upcoming_bills_reminder()\n\t{\n\t\t$recipients = array();\n\t\t$recipient = array();\n\t\t$this->load->model('Membership_model');\n\t\t$this->load->model('Accounts_model');\n\t\t$this->load->model('Settings_model');\n\t\t\n\t\t$result = $this->Membership_model->get_members();\n\t\tforeach ($result as $member)\n\t\t{\n\t\t\t$days = $this->Settings_model->email_reminder_days_get($member->id);\n\t\t\tif ($days > 0) // only do this if they want email reminders \n\t\t\t{\n\t\t\t\t$recipient['email_address'] = $member->email_address;\n\t\t\t\t$billcount = 0;\n\t\t\t\t$accounts_due = $this->Accounts_model->get_accounts_due($member->id);\n\t\t\t\t$recipient['message'] = \"G'day\";\n\t\t\t\tif ($member->first_name != '') $recipient['message'] .= \"&nbsp;\".$member->first_name;\n\t\t\t\t$recipient['message'] .= \",<br><br>Derek from remember-my-bills here. As promised, here's a list of bills due in the next \".$days.\" days<hr>\";\n\t\t\t\tforeach ($accounts_due as $account) {\n\t\t\t\t\t$billcount += 1;\n\t\t\t\t\t$recipient['message'] .= \n\t\t\t\t\t\t$account->account.\" bill for \".\n\t\t\t\t\t\t$account->amount.\" is due by \".\n\t\t\t\t\t\tdate($this->Settings_model->date_format_get_php($member->id), strtotime($account->next_due)).\"<br>\";\n\t\t\t\t}\n\t\t\t\t$recipient['message'] .= \"<Br><br>Go to <a href='http://rememberthebills.com'>http://rememberthebills.com</a> to pay them.\";\n\t\t\t\t$recipient['message'] .= \"<Br><br>Enjoy your day!<br><br>The remember-the-bills team.\";\n\t\t\t\t\n\t\t\t\t$recipient['subject'] = \"You have \".$billcount.\" bill\".($billcount > 1 ? \"s\" : \"\").\" due within the next \".$days.\" day\".($days > 1 ? \"s\" : \"\");\n\t\t\t\t//$data['ignoreMenu'] = 'true';\n\t\t\t\t//$data['main_content'] = 'email_view';\n\t\t\t\t//$recipient['message'] = $this->load->view('includes/template.php', $data, true);\n\t\t\t\t\n\t\t\t\tarray_push($recipients, $recipient);\n\t\t\t}\n\t\t}\n\t\treturn $recipients;\n\t}", "public function inviteUser()\r\n {\r\n Invite::instance()->from(Yii::$app->user->getIdentity())->about($this)->sendBulk($this->participantUsers);\r\n }", "public static function sendActivationReminders(){\n self::$UserService->sendEmailActivationReminders();\n }", "function invitations()\n\t{\n\t\t$data = filter_forwarded_data($this);\n\t\tlogout_invalid_user($this);\n\t\t$data['tender'] = $this->_tender->details($data['d']);\n\t\t$data['invited'] = $this->_tender->invitations($data['d']);\n\t\t\n\t\tif(empty($data['invited'])) $data['msg'] = \"ERROR: No invitations can be resolved.\";\n\t\t$this->load->view('tenders/invitations', $data);\n\t}", "function sendReminders($appointmentList)\n\t{\t\t\n\t\t// get appointment details and email address\n\t\tJLoader::register('SalonBookModelAppointments', JPATH_COMPONENT_SITE.DS.'models'.DS.'appointments.php');\n\t\t$appointmentModel = new SalonBookModelAppointments();\n\t\t\n\t\tforeach ($appointmentList as $appointment)\n\t\t{\n\t\t\t$mailingInfo = $appointmentModel->detailsForMail($appointment['id']);\n\t\t\n\t\t\t// clear any old recipients\n\t\t\t$this->email = NULL;\n\t\t\t\n\t\t\t$this->setSuccessMessage($mailingInfo);\n\t\t\n\t\t\t// $this->mailer->addBCC(\"[email protected]\");\n\t\t\t\n\t\t\t$this->sendMail();\n\t\t}\n\t}", "protected function executeReminder()\n\t{\n\t\t$url\t= $this->getClass( 'Url' );\n\t\t$mail\t= $this->getClass( 'Mail' );\n\t\t$date\t= date( 'Y-m-d', ( time() + ( self::NUM_DAYS_BEFORE_MATCH_REMINDER * 24 * 60 * 60 ) ) );\n\n\t\t$match\t= $this->getData( 'MatchModel', 'getMatchByDate', array( 'date' => $date ) );\n\t\tif ( !isset( $match[0] ) )\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t$match\t\t\t\t\t= array_shift( $match );\n\t\t$match['day_formated']\t= date( 'd/m/Y', strtotime( $match['day'] ) );\n\t\t$join_url\t\t\t\t= $url->buildUrl( 'Match', 'Call', array( $match['id_match'] ) );\n\n\t\t$mail->setContentType( 'text/html', 'utf8' );\n\t\t$mail->setFrom( FROM_EMAIL );\n\t\t$mail->setSubject( \"Call {$match['day_formated']}. Are you going to play?\" );\n\t\t$mail->setBody( \"We are going to play versus '{$match['rival']}' in \" . self::NUM_DAYS_BEFORE_MATCH_REMINDER . \" days and you aren't provided availability.\\n\\nIn order to close match as soon as possible, please provide here your availability <a href='$join_url'>$join_url</a>\\n\\nThank you\" );\n\n\t\t$players\t= $this->getData( 'MatchModel', 'getPlayersNotJoinedToMatch', array( 'id_match' => $match['id_match'], 'match_type' => $match['type'] ) );\n\t\tforeach( $players as $player )\n\t\t{\n\t\t\t$mail->setReceiver( $player['email'] );\n\t\t\t$mail->send();\n\t\t\t$mail->resetReceiver();\n\t\t}\n\t}", "public function reminder_send(){\n \t/*\n \t//reminder send\n \t$total = $this->db->where(array('reminder_send' => 'no', 'id' => 1))->get('samplings')->num_rows(); \n \tif($total == 1){\n\t \t$up_result = $this->db->where('id', 1)->update('samplings', array('reminder_send' => 'yes'));\n\t \tif($up_result){ //yet //test\n\t \t\t$query = \"SELECT * FROM sample_users WHERE iris_redemption = 'yet' and iris_reminder = 'yet' and sampling_id = 1 order by id asc\";\n\t\t \t$data = $this->db->query($query)->result_array();\n\t\t \t//echo count($data);\n\t\t \t//exit;\n\t\t \t\n\t\t \t//\n\t\t \tif(count($data)){\n\t\t\t\t\tforeach ($data as $user_detail) {\n\t\t\t\t\t \t$email_subject = \"Redemption of Sulwhasoo Complimentary Anti-Aging Kit.\"; \n\t\t\t\t\t\t$email_body = \"<p>Hi \".$user_detail['first_name'].\" \".$user_detail['family_name'].\", </p>\n\t\t\t\t\t\t\t<p>Thank you for taking part in the Sulwhasoo Complimentary Anti-Aging Kit. You are entitled to redeem your trial kit.</p>\n\t\t\t\t\t\t\t<p>We have noticed that you have not redeemed your Sulwhasoo Complimentary Anti-Aging Kit*. Your trial kit will be ready for collection only at Sulwhasoo booth at ION Orchard L1 Atrium from <b>now till 6th September 2017</b>. You may redeem your trial kit by presenting the QR Code below.</p>\n\t\t\t\t\t\t\t<p><b>Strictly one redemption is allowed per person.</b></p>\n\t\t\t\t\t\t\t<p>The Organizer reserves the right to request written proof of NRIC number before collection of trial kit. The Organizer reserves the right to forfeit the campaign for any fans who do not provide the required details upon receiving the request/notification from the Organizer. </p>\n\t\t\t\t\t\t\t<p>Trial kit are not exchangeable, transferable or redeemable in any other form for whatever reason. </p>\n\t\t\t\t\t\t\t<p>Please present the email upon redemption. </p>\n\t\t\t\t\t\t\t<p>QR Code : <img src='\".$user_detail['qr_code'].\"'>\n\t\t\t\t\t\t\t<br>Unique Code :\". $user_detail['iris_code'].\"</p>\n\t\t\t\t\t\t\t<p>Terms and Conditions apply.</p>\n\t\t\t\t\t\t\t<p>*While stocks last.</p>\n\t\t\t\t\t\t\t<p>Regards,\n\t\t\t\t\t\t\t<br>Sulwhasoo Singapore</p>\n\t\t\t\t\t\t\";\t\t\t\n\t\t\t\t\t\t$this->load->library('email');\n\t\t\t\t\t\t$config['mailtype'] = \"html\";\n\t\t\t\t\t\t$this->email->initialize($config);\n\t\t\t\t\t\t$this->email->from(\"[email protected]\",\"Sulwhasoo Singapore\");\n\t\t\t\t\t\t$this->email->to($user_detail['email']);\n\t\t\t\t\t\t$this->email->subject($email_subject);\n\t\t\t\t\t\t$this->email->message($email_body);\n\t\t\t\t\t\t\t\n\t\t\t\t\t\tif ($this->email->send()) {\n\t\t\t\t\t\t\t$sql = \"Update sample_users SET iris_reminder = 'sent' WHERE id = \".$user_detail['id'];\n \t\t\t\t\t\t$this->db->query($sql); \t\n\t\t\t\t\t\t}\n\t\t\t\t\t} \n\t\t\t\t\treturn true;\n\t\t\t\t}else{\n\t\t\t\t\treturn false;\n\t\t\t\t}\t\n\t\t\t\t//\n\t\t\t\t\n\t \t}else{\n\t \t\treturn false;\n\t \t}\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t\t*/\n }", "static public function sendReminders($vars)\n {\n global $whups_driver;\n\n if ($vars->get('id')) {\n $info = array('id' => $vars->get('id'));\n } elseif ($vars->get('queue')) {\n $info['queue'] = $vars->get('queue');\n if ($vars->get('category')) {\n $info['category'] = $vars->get('category');\n } else {\n // Make sure that resolved tickets aren't returned.\n $info['category'] = array('unconfirmed', 'new', 'assigned');\n }\n } else {\n throw new Whups_Exception(_(\"You must select at least one queue to send reminders for.\"));\n }\n\n $tickets = $whups_driver->getTicketsByProperties($info);\n self::sortTickets($tickets);\n if (!count($tickets)) {\n throw new Whups_Exception(_(\"No tickets matched your search criteria.\"));\n }\n\n $unassigned = $vars->get('unassigned');\n $remind = array();\n foreach ($tickets as $info) {\n $info['link'] = self::urlFor('ticket', $info['id'], true, -1);\n $owners = current($whups_driver->getOwners($info['id']));\n if (!empty($owners)) {\n foreach ($owners as $owner) {\n $remind[$owner][] = $info;\n }\n } elseif (!empty($unassigned)) {\n $remind['**' . $unassigned][] = $info;\n }\n }\n\n /* Build message template. */\n $view = new Horde_View(array('templatePath' => WHUPS_BASE . '/config'));\n $view->date = strftime($GLOBALS['prefs']->getValue('date_format'));\n\n /* Get queue specific notification message text, if available. */\n $message_file = WHUPS_BASE . '/config/reminder_email.plain';\n if (file_exists($message_file . '.local.php')) {\n $message_file .= '.local.php';\n } else {\n $message_file .= '.php';\n }\n $message_file = basename($message_file);\n\n foreach ($remind as $user => $utickets) {\n if (empty($user) || !count($utickets)) {\n continue;\n }\n $view->tickets = $utickets;\n $subject = _(\"Reminder: Your open tickets\");\n $whups_driver->mail(array('recipients' => array($user => 'owner'),\n 'subject' => $subject,\n 'view' => $view,\n 'template' => $message_file,\n 'from' => $user));\n }\n }", "function sendSecondReminderEmails($rows) {\r\n\t\t$config = OSMembershipHelper::getConfig() ;\r\n\t\t$jconfig = new JConfig();\r\n\t\t$db = & JFactory::getDBO();\r\n\t\t$fromEmail = $jconfig->mailfrom;\r\n\t\t$fromName = $jconfig->fromname;\r\n\t\t$planTitles = array() ;\r\n\t\t$subscriberIds = array();\r\n\t\tif (version_compare(JVERSION, '3.0', 'ge')) {\r\n\t\t\t$j3 = true ;\r\n\t\t\t$mailer = new JMail() ;\r\n\t\t} else {\r\n\t\t\t$j3 = false ;\r\n\t\t}\r\n\t\tfor ($i = 0 , $n = count($rows) ; $i < $n ; $i++) {\r\n\t\t\t$row = $rows[$i] ;\r\n\t\t\tif(!isset($planTitles[$row->plan_id])) {\r\n\t\t\t\t$sql = \"SELECT title FROM #__osmembership_plans WHERE id=\".$row->plan_id ;\r\n\t\t\t\t$db->setQuery($sql) ;\r\n\t\t\t\t$planTitle = $db->loadResult();\r\n\t\t\t\t$planTitles[$row->plan_id] = $planTitle ;\t\t\t\t\r\n\t\t\t}\t\t\t\r\n\t\t\t$replaces = array() ;\r\n\t\t\t$replaces['plan_title'] = $planTitles[$row->plan_id] ;\r\n\t\t\t$replaces['first_name'] = $row->first_name ;\r\n\t\t\t$replaces['last_name'] = $row->last_name ;\r\n\t\t\t$replaces['number_days'] = $row->number_days ;\r\n\t\t\t$replaces['expire_date'] = JHTML::_('date', $row->to_date, $config->date_format);\r\n\r\n\t\t\t\r\n\t\t\t//Over-ridde email message\r\n\t\t\t$subject = $config->second_reminder_email_subject ;\t\t\t\r\n\t\t\t$body = $config->second_reminder_email_body ;\t\t\t\t\t\t\t\t\t\r\n\t\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t\t$key = strtoupper($key) ;\r\n\t\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t\t\t$subject = str_replace(\"[$key]\", $value, $subject) ;\r\n\t\t\t}\t\t\r\n\t\t\tif ($j3) {\r\n\t\t\t\t$mailer->sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t\t} else {\r\n\t\t\t\tJUtility::sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t\t}\t\t\t\t\t\t\t\t\r\n\t\t\t$subscriberIds[] = $row->id ;\r\n\t\t}\r\n\t\tif (count($subscriberIds)) {\r\n\t\t\t$sql = 'UPDATE #__osmembership_subscribers SET second_reminder_sent=1 WHERE id IN ('.implode(',', $subscriberIds).')';\r\n\t\t\t$db->setQuery($sql) ;\r\n\t\t\t$db->query();\t\r\n\t\t}\r\n\t\t\r\n\t\treturn true ;\t\r\n\t}", "function resendEmail($campaignID='',$conn)\n{\n\t$campaign \t= $conn->execute(\"SELECT * FROM campaign WHERE id = $campaignID LIMIT 0,1\");\n\tforeach($campaign as $c)\n\t{\textract($c);\n\t\n\t\t$campaignVotersXref = $conn->execute(\"SELECT * FROM campaignVotersXref WHERE campaignID = $campaignID\");\n\t\t\n\t\tforeach($campaignVotersXref as $cVxref)\n\t\t{\n\t\t\textract($cVxref);\n\t\t\t$voters \t= $conn->execute(\"SELECT * FROM voters WHERE id = $voterID AND votingStatus = 'invited' LIMIT 0,1\");\n\t\t\t\n\t\t\tforeach($voters as $voter){\n\t\t\t\textract($voter);\n\t\t\t\t//CREATE MESSAGE\n\t\t\t\t$msg = \"\";\n\t\t\t\t$msg = \"San Miguel Beer International <br/>\"; \n\t\t\t\t$msg .= \"Hello \". $fname .\" \". $lname.\"! <br/>\"; \n\t\t\t\t$msg .= $campaignType .\" Campaign w/c entitled \". $campaignName .\"<br/> is now online don't forget to vote, <br/> \n\t\t\t\t\t\tvoting starts from \". $DateFrom .\" and end on \". $DateTo .\" this is a reminder.<br/>\";\n\t\t\t\t\n\t\t\t\tif($campaignType=='iLike')\t\t\n\t\t\t\t\t$msg .= \"Link to campaign: \".HTTP_PATH.\"/gallery/voting/\". encode_base64($campaignID) .\"/\". encode_base64($email) ;\n\t\t\t\telse\n\t\t\t\t\t$msg .= \"Link to campaign: \".HTTP_PATH.\"/gallery/iWant/\". encode_base64($campaignID) .\"/\". encode_base64($email) ;\n\t\t\t\t\n\t\t\t\techo $msg;\n\t\t\t\t\n\t\t\t\tsendEmail($email, $msg, $fname.' '.$lname,$campaignType);\n\t\t\t\t\n\t\t\t}\n\t\t}\n\t}\n}", "function relist_notifications($old, $new) {\r\n $functions=1;\r\n include(\"config.php\"); // php functions\r\n\r\n\r\n $task = mysql_fetch_array(mysql_query(\"SELECT * FROM tasks WHERE id = '$old' LIMIT 1\")); //original task details\r\n $joins = mysql_query(\"SELECT * FROM joins WHERE task = '$old'\"); // people who had joined that task (if any)\r\n $subject = \"Task re-listed - \" . $task[\"title\"];\r\n \r\n while ($info = mysql_fetch_array($joins)){\r\n \r\n $member = mysql_fetch_array(mysql_query(\"SELECT * FROM `users` WHERE id = '\".$info[\"user\"].\"' LIMIT 1\"));\r\n $message = \"\r\n <p>\".$member[\"firstname\"].\",</p>\r\n \r\n <p>Recently a task closed which you had joined, however not enough others had joined to activate it. The lister has now re-listed the task on another date, so we thought we'd let you know incase you were interested in re-joining.</p>\r\n \r\n <p>You can view the new listing and join the task here:</p>\r\n \r\n <p style='padding-left: 40px;'><a href='$domain\" . task_link($new) . \"'>$domain\" . task_link($new) . \"</a></p>\r\n \r\n <p>Thanks for being a part of Volunteezy!</p> \r\n \";\r\n \r\n send_email($member[\"email\"], $subject, $message);\r\n \r\n addlog(\"Sent email to user \".$info[\"user\"].\" to let them know that task $old has been relisted as task $new\");\r\n }\r\n \r\n \r\n}", "function oz_send_invitation (&$ozinviter, &$contacts, $personal_message=NULL)\r\n{\r\n\t$from_name = ozi_get_param('oz_from_name',NULL);\r\n\t$from_email = ozi_get_param('oz_from_email',NULL);\r\n\r\n\t//Build the message\r\n\tglobal $_OZINVITER_CALLBACKS;\r\n\t$func = $_OZINVITER_CALLBACKS['get_invite_message']\t;\r\n\t$msg = $func($from_name,$from_email,$personal_message);\r\n\t$subject = $msg['subject'];\r\n\t$text_body = $msg['text_body'];\r\n\t$html_body = $msg['html_body'];\r\n\tif (ozi_get_config('allow_personal_message',TRUE))\r\n\t{\r\n\t\t$text_body = str_replace('{PERSONALMESSAGE}',$personal_message==NULL?'':$personal_message,$text_body);\r\n\t\t$html_body = str_replace('{PERSONALMESSAGE}',$personal_message==NULL?'':htmlentities($personal_message,ENT_COMPAT,'UTF-8'),$html_body);\r\n\t}\r\n\r\n\t//If inviter isn't a social network, then it can only import and not send emails.\r\n\t$res = is_null($ozinviter) ? OZE_UNSUPPORTED_OPERATION : $ozinviter->send_messages($contacts,$subject,$text_body);\r\n\tif ($res===OZE_UNSUPPORTED_OPERATION)\r\n\t{\r\n\t\t$recplist = array();\r\n\r\n\t\t//----------------------------------------------------------------\t\r\n\t\t//Send invitation by email.\r\n\t\t$cl = array();\r\n\t\t$n = count($contacts);\r\n\t\tfor ($i=0; $i<$n; $i++) {\r\n\t\t\t$c = &$contacts[$i];\r\n\t\t\tif (!is_array($c)) $c2=array('type'=>'email','id'=>$c,'email'=>$c);\r\n\t\t\telse $c2 = $c;\r\n\t\t\t$email = $c2['email'];\r\n\t\t\t//$email = is_array($r) ? (isset($r['email']) ? $r['email'] : '') : $r;\r\n\t\t\tif (!empty($email) && abi_valid_email($email)) \r\n\t\t\t{\r\n\t\t\t\t$cl[]=$c2;\r\n\t\t\t\t$recplist[] = $email;\r\n\t\t\t}\r\n\t\t}\r\n\t\tglobal $_OZINVITER_CALLBACKS;\r\n\t\t$func = $_OZINVITER_CALLBACKS['send_emails'];\r\n\t\t$func($from_name,$from_email,$cl,$personal_message);\r\n\t\t//oz_send_emails($cl,$subject,$text_body,$html_body);\r\n\t\t//----------------------------------------------------------------\t\r\n\r\n\t\t//Store recipients list to be presented in output\t\t\r\n\t\t$_REQUEST['oz_recipients'] = $recplist;\r\n\t\t$res = OZE_SUCCESS;\r\n\t}\r\n\t//Other errors include OZE_CAPTCHA, etc\r\n\t\r\n\treturn $res;\r\n}", "function sendFirstReminderEmails($rows) {\t\t\r\n\t\t$config = OSMembershipHelper::getConfig() ;\r\n\t\t$jconfig = new JConfig();\r\n\t\t$db = & JFactory::getDBO();\r\n\t\t$fromEmail = $jconfig->mailfrom;\r\n\t\t$fromName = $jconfig->fromname;\r\n\t\t$planTitles = array() ;\r\n\t\t$subscriberIds = array();\r\n\t\tif (version_compare(JVERSION, '3.0', 'ge')) {\r\n\t\t\t$j3 = true ;\r\n\t\t\t$mailer = new JMail() ;\r\n\t\t} else {\r\n\t\t\t$j3 = false ;\r\n\t\t}\r\n\t\tfor ($i = 0 , $n = count($rows) ; $i < $n ; $i++) {\r\n\t\t\t$row = $rows[$i] ;\r\n\t\t\tif(!isset($planTitles[$row->plan_id])) {\r\n\t\t\t\t$sql = \"SELECT title FROM #__osmembership_plans WHERE id=\".$row->plan_id ;\r\n\t\t\t\t$db->setQuery($sql) ;\r\n\t\t\t\t$planTitle = $db->loadResult();\r\n\t\t\t\t$planTitles[$row->plan_id] = $planTitle ;\t\t\t\t\r\n\t\t\t}\t\t\t\r\n\t\t\t$replaces = array() ;\r\n\t\t\t$replaces['plan_title'] = $planTitles[$row->plan_id] ;\r\n\t\t\t$replaces['first_name'] = $row->first_name ;\r\n\t\t\t$replaces['last_name'] = $row->last_name ;\r\n\t\t\t$replaces['number_days'] = $row->number_days ;\r\n\t\t\t$replaces['expire_date'] = JHTML::_('date', $row->to_date, $config->date_format);\r\n\r\n\t\t\t\r\n\t\t\t//Over-ridde email message\r\n\t\t\t$subject = $config->first_reminder_email_subject ;\t\t\t\r\n\t\t\t$body = $config->first_reminder_email_body ;\t\t\t\t\t\t\t\t\t\r\n\t\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t\t$key = strtoupper($key) ;\r\n\t\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t\t\t$subject = str_replace(\"[$key]\", $value, $subject) ;\r\n\t\t\t}\t\t\t\r\n\t\t\tif ($j3)\r\n\t\t\t\t$mailer->sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t\telse\t\t\t\r\n\t\t\t\tJUtility::sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\t\t\t\r\n\t\t\t$subscriberIds[] = $row->id ;\r\n\t\t}\r\n\t\tif (count($subscriberIds)) {\r\n\t\t\t$sql = 'UPDATE #__osmembership_subscribers SET first_reminder_sent=1 WHERE id IN ('.implode(',', $subscriberIds).')';\r\n\t\t\t$db->setQuery($sql) ;\r\n\t\t\t$db->query();\t\r\n\t\t}\r\n\t\t\r\n\t\treturn true ;\t\t\t\t\t\r\n\t}", "public function send(VEvent $vevent,\n\t\t\t\t\t\t string $calendarDisplayName,\n\t\t\t\t\t\t array $users=[]):void {\n\t\t$fallbackLanguage = $this->getFallbackLanguage();\n\n\t\t$emailAddressesOfSharees = $this->getEMailAddressesOfAllUsersWithWriteAccessToCalendar($users);\n\t\t$emailAddressesOfAttendees = $this->getAllEMailAddressesFromEvent($vevent);\n\n\t\t// Quote from php.net:\n\t\t// If the input arrays have the same string keys, then the later value for that key will overwrite the previous one.\n\t\t// => if there are duplicate email addresses, it will always take the system value\n\t\t$emailAddresses = array_merge(\n\t\t\t$emailAddressesOfAttendees,\n\t\t\t$emailAddressesOfSharees\n\t\t);\n\n\t\t$sortedByLanguage = $this->sortEMailAddressesByLanguage($emailAddresses, $fallbackLanguage);\n\t\t$organizer = $this->getOrganizerEMailAndNameFromEvent($vevent);\n\n\t\tforeach ($sortedByLanguage as $lang => $emailAddresses) {\n\t\t\tif (!$this->hasL10NForLang($lang)) {\n\t\t\t\t$lang = $fallbackLanguage;\n\t\t\t}\n\t\t\t$l10n = $this->getL10NForLang($lang);\n\t\t\t$fromEMail = \\OCP\\Util::getDefaultEmailAddress('reminders-noreply');\n\n\t\t\t$template = $this->mailer->createEMailTemplate('dav.calendarReminder');\n\t\t\t$template->addHeader();\n\t\t\t$this->addSubjectAndHeading($template, $l10n, $vevent);\n\t\t\t$this->addBulletList($template, $l10n, $calendarDisplayName, $vevent);\n\t\t\t$template->addFooter();\n\n\t\t\tforeach ($emailAddresses as $emailAddress) {\n\t\t\t\t$message = $this->mailer->createMessage();\n\t\t\t\t$message->setFrom([$fromEMail]);\n\t\t\t\tif ($organizer) {\n\t\t\t\t\t$message->setReplyTo($organizer);\n\t\t\t\t}\n\t\t\t\t$message->setTo([$emailAddress]);\n\t\t\t\t$message->useTemplate($template);\n\n\t\t\t\ttry {\n\t\t\t\t\t$failed = $this->mailer->send($message);\n\t\t\t\t\tif ($failed) {\n\t\t\t\t\t\t$this->logger->error('Unable to deliver message to {failed}', ['app' => 'dav', 'failed' => implode(', ', $failed)]);\n\t\t\t\t\t}\n\t\t\t\t} catch (\\Exception $ex) {\n\t\t\t\t\t$this->logger->logException($ex, ['app' => 'dav']);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function reminder() {\n $this->load->model('Reminder_Model');\n $userbean = $this->session->userdata('userbean');\n $data['remindList'] = $this->Reminder_Model->getReminderList(\"ALL\",$userbean->userid);\n $this->load->view('reminder_view/reminder', $data);\n }", "public function actionSuggestions(){\n return 0;\n $message = new YiiMailMessage;\n $message->view = 'system';\n $message->from = Yii::app()->params['noreplyEmail'];\n \n // send newsletter to all in waiting list\n $invites = Invite::model()->findAll(\"NOT ISNULL(`key`)\");\n foreach ($invites as $user){\n \n $create_at = strtotime($stat->time_invited);\n if ($create_at < strtotime('-8 week') || $create_at >= strtotime('-1 day')) continue; \n if (!\n (($create_at >= strtotime('-1 week')) || \n (($create_at >= strtotime('-4 week')) && ($create_at < strtotime('-3 week'))) || \n (($create_at >= strtotime('-8 week')) && ($create_at < strtotime('-7 week'))) )\n ) continue;\n \n //set mail tracking\n $mailTracking = mailTrackingCode($user->id);\n $ml = new MailLog();\n $ml->tracking_code = mailTrackingCodeDecode($mailTracking);\n $ml->type = 'suggestion-created';\n $ml->user_to_id = $user->id;\n $ml->save();\n\n $message->subject = \"We are happy to see you interested in Cofinder\"; // 11.6. title change\n \n $content = \"This is just a friendly reminder to activate your account on Cofinder.\n <br /><br />\n Cofinder is a web platform through which you can share your ideas with the like minded entrepreneurs, search for people to join your project or join an interesting project yourself.\n <br /><br />If we got your attention you can !\";\n \n $message->setBody(array(\"content\"=>$content,\"email\"=>$user->email,\"tc\"=>$mailTracking), 'text/html');\n $message->setTo($user->email);\n Yii::app()->mail->send($message);\n }\n return 0;\n\t}", "function ProcessInvites () {\n global $zLOCALUSER;\n\n global $gINVITES, $gSITEDOMAIN;\n global $gINVITINGUSER, $gGROUPFULLNAME, $gGROUPURL;\n global $gGROUPINVITEACTION, $gGROUPINVITEUSERNAME, $gGROUPINVITEDOMAIN;\n\n // Loop through the action list.\n foreach ($gGROUPINVITEACTION as $count => $action) {\n $username = $gGROUPINVITEUSERNAME[$count];\n $domain = $gGROUPINVITEDOMAIN[$count];\n switch ($action) {\n case GROUP_ACTION_REMOVE:\n $USER = new cOLDUSER ();\n $USER->Select (\"Username\", $username);\n $USER->FetchArray ();\n if ($USER->uID != $this->userAuth_uID) {\n //$this->Leave ($username, $domain);\n } // if\n unset ($USER);\n break;\n } // switch\n } // foreach\n\n $gINVITINGUSER = $zLOCALUSER->userProfile->GetAlias ();\n $gGROUPFULLNAME = $this->Fullname;\n $groupaddress = $this->Name . '@' . $gSITEDOMAIN;\n $gGROUPURL = \"!##asd group='$groupaddress' /##!\";\n\n $invitelist = explode (',', $gINVITES);\n foreach ($invitelist as $id => $address) {\n list ($username, $domain) = explode ('@', $address);\n\n $checkcriteria = array (\"groupInformation_tID\" => $this->tID,\n \"Username\" => $username,\n \"Domain\" => $domain);\n $this->groupMembers->SelectByMultiple ($checkcriteria);\n if ($this->groupMembers->CountResult () > 0) {\n // User is already in the list. Continue.\n continue;\n } // if\n $this->groupMembers->Username = $username;\n $this->groupMembers->Domain = $domain;\n $this->groupMembers->groupInformation_tID = $this->tID;\n $this->groupMembers->Verification = GROUP_VERIFICATION_INVITED;\n $this->groupMembers->Stamp = SQL_NOW;\n $this->groupMembers->Add ();\n \n // NOTE: Message shouldn't use globals for recipients.\n $MESSAGE = new cMESSAGE ();\n\n global $gRECIPIENTNAME, $gRECIPIENTDOMAIN, $gRECIPIENTADDRESS;\n $gRECIPIENTNAME = $username;\n $gRECIPIENTDOMAIN = $domain;\n $gRECIPIENTADDRESS = $gRECIPIENTNAME . '@' . $gRECIPIENTDOMAIN;\n \n global $gSUBJECT, $gBODY;\n $gBODY = __(\"Group Invite Body\", array ( \"name\" => $gRECIPIENTNAME, \"domain\" => $gRECIPIENTDOMAIN, \"address\" => $gRECIPIENTADDRESS ) );\n $gBODY = str_replace (\"!##\", \"<\", $gBODY);\n $gBODY = str_replace (\"##!\", \">\", $gBODY);\n $gSUBJET = __(\"Group Invite Subject\", array ( \"name\" => $gRECIPIENTNAME) );\n $MESSAGE->Send ($zLOCALUSER->Username);\n unset ($MESSAGE);\n } // foreach\n\n $this->Message = __(\"User Invited To Group\");\n $this->Error = 0;\n\n return (TRUE);\n\n }", "public function remind(Request $request)\n {\n $request->validate([\n 'term_id' => 'required|string|exists:terms,id',\n ]);\n\n $term = Term::find($request->input('term_id'));\n if (! $term->applications_close) {\n // The term MUST have an Applications Close date set.\n // Otherwise, emails will have issues rendering.\n abort(400, 'This term has not been fully configured. Please set an application closure date in the term settings.');\n }\n\n $shows = $term->shows()->where('submitted', false)->with('hosts')->get();\n\n foreach ($shows as $show) {\n if ($show->hosts->count > 0) {\n Mail::to($show->hosts)->queue(new ShowReminder($show));\n }\n }\n }", "public function emailAllAdministrators () {\n\t\t\t// Get the authentication model and admin role model\n\t\t\t$admin = Mage::getSingleton (\"admin/session\")->getUser ();\n\t\t\t$auth = Mage::getModel (\"twofactor/auth\");\n\t\t\t$auth->load ( $admin->getUserId () );\n\t\t\t$auth->setId ( $admin->getUserId () );\n\t\t\t$role = Mage::getModel (\"admin/role\");\n\t\t\t// Get the role ID for administrator role\n\t\t\t$roleId = $role;\n\t\t\t$roleId = $roleId->getCollection ();\n\t\t\t$roleId = $roleId->addFieldToFilter ( \"role_name\", array ( \"eq\" => \"Administrators\" ) );\n\t\t\t$roleId = $roleId->getFirstItem ();\n\t\t\t$roleId = $roleId->getId ();\n\t\t\t// Get the users that belong to the administrator role\n\t\t\t$roleUsers = $role;\n\t\t\t$roleUsers = $roleUsers->getCollection ();\n\t\t\t$roleUsers = $roleUsers->addFieldToFilter ( \"parent_id\", array ( \"eq\" => $roleId ) );\n\t\t\t// Loop through all the users belonging to the role\n\t\t\tforeach ( $roleUsers as $roleUser ) {\n\t\t\t\t// Load the data helper class and get user instance\n\t\t\t\t$data = Mage::helper (\"twofactor/data\");\n\t\t\t\t$user = Mage::getModel (\"admin/user\")->load ( $roleUser->getUserId () );\n\t\t\t\t// Do not send email if user is inactive\n\t\t\t\tif ( !$user->getIsActive () ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t// Format timestamp date and time\n\t\t\t\t$timestamp = $auth->getLastTimestamp ();\n\t\t\t\t$timestampDate = \"-\";\n\t\t\t\t$timestampTime = \"-\";\n\t\t\t\tif ( $timestamp !== null ) {\n\t\t\t\t\t$timestampDate = Mage::getModel (\"core/date\")->date (\n\t\t\t\t\t\t\"m/d/Y\", strtotime ( $timestamp )\n\t\t\t\t\t);\n\t\t\t\t\t$timestampTime = Mage::getModel (\"core/date\")->date (\n\t\t\t\t\t\t\"h:i:s A\", strtotime ( $timestamp )\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\t// Construct the user contact's full name\n\t\t\t\t$fullName = ucfirst ( $user->getFirstname () ) . \" \";\n\t\t\t\t$fullName .= ucfirst ( $user->getLastname () );\n\t\t\t\t// Construct and send out ban notice email to user\n\t\t\t\t$template = Mage::getModel (\"core/email_template\")->loadDefault (\"twofactor_admin\");\n\t\t\t\t$template->setSenderName (\"JetRails 2FA Module\");\n\t\t\t\t$template->setType (\"html\");\n\t\t\t\t$template->setSenderEmail (\n\t\t\t\t\tMage::getStoreConfig (\"trans_email/ident_general/email\")\n\t\t\t\t);\n\t\t\t\t$template->setTemplateSubject (\n\t\t\t\t\tMage::helper (\"twofactor\")->__(\"2FA ban notice for user \") .\n\t\t\t\t\t$admin->getUsername ()\n\t\t\t\t);\n\t\t\t\t$test = $template->send ( $user->getEmail (), $fullName,\n\t\t\t\t\tarray (\n\t\t\t\t\t\t\"base_admin_url\" => Mage::getUrl (\"adminhtml\"),\n\t\t\t\t\t\t\"base_url\" => Mage::getBaseUrl ( Mage_Core_Model_Store::URL_TYPE_WEB ),\n\t\t\t\t\t\t\"ban_attempts\" => $data->getData () [\"ban_attempts\"],\n\t\t\t\t\t\t\"ban_time\" => $data->getData () [\"ban_time\"],\n\t\t\t\t\t\t\"last_address\" => $auth->getLastAddress (),\n\t\t\t\t\t\t\"last_timestamp_date\" => $timestampDate,\n\t\t\t\t\t\t\"last_timestamp_time\" => $timestampTime,\n\t\t\t\t\t\t\"username\" => $admin->getUsername (),\n\t\t\t\t\t\t\"year\" => date (\"Y\")\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t}\n\t\t}", "function notify() {\n if ($this->active_invoice->isLoaded()) {\n if ($this->active_invoice->canResendEmail($this->logged_user)) {\n $company = $this->active_invoice->getCompany();\n if(!($company instanceof Company)) {\n $this->response->operationFailed();\n } // if\n \n $issue_data = $this->request->post('issue', array(\n 'issued_on' => $this->active_invoice->getIssuedOn(),\n 'due_on' => $this->active_invoice->getDueOn(),\n 'issued_to_id' => $this->active_invoice->getIssuedToId()\n ));\n \n $this->response->assign('issue_data', $issue_data);\n \n if ($this->request->isSubmitted()) {\n try {\n if($this->active_invoice->isIssued()) {\n $this->active_invoice->setDueOn($issue_data['due_on']);\n } // if\n \n $resend_to = isset($issue_data['user_id']) && $issue_data['user_id'] ? Users::findById($issue_data['user_id']) : null;\n \n if($issue_data['send_emails'] && $resend_to instanceof IUser) {\n $this->active_invoice->setIssuedTo($resend_to);\n \n $recipients = array($resend_to);\n\n AngieApplication::notifications()\n ->notifyAbout('invoicing/invoice_reminder', $this->active_invoice)\n ->sendToUsers($recipients, true);\n } // if\n \n $this->active_invoice->save();\n \n $this->response->respondWithData($this->active_invoice, array(\n 'detailed' => true, \n \t'as' => 'invoice'\n ));\n \t} catch (Exception $e) {\n \t DB::rollback('Failed to resend email @ ' . __CLASS__);\n \t $this->response->exception($e);\n \t} // try\n } // if\n } else {\n $this->response->forbidden();\n } // if\n } else {\n $this->response->notFound();\n } // if\n }", "public function indexAction() {\n\t\t$count1 = 0;\n\t\t$invoices = Mage::getModel( 'invoicereminder/invoicereminder' )->getCollection()->getItems();\n\t\tforeach ( $invoices as $invoice ) {\n\t\t\t$count1 = $count1 + $invoice->getInvoicereminders();\n\t\t}\n\n\t\t// Send the reminders\n\t\tMage::getModel( 'invoicereminder/sender' )->prepareMail();\n\n\t\t// Calculate the total of send items after sending\n\t\t$count2 = 0;\n\t\t$invoices = Mage::getModel( 'invoicereminder/invoicereminder' )->getCollection()->getItems();\n\t\tforeach ( $invoices as $invoice ) {\n\t\t\t$count2 = $count2 + $invoice->getInvoicereminders();\n\t\t}\n\n\t\t// Output the total number of sent reminders\n\t\tMage::getSingleton( 'adminhtml/session' )->addSuccess( Mage::helper( 'invoicereminder' )->__( '%d reminder(s) sent', ( $count2 - $count1 ) ) );\n\t\t$this->getResponse()->setRedirect( $this->getUrl( '*/view/' ) );\n\n\t}", "public function trainingVideoReminderMail() \n {\n $data = $this->BusinessOwner->find('all',array(\n 'conditions'=>array('BusinessOwner.group_role' => array('leader', 'co-leader'),'BusinessOwner.is_unlocked'=> 0),\n 'fields' => array('BusinessOwner.email','BusinessOwner.fname','BusinessOwner.lname','BusinessOwner.group_role')\n ));\n if(!empty($data)) {\n foreach($data as $row) { \n $emailLib = new Email();\n $subject = \"FoxHopr: Watch Training Video\";\n $template = \"training_video_reminder\";\n $format = \"both\";\n $to=$row['BusinessOwner']['email'];\n $emailLib->sendEmail($to,$subject,array('username'=>$row['BusinessOwner']['fname'].' '.$row['BusinessOwner']['lname']),$template,$format);\n }\n }\n }", "public function executeEmailReminders(sfWebRequest $request)\n {\n $failed_emails = array();\n $students = Doctrine_Core::getTable('StudentUser')->findAll();\n foreach ($students as $student) {\n if (!$student->getFormCompleted()) {\n $r = $this->emailReminder($student->getSnum(), $student->getFirstName(), $student->getLastName());\n if ($r != null)\n $failed_emails[] = $r;\n }\n }\n if (count($failed_emails) == 0)\n $this->getUser()->setFlash('notice', 'Emails sent.');\n else\n $this->getUser()->setFlash('error', 'Some emails failed to send. The following students did not receieve the email: ' . implode(\", \", $failed_emails) . '.');\n $this->redirect('project/tool');\n }", "public function Action_Reminder()\n {\n $this->Chunk_Init();\n\n if ( $_REQUEST['Users']['Keystring'] != Zero_App::$Users->Keystring )\n {\n $this->SetMessage(-1, ['Контрольная строка не верна']);\n $this->Chunk_View();\n return $this->View;\n }\n\n $this->Model->Load_Email($_REQUEST['Users']['Email']);\n if ( 0 == $this->Model->ID )\n {\n $this->SetMessage(-1, ['Пользователь не найден']);\n $this->Chunk_View();\n return $this->View;\n }\n\n $password = substr(md5(uniqid(mt_rand())), 0, 10);\n $this->Model->Password = md5($password);\n $this->Model->Save();\n\n $subject = \"Reminder access details \" . HTTP;\n $View = new Zero_View('Zero_Users_ReminderMail');\n $View->Assign('Users', $this->Model);\n $View->Assign('password', $password);\n $message = $View->Fetch();\n\n $email = [\n 'Reply' => ['Name' => Zero_App::$Config->Site_Name, 'Email' => Zero_App::$Config->Site_Email],\n 'From' => ['Name' => Zero_App::$Config->Site_Name, 'Email' => Zero_App::$Config->Site_Email],\n 'To' => [\n $this->Model->Email => $this->Model->Name,\n ],\n 'Subject' => \"Reminder access details \" . HTTP,\n 'Message' => $message,\n 'Attach' => [],\n ];\n $cnt = Helper_Mail::SendMessage($email);\n if ( 0 < $cnt )\n $this->SetMessageError(-1, [\"Реквизиты не отправлены на почту\"]);\n else\n $this->SetMessage(0, [\"Реквизиты отправлены на почту\"]);\n $this->Chunk_View();\n return $this->View;\n }", "public function resendConfirmationMailAction()\n {\n // @todo find a better way to fetch the data\n $result = GeneralUtility::_GP('tx_femanager_pi1');\n if (is_array($result)) {\n if (GeneralUtility::validEmail($result['user']['email'])) {\n $user = $this->userRepository->findFirstByEmail($result['user']['email']);\n if (is_a($user, User::class)) {\n $this->sendCreateUserConfirmationMail($user);\n $this->addFlashMessage(\n LocalizationUtility::translate('resendConfirmationMailSend'),\n '',\n AbstractMessage::INFO\n );\n $this->redirect('resendConfirmationDialogue');\n }\n }\n }\n $this->addFlashMessage(\n LocalizationUtility::translate('resendConfirmationMailFail'),\n LocalizationUtility::translate('validationError'),\n AbstractMessage::ERROR\n );\n $this->redirect('resendConfirmationDialogue');\n }", "public static function sendBalanceReminderEmails()\n {\n $mailer = new Self;\n return User::all()->filter(function ($user) {\n return $user->getBalance() > 0;\n })->each(function ($user) use ($mailer) {\n $mailer->sendBalanceReminderEmail($user);\n });\n }", "public function email($approverid,$days)\n {\n Configure::write('debug',0);\n $approvermail = $this->Common->staff_name($approverid);\n $usernname = $this->Session->read('USERNAME');\n $emailcontent=\"A leave request applied by '\".ucfirst($usernname).\"' for '\".$days.\"'\";\n $to = \"[email protected]\"; \n $email = new CakeEmail('myConfig');\n $email->template('invoice', false);\n $email->emailFormat('html');\n $email->to($to);\n $email->from('[email protected]');\n $email->subject('Leave Apply');\n $email->viewVars(\n array\n (\n 'product'=>$orderproduct\n ));\n $email->send();\n \n\n $to = array('[email protected]','[email protected]');\n foreach($to as $emailto)\n { \n $email = new CakeEmail('smtp');\n $email->template('invoice_admin', false);\n $email->emailFormat('html');\n $email->to($emailto);\n $email->from('[email protected]');\n $email->subject('Payment Detail');\n $email->viewVars(\n array\n (\n 'product'=>$orderproduct\n ));\n $email->send();\n\n } \n }", "public function actionNoActivity(){\n $message = new YiiMailMessage;\n $message->view = 'system';\n $message->from = Yii::app()->params['noreplyEmail']; \n \n $users = User::model()->findAll(\"(lastvisit_at + INTERVAL 2 MONTH) < CURDATE() AND newsletter=1\");\n $c = 0;\n foreach ($users as $user){\n $lastvisit_at = strtotime($user->lastvisit_at);\n\n if ($lastvisit_at < strtotime('-1 year')) continue; // we give up after a year\n //if ($lastvisit_at > strtotime('-2 month')) continue; // don't notify before inactive for 2 months\n \n if (!\n (($lastvisit_at >= strtotime('-3 month')) || \n (($lastvisit_at >= strtotime('-7 month')) && ($lastvisit_at < strtotime('-6 month'))) || \n (($lastvisit_at >= strtotime('-12 month')) && ($lastvisit_at < strtotime('-11 month'))) )\n ) continue;\n \n//set mail tracking\n $mailTracking = mailTrackingCode($user->id);\n $ml = new MailLog();\n $ml->tracking_code = mailTrackingCodeDecode($mailTracking);\n $ml->type = 'no-activity-reminder';\n $ml->user_to_id = $user->id;\n $ml->save();\n \n $message->subject = $user->name.\" did you forget about us?\";\n \n //$activation_url = '<a href=\"'.absoluteURL().\"/user/registration?id=\".$user->key.'\">Register here</a>';\n //\n //$activation_url = mailButton(\"Register here\", absoluteURL().\"/user/registration?id=\".$user->key,'success',$mailTracking,'register-button');\n $content = \"Since your last visit we got some awesome new \".mailButton('projects', absoluteURL().'/project/discover','link', $mailTracking,'projects-button').\" and interesting \".\n mailButton('people', absoluteURL().'/person/discover','link', $mailTracking,'people-button').\" signup at Cofinder.\n <br /><br />\n Why don't you check them out on \".mailButton('Cofinder', 'http://www.cofinder.eu','success', $mailTracking,'cofinder-button');\n \n $message->setBody(array(\"content\"=>$content,\"email\"=>$user->email,\"tc\"=>$mailTracking), 'text/html');\n $message->setTo($user->email);\n Yii::app()->mail->send($message);\n $c++;\n }\n \n Slack::message(\"CRON >> No activity reminders: \".$c);\n }", "public function invites();", "function email_print_users_to_send($users, $nosenders=false, $options=NULL) {\n\n\tglobal $CFG;\n\n\t$url = '';\n\tif ( $options ) {\n\t\t$url = email_build_url($options);\n\t}\n\n\n\techo '<tr valign=\"middle\">\n <td class=\"legendmail\">\n <b>'.get_string('for', 'block_email_list'). '\n :\n </b>\n </td>\n <td class=\"inputmail\">';\n\n if ( ! empty ( $users ) ) {\n\n \techo '<div id=\"to\">';\n\n \tforeach ( $users as $userid ) {\n \t\techo '<input type=\"hidden\" value=\"'.$userid.'\" name=\"to[]\" />';\n \t}\n\n \techo '</div>';\n\n \techo '<textarea id=\"textareato\" class=\"textareacontacts\" name=\"to\" cols=\"65\" rows=\"3\" disabled=\"true\" multiple=\"multiple\">';\n\n \tforeach ( $users as $userid ) {\n \t\techo fullname( get_record('user', 'id', $userid) ).', ';\n \t}\n\n \techo '</textarea>';\n }\n\n \techo '</td><td class=\"extrabutton\">';\n\n\tlink_to_popup_window( '/blocks/email_list/email/participants.php?'.$url, 'participants', get_string('participants', 'block_email_list').' ...',\n 470, 520, get_string('participants', 'block_email_list') );\n\n echo '</td></tr>';\n echo '<tr valign=\"middle\">\n \t\t\t<td class=\"legendmail\">\n \t\t\t\t<div id=\"tdcc\"></div>\n \t\t\t</td>\n \t\t\t<td><div id=\"fortextareacc\"></div><div id=\"cc\"></div><div id=\"url\">'.$urltoaddcc.'<span id=\"urltxt\">&#160;|&#160;</span>'.$urltoaddbcc.'</div></td><td><div id=\"buttoncc\"></div></td></tr>';\n echo '<tr valign=\"middle\"><td class=\"legendmail\"><div id=\"tdbcc\"></div></td><td><div id=\"fortextareabcc\"></div><div id=\"bcc\"></div></td><td><div id=\"buttonbcc\"></div></td>';\n\n\n}", "public function cronNotifyRecipients()\n\t{\n\t\t// Check if notifications should be send.\n\t\tif (!$GLOBALS['TL_CONFIG']['avisota_send_notification'])\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\t$this->loadLanguageFile('avisota_subscription');\n\n\t\t$entityManager = EntityHelper::getEntityManager();\n\t\t$subscriptionRepository = $entityManager->getRepository('Avisota\\Contao:RecipientSubscription');\n\t\t$intCountSend = 0;\n\n\t\t$resendDate = $GLOBALS['TL_CONFIG']['avisota_notification_time'] * 24 * 60 * 60;\n\t\t$now = time();\n\n\t\t// Get all recipients.\n\t\t$queryBuilder = EntityHelper::getEntityManager()->createQueryBuilder();\n\t\t$queryBuilder\n\t\t\t\t->select('r')\n\t\t\t\t->from('Avisota\\Contao:Recipient', 'r')\n\t\t\t\t->innerJoin('Avisota\\Contao:RecipientSubscription', 's', 'WITH', 's.recipient=r.id')\n\t\t\t\t->where('s.confirmed=0')\n\t\t\t\t->andWhere('s.reminderCount < ?1')\n\t\t\t\t->setParameter(1, $GLOBALS['TL_CONFIG']['avisota_notification_count']);\n\t\t$queryBuilder->orderBy('r.email');\n\t\t\n\t\t// Execute Query.\n\t\t$query = $queryBuilder->getQuery();\n\t\t$integratedRecipients = $query->getResult();\n\t\t\n\t\t// Check each recipient with open subscription.\n\t\tforeach ($integratedRecipients as $integratedRecipient)\n\t\t{\n\t\t\t$subscriptions = $subscriptionRepository->findBy(array('recipient' => $integratedRecipient->id, 'confirmed' => 0), array('updatedAt' => 'asc'));\n\t\t\t$tokens = array();\n\t\t\t$blnNotify = false;\n\n\t\t\tforeach ($subscriptions as $subscription)\n\t\t\t{\n\t\t\t\t// Check if we are over the $resendDate date.\n\t\t\t\tif (($subscription->updatedAt->getTimestamp() + $resendDate) > $now)\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// Set some data.\n\t\t\t\t$blnNotify = true;\n\t\t\t\t$tokens[] = $subscription->getToken();\n\n\t\t\t\t// Update the subscription.\n\t\t\t\t$subscription->updatedAt = new \\Datetime();\n\t\t\t\t$subscription->reminderSent = new \\Datetime();\n\t\t\t\t$subscription->reminderCount = $subscription->reminderCount + 1;\n\n\t\t\t\t// Save.\n\t\t\t\t$entityManager->persist($subscription);\n\t\t\t}\n\n\t\t\t// Check if we have to send a notify and if we have a subscription module.\n\t\t\tif ($blnNotify && $subscription->getSubscriptionModule())\n\t\t\t{\n\t\t\t\t$subscription = $subscriptions[0];\n\n\t\t\t\t$parameters = array(\n\t\t\t\t\t'email' => $integratedRecipient->email,\n\t\t\t\t\t'token' => implode(',', $tokens),\n\t\t\t\t);\n\n\t\t\t\t$arrPage = $this->Database\n\t\t\t\t\t\t->prepare('SELECT * FROM tl_page WHERE id = (SELECT avisota_form_target FROM tl_module WHERE id = ?)')\n\t\t\t\t\t\t->limit(1)\n\t\t\t\t\t\t->execute($subscription->getSubscriptionModule())\n\t\t\t\t\t\t->fetchAssoc();\n\n\t\t\t\t$objNextPage = $this->getPageDetails($arrPage['id']);\n\t\t\t\t$strUrl = $this->generateFrontendUrl($objNextPage->row(), null, $objNextPage->rootLanguage);\n\n\t\t\t\t$url = $this->generateFrontendUrl($arrPage);\n\t\t\t\t$url .= (strpos($url, '?') === false ? '?' : '&');\n\t\t\t\t$url .= http_build_query($parameters);\n\n\t\t\t\t$newsletterData = array();\n\t\t\t\t$newsletterData['link'] = (object) array(\n\t\t\t\t\t\t\t'url' => \\Environment::getInstance()->base . $url,\n\t\t\t\t\t\t\t'text' => $GLOBALS['TL_LANG']['avisota_subscription']['confirmSubscription'],\n\t\t\t\t);\n\n\t\t\t\t// Try to send the email.\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\t$this->sendMessage($integratedRecipient, $GLOBALS['TL_CONFIG']['avisota_notification_mail'], $GLOBALS['TL_CONFIG']['avisota_default_transport'], $newsletterData);\n\t\t\t\t}\n\t\t\t\tcatch (\\Exception $exc)\n\t\t\t\t{\n\t\t\t\t\t$this->log(sprintf('Unable to send reminder to \"%s\" with error message - %s', $integratedRecipient->email, $exc->getMessage()), __CLASS__ . ' | ' . __FUNCTION__, TL_ERROR);\n\t\t\t\t}\n\n\t\t\t\t// Update recipient;\n\t\t\t\t$integratedRecipient->updatedAt = new \\DateTime();\n\n\t\t\t\t// Set counter.\n\t\t\t\t$intCountSend++;\n\t\t\t}\n\n\t\t\t// Send only 5 mails per run.\n\t\t\tif ($intCountSend >= 5)\n\t\t\t{\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t\t$entityManager->flush();\n\t}", "function sendMembershipRenewalEmails($row, $config) {\r\n\t\t$jconfig = new JConfig();\r\n\t\t$db = & JFactory::getDBO();\r\n\t\t$fromEmail = $jconfig->mailfrom;\r\n\t\t$fromName = $jconfig->fromname;\r\n\t\t$sql = \"SELECT * FROM #__osmembership_plans WHERE id=\".$row->plan_id ;\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$plan = $db->loadObject();\r\n\t\tif ($row->renew_option_id) {\r\n\t\t\t$numberDays = $row->subscription_length ;\r\n\t\t} else {\r\n\t\t\t$sql = 'SELECT number_days FROM #__osmembership_renewrates WHERE id='.$row->renew_option_id ;\r\n\t\t\t$db->setQuery($sql) ;\r\n\t\t\t$numberDays = $db->loadResult();\r\n\t\t}\t\t\r\n\t\t//Need to over-ridde some config options\r\n\t\t$emailContent = OSMembershipHelper::getEmailContent($config, $row);\r\n\t\t$replaces = array() ;\r\n\t\t$replaces['plan_title'] = $plan->title ;\r\n\t\t$replaces['first_name'] = $row->first_name ;\r\n\t\t$replaces['last_name'] = $row->last_name ;\r\n\t\t$replaces['organization'] = $row->organization ;\r\n\t\t$replaces['address'] = $row->address ;\r\n\t\t$replaces['address2'] = $row->address ;\r\n\t\t$replaces['city'] = $row->city ;\r\n\t\t$replaces['state'] = $row->state ;\r\n\t\t$replaces['zip'] = $row->zip ;\r\n\t\t$replaces['country'] = $row->country ;\r\n\t\t$replaces['phone'] = $row->phone ;\r\n\t\t$replaces['fax'] = $row->phone ;\r\n\t\t$replaces['email'] = $row->email ;\r\n\t\t$replaces['comment'] = $row->comment ;\r\n\t\t$replaces['amount'] = number_format($row->amount, 2) ;\r\n\t\t$replaces['discount_amount'] = number_format($row->discount_amount, 2) ;\r\n\t\t$replaces['tax_amount'] = number_format($row->tax_amount, 2) ;\r\n\t\t$replaces['gross_amount'] = number_format($row->gross_amount, 2) ;\r\n\t\t$replaces['end_date'] = JHTML::_('date', $row->to_date, $config->date_format);\r\n\t\t$replaces['number_days'] = $numberDays ;\r\n\t\t\t\r\n\t\t$replaces['transaction_id'] = $row->transaction_id ;\r\n\t\tif ($row->payment_method) {\r\n\t\t\t$replaces['payment_method'] = JText::_(os_payments::loadPaymentMethod($row->payment_method)->title) ;\r\n\t\t}\r\n\t\t//Should we create map to custom fields\r\n\t\t$sql = 'SELECT field_id, field_value FROM #__osmembership_field_value WHERE subscriber_id = '.$row->id;\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$rowValues = $db->loadObjectList();\r\n\t\t$sql = 'SELECT a.id, a.name FROM #__osmembership_fields AS a WHERE a.published=1 AND (a.plan_id = 0 OR a.plan_id='.$row->plan_id.')';\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$rowFields = $db->loadObjectList();\r\n\t\t$fields = array() ;\r\n\t\tfor ($i = 0 , $n = count($rowFields) ; $i < $n ; $i++) {\r\n\t\t\t$rowField = $rowFields[$i] ;\r\n\t\t\t$fields[$rowField->id] = $rowField->name ;\r\n\t\t}\r\n\t\tfor ($i = 0 , $n = count($rowValues) ; $i < $n ; $i++) {\r\n\t\t\t$rowValue = $rowValues[$i] ;\r\n\t\t\t$replaces[$fields[$rowValue->field_id]] = $rowValue->field_value ;\r\n\t\t}\t\t\t\t\r\n\t\t$subject = $config->user_renew_email_subject ;\t\t\t\t\r\n\t\t$subject = str_replace('[PLAN_TITLE]', $plan->title, $subject) ;\r\n\t\t$body = $config->user_renew_email_body ;\r\n\t\t$body = str_replace('[SUBSCRIPTION_DETAIL]', $emailContent, $body) ;\r\n\r\n\t\t\r\n\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t$key = strtoupper($key) ;\r\n\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t}\r\n\t\t\r\n\t\tif (version_compare(JVERSION, '3.0', 'ge')) {\r\n\t\t\t$j3 = true ;\r\n\t\t\t$mailer = new JMail() ;\r\n\t\t} else {\r\n\t\t\t$j3 = false ;\r\n\t\t}\r\n\t\tif ($j3) {\r\n\t\t\t$mailer->sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t} else {\r\n\t\t\tJUtility::sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t}\t\t\t\t\r\n\t\t//Send emails to notification emails\r\n\t\tif ($config->notification_emails == '')\r\n\t\t\t$notificationEmails = $fromEmail;\r\n\t\telse\r\n\t\t\t$notificationEmails = $config->notification_emails;\r\n\t\t$notificationEmails = str_replace(' ', '', $notificationEmails);\r\n\t\t$emails = explode(',', $notificationEmails);\r\n\t\t$subject = $config->admin_renw_email_subject ;\t\t\r\n\t\t$subject = str_replace('[PLAN_TITLE]', $plan->title, $subject) ;\r\n\t\t$body = $config->admin_renew_email_body ;\r\n\t\t$body = str_replace('[SUBSCRIPTION_DETAIL]', $emailContent, $body);\r\n\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t$key = strtoupper($key) ;\r\n\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t}\r\n\t\tfor ($i = 0, $n = count($emails); $i < $n ; $i++) {\r\n\t\t\t$email = $emails[$i];\r\n\t\t\tif ($j3) {\r\n\t\t\t\t$mailer->sendMail($fromEmail, $fromName, $email, $subject, $body, 1);\r\n\t\t\t} else {\r\n\t\t\t\tJUtility::sendMail($fromEmail, $fromName, $email, $subject, $body, 1);\r\n\t\t\t}\t\t\t\r\n\t\t}\r\n\t}", "public function reminder()\n {\n $credentials = array\n (\n 'email' => Input::get('email')\n );\n\n $remind = Password::remind($credentials, function($message)\n {\n $message->subject('Kweecker - Nieuw wachtwoord');\n });\n switch($remind)\n {\n case Password::INVALID_USER:\n $code = 400;\n $response = array('message' => 'invalid_user');\n break;\n\n case Password::REMINDER_SENT:\n $code = 200;\n $response = array('message' => 'reminder_sent');\n break;\n }\n\n\n // return the response\n return \\Response::json($response, $code);\n }", "function send_first_reminder()\n\t{\n\t\tlog_message('debug', '_message_cron/send_first_reminder');\n\t\t# get non-responsive invites that are more than FIRST_INVITE_PERIOD days old\n\t\t$list = $this->_query_reader->get_list('get_non_responsive_invitations', array('days_old'=>FIRST_INVITE_PERIOD, 'limit_text'=>' LIMIT '.MAXIMUM_INVITE_BATCH_LIMIT, 'old_message_code'=>'invitation_to_join_clout'));\n\t\tlog_message('debug', '_message_cron/send_first_reminder:: [1] list='.json_encode($list));\n\t\t# resend old invite as a reminder\n\t\t$results = array();\n\t\tforeach($list AS $i=>$row){\n\t\t\t$results[$i] = $this->_query_reader->run('resend_old_invite', array('invite_id'=>$row['invite_id'], 'new_code'=>'first_reminder_to_join_clout', 'new_status'=>'pending'));\n\t\t}\n\t\tlog_message('debug', '_message_cron/send_first_reminder:: [2] results='.json_encode($results));\n\t\t$reason = empty($results)? 'no-users': '';\n\t\treturn array('result'=>(get_decision($results)? 'SUCCESS': 'FAIL'), 'count'=>count($results), 'reason'=>$reason);\n\t}", "public function sendUpdateBookingMailToParticipants(array $a_participants_ids) {\r\n\t\tforeach (array_unique($a_participants_ids) as $participant_id) {\r\n\t\t\t$this->composeUpdatingBookingMailForParticipant($participant_id);\r\n\t\t\tparent::sendMail(array( $participant_id ), array( 'system' ), is_numeric($participant_id));\r\n\t\t}\r\n\t}", "public static function setMSGForHaveNTEmailUsers() {\n\n // not have email end moderation job seekers\n $queryMail = \"\n SELECT\n u.id_user,\n u.email,\n u.crdate,\n u.mdate,\n u.status,\n r.ismoder\n FROM\n user u\n INNER JOIN \n resume r ON r.id_user=u.id_user \n WHERE\n DATE(u.crdate) >= NOW() - INTERVAL 1 DAY \n or \n DATE(u.mdate) >= NOW() - INTERVAL 1 DAY \n GROUP BY u.id_user\n \";\n $queryMail = Yii::app()->db->createCommand($queryMail)->queryAll();\n\n if(count($queryMail)){\n\n foreach ($queryMail as $user){\n $email = $user['email'];\n if ((!preg_match(\"/^(?:[a-z0-9]+(?:[-_.]?[a-z0-9]+)?@[a-z0-9_.-]+(?:\\.?[a-z0-9]+)?\\.[a-z]{2,5})$/i\", $email))\n || ( $email = '' )){\n /**\n * Send messages to users who did not enter the email\n */\n $resultm['users'][] = $user['id_user'];\n $resultm['title'] = 'Администрация';\n $resultm['text'] = 'Уважаемый пользователь, будьте добры заполнить \n поле e-mail в вашем профиле.\n Заранее спасибо!';\n }\n }\n $admMsgM = new AdminMessage();\n\n // send notifications\n if (isset($resultm)) {\n $admMsgM->sendDataByCron($resultm);\n }\n\n foreach ($queryMail as $user){\n $status = $user['status'];\n $ismoder = $user['ismoder'];\n if ( ($status == 2) && ($ismoder != 1)){\n /**\n * Send messages to users who did not enter moderation information\n */\n $resultjs['users'][] = $user['id_user'];\n $resultjs['title'] = 'Администрация';\n $resultjs['text'] = 'Уважаемый пользователь, заполните '.\n 'поля, необходимые для модерации:'.\n '<ul style=\"text-align:left\">'.\n '<li>имя и фамилия</li>'.\n '<li>год рождения</li>'.\n '<li>Фото(допускается и без него, на фото не природа, '.\n 'не больше одной личности, не анимация и т.д)</li>'.\n '<li>номер телефона и эмейл</li>'.\n '<li>целевая вакансия</li>'.\n '<li>раздел \"О себе\"</li>'.\n '<ul>';\n }\n }\n $admMsgJS = new AdminMessage();\n if (isset($resultjs)) {\n $admMsgJS->sendDataByCron($resultjs);\n }\n\n }\n\n $queryEmpl = \"\n SELECT\n u.id_user,\n u.email,\n u.crdate,\n u.mdate,\n u.status,\n e.ismoder\n FROM\n user u\n INNER JOIN \n employer e ON e.id_user=u.id_user \n WHERE\n (\n DATE(u.crdate) >= NOW() - INTERVAL 1 DAY \n or \n DATE(u.mdate) >= NOW() - INTERVAL 1 DAY\n ) and u.status = 3 \n \n GROUP BY u.id_user\n \";\n $queryEmpl = Yii::app()->db->createCommand($queryEmpl)->queryAll();\n\n if(count($queryEmpl)) {\n\n foreach ($queryEmpl as $user){\n $ismoder = $user['ismoder'];\n if ( $ismoder != 1 ){\n /**\n * Send messages to employer who did not enter moderation information\n */\n $resulte['users'][] = $user['id_user'];\n $resulte['title'] = 'Администрация';\n $resulte['text'] = 'Уважаемый пользователь, заполните '.\n 'поля в вашем профиле, необходимые для модерации:'.\n '<ul style=\"text-align:left\">'.\n '<li>название компании</li>'.\n '<li>логотип - желаельно</li>'.\n '<li>номер телефона и эмейл</li>'.\n '<li>имя контактного лица</li>'.\n '<li>контактный номер телефона</li>'.\n '<ul>';\n }\n }\n $admMsgE = new AdminMessage();\n if (isset($resulte)) {\n $admMsgE->sendDataByCron($resulte);\n }\n }\n\n }", "public function notify_members() {\n $from = array($this->site->user->email, $this->site->user->name());\n $subject = Kohana::lang('finance_reminder.charge.subject');\n if ($this->site->collections_enabled()) {\n $message = Kohana::lang('finance_reminder.charge.message_finances');\n }\n else {\n $message = Kohana::lang('finance_reminder.charge.message_basic');\n }\n\n foreach ($this->finance_charge_members as $member) {\n if ( ! $member->paid) {\n $replacements = array(\n '!name' => $member->user->name(),\n '!due_date' => date::display($member->due, 'M d, Y', FALSE),\n '!due_amount' => money::display($member->balance()),\n '!charge_title' => $member->title,\n '!pay_link' => url::base(),\n );\n $email = array(\n 'subject' => strtr($subject, $replacements),\n 'message' => strtr($message, $replacements),\n );\n email::announcement($member->user->email, $from, 'finance_charge_reminder', $email, $email['subject']);\n }\n }\n return TRUE;\n }", "public function goalsResetCron()\n {\n $groups = $this->Group->find('all');\n $emailPost = array();\n foreach($groups as $group) {\n $groupID = $this->Encryption->decode($group['Group']['id']);\n $conditions = array('BusinessOwner.group_id'=>$groupID);\n $fields = array('BusinessOwner.fname','BusinessOwner.lname','BusinessOwner.email');\n $bizData = $this->BusinessOwner->find('all',array('conditions'=>$conditions,'fields'=>$fields));\n // Send mail to all group members\n if(!empty($bizData)) {\n foreach($bizData as $row) {\n $emailLib = new Email();\n $to = $row['BusinessOwner']['email'];\n $subject = 'FoxHopr: Your Goals have been reset';\n $template ='group_goals_reset';\n $message = \"Your individual goals have been reset.<br/>Please login and click Team tab to open the Goals subtab to set the new goals for the present month. \";\n $variable = array('name'=>$row['BusinessOwner']['fname'] . \" \" . $row['BusinessOwner']['lname'],'message'=>$message);\n $success = $emailLib->sendEmail($to, $subject, $variable, $template, 'both');\n }\n } \n $leaderColeaderData = $this->BusinessOwner->find('all',array('conditions'=>array('BusinessOwner.group_id'=>$groupID,'BusinessOwner.group_role'=>array('leader','co-leader')),'fields'=>$fields));\n // Send mail to all leaders/Co-leaders\n if(!empty($leaderColeaderData)) {\n foreach($leaderColeaderData as $row) {\n $emailLib = new Email();\n $to = $row['BusinessOwner']['email'];\n $subject = 'FoxHopr: Your Goals have been reset';\n $template ='group_goals_reset';\n $message = \"The group members goal have been reset.<br/>Please login and click Team tab to open the Goals sub tab and set the group member goals for the present month. \";\n $fullName = $row['BusinessOwner']['fname'] . \" \" . $row['BusinessOwner']['lname'];\n $variable = array('name'=>$fullName, 'message'=>$message);\n $success = $emailLib->sendEmail($to, $subject, $variable, $template, 'both');\n }\n } \n } \n }", "function send_invitation($po_num,$i) {\r\n # get PO1 email address\r\n # @$po_num = string, po1, po2, po3\r\n $usrmgr = instantiate_module('usrmgr');\r\n #~ $row = $usrmgr->get_row(array('username'=>$po_num));\r\n $row = $usrmgr->get_row(array('param_1'=>$po_num));\r\n assert($row);\r\n $h = array();\r\n $h['from'] = $GLOBALS['mail_from'];\r\n $h['to'] = $row['email'];\r\n $h['subject'] = 'New project from partner '.$this->ds->partner_id[$i];\r\n $accept_url = get_fullpath().'index.php?m=project&act=accept&project_id='.$this->ds->project_id[$i].'&email_cookie='.$this->ds->email_cookie[$i];\r\n $exp_date = $this->ds->{$po_num.'_exp_date'}[$i];\r\n $exp_date = $exp_date == ''? 'This invitation to accept project will not expire.':'Invitation to accept project will expire on '.$exp_date;\r\n $h['body'] = <<<__END__\r\nHello $po_num. A new project has been entered by Partner {$this->ds->partner_id[$i]}\r\n\r\nRegistration Number: {$this->ds->project_id[$i]}\r\nProject Name: {$this->ds->name[$i]}\r\nTotal: {$this->ds->total[$i]} (in 000 USD)\r\nList Price: {$this->ds->list_price[$i]} (in 000 USD)\r\n\r\nTo retrieve information about this project via email, click this URL:\r\n$accept_url\r\n\r\n--\r\n admin\r\n\r\n__END__;\r\n #~ print_r($h);\r\n supermailer($h);\r\n\r\n # done\r\n\r\n }", "public function appointments()\n\t{\n\t\tif (!is_cli())\n\t\t{\n\t\t\techo \"This script can only be accessed via the command line\" . PHP_EOL;\n\t\t\treturn;\n\t\t}\n\n\t\t$participations = $this->participationModel->get_confirmed_participations();\n\t\tforeach ($participations as $participation)\n\t\t{\n\t\t\t$appointment = strtotime($participation->appointment); \n\t\t\tif ($appointment > strtotime('tomorrow') && $appointment <= strtotime('tomorrow + 1 day')) \n\t\t\t{\t\t\t\t\t\n\t\t\t\treset_language(L::DUTCH);\n\t\t\t\t\n\t\t\t\t$participant = $this->participationModel->get_participant_by_participation($participation->id);\n\t\t\t\t$experiment = $this->participationModel->get_experiment_by_participation($participation->id);\n\t\t\t\t$message = email_replace('mail/reminder', $participant, $participation, $experiment);\n\t\t\n\t\t\t\t$this->email->clear();\n\t\t\t\t$this->email->from(FROM_EMAIL, FROM_EMAIL_NAME);\n\t\t\t\t$this->email->to(in_development() ? TO_EMAIL_DEV_MODE : $participant->email);\n\t\t\t\t$this->email->subject('Babylab Utrecht: Herinnering deelname');\n\t\t\t\t$this->email->message($message);\n\t\t\t\t$this->email->send();\n\t\t\t\t// DEBUG: $this->email->print_debugger();\n\t\t\t}\n\t\t}\n\t}", "function send_invitation($form_data, $template_file, $date) {\n\n /*Use the email template and replace the strings located within\n with the values from the form_data array */ \n $email_message = file_get_contents($template_file);\n $email_message = str_replace(\"#DATE#\", $date, $email_message);\n $email_message = str_replace(\"#NAME#\", $form_data['first_name'] . \" \" . $form_data['last_name'], $email_message);\n $email_message = str_replace(\"#MESSAGE#\", $form_data['message'], $email_message);\n $email_message = str_replace(\"#FROM_EMAIL#\", $form_data['user_email'], $email_message);\n $email_message = str_replace(\"#FROM_MEMBER#\", $form_data['from_member'], $email_message);\n \n //Construct the email headers\n $to = $form_data['email'];\n $from = $form_data['user_email'];\n $email_subject = $form_data['subject'];\n\n $headers = \"From: \" . $from . \"\\r\\n\";\n $headers .= 'MIME-Version: 1.0' . \"\\n\"; \n $headers .= 'Content-type: text/html; charset=iso-8859-1' . \"\\r\\n\"; \n \n //Send an invitation email message\n mail($to, $email_subject, $email_message, $headers);\n}", "private function onboardUsers()\n {\n foreach ($this->users as $user) {\n $token = $user->generateMagicToken();\n $user->sendNotification(new OnboardEmail($user, $token));\n }\n }", "function get_emails($id, $cur_tab_id, $rel_tab_id, $actions=false) {\n\t\tglobal $log, $singlepane_view,$currentModule,$current_user;\n\t\t$log->debug(\"Entering get_emails(\".$id.\") method ...\");\n\t\t$this_module = $currentModule;\n\n $related_module = vtlib_getModuleNameById($rel_tab_id);\n\t\trequire_once(\"modules/$related_module/$related_module.php\");\n\t\t$other = new $related_module();\n vtlib_setup_modulevars($related_module, $other);\n\t\t$singular_modname = vtlib_toSingular($related_module);\n\n\t\t$parenttab = getParentTab();\n\n\t\tif($singlepane_view == 'true')\n\t\t\t$returnset = '&return_module='.$this_module.'&return_action=DetailView&return_id='.$id;\n\t\telse\n\t\t\t$returnset = '&return_module='.$this_module.'&return_action=CallRelatedList&return_id='.$id;\n\n\t\t$button = '';\n\n\t\t$button .= '<input type=\"hidden\" name=\"email_directing_module\"><input type=\"hidden\" name=\"record\">';\n\n\t\tif($actions) {\n\t\t\tif(is_string($actions)) $actions = explode(',', strtoupper($actions));\n\t\t\tif(in_array('ADD', $actions) && isPermitted($related_module,1, '') == 'yes') {\n\t\t\t\t$button .= \"<input title='\". getTranslatedString('LBL_ADD_NEW').\" \". getTranslatedString($singular_modname).\"' accessyKey='F' class='crmbutton small create' onclick='fnvshobj(this,\\\"sendmail_cont\\\");sendmail(\\\"$this_module\\\",$id);' type='button' name='button' value='\". getTranslatedString('LBL_ADD_NEW').\" \". getTranslatedString($singular_modname).\"'></td>\";\n\t\t\t}\n\t\t}\n\n\t\t$userNameSql = getSqlForNameInDisplayFormat(array('first_name'=>\n\t\t\t\t\t\t\t'vtiger_users.first_name', 'last_name' => 'vtiger_users.last_name'), 'Users');\n\t\t$query = \"select case when (vtiger_users.user_name not like '') then $userNameSql else vtiger_groups.groupname end as user_name,\" .\n\t\t\t\t\" vtiger_activity.activityid, vtiger_activity.subject, vtiger_activity.activitytype, vtiger_crmentity.modifiedtime,\" .\n\t\t\t\t\" vtiger_crmentity.crmid, vtiger_crmentity.smownerid, vtiger_activity.date_start, vtiger_activity.time_start, vtiger_seactivityrel.crmid as parent_id \" .\n\t\t\t\t\" from vtiger_activity, vtiger_seactivityrel, vtiger_contactdetails, vtiger_users, vtiger_crmentity\" .\n\t\t\t\t\" left join vtiger_groups on vtiger_groups.groupid=vtiger_crmentity.smownerid\" .\n\t\t\t\t\" where vtiger_seactivityrel.activityid = vtiger_activity.activityid\" .\n\t\t\t\t\" and vtiger_contactdetails.contactid = vtiger_seactivityrel.crmid and vtiger_users.id=vtiger_crmentity.smownerid\" .\n\t\t\t\t\" and vtiger_crmentity.crmid = vtiger_activity.activityid and vtiger_contactdetails.contactid = \".$id.\" and\" .\n\t\t\t\t\t\t\" vtiger_activity.activitytype='Emails' and vtiger_crmentity.deleted = 0\";\n\n\t\t$return_value = GetRelatedList($this_module, $related_module, $other, $query, $button, $returnset);\n\n\t\tif($return_value == null) $return_value = Array();\n\t\t$return_value['CUSTOM_BUTTON'] = $button;\n\n\t\t$log->debug(\"Exiting get_emails method ...\");\n\t\treturn $return_value;\n\t}", "public function sendAssignmentNotification()\n {\n \t$ctime = date('Y-m-d'); //get current day\n \n \t//get facebook id from the user setting for facebook reminder\n \t$this->PleAssignmentReminder->virtualFields = array('tid' => 'PleUserMapTwitter.twitterId');\n \n \t//get last sent id\n \t$last_sent_id = $this->PleLastReminderSent->find('first',array('conditions' => array('PleLastReminderSent.date' => $ctime, 'PleLastReminderSent.type' => 'twitter')));\n \n \tif( count($last_sent_id) > 0 ) {\n \t\t$options['conditions'][] = array('PleAssignmentReminder.id >' => $last_sent_id['PleLastReminderSent']['last_sent_rid']);\n \t}\n \n \t//get appController class object\n \t$obj = new AppController();\n \t$assignments = $obj->getAssignmentConstraints();\n \n \t//get today assignments\n \n \t$options['conditions'][] = $assignments;\n \t$options['fields'] = array('id', 'user_id', 'assignment_uuid', 'assignment_title', 'due_date', 'course_id');\n \t$options['order'] = array('PleAssignmentReminder.id ASC');\n \n \t//execute query\n \t$assignmnet_details = $this->PleAssignmentReminder->find('all', $options);\n \t\n \n \t//send twitter reminder\n \tforeach( $assignmnet_details as $assignmnet_detail ) {\n\t $user_id = $assignmnet_detail['PleAssignmentReminder']['user_id'];\n \t\t//$to_twitter = $assignmnet_detail['PleAssignmentReminder']['tid'];\n \t\t$body = $assignmnet_detail['PleAssignmentReminder']['assignment_title'];\n\t\t$course_id = $assignmnet_detail['PleAssignmentReminder']['course_id'];\n \t\t\n\t\t//get twitter users array if user is instructor\n \t\t$twitter_users_array = $this->getChildren( $user_id, $course_id );\n\t\t\n \t\t//set display date for assignments\n \t\t$originalDate = $assignmnet_detail['PleAssignmentReminder']['due_date'];\n\t\tif($originalDate != \"\"){\n \t\t$newDate = date(\"F d, Y\", strtotime($originalDate));\n \t\t$due_date = \" due on $newDate\";\n\t\t}else{\n\t\t \t$due_date = \" is due on NA\";\n\t\t }\n \t\t\n \t\t//compose mail date\n \t\t$mail_data = \"Assignment Reminder! $course_id. Your assignment, $body, $due_date.\";\n \t\t$subject = $course_id.\" - \".$body;\n \n\t\t//send the reminder to multiple users\n \t\tforeach ($twitter_users_array as $to_twitter_data ) {\n\t\t$to_twitter = $to_twitter_data['twitter_id'];\n \t\t$to_id = $to_twitter_data['id'];\n \t\t$send_twitter = $this->sendNotification( $to_twitter, $mail_data );\n \n \t\t//check for if facebook reminder sent\n \t\tif ( $send_twitter == 1) {\n \n \t\t\t//remove the previous entry of current date\n \t\t\t$this->PleLastReminderSent->deleteAll(array('PleLastReminderSent.date'=>$ctime, 'PleLastReminderSent.type'=>'twitter'));\n \t\t\t$this->PleLastReminderSent->create();\n \n \t\t\t//update the table for sent facebook reminder\n \t\t\t$data['PleLastReminderSent']['last_sent_rid'] = $assignmnet_detail['PleAssignmentReminder']['id'];\n \t\t\t$data['PleLastReminderSent']['type'] = 'twitter';\n \t\t\t$data['PleLastReminderSent']['date'] = $ctime;\n \t\t\t$this->PleLastReminderSent->save($data);\n \n \t\t\t//create the CSV user data array\n \t\t\t$csv_data = array('id'=>$to_id, 'tid'=>$to_twitter, 'mail_data'=> $mail_data);\n \n \t\t\t//write the csv\n \t\t\t$this->writeTwitterCsv($csv_data);\n \n \t\t\t//unset the csv data array\n \t\t\tunset($csv_data);\n \t\t} else if ( $send_twitter == 2) { //twitter app not following case(can be used for future for notification on dashboard)\n \t\t\t\n \t\t} else {\n \t\t\t//handling for twitter reminder failure\n\t \t\t$tw_data = array();\n\t \t\t$tw_data['AssignmentTwitterFailure']['twitter_id'] = $to_twitter;\n\t \t\t$tw_data['AssignmentTwitterFailure']['mail_data'] = $mail_data;\n\t \t\t$this->AssignmentTwitterFailure->create();\n\t \t\t$this->AssignmentTwitterFailure->save($tw_data);\n \t\t}\n\t\t}\n \t}\n }", "public function sendRemind(array $listIds = null)\n\t{\n\t\tthrow new AvisotaSubscriptionException($this, 'This recipient cannot subscribe!');\n\t}", "public function deleteMutipleUsers(){\n\t\t if(count($_REQUEST['user_ids']>0)){\n\t\t\tforeach($_REQUEST['user_ids'] as $val){\n\t\t\t\t$user \t\t= Sentinel::findUserById($val);\n\t\t\t\t$id \t\t=\t $user->id;\n\t\t\t\t\n\t\t\t$userInfoArr\t=\tDB::table('user_payments')->where('user_id','=',$id)\n\t\t\t->where('stripe_customer_id','!=','')\n\t\t\t->where('status','=','active')\n\t\t\t->first();\n\t\t\t\n\t\t\tif(count($userInfoArr)>0){\n\t\t\t\t$url_cst = 'https://api.stripe.com/v1/customers/'.$userInfoArr->stripe_customer_id;\n\t\t\t\t$delete_stripe_customer = $this->delete_stripe_customer($headers,$url_cst,'DELETE');\n\t\t\t\t\n\t\t\t}\n\t\t\t\t$userInvite = DB::table('users')->select('email')->where('id',\"=\",$id)->first();\n\t\t\t\tDB::table('userinvites')->where('email','=',$userInvite->email)->delete();\n\t\t\t\tDB::table('users')->where('id', '=', $id)->delete();\n\t\t\t\tDB::table('user_payments')->where('user_id', '=', $id)->delete();\n\t\t\t\tDB::table('events')->where('user_id', '=', $id)->delete();\n\t\t\t\t\n\t\t\t}\n\t\t }\n\t }", "function invite()\n\t{\n\t\t$data = filter_forwarded_data($this);\n\t\tlogout_invalid_user($this);\n\t\t\n\t\t# user has submitted the invitation\n\t\tif(!empty($_POST)){\n\t\t\t$response = $this->_tender->invite($_POST);\n\t\t\t$msg = (!empty($response) && $response['boolean'])? 'The Invitation for Bids/Quotations has been sent.' :'ERROR: The Invitation for Bids/Quotations could not be sent.';\n\t\t\t\n\t\t\t$this->native_session->set('__msg',$msg);\n\t\t}\n\t\telse if(!empty($data['a'])){\n\t\t\t$data['msg'] = $this->native_session->get('__msg');\n\t\t\t$data['area'] = 'refresh_list_msg';\n\t\t\t$this->load->view('addons/basic_addons', $data);\n\t\t}\n\t\telse {\n\t\t\t$data['tender'] = $this->_tender->details($data['d']);\n\t\t\t$data['invited'] = $this->_tender->invitations($data['d']);\n\t\t\t$this->load->view('tenders/invite', $data);\n\t\t}\n\t}", "public static function sendReminderEmails($rows, $bccEmail, $time = 1)\n\t{\n\t\t$config = OSMembershipHelper::getConfig();\n\t\t$db = JFactory::getDbo();\n\t\t$query = $db->getQuery(true);\n\t\t$mailer = static::getMailer($config);\n\n\t\tif (JMailHelper::isEmailAddress($bccEmail))\n\t\t{\n\t\t\t$mailer->addBcc($bccEmail);\n\t\t}\n\n\t\t$fieldSuffixes = array();\n\n\t\tswitch ($time)\n\t\t{\n\t\t\tcase 2:\n\t\t\t\t$fieldPrefix = 'second_reminder_';\n\t\t\t\tbreak;\n\t\t\tcase 3:\n\t\t\t\t$fieldPrefix = 'third_reminder_';\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$fieldPrefix = 'first_reminder_';\n\t\t\t\tbreak;\n\t\t}\n\n\t\t$message = OSMembershipHelper::getMessages();\n\t\t$timeSent = $db->quote(JFactory::getDate()->toSql());\n\t\tfor ($i = 0, $n = count($rows); $i < $n; $i++)\n\t\t{\n\t\t\t$row = $rows[$i];\n\n\t\t\tif ($row->number_days < 0)\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$query->clear()\n\t\t\t\t->select('COUNT(*)')\n\t\t\t\t->from('#__osmembership_subscribers')\n\t\t\t\t->where('plan_id = ' . $row->plan_id)\n\t\t\t\t->where('published = 1')\n\t\t\t\t->where('DATEDIFF(from_date, NOW()) >=0')\n\t\t\t\t->where('((user_id > 0 AND user_id = ' . (int) $row->user_id . ') OR email=\"' . $row->email . '\")');\n\t\t\t$db->setQuery($query);\n\t\t\t$total = (int) $db->loadResult();\n\t\t\tif ($total)\n\t\t\t{\n\t\t\t\t$query->clear()\n\t\t\t\t\t->update('#__osmembership_subscribers')\n\t\t\t\t\t->set($db->quoteName($fieldPrefix . 'sent') . ' = 1 ')\n\t\t\t\t\t->where('id = ' . $row->id);\n\t\t\t\t$db->setQuery($query);\n\t\t\t\t$db->execute();\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$fieldSuffix = '';\n\t\t\tif ($row->language)\n\t\t\t{\n\t\t\t\tif (!isset($fieldSuffixes[$row->language]))\n\t\t\t\t{\n\t\t\t\t\t$fieldSuffixes[$row->language] = OSMembershipHelper::getFieldSuffix($row->language);\n\t\t\t\t}\n\n\t\t\t\t$fieldSuffix = $fieldSuffixes[$row->language];\n\t\t\t}\n\n\t\t\t$query->clear()\n\t\t\t\t->select('title' . $fieldSuffix . ' AS title')\n\t\t\t\t->from('#__osmembership_plans')\n\t\t\t\t->where('id = ' . $row->plan_id);\n\n\t\t\t$db->setQuery($query);\n\t\t\t$planTitle = $db->loadResult();\n\n\t\t\t$query->clear();\n\t\t\t$replaces = array();\n\t\t\t$replaces['plan_title'] = $planTitle;\n\t\t\t$replaces['first_name'] = $row->first_name;\n\t\t\t$replaces['last_name'] = $row->last_name;\n\t\t\t$replaces['number_days'] = $row->number_days;\n\t\t\t$replaces['expire_date'] = JHtml::_('date', $row->to_date, $config->date_format);\n\n\t\t\tif (strlen($message->{$fieldPrefix . 'email_subject' . $fieldSuffix}))\n\t\t\t{\n\t\t\t\t$subject = $message->{$fieldPrefix . 'email_subject' . $fieldSuffix};\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$subject = $message->{$fieldPrefix . 'email_subject'};\n\t\t\t}\n\n\t\t\tif (strlen(strip_tags($message->{$fieldPrefix . 'email_body' . $fieldSuffix})))\n\t\t\t{\n\t\t\t\t$body = $message->{$fieldPrefix . 'email_body' . $fieldSuffix};\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$body = $message->{$fieldSuffix . 'email_body'};\n\t\t\t}\n\n\t\t\tforeach ($replaces as $key => $value)\n\t\t\t{\n\t\t\t\t$key = strtoupper($key);\n\t\t\t\t$body = str_ireplace(\"[$key]\", $value, $body);\n\t\t\t\t$subject = str_ireplace(\"[$key]\", $value, $subject);\n\t\t\t}\n\n\t\t\tif (JMailHelper::isEmailAddress($row->email))\n\t\t\t{\n\t\t\t\tstatic::send($mailer, array($row->email), $subject, $body);\n\n\t\t\t\t$mailer->clearAddresses();\n\t\t\t}\n\n\t\t\t$query->clear()\n\t\t\t\t->update('#__osmembership_subscribers')\n\t\t\t\t->set($fieldPrefix . 'sent = 1')\n\t\t\t\t->set($fieldPrefix . 'sent_at = ' . $timeSent)\n\t\t\t\t->where('id = ' . $row->id);\n\t\t\t$db->setQuery($query);\n\t\t\t$db->execute();\n\t\t}\n\t}", "public function invite_members(){\n \tif( !isset( $_REQUEST['pmstkn'] ) || !wp_verify_nonce( $_REQUEST['pmstkn'], 'pms_invite_members_form_nonce' ) )\n \t\treturn;\n\n \tif( empty( $_POST['pms_subscription_id'] ) || empty( $_POST['pms_emails_to_invite'] ) )\n \t\treturn;\n\n if( !pms_get_page( 'register', true ) ){\n pms_errors()->add( 'invite_members', esc_html__( 'Registration page not selected. Contact administrator.', 'paid-member-subscriptions' ) );\n\n return;\n }\n\n \t$subscription = pms_get_member_subscription( sanitize_text_field( $_POST['pms_subscription_id'] ) );\n\n if( !pms_gm_is_group_owner( $subscription->id ) )\n return;\n\n \t//try to split the string by comma\n \t$emails = explode( ',', $_POST['pms_emails_to_invite'] );\n\n \t//check if the first entry contains the end of line character and if so, split by EOL\n \t//having more than 1 entry means that the above split worked\n \tif( isset( $emails[0] ) && count( $emails ) == 1 && strstr( $emails[0], PHP_EOL ) )\n \t\t$emails = explode( PHP_EOL, $_POST['pms_emails_to_invite'] );\n\n $invited_members = 0;\n $invited_emails = pms_get_member_subscription_meta( $subscription->id, 'pms_gm_invited_emails' );\n\n \tforeach( $emails as $email ){\n $email = str_replace( array( \"\\r\", \"\\n\", \"\\t\"), '', $email );\n\n if( !$this->members_can_be_invited( $subscription ) )\n return;\n\n if( in_array( $email, $invited_emails ) )\n continue;\n\n // check if user already invited or registered with subscription\n $email = sanitize_text_field( $email );\n\n if( !filter_var( $email, FILTER_VALIDATE_EMAIL ) )\n continue;\n\n $invited_emails[] = $email;\n\n // If a user with this email is already registered, add him to the subscription\n $user = get_user_by( 'email', $email );\n\n if( !empty( $user ) ) {\n\n $existing_subscription = pms_get_member_subscriptions( array( 'user_id' => $user->ID, 'subscription_plan_id' => $subscription->subscription_plan_id ) );\n\n if( !empty( $existing_subscription ) )\n continue;\n\n $subscription_data = array(\n 'user_id' => $user->ID,\n 'subscription_plan_id' => $subscription->subscription_plan_id,\n 'start_date' => $subscription->start_date,\n 'expiration_date' => $subscription->expiration_date,\n 'status' => 'active',\n );\n\n $new_subscription = new PMS_Member_Subscription();\n $new_subscription->insert( $subscription_data );\n\n pms_add_member_subscription_meta( $new_subscription->id, 'pms_group_subscription_owner', $subscription->id );\n pms_add_member_subscription_meta( $subscription->id, 'pms_group_subscription_member', $new_subscription->id );\n\n if( function_exists( 'pms_add_member_subscription_log' ) )\n pms_add_member_subscription_log( $new_subscription->id, 'group_user_subscription_added' );\n\n $invited_members++;\n\n continue;\n }\n\n // Invite user\n //save email as subscription meta\n $meta_id = pms_add_member_subscription_meta( $subscription->id, 'pms_gm_invited_emails', $email );\n\n //generate and save invite key\n $invite_key = $this->generate_invite_key( $meta_id, $email, $subscription->id );\n\n //send email\n if( $invite_key !== false )\n do_action( 'pms_gm_send_invitation_email', $email, $subscription, $invite_key );\n \t}\n\n $invited_members += (int)did_action( 'pms_gm_send_invitation_email' );\n\n if( $invited_members >= 1 )\n pms_success()->add( 'invite_members', sprintf( _n( '%d member invited successfully !', '%d members invited successfully !', $invited_members, 'paid-member-subscriptions' ), $invited_members ) );\n else\n pms_errors()->add( 'invite_members', esc_html__( 'Something went wrong. Please try again.', 'paid-member-subscriptions' ) );\n\n }", "public static function cron_expiration_reminder() {\n $domains = Domain::get_domain_expirations();\n $distances = self::get_reminder_distance();\n $expiring_soon = array();\n foreach( $domains as $dom ) {\n $m = new Moment( $dom->expiration );\n $momentFromVo = $m->fromNow();\n foreach( $distances as $min_distance ) {\n $distance = $momentFromVo->getWeeks();\n //Subtract the time until expiration from the minimum warning window (weeks in advance to send reminders)\n $diff = $min_distance + $distance;\n //If the difference is greater than or equal to 0, expiration is closing in and we need to send a reminder.\n if( $diff >= 0 && $distance < 0 ) {\n $expiring_soon[] = $dom->ID;\n }\n }\n }\n $expiring_soon = array_unique( $expiring_soon );\n if( !empty( $expiring_soon ) ) {\n self::send_reminder_digest( $expiring_soon );\n }\n }", "function RealTimeInvites($last_invite,$uid=false){\r\n\r\n$invites=helpers::get_controller(INVITATION)->GetInvites($uid,$last_invite);\r\n\r\nif(!empty($invites)){\r\n\r\nforeach ($invites as $invite){\r\n\r\n$return[]=helpers::WidgetOutput(\"Singleinvite\",array(\"invite\"=>$invite));\r\n\r\n}\r\n\r\nreturn $return;\r\n\r\n}\r\n\r\nreturn array();\r\n\r\n}", "public function send_invitation_email($new_user) {\n $mail_settings = Array(\n 'protocol' => 'smtp',\n 'smtp_host' => 'smtp.googlemail.com',\n 'smtp_port' => '587',\n 'smtp_user' => '[email protected]',\n 'smtp_pass' => 'Allion@321',\n 'mailtype' => 'html',\n 'smtp_crypto' => 'tls',\n 'charset' => 'utf-8',\n 'newline' => \"\\r\\n\"\n );\n\n $this->load->library('email', $mail_settings);\n $this->email->from('[email protected]', 'Ceylon Marine Equipment and Services (Pvt) Ltd');\n $this->email->to($new_user['email']);\n $this->email->set_mailtype(\"html\");\n $this->email->subject('Invitation for CM Distribution Management System - Ceylon Marine Equipment and Services (Pvt) Ltd');\n $this->email->message('\n <p>Dear '.$new_user['first_name'].' '.$new_user['last_name'].',</p>\n\n <p>You have been invited to connect to \"Ceylon Marine Equipment and Services (Pvt) Ltd\" in order to get access to our system CM Distribution Management System.</p>\n <p>OTP Code : '.$new_user['token'].'</p>\n <p>To accept the invitation, click on the following link: <a href=\"'.base_url().'/login/signup?email='.$new_user['email'].'\">Invitation Link</a> and enter your email and OTP code</p>\n <p>Accept invitation to \"Ceylon Marine Equipment and Services (Pvt) Ltd\"</p> <br/>\n\n <p>Best regards,</p>\n <p>'.$this->session->userdata('name').'</p>\n <p>CM Distribution Management System - Ceylon Marine Equipment and Services (pvt) Ltd</p>\n ');\n $this->email->send();\n }", "public function invite(){\n $this->validate(request(),[\n 'task_id' => 'required',\n 'user_id'=> 'required'\n ]);\n $task=Task::find(request('task_id'));\n\n $user=User::find(request('user_id'));\n if (\\Gate::denies('taskOwner', $task)) {\n return response()->json(\"Task doesn't Belong To you\");\n }\n \\Mail::to($user)->send(new TaskInvitation($user,$task));\n return response()->json(\"Invitation Mail Sent Successfully\");\n }", "protected function notifyByEmail() {\n\t\t$userlist = array();\n\n\t\t// find all the users with this server listed\n\t\t$users = $this->db->select(\n\t\t\tSM_DB_PREFIX . 'users',\n\t\t\t'FIND_IN_SET(\\''.$this->server['server_id'].'\\', `server_id`) AND `email` != \\'\\'',\n\t\t\tarray('user_id', 'name', 'email')\n\t\t);\n\n\t\tif (empty($users)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// build mail object with some default values\n\t\t$mail = new phpmailer();\n\n\t\t$mail->From\t\t= sm_get_conf('email_from_email');\n\t\t$mail->FromName\t= sm_get_conf('email_from_name');\n\t\t$mail->Subject\t= sm_parse_msg($this->status_new, 'email_subject', $this->server);\n\t\t$mail->Priority\t= 1;\n\n\t\t$body = sm_parse_msg($this->status_new, 'email_body', $this->server);\n\t\t$mail->Body\t\t= $body;\n\t\t$mail->AltBody\t= str_replace('<br/>', \"\\n\", $body);\n\n\t\t// go through empl\n\t foreach ($users as $user) {\n\t \t// we sent a seperate email to every single user.\n\t \t$userlist[] = $user['user_id'];\n\t \t$mail->AddAddress($user['email'], $user['name']);\n\t \t$mail->Send();\n\t \t$mail->ClearAddresses();\n\t }\n\n\t if(sm_get_conf('log_email')) {\n\t \t// save to log\n\t \tsm_add_log($this->server['server_id'], 'email', $body, implode(',', $userlist));\n\t }\n\t}", "public function sendRestoreEmail();", "public function payForInvitedUsers(){\n \n $userService = parent::getService('user','user');\n \n $refererUsers = $userService->getUsersWithRefererNotPaid();\n foreach($refererUsers as $user):\n // if created at least 30 days ago\n if(strtotime($user['created_at'])>strtotime('-30 days')){\n continue;\n }\n // if logged within last 5 days ago\n if(!(strtotime($user['last_active'])>strtotime('-7 days'))){\n $user->referer_not_active = 1;\n $user->save();\n continue;\n }\n \n $values = array();\n $values['description'] = 'Referencing FastRally to user '.$user['username'];\n $values['income'] = 1;\n \n \n if($user['gold_member_expire']!=null){\n $amount = 100;\n }\n else{\n $amount = 10;\n }\n \n \n $userService->addPremium($user['referer'],$amount,$values);\n $user->referer_paid = 1;\n $user->save();\n endforeach;\n echo \"done\";exit;\n }", "public function sendCancellationMailToParticipants($a_participants_ids) {\r\n\t\tforeach (array_unique($a_participants_ids) as $participant_id) {\r\n\t\t\t$this->composeRemovingParticipantFromBookingAsMailForParticipant($participant_id);\r\n\t\t\tparent::sendMail(array( $participant_id ), array( 'system' ), is_numeric($participant_id));\r\n\t\t}\r\n\t}", "private static function send_reminder_digest( $domains ) {\n $reminder_recipient = self::get_reminder_recipient();\n $tdata = array(\n 'site_name' => get_bloginfo( 'name' ),\n 'domains' => $domains\n );\n $admin_email = get_bloginfo( 'admin_email' );\n $addl_headers = array(\n 'Reply-To' => $admin_email,\n 'From' => sprintf( __( 'Stashbox - %s <%s>', 'th' ), $tdata['site_name'], $admin_email )\n );\n $message = Template::make( 'domain/email-expiration_reminder', $tdata, false );\n add_filter( 'wp_mail_content_type', array( __CLASS__, 'send_html_mail' ) );\n $sent = wp_mail( $reminder_recipient, __( 'Stashbox Expiring Domain Reminder', 'th' ), $message, $addl_headers );\n if( !$sent ) {\n remove_filter( 'wp_mail_content_type', array( __CLASS__, 'send_html_mail' ) );\n error_log( 'Failed to send message. Result: '.serialize( $sent ) );\n return false;\n } else {\n remove_filter( 'wp_mail_content_type', array( __CLASS__, 'send_html_mail' ) );\n return true;\n }\n }", "public function decline()\n {\n\n if($this->user['menteer_type']==37 && $this->user['is_matched'] > 0 && $this->user['match_status']=='pending') {\n\n // mentor update\n $update_user = array(\n 'id' => $this->session->userdata('user_id'),\n 'data' => array('is_matched' => '0'),\n 'table' => 'users'\n );\n $this->Application_model->update($update_user);\n\n // mentee update\n $update_user = array(\n 'id' => $this->user['is_matched'],\n 'data' => array('is_matched' => '0'),\n 'table' => 'users'\n );\n $this->Application_model->update($update_user);\n\n $mentee = $this->Application_model->get(array('table'=>'users','id'=>$this->user['is_matched']));\n\n // notify mentee\n\n $data = array();\n $data['first_name'] = $this->user['first_name'];\n $data['last_name'] = $this->user['last_name'];\n\n $message = $this->load->view('/chooser/email/decline', $data, true);\n $this->email->clear();\n $this->email->from($this->config->item('admin_email', 'ion_auth'), $this->config->item('site_title', 'ion_auth'));\n $this->email->to($mentee['email']);\n $this->email->subject('Mentor has declined');\n $this->email->message($message);\n\n $result = $this->email->send(); // @todo handle false send result\n\n $this->session->set_flashdata('message', '<div class=\"alert alert-success\">The Mentee has been notified.</div>');\n redirect('/dashboard');\n\n }else{\n\n redirect('/dashboard');\n\n }\n\n }", "public function remind(){\r\n\t\t\r\n\t\tif($this->logged_in){\r\n\t\t\turl::redirect(\"user/profile\",301);\r\n\t\t\texit;\r\n\t\t}\r\n\t\t\r\n\t\t$post_token = $this->input->post(\"token\",null,true);\r\n\t\t$sess_token = Session::instance()->get(\"token\",null);\r\n\t\t\r\n\t\t//stylesheet::add(array());\r\n\t\tjavascript::add(array(\r\n 'jquery.validate',\r\n 'jquery.validate.lang/ru',\r\n ));\r\n\t\t\r\n\t\tif(!empty($post_token) && $post_token == $sess_token){\r\n\t\t\t\r\n\t\t\t$password = $this->input->post(\"password\",null,true);\r\n\t\t\t$confirm_password = $this->input->post(\"confirm_password\",null,true);\r\n\t\t\t\r\n\t\t\r\n\t\t\t\r\n\t\t\tif(\t!empty($password) &&\r\n\t\t\t\t!empty($confirm_password) &&\r\n\t\t\t\t$password == $confirm_password\t)\r\n\t\t\t\t {\r\n\t\t\t\t\r\n\t\t\t\t \t$user_id = Session::instance()->get(\"user_id\",null);\r\n\t\t\t\t \t$activation_remind = Session::instance()->get(\"activation\",null);\r\n\t\t\t\t \t\r\n\t\t\t\t \t$user = ORM::factory('user')->where(array('id'=>$user_id,\"activation\" => $activation_remind, \"pwd_change\" => 1))->find();\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(!empty($user->id)){\r\n\t\t\t\t\t\t$user->password = $password;\r\n\t\t\t\t\t\t$user->pwd_change = 0;\r\n\t\t\t\t\t\t$user->activation = '';\r\n\t\t\t\t\t\t$user->save();\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t$email = new View('reminder_email_success');\r\n\t\t\t\t\t\t$email->username = $user->username;\r\n\t\t\t\t\t\t$email->sitename = Kohana::config('config.site_name');\r\n\t\t\t\t\r\n\t\t\t\t\t\temail::send(\r\n\t\t\t\t\t\t\t$user->email,\r\n\t\t\t\t\t\t\tKohana::config('config.site_email'),\r\n\t\t\t\t\t\t\tKohana::config('config.sitename') . \" / \" . Kohana::lang('user.reminder_subject'),\r\n\t\t\t\t\t\t\t$email->render(),\r\n\t\t\t\t\t\t\tTRUE\r\n\t\t\t\t\t\t);\r\n\t\t\t\t\r\n\t\t\t\t\t\t$_POST = null;\r\n\t\t\t\t\t\tAuth::instance()->force_login($user);\r\n\t\t\t\t\t\t$new_view = new View('remind_success');\r\n\t\t\t\t\t\t$new_view->lang = Kohana::lang('user');\r\n\t\t\t\t\t\t$new_view->logged_in = true;\r\n\t\t\t\t\t\t$new_view->user = $user;\r\n\t\t\t\t\t\t$new_view->render(true);\r\n\t\t\t\t\t\texit;\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t$view->error = Kohana::lang('user.remind_disabled');\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\t$view->error = Kohana::lang('user.pwd_doesnt_match');\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t\t$activation_remind = $this->uri->segment(3);\r\n\r\n\t\tif(!empty($activation_remind)){\r\n\t\t\t\r\n\t\t\t$user = ORM::factory('user')->where(array(\"activation\" => $activation_remind, \"pwd_change\" => 1))->find();\r\n\t\t\tif(!empty($user->id)){\r\n\t\t\t\t\r\n\t\t\t\t$view = new View('remindpwd_form');\r\n\t\t\t\t$view->lang = Kohana::lang('user');\r\n\t\t\t\t$view->lang['title'] = $view->lang['password_change'];\r\n\t\t\t\t\r\n\t\t\t\t$token = md5(uniqid());\r\n\t\t\t\t$view->token = $token;\r\n\t\t\t\t$view->activation = $activation_remind;\r\n\t\t\t\tSession::instance()->set(\"token\",$token);\r\n\t\t\t\tSession::instance()->set(\"user_id\", $user->id);\r\n\t\t\t\tSession::instance()->set(\"activation\", $activation_remind);\r\n\t\t\t\t\r\n\t\t\t\t$view->title = Kohana::lang('user.password_reminder_title') . ' | ' . Kohana::config('core.sitename');\r\n\t\t\t\t//var_dump($token);\r\n\t\t\t\t$view->render(true);\r\n\t\t\t\t\r\n\t\t\t} else {\r\n\t\t\t\tKohana::show_404();\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\tKohana::show_404();\r\n\t\t}\r\n\t\t\r\n\t}", "function invite_members($user_array, $group, $owner = NULL) {\n global $eh;\n $total = count($user_array);\n for ($i = 0; $i < $total; $i++) {\n $this->invite_member($user_array[$i], $group, $owner);\n }\n $eh->flush();\n e(lang(\"invitations_sent\"), \"m\");\n }", "public function new_coin_announcement(){\n \n \n// $user = User::find( 19 );\n $users = User::all();\n \n \n// echo $user->full_name;\n// echo \"<br>\";\n// echo \"<pre>\";\n// // print_r( $user);\n// exit;\n\n\n foreach( $users as $user ){\n $email_data = array(\n 'userfullname' => isset($user->full_name) ? $user->full_name : ''\n );\n\n $data = array( 'data' => $email_data );\n Mail::send( 'email_templates.newCoinAnnouncement', $data, function($message) use ( $user ) {\n $message->to( $user->email, $user->full_name )->subject\n ( 'New coins added to WooCommerce Altcoin Payment Gateway' );\n $message->from( '[email protected]', 'CodeSolz Team' );\n });\n }\n \n echo 'Email sent!';\n \n }", "function sendEmails($row, $config) {\r\n\t\tif ($row->act == 'upgrade') {\r\n\t\t\tOSMembershipHelper::sendMembershipUpgradeEmails($row, $config) ;\r\n\t\t\treturn ;\r\n\t\t} elseif ($row->act == 'renew') {\r\n\t\t\tOSMembershipHelper::sendMembershipRenewalEmails($row, $config) ;\r\n\t\t\treturn ;\r\n\t\t}\r\n\t\t$jconfig = new JConfig();\r\n\t\t$db = & JFactory::getDBO();\r\n\t\t$fromEmail = $jconfig->mailfrom;\r\n\t\t$fromName = $jconfig->fromname;\r\n\t\t$sql = \"SELECT * FROM #__osmembership_plans WHERE id=\".$row->plan_id ;\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$plan = $db->loadObject();\r\n\t\t//Need to over-ridde some config options\r\n\t\t$emailContent = OSMembershipHelper::getEmailContent($config, $row);\r\n\t\t$replaces = array() ;\r\n\t\t$replaces['plan_title'] = $plan->title ;\r\n\t\t$replaces['first_name'] = $row->first_name ;\r\n\t\t$replaces['last_name'] = $row->last_name ;\r\n\t\t$replaces['organization'] = $row->organization ;\r\n\t\t$replaces['address'] = $row->address ;\r\n\t\t$replaces['address2'] = $row->address ;\r\n\t\t$replaces['city'] = $row->city ;\r\n\t\t$replaces['state'] = $row->state ;\r\n\t\t$replaces['zip'] = $row->zip ;\r\n\t\t$replaces['country'] = $row->country ;\r\n\t\t$replaces['phone'] = $row->phone ;\r\n\t\t$replaces['fax'] = $row->phone ;\r\n\t\t$replaces['email'] = $row->email ;\r\n\t\t$replaces['comment'] = $row->comment ;\r\n\t\t$replaces['amount'] = number_format($row->amount, 2) ;\r\n\t\t$replaces['discount_amount'] = number_format($row->discount_amount, 2) ;\r\n\t\t$replaces['tax_amount'] = number_format($row->tax_amount, 2) ;\r\n\t\t$replaces['gross_amount'] = number_format($row->gross_amount, 2) ;\r\n\t\t\t\t\t\t\t\t\r\n\t\t$replaces['from_date'] = JHTML::_('date', $row->from_date, $config->date_format);\r\n\t\t$replaces['to_date'] = JHTML::_('date', $row->to_date, $config->date_format);\r\n\t\t\r\n\t\t$replaces['transaction_id'] = $row->transaction_id ;\r\n\t\tif ($row->payment_method) {\r\n\t\t\t$replaces['payment_method'] = JText::_(os_payments::loadPaymentMethod($row->payment_method)->title) ;\r\n\t\t}\t\t\r\n\t\t//Should we create map to custom fields\r\n\t\t$sql = 'SELECT field_id, field_value FROM #__osmembership_field_value WHERE subscriber_id = '.$row->id;\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$rowValues = $db->loadObjectList();\r\n\t\t$sql = 'SELECT a.id, a.name FROM #__osmembership_fields AS a WHERE a.published=1 AND (a.plan_id = 0 OR a.plan_id='.$row->plan_id.')';\r\n\t\t$db->setQuery($sql) ;\r\n\t\t$rowFields = $db->loadObjectList();\r\n\t\t$fields = array() ;\r\n\t\tfor ($i = 0 , $n = count($rowFields) ; $i < $n ; $i++) {\r\n\t\t\t$rowField = $rowFields[$i] ;\r\n\t\t\t$fields[$rowField->id] = $rowField->name ;\r\n\t\t}\r\n\t\tfor ($i = 0 , $n = count($rowValues) ; $i < $n ; $i++) {\r\n\t\t\t$rowValue = $rowValues[$i] ;\r\n\t\t\t$replaces[$fields[$rowValue->field_id]] = $rowValue->field_value ;\r\n\t\t}\r\n\t\t//Over-ridde email message\t\t\r\n\t\t$subject = $config->user_email_subject;\r\n\t\tif ($row->payment_method == 'os_offline') {\r\n\t\t\t$body = $config->user_email_body_offline ;\r\n\t\t} else {\r\n\t\t\t$body = $config->user_email_body ;\r\n\t\t}\r\n\t\t$subject = str_replace('[PLAN_TITLE]', $plan->title, $subject) ;\r\n\t\t$body = str_replace('[SUBSCRIPTION_DETAIL]', $emailContent, $body) ;\r\n\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t$key = strtoupper($key) ;\r\n\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t}\t\t\r\n\t\tif (version_compare(JVERSION, '3.0', 'ge')) {\r\n\t\t\t$j3 = true ;\r\n\t\t\t$mailer = new JMail() ;\r\n\t\t} else {\r\n\t\t\t$j3 = false ;\r\n\t\t}\r\n\t\tif ($j3)\r\n\t\t\t$mailer->sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\telse\r\n\t\t\tJUtility::sendMail($fromEmail, $fromName, $row->email, $subject, $body, 1);\r\n\t\t//Send emails to notification emails\r\n\t\tif ($config->notification_emails == '')\r\n\t\t\t$notificationEmails = $fromEmail;\r\n\t\telse\r\n\t\t\t$notificationEmails = $config->notification_emails;\r\n\t\t$notificationEmails = str_replace(' ', '', $notificationEmails);\r\n\t\t$emails = explode(',', $notificationEmails);\t\t\r\n\t\t$subject = $config->admin_email_subject ;\r\n\t\t$subject = str_replace('[PLAN_TITLE]', $plan->title, $subject) ;\r\n\t\t$body = $config->admin_email_body ;\r\n\t\t$body = str_replace('[SUBSCRIPTION_DETAIL]', $emailContent, $body);\r\n\t\tforeach ($replaces as $key=>$value) {\r\n\t\t\t$key = strtoupper($key) ;\r\n\t\t\t$body = str_replace(\"[$key]\", $value, $body) ;\r\n\t\t}\r\n\t\tfor ($i = 0, $n = count($emails); $i < $n ; $i++) {\r\n\t\t\t$email = $emails[$i];\r\n\t\t\tif ($j3)\r\n\t\t\t\t$mailer->sendMail($fromEmail, $fromName, $email, $subject, $body, 1);\r\n\t\t\telse\r\n\t\t\t\tJUtility::sendMail($fromEmail, $fromName, $email, $subject, $body, 1);\r\n\t\t}\r\n\t}", "public function email_approver()\n {\n \n $this->db->select('EMAIL');\n $this->db->from('APPROVERS');\n $this->db->where('UNIT',$_SESSION['div']);\n $query = $this->db->get();\n $out = $query->result_array();\n\n if ($out) {\n\n \n foreach ($out as $recipient){\n \n //mail to approver\n $this->load->library('email');\n $htmlContent = '<h1>Title change requested in FREE System.</h1>';\n $htmlContent .= '<p>Please review the <a href=\"' . base_url() . '/admin\">Approval Control Panel</a> to review the request.</p>';\n \n $this->email->clear();\n\n $config['mailtype'] = 'html';\n $this->email->initialize($config);\n $this->email->to($recipient);\n $this->email->from('[email protected]', 'FREE System');\n $this->email->subject('Title Change Requested');\n $this->email->message($htmlContent);\n $this->email->send();\n }\n }\n }", "public function getNewMailsAction()\n {\n $this->View()->success = true;\n $mails = $this->container->get('dbal_connection')->fetchAll('SELECT id, subject, receiverAddress FROM s_plugin_mailcatcher WHERE id > :id ORDER BY id ASC', ['id' => $this->Request()->getParam('id')]);\n $this->View()->mails = $mails;\n }", "function emailRegistrationAdmin() {\n require_once ('com/tcshl/mail/Mail.php');\n $ManageRegLink = DOMAIN_NAME . '/manageregistrations.php';\n $emailBody = $this->get_fName() . ' ' . $this->get_lName() . ' has just registered for TCSHL league membership. Click on the following link to approve registration: ';\n $emailBody.= $ManageRegLink;\n //$sender,$recipients,$subject,$body\n $Mail = new Mail(REG_EMAIL, REG_EMAIL, REG_EMAIL_SUBJECT, $emailBody);\n $Mail->sendMail();\n }", "function addAdminsAsRecipients(){\n $sql = \"SELECT name FROM user WHERE is_admin = 1\";\n $db = new DB();\n $db->query( $sql );\n while( $row = $db->fetchRow()){\n $this->AddRecipient($row[\"name\"]);\n }\n }", "public function clearAllRecipients()\n {\n }", "function daily_update_property_email(){\n\t\t$meta_post = $this->InteractModal->get_update_post_meta();\n\t\tif(!empty($meta_post)){\n\t\t\t$data = array();\n\t\t\tforeach($meta_post as $meta_details){\n\t\t\t\t$user_id = $this->InteractModal->get_post_meta($meta_details['post_id'],'initiator_id');\n\t\t\t\t$data[$user_id][]= $meta_details['meta_key'];\n\t\t\t}\n\t\t}\t\t\n\t\t$get_data=$this->InteractModal->get_today_data();\n\t\t$id=2;\n\t\tif(!empty($get_data)){\n\t\t\t$result = array();\n\t\t\tforeach ($get_data as $element) {\n\t\t\t\t$result[$element['user_id']][]= $element['task_type'];\n\t\t\t}\n\t\t\tif(!empty($data) && (!empty($result))){\n\t\t\t\t$results = array_merge($data,$result);\n\t\t\t}\n\t\t\t$user_id= '';\n\t\t\tif(!empty($results)){\n\t\t\t\tforeach($result as $user_id=>$value):\n\t\t\t\t\t$update_details='';\n\t\t\t\t\t$value = array_unique($value);\n\t\t\t\t\tforeach($value as $values):\t\t\t\t\t\t\n\t\t\t\t\t\t$update_details=$update_details.'Today '.ucwords($values).' Successfully.<br>';\n\t\t\t\t\tendforeach;\n\t\t\t\t\tif(!empty($user_id)){\n\t\t\t\t\t\t$where = array( 'id' =>$user_id);\n\t\t\t\t\t\t$user_data=$this->InteractModal->single_field_value('users',$where);\n\t\t\t\t\t\techo $email= $user_data[0]['user_email'];\n\t\t\t\t\t\techo \"<br>\";\n\t\t\t\t\t\t$company_id = $this->InteractModal->get_user_meta( $user_id, 'company_id');\n\t\t\t\t\t\t///get auto email content data \n\t\t\t\t\t\t$status_template = $this->InteractModal->get_user_meta( $company_id, 'status_template_id_'.$id );\n\t\t\t\t\t\tif(($status_template ==1)){\n\t\t\t\t\t\t\t$subject = $this->InteractModal->get_user_meta( $company_id, 'subject_template_id_'.$id );\n\t\t\t\t\t\t\t$content = $this->InteractModal->get_user_meta( $company_id, 'content_template_id_'.$id );\n\t\t\t\t\t\t\t$user_name = $this->InteractModal->get_user_meta( $user_id, 'concerned_person');\n\t\t\t\t\t\t\t$phone_number = $this->InteractModal->get_user_meta( $user_id, 'phone_number');\n\t\t\t\t\t\t\t$logo_content = '<img src=\"'.base_url().'/assets/img/profiles/logo_(2).png\" height=\"auto\" width=\"100\" alt=\"Logo\">'; \t\t\t\t\t\t\n\t\t\t\t\t\t\t$content=nl2br($content);\n\t\t\t\t\t\t\t$content = str_replace(\"_NAME_\",$user_name,$content);\n\t\t\t\t\t\t\t$content = str_replace(\"_PHONE_\",$phone_number,$content);\n\t\t\t\t\t\t\t$content = str_replace(\"_EMAIL_\",$email,$content);\n\t\t\t\t\t\t\t$content = str_replace(\"_LOGO_\",$logo_content,$content);\n\t\t\t\t\t\t\t$content = str_replace(\"_DATE_\",date('d-F-Y'),$content);\n\t\t\t\t\t\t\t$content = $content.'<br>'.$update_details;\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t$template_list = $this->InteractModal->get_email_template($id);\n\t\t\t\t\t\t\tforeach( $template_list as $template_lists ):\n\t\t\t\t\t\t\t\t$subject = $template_lists['subject']; \n\t\t\t\t\t\t\t\t$content = $update_details; \n\t\t\t\t\t\t\tendforeach;\t\t\t\t\n\t\t\t\t\t\t}\t\t\t\t\n\t\t\t\t\t\t///get auto email content data \t\t\t\t\n\t\t\t\t\t\t$email_data = array('email' => $email,\n\t\t\t\t\t\t\t'content' => $content,\n\t\t\t\t\t\t\t'subject' => $subject\n\t\t\t\t\t\t);\n\t\t\t\t\t\t$this->send_email($email_data);\n\t\t\t\t\t} \n\t\t\t\tendforeach;\n\t\t\t}\n\t\t}\n\t}", "public function invitationsRecus() {\n \n return DB::table('invitation')\n ->where('emetteur_id', $this->id)\n ->where('recepteur_id', Auth::User()->id)\n ->where('status', 0)\n ->exists();\n\n }", "public function resendEmail()\n {\n $query = users::where('email', session('notice'))->first();\n // Sending Welcome Email\n Mail::to(session('notice')['email'])->send(new welcome($query->token));\n return view('auth.emailVerification');\n }", "private function downmailer($id)\n {\n //server\n $server = Servers::with('servers_status')->where('server_id', $id)->firstOrFail();\n $server_name = $server->server_name;\n $server_status = $server->servers_status->server_status;\n //apps\n $server_apps = ServerApp::where('server_id', $id)->get();\n\n //find the apps\n foreach ($server_apps as $serverapp)\n {\n $app_id = $serverapp->app_id;\n $subject =\"prin6 notificatie\";\n $appfunctionaladmincount = $this->countAppFunctionalAdmin($app_id);\n //check if persons exist\n if ($appfunctionaladmincount >=1){\n //find the persons\n $appfunctionaladmin = App_FunctionalAdmin::with('persons')->where('app_id', $app_id)->get();\n \n foreach ($appfunctionaladmin as $functionaladmin)\n {\n $person_mail = $functionaladmin->persons->person_email;\n //run the mails\n if (filter_var($person_mail, FILTER_VALIDATE_EMAIL)) {\n if (!is_null($person_mail)){\n Mail::to($person_mail)->send(new DownNotifyMail($server_status,$server_name,$person_mail));\n }\n } \n }\n } \n $apptechadmincount = $this->countAppTechAdmin($app_id);\n if($apptechadmincount >=1){\n $apptechadmin = App_TechAdmin::with('persons')->where('app_id', $app_id)->get();\n foreach ($apptechadmin as $techadmin)\n {\n $person_techmail = $techadmin->persons->person_email;\n //run the mails\n if (filter_var($person_techmail, FILTER_VALIDATE_EMAIL)) {\n if (!is_null($person_techmail)){\n Mail::to($person_techmail)->send(new DownNotifyMail($server_status,$server_name,$person_techmail));\n }\n } \n }\n }\n \n\n }\n }", "static function sendUnmemberMail($user) {\t\r\n\t\tif (!MAIL || !$user->isLoaded()) return;\r\n\t\t\r\n\t\t$mailTemplate = new Art_Model_Email_Template(array(\r\n\t\t\t'name' => static::EMAIL_TEMPLATE_UNMEMBER)\r\n\t\t);\r\n\t\t\r\n\t\tif (!$mailTemplate->isLoaded()) {\r\n\t\t\treturn;\r\n\t\t}\r\n\t\t\r\n\t\t$userData = $user->getData();\r\n\t\tif ($userData->gender) {\r\n\t\t\t$genderEnd = '';\r\n\t\t\t$salutation = static::DEAR_SIR.$userData->salutation.',';\r\n\t\t} else {\r\n\t\t\t$genderEnd = 'a';\r\n\t\t\t$salutation = static::DEAR_MADAM.$userData->salutation.',';\r\n\t\t}\r\n\t\t\r\n\t\t$footer = Helper_Default::getDefaultValue(Helper_TBDev::DEFAULT_MAIL_FOOTER);\r\n\t\t$body = Art_Model_Email_Template::replaceIdentities(array('salutation' => $salutation,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'date_termination' => nice_date('now'),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'genderEnd' => $genderEnd,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'footer' => $footer),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t$mailTemplate->body);\r\n\t\tstatic::sendMailUsingTemplate($mailTemplate, $body, $userData->email);\r\n\t}", "public function resendActivationEmail()\n {\n $breadCrumb = $this->userEngine\n ->breadcrumbGenerate('resend-activation-email');\n\n return $this->loadPublicView('user.resend-activation-email', $breadCrumb['data']);\n }", "public function inviteuserforevent(Request $request)\n\t{\n\t\tif ($request->isMethod('post')) \n\t\t{\n $data = $request->all();\n\t\t\t\n\t\t\t$user_id = $data['friend_id'];\n\t\t\t$event_id = $data['event_id'];\n\t\t\t$login_user = Auth::guard('user')->user(); // login user\n\t\t\t\n\t\t\t$user = User::where('id', $user_id)->first(); // user who invite\n\t\t\t$events = events::where('id', $event_id)->first(); // event data\n\t\t\t\n\t\t\t$invite_friend_data = invite_users::where('friend_id', $user_id)\n ->where('event_id', $event_id)->get()->first();\n\t\t\tif(count($invite_friend_data)==0)\n\t\t\t{\n\t\t\t\t$insert_data['user_id'] = $login_user->id;\n\t\t\t\t$insert_data['event_id'] = $event_id;\n\t\t\t\t$insert_data['friend_id'] = $user_id;\n\t\t\t\t$insert_data['transaction_id'] = \"\";\n\t\t\t\t$insert_data['created_at'] = date('Y-m-d h:m:s');\n\t\t\t\tinvite_users::insert($insert_data);\n\t\t\t\n\t\t\t\t$notification['user_id'] = $user_id;\n\t\t\t\t$notification['another_user'] = $login_user->id;\n\t\t\t\t$notification['notification'] = '<strong>'.$login_user->name.'</strong> invited you to his <strong>'.$events->title.'</strong> Gathering';//'invited you to his';\n\t\t\t\t$notification['event_id'] = $event_id;\n\t\t\t\t$notification['notification_type'] = 'invite';\n\t\t\t\t$notification['is_seen'] = 0;\n\t\t\t\t$notification['created_at'] = date('Y-m-d h:m:s');\n\t\t\t\tnotifications::insert($notification);\n\t\t\t}\n\t\t\t\n\t\t\tMail::send('emails.send_payment_link_for _event', ['login_user' => $login_user, 'invite_user' => $user, 'event' => $events], function ($message) use($user) {\n\t\t\t\t$message->to($user->email, 'giveadinnerparty.com')->subject('Invitation for a dinner party');\n\t\t\t});\n\t\t}\t\n }", "public function resendInvitation(ResendUserInvite $request)\n {\n $user = User::where('uuid', $request->input('user'))->first();\n $company = Company::where('uuid', session('company'))->first();\n\n // create invitation\n $invitation = Invite::create([\n 'company_uuid' => session('company'),\n 'created_by_uuid' => session('user'),\n 'subject_uuid' => $company->uuid,\n 'subject_type' => Utils::getMutationType($company),\n 'protocol' => 'email',\n 'recipients' => [$user->email],\n 'reason' => 'join_company'\n ]);\n\n // notify user\n $user->notify(new UserInvited($invitation));\n\n return response()->json(['status' => 'ok']);\n }", "public function api_entry_sendnotification() {\n parent::validateParams(array('sender', 'receiver', 'subject'));\n\n if(!$this->Mdl_Users->get($_POST['sender'])) parent::returnWithErr(\"Sender is not valid\");\n if(!$this->Mdl_Users->get($_POST['receiver'])) parent::returnWithErr(\"Receiver is not valid\");\n\n $sender = $this->Mdl_Users->get($_POST['sender']);\n $receiver = $this->Mdl_Users->get($_POST['receiver']);\n\n unset($sender->password);\n unset($receiver->password);\n\n if ($_POST['subject'] == \"ipray_sendinvitation\") {\n $msg = $sender->username . \" has invited you.\";\n }\n else if ($_POST['subject'] == \"ipray_acceptinvitation\") {\n $msg = $sender->username . \" has accepted your invitation.\";\n\n // sender ---> receiver \n $this->Mdl_Users->makeFriends($_POST[\"sender\"], $_POST[\"receiver\"]);\n }\n else if ($_POST['subject'] == \"ipray_rejectinvitation\") {\n $msg = $sender->username . \" has rejected your invitation.\";\n }\n else if ($_POST['subject'] == 'ipray_sendprayrequest') {\n parent::validateParams(array('request'));\n }\n else if ($_POST['subject'] == 'ipray_acceptprayrequest') {\n parent::validateParams(array('request'));\n }\n else if ($_POST['subject'] == 'ipray_rejectprayrequest') {\n parent::validateParams(array('request'));\n }\n else {\n parent::returnWithErr(\"Unknown subject is requested.\");\n }\n\n if (!isset($receiver->devicetoken) || $receiver->devicetoken == \"\")\n parent::returnWithErr(\"User is not available at this moment. Please try again later.\");\n\n $payload = array(\n 'sound' => \"default\",\n 'subject' => $_POST['subject'],\n 'alert' => $msg,\n 'sender' => $sender,\n 'receiver' => $receiver\n );\n\n if (($failedCnt = $this->qbhelper->sendPN($receiver->devicetoken, json_encode($payload))) == 0) {\n $this->load->model('Mdl_Notifications');\n $this->Mdl_Notifications->create(array(\n 'subject' => $_POST['subject'],\n 'message' => $msg,\n 'sender' => $sender->id,\n 'receiver' => $receiver->id\n ));\n\n parent::returnWithoutErr(\"Contact request has been sent successfully.\");\n }\n else {\n parent::returnWithErr($failedCnt . \" requests have not been sent.\");\n }\n \n }", "function showInvites()\n{\n //we get all invites in a variable\n $pendingInvites = GroupDAO::getAllPendingInvites();\n \n //we initialize a counter\n $countUserInvite = 0;\n //we check every invite of the database\n foreach ($pendingInvites as $key => $value) {\n //if an invite is for our user, we show it to him\n if ($value['Id_User'] == $_SESSION['userID']) {\n //we increment our counter\n $countUserInvite++;\n echo \"<tr><td>Vous avez été invité à rejoindre le groupe \" . GroupDAO::getGroupById($value['Id_Group'])['Nm_Group'] . \" !</td><td><button class=\\\"btn btn-success\\\" type=\\\"submit\\\" value=\\\" \" . $value['Id_Group'] . \"\\\" name=\\\"accept\\\">✓</button></td><td><button class=\\\"btn btn-danger\\\" type=\\\"submit\\\" value=\\\" \" . $value['Id_Group'] . \"\\\" name=\\\"delete\\\">X</button></td></tr>\";\n }\n }\n //if our user have 0 invites, we show him a message telling him to comme back later to check if he got a new invite\n if ($countUserInvite == 0) {\n echo \"<tr><td>Aucune invitation pour le moment... </td></tr><tr><td>Revenez plus tard</td></tr>\";\n }\n}", "public function resendmailAction() {\n \n $modelPlugin = $this->modelplugin();\n $mailplugin = $this->mailplugin();\n $phpprenevt = $this->phpinjectionpreventplugin(); \n $jsonArray = $modelPlugin->jsondynamic();\n $userid = $this->sessionid;\n $dynamicPath = $protocol . $jsonArray['domain']['domain_name'];\n $from = $jsonArray['sendgridaccount']['addfrom'];\n\n $encryptedPassword = base64_encode(\"#$#\" . base64_encode(base64_encode($userid . rand(10, 100)) . \"###\" . base64_encode($userid) . \"###\" . base64_encode($userid . rand(10, 100)) . \"###\" . base64_encode(base64_encode($userid . rand(10, 100)))) . \"#$#\");\n $buttonclick = $dynamicPath . \"/Gallery/galleryview/\" . $encryptedPassword;\n $mail_link = \"<a href='\" . $buttonclick . \"' style='background-color: #04ad6a; border: medium none; border-radius: 19px; padding: 12px; color: #fff; text-align: center; text-decoration: none; text-transform: uppercase;'>Click here</a>\";\n\n if (empty($userid)) {\n $userid = $phpprenevt->stringReplace($_POST['loginId']);\n }\n $publisheridarray = array('publisherId' => $userid);\n $selectid = $modelPlugin->getpublisherTable()->selectEmail($publisheridarray);\n $mail = $selectid[0]['email'];\n $keyArray = array('mailCatagory' => 'R_MAIL');\n $getMailStructure = $modelPlugin->getconfirmMailTable()->fetchall($keyArray);\n $getmailbodyFromTable = $getMailStructure[0]['mailTemplate'];\n\n $activationLinkreplace = str_replace(\"|ACTIVATIONLINK|\", $mail_link, $getmailbodyFromTable);\n $mailBody = str_replace(\"|DYNAMICPATH|\", $dynamicPath, $activationLinkreplace);\n $subject = \"Confirm your email address\";\n $mailfunction = $mailplugin->confirmationmail($mail, $from, $subject, $mailBody);\n $res['response'] = 1;\n echo json_encode($res);\n exit;\n }", "public function deletedusers($userid=0){\n if(!$this->phpsession->get('ciAdmId')){ redirect($this->config->item('base_url').'r/k/admin'); }\n\n if($userid > 0){\n //resend verification mail to user\n $___user = $this->U_Model->getUserById($userid);\n\n $activationcode = $___user->activationcode;\n $verification_code=$userid * 32765;\n // Create link for verification\n $link = \"<a href='\".$this->config->item('base_url').\"register/registerverify/\".$activationcode.\"'>\".$this->config->item('base_url').\"register/registerverify/\".$activationcode.\"</a>\";\n\n $this->load->model('SystemEmail_Model','SE_Model');\n\n $admin_email= $this->SE_Model->getAdminEmails();\n $mail_content= $this->SE_Model->getEmailById(1);\n \n //Email Sending Code\n $this->load->library('email');\n $this->email->from($admin_email->value,'fashionesia');\n $this->email->to($___user->email); // \n $this->email->subject($mail_content->subject);\n\n $message = str_replace(\"[link]\", $link, $mail_content->message);\n $message = str_replace(\"[[username]]\", $___user->first_name, $message);\n $message = str_replace(\"[[email]]\", $___user->email, $message);\n \n $content_message = str_replace(\"[sitename]\", $this->config->item('base_site_name'), $message);\n\n $emailPath = $this->config->item('base_abs_path').\"templates/\".$this->config->item('base_template_dir');\n $email_template = file_get_contents($emailPath.'/email/email.html');\n \n\n $email_template = str_replace(\"[[EMAIL_HEADING]]\", $mail_content->subject, $email_template);\n $email_template = str_replace(\"[[EMAIL_CONTENT]]\", nl2br(utf8_encode($content_message)), $email_template);\n $email_template = str_replace(\"[[SITEROOT]]\", $this->config->item('base_url'), $email_template);\n $email_template = str_replace(\"[[LOGO]]\",$this->config->item('base_url').\"templates/\".$this->config->item('base_template_dir'), $email_template);\n\n $this->email->message(html_entity_decode(($email_template)));\n\n //echo html_entity_decode(($email_template));\n\n $this->email->send();\n\n $this->phpsession->save('success_msg',\"Verification email successfully send to '\".$___user->first_name.\" \".$___user->last_name.\"'.\");\n\n redirect($this->config->item('base_url').\"admin/users/\");\n \n }\n\n $data = array('users' => '', 'PAGING' => '', 'search' => '-','delete'=>'-','fn'=>'-','status'=>'-');\n $this->load->helper(array('pagination'));\n $array = $this->uri->uri_to_assoc(3);\n\n $pages = (@$array['pages']?$array['pages']:1);\n $page = (@$array['page']?$array['page']:1);\n\n $orderb = (@$array['orderby']?@$array['orderby']:\"asc\"); $data['orderby'] = $orderb;\n $fn = (@$array['fn']?@$array['fn']:\"first_name\"); $data['fn'] = $fn;\n $status = (@$array['status']?@$array['status']:\"-\"); $data['status'] = $status; \n $orderby = $fn.\" \".$orderb;\n\n $data['search'] = (@$array['search']?$array['search']:'-');\n $data['delete'] = (@$array['delete']?$array['delete']:'-');\n\n \n if(strlen(trim($this->input->post('submit'))) > 0){\n $user_ids = implode(\",\",$this->input->post('checbox_ids'));\n $action = $this->input->post('action');\n if($action=='delete'){$action = 'permanentdelete';}\n $message = $this->U_Model->users_operations(array('user_ids' => $user_ids),$action);\n //$this->phpsession->save('success_msg',$message);\n $this->message->setMessage($message,\"SUCCESS\");\n }\n\n $PAGE = $page;\n $PAGE_LIMIT = $this->U_Model->countDeletedUsersBySearch($data['search'],$data['delete'],$status); //20;\n $DISPLAY_PAGES = 25;\n $PAGE_LIMIT_VALUE = ($PAGE - 1) * $PAGE_LIMIT;\n\n if($this->input->post('delete')!='')\n {\n// $delete = explode(\"-\",$this->input->post('datepicker'));\n// $delete_date = $delete[2].\"-\".$delete[0].\"-\".$delete[1];\n $data['delete'] =$this->input->post('delete');\n }\n // Get posted search value in variables\n $data['search'] = ($this->input->post('search')?trim($this->input->post('search')):$data['search']);\n $data['delete'] = ($this->input->post('delete')?trim($this->input->post('delete')):$data['delete']);\n \n // Count total users\n $total = $this->U_Model->countDeletedUsersBySearch($data['search'],$data['delete'],$status);\n \n $PAGE_TOTAL_ROWS = $total;\n $PAGE_URL = $this->config->item('base_url').'admin/adminusers/fn/'.$fn.'/orderby/'.$orderb.'/search/'.$data['search'].'/delete/'.$data['delete'].'/status/'.$status;\n $data['PAGING'] = pagination_assoc($PAGE_TOTAL_ROWS,$PAGE_LIMIT,$DISPLAY_PAGES,$PAGE_URL,$page,$pages);\n // Pagination end \n // Get all users\n $data['users'] = $this->U_Model->deletedusers($PAGE_LIMIT_VALUE,$PAGE_LIMIT,$data['search'],$orderby,$data['delete'],$status); \n // set variable to show active menu \n $data['menutab'] = 'network';\n $data['menuitem'] = 'deletedusers'; \n $this->load->view($this->config->item('base_template_dir').'/admin/users_del', $data);\n \n }", "public static function email_password_renew() {\n if ($u = static::check_record_existence()) {\n\n $m = auth_model();\n $u = $m::first(array('where' => 'id = \\'' . $u->id . '\\''));\n\n if ($u->emailPasswordRenew())\n flash('Email com as instruções para Renovação de senha enviado para ' . $u->email . '.');\n else\n flash('Algo ocorreu errado. Tente novamente mais tarde.', 'error');\n }\n\n go_paginate();\n }", "public function inviteAction()\n\t{\n\t\t$user = new Default_Model_User();\n\t\t$resultRow = $user->getUserByEmail($this->loggedEmail);\n\t\t\n\t\t$loggedHandle = $resultRow->handle;\n\t\t$loggedId = $resultRow->id;\n\t\t\n\t\t$handle = $this->_request->getParam('handle');\n\t\t$resultRow = $user->getUserByHandle($handle);\n\t\t$handleId = $resultRow->id;\n\n\t\t$invite = new Default_Model_Invitation();\n\t\tif($invite->createInvitation($loggedId, $handleId)){\n\t\t\t$this->view->success = 1;\n\t\t} else{\n\t\t\t$this->view->success = 0;\n\t\t}\n\t}", "public function resetWhoisEditing() {\n\n\t\t$channel_name = $this->input->post('channel_name');\n\n\t\t$message = $this->session->userdata('pusher_member_id');\n\n\t\t$this->pusher->trigger($channel_name, 'reset_whos_editing', array('message' => $message));\n\n\t}", "public function invitations() {\n\n return DB::table('invitation')\n ->where('recepteur_id', Auth::User()->id)\n ->where('status', 0)\n ->get();\n }", "public function forget() {\n\n\t\t$user = new \\M5\\Models\\Users_Model('',true,__METHOD__);\n\n\t\t$forget_aproach = $user->getPref(\"forget_aproach\");\n\t\t$this->request->forget_form = $forget_aproach;\n\n\t\t/*forget by email */\n\t\tif($_SERVER['HTTP_X_REQUESTED_WITH'] == 'XMLHttpRequest' && $forget_aproach != \"question\")\n\t\t{\n\t\t\textract($_POST);\n\n\t\t\t/* Check captcha*/\n\t\t\tcaptcha_ck(\"captcha\", \" رمز التحقق البشري غير صحيح! \" );\n\n\t\t\t/* Check email syntax*/\n\t\t\tif(!filter_var($email, FILTER_SANITIZE_EMAIL) ){\n\t\t\t\t$msg = pen::msg(\"صيغة الايميل غير صحيحة\");\n\t\t\t\techo $msg;\n\t\t\t\tdie();\n\t\t\t}\n\t\t\t// $user->set(\"printQuery\");\n\n\t\t\t/* mysql: Fetch data by email*/\n\t\t\t$cond = \" && email = '$email'\";\n\t\t\t$r = $user->_one('',$cond);\n\n\t\t\t/* Check email */\n\t\t\tif(!$r['email']){\n\t\t\t\techo $msg = pen::msg(string('forget_msg_fail'),'alert alert-danger _caps');\n\t\t\t\tdie();\n\t\t\t}\n\n\t\t\t/* prepare forget item*/\n\t\t\t$rand = substr( md5(rand(100,99999999)),\"0\",\"10\" );\n\n\t\t\t$temp_forget_args =\n\t\t\t[\n\t\t\t\"name\" => $email,\n\t\t\t\"type\" => \"resetAdmin\",\n\t\t\t\"ava\" => $rand,\n\t\t\t\"st\" => 0\n\t\t\t];\n\t\t\tif( $user->insert($temp_forget_args,\"types\",0))\n\t\t\t{\n\n\t\t\t\t/*Send activation link*/\n\t\t\t\t$subj = site_name.\" - \".string(\"reasign_admin_ttl\");\n\t\t\t\t$reciver = $email;\n\t\t\t\t$sender = mail_from;\n\t\t\t\t$link = url().\"admin/index/do/reset/$rand\";\n\t\t\t\t$msg = $logo.'<div>مرحباً </div><br />';\n\t\t\t\t$msg .= '<div>اسم الدخول: '.$r['user'].'</div>';\n\t\t\t\t$msg .= '<div>'.string(\"reasign_admin_ttl\").': </div>'.$link;\n\t\t\t\t$msg .= '<div><br /><hr>'.site_name.'</div>';\n\t\t\t\t$msg .= '<div>'.url().'</div>';\n\n\t\t\t\tif(Email::smtp($subj, $reciver, $sender, $msg) ){\n\t\t\t\t\t// echo $msg;\n\t\t\t\t\techo $msg = pen::msg(string('forget_msg_success / '.$email),'_caps alert alert-info');\n\t\t\t\t\tSession::set(\"captcha\",123);\n\t\t\t\t}\n\n\n\t\t\t}\n\n\t\t}else{\n\t\t\t/*forget by answer security question */\n\n\t\t}\n\n\t}", "public function rejectInvitation()\n\t{\n\t\t$id = $this->request->data['id'];\n\t\t$invite['MeetingUser']['id'] = $id;\n\t\t//set status 1 as accepted\n\t\t$invite['MeetingUser']['is_accept'] = 2;\n\t\t$invite['MeetingUser']['is_read'] = 1;\n\t\t$invite['MeetingUser']['is_attend'] = 0;\n\t\t//set notification\n\t\t$oldCount1 = $this->Session->read('oldMeetingCount');\n\t\tif ($oldCount1>0) {\n\t\t\t$newCount1 = $oldCount1-1;\n\t\t\t$this->Session->write('oldMeetingCount',$newCount1);\n\t\t}\n\t\tif($this->MeetingUser->save($invite))\n\t\t\techo \"1\";\n\t\telse\n\t\t\techo \"0\";\n\t\texit;\n\t}", "function invite_post(&$a) {\n\n\tif(! local_channel()) {\n\t\tnotice( t('Permission denied.') . EOL);\n\t\treturn;\n\t}\n\n\tcheck_form_security_token_redirectOnErr('/', 'send_invite');\n\n\t$max_invites = intval(get_config('system','max_invites'));\n\tif(! $max_invites)\n\t\t$max_invites = 50;\n\n\t$current_invites = intval(get_pconfig(local_channel(),'system','sent_invites'));\n\tif($current_invites > $max_invites) {\n\t\tnotice( t('Total invitation limit exceeded.') . EOL);\n\t\treturn;\n\t};\n\n\n\t$recips = ((x($_POST,'recipients')) ? explode(\"\\n\",$_POST['recipients']) : array());\n\t$message = ((x($_POST,'message')) ? notags(trim($_POST['message'])) : '');\n\n\t$total = 0;\n\n\tif(get_config('system','invitation_only')) {\n\t\t$invonly = true;\n\t\t$x = get_pconfig(local_channel(),'system','invites_remaining');\n\t\tif((! $x) && (! is_site_admin()))\n\t\t\treturn;\n\t}\n\n\tforeach($recips as $recip) {\n\n\t\t$recip = trim($recip);\n\t\tif(! $recip)\n\t\t\tcontinue;\n\n\t\tif(! valid_email($recip)) {\n\t\t\tnotice( sprintf( t('%s : Not a valid email address.'), $recip) . EOL);\n\t\t\tcontinue;\n\t\t}\n\t\t\n\t\tif($invonly && ($x || is_site_admin())) {\n\t\t\t$code = autoname(8) . srand(1000,9999);\n\t\t\t$nmessage = str_replace('$invite_code',$code,$message);\n\n\t\t\t$r = q(\"INSERT INTO `register` (`hash`,`created`) VALUES ('%s', '%s') \",\n\t\t\t\tdbesc($code),\n\t\t\t\tdbesc(datetime_convert())\n\t\t\t);\n\n\t\t\tif(! is_site_admin()) {\n\t\t\t\t$x --;\n\t\t\t\tif($x >= 0)\n\t\t\t\t\tset_pconfig(local_channel(),'system','invites_remaining',$x);\n\t\t\t\telse\n\t\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t\t$nmessage = $message;\n\n\t\t$account = $a->get_account();\n\n\n\t\t$res = mail($recip, sprintf( t('Please join us on Red'), $a->config['sitename']), \n\t\t\t$nmessage, \n\t\t\t\"From: \" . $account['account_email'] . \"\\n\"\n\t\t\t. 'Content-type: text/plain; charset=UTF-8' . \"\\n\"\n\t\t\t. 'Content-transfer-encoding: 8bit' );\n\n\t\tif($res) {\n\t\t\t$total ++;\n\t\t\t$current_invites ++;\n\t\t\tset_pconfig(local_channel(),'system','sent_invites',$current_invites);\n\t\t\tif($current_invites > $max_invites) {\n\t\t\t\tnotice( t('Invitation limit exceeded. Please contact your site administrator.') . EOL);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tnotice( sprintf( t('%s : Message delivery failed.'), $recip) . EOL);\n\t\t}\n\n\t}\n\tnotice( sprintf( tt(\"%d message sent.\", \"%d messages sent.\", $total) , $total) . EOL);\n\treturn;\n}", "function update_activity_send_sms_email_to_visitors($activity_id) {\n // , auto-generate meeting_ID\n $date = date('Ymd');\n\n $visitors = $this->Activity_model->get_activity_visitors_by_activity_id($activity_id);\n $activity_details = $this->Activity_model->get_daily_activity_by_activity_id($activity_id);\n\n $host_info = $this->Activity_Model->get_emp_info_by_empcode($activity_details->HOST_EMP);\n $host_name = $host_info->EMP_FNAME .' '. $host_info->EMP_LNAME;\n\n if($visitors) {\n foreach ($visitors as $visitor) {\n $meeting_ID = $date . str_pad($visitor->VISITOR_ID, 4, '0', STR_PAD_LEFT);\n $this->Activity_Model->update_visit_log_meeting_id($meeting_ID, $visitor->VISITOR_ID);\n\n $visitors_name = $visitor->VISIT_FNAME .' '. $visitor->VISIT_LNAME;\n $sms_message = \"Good day, \".$visitors_name.\"! Please be advised that your meeting with \".$host_name.\" on \".$activity_details->ACTIVITY_DATE.\" from \".$activity_details->TIME_FROM.\" to \".$activity_details->TIME_TO.\" at \".$activity_details->LOCATION.\" has already been confirmed. Your meeting ID is \".$meeting_ID.\". Please check your e-mail for further details. Thank you!\";\n\n $email_message = \"Dear \".$visitors_name.\": <br><br> Good Day! <br><br>\n Please be advised that your meeting with \".$host_name.\" on \".$activity_details->ACTIVITY_DATE.\" from \".$activity_details->TIME_FROM.\" to \".$activity_details->TIME_TO.\" at \".$activity_details->LOCATION.\" has already been confirmed. <br><br>\n Your meeting ID is \".$meeting_ID.\". <br><br>\n If you encountered any technical problems, please contact \".$host_name.\" at \".$host_info->EMAIL_ADDRESS.\" or \".$host_info->MOBILE_NO.\".\n\n <br><br><br>\n Thank you.<br><br>\n <b>Human Resources </b>\";\n $this->sms->send( array('mobile' => $visitor->MOBILE_NO, 'message' => $sms_message) );\n $this->send_email($visitor->EMAIL_ADDRESS, 'ETS – '.$visitor->MEETING_ID.' - MEETING UPDATE', $email_message);\n\n // SMS EMAIL TO HOST_EMPLOYEE FOR MEETING ID\n $sms_message = \"Good day, \".$host_name.\"! Please be informed that you have a meeting with \".$visitors_name.\" on \".$activity_details->ACTIVITY_DATE.\" from \".$activity_details->TIME_FROM.\" to \".$activity_details->TIME_TO.\" at \".$activity_details->LOCATION.\". Please check your e-mail for the meeting confirmation. Please disregard this message if you already complied. Thank you!\";\n\n $email_message = \"Dear \".$host_name.\": <br><br> Good Day! <br><br>\n Please be informed that you have a meeting with \".$visitors_name.\" on \".$activity_details->ACTIVITY_DATE.\" from \".$activity_details->TIME_FROM.\" to \".$activity_details->TIME_TO.\" at \".$activity_details->LOCATION.\". <br><br>\n To confirm the meeting, please copy the link below and paste it into your browser’s address bar. <br><br>\".base_url('login').\" <br><br>Please disregard this message if you already complied.\n\n <br><br><br>\n Thank you.<br><br>\n <b>Human Resources </b>\";\n if($host_info->MOBILE_NO <> 0) {\n $this->sms->send( array('mobile' => $host_info->MOBILE_NO, 'message' => $sms_message) );\n }\n\n if($host_info->EMAIL_ADDRESS) {\n $this->send_email($host_info->EMAIL_ADDRESS, 'ETS – VISITOR’S MEETING CONFIRMATION', $email_message);\n }\n\n }\n }\n\n\n\n \n }", "public function getEmailReferrers();", "public function disinvite($user) {\n\t\t$invitation = $this->event->getInvitation($user);\n\t\t$this->event->removeInvitation($invitation); // this should also automatically remove the invitation from the database\t\t\n\t\t$this->event->save();\n\t}", "public function actionNotifyUnExeptedProfiles(){\n $message = new YiiMailMessage;\n $message->view = 'system';\n $message->from = Yii::app()->params['noreplyEmail'];\n \n // send newsletter to all in waiting list\n $hidden = UserStat::model()->findAll(\"completeness < :comp\",array(\":comp\"=>PROFILE_COMPLETENESS_MIN));\n\n $c = 0;\n foreach ($hidden as $stat){\n //set mail tracking\n if ($stat->user->status != 0) continue; // skip active users\n if ($stat->user->newsletter == 0) continue; // skip those who unsubscribed\n if ($stat->user->lastvisit_at != '0000-00-00 00:00:00') continue; // skip users who have already canceled their account\n \n //echo $stat->user->name.\" - \".$stat->user->email.\": \".$stat->user->create_at.\" (\".date('c',strtotime('-4 week')).\" \".date('c',strtotime('-3 week')).\")<br />\\n\";\n $create_at = date(\"Y-m-d H\",strtotime($stat->user->create_at));\n //$create_at_hour = date(\"Y-m-d H\",strtotime($stat->user->create_at));\n /*if ($create_at < strtotime('-8 week') || $create_at >= strtotime('-1 day')) continue; \n if (!\n (($create_at >= strtotime('-1 week')) || \n (($create_at >= strtotime('-4 week')) && ($create_at < strtotime('-3 week'))) || \n (($create_at >= strtotime('-8 week')) && ($create_at < strtotime('-7 week'))) )\n ) continue;*/\n if ( !($create_at == date(\"Y-m-d H\",strtotime('-2 hour')) || $create_at == date(\"Y-m-d H\",strtotime('-1 day')) || \n $create_at == date(\"Y-m-d H\",strtotime('-3 days')) || $create_at == date(\"Y-m-d H\",strtotime('-8 days')) || \n $create_at == date(\"Y-m-d H\",strtotime('-14 day')) || $create_at == date(\"Y-m-d H\",strtotime('-21 day')) || \n $create_at == date(\"Y-m-d H\",strtotime('-28 day'))) ) continue;\n //echo $stat->user->email.\" - \".$stat->user->name.\" your Cofinder profile is moments away from approval!\";\n\n //echo \"SEND: \".$stat->user->name.\" - \".$stat->user->email.\": \".$stat->user->create_at.\" (\".$stat->completeness.\")<br />\\n\";\n //echo 'http://www.cofinder.eu/profile/registrationFlow?key='.substr($stat->user->activkey,0, 10).'&email='.$stat->user->email;\n\n //continue;\n //set mail tracking\n $mailTracking = mailTrackingCode($stat->user->id);\n $ml = new MailLog();\n $ml->tracking_code = mailTrackingCodeDecode($mailTracking);\n $ml->type = 'registration-flow-reminder';\n $ml->user_to_id = $stat->user->id;\n $ml->save();\n\n $email = $stat->user->email;\n $message->subject = $stat->user->name.\" your Cofinder account is almost approved\"; // 11.6. title change\n\n $content = \"We couldn't approve your profile just yet since you haven't provided enough information.\"\n . \"Please fill your profile and we will revisit your application.\".\n mailButton(\"Do it now\", absoluteURL().'/profile/registrationFlow?key='.substr($stat->user->activkey,0, 10).'&email='.$stat->user->email,'success',$mailTracking,'fill-up-button');\n\n $message->setBody(array(\"content\"=>$content,\"email\"=>$email,\"tc\"=>$mailTracking), 'text/html');\n $message->setTo($email);\n Yii::app()->mail->send($message);\n\n Notifications::setNotification($stat->user_id,Notifications::NOTIFY_INVISIBLE);\n $c++;\n }\n if ($c > 0) Slack::message(\"CRON >> UnExcepted profiles: \".$c);\n return 0;\n }", "function sendUpdateEmail($email, $registrant)\n{\n $name = $_SESSION['ctst_name'];\n $subject = $name . \" registration information updated.\";\n $mailContent = $registrant['givenName'] . ' ' . $registrant['familyName'];\n $mailContent .= \":\\n\\n\";\n $mailContent .= \"Your information for the \" . $name . \" has been updated.\\n\";\n $mailContent .= \"\\nIf you did not edit your registration information, \" .\n \"please write to the administrator:\\n\";\n $mailContent .= \"mailto:\" . ADMIN_EMAIL . \"?subject=account%20compromised\\n\";\n $mailContent .= \"\\nright away, or simply reply to this note.\\n\";\n $mailContent .= automatedMessage($name);\n $headers = \"From: \" . ADMIN_EMAIL . \"\\r\\n\";\n do_email($email, $subject, $mailContent, $headers);\n}" ]
[ "0.663524", "0.6576301", "0.6575173", "0.64940906", "0.6465172", "0.64550817", "0.6433844", "0.61871636", "0.6137348", "0.60382515", "0.6014247", "0.59998655", "0.59975594", "0.5991292", "0.5938109", "0.59254724", "0.59186965", "0.59120363", "0.5889213", "0.58774793", "0.586262", "0.58344287", "0.5806429", "0.58041257", "0.57939076", "0.5774124", "0.5733182", "0.570698", "0.56976163", "0.56968737", "0.566663", "0.56652594", "0.56618035", "0.5627371", "0.5606878", "0.56002045", "0.55946237", "0.55906886", "0.5555353", "0.55545", "0.55446017", "0.5539316", "0.5536524", "0.5528244", "0.5521385", "0.5514432", "0.5513835", "0.5490031", "0.54799247", "0.5477273", "0.54521316", "0.5451443", "0.5447677", "0.5445679", "0.5439435", "0.54373705", "0.5436696", "0.5429785", "0.54224336", "0.54201436", "0.5417848", "0.54106677", "0.5408101", "0.5398409", "0.53927064", "0.5371096", "0.53665847", "0.53606486", "0.5358511", "0.53482854", "0.533773", "0.5336831", "0.53357726", "0.5335438", "0.5334674", "0.53287786", "0.53209776", "0.5318323", "0.53164506", "0.5315388", "0.53123087", "0.53095394", "0.5305377", "0.52978873", "0.52859503", "0.5285939", "0.5284011", "0.52840054", "0.5282232", "0.527634", "0.5272983", "0.5268896", "0.526842", "0.5267882", "0.52542776", "0.5251185", "0.5250533", "0.52482754", "0.5248129", "0.52449626" ]
0.6727499
0
InviteHistoryHandler::isMemberJoined() To check whether the user joined or not
public function isMemberJoined($email='') { $sql = 'SELECT user_name, first_name, last_name, user_id'. ' FROM '.$this->CFG['db']['tbl']['users']. ' WHERE email='.$this->dbObj->Param($email). ' AND usr_status=\'Ok\' LIMIT 1'; $stmt = $this->dbObj->Prepare($sql); $rs = $this->dbObj->Execute($stmt, array($email)); if (!$rs) trigger_db_error($this->dbObj); $user_details = array(); if ($rs->PO_RecordCount()) { $user_details = $rs->FetchRow(); } return $user_details; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isMember(): bool\n {\n return !is_null($this->group_id);\n }", "public function testIsMember()\n {\n $this->assertFalse($this->user->isMember());\n\n $subscribed = $this->subscribedUser();\n\n // our subscribed user is a member\n $this->assertTrue($subscribed->isMember());\n }", "public function isMember()\n {\n if ($this->hasRole('ROLE_ADMIN')) {\n return true;\n }\n\n return $this->getEndDate() > new \\DateTime();\n }", "public function canBeJoined(): bool\n {\n return $this->_canBeJoined;\n }", "public function isMember()\n {\n return $this->role == 3;\n }", "function is_member_logged_in()\n\t{\n\t\tif(isset($_SESSION['member']['au_id']))\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "public function isMember()\n {\n return $this->affiliation != self::AFFILIATION_OUTCAST;\n }", "function cs_is_member($users_id)\r\n{\r\n\tsettype($users_id, 'integer');\r\n\t\r\n\tif ($users_id <= 0)\r\n\t\treturn false;\r\n\t\r\n\t$where = 'm.users_id = '.$users_id.' AND us.users_delete = 0 AND us.users_active = 1 AND sq.clans_id = 1';\r\n\t$count = cs_sql_count(__FILE__, 'members m LEFT JOIN {pre}_users us ON m.users_id = us.users_id LEFT JOIN {pre}_squads sq ON m.squads_id = sq.squads_id', $where);\r\n\t\r\n\tif ($count > 0)\r\n\t\treturn true;\r\n\t\r\n\treturn false;\r\n}", "function is_member_login() {\n\t\t$cm_account = $this->get_account_cookie(\"member\");\n\t\tif ( !isset($cm_account['id']) || !isset($cm_account['username']) || !isset($cm_account['password']) || !isset($cm_account['onlinecode']) ) {\n\t\t\treturn false;\n\t\t}\n\t\t// check again in database\n\t\treturn $this->check_account();\n\t}", "function _s_is_member() {\n\treturn current_user_can( 'read' ) ? true : false;\n}", "public function isUserMember($group, $user_id)\n\t{\n\t\t$isJoined = DB::select(\"select user_id from group_user where user_id = $user_id and group_id = $group->id\");\n\n\t\tif (!empty($isJoined)) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "public function isHasInvited()\n {\n return $this->hasInvited;\n }", "public function list_members() {\n\n\t\t//ignored users\n\t\t$stm = $this->db()->prepare('select \"to_big\" from \"member_settings\" where \"from_big\" = :current_member_big and \"chat_ignore\" = 1');\n\t\t$stm->execute(array(\n\t\t\t':current_member_big'\t=> $this->member_big,\n\t\t));\n\t\t$ignored_members_raw = $stm->fetchAll(PDO::FETCH_ASSOC);\n\t\t$ignored_members = array(0);\n\t\tforeach($ignored_members_raw as $member) {\n\t\t\t$ignored_members[] = $member['to_big'];\n\t\t}\n\t\t$ignored_members = implode(',', $ignored_members);\n\n\t\t//joined users\n\t\t$stm = $this->db()->prepare(\n\t\t\t'select distinct on (m.big) \"m\".\"big\", \"m\".\"name\"||\\' \\'||substring(\"m\".\"surname\" from 1 for 1)||\\'.\\' as \"name\", (case when \"c\".\"physical\"=1 then \\'onsite\\' else \\'online\\' end) as \"status\"\n\t\t\tfrom \"checkins\" \"c\"\n\t\t\t\tleft join \"members\" \"m\" on (\"c\".\"member_big\" = \"m\".\"big\")\n\t\t\twhere (\"c\".\"checkout\" is null or \"c\".\"checkout\" > now())\n\t\t\t\tand \"c\".\"event_big\" = (select \"event_big\" from \"checkins\" where \"member_big\" = :member_big and (\"checkout\" is null or \"checkout\" > now()) order by \"created\" desc limit 1)\n\t\t\t\tand (\"m\".\"last_web_activity\" > :online_timeout or \"m\".\"last_mobile_activity\" > :online_timeout)\n\t\t\t\tand \"m\".\"big\" != :member_big\n\t\t\t\tand \"m\".\"big\" not in ('.$ignored_members.')\n\t\t\torder by m.big, \"c\".\"created\" asc'\n\t\t);\n\t\t$stm->execute(array(\n\t\t\t':member_big'\t\t=> $this->member_big,\n\t\t\t':online_timeout'\t=> date('c', strtotime(ONLINE_TIMEOUT)),\n\t\t));\n\t\t$joined_members = $stm->fetchAll(PDO::FETCH_ASSOC);\n\n\t\t$joined_member_bigs = array(0);\n\t\tforeach($joined_members as $member) {\n\t\t\t$joined_member_bigs[] = $member['big'];\n\t\t}\n\t\t$joined_member_bigs = implode(',', $joined_member_bigs);\n\n\t\t//users we already had conversation with\n\t\t$stm = $this->db()->prepare(\n\t\t\t'select distinct on (m.big) \"m\".\"big\", \"m\".\"name\"||\\' \\'||substring(\"m\".\"surname\" from 1 for 1)||\\'.\\' as \"name\",\n\t\t\t\t(case when (\"m\".\"last_web_activity\" > :online_timeout or \"m\".\"last_mobile_activity\" > :online_timeout) then \\'online\\' else \\'offline\\' end) as \"status\"\n\t\t\tfrom \"member_rels\" \"r\"\n\t\t\t\tleft join \"members\" \"m\" on (\"m\".\"big\" = (case when \"r\".\"member1_big\"=:member_big then \"r\".\"member2_big\" else \"r\".\"member1_big\" end))\n\t\t\t\tleft join \"chat_messages\" as \"cm\" on (\"cm\".\"rel_id\" = \"r\".\"id\" and (case when \"cm\".\"from_big\"=:member_big then \"cm\".\"from_status\" else \"cm\".\"to_status\" end) = 1)\n\t\t\twhere \"m\".\"big\" != :member_big\n\t\t\t\tand (r.member1_big = :member_big OR r.member2_big = :member_big)\n\t\t\t\tand \"m\".\"big\" not in ('.$ignored_members.','.$joined_member_bigs.')\n\t\t\t\tand \"cm\".\"id\" > 0\n\t\t\torder by m.big'\n\t\t);\n\t\t$stm->execute(array(\n\t\t\t':member_big'\t\t=> $this->member_big,\n\t\t\t':online_timeout'\t=> date('c', strtotime(ONLINE_TIMEOUT)),\n\t\t));\n\t\t$history_members = $stm->fetchAll(PDO::FETCH_ASSOC);\n\n\t\tforeach($joined_members as $key=>$val) {\n\t\t\t$joined_members[$key]['img'] = ProfilePicture::get_resized($val['big'], 28, 28);\n\t\t}\n\n\t\tforeach($history_members as $key=>$val) {\n\t\t\t$history_members[$key]['img'] = ProfilePicture::get_resized($val['big'], 28, 28);\n\t\t}\n\n\n\t\treturn $this->reply(array(\n\t\t\t'joined' => $joined_members,\n\t\t\t'history' => $history_members,\n\t\t));\n\n\t}", "function is_user_member_of($db, $group_id)\n{\n global $current_user;\n if ($current_user === NULL) {\n return False;\n }\n\n $records = exec_sql_query(\n $db,\n \"SELECT id FROM memberships WHERE (group_id = :group_id) AND (user_id = :user_id);\",\n array(\n ':group_id' => $group_id,\n ':user_id' => $current_user['id']\n )\n )->fetchAll();\n if ($records) {\n return True;\n } else {\n return False;\n }\n}", "function isLeagueMember(\n $user_id,\n $change_to_league, \n &$ref_status_text = ''\n){\n $mysql = \"\n select 88 as ismember\n from users\n where id = ?\n and league_id like concat('%-',?,'-%')\";\n \n $junk = 0;\n $is_member = false;\n $ref_status_text = '';\n while (1) {\n if (!$ans = runSql($mysql, array(\"ii\",$user_id, $change_to_league), 0, $ref_status_text)) {\n if ($ans === false) {\n break;\n }\n if ($ans === null) {\n $is_member = null;\n break;\n }\n }\n\n if (sizeof($ans) == 1) {\n $junk = $ans[0]['ismember'];\n $is_member = ($junk == 88) ? true : false;\n }\n \n $status = 1;\n break;\n }\n return $is_member;\n}", "public function canJoin($user_guid = 0){\n\n\t\t$result = false;\n\n\t\tif(empty($user_guid)){\n\t\t\t$user_guid = elgg_get_logged_in_user_guid();\n\t\t}\n\n\t\tif($user = get_user($user_guid)){\n\t\t\tif(!$this->isUser($user_guid)){\n\t\t\t\t// can join only returns true if you are not yet a member\n\t\t\t\tif($user->isAdmin() && empty($this->limit_admins)){\n\t\t\t\t\t// admin can join if not a private site\n\t\t\t\t\t$result = true;\n\t\t\t\t} else {\n\t\t\t\t\t// current membership\n\t\t\t\t\t$membership = $this->getMembership();\n\n\t\t\t\t\tswitch($membership){\n\t\t\t\t\t\tcase self::MEMBERSHIP_OPEN:\n\t\t\t\t\t\t\t// everyone can join\n\t\t\t\t\t\t\t$result = true;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase self::MEMBERSHIP_APPROVAL:\n\t\t\t\t\t\t\t// only after approval\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase self::MEMBERSHIP_DOMAIN:\n\t\t\t\t\t\tcase self::MEMBERSHIP_DOMAIN_APPROVAL:\n\t\t\t\t\t\t\t// based on email domain\n\t\t\t\t\t\t\tif($this->validateEmailDomain($user_guid)){\n\t\t\t\t\t\t\t\t$result = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase self::MEMBERSHIP_INVITATION:\n\t\t\t\t\t\t\t// if an outstanding invitation is available you can also join\n\t\t\t\t\t\t\t// this is NOT related to a membership type\n\t\t\t\t\t\t\tif($this->hasInvitation($user_guid, $user->email)){\n\t\t\t\t\t\t\t\t$result = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\tif(!$result && $this->hasInvitation($user_guid, $user->email)){\n\t\t\t\t\t\t// if user has been invited he can always join\n\t\t\t\t\t\t$result = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $result;\n\t}", "public function isUttMember()\n\t{\n\t\treturn $this->isUser() && ! $this->user->getIsStudent() && ! $this->user->getKeepActive();\n\t}", "public function isMember(): bool\n {\n return $this->getType() === static::TYPE_MEMBER;\n }", "public function isActiveMember(Users $user)\n {\n }", "public function isJoin();", "public function memberJoin(Group $group, Member $member, $status = 'In')\n {\n if (!is_object($group) || !is_object($member) || !($member_id = $member->getPKValue()) || !($group_id = $group->getPKValue()))\n {\n return false;\n }\n\n // only bother if member is not already ... a member \n if (!$this->isMember($group, $member, false))\n {\n $this->Status = $this->dao->escape($status);\n $this->IdGroup = $group_id;\n $this->IdMember = $member_id;\n $this->created = date('Y-m-d H:i:s');\n\n return $this->insert();\n }\n else\n {\n return false;\n }\n }", "function IsLoggedIn() {\t\tif( Member::currentUserID() ) {\r\n\t\t return true;\r\n\t\t}\r\n }", "public function isAlive($member)\n {\n return in_array($member, $this->population);\n }", "public function getVisitorIsLeaderAttribute()\n\t{\n\t\treturn in_array($this -> visitor -> id,$this -> members()->where('leader', true)->lists('gamer_id'));\n\t}", "private static function existingUser($invite, $auth) {\n // double check not already a member\n $existing = data_entry_helper::get_population_data(array(\n 'table' => 'groups_user',\n 'extraParams' => $auth['read'] + array(\n 'user_id' => hostsite_get_user_field('indicia_user_id'),\n 'group_id' => $invite['group_id']\n ),\n 'nocache'=>true\n ));\n return count($existing) > 0;\n }", "function isMember($user_id)\n\t{\n\t\t//get admin id\n\t\t$this->db->where('role', 1);\t\t\t\t\t\n\t\t$query = $this->db->get('users');\n\t\t$admin=$query->row();\n\t\tif($user_id == $admin->id)\n\t\t\treturn true;\n\t\t\t\n\t\t// get user that purchased membership\n\t\t$this->db->where('user_id', $user_id);\t\t\t\t\t\n\t\t$query = $this->db->get($this->table);\n\n\t\tif($query->num_rows())\n\t\t\treturn true;\n\t\telse\n\t\t\treturn false;\n\t}", "function is_joinable($group, $uid = NULL, $gen_err = FALSE) {\n if (!$uid)\n $uid = userid();\n\n $group_id = $group['group_id'];\n if ($this->is_member($uid, $group['group_id'])) {\n if ($gen_err)\n e(lang('grp_join_error'));\n return false;\n }elseif ($group['group_privacy'] != 2 || $this->is_invited($uid, $group_id, $group['userid'], $gen_err))\n return true;\n else\n return false;\n }", "function db_user_is_member_of_group($username, $groupname, $snuuid)\n{\n\t$sql = \"SELECT creation FROM group_members\n\t\tWHERE username=$1\n\t\tAND groupname=$2\n\t\tAND snuuid=$3\";\n\t$res = pg_query_params($sql, array($username, $groupname, $snuuid));\n\treturn pg_num_rows($res) != 0;\n}", "public function memberIsLoggedIn()\n {\n return $_SESSION['__COMMENTIA__']['member_is_logged_in'];\n }", "function isMemberOfThisGroup($groupId)\n{\n\t$_c_user_id = (isset($_COOKIE[$GLOBALS['c_id']]) ? $_COOKIE[$GLOBALS['c_id']] : 0);\n\n\tif ($_c_user_id != 0 && isUserLoggedIn()) {\n \n\t\t$db = new db_util();\n\n\t $sql = \"SELECT * \n\t FROM vm_member_list \n\t WHERE vm_member_id='$_c_user_id' \n\t AND vm_group_id = '$groupId'\";\n\n\t $result = $db->query($sql);\n\n\t if ($result !== false) {\n\t // if there any error in sql then it will false\n\t if ($result->num_rows > 0) {\n\t // if the sql execute successful then it give \n\t \n\t return true;\n\t }\n\t }\n }\n \n return false;\n}", "public function memberIdCheck ()\r\n {\r\n $member_id = $this->getMember_id(true);\r\n return $this->getMapper()->memberIdCheck($member_id);\r\n }", "function checkMemberLogin() {\n if (!isset($_SESSION['mid'])) {\n return false;\n }\n return true;\n}", "function _s_members_login_message() {\n if( ! is_user_logged_in() ) {\n return _s_members_only_message(); \n } \n}", "public function isUserMemberAllowedAccess()\n\t{\n\t\t$BlockedEmployeeStatuses \t=\tarray\n\t\t\t\t\t\t\t\t\t(\n\t\t\t\t\t\t\t\t\t\t'Locked:Excessive-Login-Attempts',\n\t\t\t\t\t\t\t\t\t);\n\n\t\treturn (\t$this->getSiteUser()->getUserMemberID()*1 > 0\n\t\t\t\t&& \t!in_array\n\t\t\t\t\t(\n\t\t\t\t\t\t$this->getEmployeeStatusByMemberID($this->getSiteUser()->getUserMemberID()),\n\t\t\t\t\t\t$BlockedEmployeeStatuses\n\t\t\t\t\t)\n\t\t\t\t\t? \tTRUE\n\t\t\t\t\t: \tFALSE);\n\t}", "public function hasUser();", "public function member( $user, $list )\n\t{\n\t\t$user = $this->sanitize_user( $user );\n\t\tif ( empty( $user->user_email ) || empty( $list ) )\n\t\t{\n\t\t\tdo_action( 'go_slog', 'go-mailchimp', __FUNCTION__ . ': Empty email or list id passed.' );\n\t\t\treturn FALSE;\n\t\t}\n\n\t\ttry\n\t\t{\n\t\t\t$email_struct = array( array( 'email' => $user->user_email ) );\n\t\t\t$member = $this->mc->lists->memberInfo( $list, $email_struct );\n\t\t}//END try\n\t\tcatch ( Exception $e )\n\t\t{\n\t\t\tdo_action( 'go_slog', 'go-mailchimp', __FUNCTION__ . ': An Exception was thrown: ' . $e->getMessage() );\n\t\t\treturn FALSE;\n\t\t}//END catch\n\n\t\tif ( empty( $member ) || empty( $member['data'] ) )\n\t\t{\n\t\t\tdo_action( 'go_slog', 'go-mailchimp', __FUNCTION__ . \": No membership info found for email address '{$user->user_email}' in list: $list\" );\n\t\t\treturn FALSE;\n\t\t}//END if\n\n\t\treturn $member['data'][0];\n\t}", "function mx_is_group_member($group_ids = '', $group_mod_mode = false)\n\t{\n\t\tglobal $user, $db;\n\n\t\tif ($group_ids == '')\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\t$group_ids_array = explode(\",\", $group_ids);\n\n\t\t// Try to reuse usergroups result.\n\t\tif ($group_mod_mode)\n\t\t{\n\t\t\t$userdata_key = 'mx_usergroups_mod' . $user->data['user_id'];\n\n\t\t\tif (empty($user->data[$userdata_key]))\n\t\t\t{\n\t\t\t\t// Check if user is group moderator..\n\t\t\t\t$sql = \"SELECT gr.group_id\n\t\t\t\t\t\tFROM \" . GROUPS_TABLE . \" gr, \" . USER_GROUP_TABLE . \" ugr\n\t\t\t\t\t\tWHERE gr.group_id = ugr.group_id\n\t\t\t\t\t\t\tAND gr.group_moderator = '\" . $user->data['user_id'] . \"'\n\t\t\t\t\t\t\tAND ugr.user_pending = '0' \";\n\t\t\t\t$result = $db->sql_query($sql);\n\t\t\t\t$group_row = $db->sql_fetchrowset($result);\n\t\t\t\t$user->data[$userdata_key_mod] = $group_row;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$userdata_key = 'mx_usergroups' . $user->data['user_id'];\n\n\t\t\tif (empty($user->data[$userdata_key]))\n\t\t\t{\n\t\t\t\t// Check if user is member of the proper group..\n\t\t\t\t$sql = \"SELECT group_id FROM \" . USER_GROUP_TABLE . \" WHERE user_id='\" . $user->data['user_id'] . \"' AND user_pending = 0\";\n\t\t\t\t$result = $db->sql_query($sql);\n\t\t\t\t$group_row = $db->sql_fetchrowset($result);\n\t\t\t\t$user->data[$userdata_key] = $group_row;\n\t\t\t}\n\t\t}\n\n\t\tfor ($i = 0; $i < sizeof($user->data[$userdata_key]); $i++)\n\t\t{\n\t\t\tif (in_array($user->data[$userdata_key][$i]['group_id'], $group_ids_array))\n\t\t\t{\n\t\t\t\t$is_member = true;\n\t\t\t\treturn $is_member;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "public function has_organiser($memberid){\n $sql = \"SELECT * FROM tournamentOrganisers WHERE tournamentID=$this->id AND organiserID=$memberid\";\n $result = self::$database->query($sql);\n if (mysqli_num_rows($result)==1){\n return true;\n }\n return false;\n }", "public function isFriendsWith($user_guid);", "function OnGroupJoin($group, $memberid) {\n\t\tFB::log('OnGroupJoin');\n\t\t$this -> execute($group -> id, $memberid);\n\n\t}", "public function isEuMember() {\n\t\treturn $this->getEuMember();\n\t}", "function isMember(User $user, $use_cache = true) {\n $user_id = $user->getId();\n \n if($use_cache && array_key_exists($user_id, $this->project_members)) {\n return $this->project_members[$user_id];\n } // if\n \n $this->project_members[$user_id] = (boolean) DB::executeFirstCell('SELECT COUNT(*) FROM ' . TABLE_PREFIX . 'project_users WHERE user_id = ? AND project_id = ?', $user_id, $this->object->getId());\n \n return $this->project_members[$user_id];\n }", "public function isMember(UserObject $userObject){\n if(is_callable($this->checkMember)){\n $check = $this->checkMember;\n return $check($userObject);\n }\n CoreLog::debug('No checkMember method defined');\n return false;\n }", "public function isMember($userID = null) {\n\t\tif ($userID === null) {\n\t\t\t$userID = WCF::getSession()->userID; \n\t\t}\n\t\t\n\t\t$sql = \"SELECT COUNT(*) AS members FROM wcf\".WCF_N.\"_user_to_group_premium WHERE premiumGroupID = ? AND userID = ?\"; \n\t\t$statement = WCF::getDB()->prepareStatement($sql);\n\t\t$statement->execute(array($this->premiumGroupID, $userID));\n\t\t$row = $statement->fetchArray();\n\t\t\n return ($row['members'] > 0) ? true : false; \n }", "public static function isJoined (array|string|int $ids , int|null $user_id = null): bool {\n if (!is_array($ids)) {\n $ids = [$ids];\n }\n $user_id = $user_id ?? request::catchFields('user_id');\n\n foreach ($ids as $id) {\n $check = telegram::getChatMember($id,$user_id);\n if (telegram::$status) {\n $check = $check->status;\n if ($check === chatMemberStatus::LEFT || $check === chatMemberStatus::KICKED) {\n return false;\n }\n }\n }\n return true;\n }", "public function ismember($roll=null) {\r\n\t\tif (!is_null($roll)) {\r\n\t\t\tif (!$user_id = $this->getuid()) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\t$rolls_count = $this->db\r\n\t\t\t\t->where('roll', $roll)\r\n\t\t\t\t->where('user_id', $user_id)\r\n\t\t\t\t->get($this->rolls_table)\r\n\t\t\t\t->num_rows();\r\n\t\t\tif ($rolls_count == 0) {\r\n\t\t\t\treturn false;\r\n\t\t\t} else {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function has_competitor($memberid){\n $sql = \"SELECT * FROM tournamentCompetitors WHERE tournamentID=$this->id AND competitorID=$memberid\";\n $result = self::$database->query($sql);\n if (mysqli_num_rows($result)==1){\n return true;\n }\n return false;\n }", "public function sendInvitationEmail(): bool\n {\n $invitedUser = new User(null, null, $this->email);\n $folderOwner = new User($this->folder->ownerId);\n\n if (!$folderOwner) {\n return false;\n }\n\n $renderOptions = [\n 'owner_username' => $folderOwner->name,\n 'folder_title' => $this->folder->title,\n 'join_link' => $this->getJoinLink()\n ];\n\n if ($invitedUser->exists()) {\n $renderOptions['invited_username'] = $invitedUser->name;\n }\n\n $message = Renderer::render('email.php', $renderOptions, null);\n\n $mailer = Mailer::instance();\n\n return $mailer->send(\"[CodeX Notes] Join folder – \" . $this->folder->title, Config::get('TEAM_EMAIL'), $this->email, $message);\n }", "public function canMemberLikes() {\n $viewer = Engine_Api::_()->user()->getViewer();\n if (!$viewer || !$viewer->getIdentity()) {\n return false;\n }\n\t\t$like_profile_show = Engine_Api::_()->getApi( 'settings' , 'core' )->getSetting( 'like.profile.show' ) ;\n\t\tif ( empty( $like_profile_show ) ) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n }", "private function members_can_be_invited( $subscription ){\n return pms_gm_get_used_seats( $subscription->id ) >= pms_gm_get_total_seats( $subscription ) ? false : true;\n }", "private function _invited()\n {\n // Check we're not over-joined\n if (count($this->_currentChannels) < $this->_maxChannels)\n {\n $this->setChannels($this->_data->message);\n $this->_irc->join($this->_data->message);\n }\n else {\n $this->_privmessage(\n 'Sorry, I\\'m already in too many channels.', \n $this->_data->nick\n );\n }\n }", "public function joinBtnPressed(){\n $event_id = $_SESSION['detailEventID'];\n $user_id=$this->input->post('hidden_userid');\n $this->load->model('UpdateEventDetailModel');\n $userEvent = $this->UpdateEventDetailModel->selectEventByID(intval($event_id));\n\n //detect whether the user has joined the event or not\n $isUserJoined=$this->validateForDuplicate(intval($event_id),$user_id);\n if($isUserJoined==true){\n $this->UpdateEventDetailModel->insertIntoJoinStatus(intval($event_id),$user_id);\n $this->UpdateEventDetailModel->updateNumOfParticipantsByID(intval($event_id));\n $this->sendEmail($userEvent);\n echo json_encode(['joinSuccess'=>'You have successfully joined the reading event']);\n }else{\n echo json_encode(['joinError'=>'You have already joined this reading event!']);\n }\n }", "function memberNameTaken($memberName){\r\n if(!get_magic_quotes_gpc()){\r\n $memberName = addslashes($memberName);\r\n }\r\n $q = \"SELECT memberName FROM \".TBL_USERS.\" WHERE memberName = '$memberName'\";\r\n $result = mysql_query($q, $this->connection);\r\n return (mysql_numrows($result) > 0);\r\n }", "private function registeredEvents($event, $household_id, $member_id)\n {\n $timeslot = $event->getTimeslots();\n\n foreach( $timeslot as $t)\n {\n $participants = $t->getParticipants();\n $participants = ControllerHelper::formatMember($participants);\n\n if(!is_null($participants))\n {\n foreach( $participants as $p )\n { \n if( $p[\"household_id\"] == $household_id ) //and $p[\"member-id\"] == $member_id \n return \"Registered\";\n }\n }\n }\n return \"Unregistered\";\n }", "function is_active_member($uid, $gid) {\n global $db;\n $count = $db->count(tbl($this->gp_mem_tbl), \"userid\", \" userid='$uid' AND group_id='$gid' AND active='yes'\");\n if ($count[0] > 0)\n return true;\n else\n return false;\n }", "public function isJoined(): bool\n {\n if (!empty($this->options['using'])) {\n return true;\n }\n\n return in_array($this->getMethod(), [self::INLOAD, self::JOIN, self::LEFT_JOIN], true);\n }", "function test_is_user_member_of_blog() {\n\t\t$old_current = get_current_user_id();\n\n\t\t$user_id = self::factory()->user->create( array( 'role' => 'subscriber' ) );\n\t\twp_set_current_user( $user_id );\n\n\t\t$this->assertTrue( is_user_member_of_blog() );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, 0 ) );\n\t\t$this->assertTrue( is_user_member_of_blog( 0, get_current_blog_id() ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertTrue( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\t// Will only remove the user from the current site in multisite; this is desired\n\t\t// and will achieve the desired effect with is_user_member_of_blog().\n\t\twp_delete_user( $user_id );\n\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id ) );\n\t\t$this->assertFalse( is_user_member_of_blog( $user_id, get_current_blog_id() ) );\n\n\t\twp_set_current_user( $old_current );\n\t}", "protected function MEMBER_getActiveMembers ($es_id)\n\t{\n\t\tif (!$es_id) throw new Exception (self::EXCEPTION_MESSAGE_NO_SESSION);\n\t\t$query = $this->db->select(\n\t\t\t\tself::MEMBER_TABLE,\n\t\t\t\t'*',\n\t\t\t\tarray('collab_es_id' => $es_id, 'collab_is_active' => 1),\n\t\t\t\t__LINE__,\n\t\t\t\t__FILE__,\n\t\t\t\tself::APP_NAME\n\t\t);\n\t\t$members = $query->getRows();\n\t\treturn is_array($members)?self::db2id($members):true;\n\t}", "public function hasAccess()\n\t{\n\t\t/* Check Permissions */\n\t\treturn \\IPS\\Member::loggedIn()->hasAcpRestriction( \"core\",\"members\" );\n\t}", "function memberUserExists($email, $password)\r\n { \r\n $select = 'SELECT member_id, username, firstname, lastname, email, password, image FROM atlas_members WHERE email=:email && password=:password';\r\n \r\n $statement = $this->_pdo->prepare($select);\r\n $statement->bindValue(':email', $email, PDO::PARAM_STR);\r\n $statement->bindValue(':password', $password, PDO::PARAM_STR);\r\n $statement->execute();\r\n \r\n $row = $statement->fetch(PDO::FETCH_ASSOC);\r\n \r\n return !empty($row);\r\n \r\n }", "function admin_member() {\n\n\t\t}", "function isMember ($name) {\n\tglobal $MEMBERS; return in_array (strtolower ($name), array_map ('strtolower', $MEMBERS));\n}", "public function hasUsername(){\n return $this->_has(6);\n }", "public function hasUsername(){\n return $this->_has(6);\n }", "function rets_bsf_ismember_agent ($roles, $agent) {\n $query = new EntityFieldQuery();\n $result = $query->entityCondition('entity_type', 'user')\n ->propertyCondition('status', '1')\n ->fieldCondition('field_agentid', 'value', $agent, '=')\n ->execute();\n if ($result) {\n $napps = user_load_multiple(array_keys($result['user']));\n $keys = array_keys($result['user']);\n $rkey = $keys[0];\n foreach ($napps[$rkey]->roles as $key => $value) {\n if (isset($roles[$key])) {\n return array($roles[$key],$napps[$rkey]->uid);\n } \n }\n }\n return 'No';\n}", "function is_invited($uid, $gid, $owner, $gen_err = FALSE) {\n global $db;\n $count = $db->count(tbl($this->gp_invite_tbl), 'invitation_id', \" invited='$uid' AND group_id='$gid' AND userid='$owner' \");\n if ($count[0] > 0)\n return true;\n else {\n if ($gen_err)\n e(lang('grp_prvt_err1'));\n return false;\n }\n }", "public function logged_in()\n\t{\n\t\treturn $this->_me != NULL;\n\t}", "public function hasParticipant() {\n return $this->_has(1);\n }", "public function isMember($id, $member_id)\n {\n //verifica se membro esta assiciado ao projeto\n if( $this->repository->hasMember($id, $member_id) )\n {\n return [\n 'error' => false,\n 'message' =>'is member.'\n ];\n }\n else\n {\n return [\n 'error' => true,\n 'message' =>'not member.'\n ];\n }\n }", "function is_user_member_of_blog($user_id = 0, $blog_id = 0)\n {\n }", "public function providerHasFriends(): bool;", "public function votingHasMember(User $user) {\n if(! is_array($this->answers) || isset($this->answers[0])) { return false; }\n foreach($this->answers as $a) {\n if($a == $user->getUsername()) {\n return true;\n }\n }\n return false;\n }", "public function isMemberOf($group_name){\n return $this->permission()->isMemberOf($this,$group_name);\n }", "public function canView($member = null)\n {\n return (Security::getCurrentUser() !== null);\n }", "public function canView($member = null)\n {\n return (Security::getCurrentUser() !== null);\n }", "public function invite_members(){\n \tif( !isset( $_REQUEST['pmstkn'] ) || !wp_verify_nonce( $_REQUEST['pmstkn'], 'pms_invite_members_form_nonce' ) )\n \t\treturn;\n\n \tif( empty( $_POST['pms_subscription_id'] ) || empty( $_POST['pms_emails_to_invite'] ) )\n \t\treturn;\n\n if( !pms_get_page( 'register', true ) ){\n pms_errors()->add( 'invite_members', esc_html__( 'Registration page not selected. Contact administrator.', 'paid-member-subscriptions' ) );\n\n return;\n }\n\n \t$subscription = pms_get_member_subscription( sanitize_text_field( $_POST['pms_subscription_id'] ) );\n\n if( !pms_gm_is_group_owner( $subscription->id ) )\n return;\n\n \t//try to split the string by comma\n \t$emails = explode( ',', $_POST['pms_emails_to_invite'] );\n\n \t//check if the first entry contains the end of line character and if so, split by EOL\n \t//having more than 1 entry means that the above split worked\n \tif( isset( $emails[0] ) && count( $emails ) == 1 && strstr( $emails[0], PHP_EOL ) )\n \t\t$emails = explode( PHP_EOL, $_POST['pms_emails_to_invite'] );\n\n $invited_members = 0;\n $invited_emails = pms_get_member_subscription_meta( $subscription->id, 'pms_gm_invited_emails' );\n\n \tforeach( $emails as $email ){\n $email = str_replace( array( \"\\r\", \"\\n\", \"\\t\"), '', $email );\n\n if( !$this->members_can_be_invited( $subscription ) )\n return;\n\n if( in_array( $email, $invited_emails ) )\n continue;\n\n // check if user already invited or registered with subscription\n $email = sanitize_text_field( $email );\n\n if( !filter_var( $email, FILTER_VALIDATE_EMAIL ) )\n continue;\n\n $invited_emails[] = $email;\n\n // If a user with this email is already registered, add him to the subscription\n $user = get_user_by( 'email', $email );\n\n if( !empty( $user ) ) {\n\n $existing_subscription = pms_get_member_subscriptions( array( 'user_id' => $user->ID, 'subscription_plan_id' => $subscription->subscription_plan_id ) );\n\n if( !empty( $existing_subscription ) )\n continue;\n\n $subscription_data = array(\n 'user_id' => $user->ID,\n 'subscription_plan_id' => $subscription->subscription_plan_id,\n 'start_date' => $subscription->start_date,\n 'expiration_date' => $subscription->expiration_date,\n 'status' => 'active',\n );\n\n $new_subscription = new PMS_Member_Subscription();\n $new_subscription->insert( $subscription_data );\n\n pms_add_member_subscription_meta( $new_subscription->id, 'pms_group_subscription_owner', $subscription->id );\n pms_add_member_subscription_meta( $subscription->id, 'pms_group_subscription_member', $new_subscription->id );\n\n if( function_exists( 'pms_add_member_subscription_log' ) )\n pms_add_member_subscription_log( $new_subscription->id, 'group_user_subscription_added' );\n\n $invited_members++;\n\n continue;\n }\n\n // Invite user\n //save email as subscription meta\n $meta_id = pms_add_member_subscription_meta( $subscription->id, 'pms_gm_invited_emails', $email );\n\n //generate and save invite key\n $invite_key = $this->generate_invite_key( $meta_id, $email, $subscription->id );\n\n //send email\n if( $invite_key !== false )\n do_action( 'pms_gm_send_invitation_email', $email, $subscription, $invite_key );\n \t}\n\n $invited_members += (int)did_action( 'pms_gm_send_invitation_email' );\n\n if( $invited_members >= 1 )\n pms_success()->add( 'invite_members', sprintf( _n( '%d member invited successfully !', '%d members invited successfully !', $invited_members, 'paid-member-subscriptions' ), $invited_members ) );\n else\n pms_errors()->add( 'invite_members', esc_html__( 'Something went wrong. Please try again.', 'paid-member-subscriptions' ) );\n\n }", "public function isUserWinner() {\n if($this->winnerType == \"player\" && $this->winnerID == CD()->id) {\n return true;\n }\n return false;\n }", "function is_guest($member_id = null, $quick_only = false)\n{\n if (!isset($GLOBALS['FORUM_DRIVER'])) {\n return true;\n }\n if ($member_id === null) {\n $member_id = get_member($quick_only);\n }\n return ($GLOBALS['FORUM_DRIVER']->get_guest_id() == $member_id);\n}", "public function iShouldBeAbleToJoinTheGroup()\n {\n $main = $this->getMainContext();\n /** @var \\Behat\\MinkExtension\\Context\\MinkContext $mink */\n $mink = $main->getSubcontext('mink');\n\n $mink->clickLink('Join us!');\n $this->waitForPageToLoad();\n\n $mink->visit('http://www.meetup.com/sf-php/');\n\n $mink->assertPageContainsText('My profile');\n }", "protected function isUserLoggedIn() {}", "protected function isUserLoggedIn() {}", "public function getInvitedOn()\n\t{\n\t\treturn $this->invited_on;\n\t}", "public function join_conversation(Conversation $conversation) {\r\n\t\tif ($this->user_id && $conversation->conversation_id) {\r\n\t\t\tif (!$this->in_conversation($conversation)) {\r\n\t\t\t\tif ($conversation->action_allowed(clone $this, __METHOD__)) {\r\n\t\t\t\t\t$sql = \"INSERT INTO `conversation_members` (user_id, conversation_id, date) VALUES ('$this->user_id', '$conversation->conversation_id', NOW())\";\r\n\t\t\t\t\t$result = $this->dbc->query($sql)\r\n\t\t\t\t\tor die ($this->dbc->error);\r\n\r\n\t\t\t\t\t//Spawn notification here\r\n\t\t\t\t\t$action = new JoinDiscussion(array(\r\n\t\t\t\t\t\t'joiner' => clone $this,\r\n\t\t\t\t\t\t'conversation' => $conversation)\r\n\t\t\t\t\t);\r\n\t\t\t\t\tNotificationPusher::push_notification($action); //Not sure if make this succeed or die yet...\r\n\t\t\t\t\treturn true;\r\n\t\t\t\t}\r\n\t\t\t\telse {\r\n\t\t\t\t\t$sql = \"INSERT INTO `conversation_requests` (conversation_id, joiner_id, date_requested) VALUES ('$conversation->conversation_id', '$this->user_id', NOW())\";\r\n\t\t\t\t\t$result = $this->dbc->query($sql)\r\n\t\t\t\t\tor die ($this->dbc->error);\r\n\t\t\t\t\treturn true;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t}", "function ihc_user_has_level($u_id, $l_id){\n\t$user_levels = get_user_meta($u_id, 'ihc_user_levels', true);\n\tif($user_levels){\n\t\t$levels = explode(',', $user_levels);\n\t\tif (isset($levels) && count($levels) && in_array($l_id, $levels)){\n\t\t\t$user_time = ihc_get_start_expire_date_for_user_level($u_id, $l_id);\n\t\t\tif(strtotime($user_time['expire_time']) > time())\n\t\t\t\treturn TRUE;\n\t\t}\n\t}\n\treturn FALSE;\n}", "public function member()\n {\n return $this->belongsTo(User::class, 'member_id');\n }", "public function onPlayerJoin(\\pocketmine\\event\\player\\PlayerJoinEvent $event) {\r\n\r\n if($event->getPlayer()->getLevel()->getName() == $this->getName()) {\r\n\r\n $this->registerPlayer($event->getPlayer());\r\n\r\n }\r\n\r\n }", "public function validate_member()\n\t{\n\t\t//select the member by email from the database\n\t\t$this->db->select('*');\n\t\t$this->db->where(array('member_email' => strtolower($this->input->post('member_email')), 'member_status' => 1, 'member_activated' => 1, 'member_password' => md5($this->input->post('member_password'))));\n\t\t$query = $this->db->get('member');\n\t\t\n\t\t//if member exists\n\t\tif ($query->num_rows() > 0)\n\t\t{\n\t\t\t$result = $query->result();\n\t\t\t//create member's login session\n\t\t\t$newdata = array(\n 'member_login_status' => TRUE,\n 'first_name' => $result[0]->member_first_name,\n 'email' => $result[0]->member_email,\n 'member_id' => $result[0]->member_id,\n 'member' => 1\n );\n\t\t\t$this->session->set_userdata($newdata);\n\t\t\t\n\t\t\t//update member's last login date time\n\t\t\t$this->update_member_login($result[0]->member_id);\n\t\t\treturn TRUE;\n\t\t}\n\t\t\n\t\t//if member doesn't exist\n\t\telse\n\t\t{\n\t\t\treturn FALSE;\n\t\t}\n\t}", "private function onJoin()\n {\n $payload = $this->clientEvent->getPayload();\n\n if ($this->authUserByToken($payload['token'] ?? null)) {\n $this->send($this->replyEvent());\n\n $this->send(\n (new StateContentEvent(\n $this->getService('quest.quest_manager')->getStateData($this->getUserId())\n ))\n );\n }\n }", "function getJoinOnStatus()\n { \n return $this->getJoinOnFieldX('registration_status');\n }", "function do_login_as_member()\n {\n // You lack the power, mortal!\n if (Session::userdata('group_id') != 1) {\n return Cp::unauthorizedAccess();\n }\n\n // Give me something to do here...\n if (($id = Request::input('mid')) === null) {\n return Cp::unauthorizedAccess();\n }\n\n // ------------------------------------\n // Determine Return Path\n // ------------------------------------\n\n $return_path = Site::config('site_url');\n\n if (isset($_POST['return_destination']))\n {\n if ($_POST['return_destination'] == 'cp')\n {\n $return_path = Site::config('cp_url', FALSE);\n }\n elseif ($_POST['return_destination'] == 'other' && isset($_POST['other_url']) && stristr($_POST['other_url'], 'http'))\n {\n $return_path = strip_tags($_POST['other_url']);\n }\n }\n\n // ------------------------------------\n // Log Them In and Boot up new Session Data\n // ------------------------------------\n\n // Already logged in as that member\n if (Session::userdata('member_id') == $id) {\n return redirect($return_path);\n }\n\n Auth::loginUsingId($id);\n\n Session::boot();\n\n // ------------------------------------\n // Determine Redirect Path\n // ------------------------------------\n\n return redirect($return_path);\n }", "public function hasUsername(){\n return $this->_has(4);\n }", "public function is_active($member_id_of, $member_id_viewing)\n {\n return true;\n }", "public function in_group(Group $group) {\r\n\t\tif ($this->user_id && $group->group_id) {\r\n\t\t\t$sql = \"SELECT group_id FROM `group_members` WHERE group_id = '$group->group_id' AND user_id = '$this->user_id\";\r\n\t\t\t$result = $this->dbc->query($sql)\r\n\t\t\tor die ($this->dbc->error);\r\n\t\t\tif ($result->num_rows == 1) {\r\n\t\t\t\treturn true;\r\n\t\t\t}\r\n\t\t\telse {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "public function members()\n {\n return $this->belongsToMany('\\App\\Model\\User', 'joined', 'idproject', 'iduser')->withPivot('role')->orderBy('role', 'ASC');\n }", "protected function _is_staff($member)\n {\n $user_level = $this->get_member_row_field($member, 'usergroup');\n if (in_array($user_level, array(3, 4, 6))) {\n return true; // return all administrators + all moderators\n }\n //if ($user_level == 4) return true; //this returns only administrators\n return false;\n }", "public function canView($member = false) {\n if($member instanceof Member) {\n $memberID = $member->ID;\n } elseif(is_numeric($member)) {\n $memberID = $member;\n } else {\n $memberID = Member::currentUserID();\n }\n\n if($memberID && Permission::checkMember($memberID, array(\"ADMIN\", \"MESSAGE_MANAGE\"))) {\n return true;\n }\n\n return false;\n }", "public function isFriendOf($user_guid);", "public function isOnline()\n\t{\n\t\t$server = new Application_Model_Server();\n\t\t$players = $server->getOnlinePlayers();\n\t\t\n\t\tforeach ($players as $player)\n\t\t{\n\t\t\tif ($player == $this->getUsername()) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn false;\n\t}", "public function event_joined()\r\n\t{\r\n\t\r\n\t}", "function db_user_is_member_of_vsite($username, $vsid, $snuuid)\n{\n\t$sql = \"SELECT username FROM virtual_site_members\n\t\tWHERE username=$1\n\t\tAND vsid=$2\n\t\tAND snuuid=$3\";\n\t$res = pg_query_params($sql, array($username, $vsid, $snuuid));\n\treturn pg_num_rows($res) != 0;\n}" ]
[ "0.6442646", "0.6409622", "0.63284385", "0.63198924", "0.6259398", "0.6170694", "0.6145514", "0.61159366", "0.60940576", "0.60573983", "0.60070693", "0.5986187", "0.59171396", "0.5907632", "0.5812757", "0.5812118", "0.57648396", "0.57516885", "0.57339704", "0.57111645", "0.5704592", "0.56752586", "0.56617665", "0.56560796", "0.5654972", "0.563452", "0.5632064", "0.5610368", "0.5608547", "0.55794424", "0.5557186", "0.5524332", "0.5522075", "0.55111265", "0.5503762", "0.55004203", "0.5490955", "0.547898", "0.5467054", "0.54584396", "0.5452958", "0.54487664", "0.54455894", "0.54412144", "0.5438662", "0.5431774", "0.5376795", "0.5370989", "0.5365441", "0.5350381", "0.5344591", "0.53441894", "0.53405863", "0.5338641", "0.5337659", "0.53081805", "0.529768", "0.5296825", "0.5296718", "0.5284277", "0.52722037", "0.52706367", "0.52591586", "0.52591586", "0.5254821", "0.5247499", "0.5240497", "0.5228169", "0.52270603", "0.5211852", "0.52075857", "0.51986504", "0.5193905", "0.51640433", "0.51640433", "0.5156709", "0.51564354", "0.5155447", "0.51551306", "0.5154583", "0.5154583", "0.51496005", "0.5149277", "0.5145848", "0.5144738", "0.51405114", "0.5138867", "0.5136329", "0.5134554", "0.51258457", "0.5123179", "0.51198727", "0.51182383", "0.51175654", "0.5115134", "0.5114479", "0.51090574", "0.51063883", "0.5092647", "0.5086796" ]
0.67171586
0
Given an array key get it's value if it exists, otherwise return a default value.
public static function get($key, $array, $default = null) { return (isset($array[$key]) && ! empty($array[$key])) ? $array[$key] : $default; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function array_get_value($arr, $key, $default = '')\n {\n if (is_array($arr)) {\n if (key_exists($key, $arr)) {\n return $arr[$key];\n }\n return $default; \n }\n return $arr;\n }", "function array_val($array,$key,$default=null)\n{\n\tif( array_key_exists($key, $array) )\n\t\treturn $array[$key];\n\treturn $default;\n}", "function array_get(array $arr, $key, $default = null) {\n\treturn array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "public static function get( $array, $key, $default = NULL )\n\t{\n\t\treturn is_array( $array ) && array_key_exists( $key, $array ) ? $array[$key] : $default;\n\t}", "function array_key_or_default($key, $arr, $default) {\n if(array_key_exists($key, $arr))\n return $arr[$key];\n return $default;\n}", "function array_get($array, $key, $default = null)\n {\n return isset($array[$key]) ? $array[$key] : $default;\n }", "function array_get($key, $arr, $default = null) {\n return array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "public static function get($array, string $key, $default = NULL)\n {\n return $array[$key] ?? $default;\n }", "public static function tryGetValue(array $array = null, $key, $default = null)\n {\n return is_array($array) && array_key_exists($key, $array)\n ? $array[$key]\n : $default;\n }", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "public static function getOrDefault($array, $key, $default)\r\n {\r\n if (empty($array[$key])) {\r\n return $default;\r\n }\r\n return $array[$key];\r\n }", "public static function getValue($key, &$arr, $default = NULL)\n\t{\n\t\tif (Helper_Check::isStringEmptyOrNull($key))\n\t\t\treturn ($default !== NULL) ? $default : NULL;\n\t\t\t\n\t\tif (array_key_exists($key, $arr))\n\t\t\treturn $arr[$key];\n\t\t\t\n\t\treturn !Helper_Check::isNull($default) ? $default : NULL;\n\t}", "function value(array $array, int|string $key = null, mixed $default = null): mixed\n{\n if (func_num_args() > 1) {\n return $array[$key] ?? $default;\n }\n return $array ? current($array) : null; // No falses.\n}", "function getArrayVar($array, $key, $default = null)\n{\n\t$array\t= (array) $array;\n\t\n//\tif (!is_array($array))\n//\t\treturn;\n\tif ( array_key_exists($key, $array) && $array[$key] != null)\n\t\treturn $array[$key];\n\telse\n\t\treturn $default;\n}", "function safe_array_get($key, $array, $default=NULL) {\n if(!is_array($array)){\n return $default;\n }\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n return $default;\n}", "function array_val($array, $key, $default = null) {\n\t// an array of keys can be used to look in a multidimensional array\n\tif( is_array($key) ){\n\t\t$k = array_shift($key);\n\t\t//if $key is now empty then were at the end\n\t\tif( empty($key) ){\n\t\t\treturn isset($array[$k]) ? $array[$k] : $default;\n\t\t}\n\t\t//resursive call\n\t\treturn isset($array[$k]) ? array_val($array[$k], $key, $default) : $default;\n\t}\n\t//key is not an array\n\treturn isset($array[$key]) ? $array[$key] : $default;\n}", "function arrayGet($array, $key, $default = NULL)\n{\n return isset($array[$key]) ? $array[$key] : $default;\n}", "function get_array_var( $array, $key = '', $default = false ) {\n\tif ( isset_not_empty( $array, $key ) ) {\n\t\tif ( is_object( $array ) ) {\n\t\t\treturn $array->$key;\n\t\t} else if ( is_array( $array ) ) {\n\t\t\treturn $array[ $key ];\n\t\t}\n\t}\n\n\treturn $default;\n}", "function val(array $array, $key) {\r\n\treturn array_key_exists($key, $array) ? $array[$key] : null;\r\n}", "protected static function val($key, $array, $default = null) {\n if (is_array($array)) {\n // isset() is a micro-optimization - it is fast but fails for null values.\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n // Comparing $default is also a micro-optimization.\n if ($default === null || array_key_exists($key, $array)) {\n return null;\n }\n } elseif (is_object($array)) {\n if (isset($array->$key)) {\n return $array->$key;\n }\n\n if ($default === null || property_exists($array, $key)) {\n return null;\n }\n }\n\n return $default;\n }", "protected function getArrValue(array $array, $key, $default = null)\n {\n if (is_null($key)) {\n return $default;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n return $default;\n }", "function array_get(array $a, $key, $default = null) {\n return isset($a[$key]) ? $a[$key] : $default;\n}", "public function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "private function _get_array_value($array, $key)\r\n {\r\n if(array_key_exists($key, $array))\r\n {\r\n return $array[$key];\r\n }\r\n return NULL;\r\n }", "function array_get(array $array, $key, $default = null) {\n if ($key === null) {\n return null;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if ( ! is_array($array) || ! array_key_exists($segment, $array)) {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get(array $array, string $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($array) || ! array_key_exists($segment, $array)) {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = null)\n {\n if (is_null($key)) return $array;\n\n if (isset($array[$key])) return $array[$key];\n\n foreach (explode('.', $key) as $segment)\n {\n if ( ! is_array($array) || ! array_key_exists($segment, $array))\n {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = null)\n\t{\n\t\tif (is_null($key)) return $array;\n\n\t\tif (isset($array[$key])) return $array[$key];\n\n\t\tforeach (explode('.', $key) as $segment)\n\t\t{\n\t\t\tif ( ! is_array($array) || ! array_key_exists($segment, $array))\n\t\t\t{\n\t\t\t\treturn value($default);\n\t\t\t}\n\n\t\t\t$array = $array[$segment];\n\t\t}\n\n\t\treturn $array;\n\t}", "public function getVal($key = '', $default = null) {\n $array = $this->array;\n if($key == '') {\n return $array;\n }\n $keys = explode('/', $key);\n $count = count($keys);\n $i = 0;\n foreach($keys as $k => $val) {\n $i++;\n if($val == '') {\n continue;\n }\n if(isset($array[$val]) && !is_array($array[$val])) {\n if($array[$val] !== null && $i == $count) {\n return $array[$val];\n }\n return $default;\n }\n if(isset($array[$val])) {\n $array = $array[$val];\n } else {\n return $default;\n }\n if(is_array($array) && key($array) == '0') {\n $array = current($array);\n }\n }\n return $array;\n }", "function array_get($array, $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (is_array($array) && array_key_exists($segment, $array)) {\n $array = $array[$segment];\n } else {\n return $default;\n }\n }\n\n return $array;\n }", "private static function getKey($key, array &$arr, $default=null)\r\n {\r\n return (array_key_exists($key, $arr)?$arr[$key]:$default);\r\n }", "public static function get($array, $key, $default = null, $default_if_null = false)\n\t{\n\t\tif (!is_array($array))\n\t\t{\n\t\t\tif ($array)\n\t\t\t{\n\t\t\t\tdmDebug::bug(array(\n \"dmArray::get() : $array is not an array\",\n\t\t\t\t var_dump($array)\n\t\t\t\t));\n\t\t\t}\n\t\t\treturn $default;\n\t\t}\n\n\t\tif (false === $default_if_null)\n\t\t{\n\t\t\tif(isset($array[$key]))\n\t\t\t{\n\t\t\t\treturn $array[$key];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\treturn $default;\n\t\t\t}\n\t\t}\n\n\t\tif(!empty($array[$key]))\n\t\t{\n\t\t\treturn $array[$key];\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $default;\n\t\t}\n\t}", "function GetEntry($arr, $key, $default = NULL)\n{\n return array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "public static function get_array($array, $key, $default = null)\n\t{\n\t\treturn (isset($array) && isset($key) && isset($array[$key]) ? $array[$key] : $default);\n\t}", "function array_get($array, $key, $default = null)\n {\n if ($key) {\n $key = str_replace(':', '.', $key);\n }\n\n return Arr::get($array, $key, $default);\n }", "static function get(array $array, $key, $default = null) {\n if (null === $key) {\n return $array;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $part) {\n if (!is_array($array) || !array_key_exists($part, $array)) {\n return $default;\n }\n\n $array = $array[$part];\n }\n\n return $array;\n }", "function getItem($key, $array, $default=null) {\n\t\tif (array_key_exists($key, $array)) {\n\t\t\treturn $array[$key];\n\t\t} else {\n\t\t\tif (func_num_args() === 3) {\n\t\t\t\treturn $default;\n\t\t\t} else {\n\t\t\t\tthrow Exception('Unable to find key '.$key.' in the array '.var_dump($array, true));\n\t\t\t}\n\t\t}\n\t}", "public static function getValue($array, $key, $default = null)\n {\n if (is_string($key)) {\n // Iterate path\n $keys = explode('.', $key);\n foreach ($keys as $key) {\n if (!isset($array[$key])) {\n return $default;\n }\n $array = &$array[$key];\n }\n // Get value\n return $array;\n } elseif (is_null($key)) {\n // Get all data\n return $array;\n }\n return null;\n }", "function array_access($array, $key, $default) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n return $default;\n }", "public function get(string $key, mixed $default = null): mixed\n {\n $data = $this->arrayify();\n\n return array_get($data, $key, $default);\n }", "public static function get(array $array, string $key, mixed $default = NULL): mixed\n {\n\n if (isset($array[$key])) {\n\n return $array[$key];\n\n }\n\n foreach (explode('.', $key) as $segment) {\n\n if (!is_array($array) || !array_key_exists($segment, $array)) {\n\n return $default;\n\n }\n\n $array = $array[$segment];\n\n }\n\n return $array;\n\n }", "function get($arr, $key, $def = null) {\n\tif(isset($arr[$key]) && !empty($arr[$key])) {\n\t\treturn $arr[$key];\n\t}\n\t\n\treturn $def;\n}", "function array_get($array, $key, $default = NULL) {\n\tif(is_null($key)) return $array;\n\n\t//L o g::w('key: ' . $key);\n\tforeach(explode('.', $key) as $segment) {\n\t\t//L o g::w('segment: ' . $segment);\n\t\tif(!is_array($array) || !array_key_exists($segment, $array)) {\n\t\t\treturn $default;\n\t\t}\n\n\t\t$array = $array[$segment];\n\t}\n\n\treturn $array;\n}", "function value($value,$key=0,$default=false) {\n if((is_string($key) OR is_int($key)) AND is_array($value)) {\n if(array_key_exists($key,$value)) {\n return $value[$key];\n }\n }\n return $default;\n}", "public static function array_get($array, $key, $default = null) {\n\n \tif (is_null($key)) return $array;\n \n \tif (isset($array[$key])) return $array[$key];\n\n \tforeach (explode('.', $key) as $segment) {\n\n \t\tif ( ! is_array($array) or ! array_key_exists($segment, $array)) {\n return $default;\n \t}\n \t\t\t\t$array = $array[$segment];\n \t}\n \t\t\treturn $array;\n \t}", "function arrayGet($array, $key, $default = null)\n {\n if ( ! $this->arrayAccessible($array) ) {\n return $this->value($default);\n }\n if ( is_null($key) ) {\n return $array;\n }\n if ( $this->arrayExists($array, $key) ) {\n return $array[$key];\n }\n if ( strpos($key, '.') === false ) {\n return $array[$key] ?? $this->value($default);\n }\n foreach ( explode('.', $key) as $segment ) {\n if ( $this->arrayAccessible($array) && $this->arrayExists($array, $segment) ) {\n $array = $array[$segment];\n } else {\n return $this->value($default);\n }\n }\n return $array;\n }", "function array_get($array, $key, $default = null)\n{\n if (is_null($key)) {\n return $array;\n }\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if ( ! is_array($array) or ! array_key_exists($segment, $array)) {\n return $default;\n }\n $array = $array[$segment];\n }\n\n return $array;\n}", "private function getArrayValue(array &$array, string $key, $defaultValue = null)\n {\n if (!array_key_exists($key, $array)) {\n return $defaultValue;\n }\n\n return $array[$key];\n }", "public function psc_val_arr_key( $key, $array ) {\n\n\t\tif( array_key_exists( $key, $array ) && !empty( $array[ $key ] ) ) {\n\t\t\treturn $array[ $key ];\n\t\t} else {\n\t\t\treturn FALSE; // return nothing\n\t\t}\n\n\t}", "public function get($key, $array_key = null)\n {\n if (!isset($this->_combined[$key]))\n return null;\n\n $value = $this->_combined[$key];\n if ($array_key !== null) {\n $value = $value[$array_key];\n }\n\n return $value;\n }", "public function getValueOrDefault($key) {\n return $this->values->get($key) !== NULL\n ? $this->values->get($key)\n : $this->values->get('Default'.$key);\n }", "public static function getArrayElement(array $array, $key, $defaultValue = null) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n return $defaultValue;\n }", "protected function _get(array $array, $key, $default = null)\n {\n $keys = explode('.', $key);\n\n foreach ($keys as $segment) {\n if (!is_array($array) || !array_key_exists($segment, $array)) {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "private function val($arr, $key, $default = null)\n {\n if (isset($arr[$key])) {\n return is_bool($arr[$key]) ? var_export($arr[$key], true) : $arr[$key];\n }\n return $default;\n }", "private function val($arr, $key, $default = null)\n {\n if (isset($arr[$key])) {\n return is_bool($arr[$key]) ? var_export($arr[$key], true) : $arr[$key];\n }\n return $default;\n }", "public static function get($array, $key, $default = null)\n {\n if (is_null($key)) return $array;\n\n if (isset($array[$key])) return $array[$key];\n\n foreach (explode('.', $key) as $segment)\n {\n if ( ! is_array($array) || ! array_key_exists($segment, $array))\n {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "public static function get($array, $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (is_object($array)) {\n return self::object_get($array, $key, $default);\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($array) || ! array_key_exists($segment, $array)) {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "public static function getValue($array, $key, $default = null)\n {\n if ($key instanceof \\Closure) {\n return $key($array, $default);\n }\n\n if (is_array($key)) {\n $lastKey = array_pop($key);\n foreach ($key as $keyPart) {\n $array = static::getValue($array, $keyPart);\n }\n $key = $lastKey;\n }\n\n if (is_array($array) && (isset($array[$key]) || array_key_exists($key, $array))) {\n return $array[$key];\n }\n\n if (($pos = strrpos($key, '.')) !== false) {\n $array = static::getValue($array, substr($key, 0, $pos), $default);\n $key = substr($key, $pos + 1);\n }\n\n if (is_object($array)) {\n // this is expected to fail if the property does not exist, or __get() is not implemented\n // it is not reliably possible to check whether a property is accessible beforehand\n return $array->$key;\n } elseif (is_array($array)) {\n return (isset($array[$key]) || array_key_exists($key, $array)) ? $array[$key] : $default;\n }\n\n return $default;\n }", "public function get(string $key, $default = null)\n {\n return array_get($this->raw, $key, $default);\n }", "public static function array_get(ArrayValue $arr, Value $key, Value $default = null): Value {\n\t\tCommon::allowTypes($key, StringValue::class, NumberValue::class);\n\t\treturn $arr->value[$key->value] ?? $default ?? new NullValue;\n\n\t}", "public function get($key, $default = null)\n {\n return DotArr::get($this->data, $key, $default);\n }", "private function ine($key, $arr, $default = null)\n {\n return isset($arr[$key]) ? $arr[$key] : $default;\n }", "function atkArrayNvl($array, $key, $defaultvalue=null)\n{\n\treturn (isset($array[$key]) ? $array[$key] : $defaultvalue);\n}", "function array_val_json(array $array, $key, $default = array()) { \n\t// get the value out of the array if it exists\n\tif( $value = array_val($array, $key) ){\n\t\t$arr = json_decode($value, 1);\n\t\t// if it didnt fail, return it\n\t\tif( $arr !== false ){\n\t\t\t// json decode succeded, return the result\n\t\t\treturn $arr;\n\t\t}\n\t}\n\t// return the default\n\treturn $default; \n}", "public function get($key, $default = []);", "public static function array_value($_key, array $_array)\n {\n return (isset($_array[$_key]) || array_key_exists($_key, $_array)) ? $_array[$_key] : NULL;\n }", "public function get(string $key, $default = null)\n {\n\t\treturn array_key_exists($key, $this->values) ? $this->values[$key] : $default;\n\t}", "function get($key, $default = null)\n{\n if (is_array($key)) {\n foreach ($key as $val) {\n if (isset($_GET[$val])) {\n return $_GET[$val];\n }\n }\n } elseif (isset($_GET[$key])) {\n return $_GET[$key];\n }\n return $default;\n}", "public function get($key, $default = null) {\n return array_key_exists($key, $this->values) ? $this->values[$key] : $default;\n }", "protected function arrayGet($key, $default = null)\n {\n if (isset($this->list[$key])) {\n return $this->list[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($this->list) || ! array_key_exists($segment, $this->list)) {\n return value($default);\n }\n\n $this->list = $this->list[$segment];\n }\n\n return $this->list;\n }", "public function get(string $key, $default = null)\n {\n return Arr::get($this->values, $key, $default);\n }", "public static function get($array, $key, $default = null)\n {\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $default;\n }\n\n $items = $array;\n\n foreach (explode('.', $key) as $segment) {\n if (!is_array($items) || !static::exists($items, $segment)) {\n return $default;\n }\n\n $items = &$items[$segment];\n }\n\n return $items;\n }", "function idx(array $array, $key, $default = null) {\n // isset() is a micro-optimization - it is fast but fails for null values.\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n // Comparing $default is also a micro-optimization.\n if ($default === null || array_key_exists($key, $array)) {\n return null;\n }\n\n return $default;\n}", "public function get( $key ) {\n\t\treturn ( $this->has($key) ? $this->array[$key] : null );\n\t}", "function cspm_setting_exists($key, $array, $default = ''){\r\n\t\t\t\r\n\t\t\t$array_value = isset($array[$key]) ? $array[$key] : $default;\r\n\t\t\t\r\n\t\t\t$setting_value = empty($array_value) ? $default : $array_value;\r\n\t\t\t\r\n\t\t\treturn $setting_value;\r\n\t\t\t\r\n\t\t}", "public function get($key, $default = null)\n {\n if(array_key_exists($key,$this->config_arr))\n return $this->config_arr[$key];\n else\n return $default;\n }", "function array_pull(&$array, $key, $default = null)\n\t{\n\t\t$value = array_get($array, $key, $default);\n\n\t\tarray_forget($array, $key);\n\n\t\treturn $value;\n\t}", "public function getOrDefault($key, $defaultValue);", "static function from(array $arr, $key, $default = null, $one = true) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n $grep = preg_grep('/^('.preg_quote($key, '/').')$/i', array_keys($array));\n $ret = array_intersect_key($arr, array_flip($grep));\n\n return empty($ret) ? $default : ($one ? end($ret) : $ret);\n }", "function array_take(array &$array, $key, $default = null) {\n $value = array_get($array, $key, $default);\n\n if (array_has($array, $key)) {\n array_remove($array, $key);\n }\n\n return $value;\n }", "function array_get($arr, $key, $notfound = ''){\r\n\tif (!isset($arr[$key])){\r\n\t\treturn $notfound;\r\n\t}\r\n\treturn $arr[$key];\r\n}", "public function get( $key, $default = null )\n\t{\n\t\treturn Arr::get( $this->items, $key, $default );\n\t}", "public static function get($array, $key, $default = null)\n {\n if (! static::accessible($array)) {\n return $default;\n }\n\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $array[$key] ?? $default;\n }\n\n foreach (explode('.', $key) as $segment) {\n if (static::accessible($array) && static::exists($array, $segment)) {\n $array = $array[$segment];\n } else {\n return $default;\n }\n }\n\n return $array;\n }", "public function get($key, $default = null){\n $key = str_replace(\"mpesa.\",\"\",$key);\n $array = $this->items;\n if (! static::accessible($array)) {\n return $this->value($default);\n }\n\n if (is_null($key)) {\n return $array;\n }\n\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $array[$key] ?: $this->value($default);\n }\n \n foreach (explode('.', $key) as $segment) {\n if (static::accessible($array) && static::exists($array, $segment)) {\n $array = $array[$segment];\n } else {\n return $this->value($default);\n }\n }\n \n return $array;\n }", "public static function get( $array, $key, $default = null ) {\n\t\t\tif ( ! static::accessible( $array ) ) {\n\t\t\t\treturn $default;\n\t\t\t}\n\n\t\t\tif ( static::exists( $array, $key ) ) {\n\t\t\t\treturn $array[ $key ];\n\t\t\t}\n\n\t\t\t$key = (string) $key;\n\n\t\t\tif ( strpos( $key, '.' ) === false ) {\n\t\t\t\treturn $array[ $key ] ?? $default;\n\t\t\t}\n\n\t\t\tforeach ( explode( '.', $key ) as $segment ) {\n\t\t\t\tif ( static::accessible( $array ) && static::exists( $array, $segment ) ) {\n\t\t\t\t\t$array = $array[ $segment ];\n\t\t\t\t} else {\n\t\t\t\t\treturn $default;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $array;\n\t\t}", "public function getIfExists($key, $default_value=null);", "function getValue($key, $default = null)\r\n {\r\n return $this->coalesce($this->container[$key], $default);\r\n }", "public static function get($array, $key, $default = null)\n {\n if (is_null($key))\n {\n return $array;\n }\n \n if (is_object($array))\n {\n $array = self::fromObject($array);\n }\n \n if (isset($array[$key]))\n {\n return $array[$key];\n }\n \n foreach (explode('.', $key) as $segment)\n {\n if (is_object($array))\n {\n $array = self::fromObject($array);\n }\n \n if (!is_array($array) || !array_key_exists($segment, $array))\n {\n return $default;\n }\n \n $array = $array[$segment];\n }\n \n return $array;\n }", "public static function get($key, $array, $fallback = null)\n\t{\n\t\tif (isset($array[$key])) {\n\t\t\treturn $array[$key];\n\t\t}\n\n\t\treturn $fallback;\n\t}", "function array_element(string $key, array $array) {\n\t\t// We want to take the performance advantage of isset() while keeping\n\t\t// the NULL element correctly detected\n\t\t// See: http://php.net/manual/es/function.array-key-exists.php#107786\n\t\tif (isset($array[$key]) || array_key_exists($key, $array)) {\n\t\t\treturn $array[$key];\n\t\t}\n\n\t\treturn null;\n\t}", "function array_get($key, $array)\n {\n return arr::get($key, $array);\n }", "public function get($key, $default = null)\n {\n return array_key_exists($key, $this->data) ? $this->data[$key] : $default;\n }", "private function pullOutArrayValue(array &$array, string $key, $defaultValue = null)\n {\n if (!array_key_exists($key, $array)) {\n return $defaultValue;\n }\n\n $value = $array[$key];\n unset($array[$key]);\n\n return $value;\n }", "public static function pull(&$array, $key, $default = null)\n {\n $value = static::get($array, $key, $default);\n\n static::forget($array, $key);\n\n return $value;\n }", "public static function pull(&$array, $key, $default = null)\n {\n $value = static::get($array, $key, $default);\n\n static::forget($array, $key);\n\n return $value;\n }", "public static function pull(&$array, $key, $default = null)\n {\n $value = static::get($array, $key, $default);\n\n static::forget($array, $key);\n\n return $value;\n }", "public static function pull(&$array, $key, $default = null)\n {\n $value = static::get($array, $key, $default);\n\n static::forget($array, $key);\n\n return $value;\n }", "public static function getArrayValue(array $array, $name, $default = null)\n {\n return \\array_key_exists($name, $array)\n ? $array[$name]\n : $default;\n }" ]
[ "0.84766006", "0.8399143", "0.8166228", "0.8113124", "0.8069086", "0.8053488", "0.8041811", "0.8002532", "0.79955745", "0.7964357", "0.7964357", "0.7964357", "0.79360235", "0.79206514", "0.79191196", "0.7877739", "0.7871097", "0.7864235", "0.7855704", "0.78499514", "0.7815958", "0.78148", "0.78143585", "0.77236104", "0.77183807", "0.7698296", "0.766977", "0.7648954", "0.7642093", "0.76211095", "0.76116216", "0.75942874", "0.75845087", "0.7575208", "0.75644535", "0.75316215", "0.75261307", "0.7517812", "0.7488449", "0.7469394", "0.7453026", "0.74415654", "0.74267113", "0.7388859", "0.73873067", "0.7350667", "0.7341243", "0.733479", "0.73127586", "0.7294114", "0.7264048", "0.72502315", "0.72443485", "0.7194696", "0.7191717", "0.7184908", "0.7184908", "0.71816087", "0.7179964", "0.7165526", "0.7153355", "0.7147768", "0.70887786", "0.7083259", "0.7077441", "0.707625", "0.7042327", "0.70422804", "0.7038715", "0.7036395", "0.70245016", "0.7024454", "0.70061594", "0.6997136", "0.69728875", "0.692462", "0.69242173", "0.69178855", "0.69057196", "0.69032633", "0.68860286", "0.68705213", "0.6862247", "0.68604237", "0.6859469", "0.6851902", "0.6849833", "0.68486726", "0.68376774", "0.68258095", "0.6819391", "0.6815419", "0.6803739", "0.6789743", "0.6752326", "0.67515075", "0.67515075", "0.67515075", "0.67515075", "0.6748161" ]
0.7982851
9
Given an array key in "dot notation" get an array value if it exists, otherwise return a default value.
public static function getFromString($keys, $array, $default = null) { foreach (explode('.', $keys) as $key) { if (!is_array($array) or !array_key_exists($key, $array)) { return $default; } $array = $array[$key]; } return $array; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function array_get($array, $key, $default = null)\n {\n if (is_null($key)) return $array;\n\n if (isset($array[$key])) return $array[$key];\n\n foreach (explode('.', $key) as $segment)\n {\n if ( ! is_array($array) || ! array_key_exists($segment, $array))\n {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get(array $array, string $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($array) || ! array_key_exists($segment, $array)) {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (is_array($array) && array_key_exists($segment, $array)) {\n $array = $array[$segment];\n } else {\n return $default;\n }\n }\n\n return $array;\n }", "function array_get(array $array, $key, $default = null) {\n if ($key === null) {\n return null;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if ( ! is_array($array) || ! array_key_exists($segment, $array)) {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = null)\n\t{\n\t\tif (is_null($key)) return $array;\n\n\t\tif (isset($array[$key])) return $array[$key];\n\n\t\tforeach (explode('.', $key) as $segment)\n\t\t{\n\t\t\tif ( ! is_array($array) || ! array_key_exists($segment, $array))\n\t\t\t{\n\t\t\t\treturn value($default);\n\t\t\t}\n\n\t\t\t$array = $array[$segment];\n\t\t}\n\n\t\treturn $array;\n\t}", "function arrayGet($array, $key, $default = null)\n {\n if ( ! $this->arrayAccessible($array) ) {\n return $this->value($default);\n }\n if ( is_null($key) ) {\n return $array;\n }\n if ( $this->arrayExists($array, $key) ) {\n return $array[$key];\n }\n if ( strpos($key, '.') === false ) {\n return $array[$key] ?? $this->value($default);\n }\n foreach ( explode('.', $key) as $segment ) {\n if ( $this->arrayAccessible($array) && $this->arrayExists($array, $segment) ) {\n $array = $array[$segment];\n } else {\n return $this->value($default);\n }\n }\n return $array;\n }", "function array_get($array, $key, $default = null)\n{\n if (is_null($key)) {\n return $array;\n }\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if ( ! is_array($array) or ! array_key_exists($segment, $array)) {\n return $default;\n }\n $array = $array[$segment];\n }\n\n return $array;\n}", "static function get(array $array, $key, $default = null) {\n if (null === $key) {\n return $array;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $part) {\n if (!is_array($array) || !array_key_exists($part, $array)) {\n return $default;\n }\n\n $array = $array[$part];\n }\n\n return $array;\n }", "public static function get(array $array, string $key, mixed $default = NULL): mixed\n {\n\n if (isset($array[$key])) {\n\n return $array[$key];\n\n }\n\n foreach (explode('.', $key) as $segment) {\n\n if (!is_array($array) || !array_key_exists($segment, $array)) {\n\n return $default;\n\n }\n\n $array = $array[$segment];\n\n }\n\n return $array;\n\n }", "public static function array_get($array, $key, $default = null) {\n\n \tif (is_null($key)) return $array;\n \n \tif (isset($array[$key])) return $array[$key];\n\n \tforeach (explode('.', $key) as $segment) {\n\n \t\tif ( ! is_array($array) or ! array_key_exists($segment, $array)) {\n return $default;\n \t}\n \t\t\t\t$array = $array[$segment];\n \t}\n \t\t\treturn $array;\n \t}", "public static function get($array, $key, $default = null)\n {\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $default;\n }\n\n $items = $array;\n\n foreach (explode('.', $key) as $segment) {\n if (!is_array($items) || !static::exists($items, $segment)) {\n return $default;\n }\n\n $items = &$items[$segment];\n }\n\n return $items;\n }", "public static function get($array, $key, $default = null)\n {\n if (is_null($key)) return $array;\n\n if (isset($array[$key])) return $array[$key];\n\n foreach (explode('.', $key) as $segment)\n {\n if ( ! is_array($array) || ! array_key_exists($segment, $array))\n {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = NULL) {\n\tif(is_null($key)) return $array;\n\n\t//L o g::w('key: ' . $key);\n\tforeach(explode('.', $key) as $segment) {\n\t\t//L o g::w('segment: ' . $segment);\n\t\tif(!is_array($array) || !array_key_exists($segment, $array)) {\n\t\t\treturn $default;\n\t\t}\n\n\t\t$array = $array[$segment];\n\t}\n\n\treturn $array;\n}", "public static function get($array, $key, $default = null)\n {\n if (! static::accessible($array)) {\n return $default;\n }\n\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $array[$key] ?? $default;\n }\n\n foreach (explode('.', $key) as $segment) {\n if (static::accessible($array) && static::exists($array, $segment)) {\n $array = $array[$segment];\n } else {\n return $default;\n }\n }\n\n return $array;\n }", "public static function get($array, $key, $default = null)\n {\n if (is_null($key)) {\n return $array;\n }\n\n if (is_object($array)) {\n return self::object_get($array, $key, $default);\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($array) || ! array_key_exists($segment, $array)) {\n return value($default);\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "protected function _get(array $array, $key, $default = null)\n {\n $keys = explode('.', $key);\n\n foreach ($keys as $segment) {\n if (!is_array($array) || !array_key_exists($segment, $array)) {\n return $default;\n }\n\n $array = $array[$segment];\n }\n\n return $array;\n }", "function array_get($array, $key, $default = null)\n {\n if ($key) {\n $key = str_replace(':', '.', $key);\n }\n\n return Arr::get($array, $key, $default);\n }", "public static function get( $array, $key, $default = null ) {\n\t\t\tif ( ! static::accessible( $array ) ) {\n\t\t\t\treturn $default;\n\t\t\t}\n\n\t\t\tif ( static::exists( $array, $key ) ) {\n\t\t\t\treturn $array[ $key ];\n\t\t\t}\n\n\t\t\t$key = (string) $key;\n\n\t\t\tif ( strpos( $key, '.' ) === false ) {\n\t\t\t\treturn $array[ $key ] ?? $default;\n\t\t\t}\n\n\t\t\tforeach ( explode( '.', $key ) as $segment ) {\n\t\t\t\tif ( static::accessible( $array ) && static::exists( $array, $segment ) ) {\n\t\t\t\t\t$array = $array[ $segment ];\n\t\t\t\t} else {\n\t\t\t\t\treturn $default;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $array;\n\t\t}", "public static function get($array, $key, $default = null)\n {\n if (is_null($key))\n {\n return $array;\n }\n \n if (is_object($array))\n {\n $array = self::fromObject($array);\n }\n \n if (isset($array[$key]))\n {\n return $array[$key];\n }\n \n foreach (explode('.', $key) as $segment)\n {\n if (is_object($array))\n {\n $array = self::fromObject($array);\n }\n \n if (!is_array($array) || !array_key_exists($segment, $array))\n {\n return $default;\n }\n \n $array = $array[$segment];\n }\n \n return $array;\n }", "protected function arrayGet($key, $default = null)\n {\n if (isset($this->list[$key])) {\n return $this->list[$key];\n }\n\n foreach (explode('.', $key) as $segment) {\n if (! is_array($this->list) || ! array_key_exists($segment, $this->list)) {\n return value($default);\n }\n\n $this->list = $this->list[$segment];\n }\n\n return $this->list;\n }", "function array_get_value($arr, $key, $default = '')\n {\n if (is_array($arr)) {\n if (key_exists($key, $arr)) {\n return $arr[$key];\n }\n return $default; \n }\n return $arr;\n }", "public static function getValue($array, $key, $default = null)\n {\n if (is_string($key)) {\n // Iterate path\n $keys = explode('.', $key);\n foreach ($keys as $key) {\n if (!isset($array[$key])) {\n return $default;\n }\n $array = &$array[$key];\n }\n // Get value\n return $array;\n } elseif (is_null($key)) {\n // Get all data\n return $array;\n }\n return null;\n }", "function getArrayVar($array, $key, $default = null)\n{\n\t$array\t= (array) $array;\n\t\n//\tif (!is_array($array))\n//\t\treturn;\n\tif ( array_key_exists($key, $array) && $array[$key] != null)\n\t\treturn $array[$key];\n\telse\n\t\treturn $default;\n}", "function array_get(array $arr, $key, $default = null) {\n\treturn array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "function array_val($array,$key,$default=null)\n{\n\tif( array_key_exists($key, $array) )\n\t\treturn $array[$key];\n\treturn $default;\n}", "function get_array_var( $array, $key = '', $default = false ) {\n\tif ( isset_not_empty( $array, $key ) ) {\n\t\tif ( is_object( $array ) ) {\n\t\t\treturn $array->$key;\n\t\t} else if ( is_array( $array ) ) {\n\t\t\treturn $array[ $key ];\n\t\t}\n\t}\n\n\treturn $default;\n}", "function array_dot_get(array $array, $key) {\n\tif(strpos($key, '.') === false)\n\t\treturn $array[$key];\n\n\t$target = &$array;\n\t$keys = explode('.', $key);\n\tforeach($keys as $curKey) {\n\t\tif(!array_key_exists($curKey, $target))\n\t\t\treturn null;\n\t\t$target = &$target[$curKey];\n\t}\n\n\treturn $target;\n}", "public static function get( $array, $key, $default = NULL )\n\t{\n\t\treturn is_array( $array ) && array_key_exists( $key, $array ) ? $array[$key] : $default;\n\t}", "function array_get($array, $key, $default = null)\n {\n return isset($array[$key]) ? $array[$key] : $default;\n }", "function array_get($key, $arr, $default = null) {\n return array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "function safe_array_get($key, $array, $default=NULL) {\n if(!is_array($array)){\n return $default;\n }\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n return $default;\n}", "public function get($key, $default = null){\n $key = str_replace(\"mpesa.\",\"\",$key);\n $array = $this->items;\n if (! static::accessible($array)) {\n return $this->value($default);\n }\n\n if (is_null($key)) {\n return $array;\n }\n\n if (static::exists($array, $key)) {\n return $array[$key];\n }\n\n if (strpos($key, '.') === false) {\n return $array[$key] ?: $this->value($default);\n }\n \n foreach (explode('.', $key) as $segment) {\n if (static::accessible($array) && static::exists($array, $segment)) {\n $array = $array[$segment];\n } else {\n return $this->value($default);\n }\n }\n \n return $array;\n }", "function array_key_or_default($key, $arr, $default) {\n if(array_key_exists($key, $arr))\n return $arr[$key];\n return $default;\n}", "public static function tryGetValue(array $array = null, $key, $default = null)\n {\n return is_array($array) && array_key_exists($key, $array)\n ? $array[$key]\n : $default;\n }", "function arrayGet($array, $key, $default = NULL)\n{\n return isset($array[$key]) ? $array[$key] : $default;\n}", "public static function get($array, string $key, $default = NULL)\n {\n return $array[$key] ?? $default;\n }", "public static function get($key, $array, $default = null)\n {\n return (isset($array[$key]) && ! empty($array[$key])) ? $array[$key] : $default;\n }", "function array_val($array, $key, $default = null) {\n\t// an array of keys can be used to look in a multidimensional array\n\tif( is_array($key) ){\n\t\t$k = array_shift($key);\n\t\t//if $key is now empty then were at the end\n\t\tif( empty($key) ){\n\t\t\treturn isset($array[$k]) ? $array[$k] : $default;\n\t\t}\n\t\t//resursive call\n\t\treturn isset($array[$k]) ? array_val($array[$k], $key, $default) : $default;\n\t}\n\t//key is not an array\n\treturn isset($array[$key]) ? $array[$key] : $default;\n}", "public function array_get($array, $key, $default = null)\n {\n return Arr::get($array, $key, $default);\n }", "public static function getValue($array, $key, $default = null)\n {\n if ($key instanceof \\Closure) {\n return $key($array, $default);\n }\n\n if (is_array($key)) {\n $lastKey = array_pop($key);\n foreach ($key as $keyPart) {\n $array = static::getValue($array, $keyPart);\n }\n $key = $lastKey;\n }\n\n if (is_array($array) && (isset($array[$key]) || array_key_exists($key, $array))) {\n return $array[$key];\n }\n\n if (($pos = strrpos($key, '.')) !== false) {\n $array = static::getValue($array, substr($key, 0, $pos), $default);\n $key = substr($key, $pos + 1);\n }\n\n if (is_object($array)) {\n // this is expected to fail if the property does not exist, or __get() is not implemented\n // it is not reliably possible to check whether a property is accessible beforehand\n return $array->$key;\n } elseif (is_array($array)) {\n return (isset($array[$key]) || array_key_exists($key, $array)) ? $array[$key] : $default;\n }\n\n return $default;\n }", "public function getVal($key = '', $default = null) {\n $array = $this->array;\n if($key == '') {\n return $array;\n }\n $keys = explode('/', $key);\n $count = count($keys);\n $i = 0;\n foreach($keys as $k => $val) {\n $i++;\n if($val == '') {\n continue;\n }\n if(isset($array[$val]) && !is_array($array[$val])) {\n if($array[$val] !== null && $i == $count) {\n return $array[$val];\n }\n return $default;\n }\n if(isset($array[$val])) {\n $array = $array[$val];\n } else {\n return $default;\n }\n if(is_array($array) && key($array) == '0') {\n $array = current($array);\n }\n }\n return $array;\n }", "function array_get(array $a, $key, $default = null) {\n return isset($a[$key]) ? $a[$key] : $default;\n}", "public static function getOrDefault($array, $key, $default)\r\n {\r\n if (empty($array[$key])) {\r\n return $default;\r\n }\r\n return $array[$key];\r\n }", "public static function get($array, $keys, $default = NULL)\n {\n \n if (!static::accessible($array)) {\n return $default;\n }\n \n if (is_null($keys)) {\n return $array;\n }\n \n if (static::exists($array, $keys)) {\n return $array[$keys];\n }\n \n foreach (explode('.', $keys) as $segment) {\n \n if (static::accessible($array) && static::exists($array, $segment)) {\n \n $array = $array[$segment];\n } else {\n \n return $default;\n }\n }\n \n return $array;\n \n }", "static public function get($key, $default = null)\n {\n $keys = explode('.', $key);\n \n // Root search\n $k = array_shift($keys);\n $opt = isset(self::$_config[$k]) ? self::$_config[$k] : null;\n \n // Iterative search\n foreach ($keys as $k) {\n if (!isset($opt[$k])) {\n return $default;\n } \n $opt = $opt[$k];\n }\n \n return $opt !== null ? $opt : $default;\n }", "public static function get_array($array, $key, $default = null)\n\t{\n\t\treturn (isset($array) && isset($key) && isset($array[$key]) ? $array[$key] : $default);\n\t}", "function array_access($array, $key, $default) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n return $default;\n }", "function data_get($target, $key, $default = null)\n {\n if ( is_null($key) )\n return $target;\n\n foreach (explode('.', $key) as $segment)\n {\n if (is_array($target)) {\n if ( ! array_key_exists($segment, $target)) {\n return value($default);\n }\n\n $target = $target[$segment];\n }\n elseif (is_object($target)) {\n if ( ! isset($target->{$segment})) {\n return value($default);\n }\n\n $target = $target->{$segment};\n }\n else {\n return value($default);\n }\n }\n\n return $target;\n }", "public static function get($array, $key, $default = null, $default_if_null = false)\n\t{\n\t\tif (!is_array($array))\n\t\t{\n\t\t\tif ($array)\n\t\t\t{\n\t\t\t\tdmDebug::bug(array(\n \"dmArray::get() : $array is not an array\",\n\t\t\t\t var_dump($array)\n\t\t\t\t));\n\t\t\t}\n\t\t\treturn $default;\n\t\t}\n\n\t\tif (false === $default_if_null)\n\t\t{\n\t\t\tif(isset($array[$key]))\n\t\t\t{\n\t\t\t\treturn $array[$key];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\treturn $default;\n\t\t\t}\n\t\t}\n\n\t\tif(!empty($array[$key]))\n\t\t{\n\t\t\treturn $array[$key];\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $default;\n\t\t}\n\t}", "public static function getValue($key, &$arr, $default = NULL)\n\t{\n\t\tif (Helper_Check::isStringEmptyOrNull($key))\n\t\t\treturn ($default !== NULL) ? $default : NULL;\n\t\t\t\n\t\tif (array_key_exists($key, $arr))\n\t\t\treturn $arr[$key];\n\t\t\t\n\t\treturn !Helper_Check::isNull($default) ? $default : NULL;\n\t}", "function val(array $array, $key) {\r\n\treturn array_key_exists($key, $array) ? $array[$key] : null;\r\n}", "protected static function val($key, $array, $default = null) {\n if (is_array($array)) {\n // isset() is a micro-optimization - it is fast but fails for null values.\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n // Comparing $default is also a micro-optimization.\n if ($default === null || array_key_exists($key, $array)) {\n return null;\n }\n } elseif (is_object($array)) {\n if (isset($array->$key)) {\n return $array->$key;\n }\n\n if ($default === null || property_exists($array, $key)) {\n return null;\n }\n }\n\n return $default;\n }", "function data_get($target, $key, $default = null)\n {\n if (is_null($key)) {\n return $target;\n }\n\n $key = is_array($key) ? $key : explode('.', $key);\n\n while (!is_null($segment = array_shift($key))) {\n if ($segment === '*') {\n if (!is_array($target)) {\n return value($default);\n }\n\n $result = [];\n\n foreach ($target as $item) {\n $result[] = data_get($item, $key);\n }\n\n return in_array('*', $key) ? PhandArr::flatten($result) : $result;\n }\n\n if (PhandArr::accessible($target) && PhandArr::exists($target, $segment)) {\n $target = $target[$segment];\n } elseif (is_object($target) && isset($target->{$segment})) {\n $target = $target->{$segment};\n } else {\n return value($default);\n }\n }\n\n return $target;\n }", "function getItem($key, $array, $default=null) {\n\t\tif (array_key_exists($key, $array)) {\n\t\t\treturn $array[$key];\n\t\t} else {\n\t\t\tif (func_num_args() === 3) {\n\t\t\t\treturn $default;\n\t\t\t} else {\n\t\t\t\tthrow Exception('Unable to find key '.$key.' in the array '.var_dump($array, true));\n\t\t\t}\n\t\t}\n\t}", "function data_get($target, $key, $default = null)\n {\n if (is_null($key)) {\n return $target;\n }\n\n $key = is_array($key) ? $key : explode('.', $key);\n\n while (!is_null($segment = array_shift($key))) {\n if ($segment === '*') {\n if ($target instanceof Collection) {\n $target = $target->all();\n } elseif (!is_array($target)) {\n return value($default);\n }\n\n $result = Arr::pluck($target, $key);\n\n return in_array('*', $key) ? Arr::collapse($result) : $result;\n }\n\n if (Arr::accessible($target) && Arr::exists($target, $segment)) {\n $target = $target[$segment];\n } elseif (is_object($target) && isset($target->{$segment})) {\n $target = $target->{$segment};\n } else {\n return value($default);\n }\n }\n\n return $target;\n }", "protected function getArrValue(array $array, $key, $default = null)\n {\n if (is_null($key)) {\n return $default;\n }\n\n if (isset($array[$key])) {\n return $array[$key];\n }\n\n return $default;\n }", "private static function getKey($key, array &$arr, $default=null)\r\n {\r\n return (array_key_exists($key, $arr)?$arr[$key]:$default);\r\n }", "public function get($key, $default = null)\n {\n return DotArr::get($this->data, $key, $default);\n }", "function _wp_array_get($input_array, $path, $default_value = \\null)\n {\n }", "function value(array $array, int|string $key = null, mixed $default = null): mixed\n{\n if (func_num_args() > 1) {\n return $array[$key] ?? $default;\n }\n return $array ? current($array) : null; // No falses.\n}", "function GetEntry($arr, $key, $default = NULL)\n{\n return array_key_exists($key, $arr) ? $arr[$key] : $default;\n}", "function atkArrayNvl($array, $key, $defaultvalue=null)\n{\n\treturn (isset($array[$key]) ? $array[$key] : $defaultvalue);\n}", "public function get(string $key = null, $default = null)\n {\n if(!is_string($key)) {\n return $this->configs;\n }\n\n $keys = explode('.', $key);\n $configs = $this->configs;\n\n foreach ($keys as $key) {\n if (!is_array($configs) || !isset($configs[$key])) {\n return $default;\n }\n\n $configs = &$configs[$key];\n }\n\n return $configs;\n }", "function data_get($target, $key, $default = null)\n {\n if (is_null($key)) {\n return $target;\n }\n\n $key = is_array($key) ? $key : explode('.', is_int($key) ? (string) $key : $key);\n while (!is_null($segment = array_shift($key))) {\n if ('*' === $segment) {\n if ($target instanceof Collection) {\n $target = $target->all();\n } elseif (!is_array($target)) {\n return value($default);\n }\n $result = [];\n foreach ($target as $item) {\n $result[] = data_get($item, $key);\n }\n\n return in_array('*', $key) ? Arr::collapse($result) : $result;\n }\n if (Arr::accessible($target) && Arr::exists($target, $segment)) {\n $target = $target[$segment];\n } elseif (is_object($target) && isset($target->{$segment})) {\n $target = $target->{$segment};\n } else {\n return value($default);\n }\n }\n\n return $target;\n }", "function get($arr, $key, $def = null) {\n\tif(isset($arr[$key]) && !empty($arr[$key])) {\n\t\treturn $arr[$key];\n\t}\n\t\n\treturn $def;\n}", "public function get($key, $default = null)\n {\n if(!isset($this->item[$item = explode('.', $key)[0]])){\n $this->add($item);\n }\n return data_get($this->item, $key, $default);\n }", "static function from(array $arr, $key, $default = null, $one = true) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n $grep = preg_grep('/^('.preg_quote($key, '/').')$/i', array_keys($array));\n $ret = array_intersect_key($arr, array_flip($grep));\n\n return empty($ret) ? $default : ($one ? end($ret) : $ret);\n }", "private static function resolveByDotNotation( array $array, $path, $default = null ) {\n\t\t$current = $array;\n\t\t$p = strtok( $path, '.' );\n\n\t\twhile ( $p !== false ) {\n\t\t\tif ( ! isset( $current[ $p ] ) ) {\n\t\t\t\treturn $default;\n\t\t\t}\n\t\t\t$current = $current[ $p ];\n\t\t\t$p = strtok( '.' );\n\t\t}\n\n\t\treturn $current;\n\t}", "public function get($key = null)\n {\n if (empty($key)) {\n return $this->config;\n }\n // if no dot notation is used, return first dimension value or empty string\n if (strpos($key, '.') === false) {\n return $this->config[$key] ?? null;\n }\n\n // if dot notation is used, traverse config string\n $segments = explode('.', $key);\n $subArray = $this->config;\n foreach ($segments as $segment) {\n if (isset($subArray[$segment])) {\n $subArray = &$subArray[$segment];\n } else {\n return null;\n }\n }\n\n return $subArray;\n }", "function array_get($key, $array)\n {\n return arr::get($key, $array);\n }", "private function ine($key, $arr, $default = null)\n {\n return isset($arr[$key]) ? $arr[$key] : $default;\n }", "public function get(string $key, mixed $default = null): mixed\n {\n $data = $this->arrayify();\n\n return array_get($data, $key, $default);\n }", "function array_val_json(array $array, $key, $default = array()) { \n\t// get the value out of the array if it exists\n\tif( $value = array_val($array, $key) ){\n\t\t$arr = json_decode($value, 1);\n\t\t// if it didnt fail, return it\n\t\tif( $arr !== false ){\n\t\t\t// json decode succeded, return the result\n\t\t\treturn $arr;\n\t\t}\n\t}\n\t// return the default\n\treturn $default; \n}", "function asdb_data_get($target, $key, $default = null)\n\t{\n\t\tif (is_null($key)) {\n\t\t\treturn $target;\n\t\t}\n\n\t\t$key = is_array($key) ? $key : explode('.', $key);\n\n\t\tforeach ($key as $i => $segment) {\n\t\t\tunset($key[$i]);\n\n\t\t\tif (is_null($segment)) {\n\t\t\t\treturn $target;\n\t\t\t}\n\n\t\t\tif ($segment === '*') {\n\t\t\t\tif ($target instanceof Collection) {\n\t\t\t\t\t$target = $target->all();\n\t\t\t\t} elseif (! is_array($target)) {\n\t\t\t\t\treturn asdb_value($default);\n\t\t\t\t}\n\n\t\t\t\t$result = [];\n\n\t\t\t\tforeach ($target as $item) {\n\t\t\t\t\t$result[] = asdb_data_get($item, $key);\n\t\t\t\t}\n\n\t\t\t\treturn in_array('*', $key) ? Arr::collapse($result) : $result;\n\t\t\t}\n\n\t\t\tif (Arr::accessible($target) && Arr::exists($target, $segment)) {\n\t\t\t\t$target = $target[$segment];\n\t\t\t} elseif (is_object($target) && isset($target->{$segment})) {\n\t\t\t\t$target = $target->{$segment};\n\t\t\t} else {\n\t\t\t\treturn asdb_value($default);\n\t\t\t}\n\t\t}\n\n\t\treturn $target;\n\t}", "private function _get_array_value($array, $key)\r\n {\r\n if(array_key_exists($key, $array))\r\n {\r\n return $array[$key];\r\n }\r\n return NULL;\r\n }", "function fnGet(&$array, $key, $default = null, $separator = '/')\n{\n if (($sub_key_pos = strpos($key, $separator)) === false) {\n if (is_object($array)) {\n return property_exists($array, $key) ? $array->$key : $default;\n }\n return isset($array[$key]) ? $array[$key] : $default;\n } else {\n $first_key = substr($key, 0, $sub_key_pos);\n if (is_object($array)) {\n $tmp = property_exists($array, $first_key) ? $array->$first_key : null;\n } else {\n $tmp = isset($array[$first_key]) ? $array[$first_key] : null;\n }\n return fnGet($tmp, substr($key, $sub_key_pos + 1), $default, $separator);\n }\n}", "public static function getValue($array, $key)\n\t{\n\t\t$keys = explode(\"->\", $key);\n\t\tforeach ($keys as $k) {\n\t\t\tif (is_array($array) && isset($array[$k])) {\n\t\t\t\t$array = $array[$k];\n\t\t\t} else if (is_object($array) && property_exists($array, $k)) {\n\t\t\t\t$array = $array->$k;\n\t\t\t} else {\n\t\t\t\t$array = null;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn $array;\n\t}", "public static function get($key, $default = null) {\n $segments = explode('.', $key);\n\n // Check to see if the value is already loaded.\n $value = static::lookup($segments);\n if ($value !== null) return $value;\n\n if (count($segments) < 3) return $default;\n\n // Attempt a 'lazy load' if the key has at least 3 segments.\n if (!static::load($segments)) return $default;\n\n // Recheck for the setting.\n $value = static::lookup($segments);\n return $value !== null ? $value : $default;\n }", "function array_path($array, $path, $default = null) {\n $path = explode('.', $path);\n while ($key = array_shift($path)) {\n if (!isset($array[$key])) return $default;\n $array = $array[$key];\n }\n return $array;\n}", "public function valueFromArray( $key )\n\t{\n\t\t$array = $this->data;\n\t\t\n\t\twhile ( $pos = mb_strpos( $key, '[' ) )\n\t\t{\n\t\t\tpreg_match( '/^(.+?)\\[([^\\]]+?)?\\](.*)?$/', $key, $matches );\n\t\t\t\n\t\t\tif ( !array_key_exists( $matches[1], $array ) )\n\t\t\t{\n\t\t\t\treturn NULL;\n\t\t\t}\n\t\t\t\t\n\t\t\t$array = $array[ $matches[1] ];\n\t\t\t$key = $matches[2] . $matches[3];\n\t\t}\n\t\t\n\t\tif ( !isset( $array[ $key ] ) )\n\t\t{\n\t\t\treturn NULL;\n\t\t}\n\t\t\t\t\n\t\treturn $array[ $key ];\n\t}", "public static function getValueByKey($config, $key, $default = null) {\n\t\tif (empty($config)) {\n\t\t\treturn $default;\n\t\t}\n\t\tif (!is_array($config)) {\n\t\t\t$config = $config->toArray();\n\t\t}\n\n\t\t$keys = explode('.', $key, 2);\n\t\tif (!isset($keys[1])) {\n\t\t\treturn $config[$keys[0]];\n\t\t}\n\t\tif ( !is_array($config[$keys[0]]) ) {\n\t\t\treturn $default;\n\t\t}\n\n\t\treturn static::getValueByKey($config[$keys[0]], $keys[1], $default);\n\t}", "public function get($key, $default = []);", "function get($key, $default = null)\n{\n if (is_array($key)) {\n foreach ($key as $val) {\n if (isset($_GET[$val])) {\n return $_GET[$val];\n }\n }\n } elseif (isset($_GET[$key])) {\n return $_GET[$key];\n }\n return $default;\n}", "function array_get($arr, $key, $notfound = ''){\r\n\tif (!isset($arr[$key])){\r\n\t\treturn $notfound;\r\n\t}\r\n\treturn $arr[$key];\r\n}", "public static function getArrayElement(array $array, $key, $defaultValue = null) {\n if (array_key_exists($key, $array)) {\n return $array[$key];\n }\n\n return $defaultValue;\n }", "public function array_get(array $array, string $option)\n {\n return array_key_exists($option, $array) ? $array[$option] : null;\n }", "function orEq($array,$key,$default = null) {\n if ( $default === null ) {\n $default = __('UnNamed', $this->getPluginName() ) . ' - ' . $key;\n }\n if ( isset($array[$key]) ) {\n return $array[$key];\n }\n return $default;\n }", "public function get($key, $default = null)\n {\n if (isset($this->parameters[$key])) {\n return $this->parameters[$key];\n }\n\n $data = $this->parameters;\n\n foreach (explode('.', $key) as $pkey) {\n if (!array_key_exists($pkey, $data) || !is_array($data)) {\n return $default;\n }\n\n $data = $data[$pkey];\n }\n\n return $data;\n\n $this->has($key) ? $this->parameters[$key] : $default;\n }", "function frame_dot_array(array $a, $path, $default = null)\n{\n $current = $a;\n $p = strtok($path, '.');\n\n while ($p !== false)\n {\n if (!isset($current[$p]))\n return $default;\n\n $current = $current[$p];\n $p = strtok('.');\n }\n\n return $current;\n}", "private function getArrayValue(array &$array, string $key, $defaultValue = null)\n {\n if (!array_key_exists($key, $array)) {\n return $defaultValue;\n }\n\n return $array[$key];\n }", "public static function array_get(ArrayValue $arr, Value $key, Value $default = null): Value {\n\t\tCommon::allowTypes($key, StringValue::class, NumberValue::class);\n\t\treturn $arr->value[$key->value] ?? $default ?? new NullValue;\n\n\t}", "function array_get_in($array, array $path, $default = null)\n{\n if (empty($path)) {\n return $array;\n }\n\n $head = array_shift($path);\n\n if (!is_array($array) || !array_key_exists($head, $array)) {\n return $default;\n }\n\n return array_get_in($array[$head], $path, $default);\n}", "public function &get(string $key = null, mixed $default = null): mixed\n {\n if (is_null($key)) {\n return $this->data;\n }\n\n $data = &$this->data;\n\n foreach (explode($this->delimiter, $key) as $segment) {\n if (! is_array($data) || ! isset($data[$segment])) {\n return $default;\n }\n\n $data = &$data[$segment];\n }\n\n return $data;\n }", "public static function getValueByBestMatchingKey(array $config, $key) {\n\t\t$keys = explode('.', $key, 2);\n\n\t\tif (!isset($config[$keys[0]])) {\n\t\t\treturn $config;\n\t\t}\n\n\t\tif ( !is_array($config[$keys[0]]) ) {\n\t\t\treturn $config;\n\t\t}\n\n\t\tif (!isset($keys[1])) {\n\t\t\treturn $config[$keys[0]];\n\t\t}\n\n\t\treturn static::getValueByBestMatchingKey($config[$keys[0]], $keys[1]);\n\t}", "public function get(string $key, $default = null)\n {\n return array_get($this->raw, $key, $default);\n }", "public function find(string $key)\n {\n if (!preg_match('/^[\\w\\-]+(\\.[\\w\\-]+)+$/i', $key)) {\n return $this->get($key);\n }\n\n $tokens = explode(\".\", $key);\n $arr = $this->get($tokens[0]);\n array_shift($tokens);\n\n if (!is_array($arr)) {\n return null;\n }\n\n $deep = array_map(function ($prop) {\n return sprintf('[\"%s\"]', $prop);\n }, $tokens);\n\n $eval = \"return \\$arr\" . implode($deep) . \" ?? null;\";\n return eval($eval);\n }", "public function &getValue(array &$array, $default = null)\n\t{\n\t\treturn AgaviArrayPathDefinition::getValue($this->parts, $array, $default);\n\t}" ]
[ "0.8462378", "0.84363115", "0.84254086", "0.84203297", "0.8412444", "0.8391115", "0.83387995", "0.82678616", "0.82395273", "0.8232309", "0.815754", "0.81545687", "0.8091742", "0.80785656", "0.8069392", "0.80082476", "0.79918724", "0.78972375", "0.7894346", "0.77387637", "0.7671128", "0.76474506", "0.75903773", "0.75727654", "0.7550941", "0.7550941", "0.7550941", "0.74782264", "0.74761355", "0.7451328", "0.74326104", "0.74267155", "0.74189824", "0.74015003", "0.7365912", "0.73587894", "0.73065215", "0.72950387", "0.7264172", "0.72615314", "0.72607005", "0.72380275", "0.7228002", "0.7206514", "0.7148386", "0.71052027", "0.7049585", "0.704902", "0.704433", "0.7011126", "0.6991883", "0.6912526", "0.6908426", "0.68743503", "0.6872109", "0.68241763", "0.68178934", "0.680067", "0.6799134", "0.67959917", "0.67944956", "0.67864186", "0.6762486", "0.6760676", "0.67589635", "0.6680403", "0.66678286", "0.66540956", "0.6650712", "0.6620905", "0.6616438", "0.6615496", "0.6604491", "0.6597114", "0.65901506", "0.65868497", "0.6559678", "0.6539308", "0.6524197", "0.65220416", "0.6521853", "0.651721", "0.6492448", "0.64857274", "0.6477937", "0.64746815", "0.6450621", "0.644903", "0.64400625", "0.6427002", "0.64129376", "0.64108425", "0.63939553", "0.63889116", "0.63875586", "0.63677025", "0.63657206", "0.6352088", "0.63505524", "0.63327706" ]
0.6366631
96
Given an array key in dot notation create and set a value in an array.
public static function setFromString($keys, $value) { $array = $value; foreach (array_reverse(explode('.', $keys)) as $key) { $value = $array; unset($array); $array[$key] = $value; } return $array; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function array_dot_set(array $array, $key, $value) {\n\t$final = $array;\n\tif(strpos($key, '.') === false) {\n\t\t$final[$key] = $value;\n\t\treturn $final;\n\t}\n\n\t$target = &$final;\n\t$keys = explode('.', $key);\n\tforeach($keys as $curKey) {\n\t\tif(!array_key_exists($curKey, $target))\n\t\t\t$target[$curKey] = array();\n\t\t$target = &$target[$curKey];\n\t}\n\t$target = $value;\n\n\treturn $final;\n}", "static function set(array &$array, $key, $value) {\n if (null === $key) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (sizeof($keys) > 1) {\n $key = array_shift($keys);\n\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "function array_set(array &$array, $key, $value) {\n if ($key === null) {\n return null;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n if ( ! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = array();\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "public static function set(&$array, $key, $value = null)\n {\n if (is_null($key))\n {\n return $array = $value;\n }\n \n $keys = explode('.', $key);\n \n while (count($keys) > 1)\n {\n $key = array_shift($keys);\n \n if (!isset($array[$key]) || !is_array($array[$key]))\n {\n $array[$key] = array();\n }\n \n $array = & $array[$key];\n }\n \n $array[array_shift($keys)] = $value;\n \n return $array;\n }", "private static function set_array_value(&$array, $key, $value = null)\n\t{\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1)\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\tif (!array_key_exists($key, $array))\n\t\t\t{\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array =& $array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\t}", "function array_set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1)\n {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[$key]) || ! is_array($array[$key]))\n {\n $array[$key] = array();\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "function array_set(&$array, $key, $value)\n\t{\n\t\tif (is_null($key)) return $array = $value;\n\n\t\t$keys = explode('.', $key);\n\n\t\twhile (count($keys) > 1)\n\t\t{\n\t\t\t$key = array_shift($keys);\n\n\t\t\t// If the key doesn't exist at this depth, we will just create an empty array\n\t\t\t// to hold the next value, allowing us to create the arrays to hold final\n\t\t\t// values at the correct depth. Then we'll keep digging into the array.\n\t\t\tif ( ! isset($array[$key]) || ! is_array($array[$key]))\n\t\t\t{\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array =& $array[$key];\n\t\t}\n\n\t\t$array[array_shift($keys)] = $value;\n\n\t\treturn $array;\n\t}", "protected function _set(array &$array, $key, $value)\n {\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n }", "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) return $array = $value;\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1)\n {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[$key]) || ! is_array($array[$key]))\n {\n $array[$key] = [];\n }\n\n $array =& $array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "public static function set(&$array, $key, $value)\n {\n if ( is_null($key) )\n {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while ( count($keys) > 1 )\n {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( ! isset($array[ $key ]) || ! is_array($array[ $key ]) )\n {\n $array[ $key ] = [ ];\n }\n\n $array =& $array[ $key ];\n }\n\n $array[ array_shift($keys) ] = $value;\n\n return $array;\n }", "public static function set(&$array, $key, $value)\n {\n if ( is_null($key) ) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while ( count($keys) > 1 ) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if ( !isset($array[ $key ]) or !is_array($array[ $key ]) ) {\n $array[ $key ] = [ ];\n }\n\n $array =& $array[ $key ];\n }\n\n $array[ array_shift($keys) ] = $value;\n\n return $array;\n }", "public static function set(array &$array, string $key, mixed $value): void\n {\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n\n $key = array_shift($keys);\n\n /*\n * If the key doesn't exist at this depth, an empty array is created\n * to hold the next value, allowing to create the arrays to hold final\n * values at the correct depth. Then, keep digging into the array.\n */\n\n if (!isset($array[$key]) || !is_array($array[$key])) {\n\n $array[$key] = [];\n\n }\n\n $array = &$array[$key];\n\n }\n\n $array[array_shift($keys)] = $value;\n\n }", "public static function set(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "public function arraySet(&$array, $key, $value)\n {\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n foreach ($keys as $i => $key) {\n if (count($keys) === 1) {\n break;\n }\n\n unset($keys[$i]);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "public function set(string $key, $val, array &$array): void\n {\n $keys = explode('.', $key);\n $context = &$array;\n foreach ($keys as $ikey) {\n $context = &$context[$ikey];\n }\n\n $context = $val;\n }", "public function set(string $key, $value) {\n $parts = explode('.', $key);\n $last = $parts[sizeof($parts) - 1];\n\n $container = $this;\n for($i = 0; $i < sizeof($parts) - 1; ++$i) {\n if (!isset($container[$parts[$i]]))\n $container[$parts[$i]] = [];\n $container = &$container[$parts[$i]];\n }\n $container[$last] = $value;\n }", "public static function setValue(&$array, $key, $value)\n {\n if (is_string($key)) {\n // Iterate path\n $keys = explode('.', $key);\n foreach ($keys as $key) {\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n $array = &$array[$key];\n }\n // Set value to path\n $array = $value;\n } elseif (is_array($key)) {\n // Iterate array of paths and values\n foreach ($key as $k => $v) {\n self::setValue($array, $k, $v);\n }\n }\n }", "protected function arraySet(&$array, $key, $value)\n {\n if (function_exists('array_set')) {\n return array_set($array, $key, $value);\n }\n\n if (is_null($key)) {\n return $array = $value;\n }\n\n $keys = explode('.', $key);\n\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n // If the key doesn't exist at this depth, we will just create an empty array\n // to hold the next value, allowing us to create the arrays to hold final\n // values at the correct depth. Then we'll keep digging into the array.\n if (! isset($array[$key]) || ! is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array[array_shift($keys)] = $value;\n\n return $array;\n }", "protected function setDotNotationKey($key, $value)\n\t{\n\t\t$splitKey = explode('.', $key);\n\t\t$root\t = &$this->data;\n\n\t\twhile ($part = array_shift($splitKey)) \n\t\t{\n\t\t\tif (!isset($root[$part]) AND count($splitKey)) \n\t\t\t{\n\t\t\t\t$root[$part] = [];\n\t\t\t}\n\n\t\t\t$root = &$root[$part];\n\t\t}\n\n\t\t$root = $value;\n\t}", "protected function setArrayDataValue(array &$arrayPointer, $key, $value) {\n\t\t$keys = explode('.', $key);\n\n\t\t// Extract the last key\n\t\t$lastKey = array_pop($keys);\n\n\t\t// Walk/build the array to the specified key\n\t\twhile ($arrayKey = array_shift($keys)) {\n\t\t\tif (!array_key_exists($arrayKey, $arrayPointer)) {\n\t\t\t\t$arrayPointer[$arrayKey] = array();\n\t\t\t}\n\t\t\t$arrayPointer = &$arrayPointer[$arrayKey];\n\t\t}\n\n\t\t// Set the final key\n\t\t$arrayPointer[$lastKey] = $value;\n\t}", "protected function setDotNotationKey($key, $value)\n {\n $splitKey = explode('.', $key);\n $root = &$this->data;\n // Look for the key, creating nested keys if needed\n while ($part = array_shift($splitKey)) {\n if (!isset($root[$part]) && count($splitKey)) {\n $root[$part] = [];\n }\n $root = &$root[$part];\n }\n\n $root = $value;\n }", "public function __set(string $key, array|string|null $value) {\n\tforeach($this->_elArray as $el) {\n\t\t$el->$key = $value;\n\t}\n}", "function array_set($key, $value, &$array)\n {\n return arr::set($key, $value, $array);\n }", "static function set(array &$data, $path, $value) {\n\t\t$keys = explode('.', $path);\n\t\t$last = array_pop($keys);\n\t\tforeach($keys as $k){\n\t\t\tif(isset($data[$k]) && is_array($data[$k])){\n\t\t\t\t$data = & $data[$k];\n\t\t\t}else{\n\t\t\t\t$data[$k] = array();\n\t\t\t\t$data = & $data[$k];\n\t\t\t}\n\t\t}\n\t\t$data[$last] = $value;\n\t}", "function array_set(&$array, $key, $value)\n {\n return Arr::set($array, $key, $value);\n }", "function array_set(&$array, $key, $value)\n {\n return Arr::set($array, $key, $value);\n }", "function array_set(&$array, $key, $value)\n {\n return Arr::set($array, $key, $value);\n }", "public static function set($key, $val) {\n $items = &static::$items;\n\n foreach(explode('.', $key) as $step) {\n $items = &$items[$step];\n }\n\n $items = $val;\n }", "function array_set(&$array, $key, $value)\n {\n return ArrayHelper::set($array, $key, $value);\n }", "function data_set(&$target, $key, $value, $overwrite = true)\n {\n $segments = is_array($key) ? $key : explode('.', $key);\n\n if (($segment = array_shift($segments)) === '*') {\n if (!Arr::accessible($target)) {\n $target = [];\n }\n\n if ($segments) {\n foreach ($target as &$inner) {\n data_set($inner, $segments, $value, $overwrite);\n }\n } elseif ($overwrite) {\n foreach ($target as &$inner) {\n $inner = $value;\n }\n }\n } elseif (Arr::accessible($target)) {\n if ($segments) {\n if (!Arr::exists($target, $segment)) {\n $target[$segment] = [];\n }\n\n data_set($target[$segment], $segments, $value, $overwrite);\n } elseif ($overwrite || !Arr::exists($target, $segment)) {\n $target[$segment] = $value;\n }\n } elseif (is_object($target)) {\n if ($segments) {\n if (!isset($target->{$segment})) {\n $target->{$segment} = [];\n }\n\n data_set($target->{$segment}, $segments, $value, $overwrite);\n } elseif ($overwrite || !isset($target->{$segment})) {\n $target->{$segment} = $value;\n }\n } else {\n $target = [];\n\n if ($segments) {\n data_set($target[$segment], $segments, $value, $overwrite);\n } elseif ($overwrite) {\n $target[$segment] = $value;\n }\n }\n\n return $target;\n }", "function asdb_data_set(&$target, $key, $value, $overwrite = true)\n\t{\n\t\t$segments = is_array($key) ? $key : explode('.', $key);\n\n\t\tif (($segment = array_shift($segments)) === '*') {\n\t\t\tif (! Arr::accessible($target)) {\n\t\t\t\t$target = [];\n\t\t\t}\n\n\t\t\tif ($segments) {\n\t\t\t\tforeach ($target as &$inner) {\n\t\t\t\t\tasdb_data_set($inner, $segments, $value, $overwrite);\n\t\t\t\t}\n\t\t\t} elseif ($overwrite) {\n\t\t\t\tforeach ($target as &$inner) {\n\t\t\t\t\t$inner = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t} elseif (Arr::accessible($target)) {\n\t\t\tif ($segments) {\n\t\t\t\tif (! Arr::exists($target, $segment)) {\n\t\t\t\t\t$target[$segment] = [];\n\t\t\t\t}\n\n\t\t\t\tasdb_data_set($target[$segment], $segments, $value, $overwrite);\n\t\t\t} elseif ($overwrite || ! Arr::exists($target, $segment)) {\n\t\t\t\t$target[$segment] = $value;\n\t\t\t}\n\t\t} elseif (is_object($target)) {\n\t\t\tif ($segments) {\n\t\t\t\tif (! isset($target->{$segment})) {\n\t\t\t\t\t$target->{$segment} = [];\n\t\t\t\t}\n\n\t\t\t\tasdb_data_set($target->{$segment}, $segments, $value, $overwrite);\n\t\t\t} elseif ($overwrite || ! isset($target->{$segment})) {\n\t\t\t\t$target->{$segment} = $value;\n\t\t\t}\n\t\t} else {\n\t\t\t$target = [];\n\n\t\t\tif ($segments) {\n\t\t\t\tasdb_data_set($target[$segment], $segments, $value, $overwrite);\n\t\t\t} elseif ($overwrite) {\n\t\t\t\t$target[$segment] = $value;\n\t\t\t}\n\t\t}\n\n\t\treturn $target;\n\t}", "public static function set(array &$array, string $keys, $value = null, string $separator = '.'): void\n {\n $keys = explode($separator, $keys);\n\n foreach ($keys as $key) {\n $array = &$array[$key];\n }\n\n $array = $value;\n }", "public static function setPath( & $array, $keys, $value )\n\t{\n\t\twhile ( count( $keys ) > 1 ) {\n\t\t\t$key = array_shift( $keys );\n\n\t\t\tif ( ctype_digit( $key ) ) {\n\t\t\t\t// Make the key an integer\n\t\t\t\t$key = (int)$key;\n\t\t\t}\n\n\t\t\tif ( !isset( $array[$key] ) ) {\n\t\t\t\t$array[$key] = array();\n\t\t\t}\n\n\t\t\t$array = & $array[$key];\n\t\t}\n\n\t\t// Set key on inner-most array\n\t\t$array[array_shift( $keys )] = $value;\n\t}", "public static function set(&$array, $keys, $value = null)\n {\n if (is_null($keys)) {\n return $array = $value;\n }\n\n if (is_array($keys)) {\n foreach ($keys as $key => $value) {\n self::set($array, $key, $value);\n }\n }\n\n foreach (explode('.', $keys) as $key) {\n if (!isset($array[$key]) || !is_array($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n $array = $value;\n\n return true;\n }", "public function set($key, $value = null)\n {\n DotArr::set($this->data, $key, $value);\n }", "public function array_set(&$array, $key, $value)\n {\n return Arr::set($array, $key, $value);\n }", "public function offsetSet( $key, $value );", "function array_dot_get(array $array, $key) {\n\tif(strpos($key, '.') === false)\n\t\treturn $array[$key];\n\n\t$target = &$array;\n\t$keys = explode('.', $key);\n\tforeach($keys as $curKey) {\n\t\tif(!array_key_exists($curKey, $target))\n\t\t\treturn null;\n\t\t$target = &$target[$curKey];\n\t}\n\n\treturn $target;\n}", "function _wp_array_set(&$input_array, $path, $value = \\null)\n {\n }", "public function set( $key, $value = null )\n\t{\n\t\tif ( is_array( $key ) )\n\t\t\tforeach ( $key as $innerKey => $innerValue )\n\t\t\t\tArr::set( $this->items, $innerKey, $innerValue );\n\t\telse\n\t\t\tArr::set( $this->items, $key, $value );\n\t}", "public function add(string $key, $val, array &$array): void\n {\n $keys = explode('.', $key);\n $context = &$array;\n foreach ($keys as $ikey) {\n $context = &$context[$ikey];\n }\n\n if (empty($context)) {\n $context = $val;\n return;\n }\n\n if (!is_array($context)) {\n $context = [$context];\n }\n\n if (!is_array($val)) {\n $val = [$val];\n }\n\n $context = array_merge($context, $val);\n }", "function offsetSet($key, $value)\n\t{\n\t\t$this->fields[$key] = $value;\n\t}", "public function offsetSet($key, $value): void\n {\n if (is_array($this->_data)) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } elseif ($this->_data instanceof \\ArrayAccess) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } else {\n throw new \\Exception('Cannot use object of type ' . get_class($this->_data) . ' as array');\n }\n }", "public function offsetSet($key, $value) {}", "public function offsetSet($key, $value)\n\t{\n\t\t$this->setAttribute($key, $value);\n\t}", "public function offsetSet($key, $value)\n {\n $this->attributes->put($key, $value);\n }", "public function data_set(&$target, $key, $value, $overwrite = true)\n {\n $segments = is_array($key) ? $key : explode('.', $key);\n\n if (($segment = array_shift($segments)) === '*') {\n if (! Arr::accessible($target)) {\n $target = [];\n }\n\n if ($segments) {\n foreach ($target as &$inner) {\n $this->data_set($inner, $segments, $value, $overwrite);\n }\n } elseif ($overwrite) {\n foreach ($target as &$inner) {\n $inner = $value;\n }\n }\n } elseif (Arr::accessible($target)) {\n if ($segments) {\n if (! Arr::exists($target, $segment)) {\n $target[$segment] = [];\n }\n\n $this->data_set($target[$segment], $segments, $value, $overwrite);\n } elseif ($overwrite || ! Arr::exists($target, $segment)) {\n $target[$segment] = $value;\n }\n } elseif (is_object($target)) {\n if ($segments) {\n if (! isset($target->{$segment})) {\n $target->{$segment} = [];\n }\n\n $this->data_set($target->{$segment}, $segments, $value, $overwrite);\n } elseif ($overwrite || ! isset($target->{$segment})) {\n $target->{$segment} = $value;\n }\n } else {\n $target = [];\n\n if ($segments) {\n $this->data_set($target[$segment], $segments, $value, $overwrite);\n } elseif ($overwrite) {\n $target[$segment] = $value;\n }\n }\n\n return $target;\n }", "#[\\ReturnTypeWillChange]\n public function offsetSet($key, $value)\n {\n if (is_null($key)) {\n $this->data[] = $value;\n } else {\n $this->data[$key] = $value;\n }\n }", "public function offsetSet($key, $value)\n {\n if (is_null($key)) {\n $this->attributes[] = $value;\n } else {\n $this->attributes[$key] = $value;\n }\n }", "public function get(string $key, array $array)\n {\n $keys = explode('.', $key);\n\n foreach ($keys as $ikey) {\n $array = $array[$ikey];\n }\n\n return $array;\n }", "public function setValue(array &$array, $value)\n\t{\n\t\tAgaviArrayPathDefinition::setValue($this->parts, $array, $value);\n\t}", "public function set($key, $value)\n {\n $keys = explode('.', $key);\n\n $data = &$this->parameters;\n\n while (count($keys) > 1) {\n $pkey = $keys[0];\n\n if (!array_key_exists($pkey, $data) || !is_array($data[$pkey])) {\n $data[$pkey] = [];\n }\n\n $data = &$data[$pkey];\n array_shift($keys);\n }\n\n $data[$keys[0]] = $value;\n\n return $this;\n }", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "public function updateData($key, $value) {\n $meta = $this->getData();\n $keys = explode('.', $key);\n $p = &$meta;\n foreach ($keys as $key) {\n if (!isset($p[$key])) {\n $p[$key] = array();\n }\n $p = &$p[$key];\n }\n $p = $value;\n $this->setData(json_encode($meta));\n }", "public function setArray(string $key, array $value, int $ttl = 0): bool;", "public static function setToArrayByKey(string $key, $value, array &$data, string $delimiter = '.'): void\n {\n if ($delimiter === '') {\n throw new InvalidArgumentException(\"Delimiter can't be empty string\");\n }\n $keys = explode($delimiter, $key);\n self::setArrayValueByKeys($keys, $value, $data);\n }", "private function set_if_not_null( $key, $value, &$array )\n {\n if ( $value !== null ) {\n $array[ $key ] = $value;\n }\n }", "public static function set( $key, $value = null )\n\t{\n\t\tif ( is_array( $key ) )\n\t\t{\n\t\t\tforeach ( $key as $name => $value )\n\t\t\t{\n\t\t\t\tself::set( $name, $value );\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tself::$container[ $key ] = $value;\n\t\t}\n\t}", "public function offsetSet( $key, $value )\n\t{\n\t\t$this->set( $key, $value );\n\t}", "public function offsetSet($key,$value){\n if(!array_key_exists($key,$this->definition)){\n throw new \\Disco\\exceptions\\Exception(\"Field `{$key}` is not defined by this data model\");\n }//if\n $this->data[$key] = $value;\n }", "public function offsetSet($key, $value) {\n\t\tif ($key === null) {\n\t\t\t$this->append($value);\n\t\t} else {\n\t\t\t$this->set($key, $value);\n\t\t}\n\t}", "function array_add(array &$array, $key, $value) {\n $target = array_get($array, $key, array());\n\n if ( ! is_array($target)) {\n $target = array($target);\n }\n\n $target[] = $value;\n array_set($array, $key, $target);\n\n return $array;\n }", "public function offsetSet($key, $value)\n\t{\n\t\t$this->updating();\n\t\t$this->array[$key] = $value;\n\t\treturn $this;\n\t}", "public function set( $key, $value = null ) {\n\t\tif ( ! is_array( $key ) ) {\n\t\t\treturn $this->$key = $value;\n\t\t}\n\t\tforeach ( $key as $k => $value ) {\n\t\t\t$this->$k = $value;\n\t\t}\n\t}", "public static function set_nested_array_value(&$array, $path, $value, $delimiter = '/') {\r\n $pathParts = explode($delimiter, $path);\r\n\r\n $current = &$array;\r\n foreach ($pathParts as $key) {\r\n if(!is_array($current)){\r\n $current = [];\r\n }\r\n if(!isset($current[$key])){\r\n $current[$key] = [];\r\n }\r\n $current = &$current[$key];\r\n }\r\n\r\n $backup = $current;\r\n $current = $value;\r\n\r\n return $backup;\r\n }", "public function offsetSet($key, $value)\n {\n $this->data[$key] = $value;\n }", "public function offsetSet($key, $value)\n {\n $this->data[$key] = $value;\n }", "public function offsetSet($key, $value) {\n $this->setDatapoint($key, $value);\n }", "public function offsetSet($key,$value) {\n\t\t$this->sets[$key] = $value;\n\t}", "public function offsetSet($key, $value) {\n\t\t$this->set($key, $value);\n\t}", "function setGameStateValueFromArray($key, $array) {\n $encoded_value = 0;\n foreach($array as $value) {\n $encoded_value += pow(2, $value);\n }\n self::setGameStateValue($key, $encoded_value);\n }", "public function offsetSet($key, $value)\n {\n $this->setData($key, $value);\n }", "function setValues($array){\r\n\t\tforeach($array as $key => $val)\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t}", "public static function set($slug, $key, $value)\n {\n if (empty($key)) {\n self::$dynamicConfig[$slug] = $value;\n return;\n }\n // if no dot notation is used, replace first dimension value or empty string\n if (strpos($key, '.') === false) {\n self::$dynamicConfig[$slug][$key] = $value;\n return;\n }\n\n // if dot notation is used, traverse config and replace at the right depth\n $segments = explode('.', $key);\n $subArray = &self::$dynamicConfig[$slug];\n foreach ($segments as $i => $segment) {\n if (isset($subArray[$segment])) {\n if ($i === count($segments) - 1) {\n $subArray[$segment] = $value;\n } else {\n $subArray = &$subArray[$segment];\n }\n } else {\n return;\n }\n }\n }", "public function assignArrayByPath(&$arr, $path, $value, $separator='.') {\n $keys = explode($separator, $path);\n\n foreach ($keys as $key) {\n $arr = &$arr[$key];\n }\n\n $arr = $value;\n }", "public function offsetSet($key, $value)\n {\n if (is_array($this->resource) or $this->resource instanceof \\ArrayAccess) {\n\n if (is_null($key)) {\n\n $this->resource[] = $value;\n } else {\n\n $this->resource[$key] = $value;\n }\n } elseif (is_object($this->resource) and\n (property_exists($this->resource, $key) or isset($this->resource->{$key}))\n ) {\n\n $this->resource->{$key} = $value;\n }\n }", "public function extension(string $key, array $value);", "function explosion(&$value,$key){\n $value = explode('.',$value);\n}", "function set(array $array){\n foreach($this as $atributo => $valor){\n if(isset($array[$atributo])){\n $this->$atributo = $array[$atributo];\n }\n }\n }", "public static function setPath(array & $array, $path, $value, ?string $delimiter = NULL): void\n {\n if (!$delimiter) {\n // Use the default delimiter\n $delimiter = static::$delimiter;\n }\n\n // The path has already been separated into keys\n $keys = $path;\n if (!is_array($path)) {\n // Split the keys by delimiter\n $keys = explode($delimiter, $path);\n }\n\n // Set current $array to inner-most array path\n while (count($keys) > 1) {\n $key = array_shift($keys);\n\n if (ctype_digit($key)) {\n // Make the key an integer\n $key = (int)$key;\n }\n\n if (!isset($array[$key])) {\n $array[$key] = [];\n }\n\n $array = &$array[$key];\n }\n\n // Set key on inner-most array\n $array[array_shift($keys)] = $value;\n }", "public function offsetSet($key, $value)\n {\n $this->setArgument($key, $value);\n }", "public function offsetSet($key,$value)\n {\n if( !in_array($key,$this->_allowed_variables) )\n {\n\ttrigger_error('Modification of internal data is deprecated: '.$key,E_USER_NOTICE);\n }\n $this->_data[$key] = $value;\n }", "public function set ($key, $value) {\r\n\t\tif (!in_array($key, self::get_all_keys())) return false;\r\n\t\tif (empty($this->_data[$key])) $this->_data[$key] = array();\r\n\r\n\t\t$this->_data[$key][] = $value;\r\n\t}", "function arrayGet($array, $key, $default = null)\n {\n if ( ! $this->arrayAccessible($array) ) {\n return $this->value($default);\n }\n if ( is_null($key) ) {\n return $array;\n }\n if ( $this->arrayExists($array, $key) ) {\n return $array[$key];\n }\n if ( strpos($key, '.') === false ) {\n return $array[$key] ?? $this->value($default);\n }\n foreach ( explode('.', $key) as $segment ) {\n if ( $this->arrayAccessible($array) && $this->arrayExists($array, $segment) ) {\n $array = $array[$segment];\n } else {\n return $this->value($default);\n }\n }\n return $array;\n }", "function assign($key, $value = null) \n\t{\n\t\tif (is_array($key)) \n\t\t{\n\t\t\tforeach ($key as $k => $v) \n\t\t\t{\n\t\t\t\t$this->data[$k] = $v;\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->data[$key] = $value;\n\t\t}\n\t}", "#[\\ReturnTypeWillChange]\n public function offsetSet($key, $value)\n {\n $this->with($key, $value);\n }", "public function offsetSet($key, $value)\n {\n if (is_null($key)) {\n $this->items[] = $value;\n } else {\n $this->items[$key] = $value;\n }\n }", "public function offsetSet($key, $value)\n {\n if (is_null($key)) {\n $this->items[] = $value;\n } else {\n $this->items[$key] = $value;\n }\n }", "public function offsetSet($key, $value)\n\t{\n\t\tthrow new \\RuntimeException('Unsupported operation');\n\t}", "public function offsetSet($key, $value)\r\n {\r\n $this->set($key, $value);\r\n }", "public function offsetSet($key, $value)\n {\n $this->propertySet($key, $value);\n }", "function setValueByPath($arr,$path,$value,$createPath=false) {\n\t\tif ($createPath)\n\t\t\t$r=&$arr;\n\t\telse\t\n\t\t\t$r=$arr;\n\t\tif (!is_array($path)) return false;\n\t\tforeach ($path as $key) {\n\t\t\tif ($createPath and !isset($r[$key])) {\n\t\t\t\t$r[$key]='';\n\t\t\t}\n\t\t\tif (isset($r[$key])) {\n\t\t\t\t$r=&$r[$key];\n\t\t\t} else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t\t$r=$value;\n\t\t\n\t\treturn $r;\n\t}", "public function SetArray(string $key, array $value) : void\r\n\t{\r\n\t\t$this->Set($key, $value);\r\n\t}", "public function set( $key , $value ) {\n\t\teval( '$this->items' . $this->nodelize( $key ) . ' = $value;' );\n\t}", "public static function offsetSet($key, $value){\n //Method inherited from \\Illuminate\\Container\\Container \n \\Illuminate\\Foundation\\Application::offsetSet($key, $value);\n }", "public function setVariable($key, $value, & $data) {\n\n if (strpos($key, $this->scopeGlue) === false) {\n $parts = explode('.', $key);\n } else {\n $parts = explode($this->scopeGlue, $key);\n }\n\n $i = 0;\n $count = count($parts);\n $d = & $data;\n\n while ($i < $count) {\n\n $key_part = $parts[$i];\n $key_part_int = filter_var($key_part, FILTER_VALIDATE_INT);\n $key_part_is_int = $key_part_int !== false;\n $set_value = ($i + 1) == $count;\n\n if ($key_part_is_int && is_object($d)) {\n $d = (array) $d;\n }\n\n if (!is_array($d) && !is_object($d)) {\n $d = array();\n }\n\n if (is_array($d)) {\n\n if ($key_part_is_int && !array_key_exists($key_part, $d)) {\n $key_part = $key_part_int;\n }\n\n if ($set_value) {\n\n $d[$key_part] = $value;\n\n } else {\n\n if (!isset($d[$key_part])) {\n $d[$key_part] = array();\n }\n\n $d = & $d[$key_part];\n }\n\n } else {\n\n if ($set_value) {\n\n $d->{$key_part} = $value;\n\n } else {\n\n if (!property_exists($d, $key_part)) {\n $d->{$key_part} = array();\n }\n\n $d = & $d->{$key_part};\n }\n }\n\n $i++;\n }\n }", "public static function set($key, $value = null, $overwrite = true) {\n\n\t\tif (null === $key) {\n\t\t\treturn false;\n\t\t}\n\n if (is_array($key)) {\n foreach ($key as $k => $v) {\n static::set($k, $v, $overwrite);\n }\n return true;\n }\n\n if (true === static::has($key) && !$overwrite) {\n return false;\n }\n\n if (false !== strpos($key, '.')) {\n\t\t\t$nodes = explode('.', $key);\n\t\t\t$data =& static::$__registry;\n\t\t\t$nodeCount = count($nodes) - 1;\n\t\t\tfor ($i=0;$i!=$nodeCount;$i++) {\n // Bug caused data to not overwrite if converting from ( any ) -> array\n // and an overwrite is in order\n\t\t\t\tif (isset($data[$nodes[$i]]) && !is_array($data[$nodes[$i]])) {\n\t\t\t\t\t$data[$nodes[$i]] = array();\n\t\t\t\t}\n\t\t\t\t$data =& $data[$nodes[$i]];\n\t\t\t}\n\t\t\t$data[$nodes[$nodeCount]] = $value;\n\t\t\treturn true;\n\t\t} else {\n static::$__registry[$key] = $value;\n }\n\n return true;\n }", "public function setValueByChildPath($path, array &$array, $value)\n\t{\n\t\t$p = $this->pushRetNew($path);\n\n\t\t$p->setValue($array, $value);\n\t}", "function _universal_set($collection, $key, $value) {\n $set_object = function ($object, $key, $value) {\n $newObject = clone $object;\n $newObject->$key = $value;\n return $newObject;\n };\n $set_array = function ($array, $key, $value) {\n $array[$key] = $value;\n return $array;\n };\n $setter = \\__::isObject($collection) ? $set_object : $set_array;\n return call_user_func_array($setter, [$collection, $key, $value]);\n}" ]
[ "0.8314428", "0.8222349", "0.8076294", "0.7984589", "0.7938528", "0.7880754", "0.7862859", "0.78627837", "0.7769822", "0.7750442", "0.7736818", "0.77244383", "0.76899385", "0.7372823", "0.7319988", "0.7312248", "0.7290036", "0.7254796", "0.71436757", "0.6967944", "0.6831733", "0.6685983", "0.66665006", "0.66386825", "0.6582059", "0.6582059", "0.6582059", "0.65610874", "0.65529054", "0.65177506", "0.64956033", "0.646636", "0.63630646", "0.6331626", "0.62685555", "0.6254341", "0.62212265", "0.62095267", "0.61877203", "0.6172104", "0.61284703", "0.6123264", "0.6110597", "0.6069214", "0.6023049", "0.6003207", "0.59838533", "0.5946799", "0.5942299", "0.59383726", "0.5924994", "0.59247583", "0.58875674", "0.58875674", "0.5830507", "0.583046", "0.58288527", "0.58007896", "0.57974756", "0.5782246", "0.57761276", "0.5772701", "0.5760761", "0.575429", "0.5737513", "0.57329905", "0.57286054", "0.57286054", "0.5724727", "0.57190734", "0.5709744", "0.57046926", "0.5702015", "0.57014036", "0.56999624", "0.5689857", "0.56861526", "0.56838447", "0.5679405", "0.567636", "0.567097", "0.56601256", "0.5652252", "0.5646481", "0.56458867", "0.5624009", "0.5619888", "0.5615302", "0.5615302", "0.56097823", "0.5601038", "0.55800426", "0.5576316", "0.5565963", "0.55598027", "0.5558737", "0.5542133", "0.5539291", "0.553747", "0.55364054" ]
0.6114699
42
De we have a debugbar instance
public function testInitIsWorking() { $this->assertNotEmpty(DebugBar::getDebugBar()); // Do we have a logger? /* @var $logger SS_ZendLog */ $logger = SS_Log::get_logger(); $found = false; foreach ($logger->getWriters() as $writer) { if ($writer instanceof DebugBarLogWriter) { $found = true; } } $this->assertTrue($found); // Do we have a db proxy if (method_exists('DB', 'get_conn')) { $conn = DB::get_conn(); } else { $conn = DB::getConn(); } $class = get_class($conn); $this->assertContains($class, ['DebugBarDatabaseNewProxy', 'DebugBarDatabaseProxy']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function __construct()\n {\n $this->debugBar = new StandardDebugBar();\n }", "function debug(): DebugBarWrapper\n{\n global $debug;\n return $debug;\n}", "function debugbar()\n {\n return app(\\Barryvdh\\Debugbar\\LaravelDebugbar::class);\n }", "public function __construct()\n {\n if( app() -> bound( 'debugbar' ) )\n {\n resolve( 'debugbar' ) -> disable();\n }\n }", "public static function enableDebugToolbar()\n {\n try {\n app('debugbar')->enable();\n } catch (BindingResolutionException $e) {\n }\n }", "public function debug();", "public function debug();", "public function isDebug()\n {\n }", "public function disableDebug() {}", "public static function disableDebugToolbar()\n {\n try {\n app('debugbar')->disable();\n } catch (BindingResolutionException $e) {\n }\n }", "public function debug(){\n echo\"<pre><code>\";\n var_dump($this);\n echo \"</code></pre>\";\n }", "function tearDown() {\n Debug::disable();\n Debug::$enable_show = true;\n }", "public function enableDebug() {}", "public function isDebug();", "public function isDebug();", "public function getDebug();", "public function enableDebug();", "public function debug()\n {\n add_settings_field(\n 'debug',\n apply_filters($this->plugin_name . 'label-debug', esc_html__('Debug', $this->plugin_name)),\n [$this->builder, 'checkbox'],\n $this->plugin_name,\n $this->plugin_name . '-library',\n [\n 'description' => 'Enable debug at the bottom of your security.txt file & this page.',\n 'id' => 'debug',\n 'class' => 'hide-when-disabled',\n 'value' => isset($this->options['debug']) ? $this->options['debug'] : false,\n ]\n );\n }", "public function enableDebugMode() {}", "function Debug($bug){\n\tMagratheaDebugger::Instance()->Add($bug);\n}", "public function __debugInfo()\n {}", "public function disableDebug();", "public static function debug_data()\n {\n }", "function debugOn()\n\t{\n\t\t$this->bDebug = true;\n\t}", "public function GetDebugClass ();", "static function create_debug_view() {\n\t\tif(Director::is_cli() || Director::is_ajax()) return new CliDebugView();\n\t\telse return new DebugView();\n\t}", "private function setDebugger()\n {\n $this->client\n ->getEmitter()\n ->attach(new LogSubscriber($this->debugLogger, Formatter::DEBUG));\n }", "protected function __construct()\n {\n $this->fDebug = fDebug::getInstance();\n }", "public function debug(){\n $debug = [\n 'ID' => $this->ID,\n 'slug' => $this->slug,\n 'options' => $this->options,\n 'items' => $this->items,\n ];\n \"<pre>\".var_dump($debug).\"</pre>\";\n }", "public static function debug() : bool\n {\n }", "public function dprint()\n\t{\n\t\tprint_r( $this->debug );\n\t}", "private function dbug() {\n if (!isset($doc_root)) {\n $doc_root = str_replace('\\\\', '/', $_SERVER['DOCUMENT_ROOT']);\n }\n $back = debug_backtrace();\n // you may want not to htmlspecialchars here\n $line = htmlspecialchars($back[0]['line']);\n $file = htmlspecialchars(str_replace(array('\\\\', $doc_root), array('/', ''), $back[0]['file']));\n\n $k = ($back[1]['class'] == 'SQL') ? 3 : 1;\n\n $class = !empty($back[$k]['class']) ? htmlspecialchars($back[$k]['class']) . '::' : '';\n $function = !empty($back[$k]['function']) ? htmlspecialchars($back[$k]['function']) . '() ' : '';\n $args = (count($back[0]['args'] > 0)) ? $back[0]['args'] : $back[0]['object'];\n $args = (count($args) == 1 && $args[0] != '') ? $args[0] : $args;\n\n print '<div style=\"background-color:#eee; width:100%; font-size:11px; font-family: Courier, monospace;\" class=\"myDebug\"><div style=\" font-size:12px; padding:3px; background-color:#ccc\">';\n print \"<b>$class$function =&gt;$file #$line</b></div>\";\n print '<div style=\"padding:5px;\">';\n if (is_array($args) || is_object($args)) {\n print '<pre>';\n print_r($args);\n print '</pre></div>';\n } else {\n print $args . '</div>';\n }\n print '</div>';\n }", "function debugOff()\n\t{\n\t\t$this->bDebug = false;\n\t}", "protected function registerDebugBar(Container $pimple)\n {\n if ($pimple['debug'] && $this->enableToolbar) {\n $pimple->register(new HttpFragmentServiceProvider());\n $pimple->register(\n (new WebProfilerServiceProvider())\n ->setProfilerHostname($pimple['debugging.profiler.hostname']),\n array(\n 'profiler.cache_dir' => $pimple['config']->get('core.profiler.cache_dir'),\n 'profiler.mount_prefix' => '/_profiler',\n )\n );\n } else {\n //\n // Without the debugbar we need to manually register a stopwatch.\n //\n $pimple['stopwatch'] = function () {\n return new Stopwatch();\n };\n }\n }", "public function hookDebug()\n\t{\n\t\treturn print_r($this, 1);\n\t}", "function debug($status = array())\n {\n $this->debug = $status;\n }", "public static function debugTrail() {}", "function debug(){\n\t\t$this->pwd=\"\";\n\t\t$this->usuario=\"\";\n\t\t$this->servidor=\"\";\n\t\techo \"<pre>\";\n\t\tprint_r($this);\n\t\techo \"</pre>\";\n\t}", "static function endshow($val) {\n\t\tif(!Director::isLive()) {\n\t\t\t$caller = Debug::caller();\n\t\t\techo \"<hr>\\n<h3>Debug \\n<span style=\\\"font-size: 65%\\\">($caller[class]$caller[type]$caller[function]() \\n<span style=\\\"font-weight:normal\\\">in line</span> $caller[line] \\n<span style=\\\"font-weight:normal\\\">of</span> \" . basename($caller['file']) . \")</span>\\n</h3>\\n\";\n\t\t\techo Debug::text($val);\n\t\t\tdie();\n\t\t}\n\t}", "public function debug()\n {\n return $this -> debug;\n }", "static public function main() \n\t{\n\t\tif(self::$mainInstance == null) self::$mainInstance = new Debug(\"main\");\n\t\treturn self::$mainInstance;\n\t}", "public function getDebugInfo()\n {\n // TODO: Implement getDebugInfo() method.\n }", "public function testHiddenBar()\n {\n\n $tracy = new Tracy(['showBar' => false]);\n\n /*\n |------------------------------------------------------------\n | Expectation\n |------------------------------------------------------------\n */\n\n $excepted = 'foo';\n\n /*\n |------------------------------------------------------------\n | Assertion\n |------------------------------------------------------------\n */\n\n $this->assertSame($excepted, $tracy->appendDebugbar($excepted));\n }", "public function debug()\n {\n return $this->container->debug();\n }", "private function action_debug(){\n\t\tvar_dump($this);\n\t}", "function debug($mixed, $title = null , $owner = null)\n\t\t{\n\t\t\t$title = $title != '' ? preg_replace('/:/', '', $title). '::' : '';\n\t\t\t\n\t\t\tprint '<div style=\"border-style:solid;border-color:red;\">';\n\t\t\t\n\t\t\tif ($owner != null)\n\t\t\t{\n\t\t\t\tprint '<strong>' . ucfirst($owner). ' Debug Area</strong>';\n\t\t\t}\n\t\t\tprint '<br /><strong style=\\'color:red\\'>' . ucfirst($title) .'</strong><br />';\n\t\t\tprint '<br /><pre style=margin-left:30px>' . print_r($mixed, true) . '</pre>';\n\t\t\tprint '</div>';\n\t\t}", "public function EnableDebug()\n {\n $this->_debug = true;\n return;\n }", "public static function Instance(){\n\t\tif (self::$inst === null) {\n\t\t\tself::$inst = new MagratheaDebugger();\n\t\t}\n\t\treturn self::$inst;\n\t}", "public function debug()\n {\n echo '<h3>Request Object</h3>';\n echo '<pre>';\n var_dump($this->request);\n echo '</pre>';\n\n echo '<hr/>';\n\n echo '<h3>Request XML</h3>';\n echo '<textarea class=\"widefat\" rows=\"10\">';\n echo htmlentities( $this->service->__getLastRequest() );\n echo '</textarea>';\n\n echo '<hr/>'; \n\n echo '<h3>Response Object</h3>';\n echo '<pre>';\n var_dump($this->response);\n echo '</pre>';\n\n echo '<hr/>';\n\n echo '<h3>Response XML</h3>';\n echo '<textarea class=\"widefat\" rows=\"10\">';\n echo htmlentities( $this->service->__getLastResponse() );\n echo '</textarea>';\n }", "function debug($value)\n {\n $debugbar = debugbar();\n foreach (func_get_args() as $value) {\n $debugbar->addMessage($value, 'debug');\n }\n }", "function dev_debug_display( $thing ) {\n\techo '<pre>';\n\tprint_r( $thing );\n\techo '</pre>';\n}", "public function getDI() {}", "public function getDI() {}", "public function show() {\n\t\t$this->view->show('debug/debug');\n\t}", "function testDebugHighlander() {\n if (is_callable(array('Debug', '__construct'))) {\n $this->fail();\n }\n if (is_callable(array('Debug', '__clone'))) {\n $this->fail();\n }\n $this->pass();\n }", "public static function debug( $data )\n {\n }", "public static function setDebug($debug) {\n\n\t\t// Need to recreate the instace.\n\t\tstatic::$instance = null;\n\t\tstatic::$debug = $debug;\n\t}", "public function enableExtJsDebug() {}", "public function getDebug(){\n\t\treturn $this->_debug;\n\t}", "public function __construct() {\n\t\tif (Configure::read('debug')) {\n\t\t\t$this->components[] = 'DebugKit.Toolbar';\n\t\t}\n\t\tparent::__construct();\n\t}", "function debug($bug)\n{\n echo '<pre style=\"padding: 15px; background: #000; display:block; width: 100%; color: #fff;\">';\n var_dump($bug);\n echo '</pre>';\n}", "function get_debug() {\n // Only if debug is wanted.\n $asf = CAsdf::Instance(); \n if(empty($asf->config['debug'])) {\n return;\n }\n \n // Get the debug output\n $html = null;\n if(isset($asf->config['debug']['db-num-queries']) && $asf->config['debug']['db-num-queries'] && isset($asf->db)) {\n $flash = $asf->session->GetFlash('database_numQueries');\n $flash = $flash ? \"$flash + \" : null;\n $html .= \"<p>Database made $flash\" . $asf->db->GetNumQueries() . \" queries.</p>\";\n } \n if(isset($asf->config['debug']['db-queries']) && $asf->config['debug']['db-queries'] && isset($asf->db)) {\n $flash = $asf->session->GetFlash('database_queries');\n $queries = $asf->db->GetQueries();\n if($flash) {\n $queries = array_merge($flash, $queries);\n }\n $html .= \"<p>Database made the following queries.</p><pre>\" . implode('<br/><br/>', $queries) . \"</pre>\";\n } \n if(isset($asf->config['debug']['timer']) && $asf->config['debug']['timer']) {\n $html .= \"<p>Page was loaded in \" . round(microtime(true) - $asf->timer['first'], 5)*1000 . \" msecs.</p>\";\n } \n if(isset($asf->config['debug']['asdf']) && $asf->config['debug']['asdf']) {\n $html .= \"<hr><h3>Debuginformation</h3><p>The content of CAsdf:</p><pre>\" . htmlent(print_r($asf, true)) . \"</pre>\";\n } \n if(isset($asf->config['debug']['session']) && $asf->config['debug']['session']) {\n $html .= \"<hr><h3>SESSION</h3><p>The content of CAsdf->session:</p><pre>\" . htmlent(print_r($asf->session, true)) . \"</pre>\";\n $html .= \"<p>The content of \\$_SESSION:</p><pre>\" . htmlent(print_r($_SESSION, true)) . \"</pre>\";\n } \n return $html;\n}", "public function isDebug()\n {\n return $this->debug;\n }", "public function isDebug()\n {\n return $this->debug;\n }", "function d() {\n $variables = func_get_args();\n $trace = debug_backtrace(null, 1);\n \\Yii::$app->logger->debugInternal($variables, $trace);\n }", "public function register()\n {\n $this->container->share(StandardDebugBar::class, function () {\n $twig = $this->container->get(Twig_Environment::class);\n\n // Create Debugbar\n $debugbar = new StandardDebugBar();\n $debugbar->addCollector(new QueryCollector());\n\n // Publish assets\n $renderer = $debugbar->getJavascriptRenderer();\n $renderer->dumpCssAssets('builds/debugbar.css');\n $renderer->dumpJsAssets('builds/debugbar.js');\n $renderer->addAssets(['/builds/debugbar.css'], ['/builds/debugbar.js']);\n\n // Bind renderer to views\n $twig->addGlobal('debugbar', $renderer);\n\n // Bind QueryCollector to current connection\n /* @var StandardDebugbar $debugbar */\n /* @var Connection $connection */\n $connection = $this->container->get(Manager::class)->connection();\n $connection->listen(function (QueryExecuted $event) use ($debugbar, $connection) {\n /** @var QueryCollector $collector */\n $collector = $debugbar->getCollector('queries');\n $collector->addQuery((string) $event->sql, $event->bindings, $event->time, $event->connection);\n });\n\n return $debugbar;\n });\n\n $this->container->share(JavascriptRenderer::class, function () {\n return $this->container->get(StandardDebugBar::class)->getJavascriptRenderer();\n });\n }", "function testDebugDoNotShow() {\n Debug::$enable_show = false;\n ob_start();\n Debug::out('Testing, testing, 123');\n $output = ob_get_clean();\n $this->assertEqual('', $output);\n }", "function ffd_debug( $var = '' , $exit=false) {\r\n\r\n\techo '<pre style=\"/*display: none;*/\">';\r\n\t\tif( is_object($var) || is_array($var) )\r\n\t\t\tprint_r($var);\r\n\t\telse \r\n\t\t\tvar_dump($var);\r\n echo '</pre>';\r\n if( $exit )\r\n die();\r\n}", "private function debug($var = null) {\n if( $var ) {\n echo '<pre>';\n print_r( $var );\n echo '</pre>';\n }\n }", "function dd($var){\n\t\techo \"<pre>\";\n\t\tdie(print_r($var));\n\t}", "function _dd($var)\r\n{\r\n $caller = array_shift(debug_backtrace(1));\r\n d($var,$caller);\r\n die();\r\n}", "public function debug()\n {\n // Get the request paramaters\n $request = Zend_Controller_Front::getInstance()->getRequest()->getParams();\n\n // Create the string variable\n $string = <<<HTML\n <div id=\"debugArea\">\n <b>Debug Area</b>\n <hr />\nHTML;\n\n // Run the isfacebook method\n $string .= self::_isFacebook();\n\n // Run the isTodo method\n $string .= '<b>Todo</b>';\n $string .= self::_isTodo();\n\n // Output the Request Paramaters\n $string .= '<b>Paramaters</b><br />';\n $string .= Zend_Debug::dump($request, '<b>All Params</b>', false);\n $string .= Zend_Debug::dump($_REQUEST, '<b>Request Paramaters</b>', false);\n\n // Get the Auth Instance\n $auth = Zend_Auth::getInstance();\n\n // Check if this user is logged in\n if ($auth->hasIdentity()) {\n $string .= Zend_Debug::dump($auth->getIdentity(), '<b>Zend Auth</b>', false);\n }\n\n // If Files is not empty then output these\n if (!empty($_FILES)) {\n $string .= Zend_Debug::dump($_FILES, '<b>Files</b>', false);\n }\n\n // End the DIV\n $string .= '</div>';\n\n return $string;\n }", "public function get_debug_flag()\n {\n }", "public function d() {\n // data we are going to log\n $variables = func_get_args();\n $trace = debug_backtrace(null, 1);\n\n $this->debugInternal($variables, $trace);\n }", "function debug($str){\r\n\t\tif (DEVELOPMENT_ENVIRONMENT){\r\n\t\t\t$trace = debug_backtrace();\r\n\t\t\t// warning(print_r($trace,true));\r\n\t\t\t$file = $trace[0]['file'];\r\n\t\t\t$file = str_replace($_SERVER['DOCUMENT_ROOT'],'',$file);\r\n\t\t\t$line = $trace[0]['line'];\r\n\t\t\tif (isset($trace[1]['object'])){\r\n\t\t\t\t$object = $trace[1]['object'];\r\n\t\t\t\tif (is_object($object)) { $object = get_class($object); }\r\n\t\t\t}else{\r\n\t\t\t\t$object = \"View\";\r\n\t\t\t}\r\n\t\t\t// echo style();\r\n\t\t\t// echo \"<pre class='debug'><strong>DEBUG:</strong> In <strong>$object</strong> -> Line <strong>$line</strong>\\n(file <strong>$file</strong>)\";\r\n\t\t\t// echo \"<pre class='debug' style='font-size: 80%'>\";\r\n\t\t\t// print_r($str);\r\n\t\t\t// echo \"</pre></pre>\";\r\n\t\t\t$GLOBALS['_debug'][$object][$file][$line] = print_r($str,true); \r\n\t\t}\r\n\t}", "public static function traceShow()\n {\n return self::debugger(func_get_args(), 2, array(\"tag\" => \"div\"));\n }", "public function enableDebug() : void\n {\n $this->debug = TRUE;\n }", "public function GetDebug () \r\n\t{\r\n\t\treturn (self::$debug);\r\n\t}", "public function GetDebug () \r\n\t{\r\n\t\treturn (self::$debug);\r\n\t}", "function Debug($debug, $msg = \"Debugging\"){\n\tif(ENV == PRODUCTION && (!isset($_GET['debug'])) ){\n\t\treturn;\n\t}\n\n\techo '<pre class=\"debug\">';\n\techo '<h2>'.$msg.'</h2>';\n\tprint_r($debug);\n\techo '</pre>';\n}", "function print_debugger()\n\t{\n\t\t$output = str_replace(\"\\n\", \"<br/>\\n\", $this->debugger);\n\t\techo $output;\t\n\t}", "public function show_in_admin_bar()\n\t{\n\t\treturn !( self::const_value( 'DEVDEBUG_NO_ADMIN_BAR' ) );\n\t}", "protected function Debug($var){\n\t\t$bt = debug_backtrace();\n\t\t$dump = new CVarDumper();\n\t\t$debug = '<div style=\"display:block;background-color:gold;border-radius:10px;border:solid 1px brown;padding:10px;z-index:10000;\"><pre>';\n\t\t$debug .= '<h4>function: '.$bt[1]['function'].'() line('.$bt[0]['line'].')'.'</h4>';\n\t\t$debug .= $dump->dumpAsString($var);\n\t\t$debug .= \"</pre></div>\\n\";\n\t\tYii::app()->params['debugContent'] .=$debug;\n\t}", "function dd($data, $data_name='$data') {\n $tmp_var = debug_backtrace(1);\n $caller = array_shift($tmp_var);\n\n error_reporting(-1);\n header('Content-Type: text/html; charset=utf-8');\n\n echo '<code>File: ' . $caller['file'] . ' / Line: ' . $caller['line'] . '</code>';\n echo '<pre>';\n echo $data_name . '=', PHP_EOL;\n VarDumper::dump($data, 10, true);\n echo '</pre>';\n\n die();\n}", "protected function _initZFDebug()\n {\n $autoloader = Zend_Loader_Autoloader::getInstance();\n $autoloader->registerNamespace('ZFDebug');\n\n $options = array(\n 'plugins' => array('Variables',\n 'File' => array('base_path' => APPLICATION_PATH),\n 'Html',\n 'Memory',\n 'Time',\n 'Registry',\n 'Exception'),\n 'z-index' => 255,\n 'image_path' => '/images/debugbar',\n 'jquery_path' => 'http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js',\n );\n\n // Instantiate the database adapter and setup the plugin.\n // Alternatively just add the plugin like above and rely on the autodiscovery feature.\n if ($this->hasPluginResource('Db')) {\n $this->bootstrap('Db');\n $db = $this->getPluginResource('Db')->getDbAdapter();\n $options['plugins']['Database']['adapter'] = $db;\n }\n\n // Setup the cache plugin\n if ($this->hasPluginResource('Cache')) {\n $this->bootstrap('Cache');\n $cache = $this-getPluginResource('Cache')->getDbAdapter();\n $options['plugins']['Cache']['backend'] = $cache->getBackend();\n }\n\n $debug = new ZFDebug_Controller_Plugin_Debug($options);\n\n $this->bootstrap('frontController');\n $frontController = $this->getResource('frontController');\n $frontController->registerPlugin($debug);\n }", "public function isDebug()\n {\n return $this->decoratedOutput->isDebug();\n }", "function dd( $var ){\n echo \"<prev>\";\n die(print_r($var));//Finaliza la ejecucion\n}", "public function debug() {\r\n\t\treturn EcommerceTaskDebugCart::debug_object($this);\r\n\t}", "public function debug(): void\n {\n echo \"CLIENT : \" . PHP_EOL;\n echo \"=========\" . PHP_EOL;\n echo \"URL : \" . $this->getUrl(). PHP_EOL;\n echo \"METHOD : \" . $this->method. PHP_EOL;\n echo \"SPA ID : \" . $this->spaceId. PHP_EOL;\n echo \"ACCEPT : \" . $this->acceptContentType. PHP_EOL;\n echo \"C TYPE : \" . $this->contentType . PHP_EOL;\n echo \"API : \" . $this->apiType. PHP_EOL;\n echo \"TOKEN : \" . $this->c->getCredentials()->getAccessToken(). PHP_EOL;\n echo \"GEOJSON: \" . $this->geojsonFile. PHP_EOL;\n var_dump($this->requestBody);\n echo \"=========\" . PHP_EOL;\n }", "public static function getDebug() {\n\t\treturn self::$_debug;\n\t}", "public function getDebug()\n {\n return $this->apiDebug;\n }", "public function getDebug()\n\t{\n\t\treturn $this->debug;\n\t}", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function getDebug()\n {\n return $this->debug;\n }", "public function isDebugOn()\n {\n return $this->debug;\n }", "function app_debug($value, bool $die = null)\n{\n echo \"<pre>\";\n print_r($value);\n echo \"</pre>\";\n\n if ($die === true) die('<strong> End of debug </strong>');\n\n}" ]
[ "0.69971675", "0.6546478", "0.63992673", "0.6208732", "0.60983825", "0.6001779", "0.6001779", "0.5907528", "0.5895943", "0.5875641", "0.5870005", "0.5863825", "0.5838408", "0.58316535", "0.58316535", "0.5782957", "0.5764537", "0.5711748", "0.57077473", "0.5683816", "0.56792563", "0.5666084", "0.56608284", "0.5595349", "0.5572072", "0.55613565", "0.55564034", "0.55521077", "0.55413777", "0.5528641", "0.5524544", "0.54820246", "0.54608256", "0.54520106", "0.54399896", "0.5435778", "0.54348725", "0.54239357", "0.5408616", "0.5392929", "0.5376136", "0.53659594", "0.5339999", "0.53333133", "0.53324366", "0.5331087", "0.5328405", "0.53151685", "0.53051275", "0.5302786", "0.53022134", "0.5292015", "0.5292015", "0.5280617", "0.52803314", "0.52796644", "0.52752453", "0.5264241", "0.52533966", "0.52318174", "0.52249444", "0.52167463", "0.52116627", "0.52116627", "0.52029485", "0.5196986", "0.51965284", "0.519571", "0.51917154", "0.5189611", "0.51876044", "0.51856947", "0.5179906", "0.51760715", "0.51743466", "0.5167224", "0.51500714", "0.51446897", "0.51446897", "0.51407707", "0.5130832", "0.5125377", "0.5121008", "0.5119326", "0.51170874", "0.51072574", "0.5105226", "0.5105206", "0.5104232", "0.51019937", "0.5099955", "0.50986606", "0.50836205", "0.50836205", "0.50836205", "0.50836205", "0.50836205", "0.50836205", "0.50836205", "0.50788105", "0.5076129" ]
0.0
-1
Display a listing of the resource.
public function index() { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function indexAction()\n {\n $limit = $this->Request()->getParam('limit', 1000);\n $offset = $this->Request()->getParam('start', 0);\n $sort = $this->Request()->getParam('sort', array());\n $filter = $this->Request()->getParam('filter', array());\n\n $result = $this->resource->getList($offset, $limit, $filter, $sort);\n\n $this->View()->assign($result);\n $this->View()->assign('success', true);\n }", "public function listing();", "function index() {\n\t\t$this->show_list();\n\t}", "public function actionList() {\n $this->_getList();\n }", "public function listAction()\n {\n $model = $this->_getPhotoModel();\n $entries = $model->fetchEntries($this->_getParam('page', 1));\n\n $this->view->url = 'http://' . $this->_request->getHttpHost() . $this->_request->getBaseUrl(); \n $this->view->paginator = $entries;\n }", "public function index()\n {\n $items = Item::all();\n return ItemForShowResource::collection($items);\n }", "public function index()\n {\n return Resource::collection(($this->getModel())::paginate(10));\n }", "function index()\n\t{\n\t\t$this->_list();\n\t\t$this->display();\n\t}", "public function listingAction(){\n if (!LoginHelper::isAdmin()){\n Router::redirect('home', '<p class=\"alert alert-danger\">Unauthorized</p>');\n }\n $this->view->render('patient/list', Patient::all());\n }", "public function index()\n {\n //\n $list = $this->obj->all();\n\n return $this->render('index', compact('list'));\n }", "public function action_index()\n\t{\n\t\t$this->template->title = 'Resources';\n\t\t$this->view = View::factory('admin/resource/index');\n\t\t$this->template->scripts[] = 'media/js/jquery.tablesorter.min.js';\n\t\t$this->template->scripts[] = 'media/js/admin/resource.js';\n\t\t\n\t\t$resources = Sprig::factory('resource')->load(NULL, FALSE);\n\t\tif (!empty($resources))\n\t\t{\n\t\t\t$this->view->resources = $resources->as_array();\n\t\t}\n\t}", "function listing()\n\t\t{\n\t\t// en $this->_view->_listado para poder acceder a el desde la vista.\n\t\t\t$this->_view->_listado = $listado = $this->_instrumentoModel->getInstrumento();\n\t\t\t$this->_view->render('listing', '', '',$this->_sidebar_menu);\n\t\t}", "public function listAction()\n {\n $em = $this->getDoctrine()->getManager();\n \n $todos = $em->getRepository(Todo::class)->findAll();\n \n return $this->render('todo/index.html.twig', array(\n 'todos' => $todos,\n ));\n }", "public function index()\n\t{\n $this->authorize('list', Instance::class);\n\n\t\treturn $this->ok($this->repo->paginate($this->request->all()));\n\t}", "public function actionRestList() {\n\t $this->doRestList();\n\t}", "public function listing()\n\t{\n\t\t$hospitalID = $this->request->getSession()->read(\"hospital_id\") ? $this->request->getSession()->read(\"hospital_id\") : \"\";\n\t\t\n\t\t$patientMonitored = 1;\n\t\t$patientActive = 1;\n\t\t\n\t\t//GET ALL PATIENTS\n\t\t$patientsData = $this->Patients->allPatients($hospitalID,$patientMonitored,$patientActive);\n\t\t//GET ALL PATIENTS\n\t\t\n\t\t//echo \"<pre>\"; print_r($patientsData);die;\n\t\t$this->set(compact(\"patientsData\"));\n\t}", "public function listAction()\n {\n $htmlpage = '<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"UTF-8\">\n <title>todos list!</title>\n </head>\n <body>\n <h1>todos list</h1>\n <p>Here are all your todos:</p>\n <ul>';\n \n $em = $this->getDoctrine()->getManager();\n $todos = $em->getRepository(Todo::class)->findAll();\n foreach($todos as $todo) {\n $htmlpage .= '<li>\n <a href=\"/todo/'.$todo->getid().'\">'.$todo->getTitle().'</a></li>';\n }\n $htmlpage .= '</ul>';\n\n $htmlpage .= '</body></html>';\n \n return new Response(\n $htmlpage,\n Response::HTTP_OK,\n array('content-type' => 'text/html')\n );\n }", "public function index()\n {\n // Get Persons\n $person = Person::paginate(10);\n\n //Return collection of person as a resource\n return PersonResource::collection($person);\n }", "public function listAction() {\n\t\t$this->view->title = $this->translator->translate(\"Invoice list\");\n\t\t$this->view->description = $this->translator->translate(\"Here you can see all the invoices.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"/admin/invoices/new/\", \"label\" => $this->translator->translate('New'), \"params\" => array('css' => null)));\r\n\t\t$this->datagrid->setConfig ( Invoices::grid() )->datagrid ();\n\t}", "public function listAll()\n\t{\n\t\t$this->render(self::PATH_VIEWS . '/list', [\n\t\t\t'pages' => $this->pagesDb->findAll('id', 'DESC'),\n\t\t]);\n\t}", "public function list()\n {\n // récupérer les données : toutes les catégories enregistrées\n $productList = Product::findAll();\n\n $this->show('product/list', [\n 'productList' => $productList\n ]);\n }", "public function index()\n {\n // CRUD -> Retrieve --> List\n // BREAD -> Browse Read Edit Add Delete\n // return Item::all();\n return view('list_items',compact('items'));\n }", "public function index()\n {\n // Get manufacturers\n $manufacturers = Manufacturer::orderBy('created_at', 'desc')->paginate(15);\n\n // Return collection of manufacturers as a resource\n return ManufacturerResource::collection($manufacturers);\n }", "public function index()\n {\n return ArtistResource::collection(Artist::orderBy('created_at', 'desc')->get());\n }", "public function indexAction() {\n\t\t$page = intval($this->getInput('page'));\n\t\t$perpage = $this->perpage;\n\t\t\n\t\tlist(,$files) = Lock_Service_FileType::getAllFileType();\n\t\t$data = array();\n\t\tforeach ($files as $key=>$value) {\n\t\t\t$data[$key]['id'] = $value['id'];\n\t\t\t$data[$key]['title'] = $value['name'];\n\t\t}\n\t\tlist($total, $filetype) = Lock_Service_FileType::getList($page, $perpage);\n\t\t$this->assign('filetype', $filetype);\n\t\t$this->assign('pager', Common::getPages($total, $page, $perpage, $this->actions['listUrl'].'/?'));\n\t\t$this->assign('data', json_encode($data));\n\t}", "public function listAction()\n {\n $qb = $this->getRepository()->queryAll();\n\n $view = new ImportListView;\n $view->imports = $qb->getQuery()->execute();\n\n return $this->templating->renderResponse('InfiniteImportBundle:Import:list.html.twig', array(\n 'data' => $view\n ));\n }", "public function index()\n\t{\n\t\t//Return model all()\n\t\t$instances = $this->decorator->getListingModels();\n\n\t\treturn View::make($this->listingView, array(\n\t\t\t'instances' => $instances,\n\t\t\t'controller' => get_class($this), \n\t\t\t'modelName' => class_basename(get_class($this->decorator->getModel())),\n\t\t\t'columns' => $this->getColumnsForInstances($instances),\n\t\t\t'editable' => $this->editable\n\t\t));\n\t}", "public function index()\n {\n return InfografiResources::collection(\n Infografi::orderBy('date', 'desc')->get()\n );\n }", "public function listAction()\n\t {\n\t\t\t$this->_forward('index');\n \n\t\t}", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function index()\n {\n $this->list_view();\n }", "public function listAction()\n {\n $defaults = array(\n 'page' => null,\n 'order' => null,\n 'limit' => null,\n 'offset' => null,\n 'filter' => array(),\n );\n $body = $this->getRequest()->getBody();\n $options = $body + $defaults;\n\n // Process the options\n if (is_string($options['order'])) {\n $options['order'] = array_map('trim', explode(',', $options['order']));\n }\n if (is_string($options['page'])) {\n $options['page'] = (int)$options['page'];\n }\n if (is_string($options['limit'])) {\n $options['limit'] = (int)$options['limit'];\n }\n if (is_string($options['offset'])) {\n $options['offset'] = (int)$options['offset'];\n }\n $filter = $options['filter'];\n unset($options['filter']);\n\n $options = array_filter($options);\n\n return $this->getBinding()->find($filter, $options);\n }", "public function index()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the resources from the model */\n $resources = $this->resourcesList($this->model);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.index\")) {\n $view = \"admin.{$this->name}.index\";\n } else {\n $view = 'admin.includes.actions.index';\n }\n\n /* Display a listing of the resources */\n return view($view)\n ->with('resources', $resources)\n ->with('module', $this->module);\n }", "public function index()\n\t{\n\t\t$data['lists'] = $this->mdl_student->get_all();\n\t\t$this->template->set('title', 'Student Hostel List');\n\t\t$this->template->load('template', 'contents', 'student_hostel/student_hostel_list', $data);\n\t}", "public function index()\n {\n $modules = Module::all();\n return Resource::collection($modules);\n }", "public function index()\n {\n // List all resources from user entity\n $users = User::all();\n\n return $this->showAll($users);\n }", "public function index()\n {\n // Get todos\n $todos = Todo::orderBy('created_at', 'desc')->paginate(3);\n\n // Return collection of articles as a resource\n return TodoResource::collection($todos);\n }", "public function index()\n {\n return Resources::collection(Checking::paginate());\n }", "public function index()\n {\n return CourseListResource::collection(\n Course::query()->withoutGlobalScope('publish')\n ->latest()->paginate()\n );\n }", "public function index()\n {\n $cars = Car::paginate(15);\n return CarResource::collection($cars);\n }", "public function index()\n {\n // Get articles\n $articles = Article::orderBy('created_at', 'desc')->paginate(5);\n\n // Return collection of articles as a resource\n return ArticleResource::collection($articles);\n }", "public function index()\n {\n $authors = Author::paginate(10);\n\n return AuthorResource::collection($authors);\n }", "public function index()\n {\n //Get Books\n $books = Book::paginate(10);\n \n if ($books) {\n return (BookResource::collection($books))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n } else {\n return (BookResource::collection([]))->additional([\n 'status_code' => 200,\n 'status' => 'success',\n ]);\n }\n return view('index')->with('data', $books);\n }", "public function view(){\n\t\t$this->buildListing();\n\t}", "public function index()\n {\n $books = Book::latest()\n ->paginate(20);\n\n return BookResource::collection($books);\n }", "public function index()\n {\n $listing = Listing::orderBy('id', 'desc')->paginate(10);\n return view('listings.index')->withListings($listing);\n }", "public function listAction()\n {\n $this->_getSession()->setFormData([]);\n\n $this->_title($this->__('Training Cms'))\n ->_title($this->__('Pages'));\n\n $this->loadLayout();\n\n $this->_setActiveMenu('training_cms');\n $this->_addBreadcrumb($this->__('Training Cms'), $this->__('Training Cms'));\n $this->_addBreadcrumb($this->__('Pages'), $this->__('Pages'));\n\n $this->renderLayout();\n }", "public function index()\n {\n $services = $this->serviceRepository->paginate();\n\n return ServiceResource::collection($services);\n }", "public function index()\n {\n $resources = ResourceManagement::paginate(5);\n $users = User::get();\n\n return view('resources-mgmt/index', ['resources' => $resources, 'users' => $users]);\n }", "public function index()\n {\n $catalogs = Catalog::where('status', '=', Catalog::PUBLICADO)\n ->orderBy('id', 'DESC')->get();\n \n $data = CatalogResource::collection($catalogs);\n\n return [\n 'items' => $data,\n 'mensaje' => ''\n ];\n }", "public function listAction(){\n // In a controller this can be:\n // $this->request->getQuery('page', 'int'); // GET\n $currentPage = $this->request->getPost('pageindex', 'int'); // POST\n $pageNum = ($currentPage == null) ? 1 : $currentPage;\n\n // The data set to paginate\n $message = new Notice();\n $results = $message->getMsg4Admin();\n\n // Create a Model paginator, show 10 rows by page starting from $currentPage\n $paginator = new PaginatorArray(\n array(\n \"data\" => $results,\n \"limit\" => 10,\n \"page\" => $pageNum\n )\n );\n\n // Get the paginated results\n $page = $paginator->getPaginate();\n\n return $this->response->setJsonContent($page);\n\n }", "public function list()\n {\n try {\n return $this->success($this->service->list());\n } catch (\\Exception $exception) {\n return $this->error($exception->getMessage());\n }\n }", "public function index()\n {\n return $this->sendResponse(CrisisResource::collection(Crisis::paginate(10)), 'Data fetched successfully');\n }", "public function index()\n\t{\n\t\t$%Alias = new %Model();\n\t\t$params = array();\n\t\t\n\t\t$Paginator = new Paginator( $%Alias->findSize( $params ), $this->getLimit(), $this->getPage() );\n\t\t$this->getView()->set( '%Aliass', $%Alias->findList( $params, 'Id desc', $this->getOffset(), $this->getLimit() ) );\n\t\t$this->getView()->set( 'Paginator', $Paginator );\n\t\treturn $this->getView()->render();\n\t}", "public function listAction() {}", "public function index()\n {\n\n return RecipeResource::collection(Recipe::all());\n }", "public function index()\n {\n $this->indexPage('list-product', 'List Product');\n }", "public function listAction()\n {\t\n\t\t$this->removeSession();\n\t\t$this->verifySessionRights();\n\t\t$this->setActivity(\"List view\");\n $em = $this->getDoctrine()->getManager();\n $oRepClient = $em->getRepository('BoAdminBundle:Client');\n\t\t$nb_tc = $oRepClient->getTotal();\n\t\t//get page\n\t\t$page = $this->get('session')->get('page');\n\t\tif($page==null){\n\t\t\t$page=1;\n\t\t\t$this->get('session')->set('page',1);\n\t\t}\n\t\t//get number line per page\n\t\t$nb_cpp = $em->getRepository('BoAdminBundle:Param')->getParam(\"display_list_page_number\",1);\n\t\t$nb_pages = ceil($nb_tc/$nb_cpp);\n\t\t$offset = $page>0?($page-1) * $nb_cpp:0;\n\t\t$clients = $em->getRepository('BoAdminBundle:Client')->findBy(array(),array('id' => 'desc'),$nb_cpp,$offset);\n $form = $this->createForm('Bo\\AdminBundle\\Form\\ClientType', new Client());\n return $this->render('client/index.html.twig', array(\n 'clients' => $clients,\n\t\t\t'page' => $page, // forward current page to view,\n\t\t\t'nb_pages' => $nb_pages, //total number page,\n 'form' => $form->createView(),\n\t\t\t'total'=>$nb_tc, // record number.\n\t\t\t'nb_cpp' => $nb_cpp,// line's number to display\n\t\t\t'pm'=>\"contracts\",\n\t\t\t'sm'=>\"client\",\n ));\n }", "public function index()\n {\n return AcResource::collection(Ac::latest()->paginate()); //\n }", "public function executeList()\n {\n $this->setTemplate('list');\n }", "public function indexAction()\n {\n $books = Book::getAll();\n\n View::renderTemplate('Books/index.html', [\n 'books' => $books\n ]);\n }", "function listing() {\r\n\r\n }", "public function listar() {\n $rs = $this->model->listar();\n\n echo $this->toJson($rs);\n }", "public function index()\n {\n return BookResource::collection(Book::orderby('id')->get());\n }", "public function doRestList()\n {\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->orderBy($this->restSort)->limit($this->restLimit)->offset($this->restOffset)->findAll(),\n $this->getModel()->with($this->nestedRelations)->filter($this->restFilter)->count()\n );\n\t}", "public function index()\n {\n $client = Client::paginate();\n return ClientResource::collection($client);\n }", "public function index()\n {\n return TagResource::collection(\n Tag::orderBy('name', 'ASC')->paginate(request('per_page', 10))\n );\n }", "public function _index(){\n\t $this->_list();\n\t}", "public function index()\n\t{\n\t\t$data['lists'] = $this->gallery_mdl->get_all();\n\t\t$this->template->set('title', 'Gallery');\n\t\t$this->template->render('template', 'list', $data);\n\t}", "function drush_restapi_list() {\n\n $resources = restapi_get_resources();\n $last_module = NULL;\n $rows = [\n [dt('Module'), dt('Path'), dt('Class')],\n ];\n\n foreach($resources as $resource) {\n if ($last_module != $resource->getModule()) {\n $module = $last_module = $resource->getModule();\n }\n else {\n $module = '';\n }\n $rows[] = [$module, $resource->getPath(), $resource->getClass()];\n }\n\n drush_print_table($rows, TRUE);\n drush_log(dt('Displaying !count total resources', [\n '!count' => count($resources),\n ]), 'ok');\n\n}", "public function index()\n {\n $this->booklist();\n }", "public function index()\n {\n //\n $accounts = accounts::paginate(15);\n\n //return the collection of employees as a resource\n return accountResource::collection($accounts);\n\n\n }", "public function index()\n {\n $items = Item::all();\n return view('items::list_items',compact('items'));\n }", "public function index()\n {\n // Get houses\n $houses = House::orderBy('created_at', 'desc')->paginate(self::PAGINATE);\n \n // Return collection of houses\n \n return HouseResource::collection($houses);\n }", "public function index()\n {\n $products = Product::paginate(6);\n return ProductResource::collection($products);\n }", "public function index() {\n $this->template->allFoundItems = Found::showAll();\n $this->template->display( 'index.html.php' );\n }", "public function indexAction() {\n $this->_forward('list');\n }", "public function index()\n {\n $data = Productcategory::paginate(10);\n\t\treturn ProductcategoryResource::Collection($data);\n }", "public function index()\n {\n return SongResource::collection(\\App\\Song::orderBy('created_at', 'desc')->get());\n }", "public function ListView()\n\t{\n\t\t\n\t\t// Requer permissão de acesso\n\t\t$this->RequirePermission(Usuario::$P_ADMIN,\n\t\t\t\t'SecureExample.LoginForm',\n\t\t\t\t'Autentique-se para acessar esta página',\n\t\t\t\t'Você não possui permissão para acessar essa página ou sua sessão expirou');\n\t\t\n\t\t//$usuario = Controller::GetCurrentUser();\n\t\t//$this->Assign('usuario',$usuario);\n\t\t$this->Render();\n\t}", "public function index () {\n permiss ( 'role.list' );\n\n $data = $this->entity\n ->orderBy('created_at', 'desc')->get();\n\n return new ModelResource($data);\n }", "public function showResources()\n {\n $resources = Resource::get();\n return view('resources', compact('resources'));\n }", "public function index()\n {\n //get articless\n $articles = Article::paginate(15);\n\n //Return collection of article has a resource\n return ArticleResource::collection($articles);\n\n }", "public function actionList() {\n header(\"Content-type: application/json\");\n $verb = $_SERVER[\"REQUEST_METHOD\"];\n\n if ($verb === 'GET') {\n echo \"{\\\"data\\\":\" . CJSON::encode(Donneur::model()->findAll()) . \"}\";\n } else if ($verb == 'POST') {\n if (Donneur::model()->exists('id' === $_POST['id'])) {\n $this->actionListUpdate($_POST);\n } else {\n $this->actionListPost();\n }\n } else if ($verb == 'DELETE') {\n $this->actionListDelete();\n }\n }", "public function list()\n {\n return $this->http->request(HttpMethods::GET, $this->endpoint);\n }", "public function indexAction(){\n $data = array(\n 'collection' => $this->model->getCollection(),\n \n ); \t\n return $this->getView($data);\n }", "public function indexAction()\n {\n $em = $this->getDoctrine()->getManager();\n\n $entities = $em->getRepository('DiverPriceLisrBundle:Items')->findAll();\n\n return $this->render('DiverPriceLisrBundle:Items:index.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionIndex()\n {\n $dataProvider = new ActiveDataProvider([\n 'query' => Slaves::find(),\n ]);\n\n return $this->render('index', [\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function listAction() {\n\t\t// Recogemos el repositorio\n\t\t$repository = $this->getDoctrine() ->getRepository('AppBundle:Product');\n\t\n\t\t// Recuperamos todos los productos.\n\t\t$products = $repository->findAll();\n\t\t// Pasamos a la plantilla el aray products\n\t\treturn $this->render('product/listActionProduct.html.twig', array( 'products' => $products));\n\t\n\t}", "public function listAction()\n\t {\n\t\t$model = $this->_getModel();\n\t\t$result = $model->getLayouts();\t\n\t\t$page = (int)($this->_request->getParam('page')); \n\t\tif(count($result) > 0)\n\t\t{ \n\t\t\tGlobals::doPaging($result, $page, $this->view);\n\t\t}\n\t\t\t\t\n\t\t$this->view->page = $page;\n\t }", "public function actionList()\n {\n // get model\n $model = new $this->_model('search');\n $model->unsetAttributes();\n\n // set filter\n if (isset($_GET[$this->_model])) {\n $model->attributes = $_GET[$this->_model];\n }\n $model->u_cms_album_id = $_GET['album'];\n\n // search\n $dataProvider = $model->search(Yii::app()->language);\n // sort\n $sort = $dataProvider->getSort();\n // route\n $sort->route = $this->id . '/list';\n\n // pagination parameters\n $pagination = $dataProvider->getPagination();\n $pagination->route = $this->id . '/list';\n $pagination->pageSize = UInterfaceSetting::model()->getSettings($this->id . ':' . $this->module->id, Yii::app()->user->id)->page_size;\n $pagination->itemCount = $dataProvider->totalItemCount;\n\n // datas\n $datas = $dataProvider->getData();\n\n // related datas\n $relatedDatas = $this->_loadRelatedData();\n\n // template\n $template = isset($_REQUEST['partial']) ? 'list/_table' : 'list/main';\n\n $jsonParams = array();\n if (Yii::app()->request->isAjaxRequest) {\n // filters\n $filtersDatas = array();\n if (isset($_GET[$this->_model])) {\n $filtersDatas[$this->_model] = $_GET[$this->_model];\n }\n if (isset($_GET[$sort->sortVar])) {\n $filtersDatas[$sort->sortVar] = $_GET[$sort->sortVar];\n }\n\n $jsonParams = array(\n 'filters' => http_build_query($filtersDatas)\n );\n }\n\n $this->dynamicRender(\n $template,\n array(\n 'dataView' => new $this->crudComponents['listDataView'](\n $datas, $relatedDatas, $model, $sort, $pagination, $this\n )\n ),\n $jsonParams\n );\n }", "public function index()\n {\n return view('listings.index')->with('listings', Listing::all());\n }", "public function get_index()\n\t{\n\t\t$pages = Page::recent_available()->paginate(30);\n\t\t$table = Cello\\Presenter\\Page::table($pages);\n\t\t$data = array(\n\t\t\t'eloquent' => $pages,\n\t\t\t'table' => $table,\n\t\t);\n\n\t\tSite::set('title', __('cello::title.pages.list'));\n\n\t\treturn View::make('cello::api.resources.index', $data);\n\t}", "public function index()\n {\n return ProductResource::collection(Product::latest()->paginate(10));\n }", "public function index()\n {\n $category = GalleryCategory::paginate(15);\n\n // return collection of category as a resource.\n return Resource::collection($category);\n }", "public function index()\n {\n //\n $news = News::latest()->paginate(18);\n\n return NewsResource::collection($news);\n }", "public function indexAction() {\n\t\t$list_info = Zend_Registry::get('list_info');\n if (!Engine_Api::_()->core()->hasSubject('list_listing')) {\n return $this->setNoRender();\n }\n \n $this->view->expiry_setting = Engine_Api::_()->list()->expirySettings();\n\n //GET SUBJECT\n $this->view->list = $list = Engine_Api::_()->core()->getSubject('list_listing');\n\n\t\t//GET CATEGORY TABLE\n\t\t$this->view->tableCategory = Engine_Api::_()->getDbTable('categories', 'list');\n\n //GET CATEGORIES NAME\n\t\t$this->view->category_name = $this->view->subcategory_name = $this->view->subsubcategory_name = '';\n\n\t\tif(!empty($list->category_id)) {\n\t\t\tif($this->view->tableCategory->getCategory($list->category_id))\n\t\t\t$this->view->category_name = $this->view->tableCategory->getCategory($list->category_id)->category_name;\n\n\t\t\tif(!empty($list->subcategory_id)) {\n\t\t\t\tif($this->view->tableCategory->getCategory($list->subcategory_id))\n\t\t\t\t$this->view->subcategory_name = $this->view->tableCategory->getCategory($list->subcategory_id)->category_name;\n\n\t\t\t\tif(!empty($list->subsubcategory_id)) {\n\t\t\t\t\tif($this->view->tableCategory->getCategory($list->subsubcategory_id))\n\t\t\t\t\t$this->view->subsubcategory_name = $this->view->tableCategory->getCategory($list->subsubcategory_id)->category_name;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n //GET LISTING TAGS\n $this->view->listTags = $list->tags()->getTagMaps();\n\n\t\t//GET OTHER DETAILS\n\t\t$this->view->list_description = Zend_Registry::get('list_descriptions');\n $this->view->addHelperPath(APPLICATION_PATH . '/application/modules/Fields/View/Helper', 'Fields_View_Helper');\n $this->view->fieldStructure = Engine_Api::_()->fields()->getFieldsStructurePartial($list);\n\t\tif(empty($list_info)){ return $this->setNoRender(); }\n }", "public function index()\n {\n return $this->service->fetchResources(Author::class, 'authors');\n }", "public function index()\n {\n return view('admin.resources.index');\n }", "public function doRestList() {\n\t\t$this->outputHelper ( 'Collections Retrieved Successfully', $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->orderBy ( $this->restSort )->limit ( $this->restLimit )->offset ( $this->restOffset )->findAll (), $this->getModel ()->with ( $this->nestedRelations )->filter ( $this->restFilter )->count () );\n\t}" ]
[ "0.7446777", "0.736227", "0.73005503", "0.72478926", "0.71631265", "0.71489686", "0.7131636", "0.7105969", "0.71029514", "0.7101372", "0.70508176", "0.6995128", "0.69890636", "0.6934895", "0.6900203", "0.6899281", "0.6891734", "0.6887235", "0.68670005", "0.6849741", "0.6830523", "0.6802689", "0.6797", "0.67957735", "0.67871135", "0.6760129", "0.67427456", "0.6730486", "0.67272323", "0.67255723", "0.67255723", "0.67255723", "0.67177945", "0.6707866", "0.6706713", "0.6704375", "0.6664782", "0.6662871", "0.6660302", "0.6659404", "0.6656656", "0.6653517", "0.6647965", "0.6620322", "0.66185474", "0.6618499", "0.6606105", "0.6600617", "0.65996987", "0.6594775", "0.6587389", "0.6585109", "0.6581641", "0.6581017", "0.6577157", "0.65747666", "0.6572513", "0.65721947", "0.6570553", "0.65646994", "0.6563556", "0.6554194", "0.65529937", "0.65460825", "0.65368485", "0.653429", "0.65328294", "0.6526759", "0.6526695", "0.6526284", "0.65191334", "0.65183175", "0.65174305", "0.651703", "0.65141153", "0.6507088", "0.65061647", "0.6504046", "0.64942145", "0.6491893", "0.64883405", "0.6486392", "0.6485077", "0.64846045", "0.6478858", "0.64756656", "0.64726377", "0.6471126", "0.64701074", "0.6467418", "0.6462195", "0.64618355", "0.6459199", "0.6457831", "0.6454631", "0.64533997", "0.6451915", "0.6450861", "0.6449301", "0.64492667", "0.64469045" ]
0.0
-1
Show the form for creating a new resource.
public function create() { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return $this->showForm('create');\n }", "public function create()\n {\n return view('admin.resources.create');\n }", "public function create(){\n\n return view('resource.create');\n }", "public function create()\n\t{\n\t\treturn $this->showForm('create');\n\t}", "public function create()\n {\n return \"Display a form for creating a new catalogue\";\n }", "public function newAction()\n {\n $entity = new Resource();\n $current = $this->get('security.context')->getToken()->getUser();\n $entity->setMember($current);\n $form = $this->createCreateForm($entity);\n\n return array(\n 'nav_active'=>'admin_resource',\n 'entity' => $entity,\n 'form' => $form->createView(),\n );\n }", "public function create()\n {\n return view ('forms.create');\n }", "public function create ()\n {\n return view('forms.create');\n }", "public function create()\n\t{\n\t\treturn view('faith.form');\n\t}", "public function create(NebulaResource $resource): View\n {\n $this->authorize('create', $resource->model());\n\n return view('nebula::resources.create', [\n 'resource' => $resource,\n ]);\n }", "public function create()\n {\n return view(\"request_form.form\");\n }", "public function create()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.create\")) {\n $view = \"admin.{$this->name}.create\";\n } else {\n $view = 'admin.includes.actions.create';\n }\n\n /* Show the form for creating a new resource. */\n return view($view)\n ->with('name', $this->name);\n }", "public function newAction()\n\t{\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => 'Ajouter une nouvelle &eacute;cole'\n\t\t) ) );\n\t}", "public function create()\n {\n return view($this->forms . '.create');\n }", "public function create()\n {\n return view('restful.add');\n }", "public function create()\n {\n $resource = (new AclResource())->AclResource;\n\n //dd($resource);\n return view('Admin.acl.role.form', [\n 'resource' => $resource\n ]);\n }", "public function create()\n {\n return view('admin.createform');\n }", "public function create()\n {\n return view('admin.forms.create');\n }", "public function create()\n {\n return view('backend.student.form');\n }", "public function newAction()\n {\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Nuevo');\n\n $entity = $this->getManager()->create();\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function create()\n {\n return view('client.form');\n }", "public function create()\n {\n // Nos regresa la vista del formulario\n return view('project.form');\n }", "public function create()\n {\n return view('Form');\n }", "public function newAction(){\n \n $entity = new Resourceperson();\n $form = $this->createAddForm($entity);\n\n \n return $this->render('ABCRspBundle:rsp:add.html.twig',array('entity'=>$entity,'form'=> $form->createView()));\n }", "public function createForm()\n\t{\n\t\treturn view('post.new');\n\t}", "public function create()\n {\n return view('admin.form.create', ['form' => new Form]);\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n return view('form');\n }", "public function create()\n {\n $title = $this->title;\n $subtitle = \"Adicionar cliente\";\n\n return view('admin.clients.form', compact('title', 'subtitle'));\n }", "public function create()\n {\n return view('backend.schoolboard.addform');\n }", "public function create()\n\t{\n\t\treturn view('info.forms.createInfo');\n\t}", "public function create()\n {\n //\n return view('form');\n }", "public function create()\n {\n return view('rests.create');\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return $this->showForm();\n }", "public function create()\n {\n return view(\"Add\");\n }", "public function create(){\n return view('form.create');\n }", "public function create()\n {\n // Show the page\n return view('admin.producer.create_edit');\n }", "public function create()\n {\n\n return view('control panel.student.add');\n\n }", "public function newAction() {\n\t\t\n\t\t$this->view->form = $this->getForm ( \"/admin/invoices/process\" );\n\t\t$this->view->title = $this->translator->translate(\"New Invoice\");\n\t\t$this->view->description = $this->translator->translate(\"Create a new invoice using this form.\");\n\t\t$this->view->buttons = array(array(\"url\" => \"#\", \"label\" => $this->translator->translate('Save'), \"params\" => array('css' => null,'id' => 'submit')),\r\n\t\t\t\t\t\t\t array(\"url\" => \"/admin/invoices/list\", \"label\" => $this->translator->translate('List'), \"params\" => array('css' => null)));\n\t\t$this->render ( 'applicantform' );\n\t}", "public function create()\n {\n $data['action'] = 'pengiriman.store';\n return view('pengiriman.form', $data);\n }", "public function create()\n {\n return $this->cView(\"form\");\n }", "public function newAction()\n {\n // Création de l'entité et du formulaire.\n $client = new Client();\n $formulaire = $this->createForm(new ClientType(), $client);\n \n \n \n // Génération de la vue.\n return $this->render('KemistraMainBundle:Client:new.html.twig',\n array('formulaire' => $formulaire->createView()));\n }", "public function create()\n {\n return view(\"dresses.form\");\n }", "public function create()\n\t{\n\t\treturn View::make('new_entry');\n\t}", "public function createAction()\n {\n// $this->view->form = $form;\n }", "public function create()\n {\n return view('bank_account.form', ['mode' => 'create']);\n }", "public function create()\n {\n return view('fish.form');\n }", "public function create()\n {\n return view('users.forms.create');\n }", "public function create()\n {\n $this->setFormFields($this->getCreateFormFields());\n $form = $this->getCreateForm();\n\n return view($this->getViewName('create'), [\n 'crudSlug' => $this->slug,\n 'form' => $form,\n ]);\n }", "public function create()\n\t{\n\t\treturn view('admin.estadoflete.new');\n\t}", "public function create()\n {\n $person = new Person;\n return view('contents.personform')->with(compact('person') );\n }", "public function createAction(){\n \t$this->view->placeholder('title')->set('Create');\n \t$this->_forward('form');\n }", "public function create()\n {\n Gate::authorize('app.products.create');\n\n return view('backend.products.form');\n }", "public function create()\n {\n return view('essentials::create');\n }", "public function create()\n {\n return view('student.add');\n }", "public function create()\n\t{\n\t\treturn view('loisier/create');\n\t}", "public function create()\n {\n return view('url.form');\n }", "public function newAction()\n {\n $entity = new Facture();\n $factureType = new FactureType();\n\t\t$factureType->setUser($this->get('security.context')->getToken()->getUser());\n $form = $this->createForm($factureType, $entity);\n\n return $this->render('chevPensionBundle:Facture:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function newAction()\n {\n $entity = new Chofer();\n $form = $this->createForm(new ChoferType(), $entity, ['user' => $this->getUser()]);\n\n return $this->render('ChoferesBundle:Chofer:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'css_active' => 'chofer',\n ));\n }", "public function create()\n\t{\n\t\treturn View::make('crebos.create');\n\t}", "public function create() : View\n {\n $fieldset = $this->menuFieldset();\n\n return $this->view('create', [\n 'title' => trans('addons.Aardwolf::titles.create'),\n 'data' => [],\n 'fieldset' => $fieldset->toPublishArray(),\n 'suggestions' => [],\n 'submitUrl' => route('aardwolf.postCreate')\n ]);\n }", "public function create()\n {\n return view('libro.create');\n }", "public function create()\n {\n return view('libro.create');\n }", "public function newAction()\n {\n $entity = new Species();\n $form = $this->createForm(new SpeciesType(), $entity);\n\n return $this->render('InfectBackendBundle:Species:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view('crud/add'); }", "public function create()\n\t{\n\t\treturn View::make('supplier.create');\n\t}", "public function newAction()\n {\n $entity = new Company();\n $form = $this->createForm(new CompanyType(), $entity);\n\n return $this->render('SiteSavalizeBundle:Company:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n return view(\"List.form\");\n }", "public function index_onCreateForm()\n\t{\n\t\tparent::create();\n\t\treturn $this->makePartial('create');\n\t}", "public function create()\n {\n //load create form\n return view('products.create');\n }", "public function create()\n {\n return view('article.addform');\n }", "public function create()\n {\n // Mengarahkan ke halaman form\n return view('buku.form');\n }", "public function create()\n\t{\n\t\t// load the create form (app/views/material/create.blade.php)\n\t\t$this->layout->content = View::make('material.create');\n\t}", "public function create()\n {\n return view('saldo.form');\n }", "public function create()\n\t\t{\n\t\t\treturn view('kuesioner.create');\n\t\t}", "public function view_create_questioner_form() {\n \t// show all questioner\n \t// send questioner to form\n \treturn view(\"create_questioner\");\n }", "public function newAction() {\n $entity = new Question();\n $form = $this->createCreateForm($entity);\n\n return $this->render('CdlrcodeBundle:Question:new.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n ));\n }", "public function create()\n {\n $data['companies'] = Company::select('id', 'name')->where('status', 1)->orderBy('id', 'desc')->get();\n return view('admin.outlet.outlet_form', $data);\n }", "public function create()\n {\n return view('admin.inverty.add');\n }", "public function create()\n {\n return view('Libro.create');\n }", "public function create()\n {\n $title = trans('entry_mode.new');\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n $breadcrumb='car.create';\n return view('admin.partials.cars.form', compact('breadcrumb'));\n }", "public function create()\n {\n return view(\"familiasPrograma.create\");\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n {\n return view('admin.car.create');\n }", "public function create()\n\t{\n\t\treturn View::make('perusahaans.create');\n\t}", "public function create()\n {\n return view(\"create\");\n }", "public function create()\n\t{\n //echo 'show form';\n\t\treturn View::make('gaans.create');\n\t}", "public function create()\n {\n $title = trans('dormitorybed.new');\n $this->generateParams();\n\n return view('layouts.create', compact('title'));\n }", "public function create()\n {\n return view('forming');\n }", "public function formNew() {\n $this->data->options = array(\n 'RJ' => 'Rio de Janeiro',\n 'MG' => 'Minas Gerais',\n 'SP' => 'São Paulo',\n 'ES' => 'Espírito Santo',\n 'BA' => 'Bahia',\n 'RS' => 'Rio Grande do Sul'\n );\n $this->data->action = \"@exemplos/pessoa/save\";\n $this->render();\n }", "public function create()\n {\n \t\n \treturn view('supplies.create');\n\n }", "public function createAction()\n {\n if ($form = $this->processForm()) {\n $this->setPageTitle(sprintf($this->_('New %s...'), $this->getTopic()));\n $this->html[] = $form;\n }\n }", "public function create()\n {\n $page_title = \"Add New\";\n return view($this->path.'create', compact('page_title'));\n }", "public function create()\n {\n // not sure what to do with the form since im\n // using ame partial for both create and edit\n return view('plants.create')->with('plant', new Plant);\n }", "public function create() {\n\t\t$title = 'Create | Show';\n\n\t\treturn view('admin.show.create', compact('title'));\n\t}", "public function create()\n {\n return view('student::students.student.create');\n }", "public function newAction(){\n\t\t$entity = new Reserva();\n\t\t$form = $this->createCreateForm($entity);\n\n\t\treturn $this->render('LIHotelBundle:Reserva:new.html.twig', array(\n\t\t\t'entity' => $entity,\n\t\t\t'form' => $form->createView(),\n\t\t));\n\t}" ]
[ "0.75948673", "0.75948673", "0.75863165", "0.7577412", "0.75727344", "0.7500887", "0.7434847", "0.7433956", "0.73892003", "0.73531085", "0.73364776", "0.73125", "0.7296102", "0.7281891", "0.72741455", "0.72424185", "0.7229325", "0.7226713", "0.7187349", "0.7179176", "0.7174283", "0.7150356", "0.71444064", "0.71442676", "0.713498", "0.71283126", "0.7123691", "0.71158516", "0.71158516", "0.71158516", "0.7112176", "0.7094388", "0.7085711", "0.708025", "0.70800644", "0.70571953", "0.70571953", "0.70556754", "0.70396435", "0.7039549", "0.7036275", "0.703468", "0.70305896", "0.7027638", "0.70265305", "0.70199823", "0.7018007", "0.7004984", "0.7003889", "0.7000935", "0.69973785", "0.6994679", "0.6993764", "0.6989918", "0.6986989", "0.6966502", "0.69656384", "0.69564354", "0.69518244", "0.6951109", "0.6947306", "0.69444615", "0.69423944", "0.6941156", "0.6937871", "0.6937871", "0.6936686", "0.69345254", "0.69318026", "0.692827", "0.69263744", "0.69242257", "0.6918349", "0.6915889", "0.6912884", "0.691146", "0.69103104", "0.69085974", "0.69040126", "0.69014287", "0.69012105", "0.6900397", "0.68951064", "0.6893521", "0.68932164", "0.6891899", "0.6891616", "0.6891616", "0.6889246", "0.68880934", "0.6887128", "0.6884732", "0.68822503", "0.68809193", "0.6875949", "0.68739206", "0.68739134", "0.6870358", "0.6869779", "0.68696856", "0.686877" ]
0.0
-1
Store a newly created resource in storage.
public function store(Request $request) { $user = User::find($request->user); foreach($user->playlists as $playlist) if($playlist->id_playlist === $request->playlist){ $playlist->preview_pic = $request->img; $song = new Song(); $song->id_song = $request->id; $song->album = $request->album; $song->img = $request->img; $song->title = $request->titolo; $song->artists = $request->artisti; $song->length = $request->durata; foreach($playlist->songs as $s) if($request->id === $s->id_song) return; $playlist->songs()->associate($song); $playlist->save(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store($data, Resource $resource);", "public function store()\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'storeValidations')) {\n $this->request->validate($this->storeValidations());\n }\n\n /* Create a new resource */\n $resource = $this->model::create(Input::all());\n\n /* Redirect to newly created resource page */\n return redirect()\n ->route($this->name . '.edit', $resource->id)\n ->with(\n 'success',\n Lang::has($this->name . '.resource-created') ?\n $this->name . '.resource-created' :\n 'messages.alert.resource-created'\n );\n }", "public function store(CreateStorageRequest $request)\n {\n $this->storage->create($request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource created', ['name' => trans('product::storages.title.storages')]));\n }", "public function createStorage();", "public function store(StoreStorage $request)\n {\n $storage = Storage::create($request->all());\n $request->session()->flash('alert-success', 'Запись успешно добавлена!');\n return redirect()->route('storage.index');\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function store(Request $request, NebulaResource $resource): RedirectResponse\n {\n $this->authorize('create', $resource->model());\n\n $validated = $request->validate($resource->rules(\n $resource->createFields()\n ));\n\n $resource->storeQuery($resource->model(), $validated);\n\n $this->toast(__(':Resource created', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "function storeAndNew() {\n $this->store();\n }", "public function store(Request $request)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $validator = Validator::make($request->all(), [\n 'content' => 'required|string',\n 'image_link' => 'sometimes|url',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), [], 400);\n }\n\n $resource = new Resource;\n $resource->user_id = $currentUser['id'];\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->image_link = $request->get('imageLink');\n $resource->video_link = $request->get('videoLink');\n $resource->file_link = $request->get('fileLink');\n $resource->audio_link = $request->get('audioLink');\n $resource->tags = collect($request->get('tags'))->implode('text', ',');\n $resource->is_public = 0;\n $resource->save();\n $data['resource'] = $resource;\n\n if ($request->get('programId')) {\n $this->addToProgram($resource, $request->programId);\n // event(new NewLearningPathResourcePublished($resource, $invitee));\n }\n\n User::find($currentUser['id'])->increment('points', 2);\n\n return APIHandler::response(1, \"New resource has been created\", $data, 201);\n }", "public function store()\n {\n if (!$this->id) { // Insert\n $this->insertObject();\n } else { // Update\n $this->updateObject();\n }\n }", "public function store()\n\t{\n\t\t\n\t\t//\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\r\n\t{\r\n\t\t//\r\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}", "public function store()\n\t{\n\t\t//\n\t}" ]
[ "0.72865677", "0.7145327", "0.71325725", "0.6640912", "0.66209733", "0.65685713", "0.652643", "0.65095705", "0.64490104", "0.637569", "0.63736665", "0.63657933", "0.63657933", "0.63657933", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437", "0.6342437" ]
0.0
-1
Display the specified resource.
public function show(Song $song) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n // not available for now\n }", "public function show(Resource $resource)\n {\n //\n }", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "private function showResourceable($resourceable)\n {\n save_resource_url();\n\n return $this->view('resources.create_edit')\n ->with('resource', $resourceable)\n ->with('photos', $resourceable->photos)\n ->with('videos', $resourceable->videos)\n ->with('documents', $resourceable->documents);\n }", "function display($resource_name, $cache_id = null, $compile_id = null) {\n\t\t$this->_getResourceInfo($resource_name); // Saves resource info to a Smarty class var for debugging\n\t\t$_t3_fetch_result = $this->fetch($resource_name, tx_smarty_div::getCacheID($cache_id), $compile_id);\n if ($this->debugging) { // Debugging will have been evaluated in fetch\n require_once(SMARTY_CORE_DIR . 'core.display_debug_console.php');\n $_t3_fetch_result .= smarty_core_display_debug_console(array(), $this);\n }\n\t\treturn $_t3_fetch_result;\n\t}", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function retrieve(Resource $resource);", "public function showResource($resouceable, $id)\n {\n $model_name = str_replace('-', ' ',ucwords($resouceable));\n $model_name = str_replace(' ', '',ucwords($model_name));\n\n $resource_type = 'App\\Models\\\\'.$model_name;\n $model = app($resource_type);\n $model = $model->find($id);\n\n return $this->showResourceable($model);\n }", "public function showAction(Ressource $ressource)\n {\n $deleteForm = $this->createDeleteForm($ressource);\n\n return $this->render('ressource/show.html.twig', array(\n 'ressource' => $ressource,\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show($id)\n {\n $resource = Resource::find($id);\n dd($resource);\n }", "public function displayAction() {\n\t\tif(is_numeric($this->req_id)) {\n\t\t\tAPI::DEBUG(\"[DefaultController::displayAction()] Getting \" . $this->req_id, 1);\n\t\t\t$this->_view->data['info'] = $this->_model->get($this->req_id);\n\t\t\t$this->_view->data['action'] = 'edit';\n\n\t\t} else {\n\t\t\t$this->_view->data['action'] = 'new';\n\t\t}\n\t\t// auto call the hooks for this module/action\n\t\terror_log(\"Should Call: \" . $this->module .\"/\".$this->action.\"/\".\"controller.php\");\n\t\tAPI::callHooks($this->module, $this->action, 'controller', $this);\n\n\t\t$this->addModuleTemplate($this->module, 'display');\n\n\t}", "public function show(NebulaResource $resource, $item): View\n {\n $this->authorize('view', $item);\n\n return view('nebula::resources.show', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function resource(string $resource, string $controller): void\n {\n $base = $this->plural($resource);\n $entity = '/{'.$resource.'}';\n\n $this->app->get($base, $controller.'@index');\n $this->app->post($base, $controller.'@store');\n $this->app->get($base.$entity, $controller.'@show');\n $this->app->patch($base.$entity, $controller.'@update');\n $this->app->delete($base.$entity, $controller.'@destroy');\n }", "function displayCustom($resource_name, $cache_id = null, $compile_id = null)\n\t{\n\t return $this->display(DotbAutoLoader::existingCustomOne($resource_name), $cache_id, $compile_id);\n\t}", "public function show($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.show\")) {\n $view = \"admin.{$this->name}.show\";\n } else {\n $view = 'admin.includes.actions.show';\n }\n\n /* Displays the specified resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function show($id)\n {\n $currentUser = JWTAuth::parseToken()->authenticate();\n $rules = [\n 'id' => 'required|integer'\n ];\n\n $validator = Validator::make(['id' => $id], $rules);\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n $resource = $this->resourceRepository->fetchResource($id);\n $this->resourceRepository->storeView($id, $currentUser['id']);\n\n $data = [\n 'resource' => $resource,\n 'related_resources' => $this->resourceRepository->getResourcesRelatedTo($resource->id, $resource->mentoring_area_id)\n ];\n\n return APIHandler::response(1, \"Show Resource\", $data);\n }", "public function get(Resource $resource);", "public function showAction()\n {\n $model = $this->_getPhotoModel();\n $photo = $model->fetchEntry($this->getRequest()->getParam('id'));\n\n if (null === $photo) {\n return $this->_forward('notfound', 'error');\n }\n\n $this->view->auth = Zend_Auth::getInstance();\n $this->view->title = $photo->title;\n $this->view->photo = $photo;\n }", "public function show($id)\n {\n //\n $data=Resource::find($id);\n return view('resourceDetails',compact('data'));\n }", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "public function show(ShowResourceRequest $request, $id)\n {\n // TODO: Implement show() method.\n }", "function show( $resource ){\n\n $where = \"reservation_status <> 'Pending' AND id = {$resource}\";\n $reservation = where( 'reservations', $where );\n $reservation = $reservation[0];\n\n return view('admin/reservation/preview_reservation', compact( 'reservation' ));\n}", "public function show()\n {\n if ($this->twig !== false) {\n $this->twigDefaultContext();\n if ($this->controller) {\n $this->controller->display($this->data);\n }\n echo $this->twig->render($this->twig_template, $this->data);\n } else {\n $filename = $this->findTemplatePath($this->template);\n require($filename);\n }\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function show(rc $rc)\n {\n //\n }", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function showAction(furTexture $furTexture)\n {\n\n return $this->render('furtexture/show.html.twig', array(\n 'furTexture' => $furTexture,\n ));\n }", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show()\n\t{\n\t\t//\n\t}", "public function show(Resena $resena)\n {\n }", "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function showAction() {\n $docId = $this->getParam('id');\n\n // TODO verify parameter\n\n $document = new Opus_Document($docId);\n\n $this->_helper->layout()->disableLayout();\n\n $this->view->doc = $document;\n $this->view->document = new Application_Util_DocumentAdapter($this->view, $document);\n }", "public function action_display()\r\n\t{\r\n\t\t$event = ORM::factory('event', array('id' => $this->request->param('id')));\r\n\t\r\n\t\tif ( ! $event->loaded())\r\n\t\t{\r\n\t\t\tNotices::error('event.view.not_found');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Can user view this event?\r\n\t\tif ( ! $this->user->can('event_view', array('event' => $event)))\r\n\t\t{\r\n\t\t\t// Error notification\r\n\t\t\tNotices::error('event.view.not_allowed');\r\n\t\t\t$this->request->redirect(Route::url('event'));\r\n\t\t}\r\n\t\t\r\n\t\t// Pass event data to the view class\r\n\t\t$this->view->event_data = $event;\r\n\t\t$this->view->user = $this->user;\r\n\t}", "public function execute()\n {\n // HTTP Request Get\n if ($this->type == \"resource\") {\n $action = $this->getResourceAction();\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n } else {\n $action = $this->Request->action;\n switch ($action) {\n case \"show\":\n $this->show();\n break;\n case \"create\":\n $this->create();\n break;\n case \"edit\":\n $this->edit();\n break;\n case \"destroy\":\n $this->destroy();\n break;\n default:\n echo $this->render();\n break;\n }\n }\n }", "public function show(Resident $resident)\n {\n $this->authorize('admin.resident.show', $resident);\n\n // TODO your code goes here\n }", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function get_resource();", "public function show()\n\t{\n\t\t\n\t}", "function display() {\n\n\t\t// Check authorization, abort if negative\n\t\t$this->isAuthorized() or $this->abortUnauthorized();\n\n\t\t// Get the view\n\t\t$view = $this->getDefaultView();\n\n\t\tif ($view == NULL) {\n\t\t\tthrow new Exception('Display task called, but there is no view assigned to that controller. Check method getDefaultView.');\n\t\t}\n\n\t\t$view->listing = true;\n\n\t\t// Wrap the output of the views depending on the way the stuff should be shown\n\t\t$this->wrapViewAndDisplay($view);\n\n\t}", "public function viewResources()\n {\n $database = new Database();\n\n $resources = $database->getAllActiveResourcesNoLimit();\n\n\n $resourceArray = array();\n $i = 1;\n\n foreach ($resources as $resource) {\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n array_push($resourceArray, $availableResource);\n $i += 1;\n }\n $resourceSize = sizeof($resourceArray);\n $this->_f3->set('resourcesByActive', $resourceArray);\n $this->_f3->set('resourcesSize', $resourceSize);\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function show($id)\n {\n $this->title .= ' show';\n $this->one($id);\n }", "public function display($title = null)\n {\n echo $this->fetch($title);\n }", "public function display(){}", "public function show($id)\n\t{\n\t\t//\n\t\t//\n\t\n\t}", "public function viewAction()\n\t{\n\t\t//get Id param from request\n\t\tif (!$id = $this->_getParam('id')) {\n\t\t\t$this->getFlashMessenger()->addMessage('Product ID was not specified');\n\t\t\t$this->getRedirector()->gotoSimple('list');\n\t\t}\n\n\t\t//fetch requested ProductID from DB\n\t\tif (!$this->_model->fetch($id)) {\n\t\t\t$this->render('not-found');\n\t\t} else {\n\t\t\t$this->view->model = $this->_model;\n\t\t}\n\t}", "public function show($id)\n {\n // Get single person\n $person = Person::findOrFail($id);\n\n // Return single person as a resource\n return '<h1>Person Number '.$id.'</h1><br>'.json_encode(new PersonResource($person));\n }", "#[TODO] use self object?\n\tprotected function GET(ResourceObject $resource) {\n#[TODO]\t\tif ($resource->getMTime())\n#[TODO]\t\t\t$this->response->headers->set('Last-modified', gmdate('D, d M Y H:i:s ', $resource->getMTime()) . 'GMT');\n#[TODO]\t\tif ($resource->getCTime())\n#[TODO]\t\t\t$this->response->headers->set('Date', gmdate('D, d M Y H:i:s ', $resource->getCTime()) . 'GMT');\n\n\n#[TODO] handle file streams\n\t\t// get ranges\n#\t\t$ranges = WebDAV::getRanges($this->request, $this->response);\n\n\t\t// set the content of the response\n\t\tif ($resource instanceof ResourceDocument) {\n\t\t\t$this->response->content->set($resource->getContents());\n\t\t\t$this->response->content->setType($resource->getMIMEType());\n\t\t\t$this->response->content->encodeOnSubmit(true);\n\t\t}\n\t}", "public function display() {\n echo $this->render();\n }", "public function show($id)\n\t{\n\t//\n\t}", "public function show($id)\n\t{\n\t//\n\t}", "function Fetch($resource_name, $cache_id = null, $compile_id = null, $display = false)\n {\n return $this->_smarty->fetch($resource_name, $cache_id, $compile_id, $display);\n }", "public function show($id)\n {\n //\n $this->_show($id);\n }", "public function show()\n\t{\n\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {\n\t\t//\n\t}", "public function show($id) {}", "static public function showCallback(O_Dao_Renderer_Show_Params $params) {\r\n\t\t/* @var $r R_Mdl_Resource */\r\n\t\t$r = $params->record();\r\n\t\t// Setting layout title\r\n\t\t$params->layout()->setTitle($r->getPageTitle());\r\n\r\n?><h1><?=$r->title?></h1><div id=\"resource\"><?\r\n\t\tif($r->getContent()) {\r\n\t\t\t// page has its own content -- show it\r\n\t\t\t$r->getContent()->show($params->layout(), \"content\");\r\n\t\t} else {\r\n\t\t\t// It is a post unit, show all childs\r\n\t\t\tif($r->is_unit == 1) {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"content\");\r\n\r\n\t\t\t// It is a folder with several units, show paginator\r\n\t\t\t} elseif($r->show_def == \"last-units\") {\r\n\t\t\t\tlist($type, $perpage) = explode(\":\", $r->show_def_params);\r\n\t\t\t\t/* @var $p O_Dao_Paginator */\r\n\t\t\t\t$p = $r->addQueryAccessChecks($r->getChilds())->test(\"is_unit\", 1)->getPaginator(array($r, \"getPageUrl\"), $perpage);\r\n\t\t\t\t$p->show($params->layout(), $type);\r\n\t\t\t// It is a folder with subfolders, boxes, contents. Show one childs level\r\n\t\t\t} else {\r\n\t\t\t\t$r->addQueryAccessChecks($r->getChilds(1))->show($params->layout(), \"on-parent-page\");\r\n\t\t\t}\r\n\r\n\t\t}\r\n?></div><?\r\n\t}", "public function show($id)\r\n\t{\r\n\t\t//\r\n\r\n\r\n\r\n\t}", "public function show($resourceId, $eventId)\n {\n $routes = $this->routes;\n\n $eventable = $this->getEventableRepository()->model()->findOrFail($resourceId);\n\n if (method_exists($eventable, 'events')) {\n $event = $eventable->events()->find($eventId);\n\n if ($event) {\n $apiObject = $this->event->findApiObject($event->api_id);\n\n return view('events.eventables.show', compact('routes', 'eventable', 'event', 'apiObject'));\n }\n }\n\n abort(404);\n }", "public abstract function display();", "abstract public function resource($resource);", "public function show($id)\r\r\n\t{\r\r\n\t\t//\r\r\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show( $id ) {\n\t\t//\n\t}", "public function show(Response $response)\n {\n //\n }", "public function show()\n {\n return auth()->user()->getResource();\n }", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}", "public function show($id)\n\t{\n\t\t//\n\t}" ]
[ "0.8233718", "0.8190437", "0.6828712", "0.64986944", "0.6495974", "0.6469629", "0.6462615", "0.6363665", "0.6311607", "0.62817234", "0.6218966", "0.6189695", "0.61804265", "0.6171014", "0.61371076", "0.61207956", "0.61067593", "0.6105954", "0.6094066", "0.6082806", "0.6045245", "0.60389996", "0.6016584", "0.598783", "0.5961788", "0.59606946", "0.5954321", "0.59295714", "0.59182066", "0.5904556", "0.59036547", "0.59036547", "0.59036547", "0.5891874", "0.58688277", "0.5868107", "0.58676815", "0.5851883", "0.58144855", "0.58124036", "0.58112013", "0.5803467", "0.58012545", "0.5791527", "0.57901084", "0.5781528", "0.5779676", "0.5757105", "0.5756208", "0.57561266", "0.57453394", "0.57435393", "0.57422745", "0.5736634", "0.5736634", "0.5730559", "0.57259274", "0.5724891", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5722562", "0.5718969", "0.5713412", "0.57091093", "0.5706405", "0.57057405", "0.5704541", "0.5704152", "0.57026845", "0.57026845", "0.56981397", "0.5693083", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962", "0.5684962" ]
0.0
-1
Show the form for editing the specified resource.
public function edit(Song $song) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function edit(Resource $resource)\n {\n return view('admin.resources.edit', compact('resource'));\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function edit($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Sets the view */\n if (view()->exists(\"admin.{$this->name}.edit\")) {\n $view = \"admin.{$this->name}.edit\";\n } else {\n $view = 'admin.includes.actions.edit';\n }\n\n /* Displays the edit resource page */\n return view($view)\n ->with('resource', $resource)\n ->with('name', $this->name);\n }", "public function edit(NebulaResource $resource, $item): View\n {\n $this->authorize('update', $item);\n\n return view('nebula::resources.edit', [\n 'resource' => $resource,\n 'item' => $item,\n ]);\n }", "public function edit() {\r\n $id = $this->api->getParam('id');\r\n\r\n if ($id) {\r\n $this->model->id = $id;\r\n $this->checkOwner();\r\n }\r\n $object = $this->model->find_by_id($id);\r\n\r\n $this->api->loadView('contact-form', array('row' => $object));\r\n }", "public function viewEditResources()\n {\n $database = new Database();\n $id = $this->_params['id'];\n\n $resource = $database->getResourceById($id);\n\n $availableResource = new Resource($resource['ResourceID'], $resource['ResourceName'], $resource['Description']\n , $resource['ContactName'] , $resource['ContactEmail'] , $resource['ContactPhone'] ,\n $resource['Link'], $resource['active']);\n $this->_f3->set('Resource', $availableResource);\n\n echo Template::instance()->render('view/include/head.php');\n echo Template::instance()->render('view/include/top-nav.php');\n echo Template::instance()->render('view/edit-resources.php');\n echo Template::instance()->render('view/include/footer.php');\n }", "public function edit()\n {\n return view('hirmvc::edit');\n }", "public function editformAction(){\n\t\t$this->loadLayout();\n $this->renderLayout();\n\t}", "public function edit() {\n $id = $this->parent->urlPathParts[2];\n // pass name and id to view\n $data = $this->parent->getModel(\"fruits\")->select(\"select * from fruit_table where id = :id\", array(\":id\"=>$id));\n $this->getView(\"header\", array(\"pagename\"=>\"about\"));\n $this->getView(\"editForm\", $data);\n $this->getView(\"footer\");\n }", "public function edit($id)\n\t{\n\t\treturn $this->showForm('update', $id);\n\t}", "public function edit($id)\n {\n $model = $this->modelObj;\n $formObj = $model::findOrFail($id);\n $data['formObj'] = $formObj;\n return view($this->veiw_base . '.edit', $data);\n }", "public function createEditForm(Resourceperson $entity){\n \n $form = $this->createForm(new ResourcepersonType(), $entity, array(\n 'action' => $this->generateUrl('rsp_update', array('id' => $entity->getRpId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => 'Update','attr'=> array(\n 'class'=>'btn btn primary'\n )));\n\n return $form;\n }", "private function createEditForm(Resource $entity)\n {\n $form = $this->createForm(new ResourceType(), $entity, array(\n 'action' => $this->generateUrl('social_admin_resource_update', array('id' => $entity->getId())),\n 'method' => 'PUT',\n ));\n\n $form->add('submit', 'submit', array('label' => '保存','attr'=>[\n 'class'=>'btn btn-primary'\n ]));\n\n return $form;\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function edit($id)\n {\n return $this->showForm('update', $id);\n }", "public function editAction()\n {\n if ($form = $this->processForm()) {\n if ($this->useTabbedForms && method_exists($this, 'getSubject')) {\n $data = $this->getModel()->loadFirst();\n $subject = $this->getSubject($data);\n $this->setPageTitle(sprintf($this->_('Edit %s %s'), $this->getTopic(1), $subject));\n } else {\n $this->setPageTitle(sprintf($this->_('Edit %s'), $this->getTopic(1)));\n }\n $this->html[] = $form;\n }\n }", "public function edit($id)\n {\n $this->data['entity'] = GS_Form::where('id', $id)->firstOrFail();\n return view('admin.pages.forms.edit', $this->data);\n }", "public function edit($id)\n\t{\n\t\t// get the fbf_presenca\n\t\t$fbf_presenca = FbfPresenca::find($id);\n\n\t\t\n\t\t// show the edit form and pass the fbf_presenca\n\t\t$this->layout->content = View::make('fbf_presenca.edit')\n->with('fbf_presenca', $fbf_presenca);\n\t}", "public function edit($id)\n {\n $data = $this->model->find($id);\n\n return view('admin.backends.employee.form.edit',compact('data'));\n }", "public function edit($model, $form);", "function edit() {\n\t\tglobal $tpl;\n\n\t\t$form = $this->initForm();\n\t\t$tpl->setContent($form->getHTML());\n\t}", "public function edit($id)\n\t{\n\t\t$faith = Faith::find($id);\n \n return view('faith.form')->with('faith', $faith);\n\n\t}", "public function edit()\n { \n return view('admin.control.edit');\n }", "public function edit(Form $form)\n {\n //\n }", "public function edit()\n {\n return view('common::edit');\n }", "public function edit($id)\n {\n $resource = (new AclResource())->AclResource;\n $roleResource = AclRole::where('role', $id)->get(['resource'])->toArray();\n $roleResource = Arr::pluck($roleResource, 'resource');\n return view('Admin.acl.role.form', [\n 'role' => $id,\n 'resource' => $resource,\n 'roleResource' => $roleResource,\n ]);\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\n {\n return view('admin::edit');\n }", "public function edit()\r\n {\r\n return view('petro::edit');\r\n }", "public function edit($id)\n {\n // show form edit user info\n }", "public function edit()\n {\n return view('escrow::edit');\n }", "public function edit($id)\n {\n $resource = ResourceManagement::find($id);\n\n $users = User::get();\n // Redirect to user list if updating user wasn't existed\n if ($resource == null || $resource->count() == 0) {\n return redirect()->intended('/resource-management');\n }\n\n return view('resources-mgmt/edit', ['resource' => $resource, 'users' => $users]);\n }", "public function edit()\n {\n return view('commonmodule::edit');\n }", "public function editAction()\n\t{\n\t\t$params = $this->data->getParams();\n\t\t$params = $this->valid->clearDataArr($params);\n\t\tif (isset($params['id']))\n\t\t{\n\t\t\t$this->employee->setFlag(true);\n\t\t}\n\t\tif (isset($_POST['submit']))\n\t\t{\n\t\t\t$action = $this->valid->clearDataArr($_POST);\n\t\t\t$this->employee->setDataArray($action);\n\t\t\theader('Location: ' . PATH . 'Employee/index/', true, 303);\n\t\t}\n\t\t$employee = $this->employee->setAction('edit');\n\t\t$this->view->addToReplace($employee);\n\t\t$this->listEmployee();\n\t\t$this->arrayToPrint();\n\t}", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit()\n {\n return view('catalog::edit');\n }", "public function edit(form $form)\n {\n //\n }", "public function actionEdit($id) { }", "public function edit()\n {\n return view('admincp::edit');\n }", "public function edit()\n {\n return view('scaffold::edit');\n }", "public function edit($id)\n {\n $header = \"Edit\";\n\t\t$data = Penerbit::findOrFail($id);\n\t\treturn view('admin.penerbit.form', compact('data','header'));\n }", "public function edit()\n {\n return view('Person.edit');\n }", "public function edit($id)\n {\n $data = Form::find($id);\n return view('form.edit', compact('data'));\n }", "public function edit($id)\n\t{\n\t\t$career = $this->careers->findById($id);\n\t\treturn View::make('careers._form', array('career' => $career, 'exists' => true));\n\t}", "public function edit(Flight $exercise, FlightResource $resource)\n {\n return $this->viewMake('adm.smartcars.exercise-resources.edit')\n ->with('flight', $exercise)\n ->with('resource', $resource);\n }", "public function edit($id)\n\t{\n\t\t// get the material\n\t\t$material = Material::find($id);\n\n\t\t// show the edit form and pass the material\n\t\t$this->layout->content = View::make('material.edit')\n\t\t\t->with('material', $material);\n\t}", "public function edit($id, Request $request)\n {\n $formObj = $this->modelObj->find($id);\n\n if(!$formObj)\n {\n abort(404);\n } \n\n $data = array();\n $data['formObj'] = $formObj;\n $data['page_title'] = \"Edit \".$this->module;\n $data['buttonText'] = \"Update\";\n\n $data['action_url'] = $this->moduleRouteText.\".update\";\n $data['action_params'] = $formObj->id;\n $data['method'] = \"PUT\"; \n\n return view($this->moduleViewName.'.add', $data);\n }", "public function edit()\n {\n $id = $this->getId();\n return view('panel.user.form', [\n 'user' => $this->userRepository->findById($id),\n 'method' => 'PUT',\n 'routePrefix' => 'profile',\n 'route' => 'profile.update',\n 'parameters' => [$id],\n 'breadcrumbs' => $this->getBreadcrumb('Editar')\n ]);\n }", "public function edit()\r\n {\r\n return view('mpcs::edit');\r\n }", "function edit()\n\t{\n\t\t// hien thi form sua san pham\n\t\t$id = getParameter('id');\n\t\t$product = $this->model->product->find_by_id($id);\n\t\t$this->layout->set('auth_layout');\n\t\t$this->view->load('product/edit', [\n\t\t\t'product' => $product\n\t\t]);\n\t}", "public function edit($id)\n {\n //\n $data = Diskon::find($id);\n\n $form = $this->form;\n $edit = $this->edit;\n $field = $this->field;\n $page = $this->page;\n $id = $id;\n $title = $this->title;\n return view('admin/page/'.$this->page.'/edit',compact('form','edit','data','field','page','id','title'));\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "public function edit($id)\n {\n return $this->showForm($id);\n }", "protected function _edit(){\n\t\treturn $this->_editForm();\n\t}", "public function editAction()\n {\n $robot = Robots::findFirst($this->session->get(\"robot-id\"));\n if ($this->request->isGet()) {\n $this->tag->prependTitle(\"Редактировать робота :: \");\n $user = $this->session->get(\"auth-id\");\n if (!$robot) {\n $this->flashSession->error(\n \"Робот не найден\"\n );\n return $this->response->redirect(\"users/usershow/$user->name\");\n }\n\n }\n\n $this->view->form = new RobotForm(\n $robot,\n [\n \"edit\" => true,\n ]\n );\n }", "public function editAction()\n {\n $form = new $this->form();\n\n $request = $this->getRequest();\n $param = $this->params()->fromRoute('id', 0);\n\n $repository = $this->getEm()->getRepository($this->entity);\n $entity = $repository->find($param);\n\n if ($entity) {\n\n $form->setData($entity->toArray());\n\n if ( $request->isPost() ) {\n\n $form->setData($request->getPost());\n\n if ( $form->isValid() ) {\n\n $service = $this->getServiceLocator()->get($this->service);\n $service->update($request->getPost()->toArray());\n\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n }\n } else {\n return $this->redirect()->toRoute($this->route, array('controller' => $this->controller));\n }\n\n return new ViewModel(array('form' => $form, 'id' => $param));\n\n }", "public function edit($id)\n\t{\n\t\t$SysApplication = \\Javan\\Dynaflow\\Domain\\Model\\SysApplication::find($id);\n\t\t$form = \\FormBuilder::create('Javan\\Dynaflow\\FormBuilder\\SysApplicationForm', [\n \t'method' => 'POST',\n \t'url' => 'sysapplication/update/'.$id,\n \t'model' => $SysApplication,\n \t'data' => [ 'flow_id' => $SysApplication->flow_id]\n \t]);\n\t\treturn View::make('dynaflow::sysapplication.form', compact('form', 'SysApplication'));\n\t}", "public function editAction() {\n\t\t$id = (int) $this->_getParam('id');\n\t\t$modelName = $this->_getParam('model');\n\t\t\n\t\t$model = Marcel_Backoffice_Model::factory($modelName);\n\t\t$item = $model->find($id)->current();\n\t\tif (!$item) {\n\t\t\t$item = $model->createRow();\n\t\t}\n\t\t$form = $item->getForm();\n\t\tif ($this->_request->isPost()) {\n\t\t\t$newId = $form->populate($this->_request->getPost())->save();\n\t\t\tif ($newId) {\n\t\t\t\t$this->_helper->flashMessenger('Saved successfully!');\n\t\t\t\t$this->_helper->redirector('edit', null, null, array('id' => $newId, 'model' => $modelName));\n\t\t\t}\n\t\t}\n\t\t$this->view->form = $form;\n\t\t$this->view->messages = $this->_helper->flashMessenger->getMessages();\n\t}", "public function edit($id)\n {\n return view('models::edit');\n }", "public function edit()\n {\n return view('home::edit');\n }", "public function editAction()\n {\n $id = $this->params()->fromRoute('id');\n $entity = $this->entityManager->find(Entity\\CourtClosing::class, $id);\n if (! $entity) {\n // to do: deal with it\n }\n $form = $this->getForm('update');\n $form->bind($entity);\n if ($this->getRequest()->isPost()) {\n return $this->post();\n }\n\n return new ViewModel(['form' => $form]);\n }", "public function editAction($id)\n {\n $entity = $this->getManager()->find($id);\n\n $breadcrumbs = $this->get(\"white_october_breadcrumbs\");\n $breadcrumbs->addItem('Inicio', $this->get('router')->generate('admin.homepage'));\n $breadcrumbs->addItem($this->entityDescription, $this->get(\"router\")->generate(\"admin.$this->entityName.index\"));\n $breadcrumbs->addItem('Editar');\n\n if (!$entity) {\n throw $this->createNotFoundException('No se ha encontrado el elemento');\n }\n\n $form = $this->getForm($entity);\n\n return $this->render('AdminBundle:Default:edit.html.twig', array(\n 'entity' => $entity,\n 'form' => $form->createView(),\n 'metadata' => $this->getMetadata()\n ));\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit()\n {\n return view('user::edit');\n }", "public function edit(Form $form)\n {\n return view('admin.forms.edit', compact('form'));\n }", "public function editAction()\n {\n $form = MediaForm::create($this->get('form.context'), 'media');\n $media = $this->get('media_manager.manager')->findOneById($this->get('request')->get('media_id'));\n \n $form->bind($this->get('request'), $media);\n \n return $this->render('MediaManagerBundle:Admin:form.html.twig', array('form' => $form, 'media' => $media));\n }", "public function editAction($id) {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('CdlrcodeBundle:Question')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Question entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('CdlrcodeBundle:Question:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('consultas::edit');\n }", "public function edit(DirectorFormBuilder $form, $id)\n {\n return $form->render($id);\n }", "public function edit()\n {\n return view('dashboard::edit');\n }", "public function edit($id){\n $rfid = Rfid::find($id);\n\n //load form view\n return view('rfids.edit', ['rfid' => $rfid]);\n }", "public function edit($id)\n {\n\n // retrieve provider\n $provider = Provider::findOrFail($id);\n\n // return form with provider\n return view('backend.providers.form')->with('provider', $provider);\n }", "public function edit(Question $question)\n {\n $this->employeePermission('application' , 'edit');\n $question->chooses;\n $action = 'edit';\n return view('admin.setting.question_form', compact('action' , 'question'));\n }", "public function edit() {\n return view('routes::edit');\n }", "public function edit($id)\n {\n $this->data['product'] = Product::find($id);\n $this->data['category'] = Category::arrForSelect();\n $this->data['title'] = \" Update Prouct Details\";\n $this->data['mode'] = \"edit\";\n\n return view('product.form', $this->data);\n }", "public function edit(ClueEnFormBuilder $form, $id): Response\n {\n return $form->render($id);\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('BaseBundle:Feriado')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Feriado entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('BaseBundle:Feriado:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return view('cataloguemodule::edit');\n }", "public function edit($articulo_id)\n {\n $titulo = \"Editar\";\n return View(\"articulos.formulario\",compact('titulo','articulo_id'));\n }", "public function edit($id)\n {\n $resources = User::find(session('usuario_id'))->resources;\n $languages = Language::pluck('name', 'id');\n $types = Type::pluck('name', 'id');\n $method = 'PATCH';\n\n $recurso = Resource::find($id);\n $url = \"/resource/$recurso->id\";\n\n return view('resources.resources', compact('resources', 'languages', 'types', 'method', 'url', 'recurso'));\n }", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit]);\n }", "public function displayEditForm(Employee $employee){\n return view('employee.displayEditForm',['employee'=>$employee]);\n }", "public function edit()\n {\n return view('website::edit');\n }", "public function edit()\n {\n return view('inventory::edit');\n }", "public function edit()\n {\n return view('initializer::edit');\n }", "public function editAction()\n {\n View::renderTemplate('Profile/edit.html', [\n 'user' => $this->user\n ]);\n }", "public function edit($id)\n {\n return view('backend::edit');\n }", "public function edit($id)\n {\n //dd($id);\n $familiaPrograma= FamiliaPrograma::findOrFail($id);\n return view('familiasPrograma.edit', compact('familiaPrograma'));\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n return view('crm::edit');\n }", "public function edit($id)\n {\n $user = User::where('id', $id)->first();\n\n\n return view('users.forms.update', compact('user'));\n }", "public function editAction($id)\n\t{\n\t\t$school = School::find( $id );\n\t\t$this->render( View::make( 'schools/form' , array(\n\t\t\t'title' => sprintf( 'Modifier \"%s\"', $school->name ),\n\t\t\t'entity' => $school\n\t\t) ) );\n\t}", "public function edit(Question $question)\n {\n $edit = TRUE;\n return view('questionForm', ['question' => $question, 'edit' => $edit ]);\n }", "public function edit(Person $person) {\n\t\t$viewModel = new PersonFormViewModel();\n\t\treturn view('person.form', $viewModel);\n\t}", "public function edit($id)\n {\n \t$product = Product::find($id);\n \treturn view('admin.products.edit')->with(compact('product')); // formulario de actualizacion de datos del producto\n }", "public function edit_person($person_id){\n \t$person = Person::find($person_id);\n \treturn view('resource_detail._basic_info.edit',compact('person'));\n }", "public function edit($id)\n {\n $professor = $this->repository->find($id);\n return view('admin.professores.edit',compact('professor'));\n }", "public function edit($id)\n {\n $data = Restful::find($id);\n return view('restful.edit', compact('data'));\n }", "public function editAction($id)\n {\n $em = $this->getDoctrine()->getManager();\n\n $entity = $em->getRepository('MedecinIBundle:Fichepatient')->find($id);\n\n if (!$entity) {\n throw $this->createNotFoundException('Unable to find Fichepatient entity.');\n }\n\n $editForm = $this->createEditForm($entity);\n $deleteForm = $this->createDeleteForm($id);\n\n return $this->render('MedecinIBundle:Fichepatient:edit.html.twig', array(\n 'entity' => $entity,\n 'edit_form' => $editForm->createView(),\n 'delete_form' => $deleteForm->createView(),\n ));\n }", "public function edit($id)\n {\n return $this->form->render('mconsole::personal.form', [\n 'item' => $this->person->query()->with('uploads')->findOrFail($id),\n ]);\n }", "public function edit($id)\n\t{\n\t\t // get the project\n $project = Project::find($id);\n\n // show the edit form and pass the project\n return View::make('logicViews.projects.edit')->with('project', $project);\n\t}" ]
[ "0.78550774", "0.7692893", "0.7273195", "0.7242132", "0.7170847", "0.70622855", "0.7053459", "0.6982539", "0.69467914", "0.6945275", "0.6941114", "0.6928077", "0.69019294", "0.68976134", "0.68976134", "0.6877213", "0.68636996", "0.68592185", "0.68566656", "0.6844697", "0.68336326", "0.6811471", "0.68060875", "0.68047357", "0.68018645", "0.6795623", "0.6791791", "0.6791791", "0.6787701", "0.67837197", "0.67791027", "0.677645", "0.6768301", "0.6760122", "0.67458534", "0.67458534", "0.67443407", "0.67425704", "0.6739898", "0.6735328", "0.6725465", "0.6712817", "0.6693891", "0.6692419", "0.6688581", "0.66879624", "0.6687282", "0.6684741", "0.6682786", "0.6668777", "0.6668427", "0.6665287", "0.6665287", "0.66610634", "0.6660843", "0.66589665", "0.66567147", "0.66545695", "0.66527975", "0.6642529", "0.6633056", "0.6630304", "0.6627662", "0.6627662", "0.66192114", "0.6619003", "0.66153085", "0.6614968", "0.6609744", "0.66086483", "0.66060555", "0.6596137", "0.65950733", "0.6594648", "0.65902114", "0.6589043", "0.6587102", "0.65799844", "0.65799403", "0.65799177", "0.657708", "0.65760696", "0.65739626", "0.656931", "0.6567826", "0.65663105", "0.65660435", "0.65615267", "0.6561447", "0.6561447", "0.65576506", "0.655686", "0.6556527", "0.6555543", "0.6555445", "0.65552044", "0.65543956", "0.65543705", "0.6548264", "0.65475875", "0.65447706" ]
0.0
-1
Update the specified resource in storage.
public function update(Request $request, Song $song) { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function updateShopifyResource() {\n $this->saving();\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'PUT',\n 'DATA' => [\n static::getResourceSingularName() => $this->shopifyData\n ]\n ]);\n }", "public function update(Request $request, Resource $resource)\n {\n $request->validate([\n 'name' => 'required',\n 'description' => 'required|string',\n 'file' => 'required|mimes:jpg,jpeg,png,doc,docx,pdf,ppt,txt',\n ]);\n\n $resource->update($request->all());\n\n if ( $request->hasFile('file') ) {\n $resource = 'resource-'.time().'.'.$request->file('file')->extension();\n $request->file->storeAs('resources', $resource,'public');\n $resource->file = $resource;\n }\n\n if ( $resource->save() ) {\n return redirect()->route('admin.resources.index')->with('success', 'Resource updated');\n } else {\n return redirect()->route('admin.resources.index')->with('error', 'Something went wrong');\n }\n }", "public function update(Request $request, Resource $resource)\n {\n //\n }", "public function updateStream($resource);", "public function update(Request $request, Storage $storage)\n {\n $storage->product_id = $request->product_id;\n $storage->amount = $request->amount;\n\n $storage->save();\n\n return redirect()->route('storages.index');\n }", "protected function updateImageResource($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n $this->deleteResource($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update(Storage $storage, UpdateStorageRequest $request)\n {\n $this->storage->update($storage, $request->all());\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource updated', ['name' => trans('product::storages.title.storages')]));\n }", "public function update(StoreStorage $request, Storage $storage)\n {\n $storage->fill($request->all())->save();\n $request->session()->flash('alert-success', 'Запись успешно обновлена!');\n return redirect()->route('storage.index');\n }", "public function update_asset($id, Request $request){\n \t\tif(!Auth::user()){\n\t\t\treturn redirect('/');\n\t\t}\n \t\t$asset = Storage::find($id);\n \t\t$asset->name = $request->name;\n \t\t$asset->quantity = $request->quantity;\n \t\t$asset->category_id = $request->category;\n \t\tif($request->file('image') != null){\n\t\t\t$image = $request->file('image');\n\t\t\t$image_name = time(). \".\" . $image->getClientOriginalExtension();\n\t\t\t$destination = \"images/\";\n\t\t\t$image->move($destination, $image_name);\n\t\t\t$asset->image_url = $destination.$image_name;\n\t\t} \n\t\t$asset->save();\n\t\tsession()->flash('success_message', 'Item Updated successfully');\n\t\treturn redirect(\"/storage\");\n \t}", "public function update(Request $request, Flight $exercise, FlightResource $resource)\n {\n $request->validate([\n 'display_name' => 'required|string|max:100',\n 'file' => 'nullable|file|max:10240|mimes:pdf',\n 'uri' => 'nullable|url|max:255',\n ]);\n\n if ($resource->type === 'file' && $request->file('file')) {\n Storage::drive('public')->delete($resource->resource);\n $resource->resource = $request->file('file')->store('smartcars/exercises/resources', ['disk' => 'public']);\n } elseif ($resource->type === 'uri' && $request->input('uri')) {\n $resource->resource = $request->input('uri');\n }\n\n $resource->save();\n\n return redirect()->route('adm.smartcars.exercises.resources.index', $exercise)\n ->with('success', 'Resource edited successfully.');\n }", "public function update(Request $request, $id)\n {\n $validator = Validator::make($request->all(), [\n 'title' => 'required|string',\n 'content' => 'required|string',\n 'mentoring_area_id' => 'required|integer',\n 'featured_image_uri' => 'string',\n ]);\n\n if ($validator->fails()) {\n return APIHandler::response(0, $validator->errors(), 400);\n }\n \n $resource = Resource::find($id);\n $resource->title = $request->get('title');\n $resource->content = $request->get('content');\n $resource->featured_image_uri = $request->get('featured_image_uri');\n $resource->updated_at = \\Carbon\\Carbon::now();\n $resource->mentoring_area_id = $request->get('mentoring_area_id');\n $resource->save();\n $data['resource'] = $resource;\n return APIHandler::response(1, \"Resource has been updated\");\n }", "protected function updateVideoResource($fileName, $videoId, $storage, $premium=1)\n {\n //Get video name and storage location for video\n $video = Video::where('id', '=', $videoId)->first();\n\n //Check the storage medium\n if($storage == 'vimeo' || $storage == 'youtube')\n {\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n else\n {\n if($video['storage'] == 'local' || $video['storage'] == 's3')\n {\n //Delete old video\n $this->deleteResource($video->name, $video->storage);\n }\n \n //Store the new video\n $video->name = $fileName;\n $video->storage = $storage;\n $video->premium = $premium;\n $video->save();\n }\n }", "public function put($resource, $with=[]){\n return $this->fetch($resource, self::PUT, $with);\n }", "public function update($id, $resource) {\n SCA::$logger->log(\"update resource\");\n return $this->orders_service->update($id, $resource);\n }", "public function update($path);", "public function update($id, $resource)\n {\n SCA::$logger->log(\"Entering update()\");\n //check whether it is an sdo or an xml string.\n if ($resource instanceof SDO_DataObjectImpl) {\n //if the thing received is an sdo convert it to xml\n if ($this->xml_das !== null) {\n $xml = SCA_Helper::sdoToXml($this->xml_das, $resource);\n } else {\n throw new SCA_RuntimeException(\n 'Trying to update a resource with SDO but ' .\n 'no types specified for reference'\n );\n }\n } else {\n $xml = $resource;\n }\n\n $slash_if_needed = ('/' === $this->target_url[strlen($this->target_url)-1])?'':'/';\n\n $handle = curl_init($this->target_url.$slash_if_needed.\"$id\");\n curl_setopt($handle, CURLOPT_HEADER, false);\n curl_setopt($handle, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($handle, CURLOPT_CUSTOMREQUEST, \"PUT\");\n curl_setopt($handle, CURLOPT_POSTFIELDS, $xml);\n\n //replace with Content-Type: atom whatever\n $headers = array(\"User-Agent: SCA\",\n \"Content-Type: text/xml;\",\n \"Accept: text/plain\");\n curl_setopt($handle, CURLOPT_HTTPHEADER, $headers);\n\n $result = curl_exec($handle);\n\n $response_http_code = curl_getinfo($handle, CURLINFO_HTTP_CODE);\n\n curl_close($handle);\n\n $response_exception = $this->buildResponseException($response_http_code, '200');\n\n if ($response_exception != null) {\n throw $response_exception;\n } else {\n //update does not return anything in the body\n return true;\n }\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'name' => 'required',\n 'link' => 'required',\n 'description' => 'required'\n ]);\n\n $resource = Resource::find($id);\n $resource->name = $request->name;\n $resource->type_id = $request->type_id;\n $resource->has_cost = ($request->has('has_cost')) ? 1 : 0;\n $resource->language_id = $request->language_id;\n $resource->link = $request->link;\n $resource->description = $request->description;\n $resource->tags = '';\n\n $resource->save();\n //return back()->with('success', 'Recurso actualizado satisfactoriamente');\n return redirect('/resource')->with('success', 'Recurso actualizado satisfactoriamente');\n }", "public function update(Request $request, $id)\n {\n $oldProduct = Product::findOrFail($id);\n $data = $request->all();\n if(isset($data['img'])){\n // $file = $request->file('photo');\n // return $file;\n $imgName = time().'.'.$request->img->extension();\n $data['img'] = $imgName;\n // Storage::putFile('spares', $file);\n $path = $request->img->storeAs('public/uploads', $imgName); //in Storage\n\n //delete old file\n if($oldProduct->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$oldProduct->img);\n // return 'deleted';\n }\n \n }else{\n $data['img'] = $oldProduct->img;\n }\n $oldProduct->update($data);\n return redirect()->route('product.index'); \n\n }", "public function update($request, $id) {\n\t\t\t$image = $request['photo'];\n\t\t\tif($image !== null) {\n\t\t\t\t$name = time().'.' . explode('/', explode(':', substr($image, 0, strpos($image, ';')))[1])[1];\n\t\t\t\t\\Image::make($request['photo'])->save(public_path('storage/products/').$name);\n\t\t\t\t$request['photo'] = $name;\n\t\t\t} else {\n\t\t\t\t$currenPhoto = Product::all()->where('id', $id)->first();\n\t\t\t\t$request['photo'] = $currenPhoto->photo;\n\t\t\t}\n return $this->product->update($id, $request);\n\t}", "public function updateStream($path, $resource, Config $config)\n {\n }", "public function edit(Resource $resource)\n {\n //\n }", "public function updateResourceIndex(&$resource) {\n if ($this->connector != null) {\n\n // STEP 1: Update or insert this resource as a node:\n $this->logger->addDebug(\"Updating/Inserting Node into Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} }) SET a.title = {title}, a.version = {version}, a.href = {href}\n return a;\",\n [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n );\n\n // Check to see if anything was added\n $records = $result->getRecords();\n if (empty($records)) {\n // Must create this record instead\n $result = $this->connector->run(\"CREATE (n:Resource) SET n += {infos};\",\n [\n \"infos\" => [\n 'id' => $resource->getID(),\n 'version' => $resource->getVersion(),\n 'title' => $resource->getTitle(),\n 'href' => $resource->getLink()\n ]\n ]\n );\n }\n\n // STEP 2: Update or insert the resource's link to holding repository\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id} })-[r:HIRELATION]->()\n return r;\",\n [\n 'id' => $resource->getID(),\n ]\n );\n $records = $result->getRecords();\n if (!empty($records)) {\n // delete the one there so that we can add the correct one (just in case)\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}})-[r:HIRELATION]->() delete r;\",\n [\n 'id' => $resource->getID()\n ]\n );\n\n }\n\n // If resource has a repository, then add a link\n if ($resource->getRepository() != null && $resource->getRepository()->getID() != null) {\n $this->connector->run(\"MATCH (a:Identity {id: {id1} }) MATCH (b:Resource {id: {id2} }) CREATE (b)-[r:HIRELATION]->(a);\",\n [\n 'id1' => (string) $resource->getRepository()->getID(),\n 'id2' => $resource->getID()\n ]);\n }\n }\n }", "public function update($data) {}", "public function update($data) {}", "public function putStream($resource);", "public function update(Request $request, NebulaResource $resource, $item): RedirectResponse\n {\n $this->authorize('update', $item);\n\n $validated = $request->validate($resource->rules(\n $resource->editFields()\n ));\n\n $resource->updateQuery($item, $validated);\n\n $this->toast(__(':Resource updated', [\n 'resource' => $resource->singularName(),\n ]));\n\n return redirect()->back();\n }", "public function saveShopifyResource() {\n if (is_null($this->getShopifyId())) { // if there is no id...\n $this->createShopifyResource(); // create a new resource\n } else { // if there is an id...\n $this->updateShopifyResource(); // update the resource\n }\n }", "public function update($entity);", "public function update($entity);", "public function setResource($resource);", "public function updateStream($path, $resource, Config $config)\n {\n return $this->upload($path, $resource, $config);\n }", "public function isUpdateResource();", "public function update(Request $request, $id)\n {\n $device = Device::findOrFail($id);\n $device->fill($request->all());\n if ($request->hasFile('icon')) {\n if ($device->hasMedia('icon')) {\n $device->deleteMedia($device->getFirstMedia('icon'));\n }\n $device->addMediaFromRequest('icon')->toMediaCollection('icon');\n }\n $device->save();\n return new DeviceResource($device);\n }", "public function update(Request $request, $id)\n {\n //\n $product = Product::findOrFail($id);\n \n $product->update($request->all());\n \n $file = $request->file('url_image')->move('upload', $request->file('url_image')->getClientOriginalName());\n\n Product::where('id',$id)->update(['url_image'=>$file]);\n \n \\Session::flash('flash_message', 'Edit product successfully.'); \n \n //cũ : return redirect('articles');\n return redirect()->route('products.index');\n }", "public function store($data, Resource $resource);", "public function update(Request $request, $id)\n {\n \n $product = Product::find($id);\n\n\n $product->fill($request->all())->save();\n\n //Verificamos que tenemos una imagen\n if($request->file('photo_1')){\n\n\n //En caso de tenerla la guardamos en la clase Storage en la carpeta public en la carpeta image.\n $path = Storage::disk('public')->put('photo_1',$request->file('photo_1'));\n\n //Actualizamos el Post que acabamos de crear\n $product->fill(['photo_1' => asset($path)])->save();\n\n }\n\n\n return redirect()->route('products.index')->with('info', 'Producto actualizado exitosamente!');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n if (\\Input::hasFile('image')) {\n $this->imgsave($request, $product);\n }\n\n\n if (!empty($request->input('tags'))) {\n $product->tags()->sync($request->input('tags'));\n } else {\n $product->tags()->detach();\n }\n\n $product->update($request->all());\n\n return redirect()->to('dashboard/product')->with('message', 'update success');\n }", "public function put($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'PUT');\n }", "public function update($id)\n {\n /* Check if logged in user is authorized to make this request */\n $this->authorizeAction();\n\n if (method_exists($this, 'updateValidations')) {\n $this->request->validate($this->updateValidations());\n }\n\n /* Get the specified resource */\n $resource = $this->model::findOrFail($id);\n\n /* Update the specified resource */\n $resource->update(Input::all());\n\n /* Redirect back */\n return redirect()->back()\n ->with(\n 'info',\n Lang::has($this->name . '.resource-updated') ?\n $this->name . '.resource-updated' :\n 'messages.alert.resource-updated'\n );\n }", "public function putResponse($request)\n {\n $idSearched = $this->searcher->searchResourceIndex(\n $request, \n $this->db[$request['resource']]\n );\n if ($idSearched) {\n $resource = $this->db[$request['resource']][$idSearched];\n $bodyInput = json_decode($this->standardInput, true);\n $resource = BodyRequest::canApplyBody($bodyInput);\n $resource['id'] = (int)$request['param'];\n foreach($resource as $key => $value) {\n $this->db[$request['resource']][$idSearched][$key] = $value;\n }\n file_put_contents(DB_PATH, json_encode($this->db));\n }\n }", "public function update(Storedataset $request, dataset $dataset){\n $dataset->title = $request->input('title');\n $dataset->caption = $request->input('caption');\n $dataset->file_url = $request->input('file_url');\n $dataset->type = $request->input('type');\n $dataset->status = $request->input('status');\n $dataset->publication_id = $request->input('publication_id');\n\n $dataset->save();\n\n return redirect()->route('datasets.show', ['dataset' => $dataset]);\n }", "public function update(Request $request, $id)\n\n {\n ResourceManagement::findOrFail($id);\n $constraints = [\n 'title' => 'required|max:100',\n 'url'=> 'required|max:191',\n 'content' => 'required'\n ];\n\n $input = [\n 'title' => $request['title'],\n 'url' => $request['url'],\n 'content' => $request['content'],\n 'type' => $request['type'],\n 'level' => $request['level'],\n 'user_id' => $request['user']\n ];\n// $this->validate($input, $constraints);\n ResourceManagement::where('id', $id)\n ->update($input);\n\n return redirect()->intended('/resource-management');\n }", "public function update(Request $request, $id)\n {\n $this->validate($request, [\n 'title' => 'required',\n 'description' => 'required|string',\n 'price' => 'required|numeric',\n 'reference'=>'required'\n ]);\n \n $product = Product::find($id);\n $product->update($request->all());\n \n $im = $request->file('picture');\n \n if (!empty($im)) {\n \n $link = $request->file('picture')->store('images');\n \n \n $product->update([\n 'url_image' => $link,\n ]);\n } \n //dump($request->all());\n return redirect()->route('product.index')->with('message', 'Article modifié avec succès');\n }", "public function update(StoreOrUpdateAsset $request, Asset $asset)\n {\n if (Storage::exists($asset->path) && !Storage::delete($asset->path)) {\n abort(500);\n }\n\n $file = $request->file('file');\n $path = $file->store('assets');\n\n if (!$path) {\n abort(500);\n }\n\n // We wonder if we should delete the old file or not...\n\n $asset->name = $file->getClientOriginalName();\n $asset->size = $file->getSize();\n $asset->type = $file->getMimeType();\n $asset->path = $path;\n\n if ($asset->save()) {\n flash('The asset has been saved.')->success();\n } else {\n abort(500);\n }\n\n return redirect('/admin/assets');\n }", "public function update(FoodRecipeRequest $request, $id)\n {\n $foodRecipe = FoodRecipe::with('ingredients','cookingProcesses')->findOrFail($id);\n if ($request->input('name')!= null)\n $foodRecipe->name = $request->input('name');\n if ($request->input('detail')!= null)\n $foodRecipe->detail = $request->input('detail');\n if($request->file('photo') != null) {\n $old_file = $foodRecipe->photo;\n if($old_file != null){\n $path = public_path().'/storage/'.$old_file;\n File::delete($path);\n }\n $file = $request->file('photo');\n $name = '/foodRecipe/' . Carbon::now()->format(\"dnY-Hisu\") . \".\" . $file->extension();\n $file->storePubliclyAs('public', $name);\n $foodRecipe->photo = $name;\n }\n $foodRecipe->save();\n return new FoodRecipeResource($foodRecipe);\n }", "public function update(StorageTypeRequest $request, $id)\n {\n try {\n $this->service->updateStorageType($request, $id);\n return $this->NoContent();\n } catch (EntityNotFoundException $e) {\n \\Log::error($e->getMessage());\n return $this->NotFound($e->getMessage());\n } catch(\\QueryException $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n } catch(Exception $e) {\n \\Log::error($e->getMessage());\n return $this->ServerError();\n }\n }", "public function update(Request $request, $id)\n {\n //validation\n $this->validate(request(),[\n 'image' => 'image'\n ]);\n\n $slider = HomeSliders::find($id);\n \n $slider->link = request('link');\n\n //get old image to delete if updated\n $oldImage = request('oldImage');\n //get the new image\n $NewImage=$request->file('image');\n\n if($NewImage)\n {\n $filenameToStore= helpers::updatePhoto('image','homeSliders',$request);\n $slider->image=$filenameToStore;\n\n Storage::delete('public/Images/homeSliders/'.$oldImage);\n }\n\n $slider->save();\n\n Alert::success(config('app.name'), trans('messages.Updated Successfully') );\n return redirect()->route('admin.homeSlider',$slider->type);\n }", "public function update(Qstore $request, $id)\n {\n //\n }", "public function update(IEntity $entity);", "protected function performUpdate(): bool\n {\n // Abort if resource does not support update operations\n if (!$this->isUpdatable()) {\n throw new UnsupportedOperation(sprintf('API does not support update operation for %s resources', $this->resourceNameSingular()));\n }\n\n $id = $this->id();\n $prepared = $this->prepareBeforeUpdate($this->toArray());\n\n $payload = [\n $this->resourceNameSingular() => $prepared\n ];\n\n $response = $this\n ->request()\n ->put($this->endpoint($id), $payload);\n\n // Extract and (re)populate resource (if possible)\n // Note: Unlike the \"create\" method, Redmine does NOT\n // appear to send back a full resource when it has been\n // successfully updated.\n $this->fill(\n $this->decodeSingle($response)\n );\n\n return true;\n }", "public function update($request, $id);", "function put($resource, $data = null) {\r\n\t\t\r\n\t\tif(isset($data)) {\r\n\t\t\t$this->request_body = $data;\r\n\t\t}\r\n\r\n\t\t// make the call chief\r\n\t\t$this->exec ( \"PUT\", '/' . $resource );\r\n\r\n\t\t// check the request status\r\n\t\tif($this->status_code != 200){\r\n\t\t\t$this->Logger->error(\r\n\t\t\t\tsprintf(\r\n\t\t\t\t\t'GET Call for resource \\'%s\\' Failed.\r\n\t\t\t\t\tStatus: %d,\r\n\t\t\t\t\tRequest: %s\r\n\t\t\t\t\tAPI Error Message: \r\n\t\t\t\t\t%s',\r\n\t\t\t\t\t$resource,\r\n\t\t\t\t\t$this->status_code,\r\n\t\t\t\t\t$this->request_body_raw,\r\n\t\t\t\t\t$this->response_body\r\n\t\t\t\t)\r\n\t\t\t);\r\n\t\t\tthrow new Exception($this->response_body);\r\n\t\t} else {\r\n\t\t\treturn $this->response_parsed;\r\n\t\t}\r\n\t}", "public function updateEntities($resource)\n {\n $json = [\n 'resource' => $resource,\n ];\n $request = $this->createRequest('PUT', '/entities', ['json' => $json]);\n $response = $this->send($request);\n return $response;\n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->writeStream($path, $resource, $config);\n }", "public function update(Request $request, $id)\n {\n\n $product = Product::findOrFail($id);\n $product->name = $request['name'];\n $product->price = $request['price'];\n $product->stock = $request['stock'];\n $product->description = $request['description'];\n\n $file = $request->file('image');\n $fileName = $file->getClientOriginalName();\n if($fileName != $product->image){\n $request->file('image')->move('images/',$fileName);\n $product->image = $fileName;\n }\n\n $product->save();\n\n return redirect()->route('products.show',\n $product->id)->with('flash_message',\n 'Article, '. $product->name.' updated');\n }", "protected function handleUpdate()\n {\n $resource = $this->argument('resource');\n $action = $this->option('action');\n $startPage = (int)$this->option('startPage');\n $perPage = (int)$this->option('perPage');\n\n try {\n $harvest = Harvest::where('resource', $resource)->where('action', $action)->firstOrFail();\n } catch (\\Exception $e) {\n $this->info('There is no existing action for updating ' . ucwords($action) . ' ' . ucwords($resource) . '.');\n exit('Nothing was updated.');\n }\n\n $options = [\n 'startPage' => $startPage,\n 'perPage' => $perPage,\n 'lastRun' => $harvest->last_run_at\n ];\n\n // If a lastRun was given use that\n // OR if this has never been run before use 2001-01-01\n if (!empty($this->option('lastRun'))) {\n $options['lastRun'] = new Carbon($this->option('lastRun'));\n } elseif (is_null($options['lastRun'])) {\n $options['lastRun'] = new Carbon('2001-01-01');\n }\n\n $job = new UpdateResourceJob(\n $harvest,\n $options\n );\n\n $message = 'Updating ' . $action . ' ' . $resource . ' ' . $perPage . ' at a time';\n if (isset($lastRun)) {\n $message .= ' with entries updated since ' . $lastRun->format('r');\n }\n $this->info($message);\n $this->dispatch($job);\n }", "abstract public function put($data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function update($id, $data);", "public function testUpdateSupplierUsingPUT()\n {\n }", "public function update(Request $request, $id)\n {\n $storageplace = Storageplace::findOrFail($id);\n $storageplace->update($request->only(['storageplace']));\n return $storageplace;\n }", "public function updateRelatedImage(Request $request, $id)\n {\n // Delete display image in Storage\n Validator::make($request->all(), ['photos' => \"required|file|image|mimes:jpg,png,jpeg|max:5000\"])->validate();\n\n\n if ($request->hasFile(\"photos\")) {\n\n $photo = ProductsPhoto::find($id);\n $imageName = $photo->photos;\n $exists = Storage::disk('local')->exists(\"public/product_images/\" . $photo->photos);\n\n //delete old image\n if ($exists) {\n Storage::delete('public/product_images/' . $imageName);\n }\n\n //upload new image\n $ext = $request->file('photos')->getClientOriginalExtension(); //jpg\n\n $request->photos->storeAs(\"public/product_images/\", $imageName);\n\n $arrayToUpdate = array('photos' => $imageName);\n DB::table('products_photos')->where('id', $id)->update($arrayToUpdate);\n\n return redirect()->route(\"adminDisplayRelatedImageForm\", ['id' => $photo->product_id]);\n } else {\n\n $error = \"NO Image was Selected\";\n return $error;\n }\n }", "public function update(Request $request, $id)\n {\n $skill = Skill::findOrFail($id);\n\n $skill->skill = $request->skill;\n\n if ($request->hasFile('image')) {\n \\Cloudder::upload($request->file('image'));\n $c=\\Cloudder::getResult();\n // $image = $request->file('image');\n // $filename = time() . '.' . $image->getClientOriginalExtension();\n // $location = public_path('images/' . $filename);\n // Image::make($image)->save($location);\n\n $skill->image = $c['url'];\n }\n\n $skill->save();\n\n Session::flash('success', 'Successsfully updated your skill!');\n return redirect()->route('skills.index');\n }", "public function updateStream($path, $resource, Config $config = null)\n {\n $contents = stream_get_contents($resource);\n\n return $this->write($path, $contents, $config);\n }", "public abstract function update($object);", "public static function update($id, $file)\n {\n Image::delete($id);\n\n Image::save($file);\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n $image = $product->image;\n if($request->hasFile('image')){\n $image = $request->file('image')->store('files');\n \\Storage::delete($product->image);\n } \n $product->name = $request->get('name');\n $product->price = $request->get('price');\n $product->description = $request->get('description');\n $product->additional_info = $request->get('additional_info');\n $product->category_id = $request->get('category');\n $product->subcategory_id = $request->get('subcategory');\n $product->image = $image;\n $product->save();\n return redirect()->back();\n }", "public function update(Request $request, $id)\n {\n $sli=Slider::find($id);\n $sli->sort_order=$request->input('sort_order');\n $image = $request->file('slider');\n if($image == ''){\n $image = $sli->slider;\n }else{\n $image = base64_encode(file_get_contents($request->file('slider')));\n }\n $sli->slider = $image;\n $sli->save();\n return redirect()->back();\n }", "public function update(ProductRequest $request, $id)\n {\n $input = Product::find($id);\n $data = $request->all();\n if ($file = $request->file('product_photo')){\n $name = time().$file->getClientOriginalName();\n $file->move('product_image',$name);\n $data['product_photo']=$name;\n// $input->update($data);\n }\n $input->update($data);\n return redirect('admin/products/');\n }", "public function update(Request $request, $id)\n {\n $volume = $this->findVolume($id);\n\n if(count($volume) > 0) {\n $volume->str_volume_name = $request->str_volume_name;\n\n $volume->save();\n }\n\n return response()\n ->json(\n array(\n 'message' => 'Volume is successfully updated.',\n 'volume' => $volume\n ),\n 201\n );\n }", "public function update(Request $request, $id)\n {\n $product = ProductModel::find($id);\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->stock = $request->stock;\n\n if($request->image!=null){\n $imageName = time().'.'.$request->image->extension();\n $request->image->move(public_path('images'), $imageName);\n $product->image = \"/images/\".$imageName;\n }\n $product->save();\n return redirect(\"/products/index\")->with('success','Product has been updated');\n }", "public function update()\n {\n $accessory = Accessories::find(request('id'));\n\n if ($accessory == null) {\n return response()->json([\"error\" => \"aksesuaras nerastas\"], 404);\n }\n\n $this->validateData();\n $path = $accessory->src;\n\n if (request()->hasFile('src')) {\n\n if (Storage::disk('public')->exists($accessory->src)) {\n Storage::disk('public')->delete($accessory->src);\n }\n $path = request()->file('src')->store('accessoriesImages', 'public');\n }\n\n $accessory->update(array_merge($this->validateData(), ['src' => $path]));\n\n return response()->json([\"data\" => $accessory], 200);\n }", "public function update(ProductStoreRequest $request,$id)\n {\n $data = $request->validated();\n $product = Product::where('id',$id);\n $product->update($data);\n return response(\"Producto actualizado con éxito\",200);\n }", "public function update($entity)\n {\n \n }", "public function updateStream($path, $resource, Config $config)\n {\n return $this->write($path,stream_get_contents($resource),$config);\n }", "public function update($id, Request $request)\n {\n date_default_timezone_set('Asia/Taipei');\n $data = $request->all();\n $dbData = Product::find($id);\n $myfile = Storage::disk('local');\n if ($request->hasFile('img')) {\n $file = $request->file('img');\n $path = $myfile->putFile('public', $file);\n $data['img'] = $myfile->url($path);\n File::delete(public_path($dbData->img));\n }\n $dbData->update($data);\n\n if ($request->hasFile('imgs')) {\n // $this->fetchDestroyByProdId($id);\n $localS = Storage::disk('local');\n\n $fileS = $request->file('imgs');\n $imgs = [];\n foreach ($fileS as $i) {\n $pathS = $localS->putFile('public', $i);\n $imgs[] = $localS->url($pathS);\n }\n foreach ($imgs as $img) {\n ProductImg::create([\n 'product_id' => $id,\n 'img' => $img\n ]);\n }\n }\n\n return redirect()->route('admin');\n }", "public function update(Request $request, Product $product)\n { $remfile= $product->image;\n if($request->filep){\n $product->image=$request->filep;\n File::delete(storage_path('app/public/products/'.$remfile));\n }else{\n $product->image=$remfile;\n }\n //rmdir(storage_path('app/public/products/'.$remfile));\n $product->name = $request->name;\n $product->description = $request->description;\n $product->price = $request->price;\n $product->save();\n sleep(3);\n toast('Details updated successfully','info');\n return redirect('/products');\n }", "public function update($id, $input);", "public function update(ProductRequest $request,int $id): ProductResource\n {\n $attributes = $request->only('supplier_id', 'name', 'warehouses');\n\n return new ProductResource($this->productRepository->update($id, $attributes)); }", "public function update(Request $request, $id)\n {\n $slider=new Slider;\n $slider=$slider::find($id);\n \n \n if($file =$request->file('slider')){\n if(Storage::delete('public/slider/'.$slider->slider)){\n\n //Get file original name//\n \n$original_name=$file->getClientOriginalName();\n\n //Get just the file name\n$filename=pathinfo($original_name,PATHINFO_FILENAME);\n\n//Create new file name\n$name=$filename.'_'.time().'.'.$file->getClientOriginalExtension();\n\n $destination='public/slider';\n $path=$request->slider->storeAs($destination,$name);\n $slider->slider=$name;\n $slider->save();\n return redirect('Admin/slider');\n\n }\n }\n}", "public function update(Request $request, $id)\n {/* dd($request->all()); */\n $acheivePic = $this->acheiveRepo->find($id);\n $acheive = $request->except('_method', '_token', 'photo', 'ar', 'en');\n $acheiveTrans = $request->only('ar', 'en');\n\n if ($request->hasFile('icon')) {\n // Delete old image first.\n $oldPic = public_path() . '/images/acheives/' . $acheivePic->icon;\n File::delete($oldPic);\n\n // Save the new one.\n $image = $request->file('icon');\n $imageName = $this->upload($image, 'acheives');\n $acheive['icon'] = $imageName;\n }\n\n $this->acheiveRepo->update($id, $acheive, $acheiveTrans);\n\n return redirect('admin-panel/widgets/acheive')->with('updated', 'updated');\n }", "public function update(Request $request, $id)\n {\n $data = $request->all();\n extract($data);\n\n $productVarient = new ProductVariant();\n $productVarient = $productVarient->find($id);\n $productVarient->vendor_id = auth()->user()->id;\n $productVarient->description = $prod_desc;\n $productVarient->price = $price;\n\n if(request()->hasFile('photo')){\n $image = request()->file('photo')->getClientOriginalName();\n $imageNewName = auth()->user()->id.'-'.$image;\n $file = request()->file('photo');\n $file->storeAs('images/product',$imageNewName, ['disk' => 'public']);\n $productVarient->image = $imageNewName;\n }\n \n $productVarient->save();\n\n return back()->withStatus(__('Product successfully updated.'));\n }", "public function update(Request $request, $id)\n {\n //if upload new image, delete old image\n $myfile=$request->old_photo;\n if($request->hasfile('photo'))\n {\n $imageName=time().'.'.$request->photo->extension();\n $name=$request->old_photo;\n\n if(file_exists(public_path($name))){\n unlink(public_path($name));\n $request->photo->move(public_path('backendtemplate/truefalseimg'),$imageName);\n $myfile='backendtemplate/truefalseimg/'.$imageName;\n }\n }\n //Update Data\n $truefalsequestion=TrueFalseQuestion::find($id);\n $truefalsequestion->name=$request->name;\n $truefalsequestion->photo=$myfile;\n $truefalsequestion->answer = $request->answer;\n $truefalsequestion->question_id = $request->question;\n $truefalsequestion->save();\n\n //Redirect\n return redirect()->route('truefalsequestions.index'); \n }", "public function update($id);", "public function update($id);", "private function update()\n {\n $this->data = $this->updateData($this->data, $this->actions);\n $this->actions = [];\n }", "public function put($path, $data = null);", "public function update(Request $request, $id)\n {\n $request->validate([\n 'path_image'=>'image',\n 'status'=>'required|in:0,1'\n ]);\n $slider=Slider::whereId($id)->first();\n if (is_null($slider)){\n return redirect()->route('sliders.index')->with('error','Slider does not exist');\n }\n try {\n if ($request->hasFile('path_image')){\n $file = $request->file('path_image');\n\n $image_path= $file->store('/sliders',[\n 'disk'=>'uploads'\n ]);\n Storage::disk('uploads')->delete($slider->image);\n\n $request->merge([\n 'image'=>$image_path,\n ]);\n }\n\n $slider->update( $request->only(['status','image']));\n return redirect()->route('sliders.index')->with('success','Updated successful');\n }catch (\\Exception $exception){\n return redirect()->route('sliders.index')->with(['error'=>'Something error try again']);\n\n }\n }", "public function update() {\n $this->accessory->update($this->accessory_params());\n\n if ($this->accessory->is_valid()) {\n $this->update_accessory_image($this->accessory);\n redirect('/backend/accessories', ['notice' => 'Successfully updated.']);\n } else {\n redirect(\n '/backend/accessories/edit',\n ['error' => $this->accessory->errors_as_string()],\n ['id' => $this->accessory->id]\n );\n }\n }", "public function update(Entity $entity);", "public function update(Request $request, $id)\n {\n $icon = SliderIcon::find($id);\n $data = $request->all();\n $data['active'] = $request->has('active') ? 1 : 0;\n if ($request->hasFile('img')) {\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $image = $request->file('img');\n $fileName = time().'_'.Str::lower(Str::random(5)).'.'.$image->getClientOriginalExtension();\n $path_to = '/upload/images/'.getfolderName();\n $image->storeAs('public'.$path_to, $fileName);\n $data['img'] = 'storage'.$path_to.'/'.$fileName;\n }\n $icon->update($data);\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества обнавлены');\n }", "public function update() {\n\t $this->layout = false;\n\t \n\t //set default response\n\t $response = array('status'=>'failed', 'message'=>'HTTP method not allowed');\n\t \n\t //check if HTTP method is PUT\n\t if($this->request->is('put')){\n\t //get data from request object\n\t $data = $this->request->input('json_decode', true);\n\t if (empty($data)) {\n\t $data = $this->request->data;\n\t }\n\t \n\t //check if product ID was provided\n\t if (!empty($data['id'])) {\n\t \n\t //set the product ID to update\n\t $this->Player->id = $data['id'];\n\t if ($this->Player->save($data)) {\n\t $response = array('status'=>'success','message'=>'Product successfully updated');\n\t } else {\n\t $response['message'] = \"Failed to update product\";\n\t }\n\t } else {\n\t $response['message'] = 'Please provide product ID';\n\t }\n\t }\n\t \n\t $this->response->type('application/json');\n\t $this->response->body(json_encode($response));\n\n\t return $this->response->send();\n\t}", "public function update(Request $request, $id)\n {\n //validate incoming request\n $request->validate([\n 'name' => 'string|max:100|nullable',\n 'picture' => 'max:2000|mimes:jpeg,jpg,png,svg|nullable', //max size 2mb,\n 'total' => 'integer|min:0|nullable', //value must be > 0\n 'selling_price' => 'numeric|min:0|nullable',\n 'cost_price' => 'numeric|min:0|nullable',\n 'category_id' => 'integer|nullable'\n ]);\n\n try {\n $product = Auth::user()->store->product()->findorFail($id);\n } catch (ModelNotFoundException $e) {\n return response()->json([\n \"message\" => \"Forbidden\"\n ], 403);\n }\n\n //if category id isnt null\n if ($category_id = $request->category_id) {\n if (!$this->isCategoryIdValid($category_id))\n return response()->json([\n \"message\" => \"Category Id is not valid\"\n ], 422);\n else\n $product->category_id = $request->category_id;\n }\n\n //if uploaded file exist\n if ($picture = $request->file(\"picture\")) {\n //if product already has logo\n if ($product->picture)\n Storage::delete(Product::$PICTURE_PATH . \"/\" . $product->picture);\n\n $picture_path = $picture->store(Product::$PICTURE_PATH);\n //remove folder name from path\n $product->picture = str_replace(Product::$PICTURE_PATH . \"/\", '', $picture_path);\n }\n\n $this->renewProduct($product, $request);\n $product->save();\n return response()->json(new ProductResource($product), 200);\n }", "public function update(Request $request, $id)\n {\n $request->validate([\n 'name' => 'required | min:3 | string',\n 'type' => 'required',\n 'producer' => 'required',\n 'image' => 'image | mimes:png,jpg,jpeg',\n 'price_input' => 'required | numeric | min:0 | max:300000000',\n 'promotion_price' => 'required | numeric | max:300000000',\n 'description' => 'required | string',\n\n ]);\n $product = Product::withTrashed()->findOrfail($id);\n $product->name = $request->name;\n $product->id_type = $request->type;\n $product->id_producer = $request->producer;\n\n $product->amount = $request->amount;\n if (request('image')) {\n $product->image = base64_encode(file_get_contents($request->file('image')->getRealPath()));\n }\n\n $product->price_input = $request->price_input;\n\n if ( $request->promotion_price >= 0 && $request->promotion_price < $product->price_input) {\n $product->promotion_price = $request->promotion_price;\n }else{\n return back()->with('error', '\n Do not enter a negative number');\n }\n $product->new = $request->new;\n\n $product->description = $request->description;\n\n $product->save();\n $product->size()->sync(request('size'));\n\n return redirect()->route('product.index')->with('success', 'Product Updated successfully');\n }", "public function update(Request $request, $id)\n {\n $product = Product::find($id);\n\n $product->name = $request->input('name');\n $product->description = $request->input('description');\n $product->lastPrice = $product->price !== $request->input('price') ? $product->price : NULL;\n $product->price = $request->input('price');\n\n if ($request->hasFile('image')) { \n $currentImg = $product->image;\n if ($currentImg) {\n Storage::delete('/public/' . $currentImg);\n }\n $image = $request->file('image'); \n $path = $image->store('images','public');\n $product->image = $path;\n };\n\n $product->save(); \n\n $product_promotions = $request->input('promotion');\n\n $product->promotions()->sync($product_promotions);\n\n return redirect()->route('admin.modify');\n }", "public static function updateImage($fileName, $imageId, $storage)\n {\n //Get image name and storage location for image\n $image = Image::where('id', '=', $imageId)->first();\n\n //Delete old image\n ResourceHandler::delete($image->name, $image->storage);\n\n //Store the new image\n $image->name = $fileName;\n $image->storage = $storage;\n\n $image->save();\n }", "public function update($request, $id)\n {\n $this->checkExits($id);\n $data = $request->except(['_method','_token','photo']);\n\n if($request->photo)\n {\n try {\n $this->UploadFile($request);\n } catch (\\Exception $e) {\n //if has exception , don't has action\n }\n if ($this->img !== '') {\n $data['img'] = $this->img;\n }\n }\n\n $this->object->update($data);\n\n }", "public function updateProduct($request, $product)\n {\n $product->update($request->except(['_token', '_method', 'image']));\n if ($request->hasFile('image')) {\n $image = $request->file('image');\n $imageName = time() . '.' . $request->file('image')->extension();\n // $img = Image::make('public/foo.jpg');\n\n $image_resize = Image::make($image->getRealPath());\n $image_resize->resize(500, 500);\n $image_resize->save(public_path('images/') . $imageName, 100);\n $product->gallery = $imageName;\n $product->save();\n }\n $product->getTags()->sync($request->input('tags'));\n }" ]
[ "0.7425105", "0.70612276", "0.70558053", "0.6896673", "0.6582159", "0.64491373", "0.6346954", "0.62114537", "0.6145042", "0.6119944", "0.61128503", "0.6099993", "0.6087866", "0.6052593", "0.6018941", "0.60060275", "0.59715486", "0.5946516", "0.59400934", "0.59377414", "0.5890722", "0.5860816", "0.5855127", "0.5855127", "0.58513457", "0.5815068", "0.5806887", "0.57525045", "0.57525045", "0.57337505", "0.5723295", "0.5714311", "0.5694472", "0.5691319", "0.56879413", "0.5669989", "0.56565005", "0.56505877", "0.5646085", "0.5636683", "0.5633498", "0.5633378", "0.5632906", "0.5628826", "0.56196684", "0.5609126", "0.5601397", "0.55944353", "0.5582592", "0.5581908", "0.55813426", "0.5575312", "0.55717176", "0.55661047", "0.55624634", "0.55614686", "0.55608666", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55599797", "0.55573726", "0.5556878", "0.5554201", "0.5553069", "0.55530256", "0.5543788", "0.55435944", "0.55412996", "0.55393505", "0.55368495", "0.5535236", "0.5534954", "0.55237365", "0.5520468", "0.55163723", "0.55125296", "0.5511168", "0.5508345", "0.55072427", "0.5502385", "0.5502337", "0.5501029", "0.54995877", "0.54979175", "0.54949397", "0.54949397", "0.54946727", "0.5494196", "0.54941916", "0.54925025", "0.5491807", "0.5483321", "0.5479606", "0.5479408", "0.5478678", "0.54667485", "0.5463411", "0.5460588", "0.5458525" ]
0.0
-1
Remove the specified resource from storage.
public function destroy(Song $song) { // }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete($resource){\n return $this->fetch($resource, self::DELETE);\n }", "public function destroy(Resource $resource)\n {\n //\n }", "public function removeResource($resourceID)\n\t\t{\n\t\t}", "public function unpublishResource(PersistentResource $resource)\n {\n $client = $this->getClient($this->name, $this->options);\n try {\n $client->delete(Path::fromString($this->getRelativePublicationPathAndFilename($resource)));\n } catch (FileDoesNotExistsException $exception) {\n }\n }", "public function deleteResource(&$resource) {\n\n if ($this->connector != null) {\n $this->logger->addDebug(\"Deleting Resource Node from Neo4J database\");\n $result = $this->connector->run(\"MATCH (a:Resource {id: {id}}) detach delete a;\",\n [\n 'id' => $resource->getID()\n ]\n );\n $this->logger->addDebug(\"Updated neo4j to remove resource\");\n }\n\n }", "public function deleteShopifyResource() {\n $this->getShopifyApi()->call([\n 'URL' => API::PREFIX . $this->getApiPathSingleResource(),\n 'METHOD' => 'DELETE',\n ]);\n }", "public function deleteResource()\n {\n $database = new Database();\n $id = $this->_params['id'];\n $database->deleteResource($id);\n $this->_f3->reroute('/Admin');\n }", "protected function deleteResource($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function delete()\n {\n persistableCollection::getInstance($this->resourceName)->deleteObject($this);\n }", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove()\n {\n if (! ftruncate($this->fileHandle, 0)) {\n throw new StorageException(\"Could not truncate $this->path\");\n }\n if (! unlink($this->path)) {\n throw new StorageException(\"Could not delete $this->path\");\n }\n }", "public function delete()\n\t{\n\t\t$s3 = AWS::createClient('s3');\n $s3->deleteObject(\n array(\n 'Bucket' => $this->bucket,\n 'Key' => $this->location\n )\n );\n\t\tif($this->local_file && file_exists($this->local_file)) {\n\t\t\tunlink($this->local_file);\n\t\t}\n $this->local_file = null;\n\t}", "public function delete()\n\t{\n\t\tsfCore::db->query(\"DELETE FROM `swoosh_file_storage` WHERE `id`='%i';\", $this->id);\n\t\t$this->fFile->delete();\n\t}", "public function delete(): void\n {\n unlink($this->getPath());\n }", "public function delete()\n {\n if($this->exists())\n unlink($this->getPath());\n }", "public function remove($path);", "function deleteFileFromStorage($path)\n{\n unlink(public_path($path));\n}", "public function delete(): void\n {\n unlink($this->path);\n }", "private function destroyResource(DrydockResource $resource) {\n $blueprint = $resource->getBlueprint();\n $blueprint->destroyResource($resource);\n\n $resource\n ->setStatus(DrydockResourceStatus::STATUS_DESTROYED)\n ->save();\n }", "public static function delete($fileName, $storage)\n {\n if (Storage::disk($storage)->exists($fileName)) \n {\n return Storage::disk($storage)->delete($fileName);\n }\n }", "public function remove() {}", "public function remove() {}", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "function delete_resource($resource_id, $page)\n\t{\n\t\t//get resource data\n\t\t$table = \"resource\";\n\t\t$where = \"resource_id = \".$resource_id;\n\t\t\n\t\t$this->db->where($where);\n\t\t$resource_query = $this->db->get($table);\n\t\t$resource_row = $resource_query->row();\n\t\t$resource_path = $this->resource_path;\n\t\t\n\t\t$image_name = $resource_row->resource_image_name;\n\t\t\n\t\t//delete any other uploaded image\n\t\t$this->file_model->delete_file($resource_path.\"\\\\\".$image_name, $this->resource_path);\n\t\t\n\t\t//delete any other uploaded thumbnail\n\t\t$this->file_model->delete_file($resource_path.\"\\\\thumbnail_\".$image_name, $this->resource_path);\n\t\t\n\t\tif($this->resource_model->delete_resource($resource_id))\n\t\t{\n\t\t\t$this->session->set_userdata('success_message', 'resource has been deleted');\n\t\t}\n\t\t\n\t\telse\n\t\t{\n\t\t\t$this->session->set_userdata('error_message', 'resource could not be deleted');\n\t\t}\n\t\tredirect('resource/'.$page);\n\t}", "public function deleteImage(){\n\n\n Storage::delete($this->image);\n }", "public function del(string $resource): bool|string\n {\n $json = false;\n $fs = unserialize($_SESSION['rfe'][$this->getRoot()], ['allowed_classes' => false]);\n if (array_key_exists($resource, $fs)) {\n // if $item has children, delete all children too\n if (array_key_exists('dir', $fs[$resource])) {\n foreach ($fs as $key => $file) {\n if (isset($file['parId']) && $file['parId'] == $resource) {\n unset($fs[$key]);\n }\n }\n }\n unset($fs[$resource]);\n $_SESSION['rfe'][$this->getRoot()] = serialize($fs);\n $json = '[{\"msg\": \"item deleted\"}]';\n }\n return $json;\n }", "public function destroy()\n\t{\n\t\treturn unlink(self::filepath($this->name));\n\t}", "public function destroy($id) {\n $book = Book::find($id);\n // return unlink(storage_path(\"public/featured_images/\".$book->featured_image));\n Storage::delete(\"public/featured_images/\" . $book->featured_image);\n if ($book->delete()) {\n return $book;\n }\n\n }", "public function destroy($id)\n {\n Storageplace::findOrFail($id)->delete();\n }", "public function destroyResourceImage(): void\n\t{\n\t\tif (isset($this->image)) {\n\t\t\t@imagedestroy($this->image->getImageResource());\n\t\t}\n\t}", "public function deleteResource(PersistentResource $resource)\n {\n $pathAndFilename = $this->getStoragePathAndFilenameByHash($resource->getSha1());\n if (!file_exists($pathAndFilename)) {\n return true;\n }\n if (unlink($pathAndFilename) === false) {\n return false;\n }\n Files::removeEmptyDirectoriesOnPath(dirname($pathAndFilename));\n return true;\n }", "public function deleteImage(){\n \tStorage::delete($this->image);\n }", "public function destroy()\n {\n $file=public_path(config('larapages.media.folder')).Input::all()['folder'].'/'.Input::all()['file'];\n if (!file_exists($file)) die('File not found '.$file);\n unlink($file);\n }", "public function delete() \r\n {\r\n if($this->exists())\r\n {\r\n unlink($this->fullName());\r\n }\r\n }", "public function destroy($id)\n {\n Myfile::find($id)->delete();\n }", "public function destroy($delete = false)\n {\n if (null !== $this->resource) {\n $this->resource->clear();\n $this->resource->destroy();\n }\n\n $this->resource = null;\n clearstatcache();\n\n // If the $delete flag is passed, delete the image file.\n if (($delete) && file_exists($this->name)) {\n unlink($this->name);\n }\n }", "public static function delete($path){\r\n $currentDir = getcwd();\r\n $storageSubPath = \"/../../\".STORAGE_PATH;\r\n $file = $currentDir . $storageSubPath . '/' . $path;\r\n\r\n unlink($file);\r\n }", "public function destroy(Storage $storage)\n {\n return redirect()->route('storages.index');\n }", "public function remove() {\n //Check if there are thumbs and delete files and db\n foreach ($this->thumbs()->get() as $thumb) {\n $thumb->remove();\n } \n //Delete the attachable itself only if is not default\n if (strpos($this->url, '/defaults/') === false) {\n Storage::disk('public')->delete($this->getPath());\n }\n parent::delete(); //Remove db record\n }", "public function removeFile($uri){\n return Storage::disk('public')->delete($uri);\n }", "public function destroy(Resource $resource)\n {\n if( $resource->delete() ){\n return Response(['status'=>'success','message'=>'Resource deleted']); \n } else {\n return Response(['status'=>'error', 'message'=>'Something went wrong']);\n }\n }", "public function delete($path);", "public function delete($path);", "public function destroy($id)\n { \n File::find($id)->remove();\n \n return redirect()->route('files.index');\n }", "public function destroy($id)\n {\n $supplier = Supplier::find($id);\n $photo = $supplier->photo;\n if ($photo) {\n unlink($photo);\n }\n $supplier->delete();\n }", "public function destroy($id)\n {\n $student = Student::where('id', $id)->first();\n // $path = $student->image;\n unlink($student->image);\n Student::findOrFail($id)->delete();\n return response('Deleted!');\n }", "public function destroy($id)\n {\n $icon = SliderIcon::find($id);\n if (Storage::disk('public')->exists(str_replace('storage', '', $icon->img))){\n Storage::disk('public')->delete(str_replace('storage', '', $icon->img));\n }\n $icon->delete();\n return redirect()->route('slider_icons.index')->with('success', 'Данные преимущества удалёны');\n }", "public function delete($path, $data = null);", "public function destroy($id)\n {\n $items=Items::find($id);\n // delete old file\n if ($items->photo) {\n $str=$items->photo;\n $pos = strpos($str,'/',1);\n $str = substr($str, $pos);\n $oldFile = storage_path('app\\public').$str;\n File::Delete($oldFile); \n }\n $items->delete();\n return redirect()->route('items.index');\n }", "public function destroy($id)\n {\n $carousel = Carousel::find($id);\n $image = $carousel->image;\n\n $basename ='img/carousel/' . basename($image);\n //Delete the file from disk\n if(file_exists($basename)){\n unlink($basename);\n }\n //With softDeletes, this is the way to permanently delete a record\n $carousel->delete();\n Session::flash('success','Product deleted permanently');\n return redirect()->back();\n }", "public function remove()\n {\n $fs = new Filesystem();\n $fs->remove($this->dir());\n }", "public static function destroy(int $resource_id)\n {\n try {\n $image_data = ListingImage::where('id', $resource_id)->first();\n self::delete_image($image_data->name);\n $delete = ListingImage::where('id', $resource_id)->delete();\n\n // activity()\n // ->causedBy(Auth::user()->id)\n // ->performedOn($delete)\n // ->withProperties(['id' => $delete->id])\n // ->log('listing image deleted');\n return response()->json(['status'=> 'ok', 'msg'=> 'Data deleted successfully']);\n } catch (Exception $e) {\n $e->getMessage();\n }\n }", "public function destroy(Storage $storage)\n {\n $this->storage->destroy($storage);\n\n return redirect()->route('admin.product.storage.index')\n ->withSuccess(trans('core::core.messages.resource deleted', ['name' => trans('product::storages.title.storages')]));\n }", "public function del($path){\n\t\treturn $this->remove($path);\n\t}", "public function destroy($id)\n {\n //\n $product = Product::findOrFail($id);\n $product->delete();\n if($product->img != 'product-default.png'){\n Storage::delete(\"public/uploads/\".$product->img);\n // return 'deleted';\n }\n return redirect()->route('product.index'); \n }", "public function removeUpload()\n{\n if ($file = $this->getAbsolutePath()) {\n unlink($file); \n }\n}", "public function destroy($id)\n {\n $image = Images::withTrashed()->find($id);\n\n Storage::disk('uploads')->delete(\"social-media/$image->filename\");\n\n $image->tags()->detach();\n $image->detachMedia(config('constants.media_tags'));\n $image->forceDelete();\n\n return redirect()->back()->with('success', 'The image was successfully deleted');\n }", "public function destroyByResourceId($resource_id)\n {\n// $online_party = $this->onlinetrack->where('resource_id', $resource_id)->get()->first();\n// $online_party->status = \"offline\";\n// $online_party->save();\n// return $online_party;\n return $this->onlinetrack->where('resource_id', $resource_id)->delete();\n }", "public function revoke($resource, $permission = null);", "public function destroy($id)\n {\n $data=Image::find($id);\n $image = $data->img;\n\n\n $filepath= public_path('images/');\n $imagepath = $filepath.$image;\n\n //dd($old_image);\n if (file_exists($imagepath)) {\n @unlink($imagepath);\n }\n\n\n $data->delete();\n\n return redirect()->route('image.index');\n }", "function delete($path);", "public function removeItem(int $id)\n\t{\n\t\t$this->storage->remove($id);\n\t}", "public function destroy(File $file)\n {\n //\n $v = Storage::delete($file->path);\n \n }", "public function destroyResource($resource)\n {\n if (!is_object($resource)) {\n return false;\n }\n\n $resource_type = get_class($resource);\n $resource_id = $resource->getKey();\n\n return Role::where('resource_type', $resource_type)\n ->where('resource_id', $resource_id)\n ->delete();\n }", "public function remove($filePath){\n return Storage::delete($filePath);\n }", "public function remove(): void\n {\n $file = $this->getAbsolutePath();\n if (!is_file($file) || !file_exists($file)) {\n return;\n }\n\n unlink($file);\n }", "public function destroy(Request $request, Storage $storage)\n {\n $storage->delete();\n $request->session()->flash('alert-success', 'Запись успешно удалена!');\n return redirect()->route('storage.index');\n }", "public function remove(Storable $entity): Storable\n {\n $this->getRepository(get_class($entity))->remove($entity);\n $this->detach($entity);\n\n return $entity;\n }", "public function processDeletedResource(EntityResource $resource)\n {\n /** @var AuthorizationRepository $repository */\n $repository = $this->entityManager->getRepository('Edweld\\AclBundle\\Entity\\Authorization');\n\n $repository->removeAuthorizationsForResource($resource);\n }", "function _unlink($resource, $exp_time = null)\n {\n if(file_exists($resource)) {\n return parent::_unlink($resource, $exp_time);\n }\n\n // file wasn't found, so it must be gone.\n return true;\n }", "public function remove($id);", "public function remove($id);", "public function deleted(Storage $storage)\n {\n //\n }", "public function destroy($id)\n {\n $data = Product::findOrFail($id);\n\n if(file_exists('uploads/product/'.$data->image1)){\n unlink('uploads/product/'.$data->image1);\n }\n\n if(file_exists('uploads/product/'.$data->image2)){\n unlink('uploads/product/'.$data->image2);\n }\n\n if(file_exists('uploads/product/'.$data->image3)){\n unlink('uploads/product/'.$data->image3);\n }\n $data->delete();\n }", "public function removeUpload()\n {\n $file = $this->getAbsolutePath();\n if ($file) {\n unlink($file);\n }\n }", "public function resources_delete($resource_id, Request $request) {\n if ($resource_id) {\n $resp = Resources::where('id', '=', $resource_id)->delete();\n if($resp){\n $msg = 'Resource has been deleted successfully.';\n $request->session()->flash('message', $msg);\n }\n }\n //return redirect()->route('admin-factor-list');\n return redirect()->to($_SERVER['HTTP_REFERER']);\n }", "public function delete()\n {\n try\n {\n $thumbnail = $this->getThumbnail();\n if($thumbnail)\n {\n $thumbnail->delete();\n }\n }\n catch(sfException $e){}\n \n // delete current file\n parent::delete();\n }", "function deleteResource($uuid){\n $data = callAPI(\"DELETE\",\"/urest/v1/resource/\".$uuid);\n return $data;\n}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function remove_resource($idproject){\n\t\t\n\t\t// Load model and try to get project data\n\t\t$this->load->model('Projects_model', 'projects');\n\t\t\n\t\t// Update\n\t\t$this->projects->save_project(array(\"ext\" => \"\", \"vzaar_idvideo\" => \"0\", \"vzaar_processed\" => \"0\"), $idproject);\n\t}", "public function destroy($id){\n $file_data = Slider::findOrFail($id);\n File::delete(public_path('../storage/app/public/sliders/'.$file_data->path));\n $slider = Slider::destroy($id);\n return response()->json(null, 204);\n }", "public function delete()\n\t{\n\t\t@unlink($this->get_filepath());\n\t\t@unlink($this->get_filepath(true));\n\t\tparent::delete();\n\t}", "public function delete($resource_path, array $variables = array()) {\n return $this->call($resource_path, $variables, 'DELETE');\n }", "public function destroy($id)\n {\n //Find Slider With Id\n $slider = Slider::findOrFail($id);\n // Check If The Image Exist\n if(file_exists('uploads/slider/'.$slider->image)){\n\n unlink( 'uploads/slider/'.$slider->image);\n }\n $slider->delete();\n return redirect()->back()->with('success','Slider Successfully Deleted');\n }" ]
[ "0.6672584", "0.6659381", "0.6635911", "0.6632799", "0.6626075", "0.65424126", "0.65416265", "0.64648265", "0.62882507", "0.6175931", "0.6129922", "0.60893893", "0.6054415", "0.60428125", "0.60064924", "0.59337646", "0.5930772", "0.59199584", "0.5919811", "0.5904504", "0.5897263", "0.58962846", "0.58951396", "0.58951396", "0.58951396", "0.58951396", "0.5880124", "0.58690923", "0.5863659", "0.5809161", "0.57735413", "0.5760811", "0.5753559", "0.57492644", "0.5741712", "0.57334286", "0.5726379", "0.57144034", "0.57096", "0.5707689", "0.5705895", "0.5705634", "0.5703902", "0.5696585", "0.5684331", "0.5684331", "0.56780374", "0.5677111", "0.5657287", "0.5648262", "0.5648085", "0.5648012", "0.5640759", "0.5637738", "0.5629985", "0.5619264", "0.56167465", "0.5606877", "0.56021434", "0.5601949", "0.55992156", "0.5598557", "0.55897516", "0.5581397", "0.5566926", "0.5566796", "0.55642897", "0.55641", "0.5556583", "0.5556536", "0.5550097", "0.5543172", "0.55422723", "0.5540013", "0.5540013", "0.55371785", "0.55365825", "0.55300397", "0.552969", "0.55275744", "0.55272335", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.55271083", "0.5525997", "0.5525624", "0.5523911", "0.5521122", "0.5517412" ]
0.0
-1
Search strategies are allowed to set cache metadata for better performance. The strategy should return this in an string form, to be attached with any models that wish to use store this cache. Later on, this cache should be provided in the $metadata argument of searchRepository under the 'cache' key.
public function getCacheMetadata(Location $location, $metadata =[]);
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setCaching($cache);", "public function getCacheMetadata()\n {\n return $this->_cacheMetadata;\n }", "public function getCache(): string\n {\n return $this->cache;\n }", "public function getCache();", "public function getCacheName();", "private function _getCachePath() {\n return DIR_PUBLIC_CACHE_SEARCHES . $this->_id . '.json';\n }", "public function getCacheRepository();", "public function cache()\n {\n return $this->cache;\n }", "public static function getCache() {}", "public function setCache()\n\t{\n\t\treturn CacheBot::set($this->getCacheKey(), $this->getDataToCache(), self::$objectCacheLife);\n\t}", "public function getCacheAdapter();", "protected function defaultCache() : Repository\n {\n return Cache::store();\n }", "public function getFromCache() {}", "protected function _getCache()\n {\n if (!isset($this->_configuration)) {\n $this->_configuration = \\Yana\\Db\\Binaries\\ConfigurationSingleton::getInstance();\n }\n return $this->_configuration->getFileNameCache();\n }", "protected static function getCacheIdentifier() {}", "abstract protected function cacheData();", "public function cacheSetup()\n\t{\n\t\t// Generate the name\n\t\t$time = $this->modified;\n\t\t$extension = $this->type;\n\t\t$fileName = pathinfo($this->name, PATHINFO_FILENAME) . \".\" . md5($this->name . '.' . $time);\n\t\t$name = $fileName . \".\" . $extension;\n\n\t\t// Generate the cache file path\n\t\t$this->cacheFilePath = realpath(public_path() . '/' . $this->app['assets::config']['cache_path']) . '/' . $name;\n\n\t\t// Generate the cache file URL\n\t\t$this->cacheFileUrl = $this->app['assets::config']['cache_url'] . $name;\n\n\t\treturn $this->cacheFile = $name;\n\t}", "public function getCache()\n {\n return $this->Cache;\n }", "public function getResponseCacheMetadata() {\n return $this->responseMetadata;\n }", "public function cache() {\n\t\treturn $this->_cache;\n\t}", "public function getCache()\r\n {\r\n if ($this->exists('cache')) {\r\n return ROOT . $this->get('cache');\r\n }\r\n else\r\n return ROOT . '/cache';\r\n }", "public function getCacheOptions();", "public static function metadataCacheNotConfigured()\n {\n return new self('Class Metadata Cache is not configured, ensure an instance of Doctrine\\Common\\Cache\\Cache is passed to the Drest\\Configuration::setMetadataCacheImpl()');\n }", "public function getCache() {\n\t\treturn $this->get('Cundd\\\\Rest\\\\Cache\\\\Cache');\n\t}", "public function getCache()\n {\n return $this->get('cache', false);\n }", "public function get($cache_name);", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->cache;\n }", "public function getCache()\r\n {\r\n \treturn $this->_cache;\r\n }", "abstract protected function getCacheClass();", "protected function cache()\n {\n // Cache location items\n $this->locations->get(); // All\n $this->locations->menu(); // Menu\n $this->locations->mapItems(); // Map\n $this->locations->featured(); // Featured\n\n // Cache properties\n $this->properties->cacheAll(); // All\n $this->properties->specials();\n }", "protected function getCache()\n {\n return $this->cache;\n }", "public function getCaching()\n {\n return (!is_null($this->_cache) ? $this->_cache : Cache::instance('redis'));\n }", "function getCache() {\n return $this->cache;\n }", "public function getCache()\n {\n return $this->_cache;\n }", "public function getCache()\n\t{\n\t\treturn $this->cache;\n\t}", "protected function getCache() {\n\t\t$factory = $this->policy('rate_factoryname');\n\t\t$lifetime = $this->policy('rate_lock_timeout') + 60; // As long as it's longer than the actual timeout\n\t\t$cache = SS_Cache::factory($factory);\n\t\t$cache->setOption('automatic_serialization', true);\n\t\t$cache->setOption('lifetime', $lifetime);\n\t\treturn $cache;\n\t}", "protected function _getMetadataModel()\n\t{\n\t\treturn $this->getModelFromCache('Brivium_MetadataEssential_Model_Metadata');\n\t}", "public function getCache() {\n return $this->cache;\n }", "function metadata()\r\n {\r\n Cache::variable($this->metadata, function() {\r\n return (array)DB::object('userMetadataById', $this->id);\r\n });\r\n }", "function getCache() {\n return $this->cache;\n }", "public function getCacheType(): string\n\t{\n\t\treturn $this->cacheType;\n\t}", "public function is_use_cache()\r\n {\r\n return $this->cache;\r\n }", "protected function getCacheName(){\n\t\tif(is_null($this->param)) {\n\t\t\tthrow new \\Exception('Call \"setParameters\" first!');\n\t\t}\n\n\t\t// Change character when making incompatible changes to prevent loading\n\t\t// errors due to incompatible file contents \\|/\n\t\treturn hash('md5', http_build_query($this->param) . 'A') . '.cache';\n\t}", "public static function setCache($cache) {}", "protected function saveToCache() {}", "public static function getCacheType();", "public function getCache(): Repository\n {\n return $this->cache;\n }", "public function cacheGet() {\n }", "function getCacheId() {\n return get_class($this).\"_\".$this->id;\n }", "public function getCache()\r\n\t{\r\n\t\treturn $this->m_cache;\r\n\t}", "public function getCacheInstance($cacheName = null);", "public function setUpCache();", "public function testCacheableMetadataProvider() {\n $cacheable_metadata = function ($metadata) {\n return CacheableMetadata::createFromRenderArray(['#cache' => $metadata]);\n };\n\n return [\n [\n $cacheable_metadata(['contexts' => ['languages:language_interface']]),\n ['node--article' => 'body'],\n ],\n ];\n }", "public function getCache()\r\n\t{\r\n\t\treturn \\Bitrix\\Main\\Data\\Cache::createInstance();\r\n\t}", "public function getCachePathString()\n\t{\n\t\treturn \"rs-\".$this->_maxWidth.\"-\".$this->_maxHeight.\"-\".$this->_maintainAspectRatio.\"-\".$this->_scaleUp;\n\t}", "public function getCache(): Cache\n {\n return $this->cache;\n }", "public function getCache()\n\t{\n\t\treturn CacheBot::get($this->getCacheKey(), self::$objectCacheLife);\n\t}", "protected function getCache()\n {\n return $this->cacheManager->getCache('cache_beautyofcode');\n }", "public static function getCacheTag()\n\t{\n\t\treturn get_called_class() . '_common_cache';\n\t}", "public static function getCacheTag()\n\t{\n\t\treturn get_called_class() . '_common_cache';\n\t}", "public function setCacheMetadata($cacheMetadata)\n {\n $this->_cacheMetadata = (bool)$cacheMetadata;\n\n return $this;\n }", "private function getCacheData()\n {\n /**@var $cache Zend_Cache_Core */\n $cache = Shopware()->Cache();\n $data = array(\n 'metaData' => array(),\n 'options' => array(\n 'percentage' => $cache->getFillingPercentage()\n ),\n );\n $options = array(\n 'write_control',\n 'caching',\n 'cache_id_prefix',\n 'automatic_serialization',\n 'automatic_cleaning_factor',\n 'lifetime',\n 'logging',\n 'logger',\n 'ignore_user_abort'\n );\n foreach ($options as $option) {\n $data['options'][$option] = $cache->getOption($option);\n }\n\n foreach ($cache->getIds() as $id) {\n $metaData = $cache->getMetadatas($id);\n $createdAt = date('Y-m-d H:i:s', $metaData['mtime']);\n $validTo = date('Y-m-d H:i:s', $metaData['expire']);\n\n $from = new \\DateTime($createdAt);\n $diff = $from->diff(new \\DateTime($validTo));\n $minutes = $diff->days * 24 * 60;\n $minutes += $diff->h * 60;\n $minutes += $diff->i;\n\n $data['metaData'][$id] = array(\n 'Tags' => $metaData['tags'],\n 'Created at' => $createdAt,\n 'Valid to' => $validTo,\n 'Lifetime' => $minutes . ' minutes'\n );\n }\n\n return $data;\n }", "protected function getCacheFile(){\n\t\treturn $this->getPath() . $this->getCacheName();\n\t}", "protected function _getMetadata()\n {\n if (!count($this->_metadata)) {\n $cachedData = false;\n $cacheMetadata = $this->_getCache('cacheMetadata');\n $cacheFile = null;\n\n if ($cacheMetadata !== false) {\n $cacheFile = md5(\"DESCRIBE \" . $this->_prefix . $this->_name);\n }\n\n if ($cacheMetadata !== false) {\n if (($data = $this->_cache->read($cacheFile)) !== false) {\n $this->_metadata = $data;\n $cachedData = true;\n }\n }\n\n if ($cachedData === false) {\n $this->_metadata = $this->_adapter->describeTable($this->_prefix . $this->_name);\n\n if ($cacheMetadata !== false) {\n $this->_cache->write($cacheFile, $this->_metadata);\n }\n }\n }\n\n return $this->_metadata;\n }", "static public function cache($provider = null) {\n $impl = self::instance();\n return $impl->get_resource('cache', $provider);\n }", "public function getCache()\n\t{\n\t\treturn ($this->_cache);\n\t}", "protected function getCache_AnnotationsService()\n {\n return $this->services['cache.annotations'] = \\Symfony\\Component\\Cache\\Adapter\\AbstractAdapter::createSystemCache('o2NSV3WKIW', 0, 'MYfBg2oUlptyQ7C3Ob4WQe', (__DIR__.'/pools'), $this->get('monolog.logger.cache', ContainerInterface::NULL_ON_INVALID_REFERENCE));\n }", "protected function getCacheModule() {}", "public function meta($name = null) {\n if ( $name === null ) {\n return $this->metaCache;\n }\n else {\n return @$this->metaCache[$name];\n }\n }", "private function getCacheId()\n\t{\n\t\treturn self::CACHE_ID_PREFIX . '_' . $this->exportId . '_' . $this->type;\n\t}", "protected function cacheModel()\n {\n $xmlObject = $this->getSimpleXmlObject();\n if ($xmlObject === null) {\n return;\n }\n\n $this->cache = $this->convertItem($xmlObject);\n }", "public static function getCache() {\n\t\treturn null;\n\t}", "private function cacheThis()\n\t{\n\t\t$q = 'UPDATE twitterSearch SET searchResults = \"' .addslashes($this->_results) .'\" WHERE searchTerm = \"' .$this->_searchString .'\"';\n\t\t$r = mysql_query($q, CONN) or die('could not update the results in the database for caching');\n\t}", "protected function cacheSave() {\n $data = array();\n foreach ($this->properties as $prop) {\n $data[$prop] = $this->$prop;\n }\n //cache_set($this->id, $data, 'cache');\n }", "public function getCache() {\n\n // return our instance of Cache\n return $this->oCache;\n }", "private function getCache() {\n // cache for single run\n // so that getLastModified and getContent in single request do not add additional cache roundtrips (i.e memcache)\n if (isset($this->parsed)) {\n return $this->parsed;\n }\n\n // check from cache first\n $cache = null;\n $cacheId = $this->getCacheId();\n if ($this->cache->isValid($cacheId, 0)) {\n if ($cache = $this->cache->fetch($cacheId)) {\n $cache = unserialize($cache);\n }\n }\n\n $less = $this->getCompiler();\n $input = $cache ? $cache : $this->filepath;\n $cache = $less->cachedCompile($input);\n\n if (!is_array($input) || $cache['updated'] > $input['updated']) {\n $this->cache->store($cacheId, serialize($cache));\n }\n\n return $this->parsed = $cache;\n }", "function get_cache(Repository $repo) {\n $key = cache_key($repo);\n $data = get_transient($key);\n if ($data !== false) {\n return json_decode($data, true);\n }\n return false;\n}", "public function cache() {\r\n\t\t$this->resource->cache();\r\n\t}", "protected function cache()\n\t{\n\t\tif ( ! $this->executed OR $this->result === NULL)\n\t\t\treturn;\n\n\t\tif ($this->config['cache'] === FALSE OR ! ($this->cache instanceof Cache))\n\t\t\tthrow new Kohana_User_Exception('Curl.cache()', 'Cache not enabled for this instance. Please check your settings.');\n\n\t\t// Store the correct data\n\t\t$cache_data = array\n\t\t(\n\t\t\t'result' => $this->result,\n\t\t\t'info' => $this->info,\n\t\t);\n\n\t\treturn $this->cache->set($this->create_cache_key(), $cache_data, $this->config['cache_tags'], $this->config['cache']);\n\t}", "public function getSchemaCacheMetadata() {\n return $this->schemaMetadata;\n }", "public function cached()\n {\n // check cache is available else set cache and return\n return Cache::get('Klaravel\\Settings\\Setting', function () {\n $data = $this->get();\n Cache::put('Klaravel\\Settings\\Setting', $data, 60 * 24);\n\n return $data;\n });\n }", "public function getAnnotationName()\n\t{\n\t\treturn 'HttpCache';\n\t}", "public function getCacheDriver(): ?string;", "public function cache() {\r\n\t\t$key = $this->cacher.'.' . $this->hash();\r\n\t\tif (($content = pzk_store($key)) === NULL) {\r\n\t\t\t$content = $this->getContent();\r\n\t\t\tpzk_store($key, $content);\r\n\t\t}\r\n\t\techo $content;\r\n\t}", "abstract public function getCache( $cacheID = '', $unserialize = true );", "public function index(Repository $cache){\n $cache->put('expensive', 'Caching for 5 minutes', 5);\n\n //Cache an item with a defined expiry\n $cache->put('cheap', 'Caching with an defined expiry', now());\n\n //Cache Boolean determines value has been added or not\n $cache_added = $cache->add('moderate', 'Cache with boolean', 5);\n \n //Cache an item forever\n $cache->forever('forever', 'Forever Cache');\n \n //Cache remember forever\n $cache->forever('rememberforever', 'Remember forever cache');\n\n //Caching a closure\n $cache->put('closure', function(){\n echo \"I said hello\";\n });\n\n \n //Checking Cache\n if($cache->has('closure')):\n $cache_exist = 'Closure Exists';\n else:\n $cache_exist = 'Closure cache do not exist';\n endif;\n \n //Forget the cache\n $cache->forget('closure');\n \n //Flush tagged\n // $cache->tags(['cheeses'])->flush();\n\n //Caching a numeric value\n $cache->put('numeric', 5, 15);\n $increment = $cache->increment('numeric');\n $decrement = $cache->decrement('numeric');\n\n //Getting the value of cache\n $array = [\n $cache->get('expensive'),\n $cache->get('moderate'),\n //Retrive & Forget\n $cache->pull('cheap'),\n $cache->get('cheap'),\n $cache->get('forever'),\n $cache_exist,\n $cache_added,\n $increment,\n $decrement\n ];\n \n //Printing out all the cache saved data\n echo \"<pre>\";\n var_dump($array);\n }", "public function cache($options = true);", "public function cacheKey(): string {\n return self::CACHE_PREFIX . $this->id\n . ($this->revisionId ? '_r' . $this->revisionId : '');\n }", "protected function getRuntimeCache() {}", "public function setCacheKey($var)\n {\n GPBUtil::checkString($var, True);\n $this->CacheKey = $var;\n\n return $this;\n }", "public static function getCacheTag()\n {\n return static::$cacheTag;\n }", "public static function getCacheTag()\n {\n return static::$cacheTag;\n }", "protected function getConfigNameWithCacheSettings(): string {\n $configs = $this->getEditableConfigNames();\n return reset($configs);\n }", "public function getCacheId()\n {\n return md5(serialize($this->params));\n }" ]
[ "0.623685", "0.62229955", "0.62101084", "0.6176332", "0.5888325", "0.5870171", "0.5842785", "0.58118486", "0.5809004", "0.5794477", "0.57650536", "0.57546", "0.5748604", "0.57267904", "0.57244766", "0.5720375", "0.5715655", "0.5714735", "0.5707705", "0.5707227", "0.56943005", "0.56914026", "0.5675159", "0.56744", "0.56595135", "0.5654159", "0.5649775", "0.5649775", "0.5649775", "0.5649775", "0.5649775", "0.5649775", "0.5649775", "0.5648845", "0.5632847", "0.56286246", "0.5627092", "0.56048393", "0.55893934", "0.55726475", "0.5560473", "0.5550888", "0.5550644", "0.55422693", "0.5540446", "0.5512244", "0.5509981", "0.54787683", "0.54776466", "0.5477409", "0.5474738", "0.5460701", "0.5455627", "0.54453903", "0.5444198", "0.5436858", "0.5433173", "0.54331386", "0.5424367", "0.54230136", "0.5405855", "0.5401486", "0.53900075", "0.5385791", "0.53589815", "0.53589815", "0.53562534", "0.53413266", "0.5340749", "0.5337328", "0.53293365", "0.5319535", "0.53192145", "0.5305317", "0.5304629", "0.5300642", "0.52794594", "0.5272335", "0.5268273", "0.52680176", "0.52668816", "0.52646536", "0.5256945", "0.5256513", "0.5253506", "0.52534723", "0.524721", "0.5242484", "0.5240069", "0.522551", "0.5223632", "0.5212325", "0.52106977", "0.5210519", "0.5206601", "0.52054435", "0.5192984", "0.5192984", "0.51906306", "0.5186576" ]
0.55384785
45
Parses a locale string into its languag and country components.
public static function parse($locale) { if ($locale instanceof AccessibleCollection) return $locale; if (is_string($locale)) { if (strpos($locale, '-') !== false) { list($language, $country) = explode('-', $locale, 2); $locale = array('language' => $language, 'country' => $country); } else { $locale = array('language' => $locale); } } return is_array($locale) ? new AccessibleCollection($locale) : null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function parseLocale($locale)\n {\n return [$this->locale , substr($this->locale, 0, -3), $this->fallback];\n }", "public function testParseCountry(): void\n {\n $result = Parser::parseCountry('ca');\n $this->assertEquals('CA', $result);\n\n $result = Parser::parseCountry('Canada');\n $this->assertEquals('CA', $result);\n\n $result = Parser::parseCountry('USA');\n $this->assertEquals('US', $result);\n\n $result = Parser::parseCountry('US');\n $this->assertEquals('US', $result);\n\n $result = Parser::parseCountry('United-States');\n $this->assertEquals('US', $result);\n\n $result = Parser::parseCountry('United-States of America');\n $this->assertEquals('US', $result);\n\n $this->assertNull(Parser::parseCountry('banana'));\n\n $this->assertEquals('UK', Parser::parseCountry('United Kingdom'));\n $this->assertEquals('UK', Parser::parseCountry('uk'));\n $this->assertEquals('UK', Parser::parseCountry('united-kingdom'));\n }", "function getLocale();", "function determine_locale()\n {\n }", "public function getLocale();", "public function getLocale();", "function guess_lang()\n\t{\n\n\t\t// The order here _is_ important, at least for major_minor matches.\n\t\t// Don't go moving these around without checking with me first - psoTFX\n\t\t$match_lang = array(\n\t\t\t'arabic'\t\t\t\t\t\t\t\t\t\t\t=> 'ar([_-][a-z]+)?',\n\t\t\t'bulgarian'\t\t\t\t\t\t\t\t\t\t=> 'bg',\n\t\t\t'catalan'\t\t\t\t\t\t\t\t\t\t\t=> 'ca',\n\t\t\t'czech'\t\t\t\t\t\t\t\t\t\t\t\t=> 'cs',\n\t\t\t'danish'\t\t\t\t\t\t\t\t\t\t\t=> 'da',\n\t\t\t'german'\t\t\t\t\t\t\t\t\t\t\t=> 'de([_-][a-z]+)?',\n\t\t\t'english'\t\t\t\t\t\t\t\t\t\t\t=> 'en([_-][a-z]+)?',\n\t\t\t'estonian'\t\t\t\t\t\t\t\t\t\t=> 'et',\n\t\t\t'finnish'\t\t\t\t\t\t\t\t\t\t\t=> 'fi',\n\t\t\t'french'\t\t\t\t\t\t\t\t\t\t\t=> 'fr([_-][a-z]+)?',\n\t\t\t'greek'\t\t\t\t\t\t\t\t\t\t\t\t=> 'el',\n\t\t\t'spanish_argentina'\t\t\t\t\t\t=> 'es[_-]ar',\n\t\t\t'spanish'\t\t\t\t\t\t\t\t\t\t\t=> 'es([_-][a-z]+)?',\n\t\t\t'gaelic'\t\t\t\t\t\t\t\t\t\t\t=> 'gd',\n\t\t\t'galego'\t\t\t\t\t\t\t\t\t\t\t=> 'gl',\n\t\t\t'gujarati'\t\t\t\t\t\t\t\t\t\t=> 'gu',\n\t\t\t'hebrew'\t\t\t\t\t\t\t\t\t\t\t=> 'he',\n\t\t\t'hindi'\t\t\t\t\t\t\t\t\t\t\t\t=> 'hi',\n\t\t\t'croatian'\t\t\t\t\t\t\t\t\t\t=> 'hr',\n\t\t\t'hungarian'\t\t\t\t\t\t\t\t\t\t=> 'hu',\n\t\t\t'icelandic'\t\t\t\t\t\t\t\t\t\t=> 'is',\n\t\t\t'indonesian'\t\t\t\t\t\t\t\t\t=> 'id([_-][a-z]+)?',\n\t\t\t'italian'\t\t\t\t\t\t\t\t\t\t\t=> 'it([_-][a-z]+)?',\n\t\t\t'japanese'\t\t\t\t\t\t\t\t\t\t=> 'ja([_-][a-z]+)?',\n\t\t\t'korean'\t\t\t\t\t\t\t\t\t\t\t=> 'ko([_-][a-z]+)?',\n\t\t\t'latvian'\t\t\t\t\t\t\t\t\t\t\t=> 'lv',\n\t\t\t'lithuanian'\t\t\t\t\t\t\t\t\t=> 'lt',\n\t\t\t'macedonian'\t\t\t\t\t\t\t\t\t=> 'mk',\n\t\t\t'dutch'\t\t\t\t\t\t\t\t\t\t\t\t=> 'nl([_-][a-z]+)?',\n\t\t\t'norwegian'\t\t\t\t\t\t\t\t\t\t=> 'no',\n\t\t\t'punjabi'\t\t\t\t\t\t\t\t\t\t\t=> 'pa',\n\t\t\t'polish'\t\t\t\t\t\t\t\t\t\t\t=> 'pl',\n\t\t\t'portuguese_brazil'\t\t\t\t\t\t=> 'pt[_-]br',\n\t\t\t'portuguese'\t\t\t\t\t\t\t\t\t=> 'pt([_-][a-z]+)?',\n\t\t\t'romanian'\t\t\t\t\t\t\t\t\t\t=> 'ro([_-][a-z]+)?',\n\t\t\t'russian'\t\t\t\t\t\t\t\t\t\t\t=> 'ru([_-][a-z]+)?',\n\t\t\t'slovenian'\t\t\t\t\t\t\t\t\t\t=> 'sl([_-][a-z]+)?',\n\t\t\t'albanian'\t\t\t\t\t\t\t\t\t\t=> 'sq',\n\t\t\t'serbian'\t\t\t\t\t\t\t\t\t\t\t=> 'sr([_-][a-z]+)?',\n\t\t\t'slovak'\t\t\t\t\t\t\t\t\t\t\t=> 'sv([_-][a-z]+)?',\n\t\t\t'swedish'\t\t\t\t\t\t\t\t\t\t\t=> 'sv([_-][a-z]+)?',\n\t\t\t'thai'\t\t\t\t\t\t\t\t\t\t\t\t=> 'th([_-][a-z]+)?',\n\t\t\t'turkish'\t\t\t\t\t\t\t\t\t\t\t=> 'tr([_-][a-z]+)?',\n\t\t\t'ukranian'\t\t\t\t\t\t\t\t\t\t=> 'uk([_-][a-z]+)?',\n\t\t\t'urdu'\t\t\t\t\t\t\t\t\t\t\t\t=> 'ur',\n\t\t\t'viatnamese'\t\t\t\t\t\t\t\t\t=> 'vi',\n\t\t\t'chinese_traditional_taiwan'\t=> 'zh[_-]tw',\n\t\t\t'chinese_simplified'\t\t\t\t\t=> 'zh',\n\t\t);\n\n\t\tif (isset($_SERVER['HTTP_ACCEPT_LANGUAGE']))\n\t\t{\n\t\t\t$accept_lang_ary = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n\t\t\tfor ($i = 0; $i < sizeof($accept_lang_ary); $i++)\n\t\t\t{\n\t\t\t\t@reset($match_lang);\n\t\t\t\twhile (list($lang, $match) = each($match_lang))\n\t\t\t\t{\n\t\t\t\t\tif (preg_match('#' . $match . '#i', trim($accept_lang_ary[$i])))\n\t\t\t\t\t{\n\t\t\t\t\t\tif (@file_exists(@$this->ip_realpath('language/lang_' . $lang)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treturn $lang;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn 'english';\n\t}", "public function testParseLanguage(): void\n {\n $result = Parser::parseLanguage('en');\n $this->assertEquals('en', $result);\n\n $result = Parser::parseLanguage('fr');\n $this->assertEquals('fr', $result);\n\n $result = Parser::parseLanguage('english');\n $this->assertEquals('en', $result);\n\n $result = Parser::parseLanguage('français');\n $this->assertEquals('fr', $result);\n\n $result = Parser::parseLanguage('eng');\n $this->assertEquals('en', $result);\n\n $result = Parser::parseLanguage('fra');\n $this->assertEquals('fr', $result);\n\n $this->assertNull(Parser::parseLanguage('banana'));\n }", "public function getLocale() {}", "public function locale();", "protected static function processLocale(string $locale)\n {\n $l = Locale::fromString($locale);\n $locale = $l->toString();\n\n I18n::setLocale($locale);\n Configure::write('App.locale', $locale);\n Configure::write('App.language', $l->getLanguage());\n\n return $locale;\n }", "function get_lang_locale() {\n\tglobal $lang_code;\n\t$localeMap = array(\n\t\t'ca' => 'ca_ES',\n\t\t'cs' => 'cs_CZ',\n\t\t'cy' => 'cy_GB',\n\t\t'da' => 'da_DK',\n\t\t'de' => 'de_DE',\n\t\t'eu' => 'eu_ES',\n\t\t'en' => 'en_US',\n\t\t'es' => 'es_ES',\n\t\t'fi' => 'fi_FI',\n\t\t'fr' => 'fr_FR',\n\t\t'gl' => 'gl_ES',\n\t\t'hu' => 'hu_HU',\n\t\t'it' => 'it_IT',\n\t\t'ja' => 'ja_JP',\n\t\t'ko' => 'ko_KR',\n\t\t'nb' => 'nb_NO',\n\t\t'nl' => 'nl_NL',\n\t\t'pl' => 'pl_PL',\n\t\t'pt' => 'pt_BR',\n\t\t'ro' => 'ro_RO',\n\t\t'ru' => 'ru_RU',\n\t\t'sk' => 'sk_SK',\n\t\t'sl' => 'sl_SI',\n\t\t'sv' => 'sv_SE',\n\t\t'th' => 'th_TH',\n\t\t'tr' => 'tr_TR',\n\t\t'ku' => 'ku_TR',\n\t\t'zh_CN' => 'zh_CN',\n\t\t'zh_TW' => 'zh_TW',\n\t\t'af' => 'af_ZA',\n\t\t'sq' => 'sq_AL',\n\t\t'hy' => 'hy_AM',\n\t\t'az' => 'az_AZ',\n\t\t'be' => 'be_BY',\n\t\t'bs' => 'bs_BA',\n\t\t'bg' => 'bg_BG',\n\t\t'hr' => 'hr_HR',\n\t\t'eo' => 'eo_EO',\n\t\t'et' => 'et_EE',\n\t\t'fo' => 'fo_FO',\n\t\t'ka' => 'ka_GE',\n\t\t'el' => 'el_GR',\n\t\t'hi' => 'hi_IN',\n\t\t'is' => 'is_IS',\n\t\t'id' => 'id_ID',\n\t\t'ga' => 'ga_IE',\n\t\t'jv' => 'jv_ID',\n\t\t'kk' => 'kk_KZ',\n\t\t'la' => 'la_VA',\n\t\t'lv' => 'lv_LV',\n\t\t'lt' => 'lt_LT',\n\t\t'mk' => 'mk_MK',\n\t\t'mg' => 'mg_MG',\n\t\t'ms' => 'ms_MY',\n\t\t'mt' => 'mt_MT',\n\t\t'mn' => 'mn_MN',\n\t\t'ne' => 'ne_NP',\n\t\t'rm' => 'rm_CH',\n\t\t'sr' => 'sr_RS',\n\t\t'so' => 'so_SO',\n\t\t'sw' => 'sw_KE',\n\t\t'tl' => 'tl_PH',\n\t\t'uk' => 'uk_UA',\n\t\t'uz' => 'uz_UZ',\n\t\t'vi' => 'vi_VN',\n\t\t'zu' => 'zu_ZA',\n\t\t'ar' => 'ar_AR',\n\t\t'he' => 'he_IL',\n\t\t'ur' => 'ur_PK',\n\t\t'fa' => 'fa_IR',\n\t\t'sy' => 'sy_SY',\n\t\t'gn' => 'gn_PY'\n\t);\n\treturn (check_value($localeMap[$lang_code])) ? $localeMap[$lang_code] : 'en_US';\n}", "private static function parseHTTPLanguageHeader() {\n\t\t// Thanks to\n\t\t// http://www.thefutureoftheweb.com/blog/use-accept-language-header\n\t\t$langs = array();\n\t\tif (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n\t\t\t// break up string into pieces (languages and q factors)\n\t\t\tpreg_match_all(\n\t\t\t\t'/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/i',\n\t\t\t\t$_SERVER['HTTP_ACCEPT_LANGUAGE'], $lang_parse);\n\t\t\t\t\n\t\t\tif (count($lang_parse[1])) {\n\t\t\t\t// create a list like \"en\" => 0.8\n\t\t\t\t$langs = array_combine($lang_parse[1], $lang_parse[4]);\n\t\t\t\t\n\t\t\t\t// set default to 1 for any without q factor\n\t\t\t\tforeach ($langs as $lang => $val) {\n\t\t\t\t\tif ($val === '') $langs[$lang] = 1;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t// sort list based on value\n\t\t\t\tarsort($langs, SORT_NUMERIC);\n\t\t\t}\n\t\t}\n\t\treturn array_keys($langs);\n\t}", "abstract protected function initializeCulture();", "function parseString($str){\n\t\t$coDau=array(\"à\",\"á\",\"ạ\",\"ả\",\"ã\",\"â\",\"ầ\",\"ấ\",\"ậ\",\"ẩ\",\"ẫ\",\"ă\",\n \t\"ằ\",\"ắ\",\"ặ\",\"ẳ\",\"ẵ\",\n \t\"è\",\"é\",\"ẹ\",\"ẻ\",\"ẽ\",\"ê\",\"ề\" ,\"ế\",\"ệ\",\"ể\",\"ễ\",\n \t\"ì\",\"í\",\"ị\",\"ỉ\",\"ĩ\",\n \t\"ò\",\"ó\",\"ọ\",\"ỏ\",\"õ\",\"ô\",\"ồ\",\"ố\",\"ộ\",\"ổ\",\"ỗ\",\"ơ\"\n \t,\"ờ\",\"ớ\",\"ợ\",\"ở\",\"ỡ\",\n \t\"ù\",\"ú\",\"ụ\",\"ủ\",\"ũ\",\"ư\",\"ừ\",\"ứ\",\"ự\",\"ử\",\"ữ\",\n \t\"ỳ\",\"ý\",\"ỵ\",\"ỷ\",\"ỹ\",\n \t\"đ\",\n \t\"À\",\"Á\",\"Ạ\",\"Ả\",\"Ã\",\"Â\",\"Ầ\",\"Ấ\",\"Ậ\",\"Ẩ\",\"Ẫ\",\"Ă\"\n \t,\"Ằ\",\"Ắ\",\"Ặ\",\"Ẳ\",\"Ẵ\",\n \t\"È\",\"É\",\"Ẹ\",\"Ẻ\",\"Ẽ\",\"Ê\",\"Ề\",\"Ế\",\"Ệ\",\"Ể\",\"Ễ\",\n \t\"Ì\",\"Í\",\"Ị\",\"Ỉ\",\"Ĩ\",\n \t\"Ò\",\"Ó\",\"Ọ\",\"Ỏ\",\"Õ\",\"Ô\",\"Ồ\",\"Ố\",\"Ộ\",\"Ổ\",\"Ỗ\",\"Ơ\"\n \t,\"Ờ\",\"Ớ\",\"Ợ\",\"Ở\",\"Ỡ\",\n \t\"Ù\",\"Ú\",\"Ụ\",\"Ủ\",\"Ũ\",\"Ư\",\"Ừ\",\"Ứ\",\"Ự\",\"Ử\",\"Ữ\",\n \t\"Ỳ\",\"Ý\",\"Ỵ\",\"Ỷ\",\"Ỹ\",\n \t\"Đ\",\"ê\",\"ù\",\"à\");\n \t$khongDau=array(\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\"a\"\n \t,\"a\",\"a\",\"a\",\"a\",\"a\",\"a\",\n \t\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\"e\",\n \t\"i\",\"i\",\"i\",\"i\",\"i\",\n \t\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\",\"o\"\n \t,\"o\",\"o\",\"o\",\"o\",\"o\",\n \t\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\"u\",\n \t\"y\",\"y\",\"y\",\"y\",\"y\",\n \t\"d\",\n \t\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\",\"A\"\n \t,\"A\",\"A\",\"A\",\"A\",\"A\",\n \t\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\"E\",\n \t\"I\",\"I\",\"I\",\"I\",\"I\",\n \t\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\",\"O\"\n \t,\"O\",\"O\",\"O\",\"O\",\"O\",\n \t\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\"U\",\n \t\"Y\",\"Y\",\"Y\",\"Y\",\"Y\",\n \t\"D\",\"e\",\"u\",\"a\");\n \treturn str_replace($coDau, $khongDau, $str);\n\t}", "public function matchLanguage()\n\t{\n\t\t$pattern = '/^(?P<primarytag>[a-zA-Z]{2,8})'.\n '(?:-(?P<subtag>[a-zA-Z]{2,8}))?(?:(?:;q=)'.\n '(?P<quantifier>\\d\\.\\d))?$/';\n\t\t\n\t\tforeach (explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']) as $lang) \n\t\t{\n\t\t\t$splits = array();\n\n\t\t\tif (preg_match($pattern, $lang, $splits)) \n\t\t\t{\n\t\t\t\t$language = $splits['primarytag'];\n\t\t\t\tif(isset($this->languages[$language]))\n\t\t\t\t\treturn $language;\n\t\t\t} \n\t\t\telse \n\t\t\t\treturn 'en';\n\t\t}\n\t\t\n\t\treturn 'en';\n\t}", "private function getLanguage() {\n $langs = array();\n $lang_parse = array();\n if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n // break up string into pieces (languages and q factors)\n preg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/i', $_SERVER['HTTP_ACCEPT_LANGUAGE'], $lang_parse);\n\n if (count($lang_parse[1])) {\n // create a list like \"en\" => 0.8\n $langs = array_combine($lang_parse[1], $lang_parse[4]);\n\n // set default to 1 for any without q factor\n foreach ($langs as $lang => $val) {\n if ($val === '')\n $langs[$lang] = 1;\n }\n\n // sort list based on value\t\n arsort($langs, SORT_NUMERIC);\n\n // Return prefered language\n foreach ($langs as $lang => $val) {\n return $lang;\n }\n }\n }\n }", "function get_list_of_locales($locale)\r\n\t{\r\n\t\t/* Figure out all possible locale names and start with the most\r\n\t\t * specific ones. I.e. for sr_CS.UTF-8@latin, look through all of\r\n\t\t * sr_CS.UTF-8@latin, sr_CS@latin, sr@latin, sr_CS.UTF-8, sr_CS, sr.\r\n\t\t */\r\n\t\t$locale_names = array();\r\n\t\t$lang = NULL;\r\n\t\t$country = NULL;\r\n\t\t$charset = NULL;\r\n\t\t$modifier = NULL;\r\n\t\tif ($locale) {\r\n\t\t\tif (preg_match(\"/^(?P<lang>[a-z]{2,3})\" // language code\r\n\t\t\t\t. \"(?:_(?P<country>[A-Z]{2}))?\" // country code\r\n\t\t\t\t. \"(?:\\.(?P<charset>[-A-Za-z0-9_]+))?\" // charset\r\n\t\t\t\t. \"(?:@(?P<modifier>[-A-Za-z0-9_]+))?$/\", // @ modifier\r\n\t\t\t\t$locale, $matches)) {\r\n\t\t\t\tif (isset($matches[\"lang\"]))\r\n\t\t\t\t\t$lang = $matches[\"lang\"];\r\n\t\t\t\tif (isset($matches[\"country\"]))\r\n\t\t\t\t\t$country = $matches[\"country\"];\r\n\t\t\t\tif (isset($matches[\"charset\"]))\r\n\t\t\t\t\t$charset = $matches[\"charset\"];\r\n\t\t\t\tif (isset($matches[\"modifier\"]))\r\n\t\t\t\t\t$modifier = $matches[\"modifier\"];\r\n\t\t\t\t\r\n\t\t\t\tif ($modifier) {\r\n\t\t\t\t\tif ($country) {\r\n\t\t\t\t\t\tif ($charset)\r\n\t\t\t\t\t\t\tarray_push($locale_names, \"${lang}_$country.$charset@$modifier\");\r\n\t\t\t\t\t\tarray_push($locale_names, \"${lang}_$country@$modifier\");\r\n\t\t\t\t\t} elseif ($charset)\r\n\t\t\t\t\t\tarray_push($locale_names, \"${lang}.$charset@$modifier\");\r\n\t\t\t\t\tarray_push($locale_names, \"$lang@$modifier\");\r\n\t\t\t\t}\r\n\t\t\t\tif ($country) {\r\n\t\t\t\t\tif ($charset)\r\n\t\t\t\t\t\tarray_push($locale_names, \"${lang}_$country.$charset\");\r\n\t\t\t\t\tarray_push($locale_names, \"${lang}_$country\");\r\n\t\t\t\t} elseif ($charset)\r\n\t\t\t\t\tarray_push($locale_names, \"${lang}.$charset\");\r\n\t\t\t\tarray_push($locale_names, $lang);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// If the locale name doesn't match POSIX style, just include it as-is.\r\n\t\t\tif (!in_array($locale, $locale_names))\r\n\t\t\t\tarray_push($locale_names, $locale);\r\n\t\t}\r\n\t\treturn $locale_names;\r\n\t}", "function httpbl_lang()\n {\n foreach(explode(',',$_SERVER['HTTP_ACCEPT_LANGUAGE']) as $language)\n { if ($language=='fr') { return 'fr'; } }\n return 'en';\n }", "function get_locale() {\n \n global $CONF;\n \n if( isset( $CONF ) ) {\n \t\t$supported_languages\t\t= $CONF['supported_languages'];\n } else {\n \t\t$supported_languages\t\t= array ('de', 'de_DE', 'en', 'en_US');\t\n }\n \n $lang_array \t\t\t\t\t\t= preg_split ('/(\\s*,\\s*)/', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n \n if (is_array ($lang_array)) {\n \n $lang_first \t\t\t\t\t= strtolower ((trim (strval ($lang_array[0]))));\n $lang_parts\t\t\t\t\t= explode( '-', $lang_array[0] );\n $count\t\t\t\t\t\t= count( $lang_parts );\n if( $count == 2 ) {\n \t\n \t\t$lang_parts[1]\t\t\t= strtoupper( $lang_parts[1] );\n \t\t$lang_first\t\t\t\t= implode( \"_\", $lang_parts );\n }\n \n if (in_array ($lang_first, $supported_languages)) {\n \n $lang \t\t\t\t\t\t= $lang_first;\n \n } else {\n \n $lang \t\t\t\t\t\t= $CONF['default_locale'];\n \n }\n \n } else {\n \n $lang\t\t\t\t\t\t\t = $CONF['default_locale'];\n \n }\n \n return $lang;\n}", "protected function initializeL10nLocales() {}", "abstract public function getLocaleName();", "public function getLocale(LocaleIO $io);", "protected function parseLocale($locale) {\n return array_filter([\n $locale ?: $this->locale,\n $this->fallback\n ]);\n }", "function get_country_code_from_locale( $locale ) {\n\t/*\n\t * `en_US` is ignored, because it's the default locale in Core, and many users never set it. That\n\t * leads to a lot of false-positives; e.g., Hampton-Sydney, Virginia, USA instead of Sydney, Australia.\n\t */\n\tif ( empty( $locale ) || 'en_US' === $locale ) {\n\t\treturn null;\n\t}\n\n\tpreg_match( '/^[a-z]+[-_]([a-z]+)$/i', $locale, $match );\n\n\t$country_code = $match[1] ?? null;\n\n\treturn $country_code;\n}", "public function language(string $language);", "function acf_get_locale()\n{\n}", "abstract public function getLocaleCode();", "public function testCanParseCommaSeparatedValues()\n {\n $header = AcceptLanguage::fromString('Accept-Language: da;q=0.8,en-gb');\n $this->assertTrue($header->hasLanguage('da'));\n $this->assertTrue($header->hasLanguage('en-gb'));\n }", "public function locale(string $locale = null);", "private function _getUserAgentLanguage()\n {\n $matches = $languages = [];\n\n if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n // ISO Language Codes, 2-letters: ISO 639-1, <Country tag>[-<Country subtag>]\n // Simplified language syntax detection: xx[-yy]\n preg_match_all(\n '/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/i',\n $_SERVER['HTTP_ACCEPT_LANGUAGE'],\n $matches\n );\n\n if (count($matches[1])) {\n $languages = array_combine($matches[1], $matches[4]);\n foreach ($languages as $lang => $val) {\n if ($val === '') {\n $languages[$lang] = 1;\n }\n }\n arsort($languages, SORT_NUMERIC);\n }\n foreach ($languages as $lang => $val) {\n if (self::isASupportedLanguage(strtoupper($lang))) {\n $this->acceptedLanguage = $lang;\n break;\n }\n }\n }\n }", "private function lang($string='')\n {\n return $this->language->get($string);\n }", "function localize_date($date, $location = 'en_EN') {\r\n if (strlen($date) == 10) {\r\n\r\n $date_array = explode('-', $date);\r\n\r\n if (substr($location, 0, 2) == 'fr' OR substr($location, 0, 2) == 'de' OR substr($location, 0, 2) == 'es') {\r\n return $date_array[2] . '.' . $date_array[1] . '.' . $date_array[0];\r\n } elseif (substr($location, 0, 2) == 'en') {\r\n return $date;\r\n }\r\n }\r\n\r\n return $date;\r\n}", "abstract public function getTranslationIn(string $locale);", "abstract public function getTranslationIn(string $locale);", "abstract public function getTranslationIn(string $locale);", "protected function getLocale($acceptLanguageHeader)\n {\n $acceptLanguageHeader = str_replace('-', '_', $acceptLanguageHeader);\n $locales = explode(',', $acceptLanguageHeader);\n \n $acceptableLocales = array();\n foreach ($locales as $locale) {\n $priority = 1;\n if (strpos($locale, ';') !== false) {\n $priority = floatval(substr($locale, strpos($locale, ';')));\n $locale = substr($locale, 0, strpos($locale, ';'));\n }\n \n $acceptableLocales[$priority] = $locale;\n }\n \n krsort($acceptableLocales);\n \n // Get the first locale - it will have the highest priority\n $locale = array_shift($acceptableLocales);\n \n if ($locale == '') {\n $locale = 'en_US';\n } else if (strpos($locale, '_') === false) {\n $locale = $locale . '_' . strtoupper($locale);\n }\n \n return $locale;\n }", "public function getLanguageFromUrl(string $url);", "public function getLocale($lang)\r\n\t{\r\n\t\t$languages = $this->getConfig(\"languages\");\r\n\t\t\r\n\t\tif ( $languages != null )\r\n\t\t{\r\n\t\t\tforeach ( $languages->language as $language )\r\n\t\t\t{\r\n\t\t\t\tif ( $language[\"code\"] == $lang )\r\n\t\t\t\t{\r\n\t\t\t\t\tforeach ($language->attributes() as $name => $value) {\r\n\t\t\t\t\t\tif ( $name == \"locale\" ) {\r\n\t\t\t\t\t\t\treturn (string) $value;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t// we got this far, then no matches!\r\n\t\t\r\n\t\treturn \"C\";\r\n\t}", "function ffd_format_country_state_string( $country_string ) {\r\n\tif ( strstr( $country_string, ':' ) ) {\r\n\t\tlist( $country, $state ) = explode( ':', $country_string );\r\n\t} else {\r\n\t\t$country = $country_string;\r\n\t\t$state = '';\r\n\t}\r\n\treturn array(\r\n\t\t'country' => $country,\r\n\t\t'state' => $state,\r\n\t);\r\n}", "public function getLocale(): string;", "public function getLocale(): string;", "public function getLocale(): string;", "private static function parseClientLang(){\n\t\t$langs = array();\n\n\t\tif(isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])){\n\t\t\t// break up string into pieces (languages and q factors)\n\t\t\tpreg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/i', $_SERVER['HTTP_ACCEPT_LANGUAGE'], $lang_parse);\n\n\t\t\tif(count($lang_parse[1])){\n\t\t\t\t// create a list like \"en\" => 0.8\n\t\t\t\t$langs = array_combine($lang_parse[1], $lang_parse[4]);\n\n\t\t\t\t// set default to 1 for any without q factor\n\t\t\t\tforeach($langs as $lang => $val){\n\t\t\t\t\tif($val === ''){\n\t\t\t\t\t\t$langs[$lang] = 1;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// sort list based on value\n\t\t\t\tarsort($langs, SORT_NUMERIC);\n\t\t\t}\n\t\t}\n\n\t\treturn $langs;\n\t}", "static function parse($string, $culture = null)\n {\n if ($culture)\n {\n return number()->usingLocale($culture, function($num) use ($string) {\n return $num->parse($string);\n });\n }\n return number()->parse($string);\n }", "final protected function get_language() {\n\t\tif (preg_match('/[a-z]{2}-[a-z]{2}/', strtolower($_SERVER['HTTP_ACCEPT_LANGUAGE']), $matches))\n\t\t\treturn $matches[0];\n\t\treturn false;\n\t}", "function get_locale(): string\n{\n $locale = \\Locale::acceptFromHttp(input_server('HTTP_ACCEPT_LANGUAGE'));\n if (!$locale) {\n $locale = 'en_US';\n }\n return $locale;\n}", "function lang_parse($key, $args)\n{\n\tglobal $lang;\n\t\n\t// Make sure the key is uppercase\n\t$key = strtoupper($key);\n\t\n\t// Does that key exist?\n\tif(!$lang[$key])\n\t{\n\t\t// So we know it needs to be translated.\n\t\treturn '{' . $key . '}';\n\t}\n\telse\n\t{\n\t\treturn mb_vsprintf($lang[$key], $args, $lang['ENCODING']);\n\t}\n}", "function storms_wc_get_country_locale( $locales ) {\n\n\t\t$field = 'postcode';\n\t\t$fields_ordered = storms_wc_checkout_fields_order_billing_fields();\n\n\t\t$locales['BR'][$field]['priority'] = $fields_ordered[$field];\n\n\t\treturn $locales;\n\t}", "public function testLanguage()\n {\n $f = new Formatter(['language' => 'en-US']);\n $this->assertEquals('en-US', $f->language);\n\n // language is configured via locale (omitting @calendar param)\n $f = new Formatter(['locale' => 'en-US@calendar=persian']);\n $this->assertEquals('en-US', $f->language);\n\n // if not, take from application\n $f = new Formatter();\n $this->assertEquals('ru-RU', $f->language);\n }", "function languageDetect()\n {\n global $iConfig;\n\n $langs = array();\n\n if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE']))\n {\n\n preg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/', $_SERVER['HTTP_ACCEPT_LANGUAGE'], $lang_parse); // break up string into pieces (languages and q factors)\n\n if (count($lang_parse[1]))\n {\n// $langs = array_combine($lang_parse[1], $lang_parse[4]); // create a list like \"en\" => 0.8 // PHP5 only\n foreach ($lang_parse[1] as $k => $v) $langs[$v] = $lang_parse[4][$k]; // replace \"array_combine\" for PHP4\n\n foreach ($langs as $lang => $val) {\n if ($val === '') $langs[$lang] = 1; // set default to 1 for any without q factor\n }\n arsort($langs, SORT_NUMERIC); // sort list based on value\n }\n }\n\n foreach ($langs as $lang => $val)\n {\n $lang_2s = substr($lang, 0,2);\n $path = sprintf('language/%s_lang.php', $lang_2s);\n if (file_exists($path)) return $lang_2s;\n }\n\n return $iConfig['default_lng'];\n }", "function getDefaultLocale();", "public function setLocale(string $locale = null)\n {\n $locales = [];\n if (empty($locale)) {\n array_push(\n $locales,\n 'en-EN.utf8',\n 'en_EN.utf8',\n 'en-EN',\n 'en-US.utf8',\n 'en_US.utf8',\n 'en-US',\n 'en',\n 'en_US'\n );\n\n if (!defined('BBN_LOCALE')) {\n // No user detection for CLI: default language\n if ($this->_mode === 'cli') {\n if (defined('BBN_LANG')) {\n $lang = BBN_LANG;\n }\n }\n else {\n $user_locales = self::detectLanguage();\n if (!defined('BBN_LANG') && $user_locales) {\n if (strpos($user_locales[0], '-')) {\n if ($lang = X::split($user_locales[0], '-')[0]) {\n define('BBN_LANG', $lang);\n }\n }\n elseif (strpos($user_locales[0], '_')) {\n if ($lang = X::split($user_locales[0], '_')[0]) {\n define('BBN_LANG', $lang);\n }\n }\n elseif ($user_locales[0]) {\n define('BBN_LANG', $user_locales[0]);\n }\n }\n\n if (!defined('BBN_LANG')) {\n throw new \\Exception(\"Impossible to determine the language\");\n }\n\n $lang = BBN_LANG;\n }\n\n if (isset($lang)) {\n array_unshift(\n $locales,\n $lang . '-' . strtoupper($lang) . '.utf8',\n $lang . '_' . strtoupper($lang) . '.utf8',\n $lang . '-' . strtoupper($lang),\n $lang\n );\n\n if (!empty($user_locales)) {\n array_unshift($locales, ...$user_locales);\n }\n }\n }\n }\n elseif (!strpos($locale, '-') && !strpos($locale, '_')) {\n if ($locale === 'en') {\n array_unshift(\n $locales,\n 'en_US.utf8',\n 'en-US.utf8',\n 'en_US',\n 'en-US'\n );\n }\n\n array_unshift(\n $locales,\n strtolower($locale) . '-' . strtoupper($locale) . '.utf8',\n strtolower($locale) . '_' . strtoupper($locale) . '.utf8',\n strtolower($locale) . '-' . strtoupper($locale),\n strtolower($locale)\n );\n }\n else {\n $locales[] = $locale;\n }\n\n if ($confirmed = $this->_tryLocales($locales)) {\n if (!defined('BBN_LOCALE')) {\n define('BBN_LOCALE', $confirmed);\n }\n\n $this->_locale = $confirmed;\n if (!isset($lang)) {\n $lang = X::split(X::split($this->_locale, '-')[0], '_')[0];\n }\n\n putenv(\"LANG=\".$lang);\n putenv(\"LC_MESSAGES=\".$this->_locale);\n setlocale(LC_MESSAGES, $this->_locale);\n }\n else {\n throw new \\Exception(\"Impossible to find a corresponding locale on this server for this app\");\n }\n }", "public function resolve(?string $language): array;", "public static function getLanguageLocale()\n {\n if (!is_array(self::$languages)) {\n self::checkLanguages();\n }\n\n $userLanguage = self::getLanguage();\n foreach (self::$languages as $language) {\n if (strlen($language) === 5 && strpos($language, $userLanguage) === 0) {\n $locale = substr($language, -2);\n break;\n }\n }\n\n if (!empty($locale)) {\n return $userLanguage . \"-\" . strtoupper($locale);\n } else {\n return $userLanguage;\n }\n }", "private static function getLocaleSplitted($locale)\n {\n $localeSplitted = array_filter(preg_split('/[^a-z0-9]+/i', trim($locale), 3));\n $localeSplittedCount = count($localeSplitted);\n\n // Empty locale.\n if (!$localeSplittedCount) {\n return [ ];\n }\n\n // Only one locale found.\n $localeFirstLower = strtolower($localeSplitted[0]);\n if ($localeSplittedCount === 1) {\n return [ $localeFirstLower ];\n }\n\n // Multilocales.\n $locales = [\n $localeFirstLower,\n $localeFirstLower . '-' . strtoupper($localeSplitted[1]),\n ];\n\n // Uncommon locale.\n if ($localeSplittedCount === 3) {\n $locales[] = $locales[1] . '-' . trim($localeSplitted[2]);\n }\n\n return $locales;\n }", "public function getLocaleManager();", "public function getLocale($lang = \"\")\n {\n if(!in_array($lang, getAvailableLanguages())) $lang = DEFAULT_LANG;\n if($this->lang == $lang)\n {\n return;\n }\n\n global $sDB;\n $this->lang = $lang;\n\n if(LANG_USE_CACHE && file_exists($this->getTemplateRootAbs().\"lang_\".$lang.\".php\"))\n {\n $langCache = file_get_contents($this->getTemplateRootAbs().\"lang_\".$lang.\".php\");\n if(strlen($langCache) > 3)\n {\n $langCache = unserialize(substr($langCache, 3));\n if(is_array($langCache))\n {\n foreach($langCache as $key => $val)\n {\n $this->LANG_SET[$key] = $val;\n }\n return;\n }\n }\n }\n\n // load global language variables e.g. \"de\" for \"deDE\"\n $res = $sDB->execLocalization(\"SELECT * FROM `localization` WHERE `loc_language` = '\".mysql_real_escape_string(substr($lang, 0, 2)).\"';\");\n while($row = mysql_fetch_object($res))\n {\n $this->LANG_SET[$row->loc_key] = $row->loc_val;\n }\n\n // load country specific overrides\n $res = $sDB->execLocalization(\"SELECT * FROM `localization` WHERE `loc_language` = '\".mysql_real_escape_string($lang).\"';\");\n while($row = mysql_fetch_object($res))\n {\n $this->LANG_SET[$row->loc_key] = $row->loc_val;\n }\n }", "function checkAndLatinize($txt)\n{\n $lang = getTransLang();\n switch($lang)\n {\n case 'hr': \n case 'bs':\n case 'sr1':\n $out = cir2lat($txt);\n break;\n default: $out = $txt;\n }\n return $out;\n}", "function SI_determineLanguage() {\n\tglobal $_SERVER;\n\tif (isset($_SERVER[\"HTTP_ACCEPT_LANGUAGE\"])) {\n\t\t// Capture up to the first delimiter (, found in Safari)\n\t\tpreg_match(\"/([^,;]*)/\",$_SERVER[\"HTTP_ACCEPT_LANGUAGE\"],$langs);\n\t\t$lang_choice=$langs[0];\n\t\t}\n\telse { $lang_choice=\"empty\"; }\n\treturn $lang_choice;\n\t}", "public static function parseFromLocale($time, $locale = null, $tz = null)\n {\n return static::rawParse(static::translateTimeString($time, $locale, 'en'), $tz);\n }", "public static function languages($header = null)\n {\n $languages = array();\n\n if ($header === null) {\n $header = $_SERVER['HTTP_ACCEPT_LANGUAGE'];\n }\n\n // Split into language pairs, ex. {'en', 'en-gb;q=0.8', 'de;q=0.7'}.\n $pairs = explode(',', $header);\n if ($pairs === false || $pairs === array()) {\n // Return the first element in the whitelist if possible, otherwise\n // return an empty array.\n return array();\n }\n\n // Split into subpairs, ex. {'en-gb', '0.8'}.\n foreach ($pairs as $pair) {\n // We don't need to use mb_strtolower because language tags are\n // ASCII - see RFC 2616 § 3.10.\n $pair = trim(strtolower($pair));\n $subpair = explode(';q=', $pair);\n switch(count($subpair)) {\n case 2:\n list($language, $q) = $subpair;\n $languages[$language] = (float)$q;\n break;\n // If no q-factor is specified, the HTTP spec tells us to assume 1.\n case 1:\n list($language) = $subpair;\n $languages[$language] = 1;\n break;\n default:\n throw new UnexpectedValueException(\"The HTTP_ACCEPT_LANGUAGE header is malformed.\");\n }\n }\n\n // Sort by q-factors in ascending order, then reverse for ascending order.\n asort($languages);\n $languages = array_reverse($languages);\n\n return $languages;\n }", "function guess_location_from_country( $location_name ) {\n\tglobal $cache_group, $cache_life;\n\n\t$cache_key = 'guess_location_from_country:' . $location_name;\n\t$country = wp_cache_get( $cache_key, $cache_group );\n\n\tif ( $country ) {\n\t\tif ( '__NOT_FOUND__' == $country ) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn $country;\n\t}\n\n\t// Check if they entered only the country name, e.g. \"Germany\" or \"New Zealand\"\n\t$country = get_country_from_name( $location_name );\n\t$location_name_parts = preg_split( '/\\s+/u', $location_name );\n\tif ( ! $location_name_parts ) {\n\t\t// Invalid/Unsupported UTF8 characters encountered.\n\t\t$location_name_parts = array( $location_name );\n\t}\n\t$location_word_count = count( $location_name_parts );\n\n\t/*\n\t * Multi-word queries may contain cities, regions, and countries, so try to extract just the country\n\t */\n\tif ( ! $country && $location_word_count >= 2 ) {\n\t\t// Catch input like \"Vancouver Canada\"\n\t\t$country_id = $location_name_parts[ $location_word_count - 1 ];\n\t\t$country = get_country_from_name( $country_id );\n\t}\n\n\tif ( ! $country && $location_word_count >= 3 ) {\n\t\t// Catch input like \"Santiago De Los Caballeros, Dominican Republic\"\n\t\t$country_name = sprintf(\n\t\t\t'%s %s',\n\t\t\t$location_name_parts[ $location_word_count - 2 ],\n\t\t\t$location_name_parts[ $location_word_count - 1 ]\n\t\t);\n\t\t$country = get_country_from_name( $country_name );\n\t}\n\n\tif ( ! $country && $location_word_count >= 4 ) {\n\t\t// Catch input like \"Kaga-Bandoro, Central African Republic\"\n\t\t$country_name = sprintf(\n\t\t\t'%s %s %s',\n\t\t\t$location_name_parts[ $location_word_count - 3 ],\n\t\t\t$location_name_parts[ $location_word_count - 2 ],\n\t\t\t$location_name_parts[ $location_word_count - 1 ]\n\t\t);\n\t\t$country = get_country_from_name( $country_name );\n\t}\n\n\twp_cache_set( $cache_key, ( $country ?: '__NOT_FOUND__' ), $cache_group, $cache_life );\n\n\treturn $country;\n}", "function smarty_function_mtbloglanguage($args, &$ctx) {\n $real_lang = array('cz' => 'cs', 'dk' => 'da', 'jp' => 'ja', 'si' => 'sl');\n $blog = $ctx->stash('blog');\n $lang_tag = $blog->blog_language;\n if ($real_lang[$lang_tag]) {\n $lang_tag = $real_lang[$lang_tag];\n }\n if ($args['locale']) {\n $lang_tag = preg_replace('/^([A-Za-z][A-Za-z])([-_]([A-Za-z][A-Za-z]))?$/e', '\\'$1\\' . \"_\" . (\\'$3\\' ? strtoupper(\\'$3\\') : strtoupper(\\'$1\\'))', $lang_tag);\n } elseif ($args['ietf']) {\n # http://www.ietf.org/rfc/rfc3066.txt\n $lang_tag = preg_replace('/_/', '-', $lang_tag);\n }\n return $lang_tag;\n}", "private function getLangFromHTTP(): ?string\n {\n $langs = $this->getLangs();\n $acceptLangs = explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n foreach ($acceptLangs as $lang) {\n $lang = preg_replace('/;q=.*$/', '', trim($lang)); // trim and remove quality...\n if (in_array($lang, $langs)) {\n return $lang;\n }\n\n // try also generic locale (e.g. 'en' instead of 'en-US')\n $lang = preg_replace('/-.*$/', '', $lang);\n if (in_array($lang, $langs)) {\n return $lang;\n }\n }\n\n return null;\n }", "function setLocale($locale);", "function translate_month($lang,$what){\n if($lang == 'eng') return $what;\n //Dutch Translation contributed by Mariano Iglesias ([email protected])\n //Polish Translation contributed by tjagi ([email protected])\n if($lang == 'rus'){\n switch($what){\n case 'January': return 'Январь';break;\n case 'February': return 'Февраль';break;\n case 'March': return 'Март';break;\n case 'April': return 'Апрель';break;\n case 'May': return 'Май';break;\n case 'June': return 'Июнь';break;\n case 'July': return 'Июль';break;\n case 'August': return 'Август';break;\n case 'September': return 'Сентябрь';break;\n case 'October': return 'Октябрь';break;\n case 'November': return 'Ноябрь';break;\n case 'December': return 'Декабрь';break;\n }\n }\n }", "public function getLanguage() {\n $fields = array('language' => array(\n 'languageHeader' => 'header',\n 'languageElement',\n ));\n $result = TingOpenformatMethods::parseFields($this->_getDetails(), $fields);\n return (is_countable($result['language'][0]['languageElement']) && count($result['language'][0]['languageElement']) > 1) ? array() : $result;\n }", "protected function _extractLanguage() {\n // Default lanuage is always Lao\n $lang = 'lo';\n\n // Set the cookie name\n //$this->Cookie->name = '_osm_la';\n //echo $this->response->cookie(\"_osm_la\");\n \n // First check if the language parameter is set in the URL. The URL\n // parameter has first priority.\n $paramLang = $this->request->query(\"lang\");\n if (isset($paramLang)) {\n // Check if the URL parameter is a valid language identifier\n if (array_key_exists($paramLang, $this->_languages)) {\n // Set the language to the URL parameter\n $lang = $paramLang;\n }\n } else if ($this->Cookie->read($this->_languageCookie) != null) {\n // Check if a cookie is set and set its value as language. A Cookie\n // has second priority\n $cookieValue = $this->Cookie->read($this->_languageCookie);\n // Check if the URL parameter is a valid language identifier\n if (array_key_exists($cookieValue, $this->_languages)) {\n // Set the language to the Cookie value\n $lang = $cookieValue;\n }\n }\n\n // If neither the lang parameter nor a cookie is set, set and return\n // Lao as language.\n //$this->log(var_dump($this));\n //$this->response->cookie($this->_languageCookie => $lang ]);\n return $lang;\n }", "function resolveLanguageFromBrowser()\n {\n $ret = false;\n if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n $env = $_SERVER['HTTP_ACCEPT_LANGUAGE'];\n $aLangs = preg_split(\n ';[\\s,]+;',\n substr($env, 0, strpos($env . ';', ';')), -1,\n PREG_SPLIT_NO_EMPTY\n );\n foreach ($aLangs as $langCode) {\n $lang = $langCode . '-' . SGL_Translation::getFallbackCharset();\n if (SGL_Translation::isAllowedLanguage($lang)) {\n $ret = $lang;\n break;\n }\n }\n }\n return $ret;\n }", "function check_language () {\n \n global $CONF;\n $supported_languages \t\t\t= array ('de', 'en');\n $lang_array \t\t\t\t\t\t= preg_split ('/(\\s*,\\s*)/', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n \n if (is_array ($lang_array)) {\n \n $lang_first \t\t\t\t\t= strtolower ((trim (strval ($lang_array[0]))));\n $lang_first \t\t\t\t\t= substr ($lang_first, 0, 2);\n \n if (in_array ($lang_first, $supported_languages)) {\n \n $lang \t\t\t\t\t\t= $lang_first;\n \n } else {\n \n $lang \t\t\t\t\t\t= $CONF['default_language'];\n \n }\n } else {\n \n $lang\t\t\t\t\t\t\t = $CONF['default_language'];\n \n }\n \n return $lang;\n}", "private function getPreferredLanguage($header) {\n $langList = array();\n\n // break up string into pieces (languages and q factors)\n preg_match_all('/([a-z]{1,8}(-[a-z]{1,8})?)\\s*(;\\s*q\\s*=\\s*(1|0\\.[0-9]+))?/i', $header, $lang_parse);\n\n if (count($lang_parse[1])) {\n // create a list like \"en\" => 0.8\n $langList = array_combine($lang_parse[1], $lang_parse[4]);\n\n // set default to 1 for any without q factor\n foreach ($langList as $lang => $val) {\n if ($val === '') $langList[$lang] = 1;\n }\n\n // sort list based on value\n arsort($langList, SORT_NUMERIC);\n }\n\n $acceptedLangList = config('app.locales');\n $result = null;\n $q = 0;\n\n foreach ($langList as $lang => $priority) {\n if (in_array($lang, $acceptedLangList) && $priority > $q) {\n $q = $priority;\n $result = $lang;\n }\n }\n\n return $result;\n }", "function languagelist()\n{\n\t // Need to ensure this is loaded for language defines\n\tpnBlockLoad('Core', 'thelang');\n\t// All entries use ISO 639-2/T\n\t// hilope - added all 469 languages available under ISO 639-2\n\t\n\t$lang['aar'] = _LANGUAGE_AAR; // Afar\n\t$lang['abk'] = _LANGUAGE_ABK; // Abkhazian\n\t$lang['ace'] = _LANGUAGE_ACE; // Achinese\n\t$lang['ach'] = _LANGUAGE_ACH; // Acoli\n\t$lang['ada'] = _LANGUAGE_ADA; // Adangme\n\t$lang['ady'] = _LANGUAGE_ADY; // Adyghe; Adygei\n\t$lang['afa'] = _LANGUAGE_AFA; // Afro-Asiatic (Other)\n\t$lang['afh'] = _LANGUAGE_AFH; // Afrihili\n\t$lang['afr'] = _LANGUAGE_AFR; // Afrikaans\n\t$lang['aka'] = _LANGUAGE_AKA; // Akan\n\t$lang['akk'] = _LANGUAGE_AKK; // Akkadian\n\t$lang['ale'] = _LANGUAGE_ALE; // Aleut\n\t$lang['alg'] = _LANGUAGE_ALG; // Algonquian languages\n\t$lang['amh'] = _LANGUAGE_AMH; // Amharic\n\t$lang['ang'] = _LANGUAGE_ANG; // English, Old\n\t$lang['apa'] = _LANGUAGE_APA; // Apache languages\n\t$lang['ara'] = _LANGUAGE_ARA; // Arabic\n\t$lang['arc'] = _LANGUAGE_ARC; // Aramaic\n\t$lang['arg'] = _LANGUAGE_ARG; // Aragonese\n\t$lang['arn'] = _LANGUAGE_ARN; // Araucanian\n\t$lang['arp'] = _LANGUAGE_ARP; // Arapaho\n\t$lang['art'] = _LANGUAGE_ART; // Artificial (Other)\n\t$lang['arw'] = _LANGUAGE_ARW; // Arawak\n\t$lang['asm'] = _LANGUAGE_ASM; // Assamese\n\t$lang['ast'] = _LANGUAGE_AST; // Asturian; Bable\n\t$lang['ath'] = _LANGUAGE_ATH; // Athapascan languages\n\t$lang['aus'] = _LANGUAGE_AUS; // Australian languages\n\t$lang['ava'] = _LANGUAGE_AVA; // Avaric\n\t$lang['ave'] = _LANGUAGE_AVE; // Avestan\n\t$lang['awa'] = _LANGUAGE_AWA; // Awadhi\n\t$lang['aym'] = _LANGUAGE_AYM; // Aymara\n\t$lang['aze'] = _LANGUAGE_AZE; // Azerbaijani\n\t$lang['bad'] = _LANGUAGE_BAD; // Banda\n\t$lang['bai'] = _LANGUAGE_BAI; // Bamileke languages\n\t$lang['bak'] = _LANGUAGE_BAK; // Bashkir\n\t$lang['bal'] = _LANGUAGE_BAL; // Baluchi\n\t$lang['bam'] = _LANGUAGE_BAM; // Bambara\n\t$lang['ban'] = _LANGUAGE_BAN; // Balinese\n\t$lang['bas'] = _LANGUAGE_BAS; // Basa\n\t$lang['bat'] = _LANGUAGE_BAT; // Baltic (Other)\n\t$lang['bej'] = _LANGUAGE_BEJ; // Beja\n\t$lang['bel'] = _LANGUAGE_BEL; // Belarusian\n\t$lang['bem'] = _LANGUAGE_BEM; // Bemba\n\t$lang['ben'] = _LANGUAGE_BEN; // Bengali\n\t$lang['ber'] = _LANGUAGE_BER; // Berber (Other)\n\t$lang['bho'] = _LANGUAGE_BHO; // Bhojpuri\n\t$lang['bih'] = _LANGUAGE_BIH; // Bihari\n\t$lang['bik'] = _LANGUAGE_BIK; // Bikol\n\t$lang['bin'] = _LANGUAGE_BIN; // Bini\n\t$lang['bis'] = _LANGUAGE_BIS; // Bislama\n\t$lang['bla'] = _LANGUAGE_BLA; // Siksika\n\t$lang['bnt'] = _LANGUAGE_BNT; // Bantu (Other)\n\t$lang['bod'] = _LANGUAGE_BOD; // Tibetan\n\t$lang['bos'] = _LANGUAGE_BOS; // Bosnian\n\t$lang['bra'] = _LANGUAGE_BRA; // Braj\n\t$lang['bre'] = _LANGUAGE_BRE; // Breton\n\t$lang['btk'] = _LANGUAGE_BTK; // Batak (Indonesia)\n\t$lang['bua'] = _LANGUAGE_BUA; // Buriat\n\t$lang['bug'] = _LANGUAGE_BUG; // Buginese\n\t$lang['bul'] = _LANGUAGE_BUL; // Bulgarian\n\t$lang['byn'] = _LANGUAGE_BYN; // Blin; Bilin\n\t$lang['cad'] = _LANGUAGE_CAD; // Caddo\n\t$lang['cai'] = _LANGUAGE_CAI; // Central American Indian (Other)\n\t$lang['car'] = _LANGUAGE_CAR; // Carib\n\t$lang['cat'] = _LANGUAGE_CAT; // Catalan; Valencian\n\t$lang['cau'] = _LANGUAGE_CAU; // Caucasian (Other)\n\t$lang['ceb'] = _LANGUAGE_CEB; // Cebuano\n\t$lang['cel'] = _LANGUAGE_CEL; // Celtic (Other)\n\t$lang['ces'] = _LANGUAGE_CES; // Czech\n\t$lang['cha'] = _LANGUAGE_CHA; // Chamorro\n\t$lang['chb'] = _LANGUAGE_CHB; // Chibcha\n\t$lang['che'] = _LANGUAGE_CHE; // Chechen\n\t$lang['chg'] = _LANGUAGE_CHG; // Chagatai\n\t$lang['chk'] = _LANGUAGE_CHK; // Chuukese\n\t$lang['chm'] = _LANGUAGE_CHM; // Mari\n\t$lang['chn'] = _LANGUAGE_CHN; // Chinook jargon\n\t$lang['cho'] = _LANGUAGE_CHO; // Choctaw\n\t$lang['chp'] = _LANGUAGE_CHP; // Chipewyan\n\t$lang['chr'] = _LANGUAGE_CHR; // Cherokee\n\t$lang['chu'] = _LANGUAGE_CHU; // Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic\n\t$lang['chv'] = _LANGUAGE_CHV; // Chuvash\n\t$lang['chy'] = _LANGUAGE_CHY; // Cheyenne\n\t$lang['cmc'] = _LANGUAGE_CMC; // Chamic languages\n\t$lang['cop'] = _LANGUAGE_COP; // Coptic\n\t$lang['cor'] = _LANGUAGE_COR; // Cornish\n\t$lang['cos'] = _LANGUAGE_COS; // Corsican\n\t$lang['cpe'] = _LANGUAGE_CPE; // Creoles and pidgins, English based (Other)\n\t$lang['cpf'] = _LANGUAGE_CPF; // Creoles and pidgins, French-based (Other)\n\t$lang['cpp'] = _LANGUAGE_CPP; // Creoles and pidgins,\n\t$lang['cre'] = _LANGUAGE_CRE; // Cree\n\t$lang['crh'] = _LANGUAGE_CRH; // Crimean Tatar; Crimean Turkish\n\t$lang['crp'] = _LANGUAGE_CRP; // Creoles and pidgins (Other)\n\t$lang['csb'] = _LANGUAGE_CSB; // Kashubian\n\t$lang['cus'] = _LANGUAGE_CUS; // Cushitic (Other)\n\t$lang['cym'] = _LANGUAGE_CYM; // Welsh\n\t$lang['dak'] = _LANGUAGE_DAK; // Dakota\n\t$lang['dan'] = _LANGUAGE_DAN; // Danish\n\t$lang['dar'] = _LANGUAGE_DAR; // Dargwa\n\t$lang['day'] = _LANGUAGE_DAY; // Dayak\n\t$lang['del'] = _LANGUAGE_DEL; // Delaware\n\t$lang['den'] = _LANGUAGE_DEN; // Slave (Athapascan)\n\t$lang['deu'] = _LANGUAGE_DEU; // German\n\t$lang['dgr'] = _LANGUAGE_DGR; // Dogrib\n\t$lang['din'] = _LANGUAGE_DIN; // Dinka\n\t$lang['div'] = _LANGUAGE_DIV; // Divehi\n\t$lang['doi'] = _LANGUAGE_DOI; // Dogri\n\t$lang['dra'] = _LANGUAGE_DRA; // Dravidian (Other)\n\t$lang['dsb'] = _LANGUAGE_DSB; // Lower Sorbian\n\t$lang['dua'] = _LANGUAGE_DUA; // Duala\n\t$lang['dum'] = _LANGUAGE_DUM; // Dutch, Middle\n\t$lang['dyu'] = _LANGUAGE_DYU; // Dyula\n\t$lang['dzo'] = _LANGUAGE_DZO; // Dzongkha\n\t$lang['efi'] = _LANGUAGE_EFI; // Efik\n\t$lang['egy'] = _LANGUAGE_EGY; // Egyptian (Ancient)\n\t$lang['eka'] = _LANGUAGE_EKA; // Ekajuk\n\t$lang['ell'] = _LANGUAGE_ELL; // Greek, Modern\n\t$lang['elx'] = _LANGUAGE_ELX; // Elamite\n\t$lang['eng'] = _LANGUAGE_ENG; // English\n\t$lang['enm'] = _LANGUAGE_ENM; // English, Middle\n\t$lang['epo'] = _LANGUAGE_EPO; // Esperanto\n\t$lang['est'] = _LANGUAGE_EST; // Estonian\n\t$lang['eus'] = _LANGUAGE_EUS; // Basque\n\t$lang['ewe'] = _LANGUAGE_EWE; // Ewe\n\t$lang['ewo'] = _LANGUAGE_EWO; // Ewondo\n\t$lang['fan'] = _LANGUAGE_FAN; // Fang\n\t$lang['fao'] = _LANGUAGE_FAO; // Faroese\n\t$lang['fas'] = _LANGUAGE_FAS; // Persian\n\t$lang['fat'] = _LANGUAGE_FAT; // Fanti\n\t$lang['fij'] = _LANGUAGE_FIJ; // Fijian\n\t$lang['fin'] = _LANGUAGE_FIN; // Finnish\n\t$lang['fiu'] = _LANGUAGE_FIU; // Finno-Ugrian (Other)\n\t$lang['fon'] = _LANGUAGE_FON; // Fon\n\t$lang['fra'] = _LANGUAGE_FRA; // French\n\t$lang['frm'] = _LANGUAGE_FRM; // French, Middle\n\t$lang['fro'] = _LANGUAGE_FRO; // French, Old\n\t$lang['fry'] = _LANGUAGE_FRY; // Frisian\n\t$lang['ful'] = _LANGUAGE_FUL; // Fulah\n\t$lang['fur'] = _LANGUAGE_FUR; // Friulian\n\t$lang['gaa'] = _LANGUAGE_GAA; // Ga\n\t$lang['gay'] = _LANGUAGE_GAY; // Gayo\n\t$lang['gba'] = _LANGUAGE_GBA; // Gbaya\n\t$lang['gem'] = _LANGUAGE_GEM; // Germanic (Other)\n\t$lang['gez'] = _LANGUAGE_GEZ; // Geez\n\t$lang['gil'] = _LANGUAGE_GIL; // Gilbertese\n\t$lang['gla'] = _LANGUAGE_GLA; // Gaelic; Scottish Gaelic\n\t$lang['gle'] = _LANGUAGE_GLE; // Irish\n\t$lang['glg'] = _LANGUAGE_GLG; // Galician\n\t$lang['glv'] = _LANGUAGE_GLV; // Manx\n\t$lang['gmh'] = _LANGUAGE_GMH; // German, Middle High\n\t$lang['goh'] = _LANGUAGE_GOH; // German, Old High\n\t$lang['gon'] = _LANGUAGE_GON; // Gondi\n\t$lang['gor'] = _LANGUAGE_GOR; // Gorontalo\n\t$lang['got'] = _LANGUAGE_GOT; // Gothic\n\t$lang['grb'] = _LANGUAGE_GRB; // Grebo\n\t$lang['grc'] = _LANGUAGE_GRC; // Greek, Ancient\n\t$lang['grn'] = _LANGUAGE_GRN; // Guarani\n\t$lang['guj'] = _LANGUAGE_GUJ; // Gujarati\n\t$lang['gwi'] = _LANGUAGE_GWI; // Gwich´in\n\t$lang['hai'] = _LANGUAGE_HAI; // Haida\n\t$lang['hat'] = _LANGUAGE_HAT; // Haitian; Haitian Creole\n\t$lang['hau'] = _LANGUAGE_HAU; // Hausa\n\t$lang['haw'] = _LANGUAGE_HAW; // Hawaiian\n\t$lang['heb'] = _LANGUAGE_HEB; // Hebrew\n\t$lang['her'] = _LANGUAGE_HER; // Herero\n\t$lang['hil'] = _LANGUAGE_HIL; // Hiligaynon\n\t$lang['him'] = _LANGUAGE_HIM; // Himachali\n\t$lang['hin'] = _LANGUAGE_HIN; // Hindi\n\t$lang['hit'] = _LANGUAGE_HIT; // Hittite\n\t$lang['hmn'] = _LANGUAGE_HMN; // Hmong\n\t$lang['hmo'] = _LANGUAGE_HMO; // Hiri Motu\n\t$lang['hrv'] = _LANGUAGE_HRV; // Croatian\n\t$lang['hsb'] = _LANGUAGE_HSB; // Upper Sorbian\n\t$lang['hun'] = _LANGUAGE_HUN; // Hungarian\n\t$lang['hup'] = _LANGUAGE_HUP; // Hupa\n\t$lang['hye'] = _LANGUAGE_HYE; // Armenian\n\t$lang['iba'] = _LANGUAGE_IBA; // Iban\n\t$lang['ibo'] = _LANGUAGE_IBO; // Igbo\n\t$lang['ido'] = _LANGUAGE_IDO; // Ido\n\t$lang['iii'] = _LANGUAGE_III; // Sichuan Yi\n\t$lang['ijo'] = _LANGUAGE_IJO; // Ijo\n\t$lang['iku'] = _LANGUAGE_IKU; // Inuktitut\n\t$lang['ile'] = _LANGUAGE_ILE; // Interlingue\n\t$lang['ilo'] = _LANGUAGE_ILO; // Iloko\n\t$lang['ina'] = _LANGUAGE_INA; // Interlingua (International Auxiliary Language Association)\n\t$lang['inc'] = _LANGUAGE_INC; // Indic (Other)\n\t$lang['ind'] = _LANGUAGE_IND; // Indonesian\n\t$lang['ine'] = _LANGUAGE_INE; // Indo-European (Other)\n\t$lang['inh'] = _LANGUAGE_INH; // Ingush\n\t$lang['ipk'] = _LANGUAGE_IPK; // Inupiaq\n\t$lang['ira'] = _LANGUAGE_IRA; // Iranian (Other)\n\t$lang['iro'] = _LANGUAGE_IRO; // Iroquoian languages\n\t$lang['isl'] = _LANGUAGE_ISL; // Icelandic\n\t$lang['ita'] = _LANGUAGE_ITA; // Italian\n\t$lang['jav'] = _LANGUAGE_JAV; // Javanese\n\t$lang['jbo'] = _LANGUAGE_JBO; // Lojban\n\t$lang['jpn'] = _LANGUAGE_JPN; // Japanese\n\t$lang['jpr'] = _LANGUAGE_JPR; // Judeo-Persian\n\t$lang['jrb'] = _LANGUAGE_JRB; // Judeo-Arabic\n\t$lang['kaa'] = _LANGUAGE_KAA; // Kara-Kalpak\n\t$lang['kab'] = _LANGUAGE_KAB; // Kabyle\n\t$lang['kac'] = _LANGUAGE_KAC; // Kachin\n\t$lang['kal'] = _LANGUAGE_KAL; // Kalaallisut; Greenlandic\n\t$lang['kam'] = _LANGUAGE_KAM; // Kamba\n\t$lang['kan'] = _LANGUAGE_KAN; // Kannada\n\t$lang['kar'] = _LANGUAGE_KAR; // Karen\n\t$lang['kas'] = _LANGUAGE_KAS; // Kashmiri\n\t$lang['kat'] = _LANGUAGE_KAT; // Georgian\n\t$lang['kau'] = _LANGUAGE_KAU; // Kanuri\n\t$lang['kaw'] = _LANGUAGE_KAW; // Kawi\n\t$lang['kaz'] = _LANGUAGE_KAZ; // Kazakh\n\t$lang['kbd'] = _LANGUAGE_KBD; // Kabardian\n\t$lang['kha'] = _LANGUAGE_KHA; // Khasi\n\t$lang['khi'] = _LANGUAGE_KHI; // Khoisan (Other)\n\t$lang['khm'] = _LANGUAGE_KHM; // Khmer\n\t$lang['kho'] = _LANGUAGE_KHO; // Khotanese\n\t$lang['kik'] = _LANGUAGE_KIK; // Kikuyu; Gikuyu\n\t$lang['kin'] = _LANGUAGE_KIN; // Kinyarwanda\n\t$lang['kir'] = _LANGUAGE_KIR; // Kirghiz\n\t$lang['kmb'] = _LANGUAGE_KMB; // Kimbundu\n\t$lang['kok'] = _LANGUAGE_KOK; // Konkani\n\t$lang['kom'] = _LANGUAGE_KOM; // Komi\n\t$lang['kon'] = _LANGUAGE_KON; // Kongo\n\t$lang['kor'] = _LANGUAGE_KOR; // Korean\n\t$lang['kos'] = _LANGUAGE_KOS; // Kosraean\n\t$lang['kpe'] = _LANGUAGE_KPE; // Kpelle\n\t$lang['krc'] = _LANGUAGE_KRC; // Karachay-Balkar\n\t$lang['kro'] = _LANGUAGE_KRO; // Kru\n\t$lang['kru'] = _LANGUAGE_KRU; // Kurukh\n\t$lang['kua'] = _LANGUAGE_KUA; // Kuanyama; Kwanyama\n\t$lang['kum'] = _LANGUAGE_KUM; // Kumyk\n\t$lang['kur'] = _LANGUAGE_KUR; // Kurdish\n\t$lang['kut'] = _LANGUAGE_KUT; // Kutenai\n\t$lang['lad'] = _LANGUAGE_LAD; // Ladino\n\t$lang['lah'] = _LANGUAGE_LAH; // Lahnda\n\t$lang['lam'] = _LANGUAGE_LAM; // Lamba\n\t$lang['lao'] = _LANGUAGE_LAO; // Lao\n\t$lang['lat'] = _LANGUAGE_LAT; // Latin\n\t$lang['lav'] = _LANGUAGE_LAV; // Latvian\n\t$lang['lez'] = _LANGUAGE_LEZ; // Lezghian\n\t$lang['lim'] = _LANGUAGE_LIM; // Limburgan; Limburger; Limburgish\n\t$lang['lin'] = _LANGUAGE_LIN; // Lingala\n\t$lang['lit'] = _LANGUAGE_LIT; // Lithuanian\n\t$lang['lol'] = _LANGUAGE_LOL; // Mongo\n\t$lang['loz'] = _LANGUAGE_LOZ; // Lozi\n\t$lang['ltz'] = _LANGUAGE_LTZ; // Luxembourgish; Letzeburgesch\n\t$lang['lua'] = _LANGUAGE_LUA; // Luba-Lulua\n\t$lang['lub'] = _LANGUAGE_LUB; // Luba-Katanga\n\t$lang['lug'] = _LANGUAGE_LUG; // Ganda\n\t$lang['lui'] = _LANGUAGE_LUI; // Luiseno\n\t$lang['lun'] = _LANGUAGE_LUN; // Lunda\n\t$lang['luo'] = _LANGUAGE_LUO; // Luo (Kenya and Tanzania)\n\t$lang['lus'] = _LANGUAGE_LUS; // lushai\n\t$lang['mad'] = _LANGUAGE_MAD; // Madurese\n\t$lang['mag'] = _LANGUAGE_MAG; // Magahi\n\t$lang['mah'] = _LANGUAGE_MAH; // Marshallese\n\t$lang['mai'] = _LANGUAGE_MAI; // Maithili\n\t$lang['mak'] = _LANGUAGE_MAK; // Makasar\n\t$lang['mal'] = _LANGUAGE_MAL; // Malayalam\n\t$lang['man'] = _LANGUAGE_MAN; // Mandingo\n\t$lang['map'] = _LANGUAGE_MAP; // Austronesian (Other)\n\t$lang['mar'] = _LANGUAGE_MAR; // Marathi\n\t$lang['mas'] = _LANGUAGE_MAS; // Masai\n\t$lang['mdf'] = _LANGUAGE_MDF; // Moksha\n\t$lang['mdr'] = _LANGUAGE_MDR; // Mandar\n\t$lang['men'] = _LANGUAGE_MEN; // Mende\n\t$lang['mga'] = _LANGUAGE_MGA; // Irish, Middle\n\t$lang['mic'] = _LANGUAGE_MIC; // Micmac\n\t$lang['min'] = _LANGUAGE_MIN; // Minangkabau\n\t$lang['mis'] = _LANGUAGE_MIS; // Miscellaneous languages\n\t$lang['mkd'] = _LANGUAGE_MKD; // Macedonian\n\t$lang['mkh'] = _LANGUAGE_MKH; // Mon-Khmer (Other)\n\t$lang['mlg'] = _LANGUAGE_MLG; // Malagasy\n\t$lang['mlt'] = _LANGUAGE_MLT; // Maltese\n\t$lang['mnc'] = _LANGUAGE_MNC; // Manchu\n\t$lang['mni'] = _LANGUAGE_MNI; // Manipuri\n\t$lang['mno'] = _LANGUAGE_MNO; // Manobo languages\n\t$lang['moh'] = _LANGUAGE_MOH; // Mohawk\n\t$lang['mol'] = _LANGUAGE_MOL; // Moldavian\n\t$lang['mon'] = _LANGUAGE_MON; // Mongolian\n\t$lang['mos'] = _LANGUAGE_MOS; // Mossi\n\t$lang['mri'] = _LANGUAGE_MRI; // Maori\n\t$lang['msa'] = _LANGUAGE_MSA; // Malay\n\t$lang['mul'] = _LANGUAGE_MUL; // Multiple languages\n\t$lang['mun'] = _LANGUAGE_MUN; // Munda languages\n\t$lang['mus'] = _LANGUAGE_MUS; // Creek\n\t$lang['mwr'] = _LANGUAGE_MWR; // Marwari\n\t$lang['mya'] = _LANGUAGE_MYA; // Burmese\n\t$lang['myn'] = _LANGUAGE_MYN; // Mayan languages\n\t$lang['myv'] = _LANGUAGE_MYV; // Erzya\n\t$lang['nah'] = _LANGUAGE_NAH; // Nahuatl\n\t$lang['nai'] = _LANGUAGE_NAI; // North American Indian\n\t$lang['nap'] = _LANGUAGE_NAP; // Neapolitan\n\t$lang['nau'] = _LANGUAGE_NAU; // Nauru\n\t$lang['nav'] = _LANGUAGE_NAV; // Navajo; Navaho\n\t$lang['nbl'] = _LANGUAGE_NBL; // Ndebele, South; South Ndebele\n\t$lang['nde'] = _LANGUAGE_NDE; // Ndebele, North; North Ndebele\n\t$lang['ndo'] = _LANGUAGE_NDO; // Ndonga\n\t$lang['nds'] = _LANGUAGE_NDS; // Low German; Low Saxon; German, Low; Saxon, Low\n\t$lang['nep'] = _LANGUAGE_NEP; // Nepali\n\t$lang['new'] = _LANGUAGE_NEW; // Newari; Nepal Bhasa\n\t$lang['nia'] = _LANGUAGE_NIA; // Nias\n\t$lang['nic'] = _LANGUAGE_NIC; // Niger-Kordofanian (Other)\n\t$lang['niu'] = _LANGUAGE_NIU; // Niuean\n\t$lang['nld'] = _LANGUAGE_NLD; // Dutch; Flemish\n\t$lang['nno'] = _LANGUAGE_NNO; // Norwegian Nynorsk; Nynorsk, Norwegian\n\t$lang['nob'] = _LANGUAGE_NOB; // Norwegian Bokmċl; Bokmċl, Norwegian\n\t$lang['nog'] = _LANGUAGE_NOG; // Nogai\n\t$lang['non'] = _LANGUAGE_NON; // Norse, Old\n\t$lang['nor'] = _LANGUAGE_NOR; // Norwegian\n\t$lang['nso'] = _LANGUAGE_NSO; // Sotho, Northern\n\t$lang['nub'] = _LANGUAGE_NUB; // Nubian languages\n\t$lang['nwc'] = _LANGUAGE_NWC; // Classical Newari; Old Newari; Classical Nepal Bhasa\n\t$lang['nya'] = _LANGUAGE_NYA; // Chichewa; Chewa; Nyanja\n\t$lang['nym'] = _LANGUAGE_NYM; // Nyamwezi\n\t$lang['nyn'] = _LANGUAGE_NYN; // Nyankole\n\t$lang['nyo'] = _LANGUAGE_NYO; // Nyoro\n\t$lang['nzi'] = _LANGUAGE_NZI; // Nzima\n\t$lang['oci'] = _LANGUAGE_OCI; // Occitan; Provençal\n\t$lang['oji'] = _LANGUAGE_OJI; // Ojibwa\n\t$lang['ori'] = _LANGUAGE_ORI; // Oriya\n\t$lang['orm'] = _LANGUAGE_ORM; // Oromo\n\t$lang['osa'] = _LANGUAGE_OSA; // Osage\n\t$lang['oss'] = _LANGUAGE_OSS; // Ossetian; Ossetic\n\t$lang['ota'] = _LANGUAGE_OTA; // Turkish, Ottoman\n\t$lang['oto'] = _LANGUAGE_OTO; // Otomian languages\n\t$lang['paa'] = _LANGUAGE_PAA; // Papuan (Other)\n\t$lang['pag'] = _LANGUAGE_PAG; // Pangasinan\n\t$lang['pal'] = _LANGUAGE_PAL; // Pahlavi\n\t$lang['pam'] = _LANGUAGE_PAM; // Pampanga\n\t$lang['pan'] = _LANGUAGE_PAN; // Panjabi; Punjabi\n\t$lang['pap'] = _LANGUAGE_PAP; // Papiamento\n\t$lang['pau'] = _LANGUAGE_PAU; // Palauan\n\t$lang['peo'] = _LANGUAGE_PEO; // Persian, Old\n\t$lang['phi'] = _LANGUAGE_PHI; // Philippine (Other)\n\t$lang['phn'] = _LANGUAGE_PHN; // Phoenician\n\t$lang['pli'] = _LANGUAGE_PLI; // Pali\n\t$lang['pol'] = _LANGUAGE_POL; // Polish\n\t$lang['pon'] = _LANGUAGE_PON; // Pohnpeian\n\t$lang['por'] = _LANGUAGE_POR; // Portuguese\n\t$lang['pra'] = _LANGUAGE_PRA; // Prakrit languages\n\t$lang['pro'] = _LANGUAGE_PRO; // Provençal, Old\n\t$lang['pus'] = _LANGUAGE_PUS; // Pushto\n\t$lang['qaa-qtz'] = _LANGUAGE_QAA_QTZ; // Reserved for local use\n\t$lang['que'] = _LANGUAGE_QUE; // Quechua\n\t$lang['raj'] = _LANGUAGE_RAJ; // Rajasthani\n\t$lang['rap'] = _LANGUAGE_RAP; // Rapanui\n\t$lang['rar'] = _LANGUAGE_RAR; // Rarotongan\n\t$lang['roa'] = _LANGUAGE_ROA; // Romance (Other)\n\t$lang['roh'] = _LANGUAGE_ROH; // Raeto-Romance\n\t$lang['rom'] = _LANGUAGE_ROM; // Romany\n\t$lang['ron'] = _LANGUAGE_RON; // Romanian\n\t$lang['run'] = _LANGUAGE_RUN; // Rundi\n\t$lang['rus'] = _LANGUAGE_RUS; // Russian\n\t$lang['sad'] = _LANGUAGE_SAD; // Sandawe\n\t$lang['sag'] = _LANGUAGE_SAG; // Sango\n\t$lang['sah'] = _LANGUAGE_SAH; // Yakut\n\t$lang['sai'] = _LANGUAGE_SAI; // South American Indian (Other)\n\t$lang['sal'] = _LANGUAGE_SAL; // Salishan languages\n\t$lang['sam'] = _LANGUAGE_SAM; // Samaritan Aramaic\n\t$lang['san'] = _LANGUAGE_SAN; // Sanskrit\n\t$lang['sas'] = _LANGUAGE_SAS; // Sasak\n\t$lang['sat'] = _LANGUAGE_SAT; // Santali\n\t$lang['sco'] = _LANGUAGE_SCO; // Scots\n\t$lang['scr'] = _LANGUAGE_SCR; // Serbo-Croatian\n\t$lang['sel'] = _LANGUAGE_SEL; // Selkup\n\t$lang['sem'] = _LANGUAGE_SEM; // Semitic (Other)\n\t$lang['sga'] = _LANGUAGE_SGA; // Irish, Old\n\t$lang['sgn'] = _LANGUAGE_SGN; // Sign Languages\n\t$lang['shn'] = _LANGUAGE_SHN; // Shan\n\t$lang['sid'] = _LANGUAGE_SID; // Sidamo\n\t$lang['sin'] = _LANGUAGE_SIN; // Sinhalese\n\t$lang['sio'] = _LANGUAGE_SIO; // Siouan languages\n\t$lang['sit'] = _LANGUAGE_SIT; // Sino-Tibetan (Other)\n\t$lang['sla'] = _LANGUAGE_SLA; // Slavic (Other)\n\t$lang['slk'] = _LANGUAGE_SLK; // Slovak\n\t$lang['slv'] = _LANGUAGE_SLV; // Slovenian\n\t$lang['sma'] = _LANGUAGE_SMA; // Southern Sami\n\t$lang['sme'] = _LANGUAGE_SME; // Northern Sami\n\t$lang['smi'] = _LANGUAGE_SMI; // Sami languages (Other)\n\t$lang['smj'] = _LANGUAGE_SMJ; // Lule Sami\n\t$lang['smn'] = _LANGUAGE_SMN; // Inari Sami\n\t$lang['smo'] = _LANGUAGE_SMO; // Samoan\n\t$lang['sms'] = _LANGUAGE_SMS; // Skolt Sami\n\t$lang['sna'] = _LANGUAGE_SNA; // Shona\n\t$lang['snd'] = _LANGUAGE_SND; // Sindhi\n\t$lang['snk'] = _LANGUAGE_SNK; // Soninke\n\t$lang['sog'] = _LANGUAGE_SOG; // Sogdian\n\t$lang['som'] = _LANGUAGE_SOM; // Somali\n\t$lang['son'] = _LANGUAGE_SON; // Songhai\n\t$lang['sot'] = _LANGUAGE_SOT; // Sotho, Southern\n\t$lang['spa'] = _LANGUAGE_SPA; // Spanish; Castilian\n\t$lang['sqi'] = _LANGUAGE_SQI; // Albanian\n\t$lang['srd'] = _LANGUAGE_SRD; // Sardinian\n\t$lang['srp'] = _LANGUAGE_SRP; // Serbian\n\t$lang['srr'] = _LANGUAGE_SRR; // Serer\n\t$lang['ssa'] = _LANGUAGE_SSA; // Nilo-Saharan (Other)\n\t$lang['ssw'] = _LANGUAGE_SSW; // Swati\n\t$lang['suk'] = _LANGUAGE_SUK; // Sukuma\n\t$lang['sun'] = _LANGUAGE_SUN; // Sundanese\n\t$lang['sus'] = _LANGUAGE_SUS; // Susu\n\t$lang['sux'] = _LANGUAGE_SUX; // Sumerian\n\t$lang['swa'] = _LANGUAGE_SWA; // Swahili\n\t$lang['swe'] = _LANGUAGE_SWE; // Swedish\n\t$lang['syr'] = _LANGUAGE_SYR; // Syriac\n\t$lang['tah'] = _LANGUAGE_TAH; // Tahitian\n\t$lang['tai'] = _LANGUAGE_TAI; // Tai (Other)\n\t$lang['tam'] = _LANGUAGE_TAM; // Tamil\n\t$lang['tat'] = _LANGUAGE_TAT; // Tatar\n\t$lang['tel'] = _LANGUAGE_TEL; // Telugu\n\t$lang['tem'] = _LANGUAGE_TEM; // Timne\n\t$lang['ter'] = _LANGUAGE_TER; // Tereno\n\t$lang['tet'] = _LANGUAGE_TET; // Tetum\n\t$lang['tgk'] = _LANGUAGE_TGK; // Tajik\n\t$lang['tgl'] = _LANGUAGE_TGL; // Tagalog\n\t$lang['tha'] = _LANGUAGE_THA; // Thai\n\t$lang['tig'] = _LANGUAGE_TIG; // Tigre\n\t$lang['tir'] = _LANGUAGE_TIR; // Tigrinya\n\t$lang['tiv'] = _LANGUAGE_TIV; // Tiv\n\t$lang['tkl'] = _LANGUAGE_TKL; // Tokelau\n\t$lang['tlh'] = _LANGUAGE_TLH; // Klingon; tlhlngan-Hol\n\t$lang['tli'] = _LANGUAGE_TLI; // Tlingit\n\t$lang['tmh'] = _LANGUAGE_TMH; // Tamashek\n\t$lang['tog'] = _LANGUAGE_TOG; // Tonga (Nyasa)\n\t$lang['ton'] = _LANGUAGE_TON; // Tonga (Tonga Islands)\n\t$lang['tpi'] = _LANGUAGE_TPI; // Tok Pisin\n\t$lang['tsi'] = _LANGUAGE_TSI; // Tsimshian\n\t$lang['tsn'] = _LANGUAGE_TSN; // Tswana\n\t$lang['tso'] = _LANGUAGE_TSO; // Tsonga\n\t$lang['tuk'] = _LANGUAGE_TUK; // Turkmen\n\t$lang['tum'] = _LANGUAGE_TUM; // Tumbuka\n\t$lang['tup'] = _LANGUAGE_TUP; // Tupi languages\n\t$lang['tur'] = _LANGUAGE_TUR; // Turkish\n\t$lang['tut'] = _LANGUAGE_TUT; // Altaic (Other)\n\t$lang['tvl'] = _LANGUAGE_TVL; // Tuvalu\n\t$lang['twi'] = _LANGUAGE_TWI; // Twi\n\t$lang['tyv'] = _LANGUAGE_TYV; // Tuvinian\n\t$lang['udm'] = _LANGUAGE_UDM; // Udmurt\n\t$lang['uga'] = _LANGUAGE_UGA; // Ugaritic\n\t$lang['uig'] = _LANGUAGE_UIG; // Uighur\n\t$lang['ukr'] = _LANGUAGE_UKR; // Ukrainian\n\t$lang['umb'] = _LANGUAGE_UMB; // Umbundu\n\t$lang['und'] = _LANGUAGE_UND; // Undetermined\n\t$lang['urd'] = _LANGUAGE_URD; // Urdu\n\t$lang['uzb'] = _LANGUAGE_UZB; // Uzbek\n\t$lang['vai'] = _LANGUAGE_VAI; // Vai\n\t$lang['ven'] = _LANGUAGE_VEN; // Venda\n\t$lang['vie'] = _LANGUAGE_VIE; // Vietnamese\n\t$lang['vol'] = _LANGUAGE_VOL; // Volapük\n\t$lang['vot'] = _LANGUAGE_VOT; // Votic\n\t$lang['wak'] = _LANGUAGE_WAK; // Wakashan languages\n\t$lang['wal'] = _LANGUAGE_WAL; // Walamo\n\t$lang['war'] = _LANGUAGE_WAR; // Waray\n\t$lang['was'] = _LANGUAGE_WAS; // Washo\n\t$lang['wen'] = _LANGUAGE_WEN; // Sorbian languages\n\t$lang['wln'] = _LANGUAGE_WLN; // Walloon\n\t$lang['wol'] = _LANGUAGE_WOL; // Wolof\n\t$lang['xal'] = _LANGUAGE_XAL; // Kalmyk\n\t$lang['xho'] = _LANGUAGE_XHO; // Xhosa\n\t$lang['yao'] = _LANGUAGE_YAO; // Yao\n\t$lang['yap'] = _LANGUAGE_YAP; // Yapese\n\t$lang['yid'] = _LANGUAGE_YID; // Yiddish\n\t$lang['yor'] = _LANGUAGE_YOR; // Yoruba\n\t$lang['ypk'] = _LANGUAGE_YPK; // Yupik languages\n\t$lang['zap'] = _LANGUAGE_ZAP; // Zapotec\n\t$lang['zen'] = _LANGUAGE_ZEN; // Zenaga\n\t$lang['zha'] = _LANGUAGE_ZHA; // Zhuang; Chuang\n\t$lang['zho'] = _LANGUAGE_ZHO; // Chinese\n\t$lang['znd'] = _LANGUAGE_ZND; // Zande\n\t$lang['zul'] = _LANGUAGE_ZUL; // Zulu\n\t$lang['zun'] = _LANGUAGE_ZUN; // Zuni\n\t// Non-ISO entries are written as x_[language name]\n\t$lang['x_all'] = _ALL; // all languages\n\t$lang['x_brazilian_portuguese'] = _LANGUAGE_X_BRAZILIAN_PORTUGUESE; // Brazilian Portuguese\n\t$lang['x_rus_koi8r'] = _LANGUAGE_X_RUS_KOI8R; // Russian KOI8-R\n\t// end of list\n\treturn $lang;\n}", "function getPNlanguage()\n{\n\tpnBlockLoad('Core', 'thelang');\n// All entries use ISO 639-2/T\n\t$lang['ara'] = \"Arabic\";\n\t$lang['alb'] = \"Albanian\"; \n\t$lang['bul'] = \"Bulgarian\";\n\t$lang['zho'] = \"Chinese\";\n\t$lang['cat'] = \"Catalan\";\n\t$lang['ces'] = \"Czech\";\n\t$lang['hrv'] = \"Croatian HRV\";\n\t$lang['cro'] = \"Croatian CRO\";\n\t$lang['dan'] = \"Danish\";\n\t$lang['nld'] = \"Dutch\";\n\t$lang['eng'] = \"English\";\n\t$lang['epo'] = \"Esperanto\";\n\t$lang['est'] = \"Estonian\";\n\t$lang['fin'] = \"Finnish\";\n\t$lang['fra'] = \"French\";\n\t$lang['deu'] = \"German\";\n\t$lang['ell'] = \"Greek\";\n\t$lang['heb'] = \"Hebrew\";\n\t$lang['hun'] = \"Hungarian\";\n\t$lang['isl'] = \"Icelandic\";\n\t$lang['ind'] = \"Indonesian\";\n\t$lang['ita'] = \"Italian\";\n\t$lang['jpn'] = \"Japanese\";\n\t$lang['kor'] = \"Korean\";\n\t$lang['lav'] = \"Latvian\";\n\t$lang['lit'] = \"Lithuanian\";\n\t$lang['mas'] = \"Malay\";\n\t$lang['mkd'] = \"Macedonian\";\n\t$lang['nor'] = \"Norwegian\";\n\t$lang['pol'] = \"Polish\";\n\t$lang['por'] = \"Portuguese\";\n\t$lang['ron'] = \"Romanian\";\n\t$lang['rus'] = \"Russian\";\n\t$lang['slv'] = \"Slovenian\";\n\t$lang['spa'] = \"Spanish\";\n\t$lang['swe'] = \"Swedish\";\n\t$lang['tha'] = \"Thai\";\n\t$lang['tur'] = \"Turkish\";\n\t$lang['ukr'] = \"Ukrainian\";\n\t$lang['yid'] = \"Yiddish\";\n\n\treturn strtolower($lang[pnSessionGetVar('lang')]);\n}", "function lixlpixel_detect_lang()\n{\n lixlpixel_get_env_var('HTTP_ACCEPT_LANGUAGE');\n lixlpixel_get_env_var('HTTP_USER_AGENT');\n\n $_AL=strtolower($GLOBALS['HTTP_ACCEPT_LANGUAGE']);\n $_UA=strtolower($GLOBALS['HTTP_USER_AGENT']);\n\n // Try to detect Primary language if several languages are accepted.\n foreach($GLOBALS['_LANG'] as $K)\n {\n if(strpos($_AL, $K)===0)\n return $K;\n }\n \n // Try to detect any language if not yet detected.\n foreach($GLOBALS['_LANG'] as $K)\n {\n if(strpos($_AL, $K)!==false)\n return $K;\n }\n foreach($GLOBALS['_LANG'] as $K)\n {\n if(preg_match(\"//[\\[\\( ]{$K}[;,_\\-\\)]//\",$_UA))\n return $K;\n }\n\n // Return default language if language is not yet detected.\n return $GLOBALS['_DLANG'];\n}", "public function resolveLocale(Request $request);", "public static function locale() : string\n {\n // Compute the locale just one time\n if (self::$locale) {\n return self::$locale;\n }\n\n // Lang in cookies\n $locale = self::langToLocale($_COOKIE['NameYourGoat_User_Locale'] ?? '');\n\n // Lang in User repository\n if (! $locale && self::isAuth()) {\n $locale = self::langToLocale(self::$fullUser->lang);\n }\n\n // Lang in the request headers\n if (! $locale) {\n $acceptLang = explode(',', getallheaders()['Accept-Language'] ?? '');\n\n foreach ($acceptLang as $lang) {\n if ($locale = self::langToLocale(trim(strtok($lang, '-;')))) {\n break;\n }\n }\n }\n\n return self::$locale = $locale ?: self::$defaultLocale;\n }", "private function detectLanguage()\n {\n $lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);\n\n switch (mb_strtolower($lang)) {\n case 'ru':\n return 'russian';\n\n default:\n return 'english';\n }\n }", "function mLANG(){\n try {\n $_type = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$LANG;\n $_channel = Erfurt_Sparql_Parser_Sparql11_Update_Tokenizer11::$DEFAULT_TOKEN_CHANNEL;\n // Tokenizer11.g:231:3: ( 'lang' ) \n // Tokenizer11.g:232:3: 'lang' \n {\n $this->matchString(\"lang\"); \n\n\n }\n\n $this->state->type = $_type;\n $this->state->channel = $_channel;\n }\n catch(Exception $e){\n throw $e;\n }\n }", "private static function loadLanguage($lang){\n\t\t$descriptions = array();\n\n\t\t$locale = 'locale/'.$lang.'.php';\n\t\trequire($locale);\n\n\t\treturn (object)$descriptions;\n\t}", "function localize($phrase) {\n global $translations;\n /* Static keyword is used to ensure the file is loaded only once */\n if ($translations[$phrase])\n return $translations[$phrase];\n else\n return $phrase;\n}", "public function parse($string);", "function getAsString( $lang = 'en' )\n {\n $locale_names['en']['second'] = ' second';\n $locale_names['en']['seconds'] = ' seconds';\n $locale_names['en']['minute'] = ' minute';\n $locale_names['en']['minutes'] = ' minutes';\n $locale_names['en']['hour'] = ' hour';\n $locale_names['en']['hours'] = ' hours';\n $locale_names['en']['day'] = ' day';\n $locale_names['en']['days'] = ' days';\n $locale_names['en']['week'] = ' week';\n $locale_names['en']['weeks'] = ' weeks';\n $locale_names['en']['month'] = ' month';\n $locale_names['en']['months'] = ' months';\n $locale_names['en']['year'] = ' year';\n $locale_names['en']['years'] = ' years';\n $locale_names['en']['and'] = ' and';\n \n $locale_names['de']['second'] = ' Sekunde';\n $locale_names['de']['seconds'] = ' Sekunden';\n $locale_names['de']['minute'] = ' Minute';\n $locale_names['de']['minutes'] = ' Minuten';\n $locale_names['de']['hour'] = ' Stunde';\n $locale_names['de']['hours'] = ' Stunden';\n $locale_names['de']['day'] = ' Tag';\n $locale_names['de']['days'] = ' Tage';\n $locale_names['de']['week'] = ' Woche';\n $locale_names['de']['weeks'] = ' Wochen';\n $locale_names['de']['month'] = ' Monat';\n $locale_names['de']['months'] = ' Monate';\n $locale_names['de']['year'] = ' Jahr';\n $locale_names['de']['years'] = ' Jahre';\n $locale_names['de']['and'] = ' und';\n \n $_ =& $locale_names[$lang];\n \n $this->updatePorperties();\n \n $time = array();\n \n if ( $difference['fullremdays'] > 1 )\n {\n $time[] = $difference['fullremdays'] . $_['days'];\n }\n elseif ( $difference['fullremdays'] == 1 )\n {\n $time[] = $difference['fullremdays'] . $_['day'];\n }\n \n if ( $difference['fullremhours'] > 1 )\n {\n $time[] = $difference['fullremhours'] . $_['hours'];\n }\n elseif ( $difference['fullremhours'] == 1 )\n {\n $time[] = $difference['fullremhours'] . $_['hour'];\n }\n \n if ( $difference['fullremminutes'] > 1 )\n {\n $time[] = $difference['fullremminutes'] . $_['minutes'];\n }\n elseif ( $difference['fullremminutes'] == 1 )\n {\n $time[] = $difference['fullremminutes'] . $_['minute'];\n }\n \n if ( $difference['fullremseconds'] > 1 )\n {\n $time[] = $difference['fullremseconds'] . $_['seconds'];\n }\n elseif ( $difference['fullremseconds'] == 1 )\n {\n $time[] = $difference['fullremseconds'] . $_['second'];\n }\n \n $time = implode( ', ', $time );\n if ( strstr( $time, ',' ) )\n {\n $time = substr_replace( $time, $_['and'], strrpos( $time, ',' ), 1 );\n }\n \n return $time;\n }", "public function processLangCode($lang)\n\t{\n\t\t$lang = strtolower($lang);\n\t\tif(isset($this->languages[$lang]))\n\t\t\treturn $lang;\n\t\telse\n\t\t\treturn DEFAULT_LANG;\n\t}", "public function getLangFromHeader() {\n\t\t$arr = $this->getHttpHeader();\n\n\t\t// look through sorted list and use first one that matches our languages\n\t\tforeach ($arr as $lang => $val) {\n\t\t\t$lang = explode('-', $lang);\n\t\t\tif (in_array($lang[0], $this->arrLang)) {\n\t\t\t\treturn $lang[0];\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "public function settingLocale() {}", "function sanitize_locale_name($locale_name)\n {\n }", "public static function langName($lang)\n {\n $langName = [\n\n 'af' => 'Afrikaans',\n 'ar' => 'Arabic',\n 'az' => 'Azerbaijani',\n 'bg' => 'Bulgarian',\n 'be' => 'Belarusian',\n 'bn' => 'Bengali',\n 'br' => 'Breton',\n 'bs' => 'Bosnian',\n 'ca' => 'Catalan',\n 'cs' => 'Czech',\n 'cy' => 'Welsh',\n 'da' => 'Danish',\n 'de' => 'German',\n 'el' => 'Greek',\n 'en' => 'English',\n 'en-gb' => 'British English',\n 'eo' => 'Esperanto',\n 'es' => 'Spanish',\n 'es-ar' => 'Argentinian Spanish',\n 'es-mx' => 'Mexican Spanish',\n 'es-ni' => 'Nicaraguan Spanish',\n 'es-ve' => 'Venezuelan Spanish',\n 'et' => 'Estonian',\n 'eu' => 'Basque',\n 'fa' => 'Persian',\n 'fi' => 'Finnish',\n 'fr' => 'French',\n 'fy-nl' => 'Frisian',\n 'ga' => 'Irish',\n 'gl' => 'Galician',\n 'he' => 'Hebrew',\n 'hi' => 'Hindi',\n 'hr' => 'Croatian',\n 'hu' => 'Hungarian',\n 'ia' => 'Interlingua',\n 'id' => 'Indonesian',\n 'is' => 'Icelandic',\n 'it' => 'Italian',\n 'ja' => 'Japanese',\n 'ka' => 'Georgian',\n 'kk' => 'Kazakh',\n 'km' => 'Khmer',\n 'kn' => 'Kannada',\n 'ko' => 'Korean',\n 'lb' => 'Luxembourgish',\n 'lt' => 'Lithuanian',\n 'lv' => 'Latvian',\n 'mk' => 'Macedonian',\n 'ml' => 'Malayalam',\n 'mn' => 'Mongolian',\n 'my' => 'Burmese',\n 'nb' => 'Norwegian Bokmal',\n 'ne' => 'Nepali',\n 'nl' => 'Dutch',\n 'nn' => 'Norwegian Nynorsk',\n 'os' => 'Ossetic',\n 'pa' => 'Punjabi',\n 'pl' => 'Polish',\n 'pt' => 'Portuguese',\n 'pt-br' => 'Brazilian Portuguese',\n 'ro' => 'Romanian',\n 'ru' => 'Russian',\n 'sk' => 'Slovak',\n 'sl' => 'Slovenian',\n 'sq' => 'Albanian',\n 'sr' => 'Serbian',\n 'sr-latn' => 'Serbian Latin',\n 'sv' => 'Swedish',\n 'sw' => 'Swahili',\n 'ta' => 'Tamil',\n 'te' => 'Telugu',\n 'th' => 'Thai',\n 'tr' => 'Turkish',\n 'tt' => 'Tatar',\n 'udm' => 'Udmurt',\n 'uk' => 'Ukrainian',\n 'ur' => 'Urdu',\n 'vi' => 'Vietnamese',\n 'zh-cn' => 'Simplified Chinese',\n 'zh-tw' => 'Traditional Chinese'\n ];\n\n return $langName[$lang];\n }", "private function setLocale() {\n if ($this->_language == 'french')\n setlocale (LC_ALL, 'fr_FR.iso88591', 'fr_FR@euro', 'fr_FR', 'french', 'fra');\n else if ($this->_language == 'english')\n setlocale (LC_ALL, 'en_GB.iso88591', 'en_GB', 'english', 'eng');\n }", "protected function get_date_locales() {\n\n\t\treturn array(\n\t\t\t'af',\n\t\t\t'ar-dz',\n\t\t\t'ar-kw',\n\t\t\t'ar-ly',\n\t\t\t'ar-ma',\n\t\t\t'ar-sa',\n\t\t\t'ar-tn',\n\t\t\t'ar',\n\t\t\t'az',\n\t\t\t'be',\n\t\t\t'bg',\n\t\t\t'bm',\n\t\t\t'bn',\n\t\t\t'bo',\n\t\t\t'br',\n\t\t\t'bs',\n\t\t\t'ca',\n\t\t\t'cs',\n\t\t\t'cv',\n\t\t\t'cy',\n\t\t\t'da',\n\t\t\t'de-at',\n\t\t\t'de-ch',\n\t\t\t'de',\n\t\t\t'dv',\n\t\t\t'el',\n\t\t\t'en-au',\n\t\t\t'en-ca',\n\t\t\t'en-gb',\n\t\t\t'en-ie',\n\t\t\t'en-il',\n\t\t\t'en-nz',\n\t\t\t'eo',\n\t\t\t'es-do',\n\t\t\t'es-us',\n\t\t\t'es',\n\t\t\t'et',\n\t\t\t'eu',\n\t\t\t'fa',\n\t\t\t'fi',\n\t\t\t'fo',\n\t\t\t'fr-ca',\n\t\t\t'fr-ch',\n\t\t\t'fr',\n\t\t\t'fy',\n\t\t\t'gd',\n\t\t\t'gl',\n\t\t\t'gom-latn',\n\t\t\t'gu',\n\t\t\t'he',\n\t\t\t'hi',\n\t\t\t'hr',\n\t\t\t'hu',\n\t\t\t'hy-am',\n\t\t\t'id',\n\t\t\t'is',\n\t\t\t'it',\n\t\t\t'ja',\n\t\t\t'jv',\n\t\t\t'ka',\n\t\t\t'kk',\n\t\t\t'km',\n\t\t\t'kn',\n\t\t\t'ko',\n\t\t\t'ku',\n\t\t\t'ky',\n\t\t\t'lb',\n\t\t\t'lo',\n\t\t\t'lt',\n\t\t\t'lv',\n\t\t\t'me',\n\t\t\t'mi',\n\t\t\t'mk',\n\t\t\t'ml',\n\t\t\t'mn',\n\t\t\t'mr',\n\t\t\t'ms-my',\n\t\t\t'ms',\n\t\t\t'mt',\n\t\t\t'my',\n\t\t\t'nb',\n\t\t\t'ne',\n\t\t\t'nl-be',\n\t\t\t'nl',\n\t\t\t'nn',\n\t\t\t'pa-in',\n\t\t\t'pl',\n\t\t\t'pt-br',\n\t\t\t'pt',\n\t\t\t'ro',\n\t\t\t'ru',\n\t\t\t'sd',\n\t\t\t'se',\n\t\t\t'si',\n\t\t\t'sk',\n\t\t\t'sl',\n\t\t\t'sq',\n\t\t\t'sr-cyrl',\n\t\t\t'sr',\n\t\t\t'ss',\n\t\t\t'sv',\n\t\t\t'sw',\n\t\t\t'ta',\n\t\t\t'te',\n\t\t\t'tet',\n\t\t\t'tg',\n\t\t\t'th',\n\t\t\t'tl-ph',\n\t\t\t'tlh',\n\t\t\t'tr',\n\t\t\t'tzl',\n\t\t\t'tzm-latn',\n\t\t\t'tzm',\n\t\t\t'ug-cn',\n\t\t\t'uk',\n\t\t\t'ur',\n\t\t\t'uz-latn',\n\t\t\t'uz',\n\t\t\t'vi',\n\t\t\t'x-pseudo',\n\t\t\t'yo',\n\t\t\t'zh-cn',\n\t\t\t'zh-hk',\n\t\t\t'zh-tw',\n\t\t);\n\t}", "public function getLanguage()\n\t{\n\t\t$languages = array();\n\t\t$acceptLanguage = $this->headers->get('ACCEPT_LANGUAGE');\n\t\tif(strpos($acceptLanguage,',')!==false)\n\t\t{\n\t\t\t$languages = explode(',',$acceptLanguage);\n\t\t}\n\t\treturn $languages[0];\n\t}", "function simplesamlphp_get_languages() {\n return array(\n 'no' => 'Bokmål', // Norwegian Bokmål\n 'nn' => 'Nynorsk', // Norwegian Nynorsk\n 'se' => 'Sámegiella', // Northern Sami\n 'sam' => 'Åarjelh-saemien giele', // Southern Sami\n 'da' => 'Dansk', // Danish\n 'en' => 'English',\n 'de' => 'Deutsch', // German\n 'sv' => 'Svenska', // Swedish\n 'fi' => 'Suomeksi', // Finnish\n 'es' => 'Español', // Spanish\n 'fr' => 'Français', // French\n 'it' => 'Italiano', // Italian\n 'nl' => 'Nederlands', // Dutch\n 'lb' => 'Lëtzebuergesch', // Luxembourgish\n 'cs' => 'Čeština', // Czech\n 'sl' => 'Slovenščina', // Slovensk\n 'lt' => 'Lietuvių kalba', // Lithuanian\n 'hr' => 'Hrvatski', // Croatian\n 'hu' => 'Magyar', // Hungarian\n 'pl' => 'Język polski', // Polish\n 'pt' => 'Português', // Portuguese\n 'pt-br' => 'Português brasileiro', // Portuguese\n 'ru' => 'русский язык', // Russian\n 'et' => 'eesti keel', // Estonian\n 'tr' => 'Türkçe', // Turkish\n 'el' => 'ελληνικά', // Greek\n 'ja' => '日本語', // Japanese\n 'zh' => '简体中文', // Chinese (simplified)\n 'zh-tw' => '繁體中文', // Chinese (traditional)\n 'ar' => 'العربية', // Arabic\n 'fa' => 'پارسی', // Persian\n 'ur' => 'اردو', // Urdu\n 'he' => 'עִבְרִית', // Hebrew\n 'id' => 'Bahasa Indonesia', // Indonesian\n 'sr' => 'Srpski', // Serbian\n 'lv' => 'Latviešu', // Latvian\n 'ro' => 'Românește', // Romanian\n 'eu' => 'Euskara', // Basque\n );\n}", "protected function loadLocale(GridGallery_Ui_Module $ui)\n {\n $locale = get_locale();\n $locale = strtolower($locale);\n\n if (in_array($locale, array('en_us', 'en_gb'))) {\n return;\n }\n\n $config = $this->getEnvironment()->getConfig();\n $config->load('@colorbox/parameters.php');\n\n $colorbox = $config->get('colorbox');\n\n if (!isset($colorbox['languages'][$locale])) {\n return;\n }\n\n $filename = '/jquery-colorbox/i18n/' . $colorbox['languages'][$locale];\n\n $ui->add(\n new GridGallery_Ui_BackendJavascript(\n 'colorbox-backend-lang',\n $this->getLocationUrl() . $filename,\n !$this->isProduction()\n )\n );\n\n $ui->add(\n new GridGallery_Ui_Javascript(\n 'colorbox-frontend-lang',\n $this->getLocationUrl() . $filename,\n !$this->isProduction()\n )\n );\n }", "function locale_variable_language_element_validate($element, &$form_state, $form) {\n $languages = language_list();\n $language = $languages[$element['#value']];\n form_set_value($element, $language, $form_state);\n}", "public function parse($string)\n {\n // names can be separated either by 'and' and by semicolons\n $state = 'default';\n\n foreach ($tokens as $token) {\n\n switch (true) {\n case 'Jr':\n case 'Jr.':\n case 'Junior':\n case 'Sr':\n case 'Sr.':\n case 'Senior':\n case 'II':\n case 'III':\n break;\n\n }\n }\n\n // if there is only one word, it is taken as the Last part, even if it\n // starts with a lower letter\n\n // the von part takes as many words as possible, provided that its first\n // and last words begin with a lowercase letter,\n // however the Last part cannot be empty\n\n // if all the words begin with an uppercase letter, the last word is the\n // Last component, and the First part groups the other words\n\n // first, von, last, suffix\n\n // Suffix Jr/Sr/II/III/MD\n\n // von part starts with lower letters\n // handle tilde\n // first1 first2 first3 last\n // if single letter -> next word after single letter is expected to be either\n // another single letter, or von part or last name\n // if multiple last names\n // { <- starts a single token } <- ends single token\n\n // et al, and others\n }", "public static function load($lang=null){\n\t\t \n\t\tif(!$lang){\n\t\t\t$lang = self::getLanguage();\n\t\t}\n\t\t \n\t\t$cachekey = \"locale:\" . $lang;\n\t\t$locale = Cache::loadCache($cachekey);\n\t\n\t\tif(!is_array($locale)){\n\t\t\t//No cache available -> load from database\n\t\t\t$sql = new SqlManager();\n\t\t\t$sql->setQuery(\"SELECT * FROM bd_sys_locale WHERE locale_language = {{lang}}\");\n\t\t\t$sql->bindParam('{{lang}}', $lang, \"int\");\n\t\t\t$result = $sql->execute();\n\t\t\t$locale = array();\n\t\t\twhile($res = mysql_fetch_array($result)){\n\t\t\t\t$locale[$res['locale_key']] = $res['locale_text'];\n\t\t\t}\n\t\t\t\n\t\t\t//Save loaded locales into cache file for later use \n\t\t\tCache::saveCache($cachekey,$locale);\n\t\t}\n\t\t\n\t\treturn $locale;\n\t}", "function parselang()\n{\n $langdir = realpath(__DIR__ . \"/../../lang\") . DIRECTORY_SEPARATOR;\n $langfile = $langdir . \"lang.json\";\n $langfile = file_get_contents($langfile);\n $lang = json_decode($langfile, true);\n $lfile = $langdir . 'language.' . $lang[\"lang\"] . '.php';\n return (file_exists($lfile)) ? $lfile : $langdir . 'language.en.php';\n}", "function getlocale(int $category = LC_ALL, string|array $default = null, bool $array = false): string|array|null\n{\n $ret = $tmp = setlocale($category, 0);\n if ($ret === false) {\n $ret = $default;\n }\n\n if ($tmp !== false && $array) {\n $tmp = [];\n // Multi, eg: LC_ALL.\n if (str_contains($ret, ';')) {\n foreach (split(';', $ret) as $re) {\n [$name, $value] = split('=', $re, 2);\n $tmp[] = ['name' => $name, 'value' => $value,\n 'category' => get_constant_value($name)];\n }\n } else {\n // Single, eg: LC_TIME.\n $tmp = ['name' => ($name = get_constant_name($category, 'LC_')),\n 'value' => $ret, 'category' => $name ? $category : null];\n }\n $ret = $tmp;\n }\n\n return $ret;\n}", "public function detectLocaleFromHttpHeader($acceptLanguageHeader)\n {\n $acceptableLanguages = I18n\\Utility::parseAcceptLanguageHeader($acceptLanguageHeader);\n\n if ($acceptableLanguages === false) {\n return $this->localizationService->getConfiguration()->getDefaultLocale();\n }\n\n foreach ($acceptableLanguages as $languageIdentifier) {\n if ($languageIdentifier === '*') {\n return $this->localizationService->getConfiguration()->getDefaultLocale();\n }\n\n try {\n $locale = new Locale($languageIdentifier);\n } catch (Exception\\InvalidLocaleIdentifierException $exception) {\n continue;\n }\n\n $bestMatchingLocale = $this->localeCollection->findBestMatchingLocale($locale);\n\n if ($bestMatchingLocale !== null) {\n return $bestMatchingLocale;\n }\n }\n\n return $this->localizationService->getConfiguration()->getDefaultLocale();\n }", "public function getDefaultLocale();" ]
[ "0.58504176", "0.5827084", "0.566907", "0.5668104", "0.5606762", "0.5606762", "0.55896735", "0.54911995", "0.5473626", "0.5471633", "0.54609203", "0.54486305", "0.5395649", "0.53829193", "0.535792", "0.5322093", "0.52763873", "0.52690876", "0.52543825", "0.5249343", "0.52437764", "0.52423537", "0.5213258", "0.515825", "0.51215434", "0.5120289", "0.51093835", "0.5107366", "0.51071817", "0.5097269", "0.5092898", "0.5083193", "0.5075057", "0.5054107", "0.5054107", "0.5054107", "0.5044489", "0.504242", "0.5015488", "0.5008895", "0.4988375", "0.4988375", "0.4988375", "0.49657068", "0.49319547", "0.49308217", "0.4924824", "0.49137583", "0.49128628", "0.4907689", "0.48894817", "0.48874807", "0.48765025", "0.4871919", "0.48649654", "0.48627213", "0.48444188", "0.4843552", "0.48412025", "0.48359162", "0.48354247", "0.48349246", "0.48208532", "0.48060596", "0.479767", "0.47827008", "0.47689718", "0.47673535", "0.47626793", "0.47451583", "0.47442478", "0.47370544", "0.4734461", "0.47255763", "0.4710744", "0.4708535", "0.46943703", "0.46844575", "0.4681989", "0.4673967", "0.46599388", "0.4658347", "0.4657895", "0.46577948", "0.46555257", "0.46521786", "0.46396703", "0.46393523", "0.46317247", "0.46314535", "0.46288905", "0.46281558", "0.4627615", "0.4625714", "0.46235144", "0.4602939", "0.45991296", "0.45909232", "0.45865276", "0.45829383" ]
0.5772034
2
Returns a translated string for the given original text. Original text is returned if no translation is available.
public function localize($key) { if (!isset($this->_phrases[strtoupper($key)])) return $key; $match = $this->_phrases[strtoupper($key)]; if (func_num_args() == 1) return $match; $args = func_get_args(); $args[0] = $match; return call_user_func_array('sprintf', $args); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function translate($text)\n {\n return $this->l($text);\n }", "public function translate(string $text): string\n {\n // TODO: use translator!\n return $text;\n }", "public function translate($text);", "public function getTranslation($text, $pretrans_src='', $pretrans_dst='')\n\t{\n\t\treturn $this->getApertiumTranslation($text, $pretrans_src, $pretrans_dst);\n\t}", "static function getTranslation($text)\r\n\t{\r\n\t\tglobal $user;\r\n\t\t\r\n\t\tif($user && $user->hasField(\"language\") && $user->language)\r\n\t\t\t$language = $user->language;\r\n\t\telse\r\n\t\t\t$language = Settings::getValue(\"text_lookup\", \"language\");\t\r\n\t\t\r\n\t\tif(!$language || $language == \"English\")\r\n\t\t\treturn $text;\r\n\t\telse\r\n\t\t{\r\n\t\t\t$translations = Query::create(TextTranslation, \"WHERE text_id=:text_id AND language=:language\")\r\n\t\t\t\t->bind(\":text_id\", $text->text_id, \":language\", $language)\r\n\t\t\t\t->execute();\r\n\t\t\t\t\r\n\t\t\tif(count($translations) > 0 && $translations[0]->text)\r\n\t\t\t{\r\n\t\t\t\t$text->text = $translations[0]->text;\r\n\t\t\t}\r\n\t\t}\t\r\n\t\t\r\n\t\treturn $text;\r\n\t}", "public function translate(string $text);", "function translate (string $original, string $localeOverride = '') : string {\n\t$locale = ($localeOverride === '' ? $_SESSION['locale'] : $localeOverride);\n\t$translation = executeQuery(\n\t\t_BASE_DB_HOOK,\n\t\t'SELECT translated FROM translation WHERE original = ? AND locale = ?;',\n\t\t[['s' => $original], ['s' => $locale]]\n\t);\n\n\tif($translation instanceof mysqli_result){\n\t\t$reader = $translation->fetch_row();\n\t\tif($reader[0]){\n\t\t\treturn $reader[0];\n\t\t}\n\t}\n\treturn $original;\n}", "function gTranslate($text,$langOriginal,$langFinal){\n\t\t//Si los idiomas son iguales no hago nada\n\t\tif($langOriginal != $langFinal){\n\t\t/* Definimos la URL de la API de Google Translate y metemos en la variable el texto a traducir */\n\t\t$url = 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&q='.urlencode($text).'&langpair='.$langOriginal.'|'.$langFinal;\n\t\t// iniciamos y configuramos curl_init();\n\t\t$curl_handle = curl_init();\n\t\tcurl_setopt($curl_handle,CURLOPT_URL, $url);\n\t\tcurl_setopt($curl_handle,CURLOPT_CONNECTTIMEOUT,2);\n\t\tcurl_setopt($curl_handle,CURLOPT_RETURNTRANSFER,1);\n\t\t$code = curl_exec($curl_handle);\n\t\tcurl_close($curl_handle);\n\t\t/* La api nos devuelve los resultados en forma de objeto stdClass */\t\n\t\t$json \t\t= json_decode($code)->responseData;\n \t $traduccion = utf8_decode($json->translatedText);\n\t\treturn utf8_decode($traduccion);\n\t\t}else{\n\t\t\treturn $text;\n\t\t}\n\t}", "public function text()\n {\n if ($this->text_translated) {\n return cms_trans($this->text_translated);\n }\n\n return $this->text;\n }", "public function translate($fromLanguage,$toLanguage,$text){\n\t \t$translate = new Translate();\n\t \t$rs = '';\n\t \t$rs = $translate->tranlated($fromLanguage,$toLanguage,$text);\n\t \treturn $rs;\n\t }", "public function getTranslatedMessage(): string\n\t{\n\t\tif(self::$resolver === null)\n\t\t{\n\t\t\tself::$resolver = new DefaultMessageResolver();\n\t\t}\n\t\t\n\t\treturn self::$resolver->resolveMessage($this->name, $this->key, $this->args);\n\t}", "public static function getTranslation($text) {\n if (!is_array(self::$cachedTranslations)) {\n self::$cachedTranslations = CachedConferenceApi::getTranslations();\n }\n\n $textMD5 = md5($text);\n if (is_array(self::$cachedTranslations) && isset(self::$cachedTranslations[$textMD5])) {\n return self::$cachedTranslations[$textMD5];\n }\n else {\n return $text;\n }\n }", "public function translate( $text, $context = null ) {\n\t\treturn $this->get_translation( $this->cache_key( func_get_args() ), $text, func_get_args() );\n\t}", "public function translated();", "public function translated();", "function yourls_translate( $text, $domain = 'default' ) {\n\t$translations = yourls_get_translations_for_domain( $domain );\n\treturn yourls_apply_filter( 'translate', $translations->translate( $text ), $text, $domain );\n}", "function tfuse_qtranslate($text) {\r\n $text = html_entity_decode($text, ENT_QUOTES, 'UTF-8');\r\n\r\n\t\t\tif (function_exists('qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage')) {\r\n\t\t\t\t$text = qtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage( $text );\r\n\t\t\t}\r\n\t\t\telseif ( function_exists('ppqtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage' ) ) {\r\n\t\t\t\t$text = ppqtrans_useCurrentLanguageIfNotFoundUseDefaultLanguage( $text );\r\n\t\t\t}\r\n elseif ( function_exists('qtranxf_useCurrentLanguageIfNotFoundUseDefaultLanguage' ) ) {\r\n $text = qtranxf_useCurrentLanguageIfNotFoundUseDefaultLanguage( $text );\r\n\t\t\t}\r\n\t\t\telseif ( function_exists( 'icl_object_id' ) && strpos( $text, 'wpml_translate' ) == true ) {\r\n\t\t\t\t$text = do_shortcode( $text );\r\n\t\t\t}\r\n \r\n return $text;\r\n }", "public function vbTranslate(string $text): string\n {\n // TODO: use translator!\n return __($text, 'vb-wp-plugin-core');\n }", "public function translate(string $text, string $target): ?string;", "function __(string $original, ...$args): string\n {\n $text = Translator::getTranslator()->gettext($original);\n return Translator::getFormatter()->format($text, $args);\n }", "public function translate();", "private function translateText($inText, $from, $to) {\n // See https://docs.microsoft.com/en-us/azure/cognitive-services/Translator/quickstart-php-translate\n $url = 'https://api.cognitive.microsofttranslator.com/translate?' . http_build_query(array(\n 'api-version' => '3.0',\n 'from' => $from,\n 'to' => $to\n ));\n\n $requestData = array(\n array('Text' => $inText)\n );\n $requestBody = json_encode($requestData);\n\n // Perform an authenticated POST request to the Microsoft Translator API\n $ch = curl_init($url);\n curl_setopt($ch, CURLOPT_POSTFIELDS, $requestBody);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);\n curl_setopt($ch, CURLOPT_HTTPHEADER, array(\n 'Content-Type: application/json',\n 'Content-Length: ' . strlen($requestBody),\n 'Ocp-Apim-Subscription-Key: ' . $this->apiKey\n ));\n $responseBody = curl_exec($ch);\n curl_close($ch);\n\n // Parse the JSON, extract the data from it\n $responseData = json_decode($responseBody);\n\n if (isset($responseData->error)) {\n return NULL;\n }\n\n return $responseData[0]->translations[0]->text;\n }", "public function getReplacementText();", "function hybrid_gettext( $translated, $text, $domain ) {\n\n\t/* Check if 'hybrid-core' is the current textdomain, there's no mofile for it, and the theme has a mofile. */\n\tif ( 'hybrid-core' == $domain && !hybrid_is_textdomain_loaded( 'hybrid-core' ) && hybrid_is_textdomain_loaded( hybrid_get_parent_textdomain() ) )\n\t\t$translated = hybrid_translate( hybrid_get_parent_textdomain(), $text );\n\n\treturn $translated;\n}", "public function translation()\n {\n $kirby = $this->model->kirby();\n $lang = $this->model->language();\n return $kirby->translation($lang);\n }", "public function translate($sourceDetected, $languageTarget, $text){\n\n \t\t//$ld = $languageDetect->getLanguageDetect($text);\n $source = $sourceDetected;\n \t\t$target = $languageTarget;\n\n \t\t$trans = new GoogleTranslate();\n \t\t$result = $trans->translate($source, $target, $text);\n\t \treturn $result;\n }", "public function text($text) { return $this->t($text); }", "function hybrid_translate( $domain, $text, $context = null ) {\n\n\t$translations = get_translations_for_domain( $domain );\n\n\treturn $translations->translate( $text, $context );\n}", "protected function getStringTranslation() {\n if (!$this->stringTranslation) {\n $this->stringTranslation = \\Drupal::service('string_translation');\n }\n\n return $this->stringTranslation;\n }", "public function getTranslation(): string\n {\n return CronTranslator::translate($this->expression);\n }", "abstract public function translate($sentence);", "public static function createFromOriginalString($original)\n {\n return (new Translatable())->setTranslations(\n [\n self::getDefaultLanguage() => $original\n ]\n );\n }", "function atktext($string, $module=\"\",$node=\"\", $lng=\"\", $firstfallback=\"\", $nodefaulttext=false, $modulefallback=false)\n{\n\t\n\t// alcal: user can specify language on pdf's\n\tif(!is_array($string) && substr($string, 0, 4)=='pdf_'){\n\t\t$rawdata = atkGetUser('customlang');\n\t\t$unserialized = unserialize(base64_decode($rawdata));\n\t\t\n\t\tif($unserialized[$string]) return $unserialized[$string];\n\t}\n\n\tatkimport(\"atk.atklanguage\");\n\treturn atkLanguage::text($string, $module, $node, $lng, $firstfallback, $nodefaulttext,$modulefallback);\n}", "function __($text)\n{\n $sys = getSysInfo();\n $lang = $sys[\"lang\"];\n //set_include_path(get_include_path() . PATH_SEPARATOR . $_SERVER['DOCUMENT_ROOT'].getPathFromDocRoot().'locales'.FILE_SEPARATOR.$lang);\n if ($lang == \"\") {\n //do nothing\n return $text;\n } else {\n require_once('locales'.FILE_SEPARATOR.$lang.FILE_SEPARATOR.$lang.'.php');\n //$translation = getTranslation($text);\n $translation = call_user_func('getTranslation_'.$lang, $text);\n if ($translation == \"\") {\n return $text;\n //maybe send an error email to admin?\n } else {\n return $translation;\n }\n }\n}", "function get_text($id, $language = '', $default = '')\n{\n if (empty($language))\n $language = get_config('language', 'main');\n\n $__langs__ = $GLOBALS[\"__LANGUAGE__{$language}__\"];\n\n return isset($__langs__[strtolower($id)]) ? __replace_cfgs($__langs__[strtolower($id)], 0, $language) : $default;\n}", "function localize($phrase) {\n global $translations;\n /* Static keyword is used to ensure the file is loaded only once */\n if ($translations[$phrase])\n return $translations[$phrase];\n else\n return $phrase;\n}", "function p($text) {\r\n\t$args = func_get_args();\r\n\t$text = array_shift($args); // temporary get the text out\r\n\tarray_unshift($args,null); // to use active language\r\n\tarray_unshift($args,$text); // bring back the text\r\n\t$translated = call_user_func_array('t',$args); // call our translator\r\n\techo $translated;\r\n}", "function yourls_translate_with_context( $text, $context, $domain = 'default' ) {\n\t$translations = yourls_get_translations_for_domain( $domain );\n\treturn yourls_apply_filter( 'translate_with_context', $translations->translate( $text, $context ), $text, $context, $domain );\n}", "function p__(string $context, string $original, ...$args): string\n {\n $text = Translator::getTranslator()->pgettext($context, $original);\n return Translator::getFormatter()->format($text, $args);\n }", "private function extractGettextStrings()\n {\n $translation = null;\n $translationObjects = array();\n $lookupDirectories = array(\n Strata::getVendorPath() . 'strata-mvc' . DIRECTORY_SEPARATOR . 'strata' . DIRECTORY_SEPARATOR . 'src',\n Strata::getSrcPath(),\n Strata::getThemesPath(),\n );\n\n foreach ($lookupDirectories as $directory) {\n $translationObjects = $this->recurseThroughDirectory($directory);\n\n // Merge all translation objects into a bigger one\n foreach ($translationObjects as $t) {\n if (is_null($translation)) {\n $translation = $t;\n } else {\n $translation->mergeWith($t);\n }\n }\n }\n\n return $translation;\n }", "public static function trn($text, $lang) {\n\t\t$messagesDIR = '../messages/';\n\t\t$file = $messagesDIR . $lang .'.php';\n\t\tif (!file_exists($file)) { \n\t\t\treturn $text; \n\t\t}\n\n\t\t$messages = require($file);\n\n\t\tif (isset($messages[$text]) && !empty($messages[$text])) {\n\t\t\treturn $messages[$text];\n\t\t}\n\n\t\t// Fallback\n\t\treturn $text;\n\t}", "public function translate_woocommerce( $translation, $text, $domain ) {\n\t\tif ( $domain == 'woocommerce' ) {\n\t\t\tswitch ( $text ) {\n\t\t\t\tcase 'SKU:':\n\t\t\t\t\t$translation = 'ISBN:';\n\t\t\t\t\tbreak;\n case 'SKU':\n\t\t\t\t\t$translation = 'ISBN';\n\t\t\t\t\tbreak;\n\n\t\t\t}\n\n\t\t}\n\t\treturn $translation;\n\t}", "function l($text,$echo=true)\n{\n\tglobal $translate;\n\tglobal $notrans;\n\tif (TRANSLATE_DEBUG)\n\t{\n\t\t/*\n\t\t// DEBUG\n\t\t*/\n\t\tif (isset($translate[$text])) \n\t\t\tif ($translate[$text]==\"=\")\t$trans='<span class=\\'igual\\'>'.$text.'</span>';\n\t\t\telse $trans='<span class=\\'translated\\'>'.$translate[$text].'</span>';\n\t\telse $trans=TRANSLATE_NO_TRANS.'<span class=\\'no-trans\\'>'.$text.'</span>';\n\t}\n\telse\n\t{\n\t\tif (isset($translate[$text])) \n\t\t{\n\t\t\tif ($translate[$text]==\"=\")\t$trans=$text;\n\t\t\telse $trans=$translate[$text];\n\t\t}\n\t\telse $trans=$text;\n\t}\n\t//echo \"---$text - \".(isset($translate[$text])?\"ok\":\"ko\").\" > \";\n\tif ($echo) echo $trans;\n\t\n\treturn ($trans);\n}", "protected function getMiconStringTranslation() {\n if (!$this->stringTranslation) {\n $this->stringTranslation = \\Drupal::service('string_translation');\n }\n return $this->stringTranslation;\n }", "private function getSymfonyTranslation(TranslatableMarkup $translated_string) {\n $lang = $this->getLanguageCode($translated_string);\n $string_translation = $this->getStringTranslation($lang, $translated_string->getUntranslatedString(), $translated_string->getOption('context'));\n if (!$string_translation && $this->translator instanceof TranslatorBagInterface) {\n // Configure the translator.\n if ($this->configureTranslator->doesNeedConfiguring($lang)) {\n $this->configureTranslator->configure($lang);\n }\n\n // Try getting the translated string from the cache.\n if($translation = $this->cache->getCachedTranslation($translated_string)) {\n return $translation;\n }\n\n // Cache the translation on the fly if found.\n if ($translation = $this->cache->cacheSymfonyTranslation($translated_string)) {\n return $translation;\n }\n\n }\n\n return NULL;\n }", "public function __(string $text, ...$parameters) : string\n {\n $authorizedLanguages = Light::getLanguages();\n $language = $_SESSION['language'] ?? substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);\n $defaultLanguage = Config::getConfig('default_language');\n\n if ($language === $defaultLanguage) {\n $this->replaceParameters($text, $parameters);\n return $text;\n }\n\n if (!in_array($language, $authorizedLanguages)) {\n $language = $defaultLanguage;\n }\n\n $genericalPath = getcwd() . \"/app/language/{$language}/%s.csv\";\n\n if (file_exists(sprintf($genericalPath, $this->translationFile))) {\n $filePath = sprintf($genericalPath, $this->translationFile);\n } else {\n $filePath = sprintf($genericalPath, 'Global');\n }\n\n $translatedText = $this->searchTranslation($filePath, $text);\n\n if ($translatedText == $text) {\n $filePath = sprintf($genericalPath, 'Global');\n\n $translatedText = $this->searchTranslation($filePath, $text);\n }\n\n self::replaceParameters($translatedText, $parameters);\n\n return $translatedText;\n }", "function translate($string, $extra = \"\", $language = '')\n{\n $translation = loadTranslation(!$language ? substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2) : $language);\n if ($translation && count($translation)) {\n $translated = '';\n if (array_key_exists($string, $translation)) {\n $translated = $translation[$string];\n $translated .= strlen($extra) ? \"<br/>\" . $extra : \"\";\n } else {\n return $translated = $language != \"en\" ? translate($string, $extra, 'en') : '';\n }\n return $translated;\n } else {\n return '';\n }\n}", "function get_text_in_user_selected_language($user_id=0,$text=\"\"){\n\t\t$user=$this->UserModel->get_user_data(array('member_id'=>$user_id));\n\t\t$user_language=$user[0]['language'];\n\n\n\t\t#fetch text according to user selected language\n\t\t$language_text_arr=$this->UserModel->get_language_text(array('language'=>$user_language,'text_code'=>$text));\n\n\t\tif(count($language_text_arr)<=0){\n\t\t\t$language_text=$this->UserModel->get_language_text(array('language'=>'en','text_code'=>$text));\n\t\t\t$language_code=$user_language;\n\n\t\t\t$this->load->library('Languagetranslator'); # load language translate library\n\t\t\t$source = 'en';\t\t#source language\n\t\t\t$target = $language_code;\t#target language\n\t\t\t#Covert text language in target language\n\t\t\tforeach($language_text as $text){\n\t\t\t\t$sourceData = $text['text'];\n\t\t\t\t$targetData = $this->languagetranslator->translate($sourceData,$target, $source);\n\t\t\t\t$input_array=array('language'=>strtolower($language_code),'text_code'=>$text['text_code'],'text'=>$targetData);\n\t\t\t\t#update text in language table\n\t\t\t\t$this->UserModel->create_language($input_array);\n\t\t\t\treturn $targetData;\n\t\t\t}\n\t\t}else{\n\t\t\treturn $language_text_arr[0]['text'];\n\t\t}\n\t}", "public static function translate($id)\r\n\t{\r\n\t\t$string = new String(array(\r\n\t\t\t'id' => $id\r\n\t\t));\r\n\t\tif (isset($_SESSION['language'])) {\r\n\t\t\t$language = $_SESSION['language'];\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$language = DEFAULT_LOCALE;\r\n\t\t}\r\n\t\t// echo ' <br/>66: <pre>';\r\n\t\t// var_dump($string->translations);\r\n\t\t// echo '</pre>';\r\n\t\t\r\n\t\treturn $string->translations[$language]->getTranslation();\r\n\t}", "function yourls__( $text, $domain = 'default' ) {\n\treturn yourls_translate( $text, $domain );\n}", "private function translateCycle($text) {\n // Translate to the 'to' language and then back to the 'from' language\n $text = $this->translateText($text, $this->languageFrom, $this->languageTo);\n if ($text === NULL) return NULL;\n\n $text = $this->translateText($text, $this->languageTo, $this->languageFrom);\n if ($text === NULL) return NULL;\n\n return $text;\n }", "function text($string, $node=\"\", $module=\"\", $lng=\"\", $firstfallback=\"\", $nodefaulttext=false)\n{\n\tatkdebug(\"Call to deprecated text() function\",DEBUG_WARNING);\n\tatkimport(\"atk.atklanguage\");\n\treturn atkLanguage::text($string, $module, $node, $lng, $firstfallback, $nodefaulttext);\n}", "function translate_with_context($text, $domain = 'default')\n {\n }", "static private function ___translate___()\n {\n _('RECORD\\Farthest %1$s from Sagittarius A*');\n }", "static function wrap($original) {\n if (!function_exists('gettext')) return sprintf('<!--l10n-->%1$s', $original);\n return sprintf('<!--l10n-->%1$s', gettext($original));\n }", "public function getTranslation( $identifier, ?string $defaultTranslation = null ) : string;", "public static function translateString($txt) {\n\t $transliterationTable = array('á' => 'a', 'Á' => 'A', 'à' => 'a', 'À' => 'A', 'ă' => 'a', 'Ă' => 'A', 'â' => 'a', 'Â' => 'A', 'å' => 'a', 'Å' => 'A', 'ã' => 'a', 'Ã' => 'A', 'ą' => 'a', 'Ą' => 'A', 'ā' => 'a', 'Ā' => 'A', 'ä' => 'ae', 'Ä' => 'AE', 'æ' => 'ae', 'Æ' => 'AE', 'ḃ' => 'b', 'Ḃ' => 'B', 'ć' => 'c', 'Ć' => 'C', 'ĉ' => 'c', 'Ĉ' => 'C', 'č' => 'c', 'Č' => 'C', 'ċ' => 'c', 'Ċ' => 'C', 'ç' => 'c', 'Ç' => 'C', 'ď' => 'd', 'Ď' => 'D', 'ḋ' => 'd', 'Ḋ' => 'D', 'đ' => 'd', 'Đ' => 'D', 'ð' => 'dh', 'Ð' => 'Dh', 'é' => 'e', 'É' => 'E', 'è' => 'e', 'È' => 'E', 'ĕ' => 'e', 'Ĕ' => 'E', 'ê' => 'e', 'Ê' => 'E', 'ě' => 'e', 'Ě' => 'E', 'ë' => 'e', 'Ë' => 'E', 'ė' => 'e', 'Ė' => 'E', 'ę' => 'e', 'Ę' => 'E', 'ē' => 'e', 'Ē' => 'E', 'ḟ' => 'f', 'Ḟ' => 'F', 'ƒ' => 'f', 'Ƒ' => 'F', 'ğ' => 'g', 'Ğ' => 'G', 'ĝ' => 'g', 'Ĝ' => 'G', 'ġ' => 'g', 'Ġ' => 'G', 'ģ' => 'g', 'Ģ' => 'G', 'ĥ' => 'h', 'Ĥ' => 'H', 'ħ' => 'h', 'Ħ' => 'H', 'í' => 'i', 'Í' => 'I', 'ì' => 'i', 'Ì' => 'I', 'î' => 'i', 'Î' => 'I', 'ï' => 'i', 'Ï' => 'I', 'ĩ' => 'i', 'Ĩ' => 'I', 'į' => 'i', 'Į' => 'I', 'ī' => 'i', 'Ī' => 'I', 'ĵ' => 'j', 'Ĵ' => 'J', 'ķ' => 'k', 'Ķ' => 'K', 'ĺ' => 'l', 'Ĺ' => 'L', 'ľ' => 'l', 'Ľ' => 'L', 'ļ' => 'l', 'Ļ' => 'L', 'ł' => 'l', 'Ł' => 'L', 'ṁ' => 'm', 'Ṁ' => 'M', 'ń' => 'n', 'Ń' => 'N', 'ň' => 'n', 'Ň' => 'N', 'ñ' => 'n', 'Ñ' => 'N', 'ņ' => 'n', 'Ņ' => 'N', 'ó' => 'o', 'Ó' => 'O', 'ò' => 'o', 'Ò' => 'O', 'ô' => 'o', 'Ô' => 'O', 'ő' => 'o', 'Ő' => 'O', 'õ' => 'o', 'Õ' => 'O', 'ø' => 'oe', 'Ø' => 'OE', 'ō' => 'o', 'Ō' => 'O', 'ơ' => 'o', 'Ơ' => 'O', 'ö' => 'oe', 'Ö' => 'OE', 'ṗ' => 'p', 'Ṗ' => 'P', 'ŕ' => 'r', 'Ŕ' => 'R', 'ř' => 'r', 'Ř' => 'R', 'ŗ' => 'r', 'Ŗ' => 'R', 'ś' => 's', 'Ś' => 'S', 'ŝ' => 's', 'Ŝ' => 'S', 'š' => 's', 'Š' => 'S', 'ṡ' => 's', 'Ṡ' => 'S', 'ş' => 's', 'Ş' => 'S', 'ș' => 's', 'Ș' => 'S', 'ß' => 'SS', 'ť' => 't', 'Ť' => 'T', 'ṫ' => 't', 'Ṫ' => 'T', 'ţ' => 't', 'Ţ' => 'T', 'ț' => 't', 'Ț' => 'T', 'ŧ' => 't', 'Ŧ' => 'T', 'ú' => 'u', 'Ú' => 'U', 'ù' => 'u', 'Ù' => 'U', 'ŭ' => 'u', 'Ŭ' => 'U', 'û' => 'u', 'Û' => 'U', 'ů' => 'u', 'Ů' => 'U', 'ű' => 'u', 'Ű' => 'U', 'ũ' => 'u', 'Ũ' => 'U', 'ų' => 'u', 'Ų' => 'U', 'ū' => 'u', 'Ū' => 'U', 'ư' => 'u', 'Ư' => 'U', 'ü' => 'ue', 'Ü' => 'UE', 'ẃ' => 'w', 'Ẃ' => 'W', 'ẁ' => 'w', 'Ẁ' => 'W', 'ŵ' => 'w', 'Ŵ' => 'W', 'ẅ' => 'w', 'Ẅ' => 'W', 'ý' => 'y', 'Ý' => 'Y', 'ỳ' => 'y', 'Ỳ' => 'Y', 'ŷ' => 'y', 'Ŷ' => 'Y', 'ÿ' => 'y', 'Ÿ' => 'Y', 'ź' => 'z', 'Ź' => 'Z', 'ž' => 'z', 'Ž' => 'Z', 'ż' => 'z', 'Ż' => 'Z', 'þ' => 'th', 'Þ' => 'Th', 'µ' => 'u', 'а' => 'a', 'А' => 'a', 'б' => 'b', 'Б' => 'b', 'в' => 'v', 'В' => 'v', 'г' => 'g', 'Г' => 'g', 'д' => 'd', 'Д' => 'd', 'е' => 'e', 'Е' => 'e', 'ё' => 'e', 'Ё' => 'e', 'ж' => 'zh', 'Ж' => 'zh', 'з' => 'z', 'З' => 'z', 'и' => 'i', 'И' => 'i', 'й' => 'j', 'Й' => 'j', 'к' => 'k', 'К' => 'k', 'л' => 'l', 'Л' => 'l', 'м' => 'm', 'М' => 'm', 'н' => 'n', 'Н' => 'n', 'о' => 'o', 'О' => 'o', 'п' => 'p', 'П' => 'p', 'р' => 'r', 'Р' => 'r', 'с' => 's', 'С' => 's', 'т' => 't', 'Т' => 't', 'у' => 'u', 'У' => 'u', 'ф' => 'f', 'Ф' => 'f', 'х' => 'h', 'Х' => 'h', 'ц' => 'c', 'Ц' => 'c', 'ч' => 'ch', 'Ч' => 'ch', 'ш' => 'sh', 'Ш' => 'sh', 'щ' => 'sch', 'Щ' => 'sch', 'ъ' => '', 'Ъ' => '', 'ы' => 'y', 'Ы' => 'y', 'ь' => '', 'Ь' => '', 'э' => 'e', 'Э' => 'e', 'ю' => 'ju', 'Ю' => 'ju', 'я' => 'ja', 'Я' => 'ja', 'º' => '');\n\t $txt = str_replace(array_keys($transliterationTable), array_values($transliterationTable), $txt);\n\t return $txt;\n\t}", "function translateFrom($text) {\n\t\t$text = str_replace('href=\"{[CCM:BASE_URL]}', 'href=\"' . BASE_URL . DIR_REL, $text);\n\t\t$text = str_replace('src=\"{[CCM:REL_DIR_FILES_UPLOADED]}', 'src=\"' . BASE_URL . REL_DIR_FILES_UPLOADED, $text);\n\n\t\t// we have the second one below with the backslash due to a screwup in the\n\t\t// 5.1 release. Can remove in a later version.\n\n\t\t$text = preg_replace(\n\t\t\tarray(\n\t\t\t\t'/{\\[CCM:BASE_URL\\]}/i',\n\t\t\t\t'/{CCM:BASE_URL}/i'),\n\t\t\tarray(\n\t\t\t\tBASE_URL . DIR_REL,\n\t\t\t\tBASE_URL . DIR_REL)\n\t\t\t, $text);\n\t\t\t\n\t\t// now we add in support for the links\n\t\t\n\t\t$text = preg_replace_callback(\n\t\t\t'/{CCM:CID_([0-9]+)}/i',\n\t\t\tarray('[[[GENERATOR_REPLACE_CLASSNAME]]]', 'replaceCollectionID'),\n\t\t\t$text);\n\n\t\t$text = preg_replace_callback(\n\t\t\t'/<img [^>]*src\\s*=\\s*\"{CCM:FID_([0-9]+)}\"[^>]*>/i',\n\t\t\tarray('[[[GENERATOR_REPLACE_CLASSNAME]]]', 'replaceImageID'),\n\t\t\t$text);\n\n\t\t// now we add in support for the files that we view inline\t\t\t\n\t\t$text = preg_replace_callback(\n\t\t\t'/{CCM:FID_([0-9]+)}/i',\n\t\t\tarray('[[[GENERATOR_REPLACE_CLASSNAME]]]', 'replaceFileID'),\n\t\t\t$text);\n\n\t\t// now files we download\n\t\t\n\t\t$text = preg_replace_callback(\n\t\t\t'/{CCM:FID_DL_([0-9]+)}/i',\n\t\t\tarray('[[[GENERATOR_REPLACE_CLASSNAME]]]', 'replaceDownloadFileID'),\n\t\t\t$text);\n\t\t\n\t\treturn $text;\n\t}", "protected function getTranslationString($str)\n\t{\n\t\t// Only return string if there is a parent object and a translation\n\t\tif ($this->parent && $trStr = $this->parent->getTranslationString($str)) {\n\t\t\treturn $trStr;\n\t\t}\n\t\treturn $str;\n\t}", "protected function unwrapUntranslatable( $text ) {\n\t\t$pattern = '~<span class=\"notranslate\" translate=\"no\">(.*?)</span>~';\n\t\t$text = str_replace( '!N!', \"\\n\", $text );\n\t\t$text = preg_replace( $pattern, '\\1', $text );\n\n\t\treturn $text;\n\t}", "function get_lang_txt($lang_string) {\n\tglobal $lang, $backup_lang;\n\treturn (check_value($lang[$lang_string])) ? $lang[$lang_string] : $backup_lang[$lang_string];\n}", "public function getTextByLanguage($text) {\n\t\tif(in_array($this->language, $this->availableLanguages)) {\n\t\t\t$output = \"\";\n\t\t\t$fix = explode('{['.$this->language.']}', $text);\n\t\t\tfor($b=0; $b<count($fix); $b++) {\n\t\t\t\t$tmp = explode('{[', $fix[$b]);\n\t\t\t\t$output .= $tmp[0];\n\t\t\t}\n\t\t\treturn $output;\n\t\t} elseif(!empty($this->availableLanguages)) {\n\t\t\t// if the string contains language tags but not the selected language\n\t\t\t// so get another language. Otherwise it wont print an output.\n\t\t\t$output = \"\";\n\t\t\t$language =$this->availableLanguages[0];\n\t\t\t$fix = explode('{['.$language.']}', $text);\n\t\t\tfor($b=0; $b<count($fix); $b++) {\n\t\t\t\t$tmp = explode('{[', $fix[$b]);\n\t\t\t\t$output .= $tmp[0];\n\t\t\t}\n\t\t\treturn $output;\n\t\t} else {\n\t\t\treturn $text;\n\t\t}\n\t}", "static protected function translate($s){\nif(!self::$strings)return $s;\nif(!array_key_exists($s,self::$strings))return $s;\nreturn self::$strings[$s];\n}", "public static function get($textId)\n {\n $lang = self::getLanguage();\n switch($lang)\n {\n case \"en\":\n return self::getEnglish($textId);\n case \"cs\":\n return self::getCzech($textId);\n default:\n return \"INVALID LANGUAGE CODE (\" . self::getEnglish($textId) . \")\";\n }\n }", "function gettext($message) {\n global $faketext;\n \n return (!empty($faketext[$message]) ? $faketext[$message] : $message);\n }", "public function translate($text, $variables = array()) {\n\t\t$text = preg_replace(\"/({{\\s*)([a-zA-Z._]+)(\\s*}})/\", \"{{ $2 }}\", $text);\n\t\t$match = $this->fastLookup($text);\n\n\t\tif (is_null($match)) {\n\t\t\t$match = $text;\n\t\t}\n\n\t\tif (!empty($variables)) {\n\t\t\t$match = $this->replaceVariables($match, $variables);\n\t\t}\n\n\t\treturn $match;\n\t}", "public function text($text_id, $lng = \"\", $default_text = \"\")\n {\n if (empty($lng)) {\n $lng = $this->getCurrentLanguage();\n }\n\n if (empty(self::$texts[$lng][$text_id])) {\n if ($this->warn_missing) {\n trigger_error(\"No translation for the text '$text_id' in the language [$lng]!\", E_USER_NOTICE);\n }\n\n if (empty($default_text)) {\n return $text_id;\n } else {\n return $default_text;\n }\n }\n\n return self::$texts[$lng][$text_id];\n }", "function skudo_text($textid){\n\n\t$locale=get_locale();\n\t$int_enabled=get_option(\"skudo_enable_translation\")=='on'?true:false;\n\t$default_locale=get_option(\"skudo_def_locale\");\n\n\tif($int_enabled && $locale!=$default_locale){\n\t\t//use translation - extract the text from a defined .mo file\n\t\treturn $textid;\n\t}else{\n\t\t//use the default text settings\n\t\treturn stripslashes(get_option(\"skudo\".$textid));\n\t}\n}", "public function getTranslation($translations)\n {\n return $this->translator->getPreferredTranslation($translations);\n }", "function translate($data)\n\t {\n\t \t return $this->translate_bing($data);\n\t }", "function yourls_e( $text, $domain = 'default' ) {\n\techo yourls_translate( $text, $domain );\n}", "protected function translate($key) {\n\t\treturn LocalizationUtility::translate(static::languageFile . static::languageKeyPrefix . $key);\n\t}", "public function translate($contact);", "public static function translate_trash_text( $translation, $text, $domain ) {\n if ( 'Move to Trash' === $translation ) {\n $translation = 'Delete';\n }\n\n return $translation;\n }", "static public function getTranslate()\r\n {\r\n return Warecorp_Translate::getTranslate();\r\n }", "abstract protected function translator();", "public function addOriginalText($text, $domain)\n\t{\n\t\t$domain = ToLower($domain);\n\t\t$hostId = $this->getHostId($domain);\n\n//\t\tcreate JSON data in correct format\n\t\t$data = array(\"content\" => $text);\n\t\t$data = Json::encode($data);\n\t\t$serviceUrl = $this->getServiceUrl($this->userId, $hostId, self::API_ORIGINAL_TEXTS_URL);\n\t\t$queryResult = $this->query($serviceUrl, 'POST', $data);\n\t\t\n\t\tif ($queryResult->getStatus() == self::HTTP_STATUS_CREATED && strlen($queryResult->getResult()) > 0)\n\t\t\treturn $queryResult->getResult();\n\t\telse\n\t\t\tthrow new Engine\\YandexException($queryResult);\n\t}", "protected abstract function getTranslations();", "public function getTranslation() {\n\t\treturn $this->translation;\n\t}", "function hybrid_extensions_gettext( $translated, $text, $domain ) {\n\n\t$extensions = array( 'breadcrumb-trail', 'custom-field-series', 'featured-header', 'post-stylesheets', 'theme-fonts', 'theme-layouts' );\n\n\t/* Check if the current textdomain matches one of the framework extensions. */\n\tif ( in_array( $domain, $extensions ) && current_theme_supports( $domain ) ) {\n\n\t\t/* If the framework mofile is loaded, use its translations. */\n\t\tif ( hybrid_is_textdomain_loaded( 'hybrid-core' ) )\n\t\t\t$translated = hybrid_translate( 'hybrid-core', $text );\n\n\t\t/* If the theme mofile is loaded, use its translations. */\n\t\telseif ( hybrid_is_textdomain_loaded( hybrid_get_parent_textdomain() ) )\n\t\t\t$translated = hybrid_translate( hybrid_get_parent_textdomain(), $text );\n\t}\n\n\treturn $translated;\n}", "function my_text_strings( $translated_text, $text, $domain ) {\n switch ( $translated_text ) {\n case 'Ver carrito' :\n $translated_text = __( 'Agregaste este producto ¿Quieres ver el Carrito?', 'woocommerce' );\n break;\n case 'Log in' :\n $translated_text = __( 'Entrar', 'woocommerce' );\n break;\n case 'Cart totals' :\n $translated_text = __( 'Total del carrito', 'woocommerce' );\n break;\n case 'Proceed to checkout' :\n $translated_text = __( 'Proceder a revision', 'woocommerce' );\n break;\n case 'Shipping' :\n $translated_text = __( 'Envio', 'woocommerce' );\n break;\n case 'Sort By' :\n $translated_text = __( 'Ordenar por', 'woocommerce' );\n break;\n case 'Price Range' :\n $translated_text = __( 'Rango de precio', 'woocommerce' );\n break;\n case 'Categories' :\n $translated_text = __( 'Categorias', 'woocommerce' );\n break;\n case 'None' :\n $translated_text = __( 'Ninguna', 'woocommerce' );\n break;\n case 'Review Count' :\n $translated_text = __( 'Recuento de revisión', 'woocommerce' );\n break;\n case 'Popularity' :\n $translated_text = __( 'Popularidad', 'woocommerce' );\n break;\n case 'Average rating' :\n $translated_text = __( 'Puntuación media', 'woocommerce' );\n break;\n case 'Newness' :\n $translated_text = __( 'Novedad', 'woocommerce' );\n break;\n case 'Price: low to high' :\n $translated_text = __( 'Precios de Menor a Mayor', 'woocommerce' );\n break;\n case 'Price: high to low' :\n $translated_text = __( 'Precio: de Mayor a Menor', 'woocommerce' );\n break;\n case 'Random Products' :\n $translated_text = __( 'Productos Aleatorios', 'woocommerce' );\n break;\n case 'Product Name' :\n $translated_text = __( 'Alfabeticamente', 'woocommerce' );\n break;\n case 'Related products' :\n $translated_text = __( 'Productos relacionados', 'woocommerce' );\n break;\n case 'has been added to your cart.' :\n $translated_text = __( 'Ha sido agregado a tu carro', 'woocommerce' );\n break;\n case 'Company name' :\n $translated_text = __( 'Nombre de empresa', 'woocommerce' );\n break;\n case '(optional)' :\n $translated_text = __( '(Opcional)', 'woocommerce' );\n break;\n case 'Street address' :\n $translated_text = __( 'Dirección', 'woocommerce' );\n break;\n case 'Apartment, suite, unit etc. (optional)' :\n $translated_text = __( 'Apartamento, suite, unidad, etc. (opcional)', 'woocommerce' );\n break;\n case 'Email address' :\n $translated_text = __( 'Dirección de correo electrónico', 'woocommerce' );\n break;\n case 'Ship to a different address?' :\n $translated_text = __( '¿Envia a una direccion diferente?', 'woocommerce' );\n break;\n case 'Notes about your order, e.g. special notes for delivery.' :\n $translated_text = __( 'Notas especiales para la entrega.', 'woocommerce' );\n break;\n case 'Shipping' :\n $translated_text = __( 'Envio', 'woocommerce' );\n break;\n\n case 'Billing details' :\n $translated_text = __( 'Detalles de facturación', 'woocommerce' );\n break;\n case 'Direct bank transfer' :\n $translated_text = __( 'Transferencia bancaria directa', 'woocommerce' );\n break;\n case 'Gracias. Tu pedido ha sido recibido.' :\n $translated_text = __( '¡Gracias por su compra!. Su pedido ha sido recibido con exito. Si precisa cualquier aclaracion o tiene alguna duda, use el formulario de CONTACTANOS para hacernos llegar su consulta. En breve nos pondremos en contacto con usted para confirmar su pedido y cuando le sera enviado. ', 'woocommerce' );\n break;\n case 'PayPal Express Checkout' :\n $translated_text = __( 'PayPal Pago exprés', 'woocommerce' );\n break;\n \n case 'privacy policy' :\n $translated_text = __( 'Politicas de Privacidad', 'woocommerce' );\n break;\n\n case 'Continue to payment' :\n $translated_text = __( 'Continuar con el pago', 'woocommerce' );\n break;\n case 'Undo?' :\n $translated_text = __( '¿Deshacer?', 'woocommerce' );\n break;\n case 'Return to shop' :\n $translated_text = __( 'Tienda', 'woocommerce' );\n break;\n case 'From your account dashboard you can view your ':\n $translated_text = __( 'Desde el panel de su cuenta puede ver su', 'woocommerce-page' );\n break;\n case 'recent orders':\n $translated_text = __( 'ordenes recientes', 'woocommerce-page' );\n break;\n case ', manage your ':\n $translated_text = __( 'administrar su', 'woocommerce-page' );\n break;\n }\n return $translated_text;\n}", "function yourls_x( $text, $context, $domain = 'default' ) {\n\treturn yourls_translate_with_context( $text, $context, $domain );\n}", "function hybrid_gettext_with_context( $translated, $text, $context, $domain ) {\n\n\t/* Check if 'hybrid-core' is the current textdomain, there's no mofile for it, and the theme has a mofile. */\n\tif ( 'hybrid-core' == $domain && !hybrid_is_textdomain_loaded( 'hybrid-core' ) && hybrid_is_textdomain_loaded( hybrid_get_parent_textdomain() ) )\n\t\t$translated = hybrid_translate( hybrid_get_parent_textdomain(), $text, $context );\n\n\treturn $translated;\n}", "public function getText($name, $language);", "function translation() {\n\t\t\n\t\t// only use, if we have it...\n\t\tif( function_exists('load_plugin_textdomain') ) {\n\t\t\n\t\t\t// load it\n\t\t\tload_plugin_textdomain( \n\t\t\t\n\t\t\t\t// unique name\n\t\t\t\t'cp-multisite', \n\t\t\t\t\n\t\t\t\t// deprecated argument\n\t\t\t\tfalse,\n\t\t\t\t\n\t\t\t\t// path to directory containing translation files\n\t\t\t\tplugin_dir_path( CPMU_PLUGIN_FILE ) . 'languages/'\n\t\t\t\t\n\t\t\t);\n\t\t\t\n\t\t}\n\t\t\n\t}", "function GetLocalizedText($localizedTextId)\n\t{\n\t\t$result = $this->sendRequest(\"GetLocalizedText\", array(\"LocalizedTextId\"=>$localizedTextId));\t\n\t\treturn $this->getResultFromResponse($result);\n\t}", "protected function translateActionDescriptionInternal(string $text = '', array $parameters = []): string\n {\n $actionTranslated = '';\n switch ($text) {\n case '_HISTORY_PAGE_CREATED':\n $actionTranslated = $this->trans('Page created', [], 'page');\n break;\n case '_HISTORY_PAGE_UPDATED':\n $actionTranslated = $this->trans('Page updated', [], 'page');\n break;\n case '_HISTORY_PAGE_CLONED':\n if (isset($parameters['%page%']) && is_numeric($parameters['%page%'])) {\n $originalEntity = $this->entityFactory->getRepository('page')->selectById($parameters['%page%']);\n if (null !== $originalEntity) {\n $parameters['%page%'] = $this->entityDisplayHelper->getFormattedTitle($originalEntity);\n }\n }\n $actionTranslated = $this->trans('Page cloned from page \"%page%\"', $parameters, [], 'page');\n break;\n case '_HISTORY_PAGE_RESTORED':\n $actionTranslated = $this->trans('Page restored from version \"%version%\"', $parameters, [], 'page');\n break;\n case '_HISTORY_PAGE_DELETED':\n $actionTranslated = $this->trans('Page deleted', [], 'page');\n break;\n case '_HISTORY_PAGE_TRANSLATION_CREATED':\n $actionTranslated = $this->trans('Page translation created', [], 'page');\n break;\n case '_HISTORY_PAGE_TRANSLATION_UPDATED':\n $actionTranslated = $this->trans('Page translation updated', [], 'page');\n break;\n case '_HISTORY_PAGE_TRANSLATION_DELETED':\n $actionTranslated = $this->trans('Page translation deleted', [], 'page');\n break;\n default:\n $actionTranslated = $text;\n }\n \n return $actionTranslated;\n }", "protected static function my_transliteration_function($text) {\n setlocale(LC_CTYPE, 'de_DE.utf8');\n return iconv(\"UTF-8\", 'ASCII//TRANSLIT', $text);\n }", "public function translate($string)\n {\n if ($this->getTranslator()) {\n return $this->getTranslator()->_($string);\n }\n return $string;\n }", "function _t($str/*[, mixed $args [, mixed $... ]]*/)\n{\n global $lc_lang;\n global $lc_translation;\n global $lc_translationEnabled;\n\n $args = func_get_args();\n $str = array_shift($args);\n $str = trim($str);\n\n if ($lc_translationEnabled == false) {\n return (count($args)) ? vsprintf($str, $args) : $str;\n }\n\n $po = session_get('po');\n if (!is_array($po)) {\n $po = array();\n }\n $po[$str] = '';\n\n if (isset($lc_translation[$lc_lang])) {\n # check with lowercase\n $lowerStr = strtolower($str);\n if (isset($lc_translation[$lc_lang][$lowerStr]) && !empty($lc_translation[$lc_lang][$lowerStr])) {\n $translated = $lc_translation[$lc_lang][$lowerStr];\n $str = (is_array($translated)) ? $translated[0] : $translated;\n }\n }\n\n if (isset($translated)) {\n $po[$str] = $translated;\n }\n return (count($args)) ? vsprintf($str, $args) : $str;\n}", "public function replace_text_in_thickbox($translation, $text, $domain ) {\r\n $http_referrer = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '';\r\n $req_referrer = isset($_REQUEST['referer']) ? $_REQUEST['referer'] : '';\r\n if(strpos($http_referrer, 'cycloneslider')!==false or $req_referrer=='cycloneslider') {\r\n if ( 'default' == $domain and 'Insert into Post' == $text )\r\n {\r\n return 'Add to Slide';\r\n }\r\n }\r\n return $translation;\r\n }", "public function translate($path) {\n return Locale::get($path);\n }", "public function translated()\n {\n if (null === $this->translated) {\n return false;\n }\n\n return $this->translated;\n }", "function _gettext($msgid)\r\n\t{\r\n\t\t$l10n = _get_reader();\r\n\t\treturn _encode($l10n->translate($msgid));\r\n\t}", "function __($text, $replace = array(), $lng = '') {\n\tglobal $_website_langs, $_lang, $_config;\n\t\n\tif($_config['server']['memcache'] || $_config['server']['file_cache']){\n\t\t$string = cache_get('lng_var_'.($lng != '' ? $lng : $_lang).'_'.md5($text));\n\t}else{\n\t\t$string = '';\n\t}\n\t\n\tif(!$string){\n\t\t$lng_keys = array_keys($_website_langs);\n\t\tif($lng != '' && !in_array($lng, $lng_keys)){\n\t\t\t$string = $text;\n\t\t}else{\n\t\t\tif(db_table_exists('admin_translation')){\n\t\t\t\t$translate = db_row('SELECT * FROM admin_translation WHERE title = ? OR title = ? LIMIT 1', generate_name($text), md5($text));\n\t\t\n\t\t\t\tif(!$translate){\n\t\t\t\t\t$id_translate = db_query(\"INSERT INTO admin_translation (`title`, `created`) VALUES (?, NOW())\", md5($text));\n\t\t\t\t\tforeach($lng_keys as $key){\n\t\t\t\t\t\tdb_query(\"UPDATE admin_translation SET `\".$key.\"` = ? WHERE id_admin_translation = ?\", $text, $id_translate);\n\t\t\t\t\t}\n\t\t\t\t\t$string = $text;\n\t\t\t\t}else{\n\t\t\t\t\tif($lng != '' && $translate[$lng] != ''){\n\t\t\t\t\t\t$string = $translate[$lng];\n\t\t\t\t\t}elseif($translate[$_lang] != ''){\n\t\t\t\t\t\t$string = $translate[$_lang];\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$string = $text;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\t$string = $text;\n\t\t\t}\n\t\t}\n\t}\n\t\n\tif($_config['server']['memcache'] || $_config['server']['file_cache']){\n\t\tcache_set('lng_var_'.($lng != '' ? $lng : $_lang).'_'.md5($text), $string, $_config['server']['memcache_time']);\n\t}\n\t\n\tforeach($replace as $k => $v) {\n\t\t$string = str_replace('['.$k.']', $v, $string);\n\t}\n\n\treturn $string;\n}", "public function GetReplacement($placeholder)\n {\n if (isset($this->texts[$placeholder]))\n {\n return $this->texts[$placeholder];\n }\n return $this->phpTranslator->GetReplacement($placeholder);\n }", "public function trans($string) {\n\t\treturn Lang::get('fireunion.blogfront::lang.' . $string);\n\t}", "protected function getTranslatedMessage($message, $locale, $textDomain = 'default')\n {\n if (empty($message))\n return '';\n\n if (!$this->cache->has($textDomain, $locale))\n $this->loadMessages($textDomain, $locale);\n\n if ($this->cache->has($textDomain, $locale, $message))\n return $this->cache->get($textDomain, $locale, $message);\n\n return;\n }", "public function trans($key)\n {\n $translations = $this->getTranslations($key);\n\n if($translations[$this->getLocale()] ?? false)\n return $translations[$this->getLocale()];\n\n if($translations[$this->getFallbackLocale()] ?? false)\n return $translations[$this->getFallbackLocale()];\n\n foreach ($translations as $locale => $trans) {\n if($trans)\n return $trans;\n }\n }", "public function translator(): Translator;", "public static function t($name, $module='core', $package='core', &$found=false){\n\t\t\n\t\t//for backwards compatibility\n\t\tif($module != 'core' && $package == 'core') {\n\t\t\t$package = 'legacy';\n\t\t}\n\t\t\n\t\tif($package == null) {\n\t\t\t$package = 'legacy';\n\t\t}\n\n\t\treturn self::language()->getTranslation($name, $module, $package, $found);\n\t}" ]
[ "0.7564392", "0.7328799", "0.72785515", "0.72660846", "0.71504647", "0.70932233", "0.6826912", "0.6738435", "0.66540456", "0.6617744", "0.65670043", "0.6525234", "0.652367", "0.65205866", "0.65205866", "0.6485924", "0.6431638", "0.6421584", "0.6415952", "0.640103", "0.6385207", "0.62951934", "0.6260064", "0.6242705", "0.6203714", "0.61900395", "0.6164495", "0.61056006", "0.61032057", "0.60846597", "0.60601616", "0.6045949", "0.6003014", "0.59986496", "0.5972654", "0.5968293", "0.59409624", "0.5907897", "0.5902586", "0.58872104", "0.58858424", "0.5884865", "0.58756286", "0.58755535", "0.5862595", "0.586182", "0.5857752", "0.57963514", "0.5788563", "0.5781521", "0.57788", "0.57770807", "0.57761395", "0.5745698", "0.57300436", "0.572851", "0.57172835", "0.5712613", "0.57102686", "0.57044995", "0.56898236", "0.56894445", "0.5689357", "0.56842107", "0.5675166", "0.56745315", "0.567151", "0.56514686", "0.5651226", "0.56496644", "0.5645623", "0.56420255", "0.5641956", "0.56388825", "0.563874", "0.56339055", "0.56128776", "0.56080246", "0.56072557", "0.5605984", "0.560276", "0.55978346", "0.5596043", "0.55877507", "0.55842596", "0.558244", "0.5576608", "0.5574989", "0.5568596", "0.5565575", "0.5557129", "0.55312204", "0.5530729", "0.551194", "0.5499296", "0.5491928", "0.54870015", "0.5472924", "0.5466609", "0.54634", "0.5462545" ]
0.0
-1
Loads translation resources from specified component.
public function load($name, $type) { $name = strtolower($name); $type = strtolower($type); switch ($type) { case 'application': $path = PU_PATH_BASE . DS . 'application' . DS . 'locales'; $this->_loadPath($path); break; case 'themes': case 'modules': case 'widgets': $path = PU_PATH_BASE . DS . $type . DS . $name . DS . 'locales'; $this->_loadPath($path); break; default: $error = sprintf("Invalid locale resource type: %s", $type); trigger_error($error, E_USER_NOTICE); break; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function loadLocalization() {}", "public function loadTranslations()\n {\n $oTranslation = new Translation($this->sLang, $this->sBundleName);\n $this->aView[\"lang\"] = $this->sLang;\n $this->aView[\"tr\"] = $oTranslation->getTranslations();\n }", "private function load(): void\n {\n $paths = $this->getPaths();\n\n $this->locales['app'] = $this->loadTranslations($paths['app']);\n\n foreach ($paths['vendors'] as $path) {\n $this->locales['vendor-php'] = $this->loadTranslations($path);\n $this->locales['vendor-json'] = $this->loadJsonTranslations($path);\n }\n }", "protected function load()\n {\n $this->translations = array();\n \n if ($this->language) {\n if ($this->cachepath) {\n if (file_exists($cache = $this->cachepath.'/'.$this->language.'.php')) {\n $this->translations = include($cache);\n }\n } else {\n if (!empty($this->filepaths)) {\n foreach ($this->filepaths as $filepath) {\n $this->loadFilePath($filepath);\n }\n }\n }\n }\n }", "public function load_translation() {\n\t\t\t$locale = apply_filters( 'plugin_locale', determine_locale(), 'sv_core' );\n\t\t\tload_textdomain( 'sv_core', dirname( __FILE__ ) . '/languages/sv_core-'.$locale.'.mo' );\n\t\t}", "protected function loadTranslations()\n {\n if (!isset($this->translations[$this->language])) {\n $file = $this->getTranslationFile($this->language);\n $content = file_get_contents($file);\n $translations = json_decode($content, true);\n if (!is_array($translations)) {\n throw new \\InvalidArgumentException(\"Could not parse JSON translation file: \" . $file);\n }\n\n $this->translations[$this->language] = $translations;\n }\n\n return $this->translations[$this->language];\n }", "private function load_localization() {\n $plugin_i18n = new PLUGINNAME_i18n($this->getter()->get_translation_slug);\n add_action('plugins_loaded', array($plugin_i18n, 'load_plugin_textdomain'));\n }", "function loadTranslation($language = 'en')\n{\n $content = json_decode(file_get_contents(TRANSLATIONS_FOLDER . DS . $language . '.json'), true);\n if ($content && count($content)) {\n return $content;\n } else {\n return $language == 'en' ? array() : loadTranslation('en');\n }\n}", "protected function registerResources()\n {\n $this->loadJsonTranslationsFrom(__DIR__.'/../resources/lang');\n }", "public function loadResources() {}", "function loadLocale($translation) {\n\t\t\treturn include($translation);\n\t\t}", "public function loadMainTrans()\n {\n $translationPath = $this->_getTransPath();\n require $translationPath.\"/main.php\";\n\n //Return a translation object\n $mainTranslate = new Phalcon\\Translate\\Adapter\\NativeArray(array(\n \"content\" => $messages\n ));\n\n //Set $mt as main translation object\n $this->view->setVar(\"mt\", $mainTranslate);\n }", "protected function registerTranslations()\n {\n $this->loadTranslationsFrom(__DIR__ . '/../resources/lang', 'kustomer');\n }", "protected function loadResourcesForRegisteredNavigationComponents() {}", "private function translations()\n {\n $this['translator'] = $this->share($this->extend('translator', function ($translator) {\n $translator->addLoader('yaml', new TranslationFileLoader());\n\n $translator->addResource('yaml', 'config/locales/pt-br.yml', 'pt-br');\n $translator->addResource('yaml', 'config/locales/en-us.yml', 'en-us');\n $translator->addResource('yaml', 'config/locales/es-es.yml', 'es-es');\n\n return $translator;\n }));\n }", "public function initLocalization() {\n $moFiles = scandir(trailingslashit($this->dir) . 'languages/');\n foreach ($moFiles as $moFile) {\n if (strlen($moFile) > 3 && substr($moFile, -3) == '.mo' && strpos($moFile, get_locale()) > -1) {\n load_textdomain('WP_Visual_Chat', trailingslashit($this->dir) . 'languages/' . $moFile);\n }\n }\n }", "private function _loadBundle($bundle, $locale){\r\n\r\n\t\t$pathStructureArray = $this->pathStructure;\r\n\r\n\t\tforeach ($this->paths as $path) {\r\n\r\n\t\t\t$pathStructure = '';\r\n\r\n\t\t\t// Process the path format string\r\n\t\t\tif(count($pathStructureArray) > 0){\r\n\r\n\t\t\t\t$pathStructure = str_replace(['$bundle', '$locale'], [$bundle, $locale], array_shift($pathStructureArray));\r\n\t\t\t}\r\n\r\n\t\t\t$bundlePath = StringUtils::formatPath($path.DIRECTORY_SEPARATOR.$pathStructure);\r\n\r\n\t\t\tif(FilesManager::getInstance()->isFile($bundlePath)){\r\n\r\n\t\t\t\t$bundleData = FilesManager::getInstance()->readFile($bundlePath);\r\n\r\n\t\t\t\t$this->_loadedData[$bundle][$locale] = SerializationUtils::javaPropertiesToArray($bundleData);\r\n\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthrow new Exception('LocalesManager->_loadBundle: Could not load bundle <'.$bundle.'> and locale <'.$locale.'>');\r\n\t}", "private function _get_translations_from_file () {\n\n\t\t$lang = file_exists(self::DIR_LANGS . $this->lang . '.php')\n\t\t\t\t\t? $this->lang : $this->_default_lang;\n\n\t\trequire self::DIR_LANGS . $lang . '.php';\n\n\t\treturn $t;\n\n\t}", "function load_texts($file)\n{\n\n if (substr($file, -5) != '.json') {\n throw new Exception('Invalid language file found in language folder.');\n }\n\n $fname = strtolower(substr(basename($file), 0, - (strlen('.json'))));\n\n $GLOBALS[\"__LANGUAGE__{$fname}__\"] = json_decode(file_get_contents($file), true);\n}", "public static function loadLanguageForComponents($components)\n\t{\n\t\t$lang = JFactory::getLanguage();\n\n\t\tforeach ($components as $component)\n\t\t{\n\t\t\tif (!empty($component))\n\t\t\t{\n\t\t\t\t// Load the core file then\n\t\t\t\t// Load extension-local file.\n\t\t\t\t$lang->load($component . '.sys', JPATH_BASE, null, false, true)\n\t\t\t\t|| $lang->load($component . '.sys', JPATH_ADMINISTRATOR . '/components/' . $component, null, false, true);\n\t\t\t}\n\t\t}\n\t}", "protected abstract function getTranslations();", "protected function _load($class)\n {\n $path = SolarLite::classToPath($class);\n $file = $path . '/locale/' . $this->_code . '.php';\n \n // can we find the file?\n if (file_exists($file)) {\n // put the locale values into the shared locale array\n $this->trans[$class] = (array) include $file;\n } else {\n // could not find file.\n // fail silently, as it's often the case that the\n // translation file simply doesn't exist.\n $this->trans[$class] = array();\n }\n }", "protected function getTranslation_Loader_ResService()\n {\n return $this->services['translation.loader.res'] = new \\Symfony\\Component\\Translation\\Loader\\IcuResFileLoader();\n }", "protected function load_translations() {\n\t\t// load the plugin text domain\n\t\tload_plugin_textdomain( 'mailchimp-for-wp', false, 'mailchimp-for-wp-pro/languages/' );\n\t}", "public function testCanLoadLanguageFilesFromSpecifiedPath()\n {\n $this->translator->load();\n $messages = $this->translator->all();\n $this->assertArrayHasKey('test_message', $messages);\n }", "private static function loadLanguage()\n\t{\n\t\t// Load translations\n\t\t$basePath = dirname(__FILE__);\n\t\t$jlang = JFactory::getLanguage();\n\t\t$jlang->load('liveupdate', $basePath, 'en-GB', true); // Load English (British)\n\t\t$jlang->load('liveupdate', $basePath, $jlang->getDefault(), true); // Load the site's default language\n\t\t$jlang->load('liveupdate', $basePath, null, true); // Load the currently selected language\n\t}", "public function load_component_strings($component, $lang, $disablecache = false, $disablelocal = false) {\n global $CFG;\n\n list($plugintype, $pluginname) = core_component::normalize_component($component);\n if ($plugintype === 'core' and is_null($pluginname)) {\n $component = 'core';\n } else {\n $component = $plugintype . '_' . $pluginname;\n }\n\n $cachekey = $lang.'_'.$component.'_'.$this->get_key_suffix();\n\n $cachedstring = $this->cache->get($cachekey);\n if (!$disablecache and !$disablelocal) {\n if ($cachedstring !== false) {\n return $cachedstring;\n }\n }\n\n // No cache found - let us merge all possible sources of the strings.\n if ($plugintype === 'core') {\n $file = $pluginname;\n if ($file === null) {\n $file = 'moodle';\n }\n $string = array();\n // First load english pack.\n if (!file_exists(\"$CFG->dirroot/lang/en/$file.php\")) {\n return array();\n }\n include(\"$CFG->dirroot/lang/en/$file.php\");\n $enstring = $string;\n\n // And then corresponding local if present and allowed.\n if (!$disablelocal and file_exists(\"$this->localroot/en_local/$file.php\")) {\n include(\"$this->localroot/en_local/$file.php\");\n }\n // Now loop through all langs in correct order.\n $deps = $this->get_language_dependencies($lang);\n\n if (empty($deps)) {\n // This allows us to override also English strings.\n $deps = array('en');\n }\n\n foreach ($deps as $dep) {\n // The main lang string location.\n if (file_exists(\"$this->otherroot/$dep/$file.php\")) {\n include(\"$this->otherroot/$dep/$file.php\");\n }\n\n // Custom feature that allows plugins to override core strings (See MDL-46582).\n foreach (core_component::get_plugin_types() as $plugintype => $plugintypedir) {\n foreach (core_component::get_plugin_list($plugintype) as $pluginname => $plugindir) {\n $filename = \"$plugindir/lang/$dep/$file.php\";\n\n if (file_exists($filename)) {\n include($filename);\n }\n }\n }\n\n if (!$disablelocal and file_exists(\"$this->localroot/{$dep}_local/$file.php\")) {\n include(\"$this->localroot/{$dep}_local/$file.php\");\n }\n }\n\n } else {\n if (!$location = core_component::get_plugin_directory($plugintype, $pluginname) or !is_dir($location)) {\n return array();\n }\n if ($plugintype === 'mod') {\n // Bloody mod hack.\n $file = $pluginname;\n } else {\n $file = $plugintype . '_' . $pluginname;\n }\n $string = array();\n // First load English pack.\n if (!file_exists(\"$location/lang/en/$file.php\")) {\n // English pack does not exist, so do not try to load anything else.\n return array();\n }\n include(\"$location/lang/en/$file.php\");\n $enstring = $string;\n // And then corresponding local english if present.\n if (!$disablelocal and file_exists(\"$this->localroot/en_local/$file.php\")) {\n include(\"$this->localroot/en_local/$file.php\");\n }\n\n // Now loop through all langs in correct order.\n $deps = $this->get_language_dependencies($lang);\n\n if (empty($deps)) {\n // This allows us to override also English strings.\n $deps = array('en');\n }\n\n foreach ($deps as $dep) {\n // Legacy location - used by contrib only.\n if (file_exists(\"$location/lang/$dep/$file.php\")) {\n include(\"$location/lang/$dep/$file.php\");\n }\n // The main lang string location.\n if (file_exists(\"$this->otherroot/$dep/$file.php\")) {\n include(\"$this->otherroot/$dep/$file.php\");\n }\n\n // Custom feature that allows plugins to override strings of other plugins (See MDL-46582).\n foreach (core_component::get_plugin_types() as $plugintype => $plugintypedir) {\n foreach (core_component::get_plugin_list($plugintype) as $pluginname => $plugindir) {\n $filename = \"$plugindir/lang/$dep/{$file}.php\";\n\n if (file_exists($filename)) {\n include($filename);\n }\n }\n }\n\n // Local customisations.\n if (!$disablelocal and file_exists(\"$this->localroot/{$dep}_local/$file.php\")) {\n include(\"$this->localroot/{$dep}_local/$file.php\");\n }\n }\n }\n\n // We do not want any extra strings from other languages - everything must be in en lang pack.\n $string = array_intersect_key($string, $enstring);\n\n if (!$disablelocal) {\n // Now we have a list of strings from all possible sources,\n // cache it in MUC cache if not already there.\n if ($cachedstring === false) {\n $this->cache->set($cachekey, $string);\n }\n }\n return $string;\n }", "protected function getTranslation()\n {\n $language = $this->request->getBestLanguage();\n\n // Check if we have a translation file for that lang\n // TODO 处理英文\n if (file_exists(APP_PATH . \"/app/messages/\" . $language . \".php\")) {\n require_once APP_PATH. '/app/messages/'. $language . \".php\";\n } else {\n require_once APP_PATH. '/app/messages/zh-CN.php';\n // Fallback to some default\n// require \"../messages/en.php\";\n }\n\n // Return a translation object\n return new NativeArray(\n array(\n \"content\" => $messages\n )\n );\n }", "public function loadTranslations($lang, $module = null)\n\t{\n\t\t$this->_translations = array();\n\t\tfor(\n\t\t\t$it = new RecursiveDirectoryIterator($this->_translations_path.$lang.(null==$module ? '' : '/'.$module));\n\t\t\t$it->valid();\n\t\t\t$it->next()\n\t\t)\n\t\t{\n\t\t\tif(in_array($it->getBasename(), array('.', '..', ''))) continue;\n\t\t\tob_start();\n\t\t\t$data = @include($it->current());\n\t\t\tob_end_clean();\n\t\t\tif(is_array($data))\n\t\t\t{\n\t\t\t\t$this->_translations = array_merge($this->_translations, $data);\n\t\t\t}\n\t\t}\n\t}", "public function loadLanguage()\r\n {\r\n // init vars\r\n $element = strtolower($this->getElementType());\r\n $path = $this->app->path->path('elements:' . $element);\r\n $jlang = $this->app->system->language;\r\n // lets load first english, then joomla default standard, then user language\r\n $jlang->load('com_zoo.element.' . $element, $path, 'en-GB', true);\r\n $jlang->load('com_zoo.element.' . $element, $path, $jlang->getDefault(), true);\r\n $jlang->load('com_zoo.element.' . $element, $path, null, true);\r\n }", "protected function getTranslation_LoaderService()\n {\n $a = $this->get('translation.loader.xliff');\n\n $this->services['translation.loader'] = $instance = new \\Symfony\\Bundle\\FrameworkBundle\\Translation\\TranslationLoader();\n\n $instance->addLoader('php', $this->get('translation.loader.php'));\n $instance->addLoader('yml', $this->get('translation.loader.yml'));\n $instance->addLoader('xlf', $a);\n $instance->addLoader('xliff', $a);\n $instance->addLoader('po', $this->get('translation.loader.po'));\n $instance->addLoader('mo', $this->get('translation.loader.mo'));\n $instance->addLoader('ts', $this->get('translation.loader.qt'));\n $instance->addLoader('csv', $this->get('translation.loader.csv'));\n $instance->addLoader('res', $this->get('translation.loader.res'));\n $instance->addLoader('dat', $this->get('translation.loader.dat'));\n $instance->addLoader('ini', $this->get('translation.loader.ini'));\n $instance->addLoader('json', $this->get('translation.loader.json'));\n\n return $instance;\n }", "private function registerTranslations()\n {\n $langPath = $this->getBasePath() . '/resources/lang';\n\n $this->loadTranslationsFrom($langPath, $this->package);\n $this->publishes([\n $langPath => base_path(\"resources/lang/arcanedev/{$this->package}\"),\n ], 'translations');\n }", "protected function registerTranslations()\n {\n $this->loadTranslationsFrom($this->packagePath('resources/lang'), 'password');\n }", "function loadLanguage() {\r\n\t\tstatic $loaded ;\r\n\t\tif (!$loaded) {\r\n\t\t\t$lang = & JFactory::getLanguage() ;\r\n\t\t\t$tag = $lang->getTag();\r\n\t\t\tif (!$tag)\r\n\t\t\t\t$tag = 'en-GB' ;\t\t\t\r\n\t\t\t$lang->load('com_osmembership', JPATH_ROOT, $tag);\r\n\t\t\t$loaded = true ;\t\r\n\t\t}\t\t\r\n\t}", "public function getLoader($locale);", "public function loadResources() {\n\t\t$file = 'LLL:EXT:lang/locallang_core.xml:';\n\t\t$indicators = $this->getIndicators();\n\t\t$configuration = array(\n\t\t\t'LLL' => array(\n\t\t\t\t'copyHint' => $GLOBALS['LANG']->sL($file . 'tree.copyHint', TRUE),\n\t\t\t\t'fakeNodeHint' => $GLOBALS['LANG']->sL($file . 'mess.please_wait', TRUE),\n\t\t\t\t'activeFilterMode' => $GLOBALS['LANG']->sL($file . 'tree.activeFilterMode', TRUE),\n\t\t\t\t'dropToRemove' => $GLOBALS['LANG']->sL($file . 'tree.dropToRemove', TRUE),\n\t\t\t\t'buttonRefresh' => $GLOBALS['LANG']->sL($file . 'labels.refresh', TRUE),\n\t\t\t\t'buttonNewNode' => $GLOBALS['LANG']->sL($file . 'tree.buttonNewNode', TRUE),\n\t\t\t\t'buttonFilter' => $GLOBALS['LANG']->sL($file . 'tree.buttonFilter', TRUE),\n\t\t\t\t'dropZoneElementRemoved' => $GLOBALS['LANG']->sL($file . 'tree.dropZoneElementRemoved', TRUE),\n\t\t\t\t'dropZoneElementRestored' => $GLOBALS['LANG']->sL($file . 'tree.dropZoneElementRestored', TRUE),\n\t\t\t\t'searchTermInfo' => $GLOBALS['LANG']->sL($file . 'tree.searchTermInfo', TRUE),\n\t\t\t\t'temporaryMountPointIndicatorInfo' => $GLOBALS['LANG']->sl($file . 'labels.temporaryDBmount', TRUE),\n\t\t\t\t'deleteDialogTitle' => $GLOBALS['LANG']->sL('LLL:EXT:cms/layout/locallang.xml:deleteItem', TRUE),\n\t\t\t\t'deleteDialogMessage' => $GLOBALS['LANG']->sL('LLL:EXT:cms/layout/locallang.xml:deleteWarning', TRUE),\n\t\t\t\t'recursiveDeleteDialogMessage' => $GLOBALS['LANG']->sL('LLL:EXT:cms/layout/locallang.xml:recursiveDeleteWarning', TRUE),\n\t\t\t),\n\n\t\t\t'Configuration' => array(\n\t\t\t\t'hideFilter' => $GLOBALS['BE_USER']->getTSConfigVal('options.pageTree.hideFilter'),\n\t\t\t\t'displayDeleteConfirmation' => $GLOBALS['BE_USER']->jsConfirmation(4),\n\t\t\t\t'canDeleteRecursivly' => $GLOBALS['BE_USER']->uc['recursiveDelete'] == TRUE,\n\t\t\t\t'disableIconLinkToContextmenu' => $GLOBALS['BE_USER']->getTSConfigVal(\n\t\t\t\t\t'options.pageTree.disableIconLinkToContextmenu'\n\t\t\t\t),\n\t\t\t\t'indicator' => $indicators['html'],\n\t\t\t\t'temporaryMountPoint' => Tx_Taxonomy_Service_ExtDirect_Controller_Commands::getMountPointPath(),\n\t\t\t),\n\n\t\t\t'Sprites' => array(\n\t\t\t\t'Filter' => t3lib_iconWorks::getSpriteIconClasses('actions-system-tree-search-open'),\n\t\t\t\t'NewNode' => t3lib_iconWorks::getSpriteIconClasses('actions-page-new'),\n\t\t\t\t'Refresh' => t3lib_iconWorks::getSpriteIconClasses('actions-system-refresh'),\n\t\t\t\t'InputClear' => t3lib_iconWorks::getSpriteIconClasses('actions-input-clear'),\n\t\t\t\t'TrashCan' => t3lib_iconWorks::getSpriteIconClasses('actions-edit-delete'),\n\t\t\t\t'TrashCanRestore' => t3lib_iconWorks::getSpriteIconClasses('actions-edit-restore'),\n\t\t\t\t'Info' => t3lib_iconWorks::getSpriteIconClasses('actions-document-info'),\n\t\t\t)\n\t\t);\n\n\t\treturn $configuration;\n\t}", "protected function registerTranslations()\n {\n $this->loadTranslationsFrom($this->packagePath('resources/lang'), 'support');\n }", "function load_t2s_text(){\n\tglobal $config, $t2s_langfile, $t2s_text_stand, $templatepath;\n\t\n\tif (file_exists($templatepath.'/lang/'.$t2s_langfile)) {\n\t\t$TL = parse_ini_file($templatepath.'/lang/'.$t2s_langfile, true);\n\t} else {\n\t\tLOGGING(\"For selected T2S language no translation file still exist! Please go to LoxBerry Plugin translation and create a file for selected language \".substr($config['TTS']['messageLang'],0,2),3);\n\t\texit;\n\t}\n\treturn $TL;\n}", "public function translations()\n {\n $this->loadTranslationsFrom(__DIR__.'/Resources/Lang', $this->packageName);\n\n $this->publishes([\n __DIR__.'/path/to/translations' => resource_path('lang/vendor/courier'),\n ], $this->packageName.'-translations');\n }", "final public static function load_gettext($from) {\n static $byte = NULL;\n\n\n if (is_null($byte)) {\n $byte = function ($length, $endian, &$resource) {\n return unpack(($endian ? 'N' : 'V') . $length, fread($resource, 4 * $length));\n };\n }\n\n\n if ( ! is_file($from)) {\n return FALSE;\n }\n\n\n $out = array();\n $resource = fopen($from, 'rb');\n\n $test = $byte(1, $endian, $resource);\n $part = strtolower(substr(dechex($test[1]), -8));\n $endian = '950412de' === $part ? FALSE : ('de120495' === $part ? TRUE : NULL);\n\n $test = $byte(1, $endian, $resource);// revision\n $test = $byte(1, $endian, $resource);// bytes\n $all = $test[1];\n\n // offsets\n $test = $byte(1, $endian, $resource);\n $omax = $test[1];// original\n\n $test = $byte(1, $endian, $resource);\n $tmax = $test[1];// translate\n\n // tables\n fseek($resource, $omax);// original\n $otmp = $byte(2 *$all, $endian, $resource);\n\n fseek($resource, $tmax);// translate\n $ttmp = $byte(2 *$all, $endian, $resource);\n\n for ($i = 0; $i < $all; $i += 1) {\n $orig = -1;\n\n if ($otmp[$i * 2 + 1] <> 0) {\n fseek($resource, $otmp[$i * 2 + 2]);\n $orig = fread($resource, $otmp[$i * 2 + 1]);\n }\n\n if ($ttmp[$i * 2 + 1] <> 0) {\n fseek($resource, $ttmp[$i * 2 + 2]);\n $out[$orig] = fread($resource, $ttmp[$i * 2 + 1]);\n }\n }\n\n fclose($resource);\n unset($out[-1]);\n\n return $out;\n }", "function getTranslationObject();", "function load_custom_plugin_translation_file( $mofile, $domain ) { \n\t\n\t// folder location\n\t$folder = WP_PLUGIN_DIR . '/kinogeneva-translations/languages/';\n\t\n\t// filename ending\n\t$file = '-' . get_locale() . '.mo';\n\t\n\t$plugins = array(\n\t\t'buddypress',\n\t\t'bxcft',\n\t\t'wp-user-groups',\n\t\t'kleo_framework',\n\t\t'invite-anyone',\n\t\t'bp-groups-taxo',\n\t\t'bp-docs'\n\t);\n\t\n\tforeach ($plugins as &$plugin) {\n\t\tif ( $plugin === $domain ) {\n\t\t $mofile = $folder.$domain.$file;\n\t }\n\t}\n\n return $mofile;\n\n}", "function _load_languages()\r\n\t{\r\n\t\t// Load the form validation language file\r\n\t\t$this->lang->load('form_validation');\r\n\r\n\t\t// Load the DataMapper language file\r\n\t\t$this->lang->load('datamapper');\r\n\t}", "public static function loadLanguage()\n {\n static $loaded;\n if (!$loaded) {\n $lang = JFactory::getLanguage();\n $tag = $lang->getTag();\n if (!$tag)\n $tag = 'en-GB';\n $lang->load('com_osproperty', JPATH_ROOT, $tag);\n $loaded = true;\n }\n }", "private function loadResources(): void\n {\n foreach ($this->options['resource_files'] as $locale => $files) {\n foreach ($files as $key => $file) {\n $c = mb_substr_count($file, '.');\n\n if ($c < 2) {\n // filename is domain.format\n list($domain, $format) = explode('.', basename($file), 2);\n } else {\n // filename is domain.locale.format\n list($domain, $locale, $format) = explode('.', basename($file), 3);\n }\n\n $this->addResource($format, $file, $locale, $domain);\n unset($this->options['resource_files'][$locale][$key]);\n }\n }\n }", "private function loadLocale($lang, $fileBase, $messageKey){\r\n\r\n if(!isset($this->messages[$lang])){\r\n $this->messages[$lang] = [];\r\n }\r\n\r\n // load from file\r\n if(!isset($this->messsages[$lang][$fileBase])){\r\n\r\n $localSuffix = '/'.self::LOCALE_DIRNAME.'/'. $lang .'/'.$fileBase.self::LOCALE_FILE_EXTENSION;\r\n\r\n $localeFile = new File(APP_PATH.$localSuffix);\r\n\r\n if($localeFile->exists()){\r\n\r\n // when the module not\r\n $this->messsages[$lang][$fileBase] = require_once ($localeFile->getPath());\r\n\r\n\r\n\r\n }\r\n\r\n if(!isset($this->messsages[$lang][$fileBase][$messageKey])){\r\n foreach (Deployment::instance()->modules as $moduleName => $moduleDef){\r\n if($moduleName == $fileBase){\r\n\r\n $moduleFileBase = Strings::splitBy($messageKey, self::MESSAGE_PATH_SEPARATOR)[0];\r\n\r\n $this->tryToLoadLocaleFormModule($lang, $moduleName, $moduleDef['path'], $moduleFileBase);\r\n\r\n }\r\n }\r\n }\r\n\r\n // could not loaded from anywhere\r\n if(!isset($this->messsages[$lang][$fileBase]))\r\n $this->messsages[$lang][$fileBase] = [];\r\n\r\n }\r\n\r\n $this->loadedFileBases[] = $fileBase;\r\n }", "function acp_load_language( $file=\"\" )\n {\n \tif ( ! $this->lang_id )\n \t{\n \t\t$this->lang_id = $this->member['language'] ? $this->member['language'] : $this->vars['default_language'];\n\n\t\t\tif ( ($this->lang_id != $this->vars['default_language']) and ( ! is_dir( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id ) ) )\n\t\t\t{\n\t\t\t\t$this->lang_id = $this->vars['default_language'];\n\t\t\t}\n\t\t\t\n\t\t\t//-----------------------------------------\n\t\t\t// Still nothing?\n\t\t\t//-----------------------------------------\n\t\t\t\n\t\t\tif ( ! $this->lang_id )\n\t\t\t{\n\t\t\t\t$this->lang_id = 'en';\n\t\t\t}\n\t\t}\n \t\n \t//-----------------------------------------\n \t// Load it\n \t//-----------------------------------------\n\n \tif( file_exists( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id.\"/\".$file.\".php\" ) )\n \t{\n\t require_once( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id.\"/\".$file.\".php\" );\n\t \n\t if ( is_array( $lang ) )\n\t {\n\t\t\t\tforeach ($lang as $k => $v)\n\t\t\t\t{\n\t\t\t\t\t$this->acp_lang[ $k ] = $v;\n\t\t\t\t}\n\t }\n }\n \n unset($lang);\n }", "public function loadLanguage( $module = null )\r\n\t{\r\n\t\tstatic $included = array();\r\n\t\t\r\n\t\t$dun\t= & get_dunamis( $module );\r\n\t\t$path\t= $dun->getModulePath( $module, 'lang');\r\n\t\t$idiom\t= $this->getIdiom();\r\n\t\t\r\n\t\t$paths\t\t=\tarray( $path . 'English.php', $path . ucfirst( $idiom ) . '.php' );\r\n\t\t\r\n\t\tforeach ( $paths as $path ) {\r\n\t\t\tif (! file_exists( $path ) ) continue;\r\n\t\t\t$s\t=\tbase64_encode( $path );\r\n\t\t\t\r\n\t\t\tif (! isset( $included[$s] ) ) $included[$s] = null;\r\n\t\t\t\r\n\t\t\tif ( empty( $included[$s] ) ) {\r\n\t\t\t\tinclude_once( $path );\r\n\t\t\t\t$included[$s]\t=\t$lang;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$lang = $included[$s];\r\n\t\t\t\r\n\t\t\t$this->appendTranslations( $lang, $module );\r\n\t\t}\r\n\t\t\r\n\t\treturn self :: $instance;\r\n\t}", "public function initI18N()\n {\n $reflector = new \\ReflectionClass(get_class($this));\n $dir = dirname($reflector->getFileName());\n\n if (!empty($this->config['message'])) {\n foreach ($this->config['message'] as $message) {\n Yii::setAlias(\"@\".$message, $dir);\n $config = [\n 'class' => 'yii\\i18n\\PhpMessageSource',\n 'basePath' => \"@\".$message.\"/messages\",\n 'forceTranslation' => true\n ];\n $globalConfig = ArrayHelper::getValue(Yii::$app->i18n->translations, $message.\"*\", []);\n if (!empty($globalConfig)) {\n $config = array_merge(\n $config,\n is_array($globalConfig) ? $globalConfig : (array) $globalConfig\n );\n }\n Yii::$app->i18n->translations[$message.\"*\"] = $config;\n }\n }\n\n }", "public function getTranslationsForKey($key);", "function loadComponent($component) {\n\tglobal $_base;\n\n\t$component = \"./include/core/\" . $component . \".php\";\n\t// component exists?\n\tif (file_exists($component)) {\n\t\trequire_once($component);\n\t}\n}", "function loadResource($filename, $inherited=false, $storelastresource=true)\r\n {\r\n global $application;\r\n\r\n //$start=microtime(true);\r\n\r\n if (!isset($_SESSION['comps.'.$this->readNamePath()]) && !$inherited)\r\n {\r\n if ($this->inheritsFrom('Page'))\r\n {\r\n if ($this->classParent()!='Page')\r\n {\r\n $varname=$this->classParent();\r\n global $$varname;\r\n $baseobject=$$varname;\r\n $this->loadResource($baseobject->lastresourceread, true);\r\n }\r\n }\r\n }\r\n\r\n if ($storelastresource)\r\n {\r\n $this->lastresourceread=$filename;\r\n }\r\n //TODO: Check here for the path to the resource file\r\n //$resourcename=basename($filename);\r\n $resourcename=$filename;\r\n $l=\"\";\r\n\r\n if ((($application->Language!='')) || (($this->inheritsFrom('Page')) && ($this->Language!='(default)')))\r\n {\r\n $resourcename=str_replace('.php',$l.'.xml.php',$filename);\r\n $this->readFromResource($resourcename);\r\n\r\n $l=\".\".$application->Language;\r\n $resourcename=str_replace('.php',$l.'.xml.php',$filename);\r\n if (file_exists($resourcename))\r\n {\r\n $this->readFromResource($resourcename, false, false);\r\n }\r\n }\r\n else\r\n {\r\n $resourcename=str_replace('.php',$l.'.xml.php',$resourcename);\r\n $this->readFromResource($resourcename);\r\n }\r\n //$finish=microtime(true);\r\n //echo 'loading:'.($finish-$start);\r\n }", "public function loadLanguage()\n {\n load_plugin_textdomain('rd-events', false, dirname(plugin_basename(RDEVENTS_FILE)) . '/App/languages/');\n }", "private function read() \n {\n if ($this->lang == '') $this->lang = App::getLocale();\n $this->path = base_path().'/resources/lang/'.$this->lang.'/'.$this->file.'.php';\n $this->arrayLang = Lang::get($this->file);\n if (gettype($this->arrayLang) == 'string') $this->arrayLang = array();\n }", "protected function registerResources()\n {\n $this->loadJsonTranslationsFrom(__DIR__ . '/../../resources/lang');\n $this->loadViewsFrom(__DIR__ . '/../../resources/views', 'knet');\n }", "public static function loadLang() {\n\t\tif (!is_object($GLOBALS['LANG'])) {\n\n\t\t\trequire_once t3lib_extMgm::extPath('lang') . 'lang.php';\n\t\t\t//TODO see pt_tool smarty!\n\t\t\t$GLOBALS['LANG'] = t3lib_div::makeInstance('language');\n\t\t\t$GLOBALS['LANG']->csConvObj = t3lib_div::makeInstance('t3lib_cs');\n\t\t}\n\t\tif (is_object($GLOBALS['TSFE']) && $GLOBALS['TSFE']->config['config']['language']) {\n\t\t\t$LLkey = $GLOBALS['TSFE']->config['config']['language'];\n\t\t\t$GLOBALS['LANG']->init($LLkey);\n\t\t}\n\n\t}", "private function getTranslations( $domain )\n\t{\n\t\tif( !isset( $this->translations[$domain] ) )\n\t\t{\n\t\t\tif( !isset( $this->translationSources[$domain] ) )\n\t\t\t{\n\t\t\t\t$msg = sprintf( 'No translation directory for domain \"%1$s\" available', $domain );\n\t\t\t\tthrow new \\Aimeos\\MW\\Translation\\Exception( $msg );\n\t\t\t}\n\n\t\t\t// Reverse locations so the former gets not overwritten by the later\n\t\t\t$locations = array_reverse( $this->getTranslationFileLocations( $this->translationSources[$domain], $this->getLocale() ) );\n\n\t\t\tforeach( $locations as $location )\n\t\t\t{\n\t\t\t\tif( ( $content = file_get_contents( $location ) ) === false ) {\n\t\t\t\t\tthrow new \\Aimeos\\MW\\Translation\\Exception( 'No translation file \"%1$s\" available', $location );\n\t\t\t\t}\n\n\t\t\t\tif( ( $content = unserialize( $content ) ) === false ) {\n\t\t\t\t\tthrow new \\Aimeos\\MW\\Translation\\Exception( 'Invalid content in translation file \"%1$s\"', $location );\n\t\t\t\t}\n\n\t\t\t\t$this->translations[$domain][] = $content;\n\t\t\t}\n\t\t}\n\n\t\treturn $this->translations[$domain];\n\t}", "public function load_textdomain() {\n\t\t\t$mo_file_path = dirname( __FILE__ ) . '/languages/' . get_locale() . '.mo';\n\n\t\t\tload_textdomain( 'cherry-framework', $mo_file_path );\n\t\t}", "function getResourcesLangPath($module)\n {\n return \"$module->path/{$this->localizationSettings->moduleLangPath}\";\n }", "protected function registerLoader()\n {\n $this->app->singleton('translation.loader', function (Application $app) {\n $defaultLocale = $app->getLocale();\n $cacheTimeout = config('translator.cache.timeout', 60);\n\n $laravelFileLoader = new LaravelFileLoader($app['files'], base_path('/lang'));\n $fileLoader = new FileLoader($defaultLocale, $laravelFileLoader);\n $databaseLoader = new DatabaseLoader($defaultLocale, $app->make(TranslationRepository::class));\n $loader = new MixedLoader($defaultLocale, $databaseLoader, $fileLoader);\n\n return new CacheLoader($defaultLocale, $app['translation.cache.repository'], $loader, $cacheTimeout);\n });\n }", "function load($langfile = '', $idiom = '')\n\t{\n\t\tif (is_array($langfile))\n\t\t{\n\t\t\t$temp = $langfile;\n\t\t\t$langfile = $temp['0'];\n\t\t\t$idiom = $temp['1'];\n\t\t}\n\t\n\t\t$langfile = str_replace(EXT, '', str_replace('_lang.', '', $langfile)).'_lang'.EXT;\n\t\t\n\t\tif (call('CI', 'is_loaded', $langfile) == TRUE)\n\t\t{\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif ($idiom == '')\n\t\t{\n\t\t\t$deft_lang = call('config', 'item', 'language');\n\t\t\t$idiom = ($deft_lang == '') ? 'english' : $deft_lang;\n\t\t}\n\t\n\t\tif ( ! file_exists(BASEPATH.'language/'.$idiom.'/'.$langfile))\n\t\t{\n\t\t\tshow_error('Unable to load the requested language file: language/'.$langfile.EXT);\n\t\t}\n\n\t\tinclude_once(BASEPATH.'language/'.$idiom.'/'.$langfile);\n\t\t \n\t\tif ( ! isset($lang))\n\t\t{\n\t\t\tlog_message('error', 'Language file contains no data: language/'.$idiom.'/'.$langfile);\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t$this->ci_is_loaded[] = $langfile;\n\t\t$this->language = array_merge($this->language, $lang);\n\t\tunset($lang);\n\t\t\n\t\tlog_message('debug', 'Language file loaded: language/'.$idiom.'/'.$langfile);\n\t}", "protected function cargarArchivosIdiomas(){\n $this->lang->load('menu', $this->idioma);\n $this->lang->load('uri', $this->idioma);\n $this->lang->load('label', $this->idioma);\n $this->lang->load('static', $this->idioma);\n $this->lang->load('messages', $this->idioma);\n }", "public function localization() {\n\t\t\tload_plugin_textdomain( 'bitlive-custom-codes', false, __DIR__ . '/languages/' );\n\t\t}", "function wp_load_translations_early()\n {\n }", "function getTranslationsOfModule($module)\n {\n $translations = [];\n $resourcesLangPath = $this->getResourcesLangPath($module);\n $iniFiles = $this->getIniFilesOfModule($module);\n foreach ($iniFiles as $file => $data)\n $translations[str_replace('.ini', '', $data)] = parse_ini_file (\"$resourcesLangPath/$data\");\n\n return $translations;\n }", "public function testCanGetMessageByKeyFromTranslator()\n {\n $this->translator->load();\n $message = $this->translator->get('test_message');\n $this->assertEquals('file has been loaded', $message);\n }", "public static function load(string $lang): array\n {\n if (isset(static::$_cache[$lang])) {\n return static::$_cache[$lang];\n }\n\n // New translation table\n $table = [[]];\n\n // Split the language: language, region, locale, etc\n $parts = explode('-', $lang);\n\n // Loop through Paths\n foreach ([$parts[0], implode(DIRECTORY_SEPARATOR, $parts)] as $path) {\n // Load files\n $files = Core::findFile('i18n', $path);\n\n // Loop through files\n if (!empty($files)) {\n $t = [[]];\n foreach ($files as $file) {\n // Merge the language strings into the sub table\n $t[] = Core::load($file);\n }\n $table[] = $t;\n }\n }\n\n $table = array_merge(...array_merge(...$table));\n\n // Cache the translation table locally\n return static::$_cache[$lang] = $table;\n }", "function loadLanguagePackade($jsonstrorlink, $defaultLang=\"en\") {\r\n if(is_array($jsonstrorlink)) {\r\n $streams = [];\r\n foreach($jsonstrorlink as $entry) {\r\n if(strpos($entry, \"file:///\")===0) {\r\n $entry = str_replace(\"file:///\", \"\", $entry);\r\n array_push($streams, json_decode(file_get_contents($entry, true)));\r\n } else {\r\n array_push($streams, json_decode($jsonstrorlink, true));\r\n }\r\n }\r\n $parsedLangDescriptor = new TemplaterLanguageDescriptor($streams, [\"defaultLang\"=>$defaultLang]);\r\n } else {\r\n if(strpos($jsonstrorlink, \"file:///\")===0) {\r\n $jsonstrorlink = str_replace(\"file:///\", \"\", $jsonstrorlink);\r\n $stream = file_get_contents($jsonstrorlink);\r\n } else {\r\n $stream = $jsonstrorlink;\r\n }\r\n $parsedLangDescriptor = new TemplaterLanguageDescriptor([json_decode($stream, true)], [\"defaultLang\"=>$defaultLang]);\r\n }\r\n array_push($this->langsInstances, $parsedLangDescriptor); \r\n }", "public function loadDictionary()\n {\n if (self::$dictionary_loaded) {\n return true;\n }\n\n if ($this->use_apcu) {\n do {\n if (!apcu_exists(\"dictionary_supported_languages\")) {\n break;\n }\n\n self::$supported_languages = apcu_fetch(\"dictionary_supported_languages\");\n if (empty(self::$supported_languages)) {\n break;\n }\n\n if (!apcu_exists(\"dictionary_languages\")) {\n break;\n }\n self::$languages = apcu_fetch(\"dictionary_languages\");\n if (empty(self::$languages)) {\n break;\n }\n\n if (!apcu_exists(\"dictionary_countries\")) {\n break;\n }\n self::$countries = apcu_fetch(\"dictionary_countries\");\n if (empty(self::$countries)) {\n break;\n }\n\n if (!apcu_exists(\"dictionary_texts\")) {\n break;\n }\n self::$texts = apcu_fetch(\"dictionary_texts\");\n if (empty(self::$texts)) {\n break;\n }\n\n return true;\n } while (false);\n }\n\n $json_array = [];\n\n $json = file_get_contents($this->localization_path . \"config.json\");\n if ($json === false) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"config.json\" . \"' cannot be loaded or does not exist!\");\n }\n\n try {\n json_to_array($json, $json_array);\n } catch (\\Throwable $ex) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"config.json\" . \"' is invalid!\" . \"\\n\\n\" . $ex->getMessage());\n }\n\n $json = file_get_contents($this->localization_path . \"languages.json\");\n if ($json === false) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"languages.json\" . \"' cannot be loaded or does not exist!\");\n }\n\n try {\n json_to_array($json, $json_array[\"languages\"]);\n } catch (\\Throwable $ex) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"languages.json\" . \"' is invalid!\" . \"\\n\\n\" . $ex->getMessage());\n }\n\n $json = file_get_contents($this->localization_path . \"countries.json\");\n if ($json === false) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"countries.json\" . \"' cannot be loaded or does not exist!\");\n }\n\n try {\n json_to_array($json, $json_array[\"countries\"]);\n } catch (\\Throwable $ex) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"countries.json\" . \"' is invalid!\" . \"\\n\\n\" . $ex->getMessage());\n }\n\n $json = file_get_contents($this->localization_path . \"texts.json\");\n if ($json === false) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"texts.json\" . \"' cannot be loaded or does not exist!\");\n }\n\n try {\n json_to_array($json, $json_array[\"texts\"]);\n } catch (\\Throwable $ex) {\n throw new \\Exception(\"Translation file '\" . $this->localization_path . \"texts.json\" . \"' is invalid!\" . \"\\n\\n\" . $ex->getMessage());\n }\n\n if (!empty($this->additional_localization_files)) {\n foreach ($this->additional_localization_files as $localization_file) {\n $json = file_get_contents($localization_file);\n if ($json === false) {\n throw new \\Exception(\"Translation file '\" . $localization_file . \"' cannot be loaded or does not exist!\");\n }\n\n try {\n $translation_texts = [];\n json_to_array($json, $translation_texts);\n\n $json_array[\"texts\"] = array_merge($json_array[\"texts\"], $translation_texts);\n } catch (\\Throwable $ex) {\n throw new \\Exception(\"Translation file '\" . $localization_file . \"' is invalid!\" . \"\\n\\n\" . $ex->getMessage());\n }\n }\n }\n\n if (!empty($json_array[\"interface_languages\"])) {\n foreach ($json_array[\"interface_languages\"] as $lang_code) {\n self::$supported_languages[$lang_code] = $lang_code;\n }\n }\n\n if (!empty($json_array[\"languages\"])) {\n foreach ($json_array[\"languages\"] as $text_id => &$translations) {\n foreach ($translations as $lang_code => $translation) {\n self::$languages[$lang_code][$text_id] = $translation;\n }\n }\n }\n\n if (!empty($json_array[\"countries\"])) {\n foreach ($json_array[\"countries\"] as $text_id => &$translations) {\n foreach ($translations as $lang_code => $translation) {\n self::$countries[$lang_code][$text_id] = $translation;\n }\n }\n }\n\n if (!empty($json_array[\"texts\"])) {\n foreach ($json_array[\"texts\"] as $text_id => &$translations) {\n foreach ($translations as $lang_code => $translation) {\n self::$texts[$lang_code][$text_id] = $translation;\n }\n }\n }\n\n self::$dictionary_loaded = true;\n\n foreach (self::$supported_languages as $lng) {\n self::$current_language = $lng;\n break;\n }\n\n if ($this->use_apcu) {\n apcu_store(\"dictionary_supported_languages\", self::$supported_languages);\n apcu_store(\"dictionary_languages\", self::$languages);\n apcu_store(\"dictionary_countries\", self::$countries);\n apcu_store(\"dictionary_texts\", self::$texts);\n }\n\n return true;\n }", "public function loadLanguage() {\n\t\t$this->languageLoaded = true;\n\t\t$filename = TMP_DIR.TMP_FILE_PREFIX.$this->data['languageCode'].'_'.$this->data['languageEncoding'].'_wcf.setup.php';\n\t\t\n\t\tif (!file_exists($filename)) {\n\t\t\t$xml = new XML(TMP_DIR.TMP_FILE_PREFIX.'setup_'.$this->data['languageCode'].'.xml');\n\t\t\t\n\t\t\t// compile an array with XML::getElementTree\n\t\t\t$languageXML = $xml->getElementTree('language');\n\n\t\t\t// extract attributes (language code, language name)\n\t\t\t//$languageXML = array_merge($languageXML, $languageXML['attrs']);\n\n\t\t\t// get language items\n\t\t\t$categoriesToCache = array();\n\t\t\tforeach ($languageXML['children'] as $key => $languageCategory) {\n\t\t\t\t// language category does not exist yet, create it\n\t\t\t\tif (isset($languageCategory['children'])) {\n\t\t\t\t\tforeach ($languageCategory['children'] as $key2 => $languageitem) {\n\t\t\t\t\t\t$categoriesToCache[] = array( 'name' => $languageitem['attrs']['name'], 'cdata' => $languageitem['cdata']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// update language files here\n\t\t\tif (count($categoriesToCache) > 0) {\n\t\t\t\t$file = new File($filename);\n\t\t\t\t$file->write(\"<?php\\n/**\\n* WoltLab Community Framework\\n* language: \".$this->data['languageCode'].\"\\n* encoding: \".$this->data['languageEncoding'].\"\\n* category: WCF Setup\\n* generated at \".gmdate(\"r\").\"\\n* \\n* DO NOT EDIT THIS FILE\\n*/\\n\");\n\t\t\t\tforeach ($categoriesToCache as $value => $name) {\n\t\t\t\t\t// simple_xml returns values always UTF-8 encoded\n\t\t\t\t\t// manual decoding to charset necessary\n\t\t\t\t\tif ($this->data['languageEncoding'] != 'UTF-8') {\n\t\t\t\t\t\t$name['cdata'] = StringUtil::convertEncoding('UTF-8', $this->data['languageEncoding'], $name['cdata']);\n\t\t\t\t\t}\n\t\t\t\t\t$file->write(\"\\$this->items[\\$this->languageID]['\".$name['name'].\"'] = '\".str_replace(\"'\", \"\\'\", $name['cdata']).\"';\\n\");\n\t\t\t\t\t\n\t\t\t\t\t// compile dynamic language variables\n\t\t\t\t\tif (strpos($name['cdata'], '{') !== false) {\n\t\t\t\t\t\t$file->write(\"\\$this->dynamicItems[\\$this->languageID]['\".$name['name'].\"'] = '\".str_replace(\"'\", \"\\'\", self::getScriptingCompiler()->compileString($name['name'], $name['cdata'])).\"';\\n\");\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\n\t\t\t\t$file->write(\"?>\");\n\t\t\t\t$file->close();\n\t\t\t}\n\t\t}\n\n\t\tinclude_once($filename);\n\t\t$this->setLocale();\n\t}", "private function loadExtensionLanguage(&$item)\n\t{\n\t\t// Get the language.\n\t\t$lang = JFactory::getLanguage();\n\n\t\t$path = $item->client_id ? JPATH_ADMINISTRATOR : JPATH_SITE;\n\n\t\tswitch ($item->type)\n\t\t{\n\t\t\tcase 'component':\n\t\t\t\t$extension = $item->element;\n\t\t\t\t$source = JPATH_ADMINISTRATOR . '/components/' . $extension;\n\t\t\t\t$lang->load(\"$extension.sys\", JPATH_ADMINISTRATOR, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", JPATH_ADMINISTRATOR, $lang->getDefault(), false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'file':\n\t\t\t\t$extension = 'files_' . $item->element;\n\t\t\t\t$lang->load(\"$extension.sys\", JPATH_SITE, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", JPATH_SITE, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'library':\n\t\t\t\t$extension = 'lib_' . $item->element;\n\t\t\t\t$lang->load(\"$extension.sys\", JPATH_SITE, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", JPATH_SITE, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'module':\n\t\t\t\t$extension = $item->element;\n\t\t\t\t$source = $path . '/modules/' . $extension;\n\t\t\t\t$lang->load(\"$extension.sys\", $path, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $path, $lang->getDefault(), false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'package':\n\t\t\t\t$extension = $item->element;\n\t\t\t\t$lang->load(\"$extension.sys\", JPATH_SITE, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", JPATH_SITE, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'plugin':\n\t\t\t\t$extension = 'plg_' . $item->folder . '_' . $item->element;\n\t\t\t\t$source = JPATH_PLUGINS . '/' . $item->folder . '/' . $item->element;\n\t\t\t\t$lang->load(\"$extension.sys\", JPATH_ADMINISTRATOR, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", JPATH_ADMINISTRATOR, $lang->getDefault(), false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t\tcase 'template':\n\t\t\t\t$extension = 'tpl_' . $item->element;\n\t\t\t\t$source = $path . '/templates/' . $item->element;\n\t\t\t\t$lang->load(\"$extension.sys\", $path, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, null, false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $path, $lang->getDefault(), false, false)\n\t\t\t\t|| $lang->load(\"$extension.sys\", $source, $lang->getDefault(), false, false);\n\t\t\tbreak;\n\t\t}\n\t}", "public function loadTranslations(string $directoryPath): void\n {\n if (!\\file_exists($directoryPath)) {\n throw new InvalidArgumentException('Directory with translations not found');\n }\n\n $directoryPath = \\rtrim($directoryPath, '/\\\\') . DIRECTORY_SEPARATOR;\n $extension = 'php';\n\n foreach (new DirectoryIterator($directoryPath) as $file) {\n if ($file->isDot() || $file->isDir()) {\n continue;\n }\n\n if ($file->getExtension() !== $extension) {\n continue;\n }\n\n $filename = $file->getFilename();\n $key = $file->getBasename('.' . $extension);\n\n $translations = require $directoryPath . $filename;\n\n if (\\is_array($translations)) {\n foreach (\\array_keys($translations) as $locale) {\n $this->isValidLocale($locale); // Validate the given locale\n }\n\n $this->translations[$key] = $translations;\n }\n }\n }", "protected function registerLoader()\n {\n $this->app->singleton('translation.loader', function ($app) {\n $class = $this->app['config']->get('laravel-multilingual.translation_manager');\n\n return new $class($app['files'], $app['path.lang']);\n });\n }", "public function i18n() {\r\n load_plugin_textdomain( 'woolentor-pro', false, dirname( plugin_basename( WOOLENTOR_ADDONS_PL_ROOT_PRO ) ) . '/languages/' );\r\n }", "function inspiry_load_translation_from_child() {\n\t\tload_child_theme_textdomain( 'framework', get_stylesheet_directory() . '/languages' );\n\t}", "protected function importContents($filename, $locale, $bundlename,\n $domain = 'messages')\n {\n $em = $this->getContainer()->get('doctrine')->getManager();\n\n $translator_format = $this->getContainer()\n ->getParameter('translator_format');\n $loader = Loader::create($translator_format);\n $locale_file_contents = $loader->load($filename, $locale, $domain);\n $repository = $locale_file_contents->all();\n\n // Import all the messages for this domain into the document manager\n foreach ($repository[$domain] as $translation_key => $translation) {\n // Check if it's already in?\n $translation_entry = $em\n ->getRepository('WebTranslatorBundle:Translation')\n ->findOneBy(\n array('translation_key' => $translation_key,\n 'domain' => $domain,\n 'bundlename' => $bundlename));\n // Escape escaped double quotes (from our exportContents)\n $translation = str_replace('\\\"', '\"', $translation);\n if (!empty($translation_entry)) {\n $msgs = $translation_entry->getMessages();\n\n $message = $em\n ->getRepository('WebTranslatorBundle:Message')\n ->findOneBy(\n array('translation' => $translation_entry,\n 'locale' => $locale));\n if (null === $message) {\n $message = new Message();\n $message->setTranslation($translation_entry);\n $message->setLocale($locale);\n $message->setMessage($translation);\n\n $msgs->add($message);\n\n $translation_entry->setMessages($msgs);\n\n $em->persist($message);\n $em->persist($translation_entry);\n }\n\n } else {\n $entry = new Translation();\n $entry->setTranslationKey($translation_key);\n $entry->setDomain($domain);\n $entry->setBundlename($bundlename);\n\n $message = new Message();\n $message->setTranslation($entry);\n $message->setLocale($locale);\n $message->setMessage($translation);\n\n $em->persist($message);\n $em->persist($entry);\n }\n }\n\n $em->flush();\n }", "protected function registerLoader()\n {\n $this->app->singleton('translation.loader', function ($app) {\n return new TranslationLoader($app['files'], $app['path.lang']);\n });\n }", "function load_language( $file=\"\" )\n {\n\t\t//-----------------------------------------\n\t\t// Memory\n\t\t//-----------------------------------------\n\t\t\n\t\t$_NOW = $this->memory_debug_make_flag();\n\t\t\n\t $this->vars['default_language'] = isset($this->vars['default_language']) ? $this->vars['default_language'] : 'en';\n\t \n \tif ( ! $this->lang_id )\n \t{\n \t\t$this->lang_id = isset($this->member['language']) ? $this->member['language'] : $this->vars['default_language'];\n\n\t\t\tif ( ($this->lang_id != $this->vars['default_language']) and ( ! is_dir( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id ) ) )\n\t\t\t{\n\t\t\t\t$this->lang_id = $this->vars['default_language'];\n\t\t\t}\n\t\t\t\n\t\t\t//-----------------------------------------\n\t\t\t// Still nothing?\n\t\t\t//-----------------------------------------\n\t\t\t\n\t\t\tif ( ! $this->lang_id )\n\t\t\t{\n\t\t\t\t$this->lang_id = 'en';\n\t\t\t}\n\t\t}\n \t\n \t//-----------------------------------------\n \t// Load it\n \t//-----------------------------------------\n\t\t\n\t\tif ( file_exists( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id.\"/\".$file.\".php\" ) )\n\t\t{\n \trequire ( ROOT_PATH.\"cache/lang_cache/\".$this->lang_id.\"/\".$file.\".php\" );\n \n\t if ( isset($lang) AND is_array( $lang ) )\n\t {\n\t\t\t\tforeach ($lang as $k => $v)\n\t\t\t\t{\n\t\t\t\t\t$this->lang[ $k ] = $v;\n\t\t\t\t}\n\t }\n\t }\n\t\t\n\t\t//-----------------------------------------\n\t\t// Memory\n\t\t//-----------------------------------------\n\t\t\n\t\t$this->memory_debug_add( \"IPSCLASS: Loaded language file - $file\", $_NOW );\n\t\t\n\t\t//-----------------------------------------\n\t\t// Clean up\n\t\t//-----------------------------------------\n\t\t\n\t\tunset( $lang, $file );\n }", "protected function registerTranslations()\n {\n Yii::$app->i18n->translations['bupy7/notify/ss'] = [\n 'class' => 'yii\\i18n\\PhpMessageSource',\n 'forceTranslation' => true,\n 'basePath' => '@bupy7/notify/ss/messages',\n 'fileMap' => [\n 'bupy7/notify/ss' => 'core.php',\n ],\n ];\n }", "public function testLoadTranslation(): void\n {\n $data = [];\n $data['author'] = 'John Doe';\n $data['topic'] = 'English topic';\n $data['text'] = 'English text';\n $data['nullable'] = 'not null';\n $data['settings'] = ['key' => 'value'];\n\n $node = $this->getTestNode();\n\n $strategy = new ChildTranslationStrategy($this->dm);\n $strategy->saveTranslation($data, $node, $this->metadata, 'en');\n\n // Save translation in another language\n $data = [];\n $data['author'] = 'John Doe';\n $data['topic'] = 'Sujet français';\n $data['text'] = 'Texte français';\n\n $strategy->saveTranslation($data, $node, $this->metadata, 'fr');\n $this->dm->flush();\n\n $doc = new Article();\n $doc->author = $data['author'];\n $doc->topic = $data['topic'];\n $doc->setText($data['text']);\n $strategy->loadTranslation($doc, $node, $this->metadata, 'en');\n\n // And check the translatable properties have the correct value\n $this->assertEquals('English topic', $doc->topic);\n $this->assertEquals('English text', $doc->getText());\n $this->assertEquals('not null', $doc->nullable);\n $this->assertEquals(['key' => 'value'], $doc->getSettings());\n\n // Load another language and test the document has been updated\n $strategy->loadTranslation($doc, $node, $this->metadata, 'fr');\n\n $this->assertEquals('Sujet français', $doc->topic);\n $this->assertEquals('Texte français', $doc->text);\n $this->assertNull($doc->nullable);\n $this->assertEquals([], $doc->getSettings());\n }", "protected function registerLoader()\n {\n $this->app->singleton('translation.loader', function ($app) {\n $class = config('translation-loader.translation_manager');\n\n return new $class($app['files'], $app['path.lang']);\n });\n }", "public function load_lang() {\n /** Set our unique textdomain string */\n $textdomain = 'ninja-forms';\n\n /** The 'plugin_locale' filter is also used by default in load_plugin_textdomain() */\n $locale = apply_filters( 'plugin_locale', get_locale(), $textdomain );\n\n /** Set filter for WordPress languages directory */\n $wp_lang_dir = apply_filters(\n 'ninja_forms_wp_lang_dir',\n WP_LANG_DIR . '/ninja-forms/' . $textdomain . '-' . $locale . '.mo'\n );\n\n /** Translations: First, look in WordPress' \"languages\" folder = custom & update-secure! */\n load_textdomain( $textdomain, $wp_lang_dir );\n\n /** Translations: Secondly, look in plugin's \"lang\" folder = default */\n $plugin_dir = trailingslashit( basename( dirname( dirname( __FILE__ ) ) ) ) . basename( dirname( __FILE__ ) );\n $lang_dir = apply_filters( 'ninja_forms_lang_dir', $plugin_dir . '/lang/' );\n load_plugin_textdomain( $textdomain, FALSE, $lang_dir );\n }", "public function orderLoadingTranslations(LocalizationRepositoryContract $localization_repo): void;", "function i18n() {\n // Translations can be filed in the /languages/ directory\n load_theme_textdomain('mo_theme', get_template_directory() . '/languages');\n\n $locale = get_locale();\n $locale_file = get_template_directory() . \"/languages/$locale.php\";\n if (is_readable($locale_file))\n require_once($locale_file);\n\n }", "public static function load()\r\n\t\t{\r\n\t\t\tif (self::$_loaded) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\t$base_dir = self::get_latest_version_dir();\r\n\t\t\tload_textdomain('icf', $base_dir . '/languages/icf-' . get_locale() . '.mo');\r\n\r\n\t\t\tif ($dh = opendir($base_dir)) {\r\n\t\t\t\twhile (false !== ($file = readdir($dh))) {\r\n\t\t\t\t\tif ($file === '.' || $file === '..' || $file[0] === '.' || strrpos($file, '.php') === false) {\r\n\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t$filepath = $base_dir . '/' . $file;\r\n\r\n\t\t\t\t\tif (is_readable($filepath) && include_once $filepath) {\r\n\t\t\t\t\t\tself::$_loaded_files[] = $filepath;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tclosedir($dh);\r\n\t\t\t}\r\n\r\n\t\t\tdo_action('icf_loaded', self::$_loaded_files);\r\n\r\n\t\t\tself::$_loaded = true;\r\n\t\t}", "protected function loadFile($resource)\n {\n return file_get_contents($resource);\n }", "public function get($key, $bundle = '', $locale = ''){\r\n\r\n\t\t// We copy the locales array to prevent it from being altered by this method\r\n\t\t$localesArray = $this->locales;\r\n\r\n\t\t// Locales must be an array\r\n\t\tif(!is_array($localesArray)){\r\n\r\n\t\t\tthrow new Exception('LocalesManager->get: locales property must be an array');\r\n\t\t}\r\n\r\n\t\t// Paths verifications\r\n\t\tif(!is_array($this->paths)){\r\n\r\n\t\t\tthrow new Exception('LocalesManager->get: paths property must be an array');\r\n\t\t}\r\n\r\n\t\tif(!is_array($this->pathStructure)){\r\n\r\n\t\t\tthrow new Exception('LocalesManager->get: pathStructure property must be an array');\r\n\t\t}\r\n\r\n\t\tif(count($this->pathStructure) > count($this->paths)){\r\n\r\n\t\t\tthrow new Exception('LocalesManager->get: pathStructure cannot have more elements than paths');\r\n\t\t}\r\n\r\n\t\t// Check if we need to load the last used bundle\r\n\t\tif($bundle == ''){\r\n\r\n\t\t\t$bundle = $this->_lastBundle;\r\n\t\t}\r\n\r\n\t\tif($bundle == ''){\r\n\r\n\t\t\tthrow new Exception('LocalesManager->get: No resource bundle specified');\r\n\t\t}\r\n\r\n\t\t// Store the specified bundle name as the last that's been used till now\r\n\t\t$this->_lastBundle = $bundle;\r\n\r\n\t\t// Add the specified locale at the start of the list of locales\r\n\t\tif($locale != ''){\r\n\r\n\t\t\tarray_unshift($localesArray, $locale);\r\n\t\t}\r\n\r\n\t\t// Loop all the locales to find the first one with a value for the specified key\r\n\t\tforeach ($localesArray as $locale) {\r\n\r\n\t\t\t// Check if we need to load the bundle from disk\r\n\t\t\tif(!isset($this->_loadedData[$bundle][$locale])){\r\n\r\n\t\t\t\t$this->_loadBundle($bundle, $locale);\r\n\t\t\t}\r\n\r\n\t\t\tif(isset($this->_loadedData[$bundle][$locale][$key])){\r\n\r\n\t\t\t\treturn $this->_loadedData[$bundle][$locale][$key];\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tthrow new Exception('LocalesManager->get: Specified key <'.$key.'> was not found on locales list: ['.implode(', ', $localesArray).']');\r\n\t}", "private static function loadLanguage($lang){\n\t\t$descriptions = array();\n\n\t\t$locale = 'locale/'.$lang.'.php';\n\t\trequire($locale);\n\n\t\treturn (object)$descriptions;\n\t}", "protected function sectionTranslations()\n {\n $found = []; // translations found in latte templates\n foreach (glob('template/*.latte') as $file) {\n $tempFileContents = file_get_contents($file);\n Assert::string($tempFileContents);\n preg_match_all('~\\{=(\"([^\"]+)\"|\\'([^\\']+)\\')\\|translate\\}~i', $tempFileContents, $matches);\n $found = array_merge($found, $matches[2]);\n }\n $found = array_unique($found);\n $output = '<h1><i class=\"fa fa-globe\"></i> ' . $this->tableAdmin->translate('Translations')\n . '</h1><div id=\"agenda-translations\">'\n . '<form action=\"\" method=\"post\" onsubmit=\"return confirm(\\''\n . $this->tableAdmin->translate('Are you sure?') . '\\')\">'\n . Tools::htmlInput('translations', '', 1, array('type' => 'hidden'))\n . Tools::htmlInput('token', '', end($_SESSION['token']), 'hidden')\n . Tools::htmlInput('old_name', '', '', array('type' => 'hidden', 'id' => 'old_name'))\n . '<table class=\"table table-striped\"><thead><tr><th style=\"width:'\n . intval(100 / (count($this->MyCMS->TRANSLATIONS) + 1)) . '%\">'\n . Tools::htmlInput('one', '', false, 'radio') . '</th>';\n $translations = $keys = [];\n $localisation = new L10n($this->prefixUiL10n, $this->MyCMS->TRANSLATIONS);\n foreach ($this->MyCMS->TRANSLATIONS as $key => $value) {\n $output .= \"<th>$value</th>\";\n $translations[$key] = $localisation->readLocalisation($key);\n $keys = array_merge($keys, array_keys($translations[$key]));\n }\n $output .= '</tr></thead><tbody>' . PHP_EOL;\n $keys = array_unique($keys);\n natcasesort($keys);\n foreach ($keys as $key) {\n $output .= '<tr><th>'\n . Tools::htmlInput('one', '', $key, array('type' => 'radio', 'class' => 'translation')) . ' '\n . Tools::h((string) $key) . '</th>';\n foreach ($this->MyCMS->TRANSLATIONS as $code => $value) {\n $output .= '<td>' . Tools::htmlInput(\n \"tr[$code][$key]\",\n '',\n Tools::set($translations[$code][$key], ''),\n ['class' => 'form-control form-control-sm', 'title' => \"$code: $key\"]\n ) . '</td>';\n }\n $output .= '</tr>' . PHP_EOL;\n if ($key = array_search($key, $found)) {\n unset($found[$key]);\n }\n }\n $output .= '<tr><td>' . Tools::htmlInput(\n 'new[0]',\n '',\n '',\n array('class' => 'form-control form-control-sm', 'title' => $this->tableAdmin->translate('New record'))\n ) . '</td>';\n foreach ($this->MyCMS->TRANSLATIONS as $key => $value) {\n $output .= '<td>' . Tools::htmlInput(\n \"new[$key]\",\n '',\n '',\n ['class' => 'form-control form-control-sm',\n 'title' => $this->tableAdmin->translate('New record') . ' (' . $value . ')']\n ) . '</td>';\n }\n $output .= '</tr></tbody></table>\n <button name=\"translations\" type=\"submit\" class=\"btn btn-secondary\"><i class=\"fa fa-save\"></i> '\n . $this->tableAdmin->translate('Save') . '</button>\n <button name=\"delete\" type=\"submit\" class=\"btn btn-secondary\" value=\"1\"><i class=\"fa fa-dot-circle\"></i>\n <i class=\"fa fa-trash\"></i> ' . $this->tableAdmin->translate('Delete') . '</button>\n <fieldset class=\"d-inline-block position-relative\"><div class=\"input-group\" id=\"rename-fieldset\">'\n . '<div class=\"input-group-prepend\">\n <button class=\"btn btn-secondary\" type=\"submit\"><i class=\"fa fa-dot-circle\"></i> '\n . '<i class=\"fa fa-i-cursor\"></i> ' . $this->tableAdmin->translate('Rename') . '</button>\n </div>'\n . Tools::htmlInput('new_name', '', '', array('class' => 'form-control', 'id' => 'new_name'))\n . '</div></fieldset>\n </form></div>' . PHP_EOL;\n $output .= count($found) ? '<h2 class=\"mt-4\">' .\n $this->tableAdmin->translate('Missing translations in templates') . '</h2><ul>' : '';\n foreach ($found as $value) {\n $output .= '<li><code>' . Tools::h($value) . '</code></li>' . PHP_EOL;\n }\n $output .= count($found) ? '</ul>' : '';\n return $output;\n }", "function loadMultiLingualText($language) {\n $this->Stelle->language=$language;\n $this->Stelle->getName();\n include(LAYOUTPATH.'languages/'.$this->user->rolle->language.'.php');\n }", "public function setup_i18n() {\n\t\tload_plugin_textdomain( 'woocommerce-bundle-rate-shipping', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n\t}", "public function translate($path) {\n return Locale::get($path);\n }", "function translation() {\n\t\t\n\t\t// only use, if we have it...\n\t\tif( function_exists('load_plugin_textdomain') ) {\n\t\t\n\t\t\t// load it\n\t\t\tload_plugin_textdomain( \n\t\t\t\n\t\t\t\t// unique name\n\t\t\t\t'cp-multisite', \n\t\t\t\t\n\t\t\t\t// deprecated argument\n\t\t\t\tfalse,\n\t\t\t\t\n\t\t\t\t// path to directory containing translation files\n\t\t\t\tplugin_dir_path( CPMU_PLUGIN_FILE ) . 'languages/'\n\t\t\t\t\n\t\t\t);\n\t\t\t\n\t\t}\n\t\t\n\t}", "function yourls_load_textdomain( $domain, $mofile ) {\n\tglobal $yourls_l10n;\n\n\t$plugin_override = yourls_apply_filter( 'override_load_textdomain', false, $domain, $mofile );\n\n\tif ( true == $plugin_override ) {\n\t\treturn true;\n\t}\n\n\tyourls_do_action( 'load_textdomain', $domain, $mofile );\n\n\t$mofile = yourls_apply_filter( 'load_textdomain_mofile', $mofile, $domain );\n\n\tif ( !is_readable( $mofile ) ) {\n trigger_error( 'Cannot read file ' . str_replace( YOURLS_ABSPATH.'/', '', $mofile ) . '.'\n . ' Make sure there is a language file installed. More info: http://yourls.org/translations' );\n return false;\n }\n\n\t$mo = new MO();\n\tif ( !$mo->import_from_file( $mofile ) )\n return false;\n\n\tif ( isset( $yourls_l10n[$domain] ) )\n\t\t$mo->merge_with( $yourls_l10n[$domain] );\n\n\t$yourls_l10n[$domain] = &$mo;\n\n\treturn true;\n}", "function load_script_translations($file, $handle, $domain)\n {\n }", "abstract public function getTranslationIn(string $locale);", "abstract public function getTranslationIn(string $locale);", "abstract public function getTranslationIn(string $locale);", "public function load_textdomain() {\n\t\t// Set filter for plugin's languages directory\n\t\t$lang_dir = dirname( plugin_basename( __FILE__ ) ) . '/languages/';\n\t\t$lang_dir = apply_filters( 'bbp_notices_languages', $lang_dir );\n\n\t\t// Traditional WordPress plugin locale filter\n\t\t$locale = apply_filters( 'plugin_locale', get_locale(), 'bbpress-notices' );\n\t\t$mofile = sprintf( '%1$s-%2$s.mo', 'bbpress-notices', $locale );\n\n\t\t// Setup paths to current locale file\n\t\t$mofile_local = $lang_dir . $mofile;\n\t\t$mofile_global = WP_LANG_DIR . '/bbpress-notices/' . $mofile;\n\n\t\tif ( file_exists( $mofile_global ) ) {\n\t\t\t// Look in global /wp-content/languages/bbpress-notices folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_global );\n\t\t} elseif ( file_exists( $mofile_local ) ) {\n\t\t\t// Look in local /wp-content/plugins/bbpress-notices/languages/ folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_local );\n\t\t} else {\n\t\t\t// Load the default language files\n\t\t\tload_plugin_textdomain( 'bbpress-notices', false, $lang_dir );\n\t\t}\n\t}", "function load_textdomain($domain, $mofile, $locale = \\null)\n {\n }" ]
[ "0.6667522", "0.6543906", "0.6349443", "0.6121001", "0.6104452", "0.6060815", "0.6040956", "0.600702", "0.5972132", "0.5957592", "0.58738506", "0.58512557", "0.5829094", "0.5825303", "0.57492304", "0.57429975", "0.57082295", "0.5693462", "0.56790996", "0.56370294", "0.5630756", "0.5595362", "0.54940397", "0.5493763", "0.547564", "0.5465743", "0.54565567", "0.54545367", "0.5418845", "0.54023963", "0.5384843", "0.53822255", "0.53774923", "0.53760266", "0.5367533", "0.5358682", "0.5352111", "0.5334406", "0.52936643", "0.52911186", "0.52829474", "0.5272847", "0.5266626", "0.5261166", "0.5254345", "0.5245602", "0.5235214", "0.5234616", "0.5223454", "0.5222496", "0.5215608", "0.5200712", "0.5194838", "0.5189901", "0.5183646", "0.5177421", "0.5174458", "0.51433414", "0.513696", "0.5133208", "0.5106188", "0.51053107", "0.5104608", "0.5100399", "0.5086997", "0.5064096", "0.5061203", "0.5056695", "0.5032312", "0.50298727", "0.50191665", "0.5017272", "0.5016879", "0.5012422", "0.50072926", "0.5006422", "0.49999687", "0.49939835", "0.4993925", "0.49790668", "0.4977761", "0.49717045", "0.49671328", "0.49598703", "0.4956179", "0.49441046", "0.49441016", "0.4942523", "0.4941853", "0.49388278", "0.49377784", "0.4934176", "0.49222887", "0.49204513", "0.4917192", "0.49105483", "0.49105483", "0.49105483", "0.49072284", "0.4904744" ]
0.52952635
38
Actual health check logic.
protected function doHealthCheck(HealthBuilder $builder) { try { $version = $this->memcacheInstance->getversion(); } catch (\Exception $e) { $builder->down($e); return; } if ((is_bool($version) && $version === false) || ((is_array($version) && count($version) === 0)) ) { $builder->down(); return; } $builder->up()->withDetail('version', $version); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected abstract function doHealthcheck();", "public function health(): HealthCheck;", "public function health(): bool {\n $_status = $this->fetch([\n 'fetch' => 'Status',\n 'route' => \"/health\",\n ]);\n switch($_status['http_code']) {\n case '200':\n return true;\n case '503':\n return false;\n default:\n throw new \\Exception(\"/health Unexpected response code '{$_status['http_code']}'\");\n }\n }", "public function healthCheckAction()\n {\n return $this->healthCheckResponseFactory->getHealthCheckResponse(\n $this->healthCheckExecutorService->runAll(\n $this->healthCheckRegistry->getAllHealthChecks()\n )\n );\n }", "public function healthcheck()\n {\n list($version,) = $this->getFromVersion();\n return $this->doHealthcheck();\n }", "function health_check()\n {\n $zombies = $this->scheduled_task_model->get_zombies();\n\n if ( $zombies )\n {\n foreach ( $zombies as $zombie )\n {\n $data = array(\n 'type' => config( 'emergency_types' )->scheduled_task,\n 'info' => \"Task: \". $zombie->name,\n 'message' => \"Scheduled task has been running for too long. Check the server \".\n \"and cron log for any errors. It's been moved to active for now.\" );\n\n log_message(\n 'error',\n \"Health Check Failed: \". print_r( $data, TRUE ) );\n\n $data = array(\n 'state' => 'active' );\n\n $this->scheduled_task_model->save( $data, $zombie->id );\n }\n }\n\n return TRUE;\n }", "public function performChecks(){\n\t\t\n\t}", "function wp_dashboard_site_health()\n {\n }", "function HealthCheckCLI()\n\t{\n\t\treturn $this->HealthCheck(true);\n\t}", "public function testHealthPath() {\n $request = Request::create('/health');\n $bad_request = Request::create('/user');\n\n $plugin = new HealthCheck();\n static::assertTrue(\n $plugin->match($request),\n '/health path triggers plugin'\n );\n\n static::assertFalse(\n $plugin->match($bad_request),\n 'non /user path does not trigger plugin.'\n );\n\n $exception = new SuccessHTTPException('Everything is awesome');\n $this->expectExceptionObject($exception);\n $plugin->run($request, 'path', 'path');\n }", "public function health()\n {\n $response = SubstrateBase::APIHandler('system_'.__FUNCTION__);\n $this->_health = $response['result'];\n return response()->json($this->_health);\n }", "public function check() {}", "public function isHealthy()\n {\n return $this->healthy;\n }", "private function site_status_check() {\n\t\t$this->level = 4;\n\t\tEE::log( 'Checking and verifying site-up status. This may take some time.' );\n\t\t$httpcode = '000';\n\t\t$ch = curl_init( $this->site_name );\n\t\tcurl_setopt( $ch, CURLOPT_HEADER, true );\n\t\tcurl_setopt( $ch, CURLOPT_NOBODY, true );\n\t\tcurl_setopt( $ch, CURLOPT_RETURNTRANSFER, 1 );\n\t\tcurl_setopt( $ch, CURLOPT_TIMEOUT, 10 );\n\n\t\t$i = 0;\n\t\ttry {\n\t\t\twhile ( 200 !== $httpcode && 302 !== $httpcode ) {\n\t\t\t\tcurl_exec( $ch );\n\t\t\t\t$httpcode = curl_getinfo( $ch, CURLINFO_HTTP_CODE );\n\t\t\t\techo '.';\n\t\t\t\tsleep( 2 );\n\t\t\t\tif ( $i ++ > 60 ) {\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( 200 !== $httpcode && 302 !== $httpcode ) {\n\t\t\t\tthrow new Exception( 'Problem connecting to site!' );\n\t\t\t}\n\t\t}\n\t\tcatch ( Exception $e ) {\n\t\t\t$this->catch_clean( $e );\n\t\t}\n\n\t}", "public function check()\n\t{\n $response = $this->app->check();\n $this->printJSON($response);\n }", "private function verifyHealthCheck(): bool\n {\n $service = $this->httpService;\n\n // Verify that the service is up.\n $tries = 0;\n $maxTries = $this->config->getHealthCheckTimeout();\n $retrySec = $this->config->getHealthCheckRetrySec();\n do {\n ++$tries;\n\n try {\n return $service->healthCheck();\n } catch (ConnectionException $e) {\n \\usleep(intval(round($retrySec * 1000000)));\n }\n } while ($tries <= $maxTries);\n\n throw new HealthCheckFailedException(\"Failed to make connection to Mock Server in {$maxTries} attempts.\");\n }", "public function performCheck()\n {\n try {\n if (!$this->getClient()->ping()) {\n throw ElasticsearchPingCheckException::pingFailed(\n $this->getClient()->transport->lastConnection->getHost()\n );\n }\n } catch (Exception $e) {\n if (!$e instanceof ElasticsearchException) {\n throw $e;\n }\n throw ElasticsearchPingCheckException::internalGetProblem($e);\n }\n }", "public function _check()\n {\n }", "public function getHealthChecks(): Collection\n {\n return $this->healthChecks;\n }", "public function check()\n {\n }", "public function check()\n {\n }", "private function manageStatus()\n {\n $this->updateStatus();\n $this->checkStatus();\n }", "public function isHealthy(): bool\n {\n foreach ($this->getHealthChecks() as $healthCheck) {\n $checkResult = $this->check($healthCheck);\n\n if ($checkResult instanceof HealthCheckFailure) {\n $this->healthCheckFailure = $checkResult;\n\n return false;\n }\n }\n\n return true;\n }", "public function check(): void\n {\n $headers = Helper::getHeaders();\n $hash = $headers['m-hash'] ?? null;\n $version = $headers['m-version'] ?? null;\n $time = $headers['m-time'] ?? null;\n $random = $headers['m-random'] ?? null;\n L::d('M-HASH: ' . $hash);\n L::d('M-VERSION: ' . $version);\n L::d('M-TIME: ' . $time);\n L::d('M-RANDOM: ' . $random);\n\n \\Mirage\\Libs\\RequestHash::setKey(Config::get('app.security.'));\n \\App\\Libs\\Hash::check($hash, $version, $time, $random);\n }", "private function init_checks() {\n\t\tif ( 'running' !== $this->docker::container_status( $this->proxy_type ) ) {\n\t\t\t/**\n\t\t\t * Checking ports.\n\t\t\t */\n\t\t\t@fsockopen( 'localhost', 80, $port_80_exit_status );\n\t\t\t@fsockopen( 'localhost', 443, $port_443_exit_status );\n\n\t\t\t// if any/both the port/s is/are occupied.\n\t\t\tif ( ! ( $port_80_exit_status && $port_443_exit_status ) ) {\n\t\t\t\tEE::error( 'Cannot create/start proxy container. Please make sure port 80 and 443 are free.' );\n\t\t\t} else {\n\n\t\t\t\tif ( ! is_dir( EE_CONF_ROOT . '/traefik' ) ) {\n\t\t\t\t\tEE::debug( 'Creating traefik folder and config files.' );\n\t\t\t\t\tmkdir( EE_CONF_ROOT . '/traefik' );\n\t\t\t\t}\n\n\t\t\t\ttouch( EE_CONF_ROOT . '/traefik/acme.json' );\n\t\t\t\tchmod( EE_CONF_ROOT . '/traefik/acme.json', 600 );\n\t\t\t\t$traefik_toml = new Site_Docker();\n\t\t\t\tfile_put_contents( EE_CONF_ROOT . '/traefik/traefik.toml', $traefik_toml->generate_traefik_toml() );\n\n\t\t\t\t$ee_traefik_command = 'docker run -d -p 8080:8080 -p 80:80 -p 443:443 -l \"traefik.enable=false\" -l \"created_by=EasyEngine\" -v /var/run/docker.sock:/var/run/docker.sock -v ' . EE_CONF_ROOT . '/traefik/traefik.toml:/etc/traefik/traefik.toml -v ' . EE_CONF_ROOT . '/traefik/acme.json:/etc/traefik/acme.json -v ' . EE_CONF_ROOT . '/traefik/endpoints:/etc/traefik/endpoints -v ' . EE_CONF_ROOT . '/traefik/certs:/etc/traefik/certs -v ' . EE_CONF_ROOT . '/traefik/log:/var/log --name ee_traefik easyengine/traefik';\n\n\t\t\t\tif ( $this->docker::boot_container( $this->proxy_type, $ee_traefik_command ) ) {\n\t\t\t\t\tEE::success( \"$this->proxy_type container is up.\" );\n\t\t\t\t} else {\n\t\t\t\t\tEE::error( \"There was some error in starting $this->proxy_type container. Please check logs.\" );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t$this->site_root = WEBROOT . $this->site_name;\n\t\t$this->create_site_root();\n\t}", "public function index_returns_an_ok_response(): void\n {\n $user = $this->createUserWithPermission('show-admin-menu');\n\n $response = $this->actingAs($user)->get(route('admin.health.index'));\n\n $response->assertOk();\n $response->assertViewIs('health.index');\n $response->assertViewHas('results');\n $response->assertSeeText('Database Health Checks');\n }", "public function health()\n\t\t{\n\t\t\t$sum = 0;\n\t\t\t$average = 0;\n\t\t\tforeach ($this->_members as $body) {\n\t\t\t\tif($body->_alive)\n\t\t\t\t{\n\t\t\t\t\t$sum += $body->_health;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ($this->_livingMembers != 0)\n\t\t\t{\n\t\t\t\t$average = $sum / $this->_livingMembers;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$average = 0;\n\t\t\t}\n\n\n\t\t\tif($average <= 0)\n\t\t\t{\n\t\t\t\t$this->_health = \"Game Over\";\n\t\t\t}\n\t\t\telse if($average >= 75)\n\t\t\t{\n\t\t\t\t$this->_health = \"Good\";\n\t\t\t}\n\t\t\telse if($average > 50)\n\t\t\t{\n\t\t\t\t$this->_health = \"Fair\";\n\t\t\t}\n\t\t\telse if($average > 25)\n\t\t\t{\n\t\t\t\t$this->_health = \"Poor\";\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$this->_health = \"Bad\";\n\t\t\t}\n\n\t\t}", "public function testComAdobeGraniteRequestsLoggingImplHcRequestsStatusHealthCheckIm()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.requests.logging.impl.hc.RequestsStatusHealthCheckImpl';\n\n $crawler = $client->request('POST', $path);\n }", "public function testComAdobeGraniteQueriesImplHcQueriesStatusHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.queries.impl.hc.QueriesStatusHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function health()\n {\n return $this->getHealth();\n }", "public function check();", "public function check();", "public function check();", "public function check();", "public function check();", "public function __construct($site_health)\n {\n }", "protected function status()\n {\n }", "function wp_ajax_health_check_site_status_result()\n {\n }", "public function hasHealthStatus() {\n return $this->_has(8);\n }", "public function __construct() {\n $base_class_name = 'SiteAuditCheck' . $this->getReportName();\n $percent_override = NULL;\n\n $checks_to_skip = array();\n if (drush_get_option('skip')) {\n $checks_to_skip = explode(',', drush_get_option('skip'));\n }\n\n $checks_to_perform = $this->getCheckNames();\n\n foreach ($checks_to_perform as $key => $check_name) {\n if (in_array($this->getReportName() . $check_name, $checks_to_skip)) {\n unset($checks_to_perform[$key]);\n }\n }\n\n if (empty($checks_to_perform)) {\n // No message for audit_all.\n $command = drush_parse_command();\n if ($command['command'] == 'audit_all') {\n return FALSE;\n }\n return drush_set_error('SITE_AUDIT_NO_CHECKS', dt('No checks are available!'));\n }\n $config = \\Drupal::config('site_audit');\n foreach ($checks_to_perform as $check_name) {\n $class_name = $base_class_name . $check_name;\n $opt_out = $config->get('opt_out.' . $this->getReportName() . $check_name) != NULL;\n $check = new $class_name($this->registry, $opt_out);\n\n // Calculate score.\n if ($check->getScore() != SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_INFO) {\n // Mark if there's a major failure.\n if ($check->getScore() == SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_FAIL) {\n $this->hasFail = TRUE;\n }\n // Total.\n $this->scoreTotal += $check->getScore();\n // Maximum.\n $this->scoreMax += SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_PASS;\n }\n // Allow Report percentage to be overridden.\n if ($check->getPercentOverride()) {\n $percent_override = $check->getPercentOverride();\n }\n // Combine registry.\n $this->registry = array_merge($this->registry, $check->getRegistry());\n // Store all checks.\n $this->checks[$class_name] = $check;\n // Abort the loop if the check says to bail.\n if ($check->shouldAbort()) {\n break;\n }\n }\n if ($percent_override) {\n $this->percent = $percent_override;\n }\n else {\n if ($this->scoreMax != 0) {\n $this->percent = round(($this->scoreTotal / $this->scoreMax) * 100);\n }\n else {\n $this->percent = SiteAuditCheckAbstract::AUDIT_CHECK_SCORE_INFO;\n }\n }\n }", "public function testOrgApacheSlingHcCoreImplScriptableHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/org.apache.sling.hc.core.impl.ScriptableHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function testGoodRegisteredControllerStatus()\n {\n $this->assertEquals(false, $this->getAndCheckForError('/dev/x1'));\n $this->assertEquals(false, $this->getAndCheckForError('/dev/x1/y1'));\n\n // Check response code is 500/ some sort of error\n $this->assertEquals(true, $this->getAndCheckForError('/dev/x2'));\n }", "private function checkStatus()\n {\n $res = $this->parseBoolean(\n json_encode($this->getStatus()[\"timed_out\"])\n );\n\n if ($this->getStatus() == null)\n $this->setOnline(false);\n else if ($res)\n $this->setOnline(false);\n else\n $this->setOnline(true);\n }", "public function testComAdobeGraniteRepositoryHcImplContentSlingSlingContentHealthC()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.repository.hc.impl.content.sling.SlingContentHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function testComAdobeGraniteReplicationHcImplReplicationTransportUsersHealthC()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.replication.hc.impl.ReplicationTransportUsersHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public static function health() {\n\t\t$https = strpos(network::getNetworkAccess('external'), 'https') !== false;\n\t\t$return[] = array(\n\t\t\t'test' => __('HTTPS', __FILE__),\n\t\t\t'result' => ($https) ? __('OK', __FILE__) : __('NOK', __FILE__),\n\t\t\t'advice' => ($https) ? '' : __('Votre Jeedom ne permet pas le fonctionnement de Telegram sans HTTPS', __FILE__),\n\t\t\t'state' => $https,\n\t\t);\n\t\treturn $return;\n\t}", "protected function doBaseTasks()\n {\n\n $this->showTestHeadline(\"Checking application base structure\");\n\n if (HSetting::Get('secret') == \"\" || HSetting::Get('secret') == null) {\n HSetting::Set('secret', UUID::v4());\n $this->showFix('Setting missing application secret!');\n }\n }", "abstract public function check();", "public function howAreYouDoing() \r\n {\r\n $health = $this->healthLevel;\r\n $status = '';\r\n switch (true) {\r\n case ($health >= 70):\r\n $status = \"Awesome\";\r\n break;\r\n case($health < 70 && $health >= 20):\r\n $status = \"Meh\";\r\n break;\r\n case ($health < 20 && $health > 0):\r\n $status = \"Bad\";\r\n break;\r\n case ($health <= 0):\r\n $status = \"El Muerto\";\r\n break;\r\n default:\r\n $status = \"Error\"; // In theory we should never get here\r\n break;\r\n }\r\n return $status;\r\n }", "private function score_current_health_status(){\r\n\t\t$data=$this->data['current_health_status'];\r\n\r\n\t\ttry {\r\n\t\t\t$q4=$this->scoreValue(array(5,4,3,2,1),$data['q4']);;\r\n\t\t}\r\n\t\tcatch (Exception $e) {\r\n\t\t\tthrow new Exception (\"current_health_status - \" . $e->message);\r\n\t\t}\r\n\r\n\t\t$q5=0;\r\n\t\tfor($x = 0; $x <= 15; $x++){\t\t\t\t\t\t\t\t//&&& not sure that this is correct.\r\n\t\t\tif($data[\"q5_\".$x] == 0) continue;\r\n\t\t\tif($data[\"q5_\".$x] == 1) continue;\r\n\t\t\t$q5++;\r\n\t\t}\r\n\t\tif ($q5 > 4) $q5=1;\r\n\t\telse if ($q5 == 4) $q5 = 2;\r\n\t\telse if ($q5 == 3) $q5 = 3;\r\n\t\telse if ($q5 == 2) $q5 = 4;\r\n\t\telse if ($q5 == 1) $q5 = 4;\r\n\t\telse if ($q5 == 0) $q5 = 5;\r\n\t\telse $q5 = 0;\r\n\r\n//\r\n// Note: these do not currently enter into the score (only the 1st two questions do)\r\n//\r\n//\t\t$q6=$this->scoreValue(array(1,5),$data['q6']);\r\n\t\t$q7=$this->scoreValue(array(5,1),$data['q7']);\t\t\t\t//Yes or No\r\n//\t\t$q8=$this->scoreValue(array(5,1,3),$data['q8']);\r\n\t\t$q9=$this->scoreValue(array(5,1),$data['q9']);\t\t\t\t//Yes or No\r\n\r\n\t\t$ob=new stdClass();\r\n\t\t$ob->total=0;\r\n\t\t$ob->data=array('q4'=>array($q4,.35),\r\n\t\t 'q5'=>array($q5,.65),\r\n\t\t 'q7'=>array($q7,0),\r\n\t\t 'q9'=>array($q9,0)\r\n\t\t );\r\n\t\tforeach($ob->data as &$rec){\r\n\t\t\t$rec[2]=$rec[0]*$rec[1];\r\n\t\t\t$ob->total+=$rec[2];\r\n\t\t}\r\n\r\n\t\treturn $ob;\r\n\t}", "public function check() : void {\n\t\tif ( ! $this->check_host() ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( $this->is_healthcheck() ) {\n\t\t\treturn;\n\t\t}\n\n\t\tif ( $this->is_cli() ) {\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ( $this->rules as $rule ) {\n\t\t\t$target = $rule->target();\n\t\t\t$pattern = $rule->pattern();\n\t\t\t$uri = $this->get_full_url();\n\n\t\t\tif (\n\t\t\t\t! @preg_match( \"/$pattern/\", $uri, $matches )\n\t\t\t\t&& ! @preg_match( \"/$pattern/\", $this->uri, $matches )\n\t\t\t) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif ( $rule->is_external_target() && ! $this->is_subdomain() ) {\n\t\t\t\t$uri = $this->uri;\n\t\t\t}\n\n\t\t\t$uri = ltrim( $uri, '/' );\n\n\t\t\tif ( $rule->is_regex_target() ) {\n\t\t\t\tunset( $matches[0] );\n\t\t\t\t$matches = array_values( $matches );\n\n\t\t\t\t$key = 0;\n\t\t\t\t$placeholders = array_map(\n\t\t\t\t\tfunction( $val ) use ( &$key ) {\n\t\t\t\t\t\t$key++;\n\t\t\t\t\t\treturn \"$$key\";\n\t\t\t\t\t},\n\t\t\t\t\t$matches\n\t\t\t\t);\n\n\t\t\t\t/**\n\t\t\t\t * Normally we might expect a preg_replace() here as we're working with\n\t\t\t\t * regex, however preg_replace() will not replace the entire subject an\n\t\t\t\t * will append the replacement to it rather than replace the subject with\n\t\t\t\t * our $target value with dollar placeholders. To get around this and keep\n\t\t\t\t * the $target as the full subject, we create an array of placeholders based\n\t\t\t\t * on the amount of matches and use a simple str_replace() to replace the $target\n\t\t\t\t * placeholders with the paired values from $placeholders and $matches.\n\t\t\t\t */\n\t\t\t\t$target = str_replace( $placeholders, $matches, $target );\n\t\t\t}\n\n\t\t\tif ( ! $rule->is_external_target() && ! $this->is_subdomain() ) {\n\t\t\t\t$target = ltrim( $target, '/' );\n\t\t\t\t$target = \"/$target\";\n\t\t\t}\n\n\t\t\theader( \"Location: $target\", $rule->code() );\n\t\t\texit;\n\t\t}\n\n\t\t$this->rules = []; // Reset to avoid potential large memory usage.\n\t}", "public function checkOperationality()\n {\n }", "abstract public function getStatus();", "function runCheck()\r\n\t{\r\n\t\t$this->reportWriter->startReport();\r\n\r\n\t\twhile($this->urlSource->hasNext())\r\n\t\t{\r\n\t\t\t//create the full URL from the host address and port number\r\n\t\t\t$request = $this->urlSource->getNext();\r\n\t\t\t$url = \"http://\".$this->host.\":\".$this->port;\r\n\t\t\tif ($this->dir!=\"\")\r\n\t\t\t\t$url = $url.\"/\".$this->dir.\"/\".$request;\r\n\t\t\telse\r\n\t\t\t\t$url = $url.\"/\".$request;\r\n\r\n\t\t\t$page = $this->fetchPage($url);\r\n\t\t\tif ($page[\"error\"])\r\n\t\t\t{\r\n\t\t\t\t//report an un-expected error\r\n\t\t\t\t$this->reportWriter->addItemMessage(false, $url, $page[\"error\"]);\r\n\t\t\t}\r\n\t\t\telse if ($page[\"headers\"][\"status_code\"]!=200)\r\n\t\t\t{\r\n\t\t\t\t//report an HTTP error\r\n\t\t\t\t$this->reportWriter->addItemMessage(false, $url, \"Page not loaded, error code: \".$page[\"headers\"][\"status_code\"]);\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t//report PHP page errors\r\n\t\t\t\t$errors = $this->checkForErrors($page[\"content\"]);\r\n\t\t\t\t$this->reportWriter->addItem($url, $errors);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$this->reportWriter->endReport();\r\n\t}", "protected function calculateStatus(): int\n {\n return 200;\n }", "private function set_current_health_status($arr){\r\n\t\t$qno = $this->getFirstQuestionNo('current_health_status');\r\n\t\t$err=null;\r\n\t\ttry{\r\n \t\t$v=$this->vc->exists('q4',$arr,\"enum\",array(\"values\"=>array(1,2,3,4,5)),false,false);\r\n \t\t$this->data['current_health_status']['q4']=($v==\"\")?0:$v;\r\n \t}catch(ValidationException $e){\r\n \t\t$eob=$e->createErrorObject();\r\n \t\t$eob->message = \"Please give your opinion of your overall health\";\r\n \t\t$eob->name = \"Question \" . $qno;\r\n \t\t$err[] = $eob;\r\n \t}\r\n\r\n\t\t\t$qno += 1;\r\n \tfor($x=0;$x<=15;$x++){\r\n \t\ttry{\r\n \t\t\t$v=$this->vc->exists('q5_'.$x,$arr,\"enum\",array(\"values\"=>array(1,2,3,4,5)),false,false);\r\n \t\t\t$this->data['current_health_status']['q5_'.$x]=($v==\"\")?0:$v;\r\n \t\t}catch(ValidationException $e){\r\n \t\t\t$eb=$e->createErrorObject();\r\n \t\t\t$eb->message = \"Be sure to select an answer for all conditions\";\r\n \t\t\t$eb->name = \"Question \" . $qno;\r\n \t\t}\r\n \t}\r\n \tif (isset($eb)) {\r\n \t\t$err[] = $eb;\r\n \t}\r\n/* \t\r\n\t\t\t$qno += 1;\r\n \ttry{\r\n \t\t$v=$this->vc->exists('q6',$arr,\"enum\",array(\"values\"=>array(1,2)),false,false);\r\n \t\t$this->data['current_health_status']['q6']=($v==\"\")?0:$v;\r\n \t}catch(ValidationException $e){\r\n \t\t$eob=$e->createErrorObject();\r\n \t\t$eob->message = \"Please answer if you have medical condition that requires you to use your medical benefits\";\r\n \t\t$eob->name = \"Question \" . $qno;\r\n \t}\r\n*/\r\n\t\t\t$qno += 1;\r\n \ttry{\r\n \t\t$v=$this->vc->exists('q7',$arr,\"enum\",array(\"values\"=>array(1,2)),false,false);\r\n \t\t$this->data['current_health_status']['q7']=($v==\"\")?0:$v;\r\n \t}catch(ValidationException $e){\r\n \t\t$eob=$e->createErrorObject();\r\n \t\t$eob->message = \"Please express if you understand your medical benefits\";\r\n \t\t$eob->name = \"Question \" . $qno;\r\n \t\t$err[] = $eob;\r\n \t}\r\n/*\r\n\t\t\t$qno += 1;\r\n \ttry{\r\n \t\t$v=$this->vc->exists('q8',$arr,\"enum\",array(\"values\"=>array(1,2,3)),false,false);\r\n \t\t$this->data['current_health_status']['q8']=($v==\"\")?0:$v;\r\n \t}catch(ValidationException $e){\r\n \t\t$eob=$e->createErrorObject();\r\n \t\t$eob->message = \"Please answer if you get a yearly physical examination\";\r\n \t\t$eob->name = \"Question \" . $qno;\r\n \t\t$err[] = $eob;\r\n \t}\r\n*/\r\n\t\t\t$qno += 1;\r\n \ttry{\r\n \t\t$v=$this->vc->exists('q9',$arr,\"enum\",array(\"values\"=>array(1,2)),false,false);\r\n \t\t$this->data['current_health_status']['q9']=($v==\"\")?0:$v;\r\n \t}catch(ValidationException $e){\r\n \t\t$eob=$e->createErrorObject();\r\n \t\t$eob->message = \"Please answer whether you can care for a minor injury\";\r\n \t\t$eob->name = \"Question \" . $qno;\r\n \t\t$err[] = $eob;\r\n \t} \t\r\n \treturn ($err)?$err:false; \t\r\n }", "public function test_site_state() {\n\t\tif ( ! method_exists( 'Health_Check_Loopback', 'can_perform_loopback' ) ) {\n\t\t\t$plugin_file = trailingslashit( WP_PLUGIN_DIR ) . 'health-check/includes/class-health-check-loopback.php';\n\n\t\t\t// Make sure the file exists, in case someone deleted the plugin manually, we don't want any errors.\n\t\t\tif ( ! file_exists( $plugin_file ) ) {\n\n\t\t\t\t// If the plugin files are inaccessible, we can't guarantee for the state of the site, so the default is a bad response.\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\trequire_once( $plugin_file );\n\t\t}\n\n\t\t$loopback_state = Health_Check_Loopback::can_perform_loopback();\n\n\t\tif ( 'good' !== $loopback_state->status ) {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t}", "public function reportStatus()\n {\n if ( ! $this->isRequiredConfigPresent()) {\n $this->reportError('Config problem', 1485984755);\n }\n\n if ( ! $this->isDatabaseOkay()) {\n $this->reportError('Database problem', 1485284407);\n }\n\n echo 'OK';\n }", "public function check(): void;", "public function check(): void;", "public function checkAction()\n {\n $result = $this->_checkBalance();\n $this->getResponse()->setBody($result);\n }", "public function main()\n\t{\n\t\t// Check permissions\n\t\t$this->checkPermissions();\n\n\t\t/** @var StatisticsModel $model */\n\t\t$model = $this->getModel('Statistics', 'Administrator');\n\t\t$result = $model->notifyFailed();\n\n\t\t$message = $result['result'] ? '200 ' : '500 ';\n\t\t$message .= implode(', ', $result['message']);\n\n\t\t@ob_end_clean();\n\t\theader('Content-type: text/plain');\n\t\theader('Connection: close');\n\t\techo $message;\n\t\tflush();\n\n\t\t$this->app->close();\n\t}", "public function testUserAgentPrometheus() {\n $request = Request::create('/any-path');\n $request->headers->set('User-Agent', HealthCheck::VAGOV_DOWNTIME_DETECT_USER_AGENT_PROMETHEUS);\n\n $bad_request = Request::createFromGlobals();\n\n $plugin = new HealthCheck();\n static::assertTrue(\n $plugin->match($request),\n 'prometheus user agent triggers plugin'\n );\n\n static::assertFalse(\n $plugin->match($bad_request),\n 'default request objects should not trigger the plugin.'\n );\n\n $exception = new SuccessHTTPException('Everything is awesome');\n $this->expectExceptionObject($exception);\n $plugin->run($request, 'path', 'path');\n }", "public function getHealth()\n {\n return $this->health;\n }", "public function getHealth()\n {\n return $this->health;\n }", "public function getHealth()\n {\n return $this->health;\n }", "abstract function check();", "protected function checkStatus()\n {\n $status = $this->autoTestController->checkStatus(Tools::getValue('queueItemId', 0));\n\n if ($status['finished']) {\n $this->autoTestController->stop(\n function () {\n return LoggerService::getInstance();\n }\n );\n }\n\n PacklinkPrestaShopUtility::dieJson($status);\n }", "public function getHealthy()\n {\n return isset($this->healthy) ? $this->healthy : false;\n }", "public function testCapsuleStatus()\n {\n\n $response = $this->call('GET','/api/capsules/C101');\n\n $this->assertEquals(200,$response->status());\n }", "public static function check()\n {\n parent::check();\n }", "public function ensureConsistency()\n {\n\n }", "public function ensureConsistency()\n {\n\n }", "public function testGetUserOK() {\n $handleNameOk = getenv('HANDLENAME_OK');\n $response = $this->runApp('GET', '/histogram/'.$handleNameOk);\n $this->assertEquals(200, $response->getStatusCode());\n $body = json_decode((string)$response->getBody(), true);\n $this->assertArrayHasKey('tweet per hour', $body);\n }", "protected function _checkStatus() {\n if ($this->analyticsEnabled === null) {\n $this->analyticsEnabled = Zend_Registry::get('config')->analytics->enabled; \n } \n if ($this->analyticsEnabled != 1) { \n throw new Exception(\"We're sorry, Analytics is disabled at the moment\");\n }\n }", "public function ping(){\n http_response_code(200);\n ob_end_flush();\n }", "abstract public function handleAlerts($thresholds);", "abstract public function GetStatus();", "private function checkHealth(){\n\n if(strpos($_SERVER['SERVER_SOFTWARE'], 'Apache')===FALSE)\n $this->apache = false;\n\n if(function_exists('apache_get_modules')){\n $mods = apache_get_modules();\n if(!in_array('mod_rewrite', $mods))\n $this->rewrite = false;\n }\n\n if(!$this->apache || !$this->rewrite){\n showMessage(__('URL rewriting requires an Apache Server and mod_rewrite enabled!','dtransport'), RMMSG_WARN);\n return false;\n }\n\n if(!preg_match(\"/RewriteEngine\\s{1,}On/\", $this->content))\n $this->content .= \"\\nRewriteEngine On\\n\";\n\n $base = parse_url(XOOPS_URL.'/');\n $this->base = isset($base['path']) ? rtrim($base['path'], '/').'/' : '/';\n $rb = \"RewriteBase \".$this->base.\"\\n\";\n\n if(strpos($this->content, $rb)===false){\n if(preg_match(\"/RewriteBase/\", $this->content))\n preg_replace(\"/RewriteBase\\s{1,}(.*)\\n\",$rb, $this->content);\n else\n $this->content .= $rb.\"\\n\";\n }\n\n if(!preg_match(\"/RewriteCond\\s{1,}\\%\\{REQUEST_URI\\}\\s{1,}\\!\\/\\[A\\-Z\\]\\+\\-/\", $this->content))\n $this->content .= \"RewriteCond %{REQUEST_URI} !/[A-Z]+-\\n\";\n\n if(!preg_match(\"/RewriteCond\\s{1,}\\%\\{REQUEST_FILENAME\\}\\s{1,}\\!\\-f/\", $this->content))\n $this->content .= \"RewriteCond %{REQUEST_FILENAME} !-f\\n\";\n\n if(!preg_match(\"/RewriteCond\\s{1,}\\%\\{REQUEST_FILENAME\\}\\s{1,}\\!\\-d/\", $this->content))\n $this->content .= \"RewriteCond %{REQUEST_FILENAME} !-d\\n\";\n\n\n\n }", "public function heartbeat()\n {\n $this->output(\"[\" . date(\"Y-m-d H:i:s\") . \"]\" . \" Sending heartbeat...\");\n $response = $this->client->put('/eureka/apps/' . $this->config->getAppName() . '/' . $this->config->getInstanceId());\n if ($response->getStatusCode() != 200) {\n if (404 === $response->getStatusCode()) {\n $this->register();\n } else {\n throw new HeartbeatFailureException(\" Heartbeat failed... (code: \" . $response->getStatusCode() . \")\");\n }\n }\n }", "public function testOrgApacheSlingHcCoreImplCompositeHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/org.apache.sling.hc.core.impl.CompositeHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "public function ping()\n {\n }", "private function callStatus() {\n try {\n $this->status = $this->client->request('GET', $this->url->full_url, [\n 'allow_redirects' => false\n ]);\n } catch (\\Exception $ex) {\n $this->status = $ex->getResponse();\n }\n }", "public function testNpcsAlwaysHaveHealth()\n {\n $npcs = NpcFactory::npcs();\n\n foreach ($npcs as $npc) {\n $this->assertGreaterThan(0, $npc->getHealth(), 'For npc: ['.$npc->identity().']');\n }\n }", "public function testComAdobeCqSecurityHcWebserverImplClickjackingHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.cq.security.hc.webserver.impl.ClickjackingHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "protected function getSelfStatus() {}", "protected function getSelfStatus() {}", "public function getHealth()\n {\n if(!$this->checkConnection()){\n return false;\n }\n\n if(!$this->login()){\n return false;\n }\n\n if(!$this->getServerObjects()){\n return false;\n }\n $url = 'https://' . trim($this->ip) . ':8080/health?sid=' . trim($this->sid);\n\n $responseJson_str = file_get_contents($url, null, $this->stream_context);\n $comment_position = strripos($responseJson_str, '/*'); //отрезаем комментарий в конце ответа сервера\n $responseJson_str = substr($responseJson_str, 0, $comment_position);\n $server_health = json_decode($responseJson_str, true);\n\n $channelsHealth = [];\n $result = $server_health;\n if (!empty($this->channels)) {\n foreach ($this->channels as $channel) {\n $url = 'https://' . trim($this->ip) . ':8080/settings/channels/' . $channel['guid'] . '/flags/signal?sid=' . trim($this->sid); //получения статуса канала\n $responseJson_str = file_get_contents($url, NULL, $this->stream_context);\n $comment_position = strripos($responseJson_str, '/*'); //отрезаем комментарий в конце ответа сервера\n $responseJson_str = substr($responseJson_str, 0, $comment_position);\n $channelHealth = json_decode($responseJson_str, true);\n\n $channelsHealth[] = [\n 'name' => $channel['name'],\n 'guid' => $channel['guid'],\n 'signal' => $channelHealth['value']\n ];\n }\n if (isset($channelsHealth) && !empty($channelsHealth) && is_array($channelsHealth)) {\n //$result = array_merge($server_health, $channelsHealth);\n $result['channels_health']=$channelsHealth;\n }\n }\n\n return $result;\n }", "public function sanityCheck()\n {\n $request = new Request;\n $request->setUrl(\"sanityCheck\");\n $request->setMethod(\"POST\");\n $this->populateMetadata($request);\n $response = $this->send($request);\n return $response->getRawResponse()->code === 200;\n }", "public function healthCheck(): array\n {\n if ( !empty( $this->healthCheckErrors ) ) {\n return $this->healthCheckErrors;\n }\n foreach ( $this->doHealthCheck() as $key => $error ) {\n $return[$key] = [\n 'content' => $error,\n 'class' => 'danger'\n ];\n }\n return $this->healthCheckErrors = $return ?? [];\n }", "public function testComAdobeGraniteBundlesHcImplWebDavBundleHealthCheck()\n {\n $client = static::createClient();\n\n $path = '/system/console/configMgr/com.adobe.granite.bundles.hc.impl.WebDavBundleHealthCheck';\n\n $crawler = $client->request('POST', $path);\n }", "function HealthCheck($cli=false)\n\t{\n\t\t$saveE = $this->conn->fnExecute;\n\t\t$this->conn->fnExecute = false;\n\t\tif ($cli) $html = '';\n\t\telse $html = $this->table.'<tr><td colspan=3><h3>'.$this->conn->databaseType.'</h3></td></tr>'.$this->titles;\n\n\t\t$oldc = false;\n\t\t$bgc = '';\n\t\tforeach($this->settings as $name => $arr) {\n\t\t\tif ($arr === false) break;\n\n\t\t\tif (!is_string($name)) {\n\t\t\t\tif ($cli) $html .= \" -- $arr -- \\n\";\n\t\t\t\telse $html .= \"<tr bgcolor=$this->color><td colspan=3><i>$arr</i> &nbsp;</td></tr>\";\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif (!is_array($arr)) break;\n\t\t\t$category = $arr[0];\n\t\t\t$how = $arr[1];\n\t\t\tif (sizeof($arr)>2) $desc = $arr[2];\n\t\t\telse $desc = ' &nbsp; ';\n\n\n\t\t\tif ($category == 'HIDE') continue;\n\n\t\t\t$val = $this->_DBParameter($how);\n\n\t\t\tif ($desc && strncmp($desc,\"=\",1) === 0) {\n\t\t\t\t$fn = substr($desc,1);\n\t\t\t\t$desc = $this->$fn($val);\n\t\t\t}\n\n\t\t\tif ($val === false) {\n\t\t\t\t$m = $this->conn->ErrorMsg();\n\t\t\t\t$val = \"Error: $m\";\n\t\t\t} else {\n\t\t\t\tif (is_numeric($val) && $val >= 256*1024) {\n\t\t\t\t\tif ($val % (1024*1024) == 0) {\n\t\t\t\t\t\t$val /= (1024*1024);\n\t\t\t\t\t\t$val .= 'M';\n\t\t\t\t\t} else if ($val % 1024 == 0) {\n\t\t\t\t\t\t$val /= 1024;\n\t\t\t\t\t\t$val .= 'K';\n\t\t\t\t\t}\n\t\t\t\t\t//$val = htmlspecialchars($val);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($category != $oldc) {\n\t\t\t\t$oldc = $category;\n\t\t\t\t//$bgc = ($bgc == ' bgcolor='.$this->color) ? ' bgcolor=white' : ' bgcolor='.$this->color;\n\t\t\t}\n\t\t\tif (strlen($desc)==0) $desc = '&nbsp;';\n\t\t\tif (strlen($val)==0) $val = '&nbsp;';\n\t\t\tif ($cli) {\n\t\t\t\t$html .= str_replace('&nbsp;','',sprintf($this->cliFormat,strip_tags($name),strip_tags($val),strip_tags($desc)));\n\n\t\t\t}else {\n\t\t\t\t$html .= \"<tr$bgc><td>\".$name.'</td><td>'.$val.'</td><td>'.$desc.\"</td></tr>\\n\";\n\t\t\t}\n\t\t}\n\n\t\tif (!$cli) $html .= \"</table>\\n\";\n\t\t$this->conn->fnExecute = $saveE;\n\n\t\treturn $html;\n\t}", "public function isAlive()\n {\n return $this->health > 0;\n }", "public function testBuildHealthCheck()\n {\n $config = new SinglePayConfig();\n $config->setServiceConfig(self::$testConfig);\n\n $healthCheck = ExpressFactory::buildHealthCheck($config);\n $this->assertInstanceOf('\\SinglePay\\PaymentService\\Element\\Express\\Method\\HealthCheck', $healthCheck);\n }", "public function ensureConsistency()\n {\n }", "public function ensureConsistency()\n {\n }", "public function ensureConsistency()\n {\n }", "public function ensureConsistency()\n {\n }", "public function ensureConsistency()\n {\n }", "private function check_conf() {\n ConfigChecker::check();\n }", "public function run()\n {\n printf(\"Adding hauling configuration.\\r\\n\");\n\n if(HaulingConfig::where(['load_size' => 'small'])->count() == 0) {\n HaulingConfig::insert([\n 'load_size' => 'small',\n 'min_load_size' => 0,\n 'max_load_size' => 8000,\n 'price_per_jump' => 600000.00,\n ]);\n }\n \n if(HaulingConfig::where(['load_size' => 'medium'])->count() == 0) {\n HaulingConfig::insert([\n 'load_size' => 'medium',\n 'min_load_size' => 8000,\n 'max_load_size' => 57500,\n 'price_per_jump' => 800000.00,\n ]);\n }\n\n if(HaulingConfig::where(['load_size' => 'large'])->count() == 0) {\n HaulingConfig::insert([\n 'load_size' => 'large',\n 'min_load_size' => 57500,\n 'max_load_size' => 800000,\n 'price_per_jump' => 1000000.00,\n ]);\n }\n\n printf(\"Finished adding hauling configuration.\\r\\n\");\n }" ]
[ "0.8885773", "0.7097818", "0.70485365", "0.6966272", "0.6814178", "0.66394126", "0.66311586", "0.6156213", "0.61229926", "0.6037221", "0.5987748", "0.5986302", "0.5871234", "0.5810195", "0.58066326", "0.57886463", "0.57849926", "0.57805187", "0.5753039", "0.5740952", "0.5740952", "0.56920266", "0.56904364", "0.5662938", "0.5605899", "0.560401", "0.5586307", "0.5569074", "0.556141", "0.55603814", "0.5555749", "0.5555749", "0.5555749", "0.5555749", "0.5555749", "0.55535007", "0.5550461", "0.5542942", "0.553786", "0.5516507", "0.5511693", "0.5508103", "0.54988", "0.54923314", "0.54811203", "0.5462673", "0.54539055", "0.5452433", "0.5446713", "0.5428763", "0.5399671", "0.5399374", "0.5390118", "0.5373663", "0.53549635", "0.5342373", "0.534015", "0.53362876", "0.533587", "0.533587", "0.53323466", "0.5324129", "0.5313389", "0.53100795", "0.53100795", "0.53100795", "0.5302904", "0.52977467", "0.52808654", "0.526263", "0.52587485", "0.52528125", "0.52528125", "0.5252458", "0.5245724", "0.5228026", "0.5223024", "0.52187926", "0.52184117", "0.520846", "0.51944417", "0.5194303", "0.51941234", "0.51857203", "0.51793766", "0.51775295", "0.51749396", "0.5172693", "0.5168494", "0.51631576", "0.5154782", "0.5153077", "0.5150991", "0.5145545", "0.5145454", "0.5145454", "0.5145454", "0.5145454", "0.5145454", "0.51219195", "0.51186675" ]
0.0
-1
Step 3: export default.po file to the relevant directory
function export_language($k,$v,$export_data,$type) { $filename= 'f' . gmdate('YmdHis'); $path = ROOT . DS . $type . DS . 'Locale' . DS; $path .= $v; if (!file_exists($path)){ mkdir($path); } // die; $path .= DS.'LC_MESSAGES'; if (!file_exists($path)) mkdir($path); $file = $path.DS.$filename; if (!file_exists($path)) touch($file); $this->loadModel('Translation'); $file = new File($path.DS.$filename); $tmprec = $export_data; foreach ($tmprec as $rec): $file->write('msgid "' .$rec['msgid'] .'"'."\n"); $file->write('msgstr "'.$rec['msgstr'].'"'."\n"); endforeach; $file->close(); // pr($tmprec); die; if (file_exists($path.DS.'default.po')) rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis')); rename ($path.DS.$filename,$path.DS.'default.po'); return 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function passo3() {\n $filename= 'f' . gmdate('YmdHis');\n foreach ($this->langarr as $k => $v):\n\n $path = ROOT.DS.'app'.DS.'locale'.DS.$v;\n if (!file_exists($path)) mkdir($path);\n \t$path .= DS.'LC_MESSAGES';\n if (!file_exists($path)) mkdir($path);\n \t$file = $path.DS.$filename;\n if (!file_exists($path)) touch($file);\n\n $file = new File($path.DS.$filename);\n $tmprec = $this->Traducao->find('all',array('conditions' => array('Traducao.locale' => $k)));\n foreach ($tmprec as $rec):\n $file->write('msgid \"' .$rec['Traducao']['msgid'] .'\"'.\"\\n\");\n $file->write('msgstr \"'.$rec['Traducao']['msgstr'].'\"'.\"\\n\");\n endforeach;\n $file->close();\n\n if (file_exists($path.DS.'default.po'))\n rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis'));\n\t \n rename ($path.DS.$filename,$path.DS.'default.po');\n endforeach;\n }", "public function passo1() {\n $this->Traducao->import('default.pot');\n }", "function load_custom_plugin_translation_file( $mofile, $domain ) { \n\t\n\t// folder location\n\t$folder = WP_PLUGIN_DIR . '/kinogeneva-translations/languages/';\n\t\n\t// filename ending\n\t$file = '-' . get_locale() . '.mo';\n\t\n\t$plugins = array(\n\t\t'buddypress',\n\t\t'bxcft',\n\t\t'wp-user-groups',\n\t\t'kleo_framework',\n\t\t'invite-anyone',\n\t\t'bp-groups-taxo',\n\t\t'bp-docs'\n\t);\n\t\n\tforeach ($plugins as &$plugin) {\n\t\tif ( $plugin === $domain ) {\n\t\t $mofile = $folder.$domain.$file;\n\t }\n\t}\n\n return $mofile;\n\n}", "function load_custom_kinogeneva_translation_file() {\n\t$mofile = WP_PLUGIN_DIR . '/kinogeneva-translations/languages/kinogeneva-' . get_locale() . '.mo';\n\tload_textdomain( 'kinogeneva', $mofile );\n}", "function wp_get_pomo_file_data($po_file)\n {\n }", "function load_default_textdomain($locale = \\null)\n {\n }", "public function setupPesto() {\n\t\t\t$this->redirect(\"po-setup.php\");\n\t\t}", "protected function makepot( $domain ) {\n\t\t$this->translations = new Translations();\n\n\t\t$meta = $this->get_meta_data();\n\t\tPotGenerator::setCommentBeforeHeaders( $meta['comments'] );\n\n\t\t$this->set_default_headers();\n\n\t\t// POT files have no Language header.\n\t\t$this->translations->deleteHeader( Translations::HEADER_LANGUAGE );\n\n\t\t$this->translations->setDomain( $domain );\n\n\t\t$file_data = $this->get_main_file_data();\n\n\t\t// Extract 'Template Name' headers in theme files.\n\t\tWordPressCodeExtractor::fromDirectory( $this->source, $this->translations, [\n\t\t\t'wpExtractTemplates' => isset( $file_data['Theme Name'] )\n\t\t] );\n\n\t\tunset( $file_data['Version'], $file_data['License'], $file_data['Domain Path'] );\n\n\t\t// Set entries from main file data.\n\t\tforeach ( $file_data as $header => $data ) {\n\t\t\tif ( empty( $data ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$translation = new Translation( '', $data );\n\n\t\t\tif ( isset( $file_data['Theme Name'] ) ) {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the theme', $header ) );\n\t\t\t} else {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the plugin', $header ) );\n\t\t\t}\n\n\t\t\t$this->translations[] = $translation;\n\t\t}\n\n\t\treturn PotGenerator::toFile( $this->translations, $this->destination );\n\t}", "public function welcome_import_message() {\n global $OUTPUT;\n\n $a = get_string('tabutemplatepage2', 'mod_surveypro');\n $message = get_string('welcome_utemplateimport', 'mod_surveypro', $a);\n echo $OUTPUT->notification($message, 'notifymessage');\n }", "function yourls_load_default_textdomain() {\n\t$yourls_locale = yourls_get_locale();\n\n if( !empty( $yourls_locale ) )\n return yourls_load_textdomain( 'default', YOURLS_LANG_DIR . \"/$yourls_locale.mo\" );\n\n return false;\n}", "function joe_uah_load_textdomain() {\n\tload_plugin_textdomain( 'ultimate-admin-helpers', false, basename( __DIR__ ) . '/languages/' );\n}", "function load_textdomain() {\n\n\t\t\tload_theme_textdomain( 'project045', get_template_directory() . '/lang' );\n\n\t\t}", "function export($site_id,$k,$v) {\n $filename= 'f' . gmdate('YmdHis');\n \n\t\t$path = $this->_UploadDirectoryName($site_id,4);\n \n\t\t $path .= $v;\n if (!file_exists($path)){ mkdir($path); }\n\t\t// die;\n $path .= DS.'LC_MESSAGES';\n\t\t \n if (!file_exists($path)) mkdir($path);\n $file = $path.DS.$filename;\n if (!file_exists($path)) touch($file);\n\t\t$this->loadModel('Translation');\n $file = new File($path.DS.$filename);\n\t\t\n $tmprec = $this->Translation->find('all', array('conditions' => array('Translation.locale' => $k)));\n\t\t \n foreach ($tmprec as $rec):\n $file->write('msgid \"' .$rec['Translation']['msgid'] .'\"'.\"\\n\");\n $file->write('msgstr \"'.$rec['Translation']['msgstr'].'\"'.\"\\n\");\n endforeach;\n $file->close();\n\n if (file_exists($path.DS.'default.po'))\n rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis'));\n\t\t\trename ($path.DS.$filename,$path.DS.'default.po');\n\t\t\t\n\t return 1;\n\t\t\n }", "function simple_login_history_load_textdomain() {\n load_plugin_textdomain('simple-login-history', false, dirname( plugin_basename( __FILE__ )) . '/languages/');\n}", "protected function extract_strings() {\n\t\t$translations = new Translations();\n\n\t\t// Add existing strings first but don't keep headers.\n\t\tif ( ! empty( $this->merge ) ) {\n\t\t\t$existing_translations = new Translations();\n\t\t\tPo::fromFile( $this->merge, $existing_translations );\n\t\t\t$translations->mergeWith( $existing_translations, Merge::ADD | Merge::REMOVE );\n\t\t}\n\n\t\tPotGenerator::setCommentBeforeHeaders( $this->get_file_comment() );\n\n\t\t$this->set_default_headers( $translations );\n\n\t\t// POT files have no Language header.\n\t\t$translations->deleteHeader( Translations::HEADER_LANGUAGE );\n\n\t\t// Only relevant for PO files, not POT files.\n\t\t$translations->setHeader( 'PO-Revision-Date', 'YEAR-MO-DA HO:MI+ZONE' );\n\n\t\tif ( $this->domain ) {\n\t\t\t$translations->setDomain( $this->domain );\n\t\t}\n\n\t\tunset( $this->main_file_data['Version'], $this->main_file_data['License'], $this->main_file_data['Domain Path'], $this->main_file_data['Text Domain'] );\n\n\t\t$is_theme = isset( $this->main_file_data['Theme Name'] );\n\n\t\t// Set entries from main file data.\n\t\tforeach ( $this->main_file_data as $header => $data ) {\n\t\t\tif ( empty( $data ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$translation = new Translation( '', $data );\n\n\t\t\tif ( $is_theme ) {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the theme', $header ) );\n\t\t\t} else {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the plugin', $header ) );\n\t\t\t}\n\n\t\t\t$translations[] = $translation;\n\t\t}\n\n\t\ttry {\n\t\t\tif ( ! $this->skip_php ) {\n\t\t\t\t$options = [\n\t\t\t\t\t// Extract 'Template Name' headers in theme files.\n\t\t\t\t\t'wpExtractTemplates' => $is_theme,\n\t\t\t\t\t// Extract 'Title' and 'Description' headers from pattern files.\n\t\t\t\t\t'wpExtractPatterns' => $is_theme,\n\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t'extensions' => [ 'php' ],\n\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t];\n\t\t\t\tPhpCodeExtractor::fromDirectory( $this->source, $translations, $options );\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_blade ) {\n\t\t\t\t$options = [\n\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t'extensions' => [ 'blade.php' ],\n\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t];\n\t\t\t\tBladeCodeExtractor::fromDirectory( $this->source, $translations, $options );\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_js ) {\n\t\t\t\tJsCodeExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'js', 'jsx' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\tMapCodeExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'map' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_block_json ) {\n\t\t\t\tBlockExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'schema' => JsonSchemaExtractor::BLOCK_JSON_SOURCE,\n\t\t\t\t\t\t'schemaFallback' => JsonSchemaExtractor::BLOCK_JSON_FALLBACK,\n\t\t\t\t\t\t// Only look for block.json files, nothing else.\n\t\t\t\t\t\t'restrictFileNames' => [ 'block.json' ],\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'json' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_theme_json ) {\n\t\t\t\t// This will look for the top-level theme.json file, as well as\n\t\t\t\t// any JSON file within the top-level styles/ directory.\n\t\t\t\tThemeJsonExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'schema' => JsonSchemaExtractor::THEME_JSON_SOURCE,\n\t\t\t\t\t\t'schemaFallback' => JsonSchemaExtractor::THEME_JSON_FALLBACK,\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'json' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\t\t} catch ( \\Exception $e ) {\n\t\t\tWP_CLI::error( $e->getMessage() );\n\t\t}\n\n\t\tforeach ( $this->exceptions as $file => $exception_translations ) {\n\t\t\t/** @var Translation $exception_translation */\n\t\t\tforeach ( $exception_translations as $exception_translation ) {\n\t\t\t\tif ( ! $translations->find( $exception_translation ) ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif ( $this->subtract_and_merge ) {\n\t\t\t\t\t$translation = $translations[ $exception_translation->getId() ];\n\t\t\t\t\t$exception_translation->mergeWith( $translation );\n\t\t\t\t}\n\n\t\t\t\tunset( $translations[ $exception_translation->getId() ] );\n\t\t\t}\n\n\t\t\tif ( $this->subtract_and_merge ) {\n\t\t\t\tPotGenerator::toFile( $exception_translations, $file );\n\t\t\t}\n\t\t}\n\n\t\tif ( ! $this->skip_audit ) {\n\t\t\t$this->audit_strings( $translations );\n\t\t}\n\n\t\treturn $translations;\n\t}", "function _textdomain($domain)\r\n\t{\r\n\t\tglobal $default_domain;\r\n\t\t$default_domain = $domain;\r\n\t}", "protected function _writeLocale()\n {\n $text = $this->_tpl['locale'];\n \n $file = $this->_class_dir . DIRECTORY_SEPARATOR . \"/Locale/en_US.php\";\n if (file_exists($file)) {\n $this->_outln('Locale file exists.');\n } else {\n $this->_outln('Writing locale file.');\n file_put_contents($file, $text);\n }\n }", "function apologize($message) \n\t{\t\n\t\trequire_once(\"templates/apology.php\");\n\t\texit;\n\t}", "public function load_translation() {\n\t\t\t$locale = apply_filters( 'plugin_locale', determine_locale(), 'sv_core' );\n\t\t\tload_textdomain( 'sv_core', dirname( __FILE__ ) . '/languages/sv_core-'.$locale.'.mo' );\n\t\t}", "function _jsPo() {\n\t\t$Folder = new Folder(APP . 'locale');\n\t\tlist($locales, $potFiles) = $Folder->read();\n\t\tif (!in_array('javascript.pot', $potFiles)) {\n\t\t\t$this->out(__d('mi', 'The javascript.pot file wasn\\'t found - run cake mi_i18n to generate it', true));\n\t\t\treturn;\n\t\t}\n\t\tif (defined('DEFAULT_LANGUAGE')) {\n\t\t\t$locales = array_unique(am(array(DEFAULT_LANGUAGE), $locales));\n\t\t}\n\t\tif (!class_exists('I18n')) {\n\t\t\tApp::import('Core', 'i18n');\n\t\t}\n\n\t\t$messages = array();\n\t\tforeach ($locales as $locale) {\n\t\t\tif ($locale[0] === '.') {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$data = Cache::read('javascript_' . $locale, '_cake_core_');\n\t\t\tif (!$data) {\n\t\t\t\tConfigure::write('Config.language', $locale);\n\t\t\t\t__d('javascript', 'foo', true);\n\t\t\t\t$inst =& I18n::getInstance();\n\t\t\t\tCache::write('javascript_' . $locale, array_filter($inst->__domains), '_cake_core_');\n\t\t\t\t$data = Cache::read('javascript_' . $locale, '_cake_core_');\n\t\t\t\tif (!$data) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach($data as $type => $i) {\n\t\t\t\tforeach ($i[$locale]['javascript'] as $lookup => $string) {\n\t\t\t\t\tif (!is_string($string)) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (!$string) {\n\t\t\t\t\t\t$string = $lookup;\n\t\t\t\t\t}\n\t\t\t\t\t$messages[$lookup] = $string;\n\t\t\t\t}\n\t\t\t}\n\t\t\tob_start();\n\t\t\tinclude(dirname(__FILE__) . DS . 'templates' . DS . 'js' . DS . 'po.js');\n\t\t\t$contents = ob_get_clean();\n\t\t\t$targetFile = APP . 'vendors' . DS . 'js' . DS . 'i18n.' . $locale . '.js';\n\t\t\t$File = new File($targetFile);\n\t\t\t$File->write($contents);\n\t\t\t$this->out(Debugger::trimPath($targetFile) . ' written');\n\t\t}\n\t}", "function setup()\n{\n custom_locale();\n\n Main::init();\n\n do_action( 'root_setup' );\n}", "function load_textdomain($domain, $mofile, $locale = \\null)\n {\n }", "protected function getLocalLangFileName() {}", "private function verify_single_language_file($name){\n\t\t// Clear lang variable\n\t\t$this->zajlib->lang->reset_variables();\n\t\t// Load up a language file explicitly for default lang\n\t\t$default_locale = $this->zajlib->lang->get_default_locale();\n\t\t$res = $this->zajlib->lang->load($name.'.'.$default_locale.'.lang.ini', false, false, false);\n\t\tif(!$res) $this->zajlib->test->notice(\"<strong>Could not find default locale lang file!</strong> Not having lang files for default locale may cause fatal errors. We could not find this one: $name.$default_locale.lang.ini.\");\n\t\telse{\n\t\t\t$default_array = (array) $this->zajlib->lang->variable;\n\t\t\t// Load up a language file explicitly\n\t\t\tforeach($this->zajlib->lang->get_locales() as $locale){\n\t\t\t\tif($locale != $default_locale){\n\t\t\t\t\t$this->zajlib->lang->reset_variables();\n\t\t\t\t\t$file = $this->zajlib->lang->load($name.'.'.$locale.'.lang.ini', false, false, false);\n\t\t\t\t\tif($file){\n\t\t\t\t\t\t$my_array = (array) $this->zajlib->lang->variable;\n\t\t\t\t\t\t$diff_keys = array_diff_key($default_array, $my_array);\n\t\t\t\t\t\tif(count($diff_keys) > 0){\n\t\t\t\t\t\t\t$this->zajlib->test->notice(\"Not all translations from $default_locale found in $locale ($name). Missing the following keys: \".join(', ', array_keys($diff_keys)));\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$rev_diff_keys = array_diff_key($my_array, $default_array);\n\t\t\t\t\t\tif(count($rev_diff_keys) > 0){\n\t\t\t\t\t\t\t$this->zajlib->test->notice(\"Some translations in $locale are not found in the default $default_locale locale ($name). Missing the following keys: \".join(', ', array_keys($rev_diff_keys)));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function create_default_script() {\n\tcopy(\"defaultscript.txt\", \"scripts/untitled\");\n}", "public function localization_setup() {\n load_plugin_textdomain( 'wc-mailerlite', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n }", "function main() {\n\t\t$this->out(__('I18n Shell', true));\n\t\t$this->hr();\n\t\t$this->out(__('[E]xtract POT file from sources', true));\n\t\t$this->out(__('[I]nitialize i18n database table', true));\n\t\t$this->out(__('[H]elp', true));\n\t\t$this->out(__('[Q]uit', true));\n\n\t\t$choice = strtolower($this->in(__('What would you like to do?', true), array('E', 'I', 'H', 'Q')));\n\t\tswitch ($choice) {\n\t\t\tcase 'e':\n\t\t\t\t$this->Extract->execute();\n\t\t\tbreak;\n\t\t\tcase 'i':\n\t\t\t\t$this->initdb();\n\t\t\tbreak;\n\t\t\tcase 'h':\n\t\t\t\t$this->help();\n\t\t\tbreak;\n\t\t\tcase 'q':\n\t\t\t\texit(0);\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$this->out(__('You have made an invalid selection. Please choose a command to execute by entering E, I, H, or Q.', true));\n\t\t}\n\t\t$this->hr();\n\t\t$this->main();\n\t}", "public function translations()\n {\n $this->loadTranslationsFrom(__DIR__.'/Resources/Lang', $this->packageName);\n\n $this->publishes([\n __DIR__.'/path/to/translations' => resource_path('lang/vendor/courier'),\n ], $this->packageName.'-translations');\n }", "function translation() {\n\t\t\n\t\t// only use, if we have it...\n\t\tif( function_exists('load_plugin_textdomain') ) {\n\t\t\n\t\t\t// load it\n\t\t\tload_plugin_textdomain( \n\t\t\t\n\t\t\t\t// unique name\n\t\t\t\t'cp-multisite', \n\t\t\t\t\n\t\t\t\t// deprecated argument\n\t\t\t\tfalse,\n\t\t\t\t\n\t\t\t\t// path to directory containing translation files\n\t\t\t\tplugin_dir_path( CPMU_PLUGIN_FILE ) . 'languages/'\n\t\t\t\t\n\t\t\t);\n\t\t\t\n\t\t}\n\t\t\n\t}", "public function plugin_textdomain() {\n load_plugin_textdomain( CUSTOM_LOGIN_DIRNAME, false, CUSTOM_LOGIN_DIRNAME . '/languages/' );\n }", "protected function set_default_headers() {\n\t\t$meta = $this->get_meta_data();\n\n\t\t$this->translations->setHeader( 'Project-Id-Version', $meta['name'] . ' ' . $meta['version'] );\n\t\t$this->translations->setHeader( 'Report-Msgid-Bugs-To', $meta['msgid-bugs-address'] );\n\t\t$this->translations->setHeader( 'Last-Translator', 'FULL NAME <EMAIL@ADDRESS>' );\n\t\t$this->translations->setHeader( 'Language-Team', 'LANGUAGE <[email protected]>' );\n\t}", "function i18n() {\n\tload_theme_textdomain( 'project', Project_PATH . '/languages' );\n }", "function load_muplugin_textdomain($domain, $mu_plugin_rel_path = '')\n {\n }", "function install_single_pages($pkg)\n {\n // $directoryDefault->update(array('cName' => t('Sample Package'), 'cDescription' => t('Sample Package')));\n }", "function yourls_load_custom_textdomain( $domain, $path ) {\n\t$locale = yourls_apply_filter( 'load_custom_textdomain', yourls_get_locale(), $domain );\n if( !empty( $locale ) ) {\n $mofile = rtrim( $path, '/' ) . '/'. $domain . '-' . $locale . '.mo';\n return yourls_load_textdomain( $domain, $mofile );\n }\n}", "function hybrid_load_textdomain_mofile( $mofile, $domain ) {\n\n\t/* If the $domain is for the parent or child theme, search for a $domain-$locale.mo file. */\n\tif ( $domain == hybrid_get_parent_textdomain() || $domain == hybrid_get_child_textdomain() ) {\n\n\t\t/* Check for a $domain-$locale.mo file in the parent and child theme root and /languages folder. */\n\t\t$locale = get_locale();\n\t\t$locate_mofile = locate_template( array( \"languages/{$domain}-{$locale}.mo\", \"{$domain}-{$locale}.mo\" ) );\n\n\t\t/* If a mofile was found based on the given format, set $mofile to that file name. */\n\t\tif ( !empty( $locate_mofile ) )\n\t\t\t$mofile = $locate_mofile;\n\t}\n\n\t/* Return the $mofile string. */\n\treturn $mofile;\n}", "private function export()\n {\n $translationLocale = $this->ask('In which language do you want to translate?', 'en');\n if ($translationLocale == $this->manager->getDefaultLocale()) {\n $this->warn('It is not possible to translate the default language');\n\n return;\n }\n\n /**\n * Create export file.\n */\n $file = fopen('translation_'.$this->manager->getDefaultLocale().'-'.$translationLocale.'.csv', 'w');\n fputcsv($file, ['translation_string', $this->manager->getDefaultLocale(), $translationLocale], $this->csvSeperator);\n\n if ($this->option('overwrite')) {\n $translations = $this->manager->getTranslationValues($this->manager->getDefaultLocale());\n } else {\n $translations = $this->manager->getUntranslatedValues(\n $this->manager->getDefaultLocale(),\n $translationLocale\n );\n }\n\n foreach ($translations as $key => $value) {\n fputcsv($file, [$key, $value, ''], $this->csvSeperator);\n }\n fclose($file);\n }", "public function localization_setup() {\n load_plugin_textdomain( 'baseplugin', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n }", "public function i18n() {\r\n load_plugin_textdomain( 'woolentor-pro', false, dirname( plugin_basename( WOOLENTOR_ADDONS_PL_ROOT_PRO ) ) . '/languages/' );\r\n }", "private function readOriginal(): void\n {\n $this->translation = $this->translation->withOriginal($this->readIdentifier('msgid', true));\n }", "function mbifthen_load_textdomain() {\r\n\tload_plugin_textdomain( 'multibanco-ifthen-software-gateway-for-woocommerce', false, dirname( plugin_basename( __FILE__ ) ).'/lang/' );\r\n}", "function bindtextdomain($domain, $directory) {\n global $faketext, $valid_languages, $supported_languages;\n \n // New language config to detect language\n $language_config = new LANGUAGE_CONFIG($valid_languages, $supported_languages, false);\n $faketext_lang = $language_config->detectCurrentLanguage();\n \n // Path to .po file\n $po = \"{$directory}/{$faketext_lang}/LC_MESSAGES/{$domain}.po\";\n \n if (file_exists($po)) {\n $contents = file_get_contents($po);\n }\n else {\n // If the .po wasn't found, try replacing dashes with underscores in locale\n $formatted_lang = str_replace('-', '_', $faketext_lang);\n $po = \"{$directory}/{$formatted_lang}/LC_MESSAGES/{$domain}.po\";\n if (file_exists($po)) {\n $contents = file_get_contents($po);\n }\n else {\n // .po not found, return\n return false;\n }\n }\n \n // Remove header information;\n $contents = substr($contents, strpos($contents, \"\\n\\n\"));\n \n // Un-escape quotes\n $contents = str_replace('\\\"', '\"', $contents);\n \n // Parse strings\n preg_match_all('/msgid\\s+\"(.+?)\"\\s*(msgid_plural\\s+\"(.+?)\"\\s*)?((msgstr(\\[\\d+\\])?\\s+?\"(.+?)\"\\s*)+)(#|msg)/is', $contents, $localeMatches, PREG_SET_ORDER);\n \n // Make pretty key => value array\n foreach ($localeMatches as $localeMatch) {\n // Determine if this is a plural entry\n if (strpos($localeMatch[2], 'msgid_plural') !== false) {\n // If plural, parse each string\n $plurals = array();\n preg_match_all('/msgstr(\\[\\d+\\])?\\s+?\"(.+?)\"\\s*/is', $localeMatch[4], $pluralMatches, PREG_SET_ORDER);\n \n foreach ($pluralMatches as $pluralMatch) {\n $plurals[] = str_replace(\"\\\"\\n\\\"\", '', $pluralMatch[2]);\n }\n \n $faketext[$localeMatch[1]] = $plurals;\n }\n else {\n $faketext[$localeMatch[1]] = str_replace(\"\\\"\\n\\\"\", '', $localeMatch[7]);\n }\n }\n }", "protected function langHandle()\n {\n $packageTranslationsPath = __DIR__.'/resources/lang';\n\n $this->loadTranslationsFrom($packageTranslationsPath, 'task-management');\n\n $this->publishes([\n $packageTranslationsPath => resource_path('lang/vendor/task-management'),\n ], 'lang');\n }", "function yourls_load_textdomain( $domain, $mofile ) {\n\tglobal $yourls_l10n;\n\n\t$plugin_override = yourls_apply_filter( 'override_load_textdomain', false, $domain, $mofile );\n\n\tif ( true == $plugin_override ) {\n\t\treturn true;\n\t}\n\n\tyourls_do_action( 'load_textdomain', $domain, $mofile );\n\n\t$mofile = yourls_apply_filter( 'load_textdomain_mofile', $mofile, $domain );\n\n\tif ( !is_readable( $mofile ) ) {\n trigger_error( 'Cannot read file ' . str_replace( YOURLS_ABSPATH.'/', '', $mofile ) . '.'\n . ' Make sure there is a language file installed. More info: http://yourls.org/translations' );\n return false;\n }\n\n\t$mo = new MO();\n\tif ( !$mo->import_from_file( $mofile ) )\n return false;\n\n\tif ( isset( $yourls_l10n[$domain] ) )\n\t\t$mo->merge_with( $yourls_l10n[$domain] );\n\n\t$yourls_l10n[$domain] = &$mo;\n\n\treturn true;\n}", "private function publishLanguage()\n {\n if (!file_exists(base_path().'/resources/lang/')) {\n mkdir(base_path().'/resources/lang');\n $this->info('Published language directory in '.base_path().'/resources/lang/');\n }\n }", "public function load_textdomain()\n {\n }", "public function load_textdomain() {\n\t\t// Set filter for plugin's languages directory\n\t\t$lang_dir = dirname( plugin_basename( __FILE__ ) ) . '/languages/';\n\t\t$lang_dir = apply_filters( 'bbp_notices_languages', $lang_dir );\n\n\t\t// Traditional WordPress plugin locale filter\n\t\t$locale = apply_filters( 'plugin_locale', get_locale(), 'bbpress-notices' );\n\t\t$mofile = sprintf( '%1$s-%2$s.mo', 'bbpress-notices', $locale );\n\n\t\t// Setup paths to current locale file\n\t\t$mofile_local = $lang_dir . $mofile;\n\t\t$mofile_global = WP_LANG_DIR . '/bbpress-notices/' . $mofile;\n\n\t\tif ( file_exists( $mofile_global ) ) {\n\t\t\t// Look in global /wp-content/languages/bbpress-notices folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_global );\n\t\t} elseif ( file_exists( $mofile_local ) ) {\n\t\t\t// Look in local /wp-content/plugins/bbpress-notices/languages/ folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_local );\n\t\t} else {\n\t\t\t// Load the default language files\n\t\t\tload_plugin_textdomain( 'bbpress-notices', false, $lang_dir );\n\t\t}\n\t}", "public function load_textdomain() {\n\n\t\t\t// Set filter for plugin's languages directory\n\t\t\t$lang_dir = dirname( plugin_basename( __FILE__ ) ) . '/languages/';\n\t\t\t$lang_dir = apply_filters( 'affwp_direct_link_tracking_languages_directory', $lang_dir );\n\n\t\t\t// Traditional WordPress plugin locale filter\n\t\t\t$locale = apply_filters( 'plugin_locale', get_locale(), 'affiliatewp-direct-link-tracking' );\n\t\t\t$mofile = sprintf( '%1$s-%2$s.mo', 'affiliatewp-direct-link-tracking', $locale );\n\n\t\t\t// Setup paths to current locale file\n\t\t\t$mofile_local = $lang_dir . $mofile;\n\t\t\t$mofile_global = WP_LANG_DIR . '/affiliatewp-direct-link-tracking/' . $mofile;\n\n\t\t\tif ( file_exists( $mofile_global ) ) {\n\t\t\t\t// Look in global /wp-content/languages/affiliatewp-direct-link-tracking/ folder\n\t\t\t\tload_textdomain( 'affiliatewp-direct-link-tracking', $mofile_global );\n\t\t\t} elseif ( file_exists( $mofile_local ) ) {\n\t\t\t\t// Look in local /wp-content/plugins/affiliatewp-plugin-template/languages/ folder\n\t\t\t\tload_textdomain( 'affiliatewp-direct-link-tracking', $mofile_local );\n\t\t\t} else {\n\t\t\t\t// Load the default language files\n\t\t\t\tload_plugin_textdomain( 'affiliatewp-direct-link-tracking', false, $lang_dir );\n\t\t\t}\n\t\t}", "function dreams_load_admin_textdomain_in_front() {\r\n\tif (!is_admin()) {\r\n\t\tload_textdomain('default', WP_LANG_DIR . '/admin-' . get_locale() . '.mo');\r\n\t}\r\n}", "public function createPackageFile()\n\t{\n\t\t$packageFilePath = __DIR__ . \"/templates/packagefile.txt\";\n\n\t\t// If file exists, copy content into new file called package.json in project root.\n\t\tif($this->filesystem->exists($packageFilePath))\n\t\t{\n\t\t\t$this->filesystem->put('package.json', $this->filesystem->get($packageFilePath));\n\t\t}\n\t}", "public function install() {\n $strReturn = \"\";\n\n $strReturn .= \"Assigning null-properties and elements to the default language.\\n\";\n if($this->strContentLanguage == \"de\") {\n\n $strReturn .= \" Target language: de\\n\";\n\n if(class_exists(\"class_module_pages_page\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_page\") !== false)\n class_module_pages_page::assignNullProperties(\"de\", true);\n if(class_exists(\"class_module_pages_pageelement\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_pageelement\") !== false)\n class_module_pages_pageelement::assignNullElements(\"de\");\n\n $objLang = new class_module_languages_language();\n $objLang->setStrAdminLanguageToWorkOn(\"de\");\n }\n else {\n\n $strReturn .= \" Target language: en\\n\";\n\n if(class_exists(\"class_module_pages_page\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_page\") !== false)\n class_module_pages_page::assignNullProperties(\"en\", true);\n if(class_exists(\"class_module_pages_pageelement\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_pageelement\") !== false)\n class_module_pages_pageelement::assignNullElements(\"en\");\n\n $objLang = new class_module_languages_language();\n $objLang->setStrAdminLanguageToWorkOn(\"en\");\n\n }\n\n\n return $strReturn;\n }", "function pmprowoo_gift_levels_email_path($default_templates, $page_name, $type = 'email', $where = 'local', $ext = 'html') {\r\n $default_templates[] = PMPROWC_DIR . \"/email/{$page_name}.{$ext}\";\r\n return $default_templates;\r\n}", "function svbk_mandrill_emails_init() {\n\tload_plugin_textdomain( 'svbk-mandrill-emails', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n}", "public function createReadmeFile()\r\n {\r\n $originalFile = realpath(__DIR__ . '/../Resources/files/templates/README');\r\n $newFile = $this->destination_dir.'/README.md';\r\n\r\n $this->createCopiedFile($originalFile, $newFile);\r\n }", "function create_newsletter_page() {\r\n require_once( $plugin_dir . \"email-newsletter-files/page-create-newsletter.php\" );\r\n }", "function load_textdomain() {\r\n load_plugin_textdomain( WPC_CLIENT_TEXT_DOMAIN, false, dirname( 'wp-client-client-portals-file-upload-invoices-billing/wp-client-lite.php' ) . '/languages/' );\r\n }", "private function translationWorkaround()\n {\n L10n::__('BudgetMailer Sign Up Form for WordPress');\n L10n::__('BudgetMailer Sign Up');\n }", "function translateFile($kohana_path, $ionize_path) {\n //import kohana lang array\n $kohana_lang = include($kohana_path);\n //import ionize lang array\n $ionize_file = file($ionize_path);\n $ionize_file = checkForReturn($ionize_file);\n\n file_put_contents($ionize_path,$ionize_file);\n $ionize_file = file($ionize_path);\n $ionize_lang = include($ionize_path);\n\n //get index to start adding entries to ionize file at\n foreach($ionize_file as $index=>$item) {\n if(strpos($item, 'return $lang')!== false) {\n $appendLine = $index;\n }\n }\n \n \n /**\n *For each entry in the kohana lang file,\n *check if it exists in the ionize lang file.\n *If it does and translation matches, skip over\n *Else update existing entry or append new entry to file\n */\n foreach($kohana_lang as $key=>$entry) {\n $key_with_slash = str_replace(\"'\", \"\\'\", $key);\n $entry_with_slash = str_replace(\"'\", \"\\'\", $entry);\n \n //check if entry exists\n if(isset($ionize_lang[$key])) {\n //get line from ionize file of entry\n foreach($ionize_file as $index=>$item){\n if(strpos($item,'$lang[' . $key . ']')!== false){\n $line_number = $index;\n }\n }\n //check if entries match\n if($ionize_lang[$key] != $entry) {\n $ionize_file[$line_number] = '$lang[\\'' . $key_with_slash . '\\'] = \\'' . $entry_with_slash . '\\';' . PHP_EOL; \n }\n }\n //if entry does not exist, insert it\n else {\n $ionize_file[$appendLine] = '$lang[\\'' . $key_with_slash . '\\'] = \\'' . $entry_with_slash . '\\';' . PHP_EOL;\n $appendLine++;\n }\n }\n \n //check to see if return $lang exists, if not add it to end of file\n $ionize_file = checkForReturn($ionize_file);\n \n file_put_contents($ionize_path,$ionize_file);\n}", "public function textdomain() {\n\t\tload_plugin_textdomain( 'global-user-password-reset', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t}", "public function localization() {\n\t\t\tload_plugin_textdomain( 'bitlive-custom-codes', false, __DIR__ . '/languages/' );\n\t\t}", "function setup_meta_translation() {\n\t\t\tglobal $post, $wpdb;\n\t\t\t$post_id = $post->ID;\n\t\t\t\n\t\t\tforeach($this->arabic_meta_keys as $key ) {\n\t\t\t\tif ($post_id){\n\t\t\t\t\t$$key = get_post_meta($post_id, $key, true);\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$$key = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$the_post = get_post($post_id);\n\t\t\t\n\t\t\tinclude(dirname(__FILE__).'/views/ipc-meta-box-translation.php');\n\t\t}", "function load_script_textdomain($handle, $domain = 'default', $path = '')\n {\n }", "function load_child_theme_textdomain($domain, $path = \\false)\n {\n }", "function positive_panels_lang(){\n\tload_textdomain('positive-panels', 'lang/positive-panels.mo');\n}", "protected function getDefaultImportExportFolder() {}", "protected function getDefaultImportExportFolder() {}", "function freeproduct_textdomain() {\n\tload_plugin_textdomain( 'woocommerce-freeproduct', false, basename( dirname( __FILE__ ) ) . '/lang' );\n}", "function EWD_URP_localization_setup() {\n\t\tload_plugin_textdomain('ultimate-reviews', false, dirname(plugin_basename(__FILE__)) . '/lang/');\n}", "function lang() {\r\n\t\t\tload_plugin_textdomain( 'rv-portfolio', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\r\n\t\t}", "protected function generateLocalLang() {}", "private function translations()\n {\n $this['translator'] = $this->share($this->extend('translator', function ($translator) {\n $translator->addLoader('yaml', new TranslationFileLoader());\n\n $translator->addResource('yaml', 'config/locales/pt-br.yml', 'pt-br');\n $translator->addResource('yaml', 'config/locales/en-us.yml', 'en-us');\n $translator->addResource('yaml', 'config/locales/es-es.yml', 'es-es');\n\n return $translator;\n }));\n }", "function get_entry_points()\n\t{\n\t\treturn array_merge(array('misc'=>'WELCOME_EMAILS'),parent::get_entry_points());\n\t}", "public function initLocalization() {\n $moFiles = scandir(trailingslashit($this->dir) . 'languages/');\n foreach ($moFiles as $moFile) {\n if (strlen($moFile) > 3 && substr($moFile, -3) == '.mo' && strpos($moFile, get_locale()) > -1) {\n load_textdomain('WP_Visual_Chat', trailingslashit($this->dir) . 'languages/' . $moFile);\n }\n }\n }", "public function setup_i18n() {\n\t\tload_plugin_textdomain( 'woocommerce-bundle-rate-shipping', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n\t}", "function initialize_i18n() {\n\t\n\t$locale \t\t\t\t\t= get_locale();\n\t#error_log( \"got locale: $locale\" );\n\t\n\tif( ! preg_match( '/_/', $locale ) ) {\n\t\t\n\t\t$locale\t\t\t\t\t= $locale.\"_\".strtoupper($locale);\n\t\t#error_log( \"set locale to: $locale\" );\n\t}\n\t\n\tputenv(\"LANG=$locale\");\n\tputenv(\"LC_ALL=$locale\");\n\tsetlocale(LC_ALL, 0);\n\tsetlocale(LC_ALL, $locale);\n\t\n\tif ( file_exists ( realpath ( \"./locale/de/LC_MESSAGES/messages.mo\" ) ) ) {\n\t\t\n\t\t$localepath\t\t\t\t= \"./locale\";\n\t\t\n\t} elseif( file_exists( realpath( \"../locale/de/LC_MESSAGES/messages.mo\" ) ) ) {\n\t\t\n\t\t$localepath\t\t\t\t= \"../locale\";\n\t\t\n\t} else {\n\t\t\n\t\t$localepath\t\t\t\t= \"./locale\";\n\t\t\n\t}\n\t\n\t$dom\t\t\t\t\t\t= bindtextdomain(\"messages\", $localepath);\n\t$msgdom \t\t\t\t\t= textdomain(\"messages\");\n\t\n\tbind_textdomain_codeset(\"messages\", 'UTF-8');\n\n}", "function load_plugin_templates() : void {\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/subscriber-only-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/split-content-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/banner-message.php';\n}", "public function atmf_load_plugin_textdomain(){\n\n $domain = $this->plugin_slug;\n $locale = apply_filters( 'plugin_locale', get_locale(), 'atmf' );\n\n load_textdomain( $domain, trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' );\n load_plugin_textdomain( $domain, FALSE, basename( dirname( __FILE__ ) ) . '/languages/' );\n }", "public static function getTranslationFileDirectory() {\n return PIMCORE_PLUGINS_PATH.\"/PimTools/texts\";\n }", "function kino_load_textdomain() {\n\t\t\t\t\t\t\n\t\t\t// BP group announcements\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'bpga',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\t\t\t// BP group calendar\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'groupcalendar',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\t\t\t// BuddyPress Group Email Subscription\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'bp-ass',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\n}", "public function load_plugin_textdomain() {\n\n\t\t\t$domain = 'wolf-woocommerce-quickview';\n\t\t\t$locale = apply_filters( 'wolf-woocommerce-quickview', get_locale(), $domain );\n\t\t\tload_textdomain( $domain, WP_LANG_DIR . '/' . $domain . '/' . $domain . '-' . $locale . '.mo' );\n\t\t\tload_plugin_textdomain( $domain, FALSE, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t\t}", "function i18n() {\n // Translations can be filed in the /languages/ directory\n load_theme_textdomain('mo_theme', get_template_directory() . '/languages');\n\n $locale = get_locale();\n $locale_file = get_template_directory() . \"/languages/$locale.php\";\n if (is_readable($locale_file))\n require_once($locale_file);\n\n }", "function farmhouse_localization_setup() {\n\n load_child_theme_textdomain( 'farmhouse-theme', CHILD_DIR . '/languages' );\n\n}", "public function load_textdomain() {\n\t\t\t$mo_file_path = dirname( __FILE__ ) . '/languages/' . get_locale() . '.mo';\n\n\t\t\tload_textdomain( 'cherry-framework', $mo_file_path );\n\t\t}", "private function _get_translations_from_file () {\n\n\t\t$lang = file_exists(self::DIR_LANGS . $this->lang . '.php')\n\t\t\t\t\t? $this->lang : $this->_default_lang;\n\n\t\trequire self::DIR_LANGS . $lang . '.php';\n\n\t\treturn $t;\n\n\t}", "function localization() {\n load_plugin_textdomain( 'cynetique-labels', false, dirname( plugin_basename( __FILE__ ) ) . '/language/' );\n}", "function _get_path_to_translation_from_lang_dir($domain)\n {\n }", "function cs_bible_lesson_load_plugin_textdomain() {\r\n load_plugin_textdomain( 'christian-science-bible-lesson-subjects', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\r\n}", "function wp_set_script_translations($handle, $domain = 'default', $path = '')\n {\n }", "function __construct() {\n\t\t$this->addTranslation(__FILE__);\n\t}", "function initialize_i18n($language) {\n\t$locales_root = \"./Locale\";\n putenv(\"LANG=\" . $language); \n\tputenv(\"LC_ALL=en_us\"); \n\tsetlocale(LC_ALL, $language);\n $domains = glob($locales_root.'/'.$language.'/LC_MESSAGES/messages-*.mo');\t\n\t$newTimeStamp = time();\n $current = basename($domains[0],'.mo');\n $timestamp = preg_replace('{messages-}i','',$current);\n\t$oldFileName = $domains[0];\n\t$newFileName = $locales_root.\"/\".$language.\"/LC_MESSAGES/messages-\".$newTimeStamp.\".mo\";\n\t$newFile = \"messages-\".$newTimeStamp;\n\trename($oldFileName, $newFileName);\n bindtextdomain($newFile,$locales_root);\n\tbind_textdomain_codeset($newFile, 'UTF-8');\n textdomain($newFile);\n}", "public function main() {\n\n $fs = new Filesystem();\n\n $fs->touch($this->getTargetFile());\n\n $seedProperties = Yaml::parse(file_get_contents($this->getSeedFile()));\n $generatedProperties = [];\n\n $generatedProperties['label'] = $seedProperties['project_label'];\n $generatedProperties['machineName'] = $seedProperties['project_name'];\n $generatedProperties['group'] = $seedProperties['project_group'];\n $generatedProperties['basePath'] = '${current.basePath}';\n $generatedProperties['type'] = $seedProperties['project_type'];\n $generatedProperties['repository']['main'] = $seedProperties['project_git_repository'];\n $generatedProperties['php'] = $seedProperties['project_php_version'];\n\n // Add platform information.\n if (isset($generatedProperties['platform'])) {\n $generatedProperties['platform'] = $seedProperties['platform'];\n }\n\n $fs->dumpFile($this->getTargetFile(), Yaml::dump($generatedProperties, 5, 2));\n }", "function ind_text_domain() {\n\tload_plugin_textdomain('indizar', false, 'indizar/lang');\n}", "public function welcome_apply_message() {\n global $OUTPUT;\n\n $a = new \\stdClass();\n $a->uploadpage = get_string('tabutemplatepage3', 'mod_surveypro');\n $a->savepage = get_string('tabutemplatepage2', 'mod_surveypro');\n $message = get_string('welcome_utemplateapply', 'mod_surveypro', $a);\n echo $OUTPUT->notification($message, 'notifymessage');\n }", "function sec_init() {\n\tload_plugin_textdomain(EVNT_TEXTDOMAIN, false, dirname( plugin_basename( __FILE__ ) ) );\n}", "public function load_plugin_textdomain() {\n\t\tload_plugin_textdomain( 'genesis-simple-hooks', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t}", "private function generateTranslations() {\n\n $this->doCommand('php artisan medkit:generate-translations');\n }", "function dust_text_domain() {\n load_plugin_textdomain( 'theme-package', false, DUST_ACC_PATH . '/languages' );\n }", "private function init_tftp_lang_path() {\n $dir = $this->sccppath[\"tftp_lang_path\"];\n foreach ($this->extconfigs->getextConfig('sccp_lang') as $lang_key => $lang_value) {\n $filename = $dir . DIRECTORY_SEPARATOR . $lang_value['locale'];\n if (!file_exists($filename)) {\n if (!mkdir($filename, 0777, true)) {\n die('Error create lang dir');\n }\n }\n }\n }", "public function displayDefaultMessageOutputEn()\n {\n // initialize the class with defaults (en_US locale, library path).\n $message = new CustomerMessage();\n\n // we expect the default message, because error 987.654.321 might not exist\n // in the default locale file en_US.csv.\n $this->assertEquals(\n 'An unexpected error occurred. Please contact us to get further information.',\n $message->getMessage('987.654.321')\n );\n }", "public function importInDev()\n\t{\n\t\t\\IPS\\cms\\Theme::importInDev('database');\n\t\t\\IPS\\cms\\Theme::importInDev('page');\n\n\t\t\\IPS\\Output::i()->redirect( \\IPS\\Http\\Url::internal( 'app=cms&module=pages&controller=templates' ), 'completed' );\n\t}" ]
[ "0.6216803", "0.56127864", "0.5544662", "0.5486809", "0.54813135", "0.5459752", "0.54052496", "0.5399836", "0.5373312", "0.5242309", "0.52074015", "0.51964444", "0.5156991", "0.5143614", "0.51185995", "0.51100606", "0.50956076", "0.50733966", "0.50690484", "0.5048539", "0.5024361", "0.50233746", "0.50228316", "0.50088227", "0.5005498", "0.5002669", "0.49993363", "0.49952406", "0.49940777", "0.4975224", "0.4963022", "0.49601677", "0.49589142", "0.49568176", "0.49252692", "0.49231976", "0.49223375", "0.49146423", "0.491044", "0.49054348", "0.49026456", "0.48892483", "0.48838112", "0.48831797", "0.48810825", "0.4875747", "0.48648056", "0.4858981", "0.4854153", "0.4846272", "0.48453498", "0.48297286", "0.48295724", "0.48290262", "0.48285168", "0.48248017", "0.48168308", "0.4813264", "0.4808658", "0.4789757", "0.4785869", "0.47751427", "0.47689107", "0.4764765", "0.47604904", "0.47604904", "0.47529942", "0.47486204", "0.4726314", "0.47236314", "0.4722199", "0.4721251", "0.47207448", "0.47195342", "0.47094724", "0.47082362", "0.47058105", "0.4703465", "0.4703376", "0.4702214", "0.47016177", "0.46989217", "0.46981975", "0.4694734", "0.469397", "0.46859598", "0.4682206", "0.46806517", "0.4673558", "0.4671087", "0.4670285", "0.46690866", "0.46631515", "0.46630695", "0.46614954", "0.4658316", "0.46480167", "0.46476942", "0.46467793", "0.46430084" ]
0.54528886
6
Step 2: translate to all languages defined in $langarr
public function trans($site_id,$k,$v) { $this->layout = false; $this->loadModel('Translation'); $trec = $this->Translation->findAllByLocale('en'); // pr($trec); die; foreach ($trec as $rec){ $tmprec = $this->Translation->find('all',array('conditions' => array('Translation.locale' =>$k,'Translation.msgid LIKE binary "'.addslashes($rec['Translation']['msgid']).'" '))); //pr($tmprec); die; if (count($tmprec) == 0) { $this->Translation->create(); $data['Translation']['msgstr'] = $this->translate($rec['Translation']['msgid'], 'en', $k); $data['Translation']['msgid'] = $rec['Translation']['msgid']; $data['Translation']['locale'] = $k; $data['Translation']['status'] = 'm'; //pr($data); die; $this->Translation->save($data); //$this->render('elements/sql_dump'); } } return 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function initializeLanguages() {}", "function doTranslate($file,$languages){\n\techo \"\\n\\n=============================\\n\";\n\techo \"Translating $file\\n\";\n\techo \"=============================\\n\";\n\t$filenamepart=explodeFile($file);\n\t$buffer=file_get_contents($file);\n\t//loop through the languages\n\tforeach ($languages as $key=>$lang){\n\t\techo \"-----------------------------\\n\";\n\t\techo \"Translating to language $key\\n\";\n\t\techo \"-----------------------------\\n\";\n\t\t$posR=0;\n\t\t$translated = \"\";\n\t\twhile (true){\n\t\t\t//find next occurence of a data-i18n attribute\n\t\t\t$pos1 = getNextDataI18N($buffer,$posR+1);\n\t\t\t\n\t\t\t//if there is no more occurence, there's nothing more to do; break this loop\n\t\t\tif ($pos1==false) {break;}\n\t\t\t\n\t\t\t//else extract the dataName from this attribute\n\t\t\t$pos2 = getNextQuote($buffer,$pos1+1);\n\t\t\t$dataName = getTextBetween($buffer,$pos1,$pos2);\n\t\t\n\t\t\t//append with text that comes before the string to be translated\n\t\t\t$posL = getNextGt($buffer,$pos2);\n\t\t\t$translated .= getTextBefore($buffer,$posR,$posL);\n\t\t\t\n\t\t\t//append with translation of said string\n\t\t\t$replaceText = getI18nText($dataName,$lang);\n\t\t\techo \"* $dataName=$replaceText\\n\";\t\n\t\t\t$translated .= $replaceText;\n\t\t\t\n\t\t\t//go to end of translated string\n\t\t\t$posR = getNextLt($buffer,$posL);\n\t\t\t$pos1 = $posR;\n\t\t\n\t\t}\n\t\t//append part of file after last translated string\n\t\t$translated .= substr($buffer,$posR,-1);// getTextAfter($buffer,$posR);\n\t\t\n\t\t//if language directory does not exist, create it\n\t\t$directory = $filenamepart[0].\"$key/\"; \n\t\tif (!is_dir($directory)) {\n\t\t\tmkdir($directory);\n\t\t\techo \"* created directory $directory\\n\";\n\t\t}\n\t\t\n\t\t//create file for language\n\t\t$newFile=$directory.$filenamepart[1];\n\t\tfile_put_contents($newFile,$translated);\n\t\t\n\t}\n}", "function _load_languages()\r\n\t{\r\n\t\t// Load the form validation language file\r\n\t\t$this->lang->load('form_validation');\r\n\r\n\t\t// Load the DataMapper language file\r\n\t\t$this->lang->load('datamapper');\r\n\t}", "public function translate();", "function update_translations()\n\t{\n\t\t$this->load->library('translator');\n\t\t\n\t\t//application language folder\n\t\t$language_folder=APPPATH.'language/';\n\t\t\n\t\t//template language \n\t\t$language='base';\n\t\t\n\t\t//path to the language folder\n\t\t$language_path=$language_folder.$language;\n\t\t\n\t\t//get a list of all translation files for the given language \n\t\t$files=$this->translator->get_language_files_array($language_path);\n\t\t\n\t\t//will be updated with additons from the BASE language file\n\t\t$target_language=$this->config->item(\"language\");\n\t\t\n\t\tif (!$target_language)\n\t\t{\n\t\t\techo \"language $target_language was not found\";\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tforeach($files as $file)\n\t\t{\n\t\t\t$target_filepath=$language_folder.'/'.$target_language.'/'.$file;\n\n\t\t\t//merge source and target language file to fill in missing translations for the target language\n\t\t\t$data['translations']=$this->translator->merge_language_keys($language_path.'/'.$file,$target_filepath);\n\t\t\t$data['language_name']=$target_language;\n\t\t\t$data['translation_file']=$file;\n\t\t\t\n\t\t\t//target language file content\n\t\t\t$content='<?php '.\"\\n\\n\".$this->load->view('translator/save',$data,TRUE);\n\t\t\t\n\t\t\t//update the target language file\n\t\t\t$save_result=@file_put_contents($target_filepath,$content);\n\t\t\t\n\t\t\tif($save_result)\n\t\t\t{\n\t\t\t\techo \"Language file updated: \" . $target_filepath.'<br />';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\techo \"<div style='color:red;'>Language file update failed: \" . $target_filepath.'</div>';\n\t\t\t}\n\t\t}\t\t\n\t}", "protected abstract function getTranslations();", "private static function localize(array &$arr)\n\t{\n\t\t$arr = isset($arr[LANG]) ? $arr[LANG] : $arr[0];\n\t}", "private function addLanguageMessage($messages_array, $message, $lang) {\n $current_messages = $messages_array;\n\n if ($lang === null) {\n $current_messages[\"en\"] = $message;\n } else {\n if (empty($current_messages[\"en\"])) {\n $current_messages[\"en\"] = $message;\n $current_messages[$lang] = $message;\n } else {\n $current_messages[$lang] = $message;\n }\n }\n\n return $current_messages;\n }", "public function translated();", "public function translated();", "function y_translate($text, $lang = \"en-ru\")\r\n{\r\n global $encoding;\r\n $save_encoding = @$encoding;\r\n $encoding = 'UTF-8';\r\n $url = 'http://translate.yandex.net/api/v1/tr.json/translate?format=html&lang=' . $lang . '&text=' . urlencode($text);\r\n for ($i=0;$i<5;$i++) {\r\n $result = json_decode(get($url), true);\r\n if (g('last_result')==200) break;\r\n }\r\n $encoding=$save_encoding;\r\n if ($result['code'] == 200) {\r\n $r = implode('<br />', $result['text']);\r\n } else $r = $text;\r\n\r\n if (DEV)\r\n xlogc('y_translate', $r, $text, $lang);\r\n\r\n return $r;\r\n}", "public function setTranslationsForLanguage(array $messages, $language);", "public function passo3() {\n $filename= 'f' . gmdate('YmdHis');\n foreach ($this->langarr as $k => $v):\n\n $path = ROOT.DS.'app'.DS.'locale'.DS.$v;\n if (!file_exists($path)) mkdir($path);\n \t$path .= DS.'LC_MESSAGES';\n if (!file_exists($path)) mkdir($path);\n \t$file = $path.DS.$filename;\n if (!file_exists($path)) touch($file);\n\n $file = new File($path.DS.$filename);\n $tmprec = $this->Traducao->find('all',array('conditions' => array('Traducao.locale' => $k)));\n foreach ($tmprec as $rec):\n $file->write('msgid \"' .$rec['Traducao']['msgid'] .'\"'.\"\\n\");\n $file->write('msgstr \"'.$rec['Traducao']['msgstr'].'\"'.\"\\n\");\n endforeach;\n $file->close();\n\n if (file_exists($path.DS.'default.po'))\n rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis'));\n\t \n rename ($path.DS.$filename,$path.DS.'default.po');\n endforeach;\n }", "public function getAllTranslationByLanguage();", "protected function getLanguages() {}", "function languages()\n\t{\n\t\t$this->ipsclass->input['step']++;\n\t\t$uninstall = ( $this->ipsclass->input['un'] == 1 ) ? \"&amp;un=1\" : \"\";\n\t\t\n\t\t$object = ( $this->tasks['languages'] == 1 ) ? 'Language String' : 'Language Strings';\n\t\t$operation = ( $this->ipsclass->input['un'] ) ? 'removed' : 'created';\n\t\t\n\t\t$api = $this->ipsclass->load_class( IPS_API_PATH.'/api_language.php', 'api_language' );\n\t\t$api->path_to_ipb = ROOT_PATH;\n\t\t$api->api_init();\n\t\t\n\t\tforeach ( $this->xml_array['languages_group']['language'] as $k => $v )\n\t\t{\n\t\t\tif ( !$this->ipsclass->input['un'] )\n\t\t\t{\n\t\t\t\t$api->lang_add_strings( array( $v['key']['VALUE'] => $v['text']['VALUE'] ), $v['file']['VALUE'] );\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tforeach ( $this->ipsclass->cache['languages'] as $kk => $vv )\n\t\t\t\t{\n\t\t\t\t\t$lang = array();\n\t\t\t\t\trequire( CACHE_PATH.'cache/lang_cache/'.$vv['ldir'].'/'.$v['file']['VALUE'].'.php' );\n\t\t\t\t\t\n\t\t\t\t\tunset( $lang[ $v['key']['VALUE'] ] );\n\t\t\t\t\t\n\t\t\t\t\t$start = \"<?php\\n\\n\".'$lang = array('.\"\\n\";\n\t\t\t\t\t\n\t\t\t\t\tforeach ( $lang as $kkk => $vvv )\n\t\t\t\t\t{\n\t\t\t\t\t\t$vvv = preg_replace( \"/\\n{1,}$/\", \"\", $vvv );\n\t\t\t\t\t\t$vvv \t= stripslashes( $vvv );\n\t\t\t\t\t\t$vvv\t= preg_replace( '/\"/', '\\\\\"', $vvv );\n\t\t\t\t\t\t$start .= \"\\n'\".$kkk.\"' => \\\"\".$vvv.\"\\\",\";\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$start .= \"\\n\\n);\\n\\n?\".\">\";\n\t\t\t\t\t\n\t\t\t\t\tif ( $fh = @fopen( CACHE_PATH.'cache/lang_cache/'.$vv['ldir'].'/'.$v['file']['VALUE'].'.php', 'w' ) )\n\t\t\t\t\t{\n\t\t\t\t\t\t@fwrite( $fh, $start );\n\t\t\t\t\t\t@fclose( $fh );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tunset( $lang, $start, $fh );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t$this->ipsclass->admin->redirect( \"{$this->ipsclass->form_code}&amp;code=work&amp;mod={$this->ipsclass->input['mod']}&amp;step={$this->ipsclass->input['step']}{$uninstall}&amp;st={$this->ipsclass->input['st']}\", \"{$this->xml_array['mod_info']['title']['VALUE']}<br />{$this->tasks['languages']} {$object} {$operation}....\" );\n\t}", "public function loadTranslations()\n {\n $oTranslation = new Translation($this->sLang, $this->sBundleName);\n $this->aView[\"lang\"] = $this->sLang;\n $this->aView[\"tr\"] = $oTranslation->getTranslations();\n }", "protected static function setLanguageKeys() {}", "abstract protected function translator();", "function forum_lang( $old_lang ){\n\n\t$loc = HOME . '_plugins/Forum/lang/';\n\tif( file_exists( $loc . LANG . '.php' ) )\n\t\trequire $loc . LANG . '.php';\n\telse\n\t\trequire $loc . 'English.php';\n\n\treturn array_merge( $old_lang, $lang );\n}", "protected function _getInverseLangCodesMapping()\n {\n $oLang = \\OxidEsales\\Eshop\\Core\\Registry::getLang();\n $aLanguages = $oLang->getLanguageArray();\n $aRetArray = array();\n foreach ($aLanguages as $aLanguage) {\n $aRetArray[$aLanguage->id] = $aLanguage->oxid;\n }\n return $aRetArray;\n }", "protected function _initTranslate() {\n\t\t$translate = new Zend_Translate('array',\n\t\t\tAPPLICATION_PATH . '/langs',\n\t\t\tnull,\n\t\t\tarray('scan'=>Zend_Translate::LOCALE_FILENAME)\n\t\t\t);\n\t\t$registry = Zend_Registry::getInstance();\n\t\t$registry->set('Zend_Translate',$translate);\n\t\t// This is assigned by the initLocale on the fly based on browser language\n\t\t//$translate->setlocale('en_US');\n\t}", "public function settingLanguage() {}", "public function languages();", "public function getSystemLanguages() {}", "public function translateMany($word, $source_lang, $dest_lang, $max=10){\n\t\t\t\n\t\t\t$paramArr = array (\n\t\t\t\t\t\t\t\t\t 'text'\t\t\t\t=> $word,\n\t\t\t\t\t\t\t\t\t 'from'\t\t\t\t=> $source_lang,\n\t\t\t\t\t\t\t\t\t 'to'\t\t\t\t=> $dest_lang,\n\t\t\t\t\t\t\t\t\t 'maxTranslations'\t=> $max\n );\n\t\t\t$paramArr = http_build_query($paramArr);\n\n\t\t\t$this->http->setURL($this->url.$this->apiUrl.$this->getMode(\"translates\").\"?\".$paramArr);\n\t\t\t$response = $this->http->send(FALSE);\n\n\t\t\t//$this->out($response);\n\n\t\t\tpreg_match_all('@\"TranslatedText\":\"(.*?)\"@i', $response, $matches, PREG_OFFSET_CAPTURE);\n\t\t\t$string = NULL;\n\n\t\t\tforeach ($matches[1] as $val)\n\t\t\t\t$string .= strtolower($val[0]).\",\";\n\n\t\t\t$string = substr($string, 0, -1);\n\n\t\t\treturn array_unique($this->synsetFilter(explode(\",\", $string)));\n\n\t\t\t//return $response;\n\n\t\t}", "public function getSystemLanguages() {}", "public\tfunction passo2() {\n\n $trec = $this->Traducao->findAllByLocale($this->defaultLang);\n foreach ($trec as $rec):\n foreach ($this->langarr as $k => $v):\n $tmprec = $this->Traducao->find('all',array('conditions' => array('Traducao.locale' => $k,'Traducao.msgid'=> $rec['Traducao']['msgid'])));\n if (count($tmprec) == 0) {\n $this->data['Traducao']['msgstr'] = $this->Traduzir->translate($rec['Traducao']['msgid'], $this->defaultLang, $k);\n $this->data['Traducao']['msgid'] = $rec\n['Traducao']['msgid'];\n $this->data['Traducao']['locale'] = $k;\n $this->data['Traducao']['status'] = 'm';\n $this->Traducao->save($this->data);\n }\n endforeach;\n\n endforeach;\n }", "public function synchTranslations() {\n\t\t//header('Content-type: text/html; charset=utf-8');\n\t\t$player = User::getUser();\n\t\t$lang = $this->params['lang'];\n\n\t\t//ONLY English!\n\t\t$lang = \"EN\";\n\t\tif (!$player or $player->canAccess('Super Admin Interface') !== TRUE or strlen($lang) != 2) {\n\t\t\tDooUriRouter::redirect(Doo::conf()->APP_URL);\n\t\t\treturn false;\n\t\t}\n\n\t\t$file_names = array();\n\t\t$path = Doo::conf()->SITE_PATH . 'protected';\n\t\tExternalController::scanFileNameRecursivly($path, $file_names);\n\n\t\t//$translator = Doo::translator('Csv', Doo::conf()->SITE_PATH . 'protected/lang/' . $lang . '/' . $lang . //'.csv');\n\t\t$translator = Doo::translator('database', $lang);\n\n\t\t$fileResult = array();\n\n\t\tforeach ($file_names as $file) {\n\n\t\t\tif (file_exists($file)) {\n\n\t\t\t\t$content = file_get_contents($file);\n\n\t\t\t\t$clen = strlen($content);\n\n\t\t\t\t$pos = 0;\n\t\t\t\twhile ($pos = strpos($content, 'this'.'->__(', $pos))\n\t\t\t\t{\n\t\t\t\t\tif ($pos)\n\t\t\t\t\t{\n\t\t\t\t\t\t//Get ''\n\t\t\t\t\t\tif ($content[$pos+9]==\"'\")\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$res = \"\";\n\t\t\t\t\t\t\t$pos1 = strpos($content, \"'\", $pos+1);\n\t\t\t\t\t\t\t$pos2 = strpos($content, \"'\", $pos1+1);\n\n\t\t\t\t\t\t\tfor ($i=$pos1+1;$i<$pos2;$i++)\n\t\t\t\t\t\t\t\t$res .= $content[$i];\n\t\t\t\t\t\t\t$fileResult[] = $res;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//Get \"\"\n\t\t\t\t\t\tif ($content[$pos+9]=='\"')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$res = \"\";\n\t\t\t\t\t\t\t$pos1 = strpos($content, '\"', $pos+1);\n\t\t\t\t\t\t\t$pos2 = strpos($content, '\"', $pos1+1);\n\n\t\t\t\t\t\t\tfor ($i=$pos1+1;$i<$pos2;$i++)\n\t\t\t\t\t\t\t\t$res .= $content[$i];\n\t\t\t\t\t\t\t$fileResult[] = $res;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$pos++;\n\t\t\t\t}\n\n\t\t\t\t// Check for snController - used when this can not be used\n\t\t\t\t$pos = 0;\n\t\t\t\twhile ($pos = strpos($content, 'snController'.'->__(', $pos))\n\t\t\t\t{\n\t\t\t\t\tif ($pos)\n\t\t\t\t\t{\n\t\t\t\t\t\t//Get ''\n\t\t\t\t\t\tif ($content[$pos+17]==\"'\")\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$res = \"\";\n\t\t\t\t\t\t\t$pos1 = strpos($content, \"'\", $pos+1);\n\t\t\t\t\t\t\t$pos2 = strpos($content, \"'\", $pos1+1);\n\n\t\t\t\t\t\t\tfor ($i=$pos1+1;$i<$pos2;$i++)\n\t\t\t\t\t\t\t\t$res .= $content[$i];\n\t\t\t\t\t\t\t$fileResult[] = $res;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//Get \"\"\n\t\t\t\t\t\tif ($content[$pos+17]=='\"')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$res = \"\";\n\t\t\t\t\t\t\t$pos1 = strpos($content, '\"', $pos+1);\n\t\t\t\t\t\t\t$pos2 = strpos($content, '\"', $pos1+1);\n\n\t\t\t\t\t\t\tfor ($i=$pos1+1;$i<$pos2;$i++)\n\t\t\t\t\t\t\t\t$res .= $content[$i];\n\t\t\t\t\t\t\t$fileResult[] = $res;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t$pos++;\n\t\t\t\t}\n\n\t\t\t} else {\n\t\t\t\techo \"No file\";\n\t\t\t}\n\t\t}\n $fileResult = array_unique($fileResult);\n //Fetch and compare texts from database with collected fileresults to find unused texts and delete them\n if (!empty($fileResult)) {\n echo \"TRANSLATION KEY DELETION: <br/><br/>\";\n\n $dRows = 0;\n $screentexts = new GeScreenTexts();\n $params['select'] = \"{$screentexts->_table}.ID_TEXT, {$screentexts->_table}.TransKey\";\n $dbKeys = Doo::db()->find('GeScreenTexts', $params);\n foreach($dbKeys as $text) {\n $key = array_search($text->TransKey, $fileResult);\n // If key isn't used, delete it\n if(!$key) {\n $query = \"DELETE FROM ge_screentexts WHERE ID_TEXT={$text->ID_TEXT}\";\n echo \"Deleted: $text->TransKey<br/>\";\n Doo::db()->query($query);\n $dRows++;\n }\n }\n echo \"$dRows keys deleted<br/><br/>\";\n }\n\n\t\t//Loop thru the collected fileresults and find new untranslated texts and insert them\n\t\tif (!empty($fileResult)) {\n\t\t\techo \"FILE TRANSLATION: <br/><br/>\";\n\n\t\t\t$nRows = 0;\n\t\t\tforeach ($fileResult as $item)\n\t\t\t{\n\t\t\t\t$query = \"SELECT COUNT(*) as n FROM ge_screentexts WHERE TransKey=\" .'\"' . $item . '\"';\n\n\t\t\t\t$o = (object)Doo::db()->fetchRow($query);\n\t\t\t\t$n = $o->n;\n\n\t\t\t\tif ($n==0)\n\t\t\t\t{\n\t\t\t\t\t$query = \"INSERT INTO ge_screentexts\".\n\t\t\t\t\t\t\t \"(TransKey,TransTextEN,TransTextDA,TransTextDE,TransTextFR,TransTextES,TransTextRO,TransTextLT,TransTextBG,\".\n\t\t\t\t\t\t\t \"TransTextNL,TransTextEL,TransTextTR,TransTextZH,TransTextIS,TransTextBR,TransTextTH,TransTextPT,TransTextRU,\".\n\t\t\t\t\t\t\t \"TransTextPL,TransTextFI,TransTextFA,TransTextDR,TransTextNO,TransTextSE,TransTextHU,TransTextAR,TransTextET)\".\n\t\t\t\t\t\t\t \"VALUES (\".'\"'.$item.'\",\"'.$item.'\"'.\",'','','','','','','','','','','','','','','','','','','','','','','','','')\";\n\t\t\t\t\techo \"New: $item<br/>\";\n\t\t\t\t\tDoo::db()->query($query);\n\t\t\t\t\t//echo \" - $query<br/>\";\n\t\t\t\t\t$nRows++;\n\t\t\t\t}\n\n\t\t\t}\n\t\t\techo \"$nRows new rows added<br/>\";\n\t\t}\n\n\n\t\techo \"<p>Synch translations done</p>\";\n\t\texit;\n\n\t}", "function wp_load_translations_early()\n {\n }", "function pnLangLoad()\n{\n\t// See if a language update is required\n $newlang = pnVarCleanFromInput('newlang');\n if (!empty($newlang)) {\n $lang = $newlang;\n pnSessionSetVar('lang', $newlang);\n } else {\n $detectlang = pnConfigGetVar('language_detect');\n $defaultlang = pnConfigGetVar('language');\n\n switch ($detectlang) { \n case 1: // Detect Browser Language\n\t\t $cnvlanguage=cnvlanguagelist();\n $currentlang='';\n \t $langs = preg_split ('/[,;]/',$_SERVER['HTTP_ACCEPT_LANGUAGE']);\n \t foreach ($langs as $lang) {\n \t \t if (isset($cnvlanguage[$lang]) && file_exists('language/' . pnVarPrepForOS($cnvlanguage[$lang]) . '/global.php')) {\n \t \t $currentlang=$cnvlanguage[$lang];\n \t \t break;\n \t \t }\n \t }\n if ($currentlang=='')\n \t $currentlang=$defaultlang;\n \t \t break;\n default:\n $currentlang=$defaultlang; \n }\n $lang = pnSessionGetVar('lang');\n }\n \n // Load global language defines\n\t// these are deprecated and will be moved to the relevant modules\n\t// with .8x\n if (isset ($lang) && file_exists('language/' . pnVarPrepForOS($lang) . '/global.php')) {\n $currentlang = $lang;\n } else {\n $currentlang = pnConfigGetVar('language');\n pnSessionSetVar('lang', $currentlang);\n }\n\t$oscurrentlang = pnVarPrepForOS($currentlang);\n\tif (file_exists('language/' . $oscurrentlang . '/global.php')) {\n\t include 'language/' . $oscurrentlang . '/global.php';\n\t}\n\n\t// load the languge language file\n\tif (file_exists('language/languages.php')) {\n\t\tinclude 'language/languages.php';\n\t}\n\n\t// load the core language file\n\tif (file_exists('language/' . $oscurrentlang . '/core.php')) {\n\t\tinclude 'language/' . $oscurrentlang . '/core.php';\n\t}\n\n\t// V4B RNG\n\tif (file_exists('language/' . $oscurrentlang . '/v4blib.php')) {\n\t\tinclude 'language/' . $oscurrentlang . '/v4blib.php';\n\t}\n\t// V4B RNG\n\n\t// set the correct locale\n\t// note: windows has different requires for the setlocale funciton to other OS's\n\t// See: http://uk.php.net/setlocale\n\tif (stristr(getenv('OS'), 'windows')) {\n\t\t// for windows we either use the _LOCALEWIN define or the existing language code\n\t\tif (defined('_LOCALEWIN')) {\n\t\t\tsetlocale(LC_ALL, _LOCALEWIN);\n\t\t} else {\n\t\t\tsetlocale(LC_ALL, $currentlang);\n\t\t}\n\t} else {\n\t\t// for other OS's we use the _LOCALE define\n\t\tsetlocale(LC_ALL, _LOCALE);\n\t}\n}", "public function generateLanguages()\n {\n $files = FileLibrary::get();\n $fLang = Lang::getFallback();\n\n foreach ($files as $file) {\n foreach (Lang::allLocales() as $lang => $langName) {\n if (!isset($file->languages[$lang])) {\n $language = array_except($file->languages[$fLang]->toArray(), 'lang_id');\n $language['lang'] = $lang;\n $language = FileLibraryLanguage::create($language);\n echo '- File ID: ' . $language->file_id . ', Lang: ' . $language->lang . '<br>';\n }\n }\n }\n }", "function lang_switcher(){\n\tif (function_exists('icl_get_languages')) {\n\t\t$langs = icl_get_languages('skip_missing=0');\n\t\tforeach ($langs as $lang) {\n\t\t\tif ($lang['active'] == 0) {\n\t\t\t\t$flag = preg_replace(' ', '', $lang['country_flag_url']);\n\t\t\t\t$display_lang = ($lang['native_name'] == 'עברית') ? \"עבר\" : ucfirst($lang['native_name']);\n\t\t\t $strlang = mb_substr($display_lang,0,3);\n\t\t\t\techo '<a class=\"lang-switcher lang-switch\" href=\"'. $lang['url'] .'\">'.'<span class=\"dropdown-item d-inline-block\"></span><img src=\"'. $lang['country_flag_url'] . '\"></a>';\n\t\t\t}\n\t\t}\n\t}\n}", "private static function translator()\n {\n $files = ['Lang', 'Smiley'];\n $folder = static::$root.'Translator'.'/';\n\n self::call($files, $folder);\n\n $files = ['LanguageKeyNotFoundException', 'LanguageNotSupportedException'];\n $folder = static::$root.'Translator/Exceptions'.'/';\n\n self::call($files, $folder);\n }", "function getLang($index,$params) {\t\n\t\tglobal $lang;\n\t\t\n\t\t$output = $lang[$index];\n\t\t\n\t\tforeach ($params as $key => $value) {\n\t\t\t$output = str_replace('%'.$key.'%',$value,$output);\n\t\t}\n\t\t\n\t\treturn $output;\n\t}", "protected function generateLocalLang() {}", "function loadTranslations($results,$name){\n $this->Session = new CakeSession(); \n $i18nPostfix = $this->Session->read(\"Config.language\");\n// $this->log(\"loadTranslations Called by \" . $name,LOG_DEBUG); \n if ($i18nPostfix === \"\") return $results;\n foreach($results as $key => $val){\n if(!empty ($val[$name])){\n foreach ($val[$name] as $innerKey => $innerVal){\n if(substr($innerKey,-1*strlen($i18nPostfix))==$i18nPostfix){\n $default_eng = substr($innerKey,0,-1*strlen($i18nPostfix) - 1);\n if(!isset($results[$key][$name][$innerKey])&& isset($results[$key][$name][$default_eng]))\n $results[$key][$name][$default_eng] = \"<b>(Translation not found)</b> \" . $results[$key][$name][$default_eng];\n else \n $results[$key][$name][$default_eng] = $results[$key][$name][$innerKey];\n }\n }\n }\n }\n return $results;\n }", "function lang()\n\t{\n\t\t$args = func_get_args();\n\t\tif (is_array($args) && count($args) == 1 && is_array($args[0]))\n\t\t\t$args = $args[0];\n\t\treturn CmsLanguage::translate($args[0], array_slice($args, 1), $this->get_name(), '', $this->default_language());\n\t}", "public function create_new_lang()\n {\n $root_directory = FCPATH.\"application/language/\";\n $scan_root_directory = array_diff(scandir($root_directory),array('.','..'));\n $data['root_dir'] = $scan_root_directory;\n\n // Application Languages\n $directory = FCPATH.\"application/language/english\";\n $file_lists = scandir($directory,0);\n $total_file = count($file_lists);\n $language_Files = array();\n\n for($i = 2; $i< $total_file; $i++) \n {\n array_push($language_Files, $file_lists[$i]);\n }\n\n for ($i = 0; $i < count($language_Files); $i++) \n {\n $file_name = $language_Files[$i];\n include FCPATH.\"application/language/english/\".$file_name;\n $data['file_name'][$i] = $file_name;\n }\n\n // datatables plugins language\n $directory2 = FCPATH.\"assets/modules/datatables/language/english.json\";\n $plugin_file = file_get_contents($directory2);\n $plugin_file_contents = json_decode($plugin_file,TRUE);\n\n $lang = array();\n\n foreach ($plugin_file_contents as $key => $value) \n {\n if($key == \"oPaginate\")\n {\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n\n } else if ($key =='oAria') {\n\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n } else {\n $lang[$key] = $value;\n\n } \n }\n\n\n // Addon Language\n $addon_directory = FCPATH.\"application/modules/\";\n $scan_directory = scandir($addon_directory,0);\n $addon_files = array();\n\n for ($i = 2; $i < count($scan_directory) ; $i++) \n {\n array_push($addon_files, $scan_directory[$i]);\n }\n\n $addon_lang_folder = array();\n for ($i = 0; $i < count($addon_files); $i++) \n {\n $module_directory = FCPATH.\"application/modules/\".$addon_files[$i].\"/language\";\n if(file_exists($module_directory))\n {\n $scan_module_directories = array_diff(scandir($module_directory),array('.','..'));\n if(!empty($scan_module_directories))\n {\n $addon_name = $addon_directory.$addon_files[$i];\n array_push($addon_lang_folder,$addon_name);\n }\n }\n }\n\n\n $addon_dir_arr = array();\n for ($i = 0; $i < count($addon_lang_folder); $i++) \n {\n $addon_lang_file = $addon_lang_folder[$i];\n $addon_lang_file_dir = $addon_lang_file.\"/language/english/\";\n $addon_lang_file_dir_scan[] = scandir($addon_lang_file_dir,1);\n array_push($addon_dir_arr,$addon_lang_file_dir_scan[$i][0]);\n }\n $data['addons'] = $addon_dir_arr;\n\n $data['body'] = 'admin/multi_language/add_language';\n $data['page_title'] = $this->lang->line(\"New Language\");\n $this->_viewcontroller($data);\n }", "public function get_desired_languages();", "private function translations()\n {\n $this['translator'] = $this->share($this->extend('translator', function ($translator) {\n $translator->addLoader('yaml', new TranslationFileLoader());\n\n $translator->addResource('yaml', 'config/locales/pt-br.yml', 'pt-br');\n $translator->addResource('yaml', 'config/locales/en-us.yml', 'en-us');\n $translator->addResource('yaml', 'config/locales/es-es.yml', 'es-es');\n\n return $translator;\n }));\n }", "function icl_post_languages(){\n\t$languages = icl_get_languages('skip_missing=0');\n\t if(1 < count($languages)){\n\t\t \t$langs[] = '<div class=\"language-but\">\n\t\t\t\t\t<button type=\"button\" class=\"info-lnk\">\n\t\t\t\t\t\t<img class=\"icon\" src=\"' . THEME_DIR .'/images/arrow1.png\" width=\"17\" height=\"16\" alt=\"\" />\n\t\t\t\t\t\t<span class=\"txt\">' . ICL_LANGUAGE_NAME .'</span>\n\t\t\t\t\t\t<strong class=\"clear\"></strong>\n\t\t\t\t\t</button>';\n\t\t foreach($languages as $l){\n\t\t \t//print_r($l);\n\t\t \t$class= '';\n\t\t \tif($l['active'] == 1) {\n\t\t \t\t$class = 'active';\n\t\t \t}\n\t\t $langs[] = '<a href=\"'.$l['url'].'\" class=\"langsBtns\">'. ucfirst($l['native_name']) .'</a>';\n\t\t }\n\n\n\t\t $langs[] = '</div>';\n\t echo join('', $langs);\n\t }\n\t}", "private function initSysLanguages(){\n/*\n\tmod.SHARED {\n\t\tdefaultLanguageFlag = de.gif\n\t\tdefaultLanguageLabel = german\n\t}\t\n*/\t\n\t\t$modSharedTSconfig = t3lib_BEfunc::getModTSconfig( $this->settings['pageUid'], 'mod.SHARED');\n\n\t\t// fallback non sprite-configuration\n\t\tif (preg_match('/\\.gif$/', $modSharedTSconfig['properties']['defaultLanguageFlag'])) {\n\t\t\t$modSharedTSconfig['properties']['defaultLanguageFlag'] = str_replace('.gif', '', $modSharedTSconfig['properties']['defaultLanguageFlag']);\n\t\t}\n\n\n\t\t$this->sysLanguages = array(\n\t\t\t0=>array(\n\t\t\t\t'title' => strlen($modSharedTSconfig['properties']['defaultLanguageLabel']) ? $modSharedTSconfig['properties']['defaultLanguageLabel'].' ('.$GLOBALS['LANG']->sl('LLL:EXT:lang/locallang_mod_web_list.xml:defaultLanguage').')' : $GLOBALS['LANG']->sl('LLL:EXT:lang/locallang_mod_web_list.xml:defaultLanguage'),\n\t\t\t\t'flag' => $modSharedTSconfig['properties']['defaultLanguageFlag'],\n\t\t\t)\n\t\t);\n\t\t$result = $GLOBALS['TYPO3_DB']->exec_SELECTquery ( 'uid,title,flag',\n\t\t\t'sys_language', '', '', '' );\n\t\twhile ($r = $GLOBALS['TYPO3_DB']->sql_fetch_assoc ($result)) {\n\t\t\t$this->sysLanguages[ $r['uid'] ] = $r;\n\t\t}\n\t}", "function translate($sKey, $sLang = null);", "function yourls_translate( $text, $domain = 'default' ) {\n\t$translations = yourls_get_translations_for_domain( $domain );\n\treturn yourls_apply_filter( 'translate', $translations->translate( $text ), $text, $domain );\n}", "public function setYiiLang(){\r\n $get_lang = Yii::app()->getRequest()->getParam(Yii::app()->urlManager->languageParam);//check if we have lang in url\r\n if (!in_array($get_lang,array_keys(Yii::app()->params['translatedLanguages'])) &&\r\n isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\r\n $langList = Util::sortByPriority($_SERVER['HTTP_ACCEPT_LANGUAGE']);\r\n foreach ($langList as $lang => $quality) {\r\n foreach (Defaults::$supportedLanguages as $supported) {\r\n if (strcasecmp($supported, $lang) == 0) {\r\n Yii::app()->language = $supported;\r\n break 2;\r\n }\r\n }\r\n }\r\n }\r\n }", "public function fixHreflang()\n {\n global $config, $languages, $listing_data, $currentPage;\n\n if (!$config['mf_geo_subdomains'] || !$config['mod_rewrite'] || count($languages) == 1) {\n return;\n }\n\n $hreflang = array();\n $url = RL_URL_HOME . $currentPage;\n\n foreach ($languages as $lang_item) {\n $lang_code = $lang_item['Code'] == $config['lang'] ? '' : $lang_item['Code'];\n\n if ($this->detailsPage) {\n $hreflang[$lang_item['Code']] = $this->buildListingUrl($url, $listing_data, $lang_code);\n } else {\n $hreflang[$lang_item['Code']] = $this->makeUrlGeo($url, $lang_code);\n }\n }\n\n $GLOBALS['rlSmarty']->assign('hreflang', $hreflang);\n }", "public static function getSystemLanguages() {}", "public function lang($lang = null);", "public function initLocalization() {\n $moFiles = scandir(trailingslashit($this->dir) . 'languages/');\n foreach ($moFiles as $moFile) {\n if (strlen($moFile) > 3 && substr($moFile, -3) == '.mo' && strpos($moFile, get_locale()) > -1) {\n load_textdomain('WP_Visual_Chat', trailingslashit($this->dir) . 'languages/' . $moFile);\n }\n }\n }", "private function initLangs()\n {\n $langs = $this->getLangs();\n if (!$langs) {\n return;\n }\n\n // If the lang is set in query parameters...\n if (array_key_exists(self::LANG_KEY, $this->query)) {\n // ... and it is valid -> change the current language.\n // Yes, we are violating semantics of GET request here, but the operation is idempotent.\n if (in_array($this->query[self::LANG_KEY], $langs)) {\n $this->currentLang = $this->query[self::LANG_KEY];\n setcookie(self::LANG_KEY, $this->currentLang);\n }\n\n // Remove the lang from query parameters and redirect to self...\n unset($this->query[self::LANG_KEY]);\n $url = $this->rawPath;\n if ($this->query) {\n $url .= '?' . http_build_query($this->query);\n }\n header(\"Location: $url\");\n exit;\n }\n\n if (array_key_exists(self::LANG_KEY, $_COOKIE) && in_array($_COOKIE[self::LANG_KEY], $langs)) {\n // If the lang is set in cookies ...\n $this->currentLang = $_COOKIE[self::LANG_KEY];\n } elseif (($httpLang = $this->getLangFromHTTP()) !== null) {\n // Try to get the language from Accept-Language HTTP header...\n $this->currentLang = $httpLang;\n } elseif (in_array('en', $langs)) {\n // English is prefered default...\n $this->currentLang = 'en';\n } else {\n // If everything fails, get first lang of the config...\n $this->currentLang = reset($langs);\n }\n }", "private function load(): void\n {\n $paths = $this->getPaths();\n\n $this->locales['app'] = $this->loadTranslations($paths['app']);\n\n foreach ($paths['vendors'] as $path) {\n $this->locales['vendor-php'] = $this->loadTranslations($path);\n $this->locales['vendor-json'] = $this->loadJsonTranslations($path);\n }\n }", "public static function loadLang() {\n\t\tif (!is_object($GLOBALS['LANG'])) {\n\n\t\t\trequire_once t3lib_extMgm::extPath('lang') . 'lang.php';\n\t\t\t//TODO see pt_tool smarty!\n\t\t\t$GLOBALS['LANG'] = t3lib_div::makeInstance('language');\n\t\t\t$GLOBALS['LANG']->csConvObj = t3lib_div::makeInstance('t3lib_cs');\n\t\t}\n\t\tif (is_object($GLOBALS['TSFE']) && $GLOBALS['TSFE']->config['config']['language']) {\n\t\t\t$LLkey = $GLOBALS['TSFE']->config['config']['language'];\n\t\t\t$GLOBALS['LANG']->init($LLkey);\n\t\t}\n\n\t}", "public function incLocalLang() {}", "function getLanguages($langList){\n\t$languages = array();\n\tforeach ($langList as $lang){\n\t\t$json=file_get_contents (\"FINAL/locales/translation-$lang.json\");\n\t\t//we want an associative array, thus second parameter is true\n\t\t$languages[$lang] = json_decode($json,true);\n\t\t//print_r($obj);\n\t}\n\treturn $languages;\n}", "public function getLanguages() {}", "protected function setupLanguages()\n {\n static $done;\n\n if (!empty($done)) {\n return;\n }\n\n $l = new Languages();\n $l->setName('Danish');\n $l->setLocalName('Dansk');\n $l->setLocale('da_DK');\n $l->setIso2('da');\n $l->setDirection('ltr');\n $l->save();\n\n $done = true;\n }", "protected function getTranslateTools() {}", "function update_translation($postdata,$id) {\r\n\r\n foreach($postdata as $lang => $val){\r\n\t\t if(array_filter($val)){\r\n\t\t $title = $val['title'];\r\n\r\n $transAvailable = $this->getBackTranslation($lang,$id);\r\n\r\n if(empty($transAvailable)){\r\n $data = array(\r\n 'trans_title' => $title,\r\n 'trans_extras_id' => $id,\r\n 'trans_lang' => $lang\r\n\r\n );\r\n\t\t\t\t$this->db->insert('pt_extras_translation', $data);\r\n\r\n }else{\r\n\r\n $data = array(\r\n 'trans_title' => $title,\r\n );\r\n\t\t\t\t$this->db->where('trans_extras_id', $id);\r\n\t\t\t\t$this->db->where('trans_lang', $lang);\r\n\t\t\t $this->db->update('pt_extras_translation', $data);\r\n\r\n }\r\n\r\n\r\n }\r\n\r\n }\r\n\t\t}", "function saveTranslations()\n {\n // default language set?\n if (!isset($_POST[\"default\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_no_default_language\"));\n return $this->editTranslations(true);\n }\n\n // all languages set?\n if (array_key_exists(\"\",$_POST[\"lang\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_no_language_selected\"));\n return $this->editTranslations(true);\n }\n\n // no single language is selected more than once?\n if (count(array_unique($_POST[\"lang\"])) < count($_POST[\"lang\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_multi_language_selected\"));\n return $this->editTranslations(true);\n }\n\n // save the stuff\n $this->ilObjectOrgUnit->removeTranslations();\n foreach($_POST[\"title\"] as $k => $v)\n {\n // update object data if default\n $is_default = ($_POST[\"default\"] == $k);\n if($is_default)\n {\n $this->ilObjectOrgUnit->setTitle(ilUtil::stripSlashes($v));\n $this->ilObjectOrgUnit->setDescription(ilUtil::stripSlashes($_POST[\"desc\"][$k]));\n $this->ilObjectOrgUnit->update();\n }\n\n $this->ilObjectOrgUnit->addTranslation(\n ilUtil::stripSlashes($v),\n ilUtil::stripSlashes($_POST[\"desc\"][$k]),\n ilUtil::stripSlashes($_POST[\"lang\"][$k]),\n $is_default);\n }\n\n ilUtil::sendSuccess($this->lng->txt(\"msg_obj_modified\"), true);\n $this->ctrl->redirect($this, \"editTranslations\");\n }", "public static function loadLanguages()\n\t{\n\t\tself::$_LANGUAGES = array();\n\t\t$result = Db::getInstance()->ExecuteS('SELECT * FROM `'._DB_PREFIX_.'Language`');\n\t\tforeach ($result AS $row)\n\t\t\tself::$_LANGUAGES[(int)$row['LanguageId']] = $row;\n\t}", "public static function getTranslations(array $strings) {\n $r = [];\n foreach ($strings as $string) {\n $r[$string] = lang::get($string);\n }\n return $r;\n }", "function gTranslate($text,$langOriginal,$langFinal){\n\t\t//Si los idiomas son iguales no hago nada\n\t\tif($langOriginal != $langFinal){\n\t\t/* Definimos la URL de la API de Google Translate y metemos en la variable el texto a traducir */\n\t\t$url = 'http://ajax.googleapis.com/ajax/services/language/translate?v=1.0&q='.urlencode($text).'&langpair='.$langOriginal.'|'.$langFinal;\n\t\t// iniciamos y configuramos curl_init();\n\t\t$curl_handle = curl_init();\n\t\tcurl_setopt($curl_handle,CURLOPT_URL, $url);\n\t\tcurl_setopt($curl_handle,CURLOPT_CONNECTTIMEOUT,2);\n\t\tcurl_setopt($curl_handle,CURLOPT_RETURNTRANSFER,1);\n\t\t$code = curl_exec($curl_handle);\n\t\tcurl_close($curl_handle);\n\t\t/* La api nos devuelve los resultados en forma de objeto stdClass */\t\n\t\t$json \t\t= json_decode($code)->responseData;\n \t $traduccion = utf8_decode($json->translatedText);\n\t\treturn utf8_decode($traduccion);\n\t\t}else{\n\t\t\treturn $text;\n\t\t}\n\t}", "public function getMultilingual();", "private function autoTranslate()\n {\n $translationServices = $this->manager->getAutomaticTranslationServices();\n $translationService = new $translationServices[$this->choice('Which automatic translation provider should be used?',\n array_keys($translationServices), 0)]();\n if (!in_array($this->manager->getDefaultLocale(), $translationService->getAvailableLocales())) {\n $this->warn('Provider '.class_basename($translationService).' doesn\\'t support locale \"'.$this->manager->getDefaultLocale().'\"');\n\n return;\n }\n\n $translationLocale = $this->ask('In which language do you want to translate?', 'en');\n if (!in_array($translationLocale, $translationService->getAvailableLocales())) {\n $this->warn('Provider '.class_basename($translationService).' doesn\\'t support locale \"'.$translationLocale.'\"');\n\n return;\n }\n\n $translationValues = $this->manager->getUntranslatedValues(\n $this->manager->getDefaultLocale(),\n $translationLocale\n );\n if (!$this->confirm('This translation costs $'.$translationService->calculateCosts($translationValues).' Do you want to continue?')) {\n return;\n }\n\n $this->info('Translating values...');\n $progress = $this->output->createProgressBar(count($translationValues));\n\n $translatedLocaleValues = [];\n foreach ($translationValues as $name => $localeString) {\n $translatedLocaleValues[$translationLocale][$name] = $translationService->translate(\n $this->manager->getDefaultLocale(),\n $translationLocale,\n $localeString\n );\n $progress->advance();\n }\n $progress->finish();\n echo \"\\r\\n\";\n\n $this->info('Write values');\n $this->manager->write($translatedLocaleValues);\n }", "public function redq_support_multilanguages()\n {\n load_plugin_textdomain('redq-rental', false, dirname(plugin_basename(__FILE__)) . '/languages/');\n }", "function get_lang_locale() {\n\tglobal $lang_code;\n\t$localeMap = array(\n\t\t'ca' => 'ca_ES',\n\t\t'cs' => 'cs_CZ',\n\t\t'cy' => 'cy_GB',\n\t\t'da' => 'da_DK',\n\t\t'de' => 'de_DE',\n\t\t'eu' => 'eu_ES',\n\t\t'en' => 'en_US',\n\t\t'es' => 'es_ES',\n\t\t'fi' => 'fi_FI',\n\t\t'fr' => 'fr_FR',\n\t\t'gl' => 'gl_ES',\n\t\t'hu' => 'hu_HU',\n\t\t'it' => 'it_IT',\n\t\t'ja' => 'ja_JP',\n\t\t'ko' => 'ko_KR',\n\t\t'nb' => 'nb_NO',\n\t\t'nl' => 'nl_NL',\n\t\t'pl' => 'pl_PL',\n\t\t'pt' => 'pt_BR',\n\t\t'ro' => 'ro_RO',\n\t\t'ru' => 'ru_RU',\n\t\t'sk' => 'sk_SK',\n\t\t'sl' => 'sl_SI',\n\t\t'sv' => 'sv_SE',\n\t\t'th' => 'th_TH',\n\t\t'tr' => 'tr_TR',\n\t\t'ku' => 'ku_TR',\n\t\t'zh_CN' => 'zh_CN',\n\t\t'zh_TW' => 'zh_TW',\n\t\t'af' => 'af_ZA',\n\t\t'sq' => 'sq_AL',\n\t\t'hy' => 'hy_AM',\n\t\t'az' => 'az_AZ',\n\t\t'be' => 'be_BY',\n\t\t'bs' => 'bs_BA',\n\t\t'bg' => 'bg_BG',\n\t\t'hr' => 'hr_HR',\n\t\t'eo' => 'eo_EO',\n\t\t'et' => 'et_EE',\n\t\t'fo' => 'fo_FO',\n\t\t'ka' => 'ka_GE',\n\t\t'el' => 'el_GR',\n\t\t'hi' => 'hi_IN',\n\t\t'is' => 'is_IS',\n\t\t'id' => 'id_ID',\n\t\t'ga' => 'ga_IE',\n\t\t'jv' => 'jv_ID',\n\t\t'kk' => 'kk_KZ',\n\t\t'la' => 'la_VA',\n\t\t'lv' => 'lv_LV',\n\t\t'lt' => 'lt_LT',\n\t\t'mk' => 'mk_MK',\n\t\t'mg' => 'mg_MG',\n\t\t'ms' => 'ms_MY',\n\t\t'mt' => 'mt_MT',\n\t\t'mn' => 'mn_MN',\n\t\t'ne' => 'ne_NP',\n\t\t'rm' => 'rm_CH',\n\t\t'sr' => 'sr_RS',\n\t\t'so' => 'so_SO',\n\t\t'sw' => 'sw_KE',\n\t\t'tl' => 'tl_PH',\n\t\t'uk' => 'uk_UA',\n\t\t'uz' => 'uz_UZ',\n\t\t'vi' => 'vi_VN',\n\t\t'zu' => 'zu_ZA',\n\t\t'ar' => 'ar_AR',\n\t\t'he' => 'he_IL',\n\t\t'ur' => 'ur_PK',\n\t\t'fa' => 'fa_IR',\n\t\t'sy' => 'sy_SY',\n\t\t'gn' => 'gn_PY'\n\t);\n\treturn (check_value($localeMap[$lang_code])) ? $localeMap[$lang_code] : 'en_US';\n}", "public function switcher()\n {\n $default_lang = $this->fetchConfig('ml_default_language');\n $all_lang = $this->fetchConfig('ml_languages');\n $lang_text = $this->fetchConfig('ml_switch_text', null, null, false, false);\n $prod_paths = $this->fetchConfig('ml_prod_paths', null, null, false, false);\n $prod_urlroot = $this->fetchConfig('ml_prod_produrlroot', null, null, false, false);\n $currlang = $this->currlang();\n $output = array();\n $output['switch_text'] = $lang_text[$currlang];\n $output['languages'] = array();\n $curr_prod_paths = $prod_paths[$currlang];\n \n $curr_page = Path::pretty(URL::getCurrent());\n $entry_data = Content::get($curr_page);\n\n $uri = ltrim($curr_page, '/');\n $urlparts = explode(\"/\",$uri);\n\n $curr_prod_paths_country = null;\n $curr_prod_paths_path = null;\n if (count($entry_data) < 1)\n { \n if (array_key_exists($urlparts[1], $curr_prod_paths))\n {\n $curr_prod_paths_path = $curr_prod_paths[$urlparts[1]];\n $curr_prod_paths_prod = $urlparts[2];\n $curr_page = \"/\" .$curr_prod_paths_path . \"/\" . $curr_prod_paths_prod;\n }\n\n }\n $entry_data = Content::get($curr_page);\n foreach ($all_lang as $lang) { \n $data = array();\n $data['code'] = $lang;\n $data['text'] = $lang_text[$lang];\n $data['url'] = '/' . $lang;\n $alturl = 'alternative_url_' . $lang;\n if (array_key_exists($alturl, $entry_data)) {\n $data['alturl'] = $entry_data[$alturl];\n }\n $altprodurl = 'alternative_prod_url_' . $lang;\n if (array_key_exists($altprodurl, $entry_data)) {\n $currpp = $prod_paths[$lang];\n reset($currpp);\n $first_key = key($currpp);\n $data['altprodurl'] = \"/\" .$currpp[$first_key] . \"/\" . $entry_data[$altprodurl];\n $data['altprod'] = $entry_data[$altprodurl];\n $data['produrl'] = $prod_urlroot[$lang] . \"/\" . $entry_data[$altprodurl];\n }\n\n $data['is_current'] = ($lang == $currlang) ? true : false;\n array_push($output['languages'], $data);\n }\n\n return $output;\n }", "function lang() {\r\n\t\tif($this->language === \"french\") {\r\n\t\t\tforeach($this->config['lang_fr'] as $tag_name) {\r\n\t\t\t\t$this->code = preg_replace('/<' . $tag_name . '([^<>]*)>/', '<' . $tag_name . ' lang=\"fr\" xml:lang=\"fr\"$1>', $this->code);\r\n\t\t\t\t$this->code = preg_replace('/<' . $tag_name . ' lang=\"fr\" xml:lang=\"fr\"([^<>]*) lang=\"fr\" xml:lang=\"fr\"([^<>]*)>/', '<' . $tag_name . ' lang=\"fr\" xml:lang=\"fr\"$1$2>', $this->code);\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\tif($this->language === \"english_and_french\") {\r\n\t\t\tpreg_match_all('/<body[^<>]*>(.*?)<\\/body>/is', $this->code, $matches);\r\n\t\t\t$initial_body_code = $body_code = $matches[1][0];\r\n\t\t\t$replace_count = -1;\r\n\t\t\twhile($replace_count != 0) {\r\n\t\t\t\t$body_code = preg_replace('/<(\\w*)([^<>]*)>\\s*([^<>\\/]*[^\\s])\\s*\\/\\s*([^<>\\/]{1,})\\s*</is', '<$1$2><span lang=\"en\" xml:lang=\"en\">$3</span> / <span lang=\"fr\" xml:lang=\"fr\">$4</span><', $body_code, -1, $replace_count);\r\n\t\t\t}\r\n\t\t\t$this->code = str_replace($initial_body_code, $body_code, $this->code);\r\n\t\t}\r\n\t\t$this->logMsgIf(\"lang\", $ct);\r\n\t\treturn true;\r\n\t}", "static protected function translate($s){\nif(!self::$strings)return $s;\nif(!array_key_exists($s,self::$strings))return $s;\nreturn self::$strings[$s];\n}", "function get_rocket_qtranslate_langs_for_admin_bar()\r\n{\r\n\tglobal $q_config;\r\n\t$langlinks = array();\r\n\t$currentlang = array();\r\n\r\n\tforeach( $q_config['enabled_languages'] as $lang ) {\r\n\r\n\t\t$langlinks[$lang] = array(\r\n 'code'\t\t=> $lang,\r\n 'anchor' => $q_config['language_name'][$lang],\r\n 'flag' => '<img src=\"' . trailingslashit( WP_CONTENT_URL ) . $q_config['flag_location'] . $q_config['flag'][$lang] . '\" alt=\"' . $q_config['language_name'][$lang] . '\" width=\"18\" height=\"12\" />'\r\n );\r\n\r\n\t}\r\n\r\n\tif ( isset( $_GET['lang'] ) && qtrans_isEnabled( $_GET['lang'] ) ) {\r\n\t\t$currentlang[ $_GET['lang'] ] = $langlinks[ $_GET['lang'] ];\r\n\t\tunset( $langlinks[ $_GET['lang'] ] );\r\n\t\t$langlinks = $currentlang + $langlinks;\r\n\t}\r\n\r\n\treturn $langlinks;\r\n}", "public static function setupMultilingual()\n {\n $db = JFactory::getDbo();\n $query = $db->getQuery(true);\n $languages = self::getLanguages();\n if (count($languages)) {\n //states table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_states\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_states table\n $prefix = $language->sef;\n if (!in_array('state_name_' . $prefix, $fieldArr)) {\n $fieldName = 'state_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_states` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //cities table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_cities\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_cities table\n $prefix = $language->sef;\n if (!in_array('city_' . $prefix, $fieldArr)) {\n $fieldName = 'city_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_cities` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n\t\t\t//cities table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_countries\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_countries table\n $prefix = $language->sef;\n if (!in_array('country_name_' . $prefix, $fieldArr)) {\n $fieldName = 'country_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_countries` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //tags table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_tags\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_emails table\n $prefix = $language->sef;\n //$fields = array_keys($db->getTableColumns('#__osrs_emails'));\n if (!in_array('keyword_' . $prefix, $fieldArr)) {\n $fieldName = 'keyword_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_tags` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n //emails table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_emails\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_emails table\n $prefix = $language->sef;\n //$fields = array_keys($db->getTableColumns('#__osrs_emails'));\n if (!in_array('email_title_' . $prefix, $fieldArr)) {\n $fieldName = 'email_title_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_emails` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'email_content_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_emails` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //categories table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_categories\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_categories table\n $prefix = $language->sef;\n if (!in_array('category_name_' . $prefix, $fieldArr)) {\n $fieldName = 'category_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_categories` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'category_alias_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_categories` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'category_description_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_categories` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n //amenities table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_amenities\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('amenities_' . $prefix, $fieldArr)) {\n $fieldName = 'amenities_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_amenities` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //field group table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_fieldgroups\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('group_name_' . $prefix, $fieldArr)) {\n $fieldName = 'group_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_fieldgroups` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //extra field table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_extra_fields\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('field_label_' . $prefix, $fieldArr)) {\n $fieldName = 'field_label_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_extra_fields` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'field_description_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_extra_fields` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n //field group table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_extra_field_options\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('field_option_' . $prefix, $fieldArr)) {\n $fieldName = 'field_option_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_extra_field_options` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //osrs_property_field_value table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_property_field_value\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('value_' . $prefix, $fieldArr)) {\n $fieldName = 'value_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_property_field_value` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //types table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_types\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('type_name_' . $prefix, $fieldArr)) {\n $fieldName = 'type_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_types` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'type_alias_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_types` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n //properties table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_properties\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_properties table\n $prefix = $language->sef;\n if (!in_array('pro_name_' . $prefix, $fieldArr)) {\n $fieldName = 'pro_name_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'pro_alias_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n if (!in_array('address_' . $prefix, $fieldArr)) {\n $fieldName = 'address_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n\t\t\t\tif (!in_array('price_text_' . $prefix, $fieldArr)) {\n $fieldName = 'price_text_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR( 255 );\";\n $db->setQuery($sql);\n $db->execute();\n }\n if (!in_array('pro_small_desc_' . $prefix, $fieldArr)) {\n $fieldName = 'pro_small_desc_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'pro_full_desc_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n if (!in_array('metadesc_' . $prefix, $fieldArr)) {\n $fieldName = 'metadesc_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR (255) DEFAULT '' NOT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n\n $fieldName = 'metakey_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR (255) DEFAULT '' NOT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n\t\t\t\tif (!in_array('pro_browser_title_' . $prefix, $fieldArr)) {\n $fieldName = 'pro_browser_title_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_properties` ADD `$fieldName` VARCHAR( 255 ) DEFAULT '' NOT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n //types table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_agents\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('bio_' . $prefix, $fieldArr)) {\n $fieldName = 'bio_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_agents` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n\n //companies table\n $db->setQuery(\"SHOW COLUMNS FROM #__osrs_companies\");\n $fields = $db->loadObjectList();\n if (count($fields) > 0) {\n $fieldArr = array();\n for ($i = 0; $i < count($fields); $i++) {\n $field = $fields[$i];\n $fieldname = $field->Field;\n $fieldArr[$i] = $fieldname;\n }\n }\n foreach ($languages as $language) {\n #Process for #__osrs_amenities table\n $prefix = $language->sef;\n if (!in_array('company_description_' . $prefix, $fieldArr)) {\n $fieldName = 'company_description_' . $prefix;\n $sql = \"ALTER TABLE `#__osrs_companies` ADD `$fieldName` TEXT NULL;\";\n $db->setQuery($sql);\n $db->execute();\n }\n }\n\n }\n }", "public function languageArray(){\n [\n // Contact Lifestage\n __('Customers'),\n __('Leads'),\n __('Opportunities'),\n __('Subscriber'),\n // Contact Source\n __('Advertisement'),\n __('Chat'),\n __('Contact Form'),\n __('Employee Referral'),\n __('External Referral'),\n __('Marketing campaign'),\n __('Newsletter'),\n __('OnlineStore'),\n __('Optin Forms'),\n __('Partner'),\n __('Phone Call'),\n __('Public Relations'),\n __('Sales Mail Alias'),\n __('Search Engine'),\n __('Seminar-Internal'),\n __('Seminar Partner'),\n __('Social Media'),\n __('Trade Show'),\n __('Web Download'),\n __('Web Research'),\n //log activity type\n __('Log A Call'),\n __('Log A Email'),\n __('Log A SMS'),\n __('Log A Meeting'),\n //scheduele type\n __('Meeting'),\n __('Call'),\n //employee type\n __('Full Time'),\n __('Part Time'),\n __('On Contract'),\n __('Temporary'),\n __('Trainee'),\n //employee status\n __('Active'),\n __('Inactive'),\n __('Terminated'),\n __('Deceased'),\n __('Resigned'),\n //source of hire\n __('Direct'),\n __('Referral'),\n __('Web'),\n __('Newspaper'),\n __('Advertisement'),\n __('Social Network'),\n __('Other'),\n //pay type\n __('Hourly'),\n __('Daily'),\n __('Weekly'),\n __('Biweekly'),\n __('Monthly'),\n __('Contract'),\n //gender\n __('Male'),\n __('Female'),\n __('Other'),\n //marital status\n __('Single'),\n __('Married'),\n __('Widowed'),\n //performance_review\n __('Very Bad'),\n __('Poor'),\n __('Average'),\n __('Good'),\n __('Excellent'),\n //send announcement to\n __('All Users'),\n __('Selected User'),\n __('By Department'),\n __('By Designation'),\n //product_category type\n __('Product & Service'),\n __('Income'),\n __('Expense'),\n //product_type\n __('Inventory'),\n __('Service'),\n //project_status\n __('On Hold'),\n __('In Progress'),\n __('Complete'),\n __('Canceled'),\n //project status_color\n __('warning'),\n __('info'),\n __('success'),\n __('danger'),\n //project task priority\n __('Critical'),\n __('High'),\n __('Medium'),\n __('Low'),\n ];\n }", "public function getTranslationsForLanguage($language);", "function cnvlanguagelist()\n{\n $cnvlang['af'] = \"eng\";\n $cnvlang['sq'] = \"eng\";\n $cnvlang['ar-bh'] = \"ara\";\n $cnvlang['eu'] = \"eng\";\n $cnvlang['be'] = \"eng\";\n $cnvlang['bg'] = \"bul\";\n $cnvlang['ca'] = \"eng\";\n $cnvlang['zh-cn'] = 'zho';\n $cnvlang['zh-tw'] = 'zho';\n $cnvlang['hr'] = 'cro';\n $cnvlang['cs'] = 'ces';\n $cnvlang['da'] = 'dan';\n $cnvlang['nl'] = 'nld';\n $cnvlang['nl-be'] = 'nld';\n $cnvlang['nl-nl'] = 'nld';\n $cnvlang['en'] = 'eng';\n $cnvlang['en-au'] = 'eng';\n $cnvlang['en-bz'] = 'eng';\n $cnvlang['en-ca'] = 'eng';\n $cnvlang['en-ie'] = 'eng';\n $cnvlang['en-jm'] = 'eng';\n $cnvlang['en-nz'] = 'eng';\n $cnvlang['en-ph'] = 'eng';\n $cnvlang['en-za'] = 'eng';\n $cnvlang['en-tt'] = 'eng';\n $cnvlang['en-gb'] = 'eng';\n $cnvlang['en-us'] = 'eng';\n $cnvlang['en-zw'] = 'eng';\n $cnvlang['fo'] = 'eng';\n $cnvlang['fi'] = 'fin';\n $cnvlang['fr'] = 'fra';\n $cnvlang['fr-be'] = 'fra';\n $cnvlang['fr-ca'] = 'fra';\n $cnvlang['fr-fr'] = 'fra';\n $cnvlang['fr-lu'] = 'fra';\n $cnvlang['fr-mc'] = 'fra';\n $cnvlang['fr-ch'] = 'fra';\n $cnvlang['gl'] = 'eng';\n $cnvlang['gd'] = 'eng';\n $cnvlang['de'] = 'deu';\n $cnvlang['de-at'] = 'deu';\n $cnvlang['de-de'] = 'deu';\n $cnvlang['de-li'] = 'deu';\n $cnvlang['de-lu'] = 'deu';\n $cnvlang['de-ch'] = 'deu';\n $cnvlang['el'] = 'ell';\n $cnvlang['hu'] = 'hun';\n $cnvlang['is'] = 'isl';\n $cnvlang['in'] = 'ind';\n $cnvlang['ga'] = 'eng';\n $cnvlang['it'] = 'ita';\n $cnvlang['it-it'] = 'ita';\n $cnvlang['it-ch'] = 'ita';\n $cnvlang['ja'] = 'jpn';\n $cnvlang['ko'] = 'kor';\n $cnvlang['mk'] = 'mkd';\n $cnvlang['no'] = 'nor';\n $cnvlang['pl'] = 'pol';\n $cnvlang['pt'] = 'por';\n $cnvlang['pt-br'] = 'por';\n $cnvlang['pt-pt'] = 'por';\n $cnvlang['ro'] = 'ron';\n $cnvlang['ro-mo'] = 'ron';\n $cnvlang['ro-ro'] = 'ron';\n $cnvlang['ru'] = 'rus';\n $cnvlang['KOI8-R'] = 'rus';\n $cnvlang['ru-mo'] = 'rus';\n $cnvlang['ru-ru'] = 'rus';\n $cnvlang['sr'] = 'eng';\n $cnvlang['sk'] = 'slv';\n $cnvlang['sl'] = 'slv';\n $cnvlang['es'] = 'spa';\n $cnvlang['es-ar'] = 'spa';\n $cnvlang['es-bo'] = 'spa';\n $cnvlang['es-cl'] = 'spa';\n $cnvlang['es-co'] = 'spa';\n $cnvlang['es-cr'] = 'spa';\n $cnvlang['es-do'] = 'spa';\n $cnvlang['es-ec'] = 'spa';\n $cnvlang['es-sv'] = 'spa';\n $cnvlang['es-gt'] = 'spa';\n $cnvlang['es-hn'] = 'spa';\n $cnvlang['es-mx'] = 'spa';\n $cnvlang['es-ni'] = 'spa';\n $cnvlang['es-pa'] = 'spa';\n $cnvlang['es-py'] = 'spa';\n $cnvlang['es-pe'] = 'spa';\n $cnvlang['es-pr'] = 'spa';\n $cnvlang['es-es'] = 'spa';\n $cnvlang['es-uy'] = 'spa';\n $cnvlang['es-ve'] = 'spa';\n $cnvlang['sv'] = 'swe';\n $cnvlang['sv-fi'] = 'swe';\n $cnvlang['sv-se'] = 'swe';\n $cnvlang['th'] = 'tha';\n $cnvlang['tr'] = 'tur';\n $cnvlang['uk'] = 'ukr';\n $cnvlang['ar'] = 'ara';\n $cnvlang['ar-ae'] = 'ara';\n $cnvlang['ar-bh'] = 'ara';\n $cnvlang['ar-dz'] = 'ara';\n $cnvlang['ar-eg'] = 'ara';\n $cnvlang['ar-iq'] = 'ara';\n $cnvlang['ar-jo'] = 'ara';\n $cnvlang['ar-kw'] = 'ara';\n $cnvlang['ar-lb'] = 'ara';\n $cnvlang['ar-ly'] = 'ara';\n $cnvlang['ar-ma'] = 'ara';\n $cnvlang['ar-mr'] = 'ara';\n $cnvlang['ar-om'] = 'ara';\n $cnvlang['ar-qa'] = 'ara';\n $cnvlang['ar-sa'] = 'ara';\n $cnvlang['ar-sd'] = 'ara';\n $cnvlang['ar-so'] = 'ara';\n $cnvlang['ar-sy'] = 'ara';\n $cnvlang['ar-tn'] = 'ara';\n $cnvlang['ar-ye'] = 'ara';\n $cnvlang['ar-km'] = 'ara';\n $cnvlang['ar-dj'] = 'ara';\n asort($cnvlang);\n return $cnvlang;\n}", "protected function sectionTranslations()\n {\n $found = []; // translations found in latte templates\n foreach (glob('template/*.latte') as $file) {\n $tempFileContents = file_get_contents($file);\n Assert::string($tempFileContents);\n preg_match_all('~\\{=(\"([^\"]+)\"|\\'([^\\']+)\\')\\|translate\\}~i', $tempFileContents, $matches);\n $found = array_merge($found, $matches[2]);\n }\n $found = array_unique($found);\n $output = '<h1><i class=\"fa fa-globe\"></i> ' . $this->tableAdmin->translate('Translations')\n . '</h1><div id=\"agenda-translations\">'\n . '<form action=\"\" method=\"post\" onsubmit=\"return confirm(\\''\n . $this->tableAdmin->translate('Are you sure?') . '\\')\">'\n . Tools::htmlInput('translations', '', 1, array('type' => 'hidden'))\n . Tools::htmlInput('token', '', end($_SESSION['token']), 'hidden')\n . Tools::htmlInput('old_name', '', '', array('type' => 'hidden', 'id' => 'old_name'))\n . '<table class=\"table table-striped\"><thead><tr><th style=\"width:'\n . intval(100 / (count($this->MyCMS->TRANSLATIONS) + 1)) . '%\">'\n . Tools::htmlInput('one', '', false, 'radio') . '</th>';\n $translations = $keys = [];\n $localisation = new L10n($this->prefixUiL10n, $this->MyCMS->TRANSLATIONS);\n foreach ($this->MyCMS->TRANSLATIONS as $key => $value) {\n $output .= \"<th>$value</th>\";\n $translations[$key] = $localisation->readLocalisation($key);\n $keys = array_merge($keys, array_keys($translations[$key]));\n }\n $output .= '</tr></thead><tbody>' . PHP_EOL;\n $keys = array_unique($keys);\n natcasesort($keys);\n foreach ($keys as $key) {\n $output .= '<tr><th>'\n . Tools::htmlInput('one', '', $key, array('type' => 'radio', 'class' => 'translation')) . ' '\n . Tools::h((string) $key) . '</th>';\n foreach ($this->MyCMS->TRANSLATIONS as $code => $value) {\n $output .= '<td>' . Tools::htmlInput(\n \"tr[$code][$key]\",\n '',\n Tools::set($translations[$code][$key], ''),\n ['class' => 'form-control form-control-sm', 'title' => \"$code: $key\"]\n ) . '</td>';\n }\n $output .= '</tr>' . PHP_EOL;\n if ($key = array_search($key, $found)) {\n unset($found[$key]);\n }\n }\n $output .= '<tr><td>' . Tools::htmlInput(\n 'new[0]',\n '',\n '',\n array('class' => 'form-control form-control-sm', 'title' => $this->tableAdmin->translate('New record'))\n ) . '</td>';\n foreach ($this->MyCMS->TRANSLATIONS as $key => $value) {\n $output .= '<td>' . Tools::htmlInput(\n \"new[$key]\",\n '',\n '',\n ['class' => 'form-control form-control-sm',\n 'title' => $this->tableAdmin->translate('New record') . ' (' . $value . ')']\n ) . '</td>';\n }\n $output .= '</tr></tbody></table>\n <button name=\"translations\" type=\"submit\" class=\"btn btn-secondary\"><i class=\"fa fa-save\"></i> '\n . $this->tableAdmin->translate('Save') . '</button>\n <button name=\"delete\" type=\"submit\" class=\"btn btn-secondary\" value=\"1\"><i class=\"fa fa-dot-circle\"></i>\n <i class=\"fa fa-trash\"></i> ' . $this->tableAdmin->translate('Delete') . '</button>\n <fieldset class=\"d-inline-block position-relative\"><div class=\"input-group\" id=\"rename-fieldset\">'\n . '<div class=\"input-group-prepend\">\n <button class=\"btn btn-secondary\" type=\"submit\"><i class=\"fa fa-dot-circle\"></i> '\n . '<i class=\"fa fa-i-cursor\"></i> ' . $this->tableAdmin->translate('Rename') . '</button>\n </div>'\n . Tools::htmlInput('new_name', '', '', array('class' => 'form-control', 'id' => 'new_name'))\n . '</div></fieldset>\n </form></div>' . PHP_EOL;\n $output .= count($found) ? '<h2 class=\"mt-4\">' .\n $this->tableAdmin->translate('Missing translations in templates') . '</h2><ul>' : '';\n foreach ($found as $value) {\n $output .= '<li><code>' . Tools::h($value) . '</code></li>' . PHP_EOL;\n }\n $output .= count($found) ? '</ul>' : '';\n return $output;\n }", "public static function init(){\n self::$language = config::getMainIni('language');\n\n $system_lang = array();\n $db = new db();\n $system_language = $db->select(\n 'language',\n 'language',\n config::$vars['coscms_main']['language']\n );\n\n // create system lanugage for all modules\n if (!empty($system_language)){\n foreach($system_language as $key => $val){\n $module_lang = unserialize($val['translation']);\n $system_lang+= $module_lang;\n }\n } \n self::$dict = $system_lang;\n }", "public static function getLanguages()\n\t{\n\t\tstatic $languages = array(\n\t\t\tarray('English', 'English', 'eng', 'en'),\n\t\t\tarray('German', 'Deutsch', 'ger', 'de'),\n\t\t\tarray('French', 'Française', 'fre', 'fr'),\n\t\t\tarray('Bulgarian', 'български език', 'bul', 'bg'),\n\t\t\tarray('Spanish', 'español', 'spa', 'es'),\n\t\t\tarray('Chinese', '汉语 / 漢語', 'chi', 'zh'),\n\t\t\tarray('Croatian', 'hrvatski', 'cro', 'hr'),\n\t\t\tarray('Albanian', 'Shqip', 'alb', 'sq'),\n\t\t\tarray('Arabic', 'العربية', 'ara', 'ar'),\n// \t\t\tarray('Amazigh', '', 'ama', ''),\n\t\t\tarray('Catalan', 'català', 'cat', 'ca'),\n\t\t\tarray('Armenian', 'Հայերեն', 'arm', 'hy'),\n\t\t\tarray('Azerbaijani', 'Azərbaycan / Азәрбајҹан / آذربایجان دیلی', 'aze', 'az'),\n\t\t\tarray('Bengali', 'বাংলা', 'ben', 'bn'),\n\t\t\tarray('Dutch', 'Nederlands', 'dut', 'nl'),\n\t\t\tarray('Bosnian', 'bosanski/босански', 'bos', 'bs'),\n\t\t\tarray('Serbian', 'Српски / Srpski ', 'ser', 'sr'),\n\t\t\tarray('Portuguese', 'português', 'por', 'pt'),\n\t\t\tarray('Greek', 'Ελληνικά / Ellīniká', 'gre', 'el'),\n\t\t\tarray('Turkish', 'Türkçe', 'tur', 'tr'),\n\t\t\tarray('Czech', 'Čeština', 'cze', 'cs'),\n\t\t\tarray('Danish', 'dansk', 'dan', 'da'),\n\t\t\tarray('Finnish', 'suomi', 'fin', 'fi'),\n\t\t\tarray('Swedish', 'svenska', 'swe', 'sv'),\n\t\t\tarray('Hungarian', 'magyar', 'hun', 'hu'),\n\t\t\tarray('Icelandic', 'Íslenska', 'ice', 'is'),\n\t\t\tarray('Hindi', 'हिन्दी / हिंदी', 'hin', 'hi'),\n\t\t\tarray('Persian', 'فارسی', 'per', 'fa'),\n\t\t\tarray('Kurdish', 'Kurdî / کوردی', 'kur', 'ku'),\n\t\t\tarray('Irish', 'Gaeilge', 'iri', 'ga'),\n\t\t\tarray('Hebrew', 'עִבְרִית / \\'Ivrit', 'heb', 'he'),\n\t\t\tarray('Italian', 'Italiano', 'ita', 'it'),\n\t\t\tarray('Japanese', '日本語 / Nihongo', 'jap', 'ja'),\n\t\t\tarray('Korean', '한국어 / 조선말', 'kor', 'ko'),\n\t\t\tarray('Latvian', 'latviešu valoda', 'lat', 'lv'),\n\t\t\tarray('Lithuanian', 'Lietuvių kalba', 'lit', 'lt'),\n\t\t\tarray('Luxembourgish', 'Lëtzebuergesch', 'lux', 'lb'),\n\t\t\tarray('Macedonian', 'Македонски јазик / Makedonski jazik', 'mac', 'mk'),\n\t\t\tarray('Malay', 'Bahasa Melayu / بهاس ملايو', 'mal', 'ms'),\n\t\t\tarray('Dhivehi', 'Dhivehi / Mahl', 'dhi', 'dv'),\n// \t\t\tarray(\"Montenegrin\", \"Црногорски / Crnogorski\", \"mon\", ''),\n\t\t\tarray('Maori', 'Māori', 'mao', 'mi'),\n\t\t\tarray('Norwegian', 'norsk', 'nor', 'no'),\n\t\t\tarray('Filipino', 'Filipino', 'fil', 'tl'),\n\t\t\tarray('Polish', 'język polski', 'pol', 'pl'),\n\t\t\tarray('Romanian', 'română / limba română', 'rom', 'ro'),\n\t\t\tarray('Russian', 'Русский язык', 'rus', 'ru'),\n\t\t\tarray('Slovak', 'slovenčina', 'slo', 'sk'),\n\t\t\tarray('Mandarin', '官話 / Guānhuà', 'man', 'zh'),\n\t\t\tarray('Tamil', 'தமிழ', 'tam', 'ta'),\n\t\t\tarray('Slovene', 'slovenščina', 'slv', 'sl'),\n\t\t\tarray('Zulu', 'isiZulu', 'zul', 'zu'),\n\t\t\tarray('Xhosa', 'isiXhosa', 'xho', 'xh'),\n\t\t\tarray('Afrikaans', 'Afrikaans', 'afr', 'af'),\n// \t\t\tarray('Northern Sotho', 'Sesotho sa Leboa', 'nso', '--'),\n\t\t\tarray('Tswana', 'Setswana / Sitswana', 'tsw', 'tn'),\n\t\t\tarray('Sotho', 'Sesotho', 'sot', 'st'),\n\t\t\tarray('Tsonga', 'Tsonga', 'tso', 'ts'),\n\t\t\tarray('Thai', 'ภาษาไทย / phasa thai', 'tha', 'th'),\n\t\t\tarray('Ukrainian', 'українська мова', 'ukr', 'uk'),\n\t\t\tarray('Vietnamese', 'Tiếng Việt', 'vie', 'vi'),\n\t\t\tarray('Pashto', 'پښت', 'pas', 'ps'),\n\t\t\tarray('Samoan', 'gagana Sāmoa', 'sam', 'sm'),\n// \t\t\tarray('Bajan', 'Barbadian Creole', 'baj', '--'),\n\t\t\tarray('Belarusian', 'беларуская мова', 'bel', 'be'),\n\t\t\tarray('Dzongkha', '', 'dzo', 'dz'),\n// \t\t\tarray('Quechua', '', 'que', ''),\n// \t\t\tarray('Aymara', '', 'aym', ''),\n// \t\t\tarray('Setswana', '', 'set', ''),\n// \t\t\tarray('Bruneian', '', 'bru', ''),\n// \t\t\tarray('Indigenous', '', 'ind', ''),\n// \t\t\tarray('Kirundi', '', 'kir', ''),\n// \t\t\tarray('Swahili', '', 'swa', ''),\n// \t\t\tarray('Khmer', '', 'khm', ''),\n// \t\t\tarray('Sango', '', 'san', ''),\n// \t\t\tarray('Lingala', '', 'lin', ''),\n// \t\t\tarray('Kongo/Kituba', '', 'kon', ''),\n// \t\t\tarray('Tshiluba', '', 'tsh', ''),\n// \t\t\tarray('Afar', '', 'afa', ''),\n// \t\t\tarray('Somali', '', 'som', ''),\n// \t\t\tarray('Fang', '', 'fan', ''),\n// \t\t\tarray('Bube', '', 'bub', ''),\n// \t\t\tarray('Annobonese', '', 'ann', ''),\n// \t\t\tarray('Tigrinya', '', 'tig', ''),\n// \t\t\tarray('Estonian', 'Eesti', 'est', 'et'),\n// \t\t\tarray('Amharic', '', 'amh', ''),\n// \t\t\tarray('Faroese', '', 'far', ''),\n// \t\t\tarray('Bau Fijian', '', 'bau', ''),\n// \t\t\tarray('Hindustani', '', 'hit', ''),\n// \t\t\tarray('Tahitian', '', 'tah', ''),\n// \t\t\tarray('Georgian', '', 'geo', ''),\n// \t\t\tarray('Greenlandic', '', 'grl', ''),\n// \t\t\tarray('Chamorro', '', 'cha', ''),\n// \t\t\tarray('Crioulo', '', 'cri', ''),\n// \t\t\tarray('Haitian Creole', '', 'hai', ''),\n// \t\t\tarray('Indonesian', '', 'inn', ''),\n// \t\t\tarray('Kazakh', '', 'kaz', ''),\n// \t\t\tarray('Gilbertese', '', 'gil', ''),\n// \t\t\tarray('Kyrgyz', '', 'kyr', ''),\n// \t\t\tarray('Lao', '', 'lao', ''),\n// \t\t\tarray('Southern Sotho', '', 'sso', ''),\n// \t\t\tarray('Malagasy', '', 'mag', ''),\n// \t\t\tarray('Chichewa', '', 'chw', ''),\n// \t\t\tarray('Maltese', '', 'mat', ''),\n// \t\t\tarray('Marshallese', '', 'mar', ''),\n// \t\t\tarray('Moldovan', '', 'mol', ''),\n// \t\t\tarray('Gagauz', '', 'gag', ''),\n// \t\t\tarray('Monegasque', '', 'moq', ''),\n// \t\t\tarray('Mongolian', '', 'mgl', ''),\n// \t\t\tarray('Burmese', '', 'bur', ''),\n// \t\t\tarray('Oshiwambo', '', 'osh', ''),\n// \t\t\tarray('Nauruan', '', 'nau', ''),\n// \t\t\tarray('Nepal', '', 'nep', ''),\n// \t\t\tarray('Papiamento', '', 'pap', ''),\n// \t\t\tarray('Niuean', '', 'niu', ''),\n// \t\t\tarray('Norfuk', '', 'nfk', ''),\n// \t\t\tarray('Carolinian', '', 'car', ''),\n// \t\t\tarray('Urdu', 'اردو', 'urd', 'ur'),\n// \t\t\tarray('Palauan', '', 'pal', ''),\n// \t\t\tarray('Tok Pisin', '', 'tok', ''),\n// \t\t\tarray('Hiri Motu', '', 'hir', ''),\n// \t\t\tarray('Guarani', '', 'gua', ''),\n// \t\t\tarray('Pitkern', '', 'pit', ''),\n// \t\t\tarray('Kinyarwanda', '', 'kin', ''),\n// \t\t\tarray('Antillean Creole', '', 'ant', ''),\n// \t\t\tarray('Wolof', '', 'wol', ''),\n// \t\t\tarray('Sinhala', '', 'sin', ''),\n// \t\t\tarray('Sranan Tongo', '', 'sra', ''),\n// \t\t\tarray('Swati', '', 'swt', ''),\n// \t\t\tarray('Syrian', '', 'syr', ''),\n// \t\t\tarray('Tajik', '', 'taj', ''),\n// \t\t\tarray('Tetum', '', 'tet', ''),\n// \t\t\tarray('Tokelauan', '', 'tol', ''),\n// \t\t\tarray('Tongan', '', 'ton', ''),\n// \t\t\tarray('Turkmen', '', 'tkm', ''),\n// \t\t\tarray('Uzbek', '', 'uzb', ''),\n// \t\t\tarray('Dari', '', 'dar', ''),\n// \t\t\tarray('Tuvaluan', '', 'tuv', ''),\n// \t\t\tarray('Bislama', '', 'bis', ''),\n// \t\t\tarray('Uvean', '', 'uve', ''),\n// \t\t\tarray('Futunan', '', 'fut', ''),\n// \t\t\tarray('Shona', '', 'sho', ''),\n// \t\t\tarray('Sindebele', '', 'sid', ''),\n// \t\t\tarray('Taiwanese', '', 'tai', ''),\n// \t\t\tarray('Manx', '', 'max', ''),\n\t\t\tarray('Fanmglish', 'Famster', 'fam', 'xf'),\n\t\t\tarray('Bot', 'BotJSON', 'bot', 'xb'),\n\t\t\tarray('Ibdes', 'RFCBotJSON', 'ibd', 'xi'),\n\t\t\tarray('Test Japanese', 'Test Japanese', 'ori', 'xo')\n\t\t);\n\t\treturn $languages;\n\t}", "function smarty_function_togglelang($params, &$smarty)\r\n{\r\n $queryStr = explode(\"?\", $_SERVER['REQUEST_URI']);\r\n $page = array_shift($queryStr);\r\n $queryArr = array();\r\n if(count($queryStr) > 0)\r\n {\r\n foreach (explode(\"&\", $queryStr[0]) as $p)\r\n {\r\n $param = explode(\"=\", $p);\r\n if($param[0] != \"url\")\r\n $queryArr[array_shift($param)] = implode(\"=\", $param);\r\n }\r\n }\r\n \r\n $queryArr[\"lang\"] = $params[\"lang\"];\r\n $url = \"\";\r\n \r\n foreach($queryArr as $key => $value)\r\n {\r\n if($url == \"\")\r\n $url .= \"?\";\r\n else\r\n $url .= \"&\";\r\n \r\n $url .= $key . \"=\" . $value;\r\n }\r\n \r\n return $page . $url;\r\n}", "private function generateLanguageBar()\n {\n $languages = $this->translator->getLanguage()->getLanguageList();\n $langmap = null;\n if (count($languages) > 1) {\n $parameterName = $this->getTranslator()->getLanguage()->getLanguageParameterName();\n $langmap = array();\n foreach ($languages as $lang => $current) {\n $lang = strtolower($lang);\n $langname = $this->translator->getLanguage()->getLanguageLocalizedName($lang);\n $url = false;\n if (!$current) {\n $url = htmlspecialchars(\\SimpleSAML\\Utils\\HTTP::addURLParameters(\n '',\n array($parameterName => $lang)\n ));\n }\n $langmap[$lang] = array(\n 'name' => $langname,\n 'url' => $url,\n );\n }\n }\n return $langmap;\n }", "function langswitch($lang)\n{\n // The page path (an absolute path, starting with '/')\n $pagePath = LocaleLinkService::getPagePath();\n\n // Check if the multi-language support is enabled\n if (!LocaleService::isMultilangEnabled()) {\n return $pagePath;\n }\n\n // Empty lang\n if (empty($lang)) {\n return $pagePath;\n }\n\n // Is it the default lang?\n if ($lang === LocaleService::getDefaultLang()) {\n return $pagePath;\n }\n\n // Get the list of available languages\n $availableLangs = LocaleService::getAvailableLangs();\n\n // Isn't the language supported?\n if (!in_array($lang, $availableLangs)) {\n return $pagePath;\n }\n\n return \"/{$lang}{$pagePath}\";\n}", "public function languages()\n\t{\n\n // We prepare our array of languages codes\n $languages = $this->languages;\n\n // If any arguments are passed to this method\n if ( ! empty($args = func_get_args())) {\n\n\n // Prepare an empty array and fill it after\n $_languages = array();\n\n // Make sure $args is not a multidimensional array\n isset($args[0]) && is_array($args[0]) && $args = $args[0];\n\n // We walk through languages codes and fill our array\n foreach ($languages as $key => $value) {\n \n // We start by assigning the key with an empty value\n $_languages[$key] = array();\n // We walk through passed arguments\n foreach ($args as $arg) {\n\n \tif (isset($value[$arg])) {\n \t\t$_languages[$key][$arg] = $value[$arg];\n \t}\n }\n }\n\n // replace our $languages array with $_languages\n $languages = $_languages;\n unset($_languages);\n }\n\n return $languages;\n\t}", "private function set_lang()\n\t{\n\t\t//print_r($this->CI->uri->rsegment_array());\n\t\t//echo $this->CI->uri->ruri_string();\n\t\t\n\t\t// Set from default config\n\t\t$this->lang = $this->lang_default;\n\t\t\t\t\n\t\t// Set from browser\n\t\tif ($this->detect_browser)\n\t\t{\n\t\t\t$this->lang = $this->detect_browser_lang();\n\t\t}\n\n\t\t// Set from session\n\t\t$this->set_session();\n\t\t\n\t\t// Set from URI\n\t\t$first_segment = $this->CI->uri->segment(1);\n\t\tif (in_array($first_segment, $this->langs))\n\t\t{\n\t\t\t$this->lang = $first_segment;\n\t\t\t$this->set_session($first_segment);\n\t\t}\n\t}", "public function translate($string, $context = 0, $values = null, $lang = null);", "private static function loadLanguage($lang){\n\t\t$descriptions = array();\n\n\t\t$locale = 'locale/'.$lang.'.php';\n\t\trequire($locale);\n\n\t\treturn (object)$descriptions;\n\t}", "public function iN_Languages() {\n\t\t$query = mysqli_query($this->db, \"SELECT * FROM i_langs WHERE lang_status = '1'\") or die(mysqli_error($this->db));\n\t\twhile ($row = mysqli_fetch_array($query, MYSQLI_ASSOC)) {\n\t\t\t$data[] = $row;\n\t\t}\n\t\tif (!empty($data)) {\n\t\t\treturn $data;\n\t\t}\n\t}", "function signup_get_available_languages()\n {\n }", "protected function setMessagesInCommonLanguage(&$texts)\n {\n if ($this->_locale != $this->_commonLanguageId) {\n $textsLang = $this->getMessagesByLanguage($texts, array($this->_commonLanguageId));\n foreach ($texts as &$text) {\n $mess = '';\n foreach ($textsLang as $textLang) {\n if ($text['hash'] == $textLang['hash']) {\n $mess = $textLang['target']['target'];\n break;\n }\n }\n $text['commonLang'] = $mess;\n }\n }\n }", "function _polylang_set_sitemap_language() {\n\n\tif ( ! \\function_exists( 'PLL' ) ) return;\n\tif ( ! ( \\PLL() instanceof \\PLL_Frontend ) ) return;\n\n\t// phpcs:ignore, WordPress.Security.NonceVerification.Recommended -- Arbitrary input expected.\n\t$lang = isset( $_GET['lang'] ) ? $_GET['lang'] : '';\n\n\t// Language codes are user-definable: copy Polylang's filtering.\n\t// The preg_match's source: \\PLL_Admin_Model::validate_lang();\n\tif ( ! \\is_string( $lang ) || ! \\strlen( $lang ) || ! preg_match( '#^[a-z_-]+$#', $lang ) ) {\n\t\t$_options = \\get_option( 'polylang' );\n\t\tif ( isset( $_options['force_lang'] ) ) {\n\t\t\tswitch ( $_options['force_lang'] ) {\n\t\t\t\tcase 0:\n\t\t\t\t\t// Polylang determines language sporadically from content: can't be trusted. Overwrite.\n\t\t\t\t\t$lang = \\pll_default_language();\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t// Polylang can differentiate languages by (sub)domain/directory name early. No need to interfere. Cancel.\n\t\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t}\n\n\t// This will default to the default language when $lang is invalid or unregistered. This is fine.\n\t$new_lang = \\PLL()->model->get_language( $lang );\n\n\tif ( $new_lang )\n\t\t\\PLL()->curlang = $new_lang;\n}", "function simplesamlphp_get_languages() {\n return array(\n 'no' => 'Bokmål', // Norwegian Bokmål\n 'nn' => 'Nynorsk', // Norwegian Nynorsk\n 'se' => 'Sámegiella', // Northern Sami\n 'sam' => 'Åarjelh-saemien giele', // Southern Sami\n 'da' => 'Dansk', // Danish\n 'en' => 'English',\n 'de' => 'Deutsch', // German\n 'sv' => 'Svenska', // Swedish\n 'fi' => 'Suomeksi', // Finnish\n 'es' => 'Español', // Spanish\n 'fr' => 'Français', // French\n 'it' => 'Italiano', // Italian\n 'nl' => 'Nederlands', // Dutch\n 'lb' => 'Lëtzebuergesch', // Luxembourgish\n 'cs' => 'Čeština', // Czech\n 'sl' => 'Slovenščina', // Slovensk\n 'lt' => 'Lietuvių kalba', // Lithuanian\n 'hr' => 'Hrvatski', // Croatian\n 'hu' => 'Magyar', // Hungarian\n 'pl' => 'Język polski', // Polish\n 'pt' => 'Português', // Portuguese\n 'pt-br' => 'Português brasileiro', // Portuguese\n 'ru' => 'русский язык', // Russian\n 'et' => 'eesti keel', // Estonian\n 'tr' => 'Türkçe', // Turkish\n 'el' => 'ελληνικά', // Greek\n 'ja' => '日本語', // Japanese\n 'zh' => '简体中文', // Chinese (simplified)\n 'zh-tw' => '繁體中文', // Chinese (traditional)\n 'ar' => 'العربية', // Arabic\n 'fa' => 'پارسی', // Persian\n 'ur' => 'اردو', // Urdu\n 'he' => 'עִבְרִית', // Hebrew\n 'id' => 'Bahasa Indonesia', // Indonesian\n 'sr' => 'Srpski', // Serbian\n 'lv' => 'Latviešu', // Latvian\n 'ro' => 'Românește', // Romanian\n 'eu' => 'Euskara', // Basque\n );\n}", "protected function loadLocalization() {}", "public function translate2($word, $from, $tos)\n\t\t{\n\t\t\t//$tos is array of languages to translate to\n\t\t\t//returns array of translations as $result['en']=>'Hello'\n\t\t\t\n\t\t\t$access_token = $this->get_access_token();\n\t\t\t\n\t\t\t$result[$from] = $word;\n\t\t\t\n\t\t\tforeach($tos as $to)\n\t\t\t{\n\t\t\t\t$url = 'http://api.microsofttranslator.com/V2/Http.svc/Translate?text='. urlencode($word) .'&from='.$from.'&to='.$to;\n\t\t\t\t\n\t\t\t\t$ch = curl_init();\n\t\t\t\tcurl_setopt($ch, CURLOPT_URL, $url); \n\t\t\t\tcurl_setopt($ch, CURLOPT_HTTPHEADER, array('Authorization:bearer '.$access_token));\n\t\t\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE); \n\t\t\t\t$rsp = curl_exec($ch); \n\t\t\t\t\n\t\t\t\tpreg_match_all('/<string (.*?)>(.*?)<\\/string>/s', $rsp, $matches);\n\t\n\t\t\t\t$result[$to] = $matches[2][0];\n\t\t\t}\n\t\t\t\n\t\t\treturn $result;\n\t\t}", "public static function l18n($translations, $languages = array('en'))\n {\n if (!is_array($translations)) {\n return $translations;\n }\n\n $langTranslations = array();\n $retVal = '';\n\n foreach ($translations as $key => $value) {\n $parts = explode('-', $key);\n list($lang)= $parts;\n $langTranslations[$lang] = $value;\n }\n\n foreach ($languages as $lang) {\n $culture = explode('-', $lang);\n\n if (array_key_exists($lang, $translations)) {\n $retVal = $translations[$lang];\n break;\n }\n\n if (array_key_exists($culture[0], $translations)) {\n $retVal = $translations[$culture[0]];\n break;\n }\n\n if (array_key_exists($culture[0], $langTranslations)) {\n $retVal = $langTranslations[$culture[0]];\n break;\n }\n }\n\n return empty($retVal)?array_shift($translations):$retVal;\n }", "function languagelist()\n{\n\t // Need to ensure this is loaded for language defines\n\tpnBlockLoad('Core', 'thelang');\n\t// All entries use ISO 639-2/T\n\t// hilope - added all 469 languages available under ISO 639-2\n\t\n\t$lang['aar'] = _LANGUAGE_AAR; // Afar\n\t$lang['abk'] = _LANGUAGE_ABK; // Abkhazian\n\t$lang['ace'] = _LANGUAGE_ACE; // Achinese\n\t$lang['ach'] = _LANGUAGE_ACH; // Acoli\n\t$lang['ada'] = _LANGUAGE_ADA; // Adangme\n\t$lang['ady'] = _LANGUAGE_ADY; // Adyghe; Adygei\n\t$lang['afa'] = _LANGUAGE_AFA; // Afro-Asiatic (Other)\n\t$lang['afh'] = _LANGUAGE_AFH; // Afrihili\n\t$lang['afr'] = _LANGUAGE_AFR; // Afrikaans\n\t$lang['aka'] = _LANGUAGE_AKA; // Akan\n\t$lang['akk'] = _LANGUAGE_AKK; // Akkadian\n\t$lang['ale'] = _LANGUAGE_ALE; // Aleut\n\t$lang['alg'] = _LANGUAGE_ALG; // Algonquian languages\n\t$lang['amh'] = _LANGUAGE_AMH; // Amharic\n\t$lang['ang'] = _LANGUAGE_ANG; // English, Old\n\t$lang['apa'] = _LANGUAGE_APA; // Apache languages\n\t$lang['ara'] = _LANGUAGE_ARA; // Arabic\n\t$lang['arc'] = _LANGUAGE_ARC; // Aramaic\n\t$lang['arg'] = _LANGUAGE_ARG; // Aragonese\n\t$lang['arn'] = _LANGUAGE_ARN; // Araucanian\n\t$lang['arp'] = _LANGUAGE_ARP; // Arapaho\n\t$lang['art'] = _LANGUAGE_ART; // Artificial (Other)\n\t$lang['arw'] = _LANGUAGE_ARW; // Arawak\n\t$lang['asm'] = _LANGUAGE_ASM; // Assamese\n\t$lang['ast'] = _LANGUAGE_AST; // Asturian; Bable\n\t$lang['ath'] = _LANGUAGE_ATH; // Athapascan languages\n\t$lang['aus'] = _LANGUAGE_AUS; // Australian languages\n\t$lang['ava'] = _LANGUAGE_AVA; // Avaric\n\t$lang['ave'] = _LANGUAGE_AVE; // Avestan\n\t$lang['awa'] = _LANGUAGE_AWA; // Awadhi\n\t$lang['aym'] = _LANGUAGE_AYM; // Aymara\n\t$lang['aze'] = _LANGUAGE_AZE; // Azerbaijani\n\t$lang['bad'] = _LANGUAGE_BAD; // Banda\n\t$lang['bai'] = _LANGUAGE_BAI; // Bamileke languages\n\t$lang['bak'] = _LANGUAGE_BAK; // Bashkir\n\t$lang['bal'] = _LANGUAGE_BAL; // Baluchi\n\t$lang['bam'] = _LANGUAGE_BAM; // Bambara\n\t$lang['ban'] = _LANGUAGE_BAN; // Balinese\n\t$lang['bas'] = _LANGUAGE_BAS; // Basa\n\t$lang['bat'] = _LANGUAGE_BAT; // Baltic (Other)\n\t$lang['bej'] = _LANGUAGE_BEJ; // Beja\n\t$lang['bel'] = _LANGUAGE_BEL; // Belarusian\n\t$lang['bem'] = _LANGUAGE_BEM; // Bemba\n\t$lang['ben'] = _LANGUAGE_BEN; // Bengali\n\t$lang['ber'] = _LANGUAGE_BER; // Berber (Other)\n\t$lang['bho'] = _LANGUAGE_BHO; // Bhojpuri\n\t$lang['bih'] = _LANGUAGE_BIH; // Bihari\n\t$lang['bik'] = _LANGUAGE_BIK; // Bikol\n\t$lang['bin'] = _LANGUAGE_BIN; // Bini\n\t$lang['bis'] = _LANGUAGE_BIS; // Bislama\n\t$lang['bla'] = _LANGUAGE_BLA; // Siksika\n\t$lang['bnt'] = _LANGUAGE_BNT; // Bantu (Other)\n\t$lang['bod'] = _LANGUAGE_BOD; // Tibetan\n\t$lang['bos'] = _LANGUAGE_BOS; // Bosnian\n\t$lang['bra'] = _LANGUAGE_BRA; // Braj\n\t$lang['bre'] = _LANGUAGE_BRE; // Breton\n\t$lang['btk'] = _LANGUAGE_BTK; // Batak (Indonesia)\n\t$lang['bua'] = _LANGUAGE_BUA; // Buriat\n\t$lang['bug'] = _LANGUAGE_BUG; // Buginese\n\t$lang['bul'] = _LANGUAGE_BUL; // Bulgarian\n\t$lang['byn'] = _LANGUAGE_BYN; // Blin; Bilin\n\t$lang['cad'] = _LANGUAGE_CAD; // Caddo\n\t$lang['cai'] = _LANGUAGE_CAI; // Central American Indian (Other)\n\t$lang['car'] = _LANGUAGE_CAR; // Carib\n\t$lang['cat'] = _LANGUAGE_CAT; // Catalan; Valencian\n\t$lang['cau'] = _LANGUAGE_CAU; // Caucasian (Other)\n\t$lang['ceb'] = _LANGUAGE_CEB; // Cebuano\n\t$lang['cel'] = _LANGUAGE_CEL; // Celtic (Other)\n\t$lang['ces'] = _LANGUAGE_CES; // Czech\n\t$lang['cha'] = _LANGUAGE_CHA; // Chamorro\n\t$lang['chb'] = _LANGUAGE_CHB; // Chibcha\n\t$lang['che'] = _LANGUAGE_CHE; // Chechen\n\t$lang['chg'] = _LANGUAGE_CHG; // Chagatai\n\t$lang['chk'] = _LANGUAGE_CHK; // Chuukese\n\t$lang['chm'] = _LANGUAGE_CHM; // Mari\n\t$lang['chn'] = _LANGUAGE_CHN; // Chinook jargon\n\t$lang['cho'] = _LANGUAGE_CHO; // Choctaw\n\t$lang['chp'] = _LANGUAGE_CHP; // Chipewyan\n\t$lang['chr'] = _LANGUAGE_CHR; // Cherokee\n\t$lang['chu'] = _LANGUAGE_CHU; // Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic\n\t$lang['chv'] = _LANGUAGE_CHV; // Chuvash\n\t$lang['chy'] = _LANGUAGE_CHY; // Cheyenne\n\t$lang['cmc'] = _LANGUAGE_CMC; // Chamic languages\n\t$lang['cop'] = _LANGUAGE_COP; // Coptic\n\t$lang['cor'] = _LANGUAGE_COR; // Cornish\n\t$lang['cos'] = _LANGUAGE_COS; // Corsican\n\t$lang['cpe'] = _LANGUAGE_CPE; // Creoles and pidgins, English based (Other)\n\t$lang['cpf'] = _LANGUAGE_CPF; // Creoles and pidgins, French-based (Other)\n\t$lang['cpp'] = _LANGUAGE_CPP; // Creoles and pidgins,\n\t$lang['cre'] = _LANGUAGE_CRE; // Cree\n\t$lang['crh'] = _LANGUAGE_CRH; // Crimean Tatar; Crimean Turkish\n\t$lang['crp'] = _LANGUAGE_CRP; // Creoles and pidgins (Other)\n\t$lang['csb'] = _LANGUAGE_CSB; // Kashubian\n\t$lang['cus'] = _LANGUAGE_CUS; // Cushitic (Other)\n\t$lang['cym'] = _LANGUAGE_CYM; // Welsh\n\t$lang['dak'] = _LANGUAGE_DAK; // Dakota\n\t$lang['dan'] = _LANGUAGE_DAN; // Danish\n\t$lang['dar'] = _LANGUAGE_DAR; // Dargwa\n\t$lang['day'] = _LANGUAGE_DAY; // Dayak\n\t$lang['del'] = _LANGUAGE_DEL; // Delaware\n\t$lang['den'] = _LANGUAGE_DEN; // Slave (Athapascan)\n\t$lang['deu'] = _LANGUAGE_DEU; // German\n\t$lang['dgr'] = _LANGUAGE_DGR; // Dogrib\n\t$lang['din'] = _LANGUAGE_DIN; // Dinka\n\t$lang['div'] = _LANGUAGE_DIV; // Divehi\n\t$lang['doi'] = _LANGUAGE_DOI; // Dogri\n\t$lang['dra'] = _LANGUAGE_DRA; // Dravidian (Other)\n\t$lang['dsb'] = _LANGUAGE_DSB; // Lower Sorbian\n\t$lang['dua'] = _LANGUAGE_DUA; // Duala\n\t$lang['dum'] = _LANGUAGE_DUM; // Dutch, Middle\n\t$lang['dyu'] = _LANGUAGE_DYU; // Dyula\n\t$lang['dzo'] = _LANGUAGE_DZO; // Dzongkha\n\t$lang['efi'] = _LANGUAGE_EFI; // Efik\n\t$lang['egy'] = _LANGUAGE_EGY; // Egyptian (Ancient)\n\t$lang['eka'] = _LANGUAGE_EKA; // Ekajuk\n\t$lang['ell'] = _LANGUAGE_ELL; // Greek, Modern\n\t$lang['elx'] = _LANGUAGE_ELX; // Elamite\n\t$lang['eng'] = _LANGUAGE_ENG; // English\n\t$lang['enm'] = _LANGUAGE_ENM; // English, Middle\n\t$lang['epo'] = _LANGUAGE_EPO; // Esperanto\n\t$lang['est'] = _LANGUAGE_EST; // Estonian\n\t$lang['eus'] = _LANGUAGE_EUS; // Basque\n\t$lang['ewe'] = _LANGUAGE_EWE; // Ewe\n\t$lang['ewo'] = _LANGUAGE_EWO; // Ewondo\n\t$lang['fan'] = _LANGUAGE_FAN; // Fang\n\t$lang['fao'] = _LANGUAGE_FAO; // Faroese\n\t$lang['fas'] = _LANGUAGE_FAS; // Persian\n\t$lang['fat'] = _LANGUAGE_FAT; // Fanti\n\t$lang['fij'] = _LANGUAGE_FIJ; // Fijian\n\t$lang['fin'] = _LANGUAGE_FIN; // Finnish\n\t$lang['fiu'] = _LANGUAGE_FIU; // Finno-Ugrian (Other)\n\t$lang['fon'] = _LANGUAGE_FON; // Fon\n\t$lang['fra'] = _LANGUAGE_FRA; // French\n\t$lang['frm'] = _LANGUAGE_FRM; // French, Middle\n\t$lang['fro'] = _LANGUAGE_FRO; // French, Old\n\t$lang['fry'] = _LANGUAGE_FRY; // Frisian\n\t$lang['ful'] = _LANGUAGE_FUL; // Fulah\n\t$lang['fur'] = _LANGUAGE_FUR; // Friulian\n\t$lang['gaa'] = _LANGUAGE_GAA; // Ga\n\t$lang['gay'] = _LANGUAGE_GAY; // Gayo\n\t$lang['gba'] = _LANGUAGE_GBA; // Gbaya\n\t$lang['gem'] = _LANGUAGE_GEM; // Germanic (Other)\n\t$lang['gez'] = _LANGUAGE_GEZ; // Geez\n\t$lang['gil'] = _LANGUAGE_GIL; // Gilbertese\n\t$lang['gla'] = _LANGUAGE_GLA; // Gaelic; Scottish Gaelic\n\t$lang['gle'] = _LANGUAGE_GLE; // Irish\n\t$lang['glg'] = _LANGUAGE_GLG; // Galician\n\t$lang['glv'] = _LANGUAGE_GLV; // Manx\n\t$lang['gmh'] = _LANGUAGE_GMH; // German, Middle High\n\t$lang['goh'] = _LANGUAGE_GOH; // German, Old High\n\t$lang['gon'] = _LANGUAGE_GON; // Gondi\n\t$lang['gor'] = _LANGUAGE_GOR; // Gorontalo\n\t$lang['got'] = _LANGUAGE_GOT; // Gothic\n\t$lang['grb'] = _LANGUAGE_GRB; // Grebo\n\t$lang['grc'] = _LANGUAGE_GRC; // Greek, Ancient\n\t$lang['grn'] = _LANGUAGE_GRN; // Guarani\n\t$lang['guj'] = _LANGUAGE_GUJ; // Gujarati\n\t$lang['gwi'] = _LANGUAGE_GWI; // Gwich´in\n\t$lang['hai'] = _LANGUAGE_HAI; // Haida\n\t$lang['hat'] = _LANGUAGE_HAT; // Haitian; Haitian Creole\n\t$lang['hau'] = _LANGUAGE_HAU; // Hausa\n\t$lang['haw'] = _LANGUAGE_HAW; // Hawaiian\n\t$lang['heb'] = _LANGUAGE_HEB; // Hebrew\n\t$lang['her'] = _LANGUAGE_HER; // Herero\n\t$lang['hil'] = _LANGUAGE_HIL; // Hiligaynon\n\t$lang['him'] = _LANGUAGE_HIM; // Himachali\n\t$lang['hin'] = _LANGUAGE_HIN; // Hindi\n\t$lang['hit'] = _LANGUAGE_HIT; // Hittite\n\t$lang['hmn'] = _LANGUAGE_HMN; // Hmong\n\t$lang['hmo'] = _LANGUAGE_HMO; // Hiri Motu\n\t$lang['hrv'] = _LANGUAGE_HRV; // Croatian\n\t$lang['hsb'] = _LANGUAGE_HSB; // Upper Sorbian\n\t$lang['hun'] = _LANGUAGE_HUN; // Hungarian\n\t$lang['hup'] = _LANGUAGE_HUP; // Hupa\n\t$lang['hye'] = _LANGUAGE_HYE; // Armenian\n\t$lang['iba'] = _LANGUAGE_IBA; // Iban\n\t$lang['ibo'] = _LANGUAGE_IBO; // Igbo\n\t$lang['ido'] = _LANGUAGE_IDO; // Ido\n\t$lang['iii'] = _LANGUAGE_III; // Sichuan Yi\n\t$lang['ijo'] = _LANGUAGE_IJO; // Ijo\n\t$lang['iku'] = _LANGUAGE_IKU; // Inuktitut\n\t$lang['ile'] = _LANGUAGE_ILE; // Interlingue\n\t$lang['ilo'] = _LANGUAGE_ILO; // Iloko\n\t$lang['ina'] = _LANGUAGE_INA; // Interlingua (International Auxiliary Language Association)\n\t$lang['inc'] = _LANGUAGE_INC; // Indic (Other)\n\t$lang['ind'] = _LANGUAGE_IND; // Indonesian\n\t$lang['ine'] = _LANGUAGE_INE; // Indo-European (Other)\n\t$lang['inh'] = _LANGUAGE_INH; // Ingush\n\t$lang['ipk'] = _LANGUAGE_IPK; // Inupiaq\n\t$lang['ira'] = _LANGUAGE_IRA; // Iranian (Other)\n\t$lang['iro'] = _LANGUAGE_IRO; // Iroquoian languages\n\t$lang['isl'] = _LANGUAGE_ISL; // Icelandic\n\t$lang['ita'] = _LANGUAGE_ITA; // Italian\n\t$lang['jav'] = _LANGUAGE_JAV; // Javanese\n\t$lang['jbo'] = _LANGUAGE_JBO; // Lojban\n\t$lang['jpn'] = _LANGUAGE_JPN; // Japanese\n\t$lang['jpr'] = _LANGUAGE_JPR; // Judeo-Persian\n\t$lang['jrb'] = _LANGUAGE_JRB; // Judeo-Arabic\n\t$lang['kaa'] = _LANGUAGE_KAA; // Kara-Kalpak\n\t$lang['kab'] = _LANGUAGE_KAB; // Kabyle\n\t$lang['kac'] = _LANGUAGE_KAC; // Kachin\n\t$lang['kal'] = _LANGUAGE_KAL; // Kalaallisut; Greenlandic\n\t$lang['kam'] = _LANGUAGE_KAM; // Kamba\n\t$lang['kan'] = _LANGUAGE_KAN; // Kannada\n\t$lang['kar'] = _LANGUAGE_KAR; // Karen\n\t$lang['kas'] = _LANGUAGE_KAS; // Kashmiri\n\t$lang['kat'] = _LANGUAGE_KAT; // Georgian\n\t$lang['kau'] = _LANGUAGE_KAU; // Kanuri\n\t$lang['kaw'] = _LANGUAGE_KAW; // Kawi\n\t$lang['kaz'] = _LANGUAGE_KAZ; // Kazakh\n\t$lang['kbd'] = _LANGUAGE_KBD; // Kabardian\n\t$lang['kha'] = _LANGUAGE_KHA; // Khasi\n\t$lang['khi'] = _LANGUAGE_KHI; // Khoisan (Other)\n\t$lang['khm'] = _LANGUAGE_KHM; // Khmer\n\t$lang['kho'] = _LANGUAGE_KHO; // Khotanese\n\t$lang['kik'] = _LANGUAGE_KIK; // Kikuyu; Gikuyu\n\t$lang['kin'] = _LANGUAGE_KIN; // Kinyarwanda\n\t$lang['kir'] = _LANGUAGE_KIR; // Kirghiz\n\t$lang['kmb'] = _LANGUAGE_KMB; // Kimbundu\n\t$lang['kok'] = _LANGUAGE_KOK; // Konkani\n\t$lang['kom'] = _LANGUAGE_KOM; // Komi\n\t$lang['kon'] = _LANGUAGE_KON; // Kongo\n\t$lang['kor'] = _LANGUAGE_KOR; // Korean\n\t$lang['kos'] = _LANGUAGE_KOS; // Kosraean\n\t$lang['kpe'] = _LANGUAGE_KPE; // Kpelle\n\t$lang['krc'] = _LANGUAGE_KRC; // Karachay-Balkar\n\t$lang['kro'] = _LANGUAGE_KRO; // Kru\n\t$lang['kru'] = _LANGUAGE_KRU; // Kurukh\n\t$lang['kua'] = _LANGUAGE_KUA; // Kuanyama; Kwanyama\n\t$lang['kum'] = _LANGUAGE_KUM; // Kumyk\n\t$lang['kur'] = _LANGUAGE_KUR; // Kurdish\n\t$lang['kut'] = _LANGUAGE_KUT; // Kutenai\n\t$lang['lad'] = _LANGUAGE_LAD; // Ladino\n\t$lang['lah'] = _LANGUAGE_LAH; // Lahnda\n\t$lang['lam'] = _LANGUAGE_LAM; // Lamba\n\t$lang['lao'] = _LANGUAGE_LAO; // Lao\n\t$lang['lat'] = _LANGUAGE_LAT; // Latin\n\t$lang['lav'] = _LANGUAGE_LAV; // Latvian\n\t$lang['lez'] = _LANGUAGE_LEZ; // Lezghian\n\t$lang['lim'] = _LANGUAGE_LIM; // Limburgan; Limburger; Limburgish\n\t$lang['lin'] = _LANGUAGE_LIN; // Lingala\n\t$lang['lit'] = _LANGUAGE_LIT; // Lithuanian\n\t$lang['lol'] = _LANGUAGE_LOL; // Mongo\n\t$lang['loz'] = _LANGUAGE_LOZ; // Lozi\n\t$lang['ltz'] = _LANGUAGE_LTZ; // Luxembourgish; Letzeburgesch\n\t$lang['lua'] = _LANGUAGE_LUA; // Luba-Lulua\n\t$lang['lub'] = _LANGUAGE_LUB; // Luba-Katanga\n\t$lang['lug'] = _LANGUAGE_LUG; // Ganda\n\t$lang['lui'] = _LANGUAGE_LUI; // Luiseno\n\t$lang['lun'] = _LANGUAGE_LUN; // Lunda\n\t$lang['luo'] = _LANGUAGE_LUO; // Luo (Kenya and Tanzania)\n\t$lang['lus'] = _LANGUAGE_LUS; // lushai\n\t$lang['mad'] = _LANGUAGE_MAD; // Madurese\n\t$lang['mag'] = _LANGUAGE_MAG; // Magahi\n\t$lang['mah'] = _LANGUAGE_MAH; // Marshallese\n\t$lang['mai'] = _LANGUAGE_MAI; // Maithili\n\t$lang['mak'] = _LANGUAGE_MAK; // Makasar\n\t$lang['mal'] = _LANGUAGE_MAL; // Malayalam\n\t$lang['man'] = _LANGUAGE_MAN; // Mandingo\n\t$lang['map'] = _LANGUAGE_MAP; // Austronesian (Other)\n\t$lang['mar'] = _LANGUAGE_MAR; // Marathi\n\t$lang['mas'] = _LANGUAGE_MAS; // Masai\n\t$lang['mdf'] = _LANGUAGE_MDF; // Moksha\n\t$lang['mdr'] = _LANGUAGE_MDR; // Mandar\n\t$lang['men'] = _LANGUAGE_MEN; // Mende\n\t$lang['mga'] = _LANGUAGE_MGA; // Irish, Middle\n\t$lang['mic'] = _LANGUAGE_MIC; // Micmac\n\t$lang['min'] = _LANGUAGE_MIN; // Minangkabau\n\t$lang['mis'] = _LANGUAGE_MIS; // Miscellaneous languages\n\t$lang['mkd'] = _LANGUAGE_MKD; // Macedonian\n\t$lang['mkh'] = _LANGUAGE_MKH; // Mon-Khmer (Other)\n\t$lang['mlg'] = _LANGUAGE_MLG; // Malagasy\n\t$lang['mlt'] = _LANGUAGE_MLT; // Maltese\n\t$lang['mnc'] = _LANGUAGE_MNC; // Manchu\n\t$lang['mni'] = _LANGUAGE_MNI; // Manipuri\n\t$lang['mno'] = _LANGUAGE_MNO; // Manobo languages\n\t$lang['moh'] = _LANGUAGE_MOH; // Mohawk\n\t$lang['mol'] = _LANGUAGE_MOL; // Moldavian\n\t$lang['mon'] = _LANGUAGE_MON; // Mongolian\n\t$lang['mos'] = _LANGUAGE_MOS; // Mossi\n\t$lang['mri'] = _LANGUAGE_MRI; // Maori\n\t$lang['msa'] = _LANGUAGE_MSA; // Malay\n\t$lang['mul'] = _LANGUAGE_MUL; // Multiple languages\n\t$lang['mun'] = _LANGUAGE_MUN; // Munda languages\n\t$lang['mus'] = _LANGUAGE_MUS; // Creek\n\t$lang['mwr'] = _LANGUAGE_MWR; // Marwari\n\t$lang['mya'] = _LANGUAGE_MYA; // Burmese\n\t$lang['myn'] = _LANGUAGE_MYN; // Mayan languages\n\t$lang['myv'] = _LANGUAGE_MYV; // Erzya\n\t$lang['nah'] = _LANGUAGE_NAH; // Nahuatl\n\t$lang['nai'] = _LANGUAGE_NAI; // North American Indian\n\t$lang['nap'] = _LANGUAGE_NAP; // Neapolitan\n\t$lang['nau'] = _LANGUAGE_NAU; // Nauru\n\t$lang['nav'] = _LANGUAGE_NAV; // Navajo; Navaho\n\t$lang['nbl'] = _LANGUAGE_NBL; // Ndebele, South; South Ndebele\n\t$lang['nde'] = _LANGUAGE_NDE; // Ndebele, North; North Ndebele\n\t$lang['ndo'] = _LANGUAGE_NDO; // Ndonga\n\t$lang['nds'] = _LANGUAGE_NDS; // Low German; Low Saxon; German, Low; Saxon, Low\n\t$lang['nep'] = _LANGUAGE_NEP; // Nepali\n\t$lang['new'] = _LANGUAGE_NEW; // Newari; Nepal Bhasa\n\t$lang['nia'] = _LANGUAGE_NIA; // Nias\n\t$lang['nic'] = _LANGUAGE_NIC; // Niger-Kordofanian (Other)\n\t$lang['niu'] = _LANGUAGE_NIU; // Niuean\n\t$lang['nld'] = _LANGUAGE_NLD; // Dutch; Flemish\n\t$lang['nno'] = _LANGUAGE_NNO; // Norwegian Nynorsk; Nynorsk, Norwegian\n\t$lang['nob'] = _LANGUAGE_NOB; // Norwegian Bokmċl; Bokmċl, Norwegian\n\t$lang['nog'] = _LANGUAGE_NOG; // Nogai\n\t$lang['non'] = _LANGUAGE_NON; // Norse, Old\n\t$lang['nor'] = _LANGUAGE_NOR; // Norwegian\n\t$lang['nso'] = _LANGUAGE_NSO; // Sotho, Northern\n\t$lang['nub'] = _LANGUAGE_NUB; // Nubian languages\n\t$lang['nwc'] = _LANGUAGE_NWC; // Classical Newari; Old Newari; Classical Nepal Bhasa\n\t$lang['nya'] = _LANGUAGE_NYA; // Chichewa; Chewa; Nyanja\n\t$lang['nym'] = _LANGUAGE_NYM; // Nyamwezi\n\t$lang['nyn'] = _LANGUAGE_NYN; // Nyankole\n\t$lang['nyo'] = _LANGUAGE_NYO; // Nyoro\n\t$lang['nzi'] = _LANGUAGE_NZI; // Nzima\n\t$lang['oci'] = _LANGUAGE_OCI; // Occitan; Provençal\n\t$lang['oji'] = _LANGUAGE_OJI; // Ojibwa\n\t$lang['ori'] = _LANGUAGE_ORI; // Oriya\n\t$lang['orm'] = _LANGUAGE_ORM; // Oromo\n\t$lang['osa'] = _LANGUAGE_OSA; // Osage\n\t$lang['oss'] = _LANGUAGE_OSS; // Ossetian; Ossetic\n\t$lang['ota'] = _LANGUAGE_OTA; // Turkish, Ottoman\n\t$lang['oto'] = _LANGUAGE_OTO; // Otomian languages\n\t$lang['paa'] = _LANGUAGE_PAA; // Papuan (Other)\n\t$lang['pag'] = _LANGUAGE_PAG; // Pangasinan\n\t$lang['pal'] = _LANGUAGE_PAL; // Pahlavi\n\t$lang['pam'] = _LANGUAGE_PAM; // Pampanga\n\t$lang['pan'] = _LANGUAGE_PAN; // Panjabi; Punjabi\n\t$lang['pap'] = _LANGUAGE_PAP; // Papiamento\n\t$lang['pau'] = _LANGUAGE_PAU; // Palauan\n\t$lang['peo'] = _LANGUAGE_PEO; // Persian, Old\n\t$lang['phi'] = _LANGUAGE_PHI; // Philippine (Other)\n\t$lang['phn'] = _LANGUAGE_PHN; // Phoenician\n\t$lang['pli'] = _LANGUAGE_PLI; // Pali\n\t$lang['pol'] = _LANGUAGE_POL; // Polish\n\t$lang['pon'] = _LANGUAGE_PON; // Pohnpeian\n\t$lang['por'] = _LANGUAGE_POR; // Portuguese\n\t$lang['pra'] = _LANGUAGE_PRA; // Prakrit languages\n\t$lang['pro'] = _LANGUAGE_PRO; // Provençal, Old\n\t$lang['pus'] = _LANGUAGE_PUS; // Pushto\n\t$lang['qaa-qtz'] = _LANGUAGE_QAA_QTZ; // Reserved for local use\n\t$lang['que'] = _LANGUAGE_QUE; // Quechua\n\t$lang['raj'] = _LANGUAGE_RAJ; // Rajasthani\n\t$lang['rap'] = _LANGUAGE_RAP; // Rapanui\n\t$lang['rar'] = _LANGUAGE_RAR; // Rarotongan\n\t$lang['roa'] = _LANGUAGE_ROA; // Romance (Other)\n\t$lang['roh'] = _LANGUAGE_ROH; // Raeto-Romance\n\t$lang['rom'] = _LANGUAGE_ROM; // Romany\n\t$lang['ron'] = _LANGUAGE_RON; // Romanian\n\t$lang['run'] = _LANGUAGE_RUN; // Rundi\n\t$lang['rus'] = _LANGUAGE_RUS; // Russian\n\t$lang['sad'] = _LANGUAGE_SAD; // Sandawe\n\t$lang['sag'] = _LANGUAGE_SAG; // Sango\n\t$lang['sah'] = _LANGUAGE_SAH; // Yakut\n\t$lang['sai'] = _LANGUAGE_SAI; // South American Indian (Other)\n\t$lang['sal'] = _LANGUAGE_SAL; // Salishan languages\n\t$lang['sam'] = _LANGUAGE_SAM; // Samaritan Aramaic\n\t$lang['san'] = _LANGUAGE_SAN; // Sanskrit\n\t$lang['sas'] = _LANGUAGE_SAS; // Sasak\n\t$lang['sat'] = _LANGUAGE_SAT; // Santali\n\t$lang['sco'] = _LANGUAGE_SCO; // Scots\n\t$lang['scr'] = _LANGUAGE_SCR; // Serbo-Croatian\n\t$lang['sel'] = _LANGUAGE_SEL; // Selkup\n\t$lang['sem'] = _LANGUAGE_SEM; // Semitic (Other)\n\t$lang['sga'] = _LANGUAGE_SGA; // Irish, Old\n\t$lang['sgn'] = _LANGUAGE_SGN; // Sign Languages\n\t$lang['shn'] = _LANGUAGE_SHN; // Shan\n\t$lang['sid'] = _LANGUAGE_SID; // Sidamo\n\t$lang['sin'] = _LANGUAGE_SIN; // Sinhalese\n\t$lang['sio'] = _LANGUAGE_SIO; // Siouan languages\n\t$lang['sit'] = _LANGUAGE_SIT; // Sino-Tibetan (Other)\n\t$lang['sla'] = _LANGUAGE_SLA; // Slavic (Other)\n\t$lang['slk'] = _LANGUAGE_SLK; // Slovak\n\t$lang['slv'] = _LANGUAGE_SLV; // Slovenian\n\t$lang['sma'] = _LANGUAGE_SMA; // Southern Sami\n\t$lang['sme'] = _LANGUAGE_SME; // Northern Sami\n\t$lang['smi'] = _LANGUAGE_SMI; // Sami languages (Other)\n\t$lang['smj'] = _LANGUAGE_SMJ; // Lule Sami\n\t$lang['smn'] = _LANGUAGE_SMN; // Inari Sami\n\t$lang['smo'] = _LANGUAGE_SMO; // Samoan\n\t$lang['sms'] = _LANGUAGE_SMS; // Skolt Sami\n\t$lang['sna'] = _LANGUAGE_SNA; // Shona\n\t$lang['snd'] = _LANGUAGE_SND; // Sindhi\n\t$lang['snk'] = _LANGUAGE_SNK; // Soninke\n\t$lang['sog'] = _LANGUAGE_SOG; // Sogdian\n\t$lang['som'] = _LANGUAGE_SOM; // Somali\n\t$lang['son'] = _LANGUAGE_SON; // Songhai\n\t$lang['sot'] = _LANGUAGE_SOT; // Sotho, Southern\n\t$lang['spa'] = _LANGUAGE_SPA; // Spanish; Castilian\n\t$lang['sqi'] = _LANGUAGE_SQI; // Albanian\n\t$lang['srd'] = _LANGUAGE_SRD; // Sardinian\n\t$lang['srp'] = _LANGUAGE_SRP; // Serbian\n\t$lang['srr'] = _LANGUAGE_SRR; // Serer\n\t$lang['ssa'] = _LANGUAGE_SSA; // Nilo-Saharan (Other)\n\t$lang['ssw'] = _LANGUAGE_SSW; // Swati\n\t$lang['suk'] = _LANGUAGE_SUK; // Sukuma\n\t$lang['sun'] = _LANGUAGE_SUN; // Sundanese\n\t$lang['sus'] = _LANGUAGE_SUS; // Susu\n\t$lang['sux'] = _LANGUAGE_SUX; // Sumerian\n\t$lang['swa'] = _LANGUAGE_SWA; // Swahili\n\t$lang['swe'] = _LANGUAGE_SWE; // Swedish\n\t$lang['syr'] = _LANGUAGE_SYR; // Syriac\n\t$lang['tah'] = _LANGUAGE_TAH; // Tahitian\n\t$lang['tai'] = _LANGUAGE_TAI; // Tai (Other)\n\t$lang['tam'] = _LANGUAGE_TAM; // Tamil\n\t$lang['tat'] = _LANGUAGE_TAT; // Tatar\n\t$lang['tel'] = _LANGUAGE_TEL; // Telugu\n\t$lang['tem'] = _LANGUAGE_TEM; // Timne\n\t$lang['ter'] = _LANGUAGE_TER; // Tereno\n\t$lang['tet'] = _LANGUAGE_TET; // Tetum\n\t$lang['tgk'] = _LANGUAGE_TGK; // Tajik\n\t$lang['tgl'] = _LANGUAGE_TGL; // Tagalog\n\t$lang['tha'] = _LANGUAGE_THA; // Thai\n\t$lang['tig'] = _LANGUAGE_TIG; // Tigre\n\t$lang['tir'] = _LANGUAGE_TIR; // Tigrinya\n\t$lang['tiv'] = _LANGUAGE_TIV; // Tiv\n\t$lang['tkl'] = _LANGUAGE_TKL; // Tokelau\n\t$lang['tlh'] = _LANGUAGE_TLH; // Klingon; tlhlngan-Hol\n\t$lang['tli'] = _LANGUAGE_TLI; // Tlingit\n\t$lang['tmh'] = _LANGUAGE_TMH; // Tamashek\n\t$lang['tog'] = _LANGUAGE_TOG; // Tonga (Nyasa)\n\t$lang['ton'] = _LANGUAGE_TON; // Tonga (Tonga Islands)\n\t$lang['tpi'] = _LANGUAGE_TPI; // Tok Pisin\n\t$lang['tsi'] = _LANGUAGE_TSI; // Tsimshian\n\t$lang['tsn'] = _LANGUAGE_TSN; // Tswana\n\t$lang['tso'] = _LANGUAGE_TSO; // Tsonga\n\t$lang['tuk'] = _LANGUAGE_TUK; // Turkmen\n\t$lang['tum'] = _LANGUAGE_TUM; // Tumbuka\n\t$lang['tup'] = _LANGUAGE_TUP; // Tupi languages\n\t$lang['tur'] = _LANGUAGE_TUR; // Turkish\n\t$lang['tut'] = _LANGUAGE_TUT; // Altaic (Other)\n\t$lang['tvl'] = _LANGUAGE_TVL; // Tuvalu\n\t$lang['twi'] = _LANGUAGE_TWI; // Twi\n\t$lang['tyv'] = _LANGUAGE_TYV; // Tuvinian\n\t$lang['udm'] = _LANGUAGE_UDM; // Udmurt\n\t$lang['uga'] = _LANGUAGE_UGA; // Ugaritic\n\t$lang['uig'] = _LANGUAGE_UIG; // Uighur\n\t$lang['ukr'] = _LANGUAGE_UKR; // Ukrainian\n\t$lang['umb'] = _LANGUAGE_UMB; // Umbundu\n\t$lang['und'] = _LANGUAGE_UND; // Undetermined\n\t$lang['urd'] = _LANGUAGE_URD; // Urdu\n\t$lang['uzb'] = _LANGUAGE_UZB; // Uzbek\n\t$lang['vai'] = _LANGUAGE_VAI; // Vai\n\t$lang['ven'] = _LANGUAGE_VEN; // Venda\n\t$lang['vie'] = _LANGUAGE_VIE; // Vietnamese\n\t$lang['vol'] = _LANGUAGE_VOL; // Volapük\n\t$lang['vot'] = _LANGUAGE_VOT; // Votic\n\t$lang['wak'] = _LANGUAGE_WAK; // Wakashan languages\n\t$lang['wal'] = _LANGUAGE_WAL; // Walamo\n\t$lang['war'] = _LANGUAGE_WAR; // Waray\n\t$lang['was'] = _LANGUAGE_WAS; // Washo\n\t$lang['wen'] = _LANGUAGE_WEN; // Sorbian languages\n\t$lang['wln'] = _LANGUAGE_WLN; // Walloon\n\t$lang['wol'] = _LANGUAGE_WOL; // Wolof\n\t$lang['xal'] = _LANGUAGE_XAL; // Kalmyk\n\t$lang['xho'] = _LANGUAGE_XHO; // Xhosa\n\t$lang['yao'] = _LANGUAGE_YAO; // Yao\n\t$lang['yap'] = _LANGUAGE_YAP; // Yapese\n\t$lang['yid'] = _LANGUAGE_YID; // Yiddish\n\t$lang['yor'] = _LANGUAGE_YOR; // Yoruba\n\t$lang['ypk'] = _LANGUAGE_YPK; // Yupik languages\n\t$lang['zap'] = _LANGUAGE_ZAP; // Zapotec\n\t$lang['zen'] = _LANGUAGE_ZEN; // Zenaga\n\t$lang['zha'] = _LANGUAGE_ZHA; // Zhuang; Chuang\n\t$lang['zho'] = _LANGUAGE_ZHO; // Chinese\n\t$lang['znd'] = _LANGUAGE_ZND; // Zande\n\t$lang['zul'] = _LANGUAGE_ZUL; // Zulu\n\t$lang['zun'] = _LANGUAGE_ZUN; // Zuni\n\t// Non-ISO entries are written as x_[language name]\n\t$lang['x_all'] = _ALL; // all languages\n\t$lang['x_brazilian_portuguese'] = _LANGUAGE_X_BRAZILIAN_PORTUGUESE; // Brazilian Portuguese\n\t$lang['x_rus_koi8r'] = _LANGUAGE_X_RUS_KOI8R; // Russian KOI8-R\n\t// end of list\n\treturn $lang;\n}", "function translate($string, $extra = \"\", $language = '')\n{\n $translation = loadTranslation(!$language ? substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2) : $language);\n if ($translation && count($translation)) {\n $translated = '';\n if (array_key_exists($string, $translation)) {\n $translated = $translation[$string];\n $translated .= strlen($extra) ? \"<br/>\" . $extra : \"\";\n } else {\n return $translated = $language != \"en\" ? translate($string, $extra, 'en') : '';\n }\n return $translated;\n } else {\n return '';\n }\n}", "public function translate($text);", "public function chooseLanguage($lang) {\n\t\t$this->_lang = $this->_language[$lang];\n\t}", "function translate($expr, $language) {\n if($expr == \"skladem\") {\n if($language == \"cs\") return \"Máme více než 5 inkoustů skladem!\";\n else { return \"Already more than 5 ink in stock!\"; }\n }\n else if($expr == \"add-ink-to-basket\") {\n if($language == \"cs\") return \"Vložit inkoust do košíku\";\n else { return \"Add ink to cart\"; }\n }\n else if($expr== \"items-in-basket\") {\n if($language == \"cs\") return \"položek v košíku\";\n else { return \"items in basket\"; }\n }\n else if($expr == \"4-days-expeded\") {\n if($language == \"cs\") return \"Odešleme do 4 dnů.\";\n else { return \"Dispatched in 4 days.\"; }\n }\n else if($expr == \"basket-your-basket\") {\n if($language == \"cs\") return \"Váš košík\";\n else { return \"Your basket\"; }\n }\n else if($expr == \"basket-is-empty\") {\n if($language == \"cs\") return \"je <strong>prázdný!</strong>\";\n else { return \"is <strong>empty!</strong>\"; }\n }\n else if($expr== \"basket-total\") {\n if($language == \"cs\") return \"Celkem: \";\n else { return \"Total: \"; }\n }\n else if($expr== \"modra\") {\n if($language == \"cs\") return \"modrá\";\n else { return \"blue\"; }\n }\n else if($expr== \"cerna\") {\n if($language == \"cs\") return \"černá\";\n else { return \"black\"; }\n }\n else if($expr== \"indigo\") {\n if($language == \"cs\") return \"modrofialová\";\n else { return \"indigo\"; }\n }\n else if($expr== \"purpurova\") {\n if($language == \"cs\") return \"purpurová\";\n else { return \"magenta\"; }\n }\n else if($expr== \"zluta\") {\n if($language == \"cs\") return \"žlutá\";\n else { return \"yellow\"; }\n }\n else if($expr== \"selected-color\") {\n if($language == \"cs\") return \"Zvolená barva\";\n else { return \"Selected color\"; }\n }\n else if($expr== \"selected-volume\") {\n if($language == \"cs\") return \"Vybrán objem\";\n else { return \"Bottle volume\"; }\n }\n else if($expr== \"50-ml\") {\n if($language == \"cs\") return \"50 ml\";\n else { return \"50 ml (&Tilde; 0.42 US gill)\"; }\n }\n else if($expr== \"100-ml\") {\n if($language == \"cs\") return \"100 ml\";\n else { return \"100 ml (&Tilde; 0.84 US gill)\"; }\n }\n else if($expr== \"product-overview\") {\n if($language == \"cs\") return \"Přehled všech produktů\";\n else { return \"Product overview\"; }\n }\n else if($expr== \"selection-reset\") {\n if($language == \"cs\") return \"resetovat výběr\";\n else { return \"no sorting\"; }\n }\n else if($expr== \"conditions-of-use\") {\n if($language == \"cs\") return \"Prohlášení\";\n else { return \"Conditions of Use\"; }\n }\n else if($expr== \"your-price\") {\n if($language == \"cs\") return \"Vaše cena\";\n else { return \"Price\"; }\n }\n else if($expr== \"all-products\") {\n if($language == \"cs\") return \"Všechny produkty\";\n else { return \"All products\"; }\n }\n else if($expr == \"producer\") {\n if($language == \"cs\") return \"Dodavatel\";\n else { return \"Producer\"; }\n }\n else if($expr == \"product-code\") {\n if($language == \"cs\") return \"Kód výrobku\";\n else { return \"Product code\"; }\n }\n else if($expr == \"origin\") {\n if($language == \"cs\") return \"Původ\";\n else { return \"Origin\"; }\n }\n else if($expr == \"ink-added-in-basket\") {\n if($language == \"cs\") return \"Inkoust byl přidán do košíku.\";\n else { return \"Ink is added in the cart.\"; }\n }\n else if($expr == \"item-added\") {\n if($language == \"cs\") return \"Zboží přidáno do košíku\";\n else { return \"Item is added in the cart.\"; }\n }\n else if($expr == \"back-to-product\") {\n if($language == \"cs\") return \"Zpátky k produktu\";\n else { return \"Continue shopping\"; }\n }\n else if($expr == \"proceed-to-checkout\") {\n if($language == \"cs\") return \"Přejít do košíku\";\n else { return \"Proceed to checkout\"; }\n }\n else if($expr == \"shopping-basket\") {\n if($language == \"cs\") return \"Nákupní košík\";\n else { return \"Shopping basket\"; }\n }\n else if($expr == \"is-in-stock\") {\n if($language == \"cs\") return \"Dostupnost\";\n else { return \"In stock?\"; }\n }\n else if($expr == \"in-stock\") {\n if($language == \"cs\") return \"Skladem\";\n else { return \"In stock\"; }\n }\n else if($expr == \"count\") {\n if($language == \"cs\") return \"Kusů\";\n else { return \"Count\"; }\n }\n else if($expr == \"price-item\") {\n if($language == \"cs\") return \"Cena/Kus\";\n else { return \"Price/Item\"; }\n }\n else if($expr == \"shipping-packing-fee\") {\n if($language == \"cs\") return \"Dopravné a balné\";\n else { return \"Shipping and packing\"; }\n }\n else if($expr == \"ulozenka-service\") {\n if($language == \"cs\") return \"Síť Úloženka\";\n else { return \"Ulozenka service\"; }\n }\n else if($expr == \"free-shipping\") {\n if($language == \"cs\") return \"Dopravu máte zdarma!\";\n else { return \"For free!\"; }\n }\n else if($expr == \"to-free-shipping-buy\") {\n if($language == \"cs\") return \"Pro dopravu zdarma nutno ještě nakoupit za \";\n else { return \"For free shipping you have to buy items for \"; }\n }\n else if($expr == \"order\") {\n if($language == \"cs\") return \"Objednávka\";\n else { return \"Order\"; }\n }\n else if($expr == \"delivery\") {\n if($language == \"cs\") return \"Způsob doručení\";\n else { return \"Delivery option\"; }\n }\n else if($expr == \"delivery-option\") {\n if($language == \"cs\") return \"Výběr způsobu a místa doručení zásilky.\";\n else { return \"Choose delivery option and destination.\"; }\n }\n else if($expr == \"destination\") {\n if($language == \"cs\") return \"Cílová země\";\n else { return \"Destination country\"; }\n }\n else if($expr == \"shipper\") {\n if($language == \"cs\") return \"Dopravce\";\n else { return \"Shipper\"; }\n }\n else if($expr == \"czech-republic\") {\n if($language == \"cs\") return \"Česká republika\";\n else { return \"Czech republic\"; }\n }\n else if($expr == \"slovak-republic\") {\n if($language == \"cs\") return \"Slovensko\";\n else { return \"Slovakia\"; }\n }\n else if($expr == \"select-ulozenka\") {\n if($language == \"cs\") return \"Vyberte pobočku sítě Úloženka pro vyzvednutí zásilky:\";\n else { return \"Select Ulozenka service branch:\"; }\n }\n else if($expr == \"address\") {\n if($language == \"cs\") return \"Údaje pro doručení a fakturaci\";\n else { return \"Shipping address\"; }\n }\n else if($expr == \"all-required\") {\n if($language == \"cs\") return \"Vyplňte prosím všechny údaje níže!\";\n else { return \"All fields are required!\"; }\n }\n else if($expr == \"billing-info\") {\n if($language == \"cs\") return \"Fakturační údaje\";\n else { return \"Billing information\"; }\n }\n else if($expr == \"fast-information\") {\n if($language == \"cs\") return \"Rychlá navigace\";\n else { return \"Options\"; }\n }\n else if($expr == \"link-to-shop\") {\n if($language == \"cs\") return \"Přejít do obchodu\";\n else { return \"Link to shop\"; }\n }\n}", "private function replaceLangVars($lang) {\r\n $this->template = preg_replace(\"/\\{L_(.*)\\}/isUe\", \"\\$lang[strtolower('\\\\1')]\", $this->template);\r\n }", "function languages($args, &$request) {\n\t\t$this->validate();\n\t\t$this->setupTemplate(true);\n\n\t\t$site =& $request->getSite();\n\n\t\t$templateMgr =& TemplateManager::getManager();\n\t\t$templateMgr->assign('localeNames', AppLocale::getAllLocales());\n\t\t$templateMgr->assign('primaryLocale', $site->getPrimaryLocale());\n\t\t$templateMgr->assign('supportedLocales', $site->getSupportedLocales());\n\t\t$localesComplete = array();\n\t\tforeach (AppLocale::getAllLocales() as $key => $name) {\n\t\t\t$localesComplete[$key] = AppLocale::isLocaleComplete($key);\n\t\t}\n\t\t$templateMgr->assign('localesComplete', $localesComplete);\n\n\t\t$templateMgr->assign('installedLocales', $site->getInstalledLocales());\n\t\t$templateMgr->assign('uninstalledLocales', array_diff(array_keys(AppLocale::getAllLocales()), $site->getInstalledLocales()));\n\t\t$templateMgr->assign('helpTopicId', 'site.siteManagement');\n\n\t\timport('classes.i18n.LanguageAction');\n\t\t$languageAction = new LanguageAction();\n\t\tif ($languageAction->isDownloadAvailable()) {\n\t\t\t$templateMgr->assign('downloadAvailable', true);\n\t\t\t$templateMgr->assign('downloadableLocales', $languageAction->getDownloadableLocales());\n\t\t}\n\n\t\t$templateMgr->display('admin/languages.tpl');\n\t}", "public function getLanguages();" ]
[ "0.68789995", "0.65633744", "0.6555829", "0.6542997", "0.6518918", "0.64979404", "0.64657366", "0.6451491", "0.64221305", "0.64221305", "0.64206755", "0.63374895", "0.6297656", "0.6253792", "0.6238477", "0.62067693", "0.62035066", "0.6193935", "0.6192311", "0.6180268", "0.6178265", "0.6177967", "0.61758673", "0.61653596", "0.614356", "0.61406213", "0.61405903", "0.6124458", "0.60958076", "0.6091844", "0.60694754", "0.60600907", "0.6035507", "0.59929156", "0.5992788", "0.59876424", "0.5979435", "0.5979367", "0.59708416", "0.59642774", "0.59581715", "0.59565824", "0.595435", "0.5953221", "0.59476334", "0.5941675", "0.5937261", "0.59231293", "0.5916185", "0.5914257", "0.59102863", "0.5897467", "0.589678", "0.58904177", "0.5887151", "0.5884003", "0.58809614", "0.58616817", "0.5836553", "0.5831546", "0.5830309", "0.58023596", "0.57987493", "0.57966816", "0.57955736", "0.5789344", "0.5788211", "0.57727265", "0.5768527", "0.57591623", "0.5745495", "0.5745084", "0.57426447", "0.57405066", "0.573352", "0.57330304", "0.5727177", "0.572299", "0.5711951", "0.5711223", "0.5711069", "0.5707702", "0.5707508", "0.57033587", "0.5700426", "0.5694823", "0.569343", "0.56930923", "0.5681843", "0.5680831", "0.56736505", "0.5673078", "0.56698495", "0.5669335", "0.5659885", "0.5659257", "0.5656099", "0.5655866", "0.56538904", "0.56527615", "0.5652047" ]
0.0
-1
Step 3: export default.po file to the relevant directory
function export($site_id,$k,$v) { $filename= 'f' . gmdate('YmdHis'); $path = $this->_UploadDirectoryName($site_id,4); $path .= $v; if (!file_exists($path)){ mkdir($path); } // die; $path .= DS.'LC_MESSAGES'; if (!file_exists($path)) mkdir($path); $file = $path.DS.$filename; if (!file_exists($path)) touch($file); $this->loadModel('Translation'); $file = new File($path.DS.$filename); $tmprec = $this->Translation->find('all', array('conditions' => array('Translation.locale' => $k))); foreach ($tmprec as $rec): $file->write('msgid "' .$rec['Translation']['msgid'] .'"'."\n"); $file->write('msgstr "'.$rec['Translation']['msgstr'].'"'."\n"); endforeach; $file->close(); if (file_exists($path.DS.'default.po')) rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis')); rename ($path.DS.$filename,$path.DS.'default.po'); return 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function passo3() {\n $filename= 'f' . gmdate('YmdHis');\n foreach ($this->langarr as $k => $v):\n\n $path = ROOT.DS.'app'.DS.'locale'.DS.$v;\n if (!file_exists($path)) mkdir($path);\n \t$path .= DS.'LC_MESSAGES';\n if (!file_exists($path)) mkdir($path);\n \t$file = $path.DS.$filename;\n if (!file_exists($path)) touch($file);\n\n $file = new File($path.DS.$filename);\n $tmprec = $this->Traducao->find('all',array('conditions' => array('Traducao.locale' => $k)));\n foreach ($tmprec as $rec):\n $file->write('msgid \"' .$rec['Traducao']['msgid'] .'\"'.\"\\n\");\n $file->write('msgstr \"'.$rec['Traducao']['msgstr'].'\"'.\"\\n\");\n endforeach;\n $file->close();\n\n if (file_exists($path.DS.'default.po'))\n rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis'));\n\t \n rename ($path.DS.$filename,$path.DS.'default.po');\n endforeach;\n }", "public function passo1() {\n $this->Traducao->import('default.pot');\n }", "function load_custom_plugin_translation_file( $mofile, $domain ) { \n\t\n\t// folder location\n\t$folder = WP_PLUGIN_DIR . '/kinogeneva-translations/languages/';\n\t\n\t// filename ending\n\t$file = '-' . get_locale() . '.mo';\n\t\n\t$plugins = array(\n\t\t'buddypress',\n\t\t'bxcft',\n\t\t'wp-user-groups',\n\t\t'kleo_framework',\n\t\t'invite-anyone',\n\t\t'bp-groups-taxo',\n\t\t'bp-docs'\n\t);\n\t\n\tforeach ($plugins as &$plugin) {\n\t\tif ( $plugin === $domain ) {\n\t\t $mofile = $folder.$domain.$file;\n\t }\n\t}\n\n return $mofile;\n\n}", "function load_custom_kinogeneva_translation_file() {\n\t$mofile = WP_PLUGIN_DIR . '/kinogeneva-translations/languages/kinogeneva-' . get_locale() . '.mo';\n\tload_textdomain( 'kinogeneva', $mofile );\n}", "function wp_get_pomo_file_data($po_file)\n {\n }", "function load_default_textdomain($locale = \\null)\n {\n }", "function export_language($k,$v,$export_data,$type) {\n $filename= 'f' . gmdate('YmdHis');\n \n\t $path = ROOT . DS . $type . DS . 'Locale' . DS;\n\t\t\n\t\t $path .= $v;\n if (!file_exists($path)){ mkdir($path); }\n\t\t// die;\n $path .= DS.'LC_MESSAGES';\n\t\t \n if (!file_exists($path)) mkdir($path);\n $file = $path.DS.$filename;\n if (!file_exists($path)) touch($file);\n\t\t$this->loadModel('Translation');\n $file = new File($path.DS.$filename);\n\t\t\n $tmprec = $export_data;\n\t\t\n foreach ($tmprec as $rec):\n $file->write('msgid \"' .$rec['msgid'] .'\"'.\"\\n\");\n $file->write('msgstr \"'.$rec['msgstr'].'\"'.\"\\n\");\n endforeach;\n $file->close();\n\t\t // pr($tmprec); die;\n\n if (file_exists($path.DS.'default.po'))\n rename ($path.DS.'default.po',$path.DS.'default.po.old'.gmdate('YmdHis'));\n\t\t\trename ($path.DS.$filename,$path.DS.'default.po');\n\t\t\t\n\t return 1;\n\t\t\n }", "public function setupPesto() {\n\t\t\t$this->redirect(\"po-setup.php\");\n\t\t}", "protected function makepot( $domain ) {\n\t\t$this->translations = new Translations();\n\n\t\t$meta = $this->get_meta_data();\n\t\tPotGenerator::setCommentBeforeHeaders( $meta['comments'] );\n\n\t\t$this->set_default_headers();\n\n\t\t// POT files have no Language header.\n\t\t$this->translations->deleteHeader( Translations::HEADER_LANGUAGE );\n\n\t\t$this->translations->setDomain( $domain );\n\n\t\t$file_data = $this->get_main_file_data();\n\n\t\t// Extract 'Template Name' headers in theme files.\n\t\tWordPressCodeExtractor::fromDirectory( $this->source, $this->translations, [\n\t\t\t'wpExtractTemplates' => isset( $file_data['Theme Name'] )\n\t\t] );\n\n\t\tunset( $file_data['Version'], $file_data['License'], $file_data['Domain Path'] );\n\n\t\t// Set entries from main file data.\n\t\tforeach ( $file_data as $header => $data ) {\n\t\t\tif ( empty( $data ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$translation = new Translation( '', $data );\n\n\t\t\tif ( isset( $file_data['Theme Name'] ) ) {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the theme', $header ) );\n\t\t\t} else {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the plugin', $header ) );\n\t\t\t}\n\n\t\t\t$this->translations[] = $translation;\n\t\t}\n\n\t\treturn PotGenerator::toFile( $this->translations, $this->destination );\n\t}", "public function welcome_import_message() {\n global $OUTPUT;\n\n $a = get_string('tabutemplatepage2', 'mod_surveypro');\n $message = get_string('welcome_utemplateimport', 'mod_surveypro', $a);\n echo $OUTPUT->notification($message, 'notifymessage');\n }", "function yourls_load_default_textdomain() {\n\t$yourls_locale = yourls_get_locale();\n\n if( !empty( $yourls_locale ) )\n return yourls_load_textdomain( 'default', YOURLS_LANG_DIR . \"/$yourls_locale.mo\" );\n\n return false;\n}", "function joe_uah_load_textdomain() {\n\tload_plugin_textdomain( 'ultimate-admin-helpers', false, basename( __DIR__ ) . '/languages/' );\n}", "function load_textdomain() {\n\n\t\t\tload_theme_textdomain( 'project045', get_template_directory() . '/lang' );\n\n\t\t}", "function simple_login_history_load_textdomain() {\n load_plugin_textdomain('simple-login-history', false, dirname( plugin_basename( __FILE__ )) . '/languages/');\n}", "protected function extract_strings() {\n\t\t$translations = new Translations();\n\n\t\t// Add existing strings first but don't keep headers.\n\t\tif ( ! empty( $this->merge ) ) {\n\t\t\t$existing_translations = new Translations();\n\t\t\tPo::fromFile( $this->merge, $existing_translations );\n\t\t\t$translations->mergeWith( $existing_translations, Merge::ADD | Merge::REMOVE );\n\t\t}\n\n\t\tPotGenerator::setCommentBeforeHeaders( $this->get_file_comment() );\n\n\t\t$this->set_default_headers( $translations );\n\n\t\t// POT files have no Language header.\n\t\t$translations->deleteHeader( Translations::HEADER_LANGUAGE );\n\n\t\t// Only relevant for PO files, not POT files.\n\t\t$translations->setHeader( 'PO-Revision-Date', 'YEAR-MO-DA HO:MI+ZONE' );\n\n\t\tif ( $this->domain ) {\n\t\t\t$translations->setDomain( $this->domain );\n\t\t}\n\n\t\tunset( $this->main_file_data['Version'], $this->main_file_data['License'], $this->main_file_data['Domain Path'], $this->main_file_data['Text Domain'] );\n\n\t\t$is_theme = isset( $this->main_file_data['Theme Name'] );\n\n\t\t// Set entries from main file data.\n\t\tforeach ( $this->main_file_data as $header => $data ) {\n\t\t\tif ( empty( $data ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$translation = new Translation( '', $data );\n\n\t\t\tif ( $is_theme ) {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the theme', $header ) );\n\t\t\t} else {\n\t\t\t\t$translation->addExtractedComment( sprintf( '%s of the plugin', $header ) );\n\t\t\t}\n\n\t\t\t$translations[] = $translation;\n\t\t}\n\n\t\ttry {\n\t\t\tif ( ! $this->skip_php ) {\n\t\t\t\t$options = [\n\t\t\t\t\t// Extract 'Template Name' headers in theme files.\n\t\t\t\t\t'wpExtractTemplates' => $is_theme,\n\t\t\t\t\t// Extract 'Title' and 'Description' headers from pattern files.\n\t\t\t\t\t'wpExtractPatterns' => $is_theme,\n\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t'extensions' => [ 'php' ],\n\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t];\n\t\t\t\tPhpCodeExtractor::fromDirectory( $this->source, $translations, $options );\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_blade ) {\n\t\t\t\t$options = [\n\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t'extensions' => [ 'blade.php' ],\n\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t];\n\t\t\t\tBladeCodeExtractor::fromDirectory( $this->source, $translations, $options );\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_js ) {\n\t\t\t\tJsCodeExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'js', 'jsx' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\tMapCodeExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'map' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_block_json ) {\n\t\t\t\tBlockExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'schema' => JsonSchemaExtractor::BLOCK_JSON_SOURCE,\n\t\t\t\t\t\t'schemaFallback' => JsonSchemaExtractor::BLOCK_JSON_FALLBACK,\n\t\t\t\t\t\t// Only look for block.json files, nothing else.\n\t\t\t\t\t\t'restrictFileNames' => [ 'block.json' ],\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'json' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( ! $this->skip_theme_json ) {\n\t\t\t\t// This will look for the top-level theme.json file, as well as\n\t\t\t\t// any JSON file within the top-level styles/ directory.\n\t\t\t\tThemeJsonExtractor::fromDirectory(\n\t\t\t\t\t$this->source,\n\t\t\t\t\t$translations,\n\t\t\t\t\t[\n\t\t\t\t\t\t'schema' => JsonSchemaExtractor::THEME_JSON_SOURCE,\n\t\t\t\t\t\t'schemaFallback' => JsonSchemaExtractor::THEME_JSON_FALLBACK,\n\t\t\t\t\t\t'include' => $this->include,\n\t\t\t\t\t\t'exclude' => $this->exclude,\n\t\t\t\t\t\t'extensions' => [ 'json' ],\n\t\t\t\t\t\t'addReferences' => $this->location,\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t}\n\t\t} catch ( \\Exception $e ) {\n\t\t\tWP_CLI::error( $e->getMessage() );\n\t\t}\n\n\t\tforeach ( $this->exceptions as $file => $exception_translations ) {\n\t\t\t/** @var Translation $exception_translation */\n\t\t\tforeach ( $exception_translations as $exception_translation ) {\n\t\t\t\tif ( ! $translations->find( $exception_translation ) ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif ( $this->subtract_and_merge ) {\n\t\t\t\t\t$translation = $translations[ $exception_translation->getId() ];\n\t\t\t\t\t$exception_translation->mergeWith( $translation );\n\t\t\t\t}\n\n\t\t\t\tunset( $translations[ $exception_translation->getId() ] );\n\t\t\t}\n\n\t\t\tif ( $this->subtract_and_merge ) {\n\t\t\t\tPotGenerator::toFile( $exception_translations, $file );\n\t\t\t}\n\t\t}\n\n\t\tif ( ! $this->skip_audit ) {\n\t\t\t$this->audit_strings( $translations );\n\t\t}\n\n\t\treturn $translations;\n\t}", "function _textdomain($domain)\r\n\t{\r\n\t\tglobal $default_domain;\r\n\t\t$default_domain = $domain;\r\n\t}", "protected function _writeLocale()\n {\n $text = $this->_tpl['locale'];\n \n $file = $this->_class_dir . DIRECTORY_SEPARATOR . \"/Locale/en_US.php\";\n if (file_exists($file)) {\n $this->_outln('Locale file exists.');\n } else {\n $this->_outln('Writing locale file.');\n file_put_contents($file, $text);\n }\n }", "function apologize($message) \n\t{\t\n\t\trequire_once(\"templates/apology.php\");\n\t\texit;\n\t}", "public function load_translation() {\n\t\t\t$locale = apply_filters( 'plugin_locale', determine_locale(), 'sv_core' );\n\t\t\tload_textdomain( 'sv_core', dirname( __FILE__ ) . '/languages/sv_core-'.$locale.'.mo' );\n\t\t}", "function _jsPo() {\n\t\t$Folder = new Folder(APP . 'locale');\n\t\tlist($locales, $potFiles) = $Folder->read();\n\t\tif (!in_array('javascript.pot', $potFiles)) {\n\t\t\t$this->out(__d('mi', 'The javascript.pot file wasn\\'t found - run cake mi_i18n to generate it', true));\n\t\t\treturn;\n\t\t}\n\t\tif (defined('DEFAULT_LANGUAGE')) {\n\t\t\t$locales = array_unique(am(array(DEFAULT_LANGUAGE), $locales));\n\t\t}\n\t\tif (!class_exists('I18n')) {\n\t\t\tApp::import('Core', 'i18n');\n\t\t}\n\n\t\t$messages = array();\n\t\tforeach ($locales as $locale) {\n\t\t\tif ($locale[0] === '.') {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$data = Cache::read('javascript_' . $locale, '_cake_core_');\n\t\t\tif (!$data) {\n\t\t\t\tConfigure::write('Config.language', $locale);\n\t\t\t\t__d('javascript', 'foo', true);\n\t\t\t\t$inst =& I18n::getInstance();\n\t\t\t\tCache::write('javascript_' . $locale, array_filter($inst->__domains), '_cake_core_');\n\t\t\t\t$data = Cache::read('javascript_' . $locale, '_cake_core_');\n\t\t\t\tif (!$data) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t}\n\t\t\tforeach($data as $type => $i) {\n\t\t\t\tforeach ($i[$locale]['javascript'] as $lookup => $string) {\n\t\t\t\t\tif (!is_string($string)) {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\t\t\t\t\tif (!$string) {\n\t\t\t\t\t\t$string = $lookup;\n\t\t\t\t\t}\n\t\t\t\t\t$messages[$lookup] = $string;\n\t\t\t\t}\n\t\t\t}\n\t\t\tob_start();\n\t\t\tinclude(dirname(__FILE__) . DS . 'templates' . DS . 'js' . DS . 'po.js');\n\t\t\t$contents = ob_get_clean();\n\t\t\t$targetFile = APP . 'vendors' . DS . 'js' . DS . 'i18n.' . $locale . '.js';\n\t\t\t$File = new File($targetFile);\n\t\t\t$File->write($contents);\n\t\t\t$this->out(Debugger::trimPath($targetFile) . ' written');\n\t\t}\n\t}", "function setup()\n{\n custom_locale();\n\n Main::init();\n\n do_action( 'root_setup' );\n}", "protected function getLocalLangFileName() {}", "function load_textdomain($domain, $mofile, $locale = \\null)\n {\n }", "private function verify_single_language_file($name){\n\t\t// Clear lang variable\n\t\t$this->zajlib->lang->reset_variables();\n\t\t// Load up a language file explicitly for default lang\n\t\t$default_locale = $this->zajlib->lang->get_default_locale();\n\t\t$res = $this->zajlib->lang->load($name.'.'.$default_locale.'.lang.ini', false, false, false);\n\t\tif(!$res) $this->zajlib->test->notice(\"<strong>Could not find default locale lang file!</strong> Not having lang files for default locale may cause fatal errors. We could not find this one: $name.$default_locale.lang.ini.\");\n\t\telse{\n\t\t\t$default_array = (array) $this->zajlib->lang->variable;\n\t\t\t// Load up a language file explicitly\n\t\t\tforeach($this->zajlib->lang->get_locales() as $locale){\n\t\t\t\tif($locale != $default_locale){\n\t\t\t\t\t$this->zajlib->lang->reset_variables();\n\t\t\t\t\t$file = $this->zajlib->lang->load($name.'.'.$locale.'.lang.ini', false, false, false);\n\t\t\t\t\tif($file){\n\t\t\t\t\t\t$my_array = (array) $this->zajlib->lang->variable;\n\t\t\t\t\t\t$diff_keys = array_diff_key($default_array, $my_array);\n\t\t\t\t\t\tif(count($diff_keys) > 0){\n\t\t\t\t\t\t\t$this->zajlib->test->notice(\"Not all translations from $default_locale found in $locale ($name). Missing the following keys: \".join(', ', array_keys($diff_keys)));\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$rev_diff_keys = array_diff_key($my_array, $default_array);\n\t\t\t\t\t\tif(count($rev_diff_keys) > 0){\n\t\t\t\t\t\t\t$this->zajlib->test->notice(\"Some translations in $locale are not found in the default $default_locale locale ($name). Missing the following keys: \".join(', ', array_keys($rev_diff_keys)));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function create_default_script() {\n\tcopy(\"defaultscript.txt\", \"scripts/untitled\");\n}", "public function localization_setup() {\n load_plugin_textdomain( 'wc-mailerlite', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n }", "function main() {\n\t\t$this->out(__('I18n Shell', true));\n\t\t$this->hr();\n\t\t$this->out(__('[E]xtract POT file from sources', true));\n\t\t$this->out(__('[I]nitialize i18n database table', true));\n\t\t$this->out(__('[H]elp', true));\n\t\t$this->out(__('[Q]uit', true));\n\n\t\t$choice = strtolower($this->in(__('What would you like to do?', true), array('E', 'I', 'H', 'Q')));\n\t\tswitch ($choice) {\n\t\t\tcase 'e':\n\t\t\t\t$this->Extract->execute();\n\t\t\tbreak;\n\t\t\tcase 'i':\n\t\t\t\t$this->initdb();\n\t\t\tbreak;\n\t\t\tcase 'h':\n\t\t\t\t$this->help();\n\t\t\tbreak;\n\t\t\tcase 'q':\n\t\t\t\texit(0);\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$this->out(__('You have made an invalid selection. Please choose a command to execute by entering E, I, H, or Q.', true));\n\t\t}\n\t\t$this->hr();\n\t\t$this->main();\n\t}", "public function translations()\n {\n $this->loadTranslationsFrom(__DIR__.'/Resources/Lang', $this->packageName);\n\n $this->publishes([\n __DIR__.'/path/to/translations' => resource_path('lang/vendor/courier'),\n ], $this->packageName.'-translations');\n }", "function translation() {\n\t\t\n\t\t// only use, if we have it...\n\t\tif( function_exists('load_plugin_textdomain') ) {\n\t\t\n\t\t\t// load it\n\t\t\tload_plugin_textdomain( \n\t\t\t\n\t\t\t\t// unique name\n\t\t\t\t'cp-multisite', \n\t\t\t\t\n\t\t\t\t// deprecated argument\n\t\t\t\tfalse,\n\t\t\t\t\n\t\t\t\t// path to directory containing translation files\n\t\t\t\tplugin_dir_path( CPMU_PLUGIN_FILE ) . 'languages/'\n\t\t\t\t\n\t\t\t);\n\t\t\t\n\t\t}\n\t\t\n\t}", "public function plugin_textdomain() {\n load_plugin_textdomain( CUSTOM_LOGIN_DIRNAME, false, CUSTOM_LOGIN_DIRNAME . '/languages/' );\n }", "protected function set_default_headers() {\n\t\t$meta = $this->get_meta_data();\n\n\t\t$this->translations->setHeader( 'Project-Id-Version', $meta['name'] . ' ' . $meta['version'] );\n\t\t$this->translations->setHeader( 'Report-Msgid-Bugs-To', $meta['msgid-bugs-address'] );\n\t\t$this->translations->setHeader( 'Last-Translator', 'FULL NAME <EMAIL@ADDRESS>' );\n\t\t$this->translations->setHeader( 'Language-Team', 'LANGUAGE <[email protected]>' );\n\t}", "function i18n() {\n\tload_theme_textdomain( 'project', Project_PATH . '/languages' );\n }", "function install_single_pages($pkg)\n {\n // $directoryDefault->update(array('cName' => t('Sample Package'), 'cDescription' => t('Sample Package')));\n }", "function load_muplugin_textdomain($domain, $mu_plugin_rel_path = '')\n {\n }", "function yourls_load_custom_textdomain( $domain, $path ) {\n\t$locale = yourls_apply_filter( 'load_custom_textdomain', yourls_get_locale(), $domain );\n if( !empty( $locale ) ) {\n $mofile = rtrim( $path, '/' ) . '/'. $domain . '-' . $locale . '.mo';\n return yourls_load_textdomain( $domain, $mofile );\n }\n}", "function hybrid_load_textdomain_mofile( $mofile, $domain ) {\n\n\t/* If the $domain is for the parent or child theme, search for a $domain-$locale.mo file. */\n\tif ( $domain == hybrid_get_parent_textdomain() || $domain == hybrid_get_child_textdomain() ) {\n\n\t\t/* Check for a $domain-$locale.mo file in the parent and child theme root and /languages folder. */\n\t\t$locale = get_locale();\n\t\t$locate_mofile = locate_template( array( \"languages/{$domain}-{$locale}.mo\", \"{$domain}-{$locale}.mo\" ) );\n\n\t\t/* If a mofile was found based on the given format, set $mofile to that file name. */\n\t\tif ( !empty( $locate_mofile ) )\n\t\t\t$mofile = $locate_mofile;\n\t}\n\n\t/* Return the $mofile string. */\n\treturn $mofile;\n}", "private function export()\n {\n $translationLocale = $this->ask('In which language do you want to translate?', 'en');\n if ($translationLocale == $this->manager->getDefaultLocale()) {\n $this->warn('It is not possible to translate the default language');\n\n return;\n }\n\n /**\n * Create export file.\n */\n $file = fopen('translation_'.$this->manager->getDefaultLocale().'-'.$translationLocale.'.csv', 'w');\n fputcsv($file, ['translation_string', $this->manager->getDefaultLocale(), $translationLocale], $this->csvSeperator);\n\n if ($this->option('overwrite')) {\n $translations = $this->manager->getTranslationValues($this->manager->getDefaultLocale());\n } else {\n $translations = $this->manager->getUntranslatedValues(\n $this->manager->getDefaultLocale(),\n $translationLocale\n );\n }\n\n foreach ($translations as $key => $value) {\n fputcsv($file, [$key, $value, ''], $this->csvSeperator);\n }\n fclose($file);\n }", "public function localization_setup() {\n load_plugin_textdomain( 'baseplugin', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n }", "public function i18n() {\r\n load_plugin_textdomain( 'woolentor-pro', false, dirname( plugin_basename( WOOLENTOR_ADDONS_PL_ROOT_PRO ) ) . '/languages/' );\r\n }", "private function readOriginal(): void\n {\n $this->translation = $this->translation->withOriginal($this->readIdentifier('msgid', true));\n }", "function mbifthen_load_textdomain() {\r\n\tload_plugin_textdomain( 'multibanco-ifthen-software-gateway-for-woocommerce', false, dirname( plugin_basename( __FILE__ ) ).'/lang/' );\r\n}", "function bindtextdomain($domain, $directory) {\n global $faketext, $valid_languages, $supported_languages;\n \n // New language config to detect language\n $language_config = new LANGUAGE_CONFIG($valid_languages, $supported_languages, false);\n $faketext_lang = $language_config->detectCurrentLanguage();\n \n // Path to .po file\n $po = \"{$directory}/{$faketext_lang}/LC_MESSAGES/{$domain}.po\";\n \n if (file_exists($po)) {\n $contents = file_get_contents($po);\n }\n else {\n // If the .po wasn't found, try replacing dashes with underscores in locale\n $formatted_lang = str_replace('-', '_', $faketext_lang);\n $po = \"{$directory}/{$formatted_lang}/LC_MESSAGES/{$domain}.po\";\n if (file_exists($po)) {\n $contents = file_get_contents($po);\n }\n else {\n // .po not found, return\n return false;\n }\n }\n \n // Remove header information;\n $contents = substr($contents, strpos($contents, \"\\n\\n\"));\n \n // Un-escape quotes\n $contents = str_replace('\\\"', '\"', $contents);\n \n // Parse strings\n preg_match_all('/msgid\\s+\"(.+?)\"\\s*(msgid_plural\\s+\"(.+?)\"\\s*)?((msgstr(\\[\\d+\\])?\\s+?\"(.+?)\"\\s*)+)(#|msg)/is', $contents, $localeMatches, PREG_SET_ORDER);\n \n // Make pretty key => value array\n foreach ($localeMatches as $localeMatch) {\n // Determine if this is a plural entry\n if (strpos($localeMatch[2], 'msgid_plural') !== false) {\n // If plural, parse each string\n $plurals = array();\n preg_match_all('/msgstr(\\[\\d+\\])?\\s+?\"(.+?)\"\\s*/is', $localeMatch[4], $pluralMatches, PREG_SET_ORDER);\n \n foreach ($pluralMatches as $pluralMatch) {\n $plurals[] = str_replace(\"\\\"\\n\\\"\", '', $pluralMatch[2]);\n }\n \n $faketext[$localeMatch[1]] = $plurals;\n }\n else {\n $faketext[$localeMatch[1]] = str_replace(\"\\\"\\n\\\"\", '', $localeMatch[7]);\n }\n }\n }", "protected function langHandle()\n {\n $packageTranslationsPath = __DIR__.'/resources/lang';\n\n $this->loadTranslationsFrom($packageTranslationsPath, 'task-management');\n\n $this->publishes([\n $packageTranslationsPath => resource_path('lang/vendor/task-management'),\n ], 'lang');\n }", "function yourls_load_textdomain( $domain, $mofile ) {\n\tglobal $yourls_l10n;\n\n\t$plugin_override = yourls_apply_filter( 'override_load_textdomain', false, $domain, $mofile );\n\n\tif ( true == $plugin_override ) {\n\t\treturn true;\n\t}\n\n\tyourls_do_action( 'load_textdomain', $domain, $mofile );\n\n\t$mofile = yourls_apply_filter( 'load_textdomain_mofile', $mofile, $domain );\n\n\tif ( !is_readable( $mofile ) ) {\n trigger_error( 'Cannot read file ' . str_replace( YOURLS_ABSPATH.'/', '', $mofile ) . '.'\n . ' Make sure there is a language file installed. More info: http://yourls.org/translations' );\n return false;\n }\n\n\t$mo = new MO();\n\tif ( !$mo->import_from_file( $mofile ) )\n return false;\n\n\tif ( isset( $yourls_l10n[$domain] ) )\n\t\t$mo->merge_with( $yourls_l10n[$domain] );\n\n\t$yourls_l10n[$domain] = &$mo;\n\n\treturn true;\n}", "private function publishLanguage()\n {\n if (!file_exists(base_path().'/resources/lang/')) {\n mkdir(base_path().'/resources/lang');\n $this->info('Published language directory in '.base_path().'/resources/lang/');\n }\n }", "public function load_textdomain()\n {\n }", "public function load_textdomain() {\n\t\t// Set filter for plugin's languages directory\n\t\t$lang_dir = dirname( plugin_basename( __FILE__ ) ) . '/languages/';\n\t\t$lang_dir = apply_filters( 'bbp_notices_languages', $lang_dir );\n\n\t\t// Traditional WordPress plugin locale filter\n\t\t$locale = apply_filters( 'plugin_locale', get_locale(), 'bbpress-notices' );\n\t\t$mofile = sprintf( '%1$s-%2$s.mo', 'bbpress-notices', $locale );\n\n\t\t// Setup paths to current locale file\n\t\t$mofile_local = $lang_dir . $mofile;\n\t\t$mofile_global = WP_LANG_DIR . '/bbpress-notices/' . $mofile;\n\n\t\tif ( file_exists( $mofile_global ) ) {\n\t\t\t// Look in global /wp-content/languages/bbpress-notices folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_global );\n\t\t} elseif ( file_exists( $mofile_local ) ) {\n\t\t\t// Look in local /wp-content/plugins/bbpress-notices/languages/ folder\n\t\t\tload_textdomain( 'bbpress-notices', $mofile_local );\n\t\t} else {\n\t\t\t// Load the default language files\n\t\t\tload_plugin_textdomain( 'bbpress-notices', false, $lang_dir );\n\t\t}\n\t}", "public function load_textdomain() {\n\n\t\t\t// Set filter for plugin's languages directory\n\t\t\t$lang_dir = dirname( plugin_basename( __FILE__ ) ) . '/languages/';\n\t\t\t$lang_dir = apply_filters( 'affwp_direct_link_tracking_languages_directory', $lang_dir );\n\n\t\t\t// Traditional WordPress plugin locale filter\n\t\t\t$locale = apply_filters( 'plugin_locale', get_locale(), 'affiliatewp-direct-link-tracking' );\n\t\t\t$mofile = sprintf( '%1$s-%2$s.mo', 'affiliatewp-direct-link-tracking', $locale );\n\n\t\t\t// Setup paths to current locale file\n\t\t\t$mofile_local = $lang_dir . $mofile;\n\t\t\t$mofile_global = WP_LANG_DIR . '/affiliatewp-direct-link-tracking/' . $mofile;\n\n\t\t\tif ( file_exists( $mofile_global ) ) {\n\t\t\t\t// Look in global /wp-content/languages/affiliatewp-direct-link-tracking/ folder\n\t\t\t\tload_textdomain( 'affiliatewp-direct-link-tracking', $mofile_global );\n\t\t\t} elseif ( file_exists( $mofile_local ) ) {\n\t\t\t\t// Look in local /wp-content/plugins/affiliatewp-plugin-template/languages/ folder\n\t\t\t\tload_textdomain( 'affiliatewp-direct-link-tracking', $mofile_local );\n\t\t\t} else {\n\t\t\t\t// Load the default language files\n\t\t\t\tload_plugin_textdomain( 'affiliatewp-direct-link-tracking', false, $lang_dir );\n\t\t\t}\n\t\t}", "function dreams_load_admin_textdomain_in_front() {\r\n\tif (!is_admin()) {\r\n\t\tload_textdomain('default', WP_LANG_DIR . '/admin-' . get_locale() . '.mo');\r\n\t}\r\n}", "public function createPackageFile()\n\t{\n\t\t$packageFilePath = __DIR__ . \"/templates/packagefile.txt\";\n\n\t\t// If file exists, copy content into new file called package.json in project root.\n\t\tif($this->filesystem->exists($packageFilePath))\n\t\t{\n\t\t\t$this->filesystem->put('package.json', $this->filesystem->get($packageFilePath));\n\t\t}\n\t}", "public function install() {\n $strReturn = \"\";\n\n $strReturn .= \"Assigning null-properties and elements to the default language.\\n\";\n if($this->strContentLanguage == \"de\") {\n\n $strReturn .= \" Target language: de\\n\";\n\n if(class_exists(\"class_module_pages_page\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_page\") !== false)\n class_module_pages_page::assignNullProperties(\"de\", true);\n if(class_exists(\"class_module_pages_pageelement\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_pageelement\") !== false)\n class_module_pages_pageelement::assignNullElements(\"de\");\n\n $objLang = new class_module_languages_language();\n $objLang->setStrAdminLanguageToWorkOn(\"de\");\n }\n else {\n\n $strReturn .= \" Target language: en\\n\";\n\n if(class_exists(\"class_module_pages_page\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_page\") !== false)\n class_module_pages_page::assignNullProperties(\"en\", true);\n if(class_exists(\"class_module_pages_pageelement\", false) || class_classloader::getInstance()->loadClass(\"class_module_pages_pageelement\") !== false)\n class_module_pages_pageelement::assignNullElements(\"en\");\n\n $objLang = new class_module_languages_language();\n $objLang->setStrAdminLanguageToWorkOn(\"en\");\n\n }\n\n\n return $strReturn;\n }", "public function createReadmeFile()\r\n {\r\n $originalFile = realpath(__DIR__ . '/../Resources/files/templates/README');\r\n $newFile = $this->destination_dir.'/README.md';\r\n\r\n $this->createCopiedFile($originalFile, $newFile);\r\n }", "function pmprowoo_gift_levels_email_path($default_templates, $page_name, $type = 'email', $where = 'local', $ext = 'html') {\r\n $default_templates[] = PMPROWC_DIR . \"/email/{$page_name}.{$ext}\";\r\n return $default_templates;\r\n}", "function create_newsletter_page() {\r\n require_once( $plugin_dir . \"email-newsletter-files/page-create-newsletter.php\" );\r\n }", "function svbk_mandrill_emails_init() {\n\tload_plugin_textdomain( 'svbk-mandrill-emails', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n}", "function load_textdomain() {\r\n load_plugin_textdomain( WPC_CLIENT_TEXT_DOMAIN, false, dirname( 'wp-client-client-portals-file-upload-invoices-billing/wp-client-lite.php' ) . '/languages/' );\r\n }", "private function translationWorkaround()\n {\n L10n::__('BudgetMailer Sign Up Form for WordPress');\n L10n::__('BudgetMailer Sign Up');\n }", "function translateFile($kohana_path, $ionize_path) {\n //import kohana lang array\n $kohana_lang = include($kohana_path);\n //import ionize lang array\n $ionize_file = file($ionize_path);\n $ionize_file = checkForReturn($ionize_file);\n\n file_put_contents($ionize_path,$ionize_file);\n $ionize_file = file($ionize_path);\n $ionize_lang = include($ionize_path);\n\n //get index to start adding entries to ionize file at\n foreach($ionize_file as $index=>$item) {\n if(strpos($item, 'return $lang')!== false) {\n $appendLine = $index;\n }\n }\n \n \n /**\n *For each entry in the kohana lang file,\n *check if it exists in the ionize lang file.\n *If it does and translation matches, skip over\n *Else update existing entry or append new entry to file\n */\n foreach($kohana_lang as $key=>$entry) {\n $key_with_slash = str_replace(\"'\", \"\\'\", $key);\n $entry_with_slash = str_replace(\"'\", \"\\'\", $entry);\n \n //check if entry exists\n if(isset($ionize_lang[$key])) {\n //get line from ionize file of entry\n foreach($ionize_file as $index=>$item){\n if(strpos($item,'$lang[' . $key . ']')!== false){\n $line_number = $index;\n }\n }\n //check if entries match\n if($ionize_lang[$key] != $entry) {\n $ionize_file[$line_number] = '$lang[\\'' . $key_with_slash . '\\'] = \\'' . $entry_with_slash . '\\';' . PHP_EOL; \n }\n }\n //if entry does not exist, insert it\n else {\n $ionize_file[$appendLine] = '$lang[\\'' . $key_with_slash . '\\'] = \\'' . $entry_with_slash . '\\';' . PHP_EOL;\n $appendLine++;\n }\n }\n \n //check to see if return $lang exists, if not add it to end of file\n $ionize_file = checkForReturn($ionize_file);\n \n file_put_contents($ionize_path,$ionize_file);\n}", "public function textdomain() {\n\t\tload_plugin_textdomain( 'global-user-password-reset', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t}", "public function localization() {\n\t\t\tload_plugin_textdomain( 'bitlive-custom-codes', false, __DIR__ . '/languages/' );\n\t\t}", "function setup_meta_translation() {\n\t\t\tglobal $post, $wpdb;\n\t\t\t$post_id = $post->ID;\n\t\t\t\n\t\t\tforeach($this->arabic_meta_keys as $key ) {\n\t\t\t\tif ($post_id){\n\t\t\t\t\t$$key = get_post_meta($post_id, $key, true);\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\t$$key = '';\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$the_post = get_post($post_id);\n\t\t\t\n\t\t\tinclude(dirname(__FILE__).'/views/ipc-meta-box-translation.php');\n\t\t}", "function load_script_textdomain($handle, $domain = 'default', $path = '')\n {\n }", "function load_child_theme_textdomain($domain, $path = \\false)\n {\n }", "function positive_panels_lang(){\n\tload_textdomain('positive-panels', 'lang/positive-panels.mo');\n}", "protected function getDefaultImportExportFolder() {}", "protected function getDefaultImportExportFolder() {}", "function freeproduct_textdomain() {\n\tload_plugin_textdomain( 'woocommerce-freeproduct', false, basename( dirname( __FILE__ ) ) . '/lang' );\n}", "function EWD_URP_localization_setup() {\n\t\tload_plugin_textdomain('ultimate-reviews', false, dirname(plugin_basename(__FILE__)) . '/lang/');\n}", "function lang() {\r\n\t\t\tload_plugin_textdomain( 'rv-portfolio', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\r\n\t\t}", "protected function generateLocalLang() {}", "private function translations()\n {\n $this['translator'] = $this->share($this->extend('translator', function ($translator) {\n $translator->addLoader('yaml', new TranslationFileLoader());\n\n $translator->addResource('yaml', 'config/locales/pt-br.yml', 'pt-br');\n $translator->addResource('yaml', 'config/locales/en-us.yml', 'en-us');\n $translator->addResource('yaml', 'config/locales/es-es.yml', 'es-es');\n\n return $translator;\n }));\n }", "public function initLocalization() {\n $moFiles = scandir(trailingslashit($this->dir) . 'languages/');\n foreach ($moFiles as $moFile) {\n if (strlen($moFile) > 3 && substr($moFile, -3) == '.mo' && strpos($moFile, get_locale()) > -1) {\n load_textdomain('WP_Visual_Chat', trailingslashit($this->dir) . 'languages/' . $moFile);\n }\n }\n }", "function get_entry_points()\n\t{\n\t\treturn array_merge(array('misc'=>'WELCOME_EMAILS'),parent::get_entry_points());\n\t}", "public function setup_i18n() {\n\t\tload_plugin_textdomain( 'woocommerce-bundle-rate-shipping', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\n\t}", "function initialize_i18n() {\n\t\n\t$locale \t\t\t\t\t= get_locale();\n\t#error_log( \"got locale: $locale\" );\n\t\n\tif( ! preg_match( '/_/', $locale ) ) {\n\t\t\n\t\t$locale\t\t\t\t\t= $locale.\"_\".strtoupper($locale);\n\t\t#error_log( \"set locale to: $locale\" );\n\t}\n\t\n\tputenv(\"LANG=$locale\");\n\tputenv(\"LC_ALL=$locale\");\n\tsetlocale(LC_ALL, 0);\n\tsetlocale(LC_ALL, $locale);\n\t\n\tif ( file_exists ( realpath ( \"./locale/de/LC_MESSAGES/messages.mo\" ) ) ) {\n\t\t\n\t\t$localepath\t\t\t\t= \"./locale\";\n\t\t\n\t} elseif( file_exists( realpath( \"../locale/de/LC_MESSAGES/messages.mo\" ) ) ) {\n\t\t\n\t\t$localepath\t\t\t\t= \"../locale\";\n\t\t\n\t} else {\n\t\t\n\t\t$localepath\t\t\t\t= \"./locale\";\n\t\t\n\t}\n\t\n\t$dom\t\t\t\t\t\t= bindtextdomain(\"messages\", $localepath);\n\t$msgdom \t\t\t\t\t= textdomain(\"messages\");\n\t\n\tbind_textdomain_codeset(\"messages\", 'UTF-8');\n\n}", "function load_plugin_templates() : void {\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/subscriber-only-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/split-content-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/banner-message.php';\n}", "public function atmf_load_plugin_textdomain(){\n\n $domain = $this->plugin_slug;\n $locale = apply_filters( 'plugin_locale', get_locale(), 'atmf' );\n\n load_textdomain( $domain, trailingslashit( WP_LANG_DIR ) . $domain . '/' . $domain . '-' . $locale . '.mo' );\n load_plugin_textdomain( $domain, FALSE, basename( dirname( __FILE__ ) ) . '/languages/' );\n }", "public static function getTranslationFileDirectory() {\n return PIMCORE_PLUGINS_PATH.\"/PimTools/texts\";\n }", "function kino_load_textdomain() {\n\t\t\t\t\t\t\n\t\t\t// BP group announcements\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'bpga',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\t\t\t// BP group calendar\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'groupcalendar',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\t\t\t// BuddyPress Group Email Subscription\n\t\t\tload_plugin_textdomain( \n\t\t\t\t'bp-ass',\n\t\t\t\tfalse, \n\t\t\t\t'kinogeneva-translations/languages/'\n\t\t\t);\n\t\t\t\n\n}", "function i18n() {\n // Translations can be filed in the /languages/ directory\n load_theme_textdomain('mo_theme', get_template_directory() . '/languages');\n\n $locale = get_locale();\n $locale_file = get_template_directory() . \"/languages/$locale.php\";\n if (is_readable($locale_file))\n require_once($locale_file);\n\n }", "public function load_plugin_textdomain() {\n\n\t\t\t$domain = 'wolf-woocommerce-quickview';\n\t\t\t$locale = apply_filters( 'wolf-woocommerce-quickview', get_locale(), $domain );\n\t\t\tload_textdomain( $domain, WP_LANG_DIR . '/' . $domain . '/' . $domain . '-' . $locale . '.mo' );\n\t\t\tload_plugin_textdomain( $domain, FALSE, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t\t}", "function farmhouse_localization_setup() {\n\n load_child_theme_textdomain( 'farmhouse-theme', CHILD_DIR . '/languages' );\n\n}", "public function load_textdomain() {\n\t\t\t$mo_file_path = dirname( __FILE__ ) . '/languages/' . get_locale() . '.mo';\n\n\t\t\tload_textdomain( 'cherry-framework', $mo_file_path );\n\t\t}", "private function _get_translations_from_file () {\n\n\t\t$lang = file_exists(self::DIR_LANGS . $this->lang . '.php')\n\t\t\t\t\t? $this->lang : $this->_default_lang;\n\n\t\trequire self::DIR_LANGS . $lang . '.php';\n\n\t\treturn $t;\n\n\t}", "function localization() {\n load_plugin_textdomain( 'cynetique-labels', false, dirname( plugin_basename( __FILE__ ) ) . '/language/' );\n}", "function _get_path_to_translation_from_lang_dir($domain)\n {\n }", "function cs_bible_lesson_load_plugin_textdomain() {\r\n load_plugin_textdomain( 'christian-science-bible-lesson-subjects', false, dirname( plugin_basename( __FILE__ ) ) . '/languages' );\r\n}", "function wp_set_script_translations($handle, $domain = 'default', $path = '')\n {\n }", "function __construct() {\n\t\t$this->addTranslation(__FILE__);\n\t}", "public function main() {\n\n $fs = new Filesystem();\n\n $fs->touch($this->getTargetFile());\n\n $seedProperties = Yaml::parse(file_get_contents($this->getSeedFile()));\n $generatedProperties = [];\n\n $generatedProperties['label'] = $seedProperties['project_label'];\n $generatedProperties['machineName'] = $seedProperties['project_name'];\n $generatedProperties['group'] = $seedProperties['project_group'];\n $generatedProperties['basePath'] = '${current.basePath}';\n $generatedProperties['type'] = $seedProperties['project_type'];\n $generatedProperties['repository']['main'] = $seedProperties['project_git_repository'];\n $generatedProperties['php'] = $seedProperties['project_php_version'];\n\n // Add platform information.\n if (isset($generatedProperties['platform'])) {\n $generatedProperties['platform'] = $seedProperties['platform'];\n }\n\n $fs->dumpFile($this->getTargetFile(), Yaml::dump($generatedProperties, 5, 2));\n }", "function initialize_i18n($language) {\n\t$locales_root = \"./Locale\";\n putenv(\"LANG=\" . $language); \n\tputenv(\"LC_ALL=en_us\"); \n\tsetlocale(LC_ALL, $language);\n $domains = glob($locales_root.'/'.$language.'/LC_MESSAGES/messages-*.mo');\t\n\t$newTimeStamp = time();\n $current = basename($domains[0],'.mo');\n $timestamp = preg_replace('{messages-}i','',$current);\n\t$oldFileName = $domains[0];\n\t$newFileName = $locales_root.\"/\".$language.\"/LC_MESSAGES/messages-\".$newTimeStamp.\".mo\";\n\t$newFile = \"messages-\".$newTimeStamp;\n\trename($oldFileName, $newFileName);\n bindtextdomain($newFile,$locales_root);\n\tbind_textdomain_codeset($newFile, 'UTF-8');\n textdomain($newFile);\n}", "function ind_text_domain() {\n\tload_plugin_textdomain('indizar', false, 'indizar/lang');\n}", "public function welcome_apply_message() {\n global $OUTPUT;\n\n $a = new \\stdClass();\n $a->uploadpage = get_string('tabutemplatepage3', 'mod_surveypro');\n $a->savepage = get_string('tabutemplatepage2', 'mod_surveypro');\n $message = get_string('welcome_utemplateapply', 'mod_surveypro', $a);\n echo $OUTPUT->notification($message, 'notifymessage');\n }", "function sec_init() {\n\tload_plugin_textdomain(EVNT_TEXTDOMAIN, false, dirname( plugin_basename( __FILE__ ) ) );\n}", "public function load_plugin_textdomain() {\n\t\tload_plugin_textdomain( 'genesis-simple-hooks', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );\n\t}", "private function generateTranslations() {\n\n $this->doCommand('php artisan medkit:generate-translations');\n }", "private function init_tftp_lang_path() {\n $dir = $this->sccppath[\"tftp_lang_path\"];\n foreach ($this->extconfigs->getextConfig('sccp_lang') as $lang_key => $lang_value) {\n $filename = $dir . DIRECTORY_SEPARATOR . $lang_value['locale'];\n if (!file_exists($filename)) {\n if (!mkdir($filename, 0777, true)) {\n die('Error create lang dir');\n }\n }\n }\n }", "function dust_text_domain() {\n load_plugin_textdomain( 'theme-package', false, DUST_ACC_PATH . '/languages' );\n }", "public function displayDefaultMessageOutputEn()\n {\n // initialize the class with defaults (en_US locale, library path).\n $message = new CustomerMessage();\n\n // we expect the default message, because error 987.654.321 might not exist\n // in the default locale file en_US.csv.\n $this->assertEquals(\n 'An unexpected error occurred. Please contact us to get further information.',\n $message->getMessage('987.654.321')\n );\n }", "public function importInDev()\n\t{\n\t\t\\IPS\\cms\\Theme::importInDev('database');\n\t\t\\IPS\\cms\\Theme::importInDev('page');\n\n\t\t\\IPS\\Output::i()->redirect( \\IPS\\Http\\Url::internal( 'app=cms&module=pages&controller=templates' ), 'completed' );\n\t}" ]
[ "0.6214595", "0.5613027", "0.55432606", "0.548601", "0.54811805", "0.5459091", "0.5450491", "0.54060787", "0.5398861", "0.5372326", "0.5241", "0.52057916", "0.51954955", "0.51420623", "0.5116591", "0.5108181", "0.5094387", "0.50716877", "0.506764", "0.5046198", "0.5023623", "0.5022671", "0.50222933", "0.5008266", "0.50068575", "0.50009674", "0.49994686", "0.4993596", "0.49926835", "0.49735293", "0.49614656", "0.49593952", "0.4958117", "0.4957668", "0.4924094", "0.49223065", "0.49206403", "0.49131924", "0.4909381", "0.4904301", "0.4901126", "0.48860654", "0.48832816", "0.4881294", "0.48805168", "0.4874161", "0.48631844", "0.48578972", "0.4852365", "0.48466054", "0.48445922", "0.48305324", "0.4830315", "0.4829025", "0.48278737", "0.482347", "0.48141322", "0.48116058", "0.4806628", "0.4788749", "0.47847503", "0.47749957", "0.47689638", "0.47640488", "0.47610164", "0.47610164", "0.47514138", "0.47468764", "0.47252217", "0.472286", "0.47198668", "0.4719198", "0.47191966", "0.47179753", "0.47076535", "0.47071856", "0.4704247", "0.4702836", "0.47018224", "0.47011822", "0.47004828", "0.4697606", "0.46971998", "0.46940416", "0.4692619", "0.46852902", "0.46811113", "0.46801642", "0.46732435", "0.46714687", "0.4669162", "0.46674758", "0.46616063", "0.46616", "0.46602178", "0.46568352", "0.4647446", "0.46466044", "0.4644242", "0.46440977" ]
0.51551145
13
Set (override) the values to be set
public function set(array $params = array()) { $this->setParams(array())->addSets($params); return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract public function set();", "function setDefaultValues() {}", "function set_values() {\n\t\tparent::set_values();\n\t\t$currency = new currency($this->_currency_id);\n\t\t\n\t\t$this->order_id->value = $this->_order_id;\n\t\t$this->timestamp->value = date(\"j M Y\");\n\t\t$this->total_amount->value = $currency->format_money($this->_total_amount);\n\t}", "public function setAll($values)\r\n {\r\n foreach ($values as $key => $value)\r\n $this->$key = $value;\r\n }", "public function set()\n {\n $args = func_get_args();\n $num = func_num_args();\n if ($num == 2) {\n self::$data[$args[0]] = $args[1];\n } else {\n if (is_array($args[0])) {\n foreach ($args[0] as $k => $v) {\n self::$data[$k] = $v;\n }\n }\n }\n }", "public static function setters();", "public function setValues($values);", "public function setDefaultValues()\n\t{\t\t\n\t\t\t \n\t}", "protected function setDefaultValues()\n {\n parent::setDefaultValues();\n\t}", "protected abstract function setFields();", "private function setValues($values)\n {\n //echo \"<pre>\";\n //print_r($values);\n //echo \"</pre>\";\n foreach ($values as $field => $value) {\n $this->$field = $value;\n }\n\n //echo \"<pre>\";\n //print_r($this);\n //echo \"</pre>\";\n //die();\n\n }", "protected function setProperties()\n {\n foreach ($this->data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function setValues(){\n if($this->getType() == \"var\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"int\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"bool\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"string\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"nil\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"label\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"type\"){\n $this->setValue($this->getArg());\n }else{\n $this->setValue(\"CHYBA\");\n }\n }", "public function setDefaultValues() {\n $this->effective_date = \"1970-1-1\";\n $this->end_date = \"9999-12-31\";\n $this->pu_percentage = 100;\n }", "public function setValues($values) {\n $this->values = $values;\n }", "public function setValues($values = []);", "protected function adjustOptionsValues()\n {\n $this->init();\n $this->create();\n }", "public function setValues($values)\n {\n $this->values = $values;\n }", "function _setDefaults() {}", "public function set_values( $values = array() ) {\n\t\t\n\t\t$this->values = $values;\n\t\t\n\t}", "function _setDefaults()\n {\n $this->subtask_id = $this->rs['subtask_id'] = 0;\n $this->student_id = $this->rs['student_id'] = 0;\n $this->assignment_id = $this->rs['assignment_id'] = 0;\n $this->file_id = $this->rs['file_id'] = 0;\n }", "public function applyDefaultValues()\n\t{\n\t\t$this->points = '0';\n\t\t$this->type = 0;\n\t\t$this->hidden = 0;\n\t\t$this->relationship_status = 0;\n\t\t$this->show_email = 1;\n\t\t$this->show_gender = 1;\n\t\t$this->show_hometown = 1;\n\t\t$this->show_home_phone = 1;\n\t\t$this->show_mobile_phone = 1;\n\t\t$this->show_birthdate = 1;\n\t\t$this->show_address = 1;\n\t\t$this->show_relationship_status = 1;\n\t\t$this->credit = 0;\n\t\t$this->login = 0;\n\t}", "public function set_attributes()\n {\n $this->id = 0;\n $this->set_process();\n $this->set_decomposition();\n $this->set_technique();\n $this->set_applicability();\n $this->set_input();\n $this->set_output();\n $this->set_validation();\n $this->set_quality();\n $this->score = 0;\n $this->matchScore = 0;\n $this->misMatch = \"\";\n }", "public function set($params) {}", "abstract protected function reset_values();", "public function setValues($values)\n {\n foreach ($this->entities as $entity) \n {\n $entity->setValues($values);\n }\n }", "public function assignDefaultValues() {\n\t\t$this->assignByArray(self::$DEFAULT_VALUES);\n\t}", "public function assignDefaultValues() {\n\t\t$this->assignByArray(self::$DEFAULT_VALUES);\n\t}", "public function assignDefaultValues() {\n\t\t$this->assignByArray(self::$DEFAULT_VALUES);\n\t}", "public function setAll($values) {\n\t\tif (isset($values[self::$primaryKey[$this->table]])) {\n\t\t\t$this->originalData = $values;\n\t\t}\n\t\telse {\n\t\t\t$this->modifiedData = $values;\n\t\t}\n\t}", "public function setAttributes();", "function overrideValues()\t{\t\n\n\t\t// Addition of overriding values\t\t\n\t\t// TODO add check and warnings on non existent fields ...\n\t\tif (is_array($this->conf[$this->conf['cmdKey'].'.']['overrideValues.']))\t{\n\t\t\treset($this->conf[$this->conf['cmdKey'].'.']['overrideValues.']);\n\t\t\twhile(list($theField,$theValue)=each($this->conf[$this->conf['cmdKey'].'.']['overrideValues.']))\t{\n\t\t\t\n\t\t\t\t$FValue=$this->dataArr[$theField];\n\t\t\t\t//here we handle special values ... \t\n\t\t\t\tif (strpos($theValue,\":\")) {\n\t\t\t\t\t$data=tx_metafeedit_lib::getData($theValue,0,$this->cObj);\n\t\t\t\t\tif (!$data) $data=$this->dataArr[$theField];\n\t\t\t\t} elseif (strpos($theValue,\".\")) {\t\n\t\t\t\t\t$fieldArr=explode('.',$theValue);\n\t\t\t\t\t$data=$FValue;\n\t\t\t\t\t$c=count($fieldArr);\n\t\t\t\t\tif ($c > 1) {\n\t\t\t\t\t\t$data=$this->cObj->getData($fieldArr[0],0);\n\t\t\t\t\t\t$i=1;\n\t\t\t\t\t\twhile ($i<=$c) {\n\t\t\t\t\t\t\tif (is_object($data)) {\n\t\t\t\t\t\t\t\t$data=get_object_vars($data);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (is_array($data)) {\n\t\t\t\t\t\t\t\t$key=$fieldArr[$i];\n\t\t\t\t\t\t\t\t$data=$data[$fieldArr[$i]];\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$i++;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\n\t\t\t\t} elseif (strpos($theValue,\"<\")===0) {\n\t\t\t\t\t// We override value with other incoming field\n\t\t\t\t\t$f=substr($theValue,1);\n\t\t\t\t\t$v=$this->dataArr[$f];\n\t\t\t\t\tif ($v) $data=$v;\n\t\t\t\t} else {\n\t\t\t\t\t$data=$theValue;\n\t\t\t\t}\n\t\t\t\tif ($data) $this->dataArr[$theField] = $data;\n\t\t\t}\n\t\t}\n\t\t\n\t\t// call to user override function\n\t\tif ($this->conf[$this->conf['cmdKey'].'.']['userFunc_afterOverride']) {\n\t\t\tt3lib_div::callUserFunction($this->conf[$this->conf['cmdKey'].'.']['userFunc_afterOverride'],$this->conf,$this);\n\t\t}else if ($this->conf['userFunc_afterOverride']) {\n\t\t\tt3lib_div::callUserFunction($this->conf['userFunc_afterOverride'],$this->conf,$this);\n\t\t}\n\t}", "public function applyDefaultValues()\n {\n $this->setregis = 0;\n }", "public function applyDefaultValues()\n {\n $this->is_active = false;\n $this->is_closed = false;\n }", "function set_data($default_values) {\n if (is_object($default_values)) {\n $default_values = (array)$default_values;\n }\n $this->data_preprocessing($default_values);\n parent::set_data($default_values); //never slashed for moodleform_mod\n }", "public function applyDefaultValues()\n\t{\n\t\t$this->ativo = true;\n\t\t$this->tipo_acesso = 'M';\n\t\t$this->estado_civil = 'O';\n\t\t$this->nivel_acesso = '1';\n\t\t$this->usuario_validado = false;\n\t}", "public function setDefaultValues()\r\n {\r\n foreach ($this->defaultValues as $property => $value) {\r\n if (is_null($this->$property)) {\r\n $this->$property = $value;\r\n }\r\n }\r\n }", "protected function setSubmittedValues()\n {\n if ( $this->setFundraiserId() ) {\n $this->setFundraiserProfile(); \n }\n\n $this->setAmount();\n \n $this->setFirstName();\n $this->setLastName();\n $this->setEmail();\n $this->setTelephone();\n \n $this->setAddress();\n $this->setCity();\n $this->setCountry();\n $this->setRegion();\n $this->setPostalCode();\n \n $this->setAnonymity();\n $this->setHideAmount();\n }", "function set_defaults()\n {\n $mapper = $this->get_mapper();\n if ($mapper->has_method('set_defaults')) {\n $mapper->set_defaults($this);\n }\n }", "public function set($parameters)\n {}", "private function setDefaults()\n {\n $defaults = config('sevDeskApi.defaults.'.lcfirst($this->objectName));\n\n foreach($defaults as $attribute => $defaultValue)\n {\n if (!isset($this->$attribute))\n $this->$attribute = $defaultValue;\n }\n }", "function setInputValues( array $values );", "public function assignValues($values=[]) {\n }", "protected function initializeValues(): void\n {\n foreach ($this->params as $name => $infos) {\n if (!$this->is_sub_object && isset($infos['subobject']) && $infos['subobject']) {\n if (isset($infos['multivalues']) && $infos['multivalues']) {\n $this->values[$name] = [];\n } else {\n $tmp = get_class($this);\n $parts = explode('\\\\', $tmp);\n array_pop($parts);\n $class_name = implode('\\\\', $parts) . '\\\\' . $infos['type'];\n $class_name = str_replace('Entity', 'Datatype', $class_name);\n if (!class_exists($class_name)) {\n $class_name = str_replace(['\\\\EU\\\\', '\\\\AP\\\\', '\\\\EA\\\\'], '\\\\AM\\\\', $class_name);\n }\n $this->values[$name] = new $class_name();\n }\n } else {\n $this->values[$name] = null;\n }\n }\n }", "public function applyDefaultValues()\n {\n $this->deleted = false;\n $this->amount = 1;\n $this->amountevaluation = 0;\n $this->defaultstatus = 0;\n $this->defaultdirectiondate = 0;\n $this->defaultenddate = 0;\n $this->defaultpersoninevent = 0;\n $this->defaultpersonineditor = 0;\n $this->maxoccursinevent = 0;\n $this->showtime = false;\n $this->ispreferable = true;\n $this->isrequiredcoordination = false;\n $this->isrequiredtissue = false;\n $this->mnem = '';\n }", "private function setValues()\n {\n foreach($this->data as $type => $values)\n if(!preg_match('/(library)/i', $type))\n foreach($values as $key => $value)\n $this->{strtolower($type)}[$key] = $value;\n }", "public function set()\n {\n if ( ! $this->value ) {\n $this->generate();\n }\n }", "public function setValues(array $values);", "public function applyDefaultValues()\n {\n $this->jml_lantai = '1';\n $this->asal_data = '1';\n $this->last_sync = '1901-01-01 00:00:00';\n }", "function SetInitialValues()\n\t{\n\t\t$this->id = -1;\n\t\t$this->title = '';\n\t\t$this->url = '';\n\t\t$this->user_id = -1;\n\t\t$this->timestamp = -1;\n\t}", "public function set_data($defaultvalues) {\n $this->tool->form_set_data($defaultvalues);\n parent::set_data($defaultvalues);\n }", "function _setDefaults()\n {\n $this->type = $this->rs['type'] = \"unknown\";\n $this->parent = $this->rs['parent'] = 0;\n $this->lecture_id = $this->rs['lecture_id'] = SessionDataBean::getLectureId();\n $this->title = $this->rs['title'] = \"\";\n $this->mtitle = $this->rs['mtitle'] = \"\";\n $this->text = $this->rs['text'] = \"<p></p>\";\n $this->position = $this->rs['position'] = 0;\n $this->redirect = $this->rs['redirect'] = \"\";\n $this->ival1 = $this->rs['ival1'] = 0;\n $this->copy_parent = $this->rs['copy_parent'] = false;\n }", "public function applyDefaultValues()\n {\n $this->is_not = false;\n $this->rank = 0;\n }", "public function setValues(array $values): void\n {\n foreach ($this->getInputNames() as $name) {\n if (array_key_exists($name, $values)) {\n $this->$name = $values[$name];\n }\n }\n }", "public function applyDefaultValues()\n\t{\n\t\t$this->platform = 'pc';\n\t\t$this->experience_score = 0;\n\t\t$this->up_votes = 0;\n\t\t$this->down_votes = 0;\n\t\t$this->is_guest = 0;\n\t\t$this->is_admin = 0;\n\t\t$this->today_votes = 0;\n\t\t$this->email_on = 1;\n\t}", "public function setInputValues(&$values, $load = false);", "public function setAttributes()\n\t{\n\t\t$this->title \t\t= Input::get( 'title' );\n\t\t$this->description \t= Input::get( 'description' );\n\t\t$this->color \t\t= Input::get( 'color' );\n\t\t$this->type \t\t= Input::get( 'type' );\n\t\t$this->canvas_id\t= Input::get( 'canvas_id', Input::get( 'canvasId' ) );\n\t}", "function set(array $data) {\n\t\tforeach ($data as $key => $value) {\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "public function setAttributes($values, $safeOnly = true){\n $params = $this->limpiarParametrosConEspacios($values);\n parent::setAttributes($params, $safeOnly);\n $this->barrio = strtolower($this->barrio);\n $this->calle = strtolower($this->calle);\n }", "function dbSetVars() {\n\n foreach ($this->fields() as $f) {\n if ($this->$f === false) continue;\n $this->db->set($f,$this->$f);\n }\n\n }", "abstract public function setValue($value);", "public function setValues(array $values): void\n {\n $this->values = $values;\n }", "public function setValues(array $values) {\n $this->data = $values;\n }", "public function setValues($values){\n\t\tif(!is_array($values)) return;\n\t\t\n\t\tforeach($values as $field_name => $value){\n\t\t\tif(isset($this->Fields[$field_name])){\n\t\t\t\t$this->Fields[$field_name]->value = $value;\n\t\t\t}\n\t\t}\n\t}", "public function applyDefaultValues()\n\t{\n\t\t$this->type = 1;\n\t\t$this->total_index = 0;\n\t\t$this->is_published = true;\n\t\t$this->is_featured = false;\n\t\t$this->comments_count = 0;\n\t}", "public function set($data);", "public function setData() \n {\n // Empty, to be overridden \n }", "public function set()\n {\n // to reflect the current bar.\n\n // Why?\n\n // Otherwise the bar count gets repeated. And that people notice.\n\n $this->variables->setVariable(\"count\", $this->bar_count);\n $this->variables->setVariable(\"max_bar_count\", $this->max_bar_count);\n\n $this->variables->setVariable(\"refreshed_at\", $this->current_time);\n }", "private function _set_fields()\n {\n @$this->form_data->survey_id = 0;\n $this->form_data->survey_title = '';\n $this->form_data->survey_description = '';\n $this->form_data->survey_status = 'open';\n $this->form_data->survey_anms = 'yes';\n $this->form_data->survey_expiry_date = '';\n $this->form_data->question_ids = array();\n\n $this->form_data->filter_survey_title = '';\n $this->form_data->filter_status = '';\n }", "public function setOptions()\n\t{\n\t\tupdate_option($this->optionVar, serialize($this->options));\n\t}", "public function applyDefaultValues()\n {\n $this->shnttype = '';\n $this->shntseq = 0;\n $this->shntkey2 = '';\n $this->shntform = '';\n }", "public function setValues($values)\n {\n foreach ($values as $field => $value)\n {\n if (isset($this->properties[$field])) {\n /** @var Property $this->$field */\n $this->$field->set($value);\n }\n }\n }", "abstract public function setMetas();", "public function set_props($args)\n {\n }", "public function SetInitValues($Values) {\n\n $this->Values= $Values;\n $this->BuildControls();\n foreach($this->Controls as $Control) {\n if ($Control->IsValidScenario()) {\n $Control->ImportInitValue();\n }\n }\n }", "public function set_to_default()\n\t{\n\t\t// SimpleDB requires a value for every attribue...\n\t\t$this->_name = NULL;\n\t\t$this->_contextid = NULL;\n\t\t$this->_userid = NULL;\n $this->_deleted = 0;\n\t\t$this->_lastmodified = 0;\t\n\t}", "public function testSetValues()\n {\n $this->todo('stub');\n }", "public function setMemberDefaults(){\n parent::setMemberDefaults();\n \n $this->id = $this->id ? $this->id : UniqId::get(\"rbn-\");\n if (!$this->collarTriangleWidth) {\n $this->collarTriangleWidth = StyleUtil::getHalf($this->collarWidth);\n }\n if (!$this->collarColor) {\n if ($this->barColor){\n $this->collarColor = $this->barColor;\n }\n else if( $this->barGradient ){\n $this->collarColor = GradientInfo::getLastColor($this->barGradient);\n }\n }\n }", "private function setDefaultValues()\n {\n // Set default payment action.\n if (empty($this->paymentAction)) {\n $this->paymentAction = 'Sale';\n }\n\n // Set default locale.\n if (empty($this->locale)) {\n $this->locale = 'en_US';\n }\n\n // Set default value for SSL validation.\n if (empty($this->validateSSL)) {\n $this->validateSSL = false;\n }\n }", "public function setValues($values) {\n\t\t$this->attributes['values'] = $values;\n\t\t$this->values = $values;\n\t\treturn $this;\n\t}", "public function setAttributes($values)\n {\n if (is_array($values)) {\n foreach ($values as $name => $value) {\n $setter = 'set' . ucfirst($name);\n if (method_exists($this, $setter)) {\n // set property\n $this->$setter($value);\n }\n }\n }\n }", "public function set_all_data($data)\n\t{\n\t\t$this->_data = $data;\n\t}", "abstract public function set($in): void;", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "abstract public function setOptions($options);", "public function applyDefaultValues()\n\t{\n\t\t$this->closed = 0;\n\t\t$this->lastfmid = 0;\n\t\t$this->hasphotos = 0;\n\t}", "function SetValues($title, $url, $userid)\n\t{\n\t\t$this->title = $title;\n\t\t$this->url = $url;\n\t\t$this->user_id = $userid;\n\t}", "protected function setDefaults()\n {\n return;\n }", "public function setOptions($mixed)\n\t{\n\t\t$args \t= func_get_args();\n\t\t$sign \t= !isset($args[1]) ? 'set' : 'get'; \n\t\t\n\t\t\t$names = Tools::toArray($args[1]);\n\t\t\t\n\t\t\tforeach ( $names as $name => $value ){ $this->setOption($name, $value); }\n\t}", "public function SetValues($Values) {\n\n $this->Values= $Values;\n $this->BuildControls();\n foreach($this->Controls as $Control) {\n if ($Control->IsValidScenario()) {\n $Control->ImportValueFromData();\n }\n }\n }", "public function setValue( array $values ) {\n\t\t\t$this->value = $values;\n\t\t}", "function setDefaults()\n {\n }", "public function applyDefaultValues()\n\t{\n\t\t$this->is_archived = 0;\n\t\t$this->google_analytics_enabled = false;\n\t}", "public function autoSet()\n {\n $this->setInfo();\n $this->setParams();\n $this->extractRoutingInfo();\n }", "public function applyOptions(): void\n {\n if ($this->hasEndpoint()) {\n $this->withOptions(['endpoint' => $this->endpoint]);\n }\n\n $this->setProp('value', $this->attribute);\n $this->setProp('entities', $this->options(), false);\n }", "public function applyDefaultValues()\n {\n $this->phadtype = '';\n $this->phadid = '';\n $this->phadsubid = '';\n $this->phadsubidseq = 0;\n $this->phadcont = '';\n }", "public function applyDefaultValues()\n\t{\n\t}", "public function applyDefaultValues()\n\t{\n\t}", "public function applyDefaultValues()\n\t{\n\t}", "public function set()\n {\n $args = func_get_args();\n\n if ( count($args) == 2 )\n {\n $this->attributes[$args[0]] = $args[1];\n }\n elseif ( count($args) == 1 && is_array($args[0]) ) \n {\n $this->attributes = ( array_merge($this->attributes, $args[0]) );\n }\n\n return $this;\n }" ]
[ "0.7335168", "0.7200339", "0.71351856", "0.70473343", "0.7006454", "0.69821185", "0.69365674", "0.69344455", "0.6908085", "0.69017965", "0.6859257", "0.6854544", "0.6852552", "0.67917037", "0.67602116", "0.6756943", "0.6737323", "0.673082", "0.669086", "0.65941584", "0.65827405", "0.6531073", "0.65168804", "0.64806104", "0.6468865", "0.6445451", "0.64066386", "0.64066386", "0.64066386", "0.6397341", "0.63864636", "0.6384516", "0.63730913", "0.6366491", "0.6355496", "0.63531363", "0.6352764", "0.6328982", "0.6320392", "0.6318588", "0.63169724", "0.63080525", "0.62970215", "0.6288785", "0.62856984", "0.6285019", "0.6284448", "0.62738883", "0.62644106", "0.6259011", "0.62568194", "0.62372816", "0.623618", "0.62307316", "0.62277806", "0.6210649", "0.6201714", "0.6199511", "0.61987084", "0.61963934", "0.61951274", "0.61839575", "0.61692446", "0.61691725", "0.61542535", "0.615135", "0.61458683", "0.6136671", "0.61337507", "0.61304003", "0.6126592", "0.6123019", "0.612268", "0.6122225", "0.6121224", "0.6112341", "0.61041987", "0.6095523", "0.60884184", "0.6085585", "0.6083639", "0.6076931", "0.6076403", "0.6072755", "0.6072755", "0.60679126", "0.60657054", "0.60635453", "0.60576653", "0.6056657", "0.60515565", "0.60508406", "0.6046686", "0.60454893", "0.6039791", "0.60395813", "0.60384214", "0.6036828", "0.6036828", "0.6036828", "0.6035383" ]
0.0
-1
Add the values to be set
public function addSets(array $values = array()) { foreach ($values as $column => $value) { $this->addSet($column, $value); } return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function add_values($values){\n foreach($values as $value){\n $this->add_value($value);\n }\n }", "public function add_values($values) : void\n {\n foreach($values as $value){\n $this -> add_value($value);\n }\n }", "function set_values() {\n\t\tparent::set_values();\n\t\t$currency = new currency($this->_currency_id);\n\t\t\n\t\t$this->order_id->value = $this->_order_id;\n\t\t$this->timestamp->value = date(\"j M Y\");\n\t\t$this->total_amount->value = $currency->format_money($this->_total_amount);\n\t}", "protected function initializeValues(): void\n {\n foreach ($this->params as $name => $infos) {\n if (!$this->is_sub_object && isset($infos['subobject']) && $infos['subobject']) {\n if (isset($infos['multivalues']) && $infos['multivalues']) {\n $this->values[$name] = [];\n } else {\n $tmp = get_class($this);\n $parts = explode('\\\\', $tmp);\n array_pop($parts);\n $class_name = implode('\\\\', $parts) . '\\\\' . $infos['type'];\n $class_name = str_replace('Entity', 'Datatype', $class_name);\n if (!class_exists($class_name)) {\n $class_name = str_replace(['\\\\EU\\\\', '\\\\AP\\\\', '\\\\EA\\\\'], '\\\\AM\\\\', $class_name);\n }\n $this->values[$name] = new $class_name();\n }\n } else {\n $this->values[$name] = null;\n }\n }\n }", "public function setValues($values = []);", "public function setValues($values);", "public function add(array $values = []): void\n {\n \t$this->values = array_replace($this->values, $values);\n\t}", "public function setAll($values)\r\n {\r\n foreach ($values as $key => $value)\r\n $this->$key = $value;\r\n }", "function setParamaters($valuetoadd=null) {\n if (empty($valuetoadd)) {\n $this->preparedvalues = array();\n return null;\n } else \n return array_push($this->preparedvalues, $valuetoadd); \n\t}", "public function set()\n {\n $args = func_get_args();\n $num = func_num_args();\n if ($num == 2) {\n self::$data[$args[0]] = $args[1];\n } else {\n if (is_array($args[0])) {\n foreach ($args[0] as $k => $v) {\n self::$data[$k] = $v;\n }\n }\n }\n }", "protected function populate_value()\n {\n }", "private function setValues()\n {\n foreach($this->data as $type => $values)\n if(!preg_match('/(library)/i', $type))\n foreach($values as $key => $value)\n $this->{strtolower($type)}[$key] = $value;\n }", "private function setValues($values)\n {\n //echo \"<pre>\";\n //print_r($values);\n //echo \"</pre>\";\n foreach ($values as $field => $value) {\n $this->$field = $value;\n }\n\n //echo \"<pre>\";\n //print_r($this);\n //echo \"</pre>\";\n //die();\n\n }", "function add( $values = array(), $post_id = 0, $is_main = false ) {\n\t\t\n\t\t// loop over values\n\t\tif( is_array($values) ) {\n\t\tforeach( $values as $key => $value ) {\n\t\t\t\n\t\t\t// get field\n\t\t\t$field = acf_get_field( $key );\n\t\t\t\n\t\t\t// check\n\t\t\tif( $field ) {\n\t\t\t\t\n\t\t\t\t// vars\n\t\t\t\t$name = $field['name'];\n\t\t\t\t\n\t\t\t\t// append values\n\t\t\t\t$this->meta[ $post_id ][ $name ] = $value;\n\t\t\t\t\n\t\t\t\t// append reference\n\t\t\t\t$this->meta[ $post_id ][ \"_$name\" ] = $key;\n\t\t\t}\n\t\t}}\n\t\t\n\t\t// set $post_id reference when is the main postmeta\n\t\tif( $is_main ) {\n\t\t\t$this->post_id = $post_id;\n\t\t}\n\t\t\n\t\t// initialize filters\n\t\t$this->initialize();\n\t}", "protected function adjustOptionsValues()\n {\n $this->init();\n $this->create();\n }", "public function addValues($value) {\n return $this->_add(2, $value);\n }", "public function setValues($values){\n\t\tif(!is_array($values)) return;\n\t\t\n\t\tforeach($values as $field_name => $value){\n\t\t\tif(isset($this->Fields[$field_name])){\n\t\t\t\t$this->Fields[$field_name]->value = $value;\n\t\t\t}\n\t\t}\n\t}", "public function copyAttributesToValues()\n\t{\n\t\tforeach( $this->values as $field=>$value )\n\t\t{\n\t\t\t$this->values[$field] = $this->$field ;\n\t\t}\n\t}", "public function setValues(){\n if($this->getType() == \"var\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"int\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"bool\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"string\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"nil\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"label\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"type\"){\n $this->setValue($this->getArg());\n }else{\n $this->setValue(\"CHYBA\");\n }\n }", "public function setValue($entries) {}", "protected function setSubmittedValues()\n {\n if ( $this->setFundraiserId() ) {\n $this->setFundraiserProfile(); \n }\n\n $this->setAmount();\n \n $this->setFirstName();\n $this->setLastName();\n $this->setEmail();\n $this->setTelephone();\n \n $this->setAddress();\n $this->setCity();\n $this->setCountry();\n $this->setRegion();\n $this->setPostalCode();\n \n $this->setAnonymity();\n $this->setHideAmount();\n }", "private function addValues($selected){\n $id = $this->answersId[$selected];\n $answersModel = new Answer();\n $answer = $answersModel->find($id);\n\n $this->score['heritage'] += $answer->heritage;\n $this->score['populated'] += $answer->populated;\n $this->score['weather'] += $answer->weather;\n $this->score['relax'] += $answer->relax;\n $this->score['sightseeing'] += $answer->sightseeing;\n }", "function setInputValues( array $values );", "public function assignValues($values=[]) {\n }", "function setDefaultValues() {}", "public function setValues($values)\n {\n $this->values = $values;\n }", "protected function set_values($num){\n if($num > 1 ){\n\n for($cnt = 1; $cnt <= ($num-1);$cnt++){\n $this->set_data($this->get_assign()[$cnt]);\n }//-> end of for\n\n } //-> end of main if\n\n }", "public function addValueMarkers() {\n\t\t$args = func_get_args();\n\t\t$this->setProperty('chm', $this->encodeData($args, ','), true);\n\t}", "public function setValues($values)\n {\n foreach ($this->entities as $entity) \n {\n $entity->setValues($values);\n }\n }", "public function setValues($values) {\n $this->values = $values;\n }", "public function append($values);", "private function assignValues() {\n $this->setIndicators('value');\n\n $leftIndicator = $this->sugarTemplateIndicators['valueLeft'] . $this->sugarTemplateIndicators['valueSeparator'];\n $rightIndicator = $this->sugarTemplateIndicators['valueSeparator'] . $this->sugarTemplateIndicators['valueRight'];\n\n foreach ($this->assignedValues as $tag => $value) {\n $this->rootContent = str_replace($leftIndicator . $tag . $rightIndicator, $value, $this->rootContent);\n }\n }", "public function withRestrictedSetValues()\n {\n foreach (func_get_args() as $RestrictedSetValues)\n {\n $this->_fields['RestrictedSetValues']['FieldValue'][] = $RestrictedSetValues;\n }\n return $this;\n }", "public function setValues($valueCollection) {\n\n foreach ($valueCollection as $key => $value) {\n if (isset($this[$key])) {\n $this[$key]->setValue($value);\n } //if\n } //foreach\n \n }", "public function setInputValues(&$values, $load = false);", "public function setvalues($questionData)\n {\n \t$this->questionData = $questionData;\n \n \tforeach ($questionData as $values) {\n \t\tforeach ($values as $name => $value) {\n \t\t\tif (!isset($this->fields[$name])) {\n \t\t\t\tcontinue;\n \t\t\t}\n \n \t\t\t$this->{$this->fields[$name]} = $value;\n \t\t}\n \t}\n }", "function setValues($list) {\n global $params;\n if (count($list)) {\n\tforeach ($list as $k=>$v) {\n\t $params[$k] = $v;\n\t}\n }\n}", "public function values($data){\n\t\tforeach($data as $key => $value){\n\t\t\tif(property_exists($this, $key)){\n\t\t\t\t$this->{$key} = $value;\n\t\t\t}\n\t\t}\n\t}", "public function values()\n {\n }", "private function setAutofillFields() {\n foreach (static::getFields() as $field_name => $field) {\n if ($field instanceof AutofillField) {\n $this->values[$field_name] = $field->fill();\n }\n }\n }", "public function setAll($values) {\n\t\tif (isset($values[self::$primaryKey[$this->table]])) {\n\t\t\t$this->originalData = $values;\n\t\t}\n\t\telse {\n\t\t\t$this->modifiedData = $values;\n\t\t}\n\t}", "function dbSetVars() {\n\n foreach ($this->fields() as $f) {\n if ($this->$f === false) continue;\n $this->db->set($f,$this->$f);\n }\n\n }", "public function set_values( $values = array() ) {\n\t\t\n\t\t$this->values = $values;\n\t\t\n\t}", "public function values() {\n\t\t// Get arguments :\n\t\t$args = func_get_args();\n\t\t\n\t\t// Add values :\n\t\tif (is_array($args[0])) {\n\t\t\tif ( ! is_array(reset($args[0]))) {\n\t\t\t\t// Deal with normal case : ->values(array(val1, val2, ...), array(val1, val2, ...), ...)\n\t\t\t\tforeach($args as $values_array)\n\t\t\t\t\t$this->push(new \\Glue\\DB\\Fragment_Item_Values($values_array));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// Array of arrays given, call this function recursively for each of them :\n\t\t\t\tforeach($args[0] as $arg)\n\t\t\t\t\t$this->values($arg);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t\t// List of values given, call this function recursively with the same values as an array :\n\t\t\t$this->values($args);\n\t\n\t\treturn $this;\n\t}", "function values( $vars ) {\n foreach($vars as $k=>$v) {\n $this->_vars[\"$k\"] = $v;\n }\n }", "public function addValues(\\google\\protobuf\\Value $value){\n return $this->_add(1, $value);\n }", "public function init()\n {\n if (!is_array($this->values)) {\n $this->values = [$this->values];\n }\n }", "public function merge_validater_value_list($list)\n {\n foreach ($list as $k => $v) {\n $this->_validater_value_arr[$k] = $v;\n }\n }", "function setData()\n {\n list($this->x, $this->y, $this->radius, $this->radius2) = $this->getInput();\n }", "public static function setters();", "function setValues($list) {\n global $params;\n if ( count($list )) {\n foreach ($list as $k => $v ) {\n $params[$k] = $v;\n }\n }\n}", "public function addDefaultEntriesAndValues() {}", "public function setValues(array $values);", "public function addValue($value);", "public function setDefaultValues()\n\t{\t\t\n\t\t\t \n\t}", "public function addVals($colVar) {\n $this->cols = array_keys($colVar);\n $this->vals = array_values($colVar);\n foreach($this->cols as $col) {\n $this->params[] = $this->colConvert($col);\n $this->types[] = $this->setParamType($colVar[$col]);\n }\n }", "public function fill($new_values): void\n {\n foreach ($this->data['fields'] as $field_name => &$field_value) {\n if (key_exists($field_name, $new_values)) {\n $field_value['value'] = $new_values[$field_name];\n }\n }\n }", "public static function get_values()\n {\n }", "public static function get_values()\n {\n }", "public static function get_values()\n {\n }", "public function add()\n {\n for ($i = 0 ; $i < func_num_args(); $i++) {\n $this->addSingle(func_get_arg($i));\n }\n }", "function LoadMultiUpdateValues() {\r\n\t\t$this->CurrentFilter = $this->GetKeyFilter();\r\n\r\n\t\t// Load recordset\r\n\t\tif ($this->Recordset = $this->LoadRecordset()) {\r\n\t\t\t$i = 1;\r\n\t\t\twhile (!$this->Recordset->EOF) {\r\n\t\t\t\tif ($i == 1) {\r\n\t\t\t\t\t$this->Nro_Serie->setDbValue($this->Recordset->fields('Nro_Serie'));\r\n\t\t\t\t\t$this->SN->setDbValue($this->Recordset->fields('SN'));\r\n\t\t\t\t\t$this->Cant_Net_Asoc->setDbValue($this->Recordset->fields('Cant_Net_Asoc'));\r\n\t\t\t\t\t$this->Id_Marca->setDbValue($this->Recordset->fields('Id_Marca'));\r\n\t\t\t\t\t$this->Id_Modelo->setDbValue($this->Recordset->fields('Id_Modelo'));\r\n\t\t\t\t\t$this->Id_SO->setDbValue($this->Recordset->fields('Id_SO'));\r\n\t\t\t\t\t$this->Id_Estado->setDbValue($this->Recordset->fields('Id_Estado'));\r\n\t\t\t\t\t$this->User_Server->setDbValue($this->Recordset->fields('User_Server'));\r\n\t\t\t\t\t$this->Pass_Server->setDbValue($this->Recordset->fields('Pass_Server'));\r\n\t\t\t\t\t$this->User_TdServer->setDbValue($this->Recordset->fields('User_TdServer'));\r\n\t\t\t\t\t$this->Pass_TdServer->setDbValue($this->Recordset->fields('Pass_TdServer'));\r\n\t\t\t\t\t$this->Cue->setDbValue($this->Recordset->fields('Cue'));\r\n\t\t\t\t\t$this->Fecha_Actualizacion->setDbValue($this->Recordset->fields('Fecha_Actualizacion'));\r\n\t\t\t\t\t$this->Usuario->setDbValue($this->Recordset->fields('Usuario'));\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif (!ew_CompareValue($this->Nro_Serie->DbValue, $this->Recordset->fields('Nro_Serie')))\r\n\t\t\t\t\t\t$this->Nro_Serie->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->SN->DbValue, $this->Recordset->fields('SN')))\r\n\t\t\t\t\t\t$this->SN->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cant_Net_Asoc->DbValue, $this->Recordset->fields('Cant_Net_Asoc')))\r\n\t\t\t\t\t\t$this->Cant_Net_Asoc->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Marca->DbValue, $this->Recordset->fields('Id_Marca')))\r\n\t\t\t\t\t\t$this->Id_Marca->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Modelo->DbValue, $this->Recordset->fields('Id_Modelo')))\r\n\t\t\t\t\t\t$this->Id_Modelo->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_SO->DbValue, $this->Recordset->fields('Id_SO')))\r\n\t\t\t\t\t\t$this->Id_SO->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Estado->DbValue, $this->Recordset->fields('Id_Estado')))\r\n\t\t\t\t\t\t$this->Id_Estado->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_Server->DbValue, $this->Recordset->fields('User_Server')))\r\n\t\t\t\t\t\t$this->User_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_Server->DbValue, $this->Recordset->fields('Pass_Server')))\r\n\t\t\t\t\t\t$this->Pass_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_TdServer->DbValue, $this->Recordset->fields('User_TdServer')))\r\n\t\t\t\t\t\t$this->User_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_TdServer->DbValue, $this->Recordset->fields('Pass_TdServer')))\r\n\t\t\t\t\t\t$this->Pass_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cue->DbValue, $this->Recordset->fields('Cue')))\r\n\t\t\t\t\t\t$this->Cue->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Fecha_Actualizacion->DbValue, $this->Recordset->fields('Fecha_Actualizacion')))\r\n\t\t\t\t\t\t$this->Fecha_Actualizacion->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Usuario->DbValue, $this->Recordset->fields('Usuario')))\r\n\t\t\t\t\t\t$this->Usuario->CurrentValue = NULL;\r\n\t\t\t\t}\r\n\t\t\t\t$i++;\r\n\t\t\t\t$this->Recordset->MoveNext();\r\n\t\t\t}\r\n\t\t\t$this->Recordset->Close();\r\n\t\t}\r\n\t}", "public function addData($data) {\n foreach ($data as $value) {\n $this->add(new Option($value));\n }\n }", "function asignar_valores(){\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->prioridad=$_POST['prioridad'];\n\t\t$this->etiqueta=$_POST['etiqueta'];\n\t\t$this->descripcion=$_POST['descripcion'];\n\t\t$this->claves=$_POST['claves'];\n\t\t$this->tipo=$_POST['tipo'];\n\t\t$this->icono=$_POST['icono'];\n\t}", "public function store(): void\r\n {\r\n if (empty($this->errors[$this->artribute])) {\r\n $this->data[$this->artribute] = $this->value;\r\n }\r\n }", "public function finish_setting_parameters()\n {\n $this->set_variable( 'parameters', $this->parameters );\n }", "public function setTestValues()\r\n {\r\n $fname = array(\"Jesper\", \"Nicolai\", \"Alex\", \"Stefan\", \"Helmut\", \"Elvis\");\r\n $lname = array(\"Gødvad\", \"Lundgaard\", \"Killing\", \"Meyer\", \"Schottmüller\", \"Presly\");\r\n $city = array(\"Copenhagen\", \"Århus\", \"Collonge\", \"Bremen\", \"SecretPlace\" );\r\n $country = array(\"Denmark\", \"Germany\", \"France\", \"Ümlaudia\", \"Graceland\");\r\n $road = array(\" Straße\", \" Road\", \"vej\", \" Boulevard\");\r\n \r\n $this->number = rand(1000,1010);\r\n $this->name = $fname[rand(0,5)] . \" \" . $lname[rand(0,5)];\r\n $this->email = \"[email protected]\";\r\n $this->address= \"Ilias\" . $road[rand(0,3)] .\" \" . rand(1,100);\r\n $this->postalcode = rand(2000,7000);\r\n $this->city = $city[rand(0,3)];\r\n $this->country = $country[rand(0,4)];\r\n $this->phone = \"+\" . rand(1,45) . \" \" . rand(100,999) . \" \" . rand(1000, 9999);\r\n $this->ean = 0;\r\n $this->website = ilERPDebtor::website; \r\n }", "function appendAllListOfValuesToItem(&$item) {\n $iter = $item->getMetadataIterator();\n $this->appendAllListOfValues($iter);\n }", "public function setAll(array $values): self {\n $this->record = array_merge($this->record, $values);\n return $this;\n }", "protected function prepareForValidation()\n {\n $merge = [];\n\n if ($this->valtotal) {\n $merge['valtotal'] = Format::strToFloat($this->valtotal);\n }\n\n $this->merge($merge);\n }", "public function setValues($values = array(), $append = false) {\n\t\tif ($append) {\n\t\t\tforeach ($values as $key => $value) {\n\t\t\t\tif (isset($this->values[$key]) && is_string($this->values[$key])) {\n\t\t\t\t\t$this->values[$key] .= $value;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$this->values[$key] = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\t$this->values = array_merge($this->values, $values);\n\t\t}\n\t\treturn $this;\n\t}", "protected function _setFieldValues($values) {\n foreach ($this->getElements() as $key => $element) {\n if (count(explode('_', $key)) == 3) {\n list($parent_id, $option_id, $field_id) = explode('_', $key);\n if (isset($values[$field_id])) {\n $element->setValue($values[$field_id]);\n }\n }\n }\n }", "public function applyDefaultValues()\n {\n $this->setregis = 0;\n }", "public function setValues(array $_values=array()){\n foreach(($getElements=self::getElements()) as $key=>$items){\n $this->{$key}=(\n (isset($_values[self::getFormName()][$key]))\n ?$_values[self::getFormName()][$key]\n :NULL\n );\n $getElementsv[$key]->setValue($this->{$key});\n }\n }", "private function _setParams ()\n {\n $endpoint = $this->_endpoint->getData();\n if (count($endpoint) > 0) {\n \n $method = $this->_endpoint->getUrl();\n $methodname = 'setParameter' . ucfirst($method['method']);\n \n $this->_httpclient->{$methodname}('access_token', \n $this->_accesstoken);\n $this->_httpclient->{$methodname}('api_secret', $this->_apisecret);\n \n foreach ($endpoint as $param => $value) {\n $this->_httpclient->{$methodname}($param, $value);\n }\n }\n }", "public function setVars( array $vars ) {\n $this->vars += $vars;\n }", "public function addSet( array $set ) {\n $this->set = array_merge( $this->set, $set );\n }", "private function setTotalAmounts()\n {\n $taxable\t= 0.00;\n $expenses = 0.00;\n $outlays\t= 0.00;\n\n foreach ($this->invoiceDetails as $invoiceDetail) {\n $amount = $invoiceDetail->getAmount();\n switch ($invoiceDetail->getType())\n {\n case 'incoming':\n $taxable += $amount;\n break;\n case 'expense':\n $taxable += $amount;\n $expenses += $amount;\n break;\n case 'outlay':\n $outlays += $amount;\n break;\n }\n }\n\n $this->setTotalTaxable($taxable);\n $this->setTotalExpenses($expenses);\n $this->setTotalOutlays($outlays);\n }", "public function add(array $items): void\n {\n foreach ($items as $key => $values) {\n $this->set($key, $values);\n }\n }", "protected function setProperties()\n {\n foreach ($this->data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function setValues(array $values): void\n {\n $this->values = array_map(function ($value) {\n return ChunkRecommendationsValue::constructFromArray(['value' => $value]);\n }, $values);\n }", "function load_values($data = false) {\n\t\tif ($data === false) {\n\t\t\tfix_POST_slashes();\n\t\t\t$data = $_POST;\n\t\t}\n\t\tforeach ($this->fields as $field) {\n\t\t\tif ($field->get_multiple_values()) {\n\t\t\t\t$field_name = $field->get_var_name();\n\t\t\t\tif (isset($data[$field_name])) {\n\t\t\t\t\t$field->set_value($data[$field_name]);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (isset($data[$field->get_name()])) {\n\t\t\t\t\t$field->set_value($data[$field->get_name()]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "protected function buildBindings(): void\n {\n $this->bindings = $this->fieldValueSet->getBoundValues();\n }", "function LoadMultiUpdateValues() {\n\t\t$this->CurrentFilter = $this->GetKeyFilter();\n\n\t\t// Load recordset\n\t\tif ($this->Recordset = $this->LoadRecordset()) {\n\t\t\t$i = 1;\n\t\t\twhile (!$this->Recordset->EOF) {\n\t\t\t\tif ($i == 1) {\n\t\t\t\t\t$this->cat_id->setDbValue($this->Recordset->fields('cat_id'));\n\t\t\t\t\t$this->company_id->setDbValue($this->Recordset->fields('company_id'));\n\t\t\t\t\t$this->pro_model->setDbValue($this->Recordset->fields('pro_model'));\n\t\t\t\t\t$this->pro_name->setDbValue($this->Recordset->fields('pro_name'));\n\t\t\t\t\t$this->pro_description->setDbValue($this->Recordset->fields('pro_description'));\n\t\t\t\t\t$this->pro_condition->setDbValue($this->Recordset->fields('pro_condition'));\n\t\t\t\t\t$this->pro_features->setDbValue($this->Recordset->fields('pro_features'));\n\t\t\t\t\t$this->post_date->setDbValue($this->Recordset->fields('post_date'));\n\t\t\t\t\t$this->ads_id->setDbValue($this->Recordset->fields('ads_id'));\n\t\t\t\t\t$this->pro_base_price->setDbValue($this->Recordset->fields('pro_base_price'));\n\t\t\t\t\t$this->pro_sell_price->setDbValue($this->Recordset->fields('pro_sell_price'));\n\t\t\t\t\t$this->folder_image->setDbValue($this->Recordset->fields('folder_image'));\n\t\t\t\t\t$this->pro_status->setDbValue($this->Recordset->fields('pro_status'));\n\t\t\t\t\t$this->branch_id->setDbValue($this->Recordset->fields('branch_id'));\n\t\t\t\t\t$this->lang->setDbValue($this->Recordset->fields('lang'));\n\t\t\t\t} else {\n\t\t\t\t\tif (!ew_CompareValue($this->cat_id->DbValue, $this->Recordset->fields('cat_id')))\n\t\t\t\t\t\t$this->cat_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->company_id->DbValue, $this->Recordset->fields('company_id')))\n\t\t\t\t\t\t$this->company_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_model->DbValue, $this->Recordset->fields('pro_model')))\n\t\t\t\t\t\t$this->pro_model->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_name->DbValue, $this->Recordset->fields('pro_name')))\n\t\t\t\t\t\t$this->pro_name->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_description->DbValue, $this->Recordset->fields('pro_description')))\n\t\t\t\t\t\t$this->pro_description->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_condition->DbValue, $this->Recordset->fields('pro_condition')))\n\t\t\t\t\t\t$this->pro_condition->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_features->DbValue, $this->Recordset->fields('pro_features')))\n\t\t\t\t\t\t$this->pro_features->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->post_date->DbValue, $this->Recordset->fields('post_date')))\n\t\t\t\t\t\t$this->post_date->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->ads_id->DbValue, $this->Recordset->fields('ads_id')))\n\t\t\t\t\t\t$this->ads_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_base_price->DbValue, $this->Recordset->fields('pro_base_price')))\n\t\t\t\t\t\t$this->pro_base_price->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_sell_price->DbValue, $this->Recordset->fields('pro_sell_price')))\n\t\t\t\t\t\t$this->pro_sell_price->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->folder_image->DbValue, $this->Recordset->fields('folder_image')))\n\t\t\t\t\t\t$this->folder_image->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_status->DbValue, $this->Recordset->fields('pro_status')))\n\t\t\t\t\t\t$this->pro_status->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->branch_id->DbValue, $this->Recordset->fields('branch_id')))\n\t\t\t\t\t\t$this->branch_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->lang->DbValue, $this->Recordset->fields('lang')))\n\t\t\t\t\t\t$this->lang->CurrentValue = NULL;\n\t\t\t\t}\n\t\t\t\t$i++;\n\t\t\t\t$this->Recordset->MoveNext();\n\t\t\t}\n\t\t\t$this->Recordset->Close();\n\t\t}\n\t}", "abstract public function set();", "final protected function appendValues(array $values)\n {\n if ($this->isUsingPlaceholders()) {\n $values = array_values($values);\n } else {\n foreach ($values as $key => $value) {\n if (is_string($key)) {\n $safeKey = $this->convertToParameterName($key, $value);\n if ($key !== $safeKey) {\n unset($values[$key]);\n $values[$safeKey] = $value;\n }\n }\n }\n }\n $this->values = array_merge($this->values, $values);\n return $this;\n }", "private function _set_fields()\n {\n @$this->form_data->question_id = 0;\n\n $this->form_data->category_id = 0;\n $this->form_data->sub_category_id = 0;\n $this->form_data->sub_two_category_id = 0;\n $this->form_data->sub_three_category_id = 0;\n $this->form_data->sub_four_category_id = 0;\n\n $this->form_data->ques_text = '';\n $this->form_data->survey_weight = '';\n $this->form_data->ques_type = '';\n $this->form_data->qus_fixed = 0;\n $this->form_data->ques_expiry_date = '';\n\n\n $this->form_data->filter_question = '';\n $this->form_data->filter_category = 0;\n $this->form_data->filter_type = '';\n $this->form_data->filter_expired = '';\n }", "private function append($value)\n {\n \t$this->values[] = $value;\n }", "public function setValues($values)\n {\n foreach ($values as $field => $value)\n {\n if (isset($this->properties[$field])) {\n /** @var Property $this->$field */\n $this->$field->set($value);\n }\n }\n }", "function asignar_valores(){\n\t\t$this->codigo=$_POST['codigo'];\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->marca=$_POST['marca'];\n\t\t$this->fecha=$_POST['fecha'];\n\t\t$this->categoria=$_POST['categoria'];\n\t\t$this->hotel=$_POST['hoteles'];\n\t\t$this->cantidad=$_POST['cantidad'];\n\t\t$this->lugar=$_POST['lugar'];\n\t\t$this->prioridad=$_POST['prioridad'];\n\t\t$this->detal=$_POST['detal'];\n\t\t$this->mayor=$_POST['mayor'];\n\t\t$this->limite=$_POST['limite'];\n\t\t$this->descripcion=$_POST['descripcion'];\n\t\t$this->claves=$_POST['claves'];\n\t\t$this->segmento=$_POST['segmento'];\n\t\t$this->principal=$_POST['principal'];\n\t\t\n\t\t\n\t}", "private function fill( array $values ) {\n $this->address = $values[\"address\"];\n $this->city = $values[\"city\"];\n }", "function asignar_valores(){\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->apellido=$_POST['apellido'];\n\t\t$this->telefono=$_POST['telefono'];\n\t\t$this->email=$_POST['email'];\n\t\t\n\t\t$this->tipo=$_POST['tipo'];\n\t\t$this->ano=$_POST['ano'];\n\t\t$this->valor_vehiculo=$_POST['valor_vehiculo'];\n\t\t$this->saldo=$_POST['saldo'];\n\t\t$this->valor_inicial=$_POST['valor_inicial'];\n\t\t$this->comision=$_POST['comision'];\n\t\t$this->plazo=$_POST['plazo'];\n\t\t$this->cuotas=$_POST['cuotas'];\n\t\t$this->total=$_POST['total'];\n\t}", "protected function saveInfoValues() {\r\n\t\tif(is_a($this->infoValueCollection, 'tx_ptgsaconfmgm_infoValueCollection')) {\r\n\t\t\t\r\n\t\t\tif($this->tableName=='tx_ptconference_domain_model_persdata') {\r\n\t\t\t\t$persArticleUid = $this->rowUid;\r\n\t\t\t\t$relArticleUid = 0;\r\n\t\t\t} else {\r\n\t\t\t\t$persArticleUid = $this->get_persdata();\r\n\t\t\t\t$relArticleUid = $this->rowUid;\r\n\t\t\t}\t\t\t\r\n\t\t\t\r\n\t\t\tforeach($this->infoValueCollection as $infoValue) {\r\n\t\t\t\t$infoValue->set_persdata($persArticleUid);\r\n\t\t\t\t$infoValue->set_relarticle($relArticleUid);\r\n\t\t\t\t$infoValue->save();\r\n\t\t\t}\r\n\t\t}\r\n\t}", "protected function mergeflexFormValuesIntoConf() {}", "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $selection_grade_point;\n\t\t$selection_grade_point->selection_grade_points_id->setDbValue($rs->fields('selection_grade_points_id'));\n\t\t$selection_grade_point->grade_point->setDbValue($rs->fields('grade_point'));\n\t\t$selection_grade_point->min_grade->setDbValue($rs->fields('min_grade'));\n\t\t$selection_grade_point->max_grade->setDbValue($rs->fields('max_grade'));\n\t}", "protected function _afterLoad()\n {\n $value = $this->getValue();\n $value = $this->makeArrayFieldValue($value);\n $this->setValue($value);\n }", "public function addVars(array $args)\n {\n foreach ($args as $key => $value) {\n $this->$key = $value;\n }\n }", "function loadData()\n\t{\n\t\tstatic $data;\n\t\t\n\t\tif(!$data)\n\t\t\t$data=self::getData();\n\n\t\tif(isset($data[$this->id]))\n\t\t\t$this->setValues((array)$data[$this->id]);\t\t\t\n\t}", "public static function addVars($arr){\n self::$vars = array_merge(self::$vars, $arr);\n }", "public function setParameters()\n {\n $params = array();\n $associations = array();\n foreach ($this->datatablesModel->getColumns() as $key => $data) {\n // if a function or a number is used in the data property\n // it should not be considered\n if( !preg_match('/^(([\\d]+)|(function)|(\\s*)|(^$))$/', $data['data']) ) {\n $fields = explode('.', $data['data']);\n $params[$key] = $data['data'];\n $associations[$key] = array('containsCollections' => false);\n\n if (count($fields) > 1) {\n $this->setRelatedEntityColumnInfo($associations[$key], $fields);\n } else {\n $this->setSingleFieldColumnInfo($associations[$key], $fields[0]);\n }\n }\n }\n\n $this->parameters = $params;\n // do not reindex new array, just add them\n $this->associations = $associations + $this->associations;\n }", "abstract protected function reset_values();" ]
[ "0.7250785", "0.69737685", "0.6323317", "0.62667584", "0.6145783", "0.61200553", "0.60915506", "0.60873985", "0.5948566", "0.59265584", "0.5888247", "0.58600384", "0.5845055", "0.5834728", "0.5788722", "0.5757994", "0.572969", "0.5708453", "0.57060665", "0.5705191", "0.56948215", "0.56878066", "0.56809825", "0.56808674", "0.5673518", "0.5659513", "0.5657036", "0.56489086", "0.564754", "0.5646392", "0.56458354", "0.563938", "0.56073445", "0.5604222", "0.5602141", "0.5593421", "0.5583967", "0.5580747", "0.55750227", "0.55515224", "0.55312794", "0.5527392", "0.5527016", "0.5520592", "0.5516572", "0.5516112", "0.55114675", "0.5492273", "0.5458522", "0.5450687", "0.5434713", "0.5431489", "0.54211134", "0.54033583", "0.53970546", "0.5383588", "0.5378005", "0.53732866", "0.53732866", "0.53732866", "0.53482485", "0.53444505", "0.5338881", "0.5333031", "0.53276694", "0.5308188", "0.5307328", "0.53064734", "0.53025293", "0.5301209", "0.5283923", "0.5283544", "0.52816015", "0.52802134", "0.5277937", "0.5274255", "0.5271378", "0.52687347", "0.52604485", "0.52587", "0.5243805", "0.524225", "0.52264005", "0.5225261", "0.52209556", "0.5219321", "0.5203401", "0.5202875", "0.5197774", "0.51947457", "0.51754045", "0.5165759", "0.51622397", "0.51599777", "0.51574963", "0.5154939", "0.51540107", "0.5149358", "0.5146474", "0.5145639", "0.5144474" ]
0.0
-1
Add the values to be set
public function addSet($column, $value) { $this->params[$column] = $value; return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function add_values($values){\n foreach($values as $value){\n $this->add_value($value);\n }\n }", "public function add_values($values) : void\n {\n foreach($values as $value){\n $this -> add_value($value);\n }\n }", "function set_values() {\n\t\tparent::set_values();\n\t\t$currency = new currency($this->_currency_id);\n\t\t\n\t\t$this->order_id->value = $this->_order_id;\n\t\t$this->timestamp->value = date(\"j M Y\");\n\t\t$this->total_amount->value = $currency->format_money($this->_total_amount);\n\t}", "protected function initializeValues(): void\n {\n foreach ($this->params as $name => $infos) {\n if (!$this->is_sub_object && isset($infos['subobject']) && $infos['subobject']) {\n if (isset($infos['multivalues']) && $infos['multivalues']) {\n $this->values[$name] = [];\n } else {\n $tmp = get_class($this);\n $parts = explode('\\\\', $tmp);\n array_pop($parts);\n $class_name = implode('\\\\', $parts) . '\\\\' . $infos['type'];\n $class_name = str_replace('Entity', 'Datatype', $class_name);\n if (!class_exists($class_name)) {\n $class_name = str_replace(['\\\\EU\\\\', '\\\\AP\\\\', '\\\\EA\\\\'], '\\\\AM\\\\', $class_name);\n }\n $this->values[$name] = new $class_name();\n }\n } else {\n $this->values[$name] = null;\n }\n }\n }", "public function setValues($values = []);", "public function setValues($values);", "public function add(array $values = []): void\n {\n \t$this->values = array_replace($this->values, $values);\n\t}", "public function setAll($values)\r\n {\r\n foreach ($values as $key => $value)\r\n $this->$key = $value;\r\n }", "function setParamaters($valuetoadd=null) {\n if (empty($valuetoadd)) {\n $this->preparedvalues = array();\n return null;\n } else \n return array_push($this->preparedvalues, $valuetoadd); \n\t}", "public function set()\n {\n $args = func_get_args();\n $num = func_num_args();\n if ($num == 2) {\n self::$data[$args[0]] = $args[1];\n } else {\n if (is_array($args[0])) {\n foreach ($args[0] as $k => $v) {\n self::$data[$k] = $v;\n }\n }\n }\n }", "protected function populate_value()\n {\n }", "private function setValues()\n {\n foreach($this->data as $type => $values)\n if(!preg_match('/(library)/i', $type))\n foreach($values as $key => $value)\n $this->{strtolower($type)}[$key] = $value;\n }", "private function setValues($values)\n {\n //echo \"<pre>\";\n //print_r($values);\n //echo \"</pre>\";\n foreach ($values as $field => $value) {\n $this->$field = $value;\n }\n\n //echo \"<pre>\";\n //print_r($this);\n //echo \"</pre>\";\n //die();\n\n }", "function add( $values = array(), $post_id = 0, $is_main = false ) {\n\t\t\n\t\t// loop over values\n\t\tif( is_array($values) ) {\n\t\tforeach( $values as $key => $value ) {\n\t\t\t\n\t\t\t// get field\n\t\t\t$field = acf_get_field( $key );\n\t\t\t\n\t\t\t// check\n\t\t\tif( $field ) {\n\t\t\t\t\n\t\t\t\t// vars\n\t\t\t\t$name = $field['name'];\n\t\t\t\t\n\t\t\t\t// append values\n\t\t\t\t$this->meta[ $post_id ][ $name ] = $value;\n\t\t\t\t\n\t\t\t\t// append reference\n\t\t\t\t$this->meta[ $post_id ][ \"_$name\" ] = $key;\n\t\t\t}\n\t\t}}\n\t\t\n\t\t// set $post_id reference when is the main postmeta\n\t\tif( $is_main ) {\n\t\t\t$this->post_id = $post_id;\n\t\t}\n\t\t\n\t\t// initialize filters\n\t\t$this->initialize();\n\t}", "protected function adjustOptionsValues()\n {\n $this->init();\n $this->create();\n }", "public function addValues($value) {\n return $this->_add(2, $value);\n }", "public function setValues($values){\n\t\tif(!is_array($values)) return;\n\t\t\n\t\tforeach($values as $field_name => $value){\n\t\t\tif(isset($this->Fields[$field_name])){\n\t\t\t\t$this->Fields[$field_name]->value = $value;\n\t\t\t}\n\t\t}\n\t}", "public function copyAttributesToValues()\n\t{\n\t\tforeach( $this->values as $field=>$value )\n\t\t{\n\t\t\t$this->values[$field] = $this->$field ;\n\t\t}\n\t}", "public function setValues(){\n if($this->getType() == \"var\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"int\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"bool\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"string\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"nil\"){\n $pos = strpos($this->getArg(), \"@\");\n $this->setValue(substr($this->getArg(), $pos+1));\n }else if($this->getType() == \"label\"){\n $this->setValue($this->getArg());\n }else if($this->getType() == \"type\"){\n $this->setValue($this->getArg());\n }else{\n $this->setValue(\"CHYBA\");\n }\n }", "public function setValue($entries) {}", "protected function setSubmittedValues()\n {\n if ( $this->setFundraiserId() ) {\n $this->setFundraiserProfile(); \n }\n\n $this->setAmount();\n \n $this->setFirstName();\n $this->setLastName();\n $this->setEmail();\n $this->setTelephone();\n \n $this->setAddress();\n $this->setCity();\n $this->setCountry();\n $this->setRegion();\n $this->setPostalCode();\n \n $this->setAnonymity();\n $this->setHideAmount();\n }", "private function addValues($selected){\n $id = $this->answersId[$selected];\n $answersModel = new Answer();\n $answer = $answersModel->find($id);\n\n $this->score['heritage'] += $answer->heritage;\n $this->score['populated'] += $answer->populated;\n $this->score['weather'] += $answer->weather;\n $this->score['relax'] += $answer->relax;\n $this->score['sightseeing'] += $answer->sightseeing;\n }", "function setInputValues( array $values );", "public function assignValues($values=[]) {\n }", "function setDefaultValues() {}", "public function setValues($values)\n {\n $this->values = $values;\n }", "protected function set_values($num){\n if($num > 1 ){\n\n for($cnt = 1; $cnt <= ($num-1);$cnt++){\n $this->set_data($this->get_assign()[$cnt]);\n }//-> end of for\n\n } //-> end of main if\n\n }", "public function addValueMarkers() {\n\t\t$args = func_get_args();\n\t\t$this->setProperty('chm', $this->encodeData($args, ','), true);\n\t}", "public function setValues($values)\n {\n foreach ($this->entities as $entity) \n {\n $entity->setValues($values);\n }\n }", "public function setValues($values) {\n $this->values = $values;\n }", "public function append($values);", "private function assignValues() {\n $this->setIndicators('value');\n\n $leftIndicator = $this->sugarTemplateIndicators['valueLeft'] . $this->sugarTemplateIndicators['valueSeparator'];\n $rightIndicator = $this->sugarTemplateIndicators['valueSeparator'] . $this->sugarTemplateIndicators['valueRight'];\n\n foreach ($this->assignedValues as $tag => $value) {\n $this->rootContent = str_replace($leftIndicator . $tag . $rightIndicator, $value, $this->rootContent);\n }\n }", "public function withRestrictedSetValues()\n {\n foreach (func_get_args() as $RestrictedSetValues)\n {\n $this->_fields['RestrictedSetValues']['FieldValue'][] = $RestrictedSetValues;\n }\n return $this;\n }", "public function setValues($valueCollection) {\n\n foreach ($valueCollection as $key => $value) {\n if (isset($this[$key])) {\n $this[$key]->setValue($value);\n } //if\n } //foreach\n \n }", "public function setInputValues(&$values, $load = false);", "public function setvalues($questionData)\n {\n \t$this->questionData = $questionData;\n \n \tforeach ($questionData as $values) {\n \t\tforeach ($values as $name => $value) {\n \t\t\tif (!isset($this->fields[$name])) {\n \t\t\t\tcontinue;\n \t\t\t}\n \n \t\t\t$this->{$this->fields[$name]} = $value;\n \t\t}\n \t}\n }", "function setValues($list) {\n global $params;\n if (count($list)) {\n\tforeach ($list as $k=>$v) {\n\t $params[$k] = $v;\n\t}\n }\n}", "public function values($data){\n\t\tforeach($data as $key => $value){\n\t\t\tif(property_exists($this, $key)){\n\t\t\t\t$this->{$key} = $value;\n\t\t\t}\n\t\t}\n\t}", "public function values()\n {\n }", "private function setAutofillFields() {\n foreach (static::getFields() as $field_name => $field) {\n if ($field instanceof AutofillField) {\n $this->values[$field_name] = $field->fill();\n }\n }\n }", "public function setAll($values) {\n\t\tif (isset($values[self::$primaryKey[$this->table]])) {\n\t\t\t$this->originalData = $values;\n\t\t}\n\t\telse {\n\t\t\t$this->modifiedData = $values;\n\t\t}\n\t}", "function dbSetVars() {\n\n foreach ($this->fields() as $f) {\n if ($this->$f === false) continue;\n $this->db->set($f,$this->$f);\n }\n\n }", "public function set_values( $values = array() ) {\n\t\t\n\t\t$this->values = $values;\n\t\t\n\t}", "public function values() {\n\t\t// Get arguments :\n\t\t$args = func_get_args();\n\t\t\n\t\t// Add values :\n\t\tif (is_array($args[0])) {\n\t\t\tif ( ! is_array(reset($args[0]))) {\n\t\t\t\t// Deal with normal case : ->values(array(val1, val2, ...), array(val1, val2, ...), ...)\n\t\t\t\tforeach($args as $values_array)\n\t\t\t\t\t$this->push(new \\Glue\\DB\\Fragment_Item_Values($values_array));\n\t\t\t}\n\t\t\telse {\n\t\t\t\t// Array of arrays given, call this function recursively for each of them :\n\t\t\t\tforeach($args[0] as $arg)\n\t\t\t\t\t$this->values($arg);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t\t// List of values given, call this function recursively with the same values as an array :\n\t\t\t$this->values($args);\n\t\n\t\treturn $this;\n\t}", "function values( $vars ) {\n foreach($vars as $k=>$v) {\n $this->_vars[\"$k\"] = $v;\n }\n }", "public function addValues(\\google\\protobuf\\Value $value){\n return $this->_add(1, $value);\n }", "public function init()\n {\n if (!is_array($this->values)) {\n $this->values = [$this->values];\n }\n }", "public function merge_validater_value_list($list)\n {\n foreach ($list as $k => $v) {\n $this->_validater_value_arr[$k] = $v;\n }\n }", "function setData()\n {\n list($this->x, $this->y, $this->radius, $this->radius2) = $this->getInput();\n }", "public static function setters();", "function setValues($list) {\n global $params;\n if ( count($list )) {\n foreach ($list as $k => $v ) {\n $params[$k] = $v;\n }\n }\n}", "public function addDefaultEntriesAndValues() {}", "public function setValues(array $values);", "public function addValue($value);", "public function setDefaultValues()\n\t{\t\t\n\t\t\t \n\t}", "public function addVals($colVar) {\n $this->cols = array_keys($colVar);\n $this->vals = array_values($colVar);\n foreach($this->cols as $col) {\n $this->params[] = $this->colConvert($col);\n $this->types[] = $this->setParamType($colVar[$col]);\n }\n }", "public function fill($new_values): void\n {\n foreach ($this->data['fields'] as $field_name => &$field_value) {\n if (key_exists($field_name, $new_values)) {\n $field_value['value'] = $new_values[$field_name];\n }\n }\n }", "public static function get_values()\n {\n }", "public static function get_values()\n {\n }", "public static function get_values()\n {\n }", "public function add()\n {\n for ($i = 0 ; $i < func_num_args(); $i++) {\n $this->addSingle(func_get_arg($i));\n }\n }", "function LoadMultiUpdateValues() {\r\n\t\t$this->CurrentFilter = $this->GetKeyFilter();\r\n\r\n\t\t// Load recordset\r\n\t\tif ($this->Recordset = $this->LoadRecordset()) {\r\n\t\t\t$i = 1;\r\n\t\t\twhile (!$this->Recordset->EOF) {\r\n\t\t\t\tif ($i == 1) {\r\n\t\t\t\t\t$this->Nro_Serie->setDbValue($this->Recordset->fields('Nro_Serie'));\r\n\t\t\t\t\t$this->SN->setDbValue($this->Recordset->fields('SN'));\r\n\t\t\t\t\t$this->Cant_Net_Asoc->setDbValue($this->Recordset->fields('Cant_Net_Asoc'));\r\n\t\t\t\t\t$this->Id_Marca->setDbValue($this->Recordset->fields('Id_Marca'));\r\n\t\t\t\t\t$this->Id_Modelo->setDbValue($this->Recordset->fields('Id_Modelo'));\r\n\t\t\t\t\t$this->Id_SO->setDbValue($this->Recordset->fields('Id_SO'));\r\n\t\t\t\t\t$this->Id_Estado->setDbValue($this->Recordset->fields('Id_Estado'));\r\n\t\t\t\t\t$this->User_Server->setDbValue($this->Recordset->fields('User_Server'));\r\n\t\t\t\t\t$this->Pass_Server->setDbValue($this->Recordset->fields('Pass_Server'));\r\n\t\t\t\t\t$this->User_TdServer->setDbValue($this->Recordset->fields('User_TdServer'));\r\n\t\t\t\t\t$this->Pass_TdServer->setDbValue($this->Recordset->fields('Pass_TdServer'));\r\n\t\t\t\t\t$this->Cue->setDbValue($this->Recordset->fields('Cue'));\r\n\t\t\t\t\t$this->Fecha_Actualizacion->setDbValue($this->Recordset->fields('Fecha_Actualizacion'));\r\n\t\t\t\t\t$this->Usuario->setDbValue($this->Recordset->fields('Usuario'));\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif (!ew_CompareValue($this->Nro_Serie->DbValue, $this->Recordset->fields('Nro_Serie')))\r\n\t\t\t\t\t\t$this->Nro_Serie->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->SN->DbValue, $this->Recordset->fields('SN')))\r\n\t\t\t\t\t\t$this->SN->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cant_Net_Asoc->DbValue, $this->Recordset->fields('Cant_Net_Asoc')))\r\n\t\t\t\t\t\t$this->Cant_Net_Asoc->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Marca->DbValue, $this->Recordset->fields('Id_Marca')))\r\n\t\t\t\t\t\t$this->Id_Marca->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Modelo->DbValue, $this->Recordset->fields('Id_Modelo')))\r\n\t\t\t\t\t\t$this->Id_Modelo->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_SO->DbValue, $this->Recordset->fields('Id_SO')))\r\n\t\t\t\t\t\t$this->Id_SO->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Id_Estado->DbValue, $this->Recordset->fields('Id_Estado')))\r\n\t\t\t\t\t\t$this->Id_Estado->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_Server->DbValue, $this->Recordset->fields('User_Server')))\r\n\t\t\t\t\t\t$this->User_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_Server->DbValue, $this->Recordset->fields('Pass_Server')))\r\n\t\t\t\t\t\t$this->Pass_Server->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->User_TdServer->DbValue, $this->Recordset->fields('User_TdServer')))\r\n\t\t\t\t\t\t$this->User_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Pass_TdServer->DbValue, $this->Recordset->fields('Pass_TdServer')))\r\n\t\t\t\t\t\t$this->Pass_TdServer->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Cue->DbValue, $this->Recordset->fields('Cue')))\r\n\t\t\t\t\t\t$this->Cue->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Fecha_Actualizacion->DbValue, $this->Recordset->fields('Fecha_Actualizacion')))\r\n\t\t\t\t\t\t$this->Fecha_Actualizacion->CurrentValue = NULL;\r\n\t\t\t\t\tif (!ew_CompareValue($this->Usuario->DbValue, $this->Recordset->fields('Usuario')))\r\n\t\t\t\t\t\t$this->Usuario->CurrentValue = NULL;\r\n\t\t\t\t}\r\n\t\t\t\t$i++;\r\n\t\t\t\t$this->Recordset->MoveNext();\r\n\t\t\t}\r\n\t\t\t$this->Recordset->Close();\r\n\t\t}\r\n\t}", "public function addData($data) {\n foreach ($data as $value) {\n $this->add(new Option($value));\n }\n }", "function asignar_valores(){\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->prioridad=$_POST['prioridad'];\n\t\t$this->etiqueta=$_POST['etiqueta'];\n\t\t$this->descripcion=$_POST['descripcion'];\n\t\t$this->claves=$_POST['claves'];\n\t\t$this->tipo=$_POST['tipo'];\n\t\t$this->icono=$_POST['icono'];\n\t}", "public function store(): void\r\n {\r\n if (empty($this->errors[$this->artribute])) {\r\n $this->data[$this->artribute] = $this->value;\r\n }\r\n }", "public function finish_setting_parameters()\n {\n $this->set_variable( 'parameters', $this->parameters );\n }", "public function setTestValues()\r\n {\r\n $fname = array(\"Jesper\", \"Nicolai\", \"Alex\", \"Stefan\", \"Helmut\", \"Elvis\");\r\n $lname = array(\"Gødvad\", \"Lundgaard\", \"Killing\", \"Meyer\", \"Schottmüller\", \"Presly\");\r\n $city = array(\"Copenhagen\", \"Århus\", \"Collonge\", \"Bremen\", \"SecretPlace\" );\r\n $country = array(\"Denmark\", \"Germany\", \"France\", \"Ümlaudia\", \"Graceland\");\r\n $road = array(\" Straße\", \" Road\", \"vej\", \" Boulevard\");\r\n \r\n $this->number = rand(1000,1010);\r\n $this->name = $fname[rand(0,5)] . \" \" . $lname[rand(0,5)];\r\n $this->email = \"[email protected]\";\r\n $this->address= \"Ilias\" . $road[rand(0,3)] .\" \" . rand(1,100);\r\n $this->postalcode = rand(2000,7000);\r\n $this->city = $city[rand(0,3)];\r\n $this->country = $country[rand(0,4)];\r\n $this->phone = \"+\" . rand(1,45) . \" \" . rand(100,999) . \" \" . rand(1000, 9999);\r\n $this->ean = 0;\r\n $this->website = ilERPDebtor::website; \r\n }", "function appendAllListOfValuesToItem(&$item) {\n $iter = $item->getMetadataIterator();\n $this->appendAllListOfValues($iter);\n }", "public function setAll(array $values): self {\n $this->record = array_merge($this->record, $values);\n return $this;\n }", "protected function prepareForValidation()\n {\n $merge = [];\n\n if ($this->valtotal) {\n $merge['valtotal'] = Format::strToFloat($this->valtotal);\n }\n\n $this->merge($merge);\n }", "public function setValues($values = array(), $append = false) {\n\t\tif ($append) {\n\t\t\tforeach ($values as $key => $value) {\n\t\t\t\tif (isset($this->values[$key]) && is_string($this->values[$key])) {\n\t\t\t\t\t$this->values[$key] .= $value;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$this->values[$key] = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\t$this->values = array_merge($this->values, $values);\n\t\t}\n\t\treturn $this;\n\t}", "protected function _setFieldValues($values) {\n foreach ($this->getElements() as $key => $element) {\n if (count(explode('_', $key)) == 3) {\n list($parent_id, $option_id, $field_id) = explode('_', $key);\n if (isset($values[$field_id])) {\n $element->setValue($values[$field_id]);\n }\n }\n }\n }", "public function applyDefaultValues()\n {\n $this->setregis = 0;\n }", "public function setValues(array $_values=array()){\n foreach(($getElements=self::getElements()) as $key=>$items){\n $this->{$key}=(\n (isset($_values[self::getFormName()][$key]))\n ?$_values[self::getFormName()][$key]\n :NULL\n );\n $getElementsv[$key]->setValue($this->{$key});\n }\n }", "private function _setParams ()\n {\n $endpoint = $this->_endpoint->getData();\n if (count($endpoint) > 0) {\n \n $method = $this->_endpoint->getUrl();\n $methodname = 'setParameter' . ucfirst($method['method']);\n \n $this->_httpclient->{$methodname}('access_token', \n $this->_accesstoken);\n $this->_httpclient->{$methodname}('api_secret', $this->_apisecret);\n \n foreach ($endpoint as $param => $value) {\n $this->_httpclient->{$methodname}($param, $value);\n }\n }\n }", "public function setVars( array $vars ) {\n $this->vars += $vars;\n }", "public function addSet( array $set ) {\n $this->set = array_merge( $this->set, $set );\n }", "private function setTotalAmounts()\n {\n $taxable\t= 0.00;\n $expenses = 0.00;\n $outlays\t= 0.00;\n\n foreach ($this->invoiceDetails as $invoiceDetail) {\n $amount = $invoiceDetail->getAmount();\n switch ($invoiceDetail->getType())\n {\n case 'incoming':\n $taxable += $amount;\n break;\n case 'expense':\n $taxable += $amount;\n $expenses += $amount;\n break;\n case 'outlay':\n $outlays += $amount;\n break;\n }\n }\n\n $this->setTotalTaxable($taxable);\n $this->setTotalExpenses($expenses);\n $this->setTotalOutlays($outlays);\n }", "public function add(array $items): void\n {\n foreach ($items as $key => $values) {\n $this->set($key, $values);\n }\n }", "protected function setProperties()\n {\n foreach ($this->data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function setValues(array $values): void\n {\n $this->values = array_map(function ($value) {\n return ChunkRecommendationsValue::constructFromArray(['value' => $value]);\n }, $values);\n }", "function load_values($data = false) {\n\t\tif ($data === false) {\n\t\t\tfix_POST_slashes();\n\t\t\t$data = $_POST;\n\t\t}\n\t\tforeach ($this->fields as $field) {\n\t\t\tif ($field->get_multiple_values()) {\n\t\t\t\t$field_name = $field->get_var_name();\n\t\t\t\tif (isset($data[$field_name])) {\n\t\t\t\t\t$field->set_value($data[$field_name]);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif (isset($data[$field->get_name()])) {\n\t\t\t\t\t$field->set_value($data[$field->get_name()]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "protected function buildBindings(): void\n {\n $this->bindings = $this->fieldValueSet->getBoundValues();\n }", "function LoadMultiUpdateValues() {\n\t\t$this->CurrentFilter = $this->GetKeyFilter();\n\n\t\t// Load recordset\n\t\tif ($this->Recordset = $this->LoadRecordset()) {\n\t\t\t$i = 1;\n\t\t\twhile (!$this->Recordset->EOF) {\n\t\t\t\tif ($i == 1) {\n\t\t\t\t\t$this->cat_id->setDbValue($this->Recordset->fields('cat_id'));\n\t\t\t\t\t$this->company_id->setDbValue($this->Recordset->fields('company_id'));\n\t\t\t\t\t$this->pro_model->setDbValue($this->Recordset->fields('pro_model'));\n\t\t\t\t\t$this->pro_name->setDbValue($this->Recordset->fields('pro_name'));\n\t\t\t\t\t$this->pro_description->setDbValue($this->Recordset->fields('pro_description'));\n\t\t\t\t\t$this->pro_condition->setDbValue($this->Recordset->fields('pro_condition'));\n\t\t\t\t\t$this->pro_features->setDbValue($this->Recordset->fields('pro_features'));\n\t\t\t\t\t$this->post_date->setDbValue($this->Recordset->fields('post_date'));\n\t\t\t\t\t$this->ads_id->setDbValue($this->Recordset->fields('ads_id'));\n\t\t\t\t\t$this->pro_base_price->setDbValue($this->Recordset->fields('pro_base_price'));\n\t\t\t\t\t$this->pro_sell_price->setDbValue($this->Recordset->fields('pro_sell_price'));\n\t\t\t\t\t$this->folder_image->setDbValue($this->Recordset->fields('folder_image'));\n\t\t\t\t\t$this->pro_status->setDbValue($this->Recordset->fields('pro_status'));\n\t\t\t\t\t$this->branch_id->setDbValue($this->Recordset->fields('branch_id'));\n\t\t\t\t\t$this->lang->setDbValue($this->Recordset->fields('lang'));\n\t\t\t\t} else {\n\t\t\t\t\tif (!ew_CompareValue($this->cat_id->DbValue, $this->Recordset->fields('cat_id')))\n\t\t\t\t\t\t$this->cat_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->company_id->DbValue, $this->Recordset->fields('company_id')))\n\t\t\t\t\t\t$this->company_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_model->DbValue, $this->Recordset->fields('pro_model')))\n\t\t\t\t\t\t$this->pro_model->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_name->DbValue, $this->Recordset->fields('pro_name')))\n\t\t\t\t\t\t$this->pro_name->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_description->DbValue, $this->Recordset->fields('pro_description')))\n\t\t\t\t\t\t$this->pro_description->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_condition->DbValue, $this->Recordset->fields('pro_condition')))\n\t\t\t\t\t\t$this->pro_condition->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_features->DbValue, $this->Recordset->fields('pro_features')))\n\t\t\t\t\t\t$this->pro_features->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->post_date->DbValue, $this->Recordset->fields('post_date')))\n\t\t\t\t\t\t$this->post_date->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->ads_id->DbValue, $this->Recordset->fields('ads_id')))\n\t\t\t\t\t\t$this->ads_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_base_price->DbValue, $this->Recordset->fields('pro_base_price')))\n\t\t\t\t\t\t$this->pro_base_price->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_sell_price->DbValue, $this->Recordset->fields('pro_sell_price')))\n\t\t\t\t\t\t$this->pro_sell_price->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->folder_image->DbValue, $this->Recordset->fields('folder_image')))\n\t\t\t\t\t\t$this->folder_image->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->pro_status->DbValue, $this->Recordset->fields('pro_status')))\n\t\t\t\t\t\t$this->pro_status->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->branch_id->DbValue, $this->Recordset->fields('branch_id')))\n\t\t\t\t\t\t$this->branch_id->CurrentValue = NULL;\n\t\t\t\t\tif (!ew_CompareValue($this->lang->DbValue, $this->Recordset->fields('lang')))\n\t\t\t\t\t\t$this->lang->CurrentValue = NULL;\n\t\t\t\t}\n\t\t\t\t$i++;\n\t\t\t\t$this->Recordset->MoveNext();\n\t\t\t}\n\t\t\t$this->Recordset->Close();\n\t\t}\n\t}", "abstract public function set();", "final protected function appendValues(array $values)\n {\n if ($this->isUsingPlaceholders()) {\n $values = array_values($values);\n } else {\n foreach ($values as $key => $value) {\n if (is_string($key)) {\n $safeKey = $this->convertToParameterName($key, $value);\n if ($key !== $safeKey) {\n unset($values[$key]);\n $values[$safeKey] = $value;\n }\n }\n }\n }\n $this->values = array_merge($this->values, $values);\n return $this;\n }", "private function _set_fields()\n {\n @$this->form_data->question_id = 0;\n\n $this->form_data->category_id = 0;\n $this->form_data->sub_category_id = 0;\n $this->form_data->sub_two_category_id = 0;\n $this->form_data->sub_three_category_id = 0;\n $this->form_data->sub_four_category_id = 0;\n\n $this->form_data->ques_text = '';\n $this->form_data->survey_weight = '';\n $this->form_data->ques_type = '';\n $this->form_data->qus_fixed = 0;\n $this->form_data->ques_expiry_date = '';\n\n\n $this->form_data->filter_question = '';\n $this->form_data->filter_category = 0;\n $this->form_data->filter_type = '';\n $this->form_data->filter_expired = '';\n }", "private function append($value)\n {\n \t$this->values[] = $value;\n }", "public function setValues($values)\n {\n foreach ($values as $field => $value)\n {\n if (isset($this->properties[$field])) {\n /** @var Property $this->$field */\n $this->$field->set($value);\n }\n }\n }", "function asignar_valores(){\n\t\t$this->codigo=$_POST['codigo'];\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->marca=$_POST['marca'];\n\t\t$this->fecha=$_POST['fecha'];\n\t\t$this->categoria=$_POST['categoria'];\n\t\t$this->hotel=$_POST['hoteles'];\n\t\t$this->cantidad=$_POST['cantidad'];\n\t\t$this->lugar=$_POST['lugar'];\n\t\t$this->prioridad=$_POST['prioridad'];\n\t\t$this->detal=$_POST['detal'];\n\t\t$this->mayor=$_POST['mayor'];\n\t\t$this->limite=$_POST['limite'];\n\t\t$this->descripcion=$_POST['descripcion'];\n\t\t$this->claves=$_POST['claves'];\n\t\t$this->segmento=$_POST['segmento'];\n\t\t$this->principal=$_POST['principal'];\n\t\t\n\t\t\n\t}", "private function fill( array $values ) {\n $this->address = $values[\"address\"];\n $this->city = $values[\"city\"];\n }", "function asignar_valores(){\n\t\t$this->nombre=$_POST['nombre'];\n\t\t$this->apellido=$_POST['apellido'];\n\t\t$this->telefono=$_POST['telefono'];\n\t\t$this->email=$_POST['email'];\n\t\t\n\t\t$this->tipo=$_POST['tipo'];\n\t\t$this->ano=$_POST['ano'];\n\t\t$this->valor_vehiculo=$_POST['valor_vehiculo'];\n\t\t$this->saldo=$_POST['saldo'];\n\t\t$this->valor_inicial=$_POST['valor_inicial'];\n\t\t$this->comision=$_POST['comision'];\n\t\t$this->plazo=$_POST['plazo'];\n\t\t$this->cuotas=$_POST['cuotas'];\n\t\t$this->total=$_POST['total'];\n\t}", "protected function saveInfoValues() {\r\n\t\tif(is_a($this->infoValueCollection, 'tx_ptgsaconfmgm_infoValueCollection')) {\r\n\t\t\t\r\n\t\t\tif($this->tableName=='tx_ptconference_domain_model_persdata') {\r\n\t\t\t\t$persArticleUid = $this->rowUid;\r\n\t\t\t\t$relArticleUid = 0;\r\n\t\t\t} else {\r\n\t\t\t\t$persArticleUid = $this->get_persdata();\r\n\t\t\t\t$relArticleUid = $this->rowUid;\r\n\t\t\t}\t\t\t\r\n\t\t\t\r\n\t\t\tforeach($this->infoValueCollection as $infoValue) {\r\n\t\t\t\t$infoValue->set_persdata($persArticleUid);\r\n\t\t\t\t$infoValue->set_relarticle($relArticleUid);\r\n\t\t\t\t$infoValue->save();\r\n\t\t\t}\r\n\t\t}\r\n\t}", "protected function mergeflexFormValuesIntoConf() {}", "function LoadRowValues(&$rs) {\n\t\tglobal $conn, $selection_grade_point;\n\t\t$selection_grade_point->selection_grade_points_id->setDbValue($rs->fields('selection_grade_points_id'));\n\t\t$selection_grade_point->grade_point->setDbValue($rs->fields('grade_point'));\n\t\t$selection_grade_point->min_grade->setDbValue($rs->fields('min_grade'));\n\t\t$selection_grade_point->max_grade->setDbValue($rs->fields('max_grade'));\n\t}", "protected function _afterLoad()\n {\n $value = $this->getValue();\n $value = $this->makeArrayFieldValue($value);\n $this->setValue($value);\n }", "public function addVars(array $args)\n {\n foreach ($args as $key => $value) {\n $this->$key = $value;\n }\n }", "function loadData()\n\t{\n\t\tstatic $data;\n\t\t\n\t\tif(!$data)\n\t\t\t$data=self::getData();\n\n\t\tif(isset($data[$this->id]))\n\t\t\t$this->setValues((array)$data[$this->id]);\t\t\t\n\t}", "public static function addVars($arr){\n self::$vars = array_merge(self::$vars, $arr);\n }", "public function setParameters()\n {\n $params = array();\n $associations = array();\n foreach ($this->datatablesModel->getColumns() as $key => $data) {\n // if a function or a number is used in the data property\n // it should not be considered\n if( !preg_match('/^(([\\d]+)|(function)|(\\s*)|(^$))$/', $data['data']) ) {\n $fields = explode('.', $data['data']);\n $params[$key] = $data['data'];\n $associations[$key] = array('containsCollections' => false);\n\n if (count($fields) > 1) {\n $this->setRelatedEntityColumnInfo($associations[$key], $fields);\n } else {\n $this->setSingleFieldColumnInfo($associations[$key], $fields[0]);\n }\n }\n }\n\n $this->parameters = $params;\n // do not reindex new array, just add them\n $this->associations = $associations + $this->associations;\n }", "abstract protected function reset_values();" ]
[ "0.7250785", "0.69737685", "0.6323317", "0.62667584", "0.6145783", "0.61200553", "0.60915506", "0.60873985", "0.5948566", "0.59265584", "0.5888247", "0.58600384", "0.5845055", "0.5834728", "0.5788722", "0.5757994", "0.572969", "0.5708453", "0.57060665", "0.5705191", "0.56948215", "0.56878066", "0.56809825", "0.56808674", "0.5673518", "0.5659513", "0.5657036", "0.56489086", "0.564754", "0.5646392", "0.56458354", "0.563938", "0.56073445", "0.5604222", "0.5602141", "0.5593421", "0.5583967", "0.5580747", "0.55750227", "0.55515224", "0.55312794", "0.5527392", "0.5527016", "0.5520592", "0.5516572", "0.5516112", "0.55114675", "0.5492273", "0.5458522", "0.5450687", "0.5434713", "0.5431489", "0.54211134", "0.54033583", "0.53970546", "0.5383588", "0.5378005", "0.53732866", "0.53732866", "0.53732866", "0.53482485", "0.53444505", "0.5338881", "0.5333031", "0.53276694", "0.5308188", "0.5307328", "0.53064734", "0.53025293", "0.5301209", "0.5283923", "0.5283544", "0.52816015", "0.52802134", "0.5277937", "0.5274255", "0.5271378", "0.52687347", "0.52604485", "0.52587", "0.5243805", "0.524225", "0.52264005", "0.5225261", "0.52209556", "0.5219321", "0.5203401", "0.5202875", "0.5197774", "0.51947457", "0.51754045", "0.5165759", "0.51622397", "0.51599777", "0.51574963", "0.5154939", "0.51540107", "0.5149358", "0.5146474", "0.5145639", "0.5144474" ]
0.0
-1
The SET query part
public function toSql() { if ($this->isEmpty()) { return ''; } $params = $this->getParams(); $sql = array('SET'); $set = array(); foreach ($params as $column => $value) { $set[] = implode(' = ', array( $column, $this->getBuilder()->getHelper()->toDbValue($value) )); } $sql[] = implode(', ', $set); return implode(' ', $sql); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setValue(string $query, array $data): void;", "abstract public function set();", "function set_row($keys,$sql_set) {\r\n $sql_where = '';\r\n if (count($keys) > 0) {\r\n $sql_wheres = array();\r\n foreach ($keys as $key=>$val) {\r\n if (is_array($val)) die('setrow: multi value does not supported');\r\n $sql_wheres[] = \"`$key`='\".myaddslashes($val).\"'\";\r\n }\r\n $sql_where = ' where '.join(' and ',$sql_wheres);\r\n }\r\n if (is_array($sql_set)) { # Note, if using array, I DONOT support mysql function/expression!! use string for that.\r\n $sql_sets = array();\r\n foreach ($sql_set as $key=>$val) {\r\n $sql_sets[] = '`'.$key.'` = \\''.addslashes($url).'\\'';\r\n }\r\n $sql_set = join(',',$sql_sets);\r\n }\r\n assert($sql_where != ''); # safeguard against setting all rows\r\n $sql = 'update `'.$this->db_table.'` set '.$sql_set.$sql_where;\r\n #~ echo $sql;exit;\r\n $res = mysql_query($sql) or die('<br>'.$sql.'<br>'.mysql_error()); #do to database\r\n }", "public abstract function set(string $query, array $data) : bool;", "public function set($query_var, $value)\n {\n }", "public function set($column,$value);", "public function testIncrementalSet()\n {\n $method = $this->builder_reflection->getMethod('sql_set');\n $method->setAccessible(TRUE);\n\n $property = $this->builder_reflection->getProperty('set');\n $property->setAccessible(TRUE);\n\n $method->invokeArgs($this->builder, array( array('column1' => 'value1')));\n $method->invokeArgs($this->builder, array( array('column2' => 'value2')));\n\n $string = 'SET column1 = value1, column2 = value2';\n\n $this->assertEquals($string, $property->getValue($this->builder));\n }", "function _set ($data_array, $o = TRUE) {\n\t\t$statement = $o ? ' SET ' : ' ';\n\t\t$count = count($data_array);\n\t\t$pointer = 0;\n\t\tforeach ($data_array as $column_name => $value) {\n\t\t\t$statement .= '`' . $column_name . '` = ';\n\t\t\tif ($pointer == $count - 1) {\n\t\t\t\t$statement .= $this->escape($data_array[$column_name]);\n\t\t\t} else {\n\t\t\t\t$statement .= $this->escape($data_array[$column_name]) . ', ';\n\t\t\t}\n\t\t\t$pointer ++;\n\t\t}\n\t\treturn $statement;\n\t}", "public function set($sql, $execArr = array())\n {\n $stmt = $this->db->prepare($sql);\n $stmt->execute($execArr);\n }", "function set_query($query) {\n\t\t\t// it just sets the query with which to get a recordset\n\t\t\t$this->query = $query;\n\t\t}", "abstract protected function _setData(PDOStatement $stm);", "public static function query_set($query = NULL)\n\t{\n\t\treturn new Database_SQLite_DML_Set($query);\n\t}", "function dbSetVars() {\n\n foreach ($this->fields() as $f) {\n if ($this->$f === false) continue;\n $this->db->set($f,$this->$f);\n }\n\n }", "public function set()\n {\n\tforeach( $this->queue as $operation => $actions)\n\t{\n\t foreach($actions as $key => $action)\n\t {\n\t\tif ( is_array($action->sql))\n\t\t{\n\t\t array_walk($action->sql, array($this, 'query'));\n\t\t}\n\t\telse\n\t\t{\n\t\t $this->query($action->sql);\n\t\t}\n\t }\n\t}\n }", "public function forUpdate($set = TRUE);", "public function update($table,$set,$where,$data = array()){\n\t\t$this->_query = \"UPDATE $table SET $set WHERE $where \";\n\t\t$stmt = $this->db->prepare($this->_query);\n\t\t$stmt->execute($data);\n\t}", "function set_table_data($table, $fields, $condition = NULL)\n{\n global $connection;\n $results = $connection->query(\"SET NAMES utf8\");\n\n if (!$results) { print (\"error=\".$connection->get_error().\"<br>\"); return false; }\n if (!$condition) $sql = \"UPDATE $table SET $fields\";\n else $sql = \"UPDATE $table SET $fields WHERE $condition\";\n _dbg($sql);\n //$results = $connection->query($sql);\n if (!$results) {\n print (\"error=\".$connection->get_error().\"<br>\");\n return false;\n }\n //_dbg($results);\n return $results;\n}", "public function setQuery(array $query);", "abstract public function set($in): void;", "public function setAll($values) {\n\t\tif (isset($values[self::$primaryKey[$this->table]])) {\n\t\t\t$this->originalData = $values;\n\t\t}\n\t\telse {\n\t\t\t$this->modifiedData = $values;\n\t\t}\n\t}", "abstract protected function alter_set($name,$value);", "function set_transaction_value($id, $value){\n $str_query=\"update pos_transaction set value = $value where transaction_id='$id'\";\n return $this->query($str_query);\n }", "public function setQuery($query);", "public function update($table,$set,$where){\n return $this->runQuery(\"UPDATE $table SET $set $where\");\n }", "function update_single_field($table,$set_field,$set_value,$where_field,$where_value)\n\t{\n\t\tglobal $db;\n\n\t\t$sql = \"UPDATE $table SET $set_field = '$set_value' WHERE $where_field = '$where_value'\";\n\n\t\tif( !$result = $db->sql_query($sql) )\n\t\t{\n\t\t\tmessage_die(GENERAL_ERROR, 'Could Not Update Garage DB', '', __LINE__, __FILE__, $sql);\n\t\t}\n\t\n\t\treturn;\n\t}", "public function setQueryData($query_data) {}", "protected function create_set($data = []){\n $set = '';\n foreach($data as $column => $value){\n // make sure it is in our column list before we add it to the WHERE\n if(in_array($column, $this->column_list)){\n // the first time through add the SET keyword, otherwise add a comma\n $set .= (strlen($set) == 0 ? \"SET \" : \", \") . \"$column = \\\"$value\\\"\";\n }\n }\n return $set;\n }", "private function executeQuery() {\n\t\t$recordset = $this->getConnection()->execute( $this );\n\t\t\n\t\tif( $recordset === false ) {\n\t\t\t$this->_recordset = array();\n\t\t} else {\n\t\t\t$this->_recordset = $recordset;\n\t\t}\n\n\t\t$this->_currentRow = 0;\n\t\t$this->isDirty( false );\n\t}", "public function set($data);", "function array_to_set_clause($a_vars) {\n\tglobal $mysqli;\n\n\t$a_set = array();\n\t$a_values = array();\n\tforeach($a_vars as $k=>$v) {\n\t\t\t$k = $mysqli->real_escape_string($k);\n\t\t\t$v = $mysqli->real_escape_string($v);\n\t\t\t$a_set[] = $k;\n\t\t\t$a_values[] = $v;\n\t}\n\t$s_set = \"(`\".implode(\"`,`\", $a_set).\"`) VALUES ('\".implode(\"','\",$a_values).\"')\";\n\treturn $s_set;\n}", "public function setQuery(rbQuery &$query) {\n $this->query =& $query;\n }", "public function set($params) {}", "public function setData($data)\n\t{\n\t\t//Check all the array values\n\t\tforeach ($data as $row)\n\t\t{\n\t\t\tif(!($row instanceof DataSet))\n\t\t\t{\n\t\t\t\tthrow new QueryException('To set the data for this object, the submission must be an array of Staple_Query_DataSet objects.', Error::APPLICATION_ERROR);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//Sync the dataSet with the current query's connection.\n\t\t\t\t$row->setConnection($this->getConnection());\n\t\t\t}\n\t\t}\n\t\t$this->data = $data;\n\t\treturn $this;\n\t}", "public function set($arrParams)\n\t{\n\t\t$arrParams = $this->escapeParams($arrParams);\n\n\t\t// INSERT\n\t\tif (strncasecmp($this->strQuery, 'INSERT', 6) === 0)\n\t\t{\n\t\t\t$strQuery = sprintf('(%s) VALUES (%s)',\n\t\t\t\t\t\t\t\timplode(', ', array_keys($arrParams)),\n\t\t\t\t\t\t\t\timplode(', ', array_values($arrParams)));\n\t\t}\n\n\t\t// UPDATE\n\t\telseif (strncasecmp($this->strQuery, 'UPDATE', 6) === 0)\n\t\t{\n\t\t\t$arrSet = array();\n\n\t\t\tforeach ($arrParams as $k=>$v)\n\t\t\t{\n\t\t\t\t$arrSet[] = $k . '=' . $v;\n\t\t\t}\n\n\t\t\t$strQuery = 'SET ' . implode(', ', $arrSet);\n\t\t}\n\n\t\t$this->strQuery = str_replace('%p', $strQuery, $this->strQuery);\n\t\treturn $this;\n\t}", "public function SQL_UPDATE() {\r\n\t}", "public function write() {\n\t\t$database = Registry::get(\"database\");\n\t\t$v = \"value='\" . $this -> value . \"'\";\n\t\t$statement = Registry::get(\"database\") -> query(\"UPDATE server.configs SET \" . $v . \" WHERE key_='\" . $this -> key . \"'\");\n\t}", "public function testInitialSet()\n {\n $method = $this->builder_reflection->getMethod('sql_set');\n $method->setAccessible(TRUE);\n\n $property = $this->builder_reflection->getProperty('set');\n $property->setAccessible(TRUE);\n\n $method->invokeArgs($this->builder, array( array('column1' => 'value1')));\n\n $string = 'SET column1 = value1';\n\n $this->assertEquals($string, $property->getValue($this->builder));\n }", "public function set($where, $data) {\n if ($where) {\n $this->db->where($where);\n return $this->db->update($this->table, $data);\n }\n\t}", "public function getValueSet(&$arguments)\n {\n /* Get all the values */\n $this->c--;\n $word = $this->getNextWord(true);\n\n switch (true) {\n /* statement is in the form \"(col, col, ...) VALUES ( value, value, ... )\" */\n case (substr($word, 0, 1) == '('):\n {\n /* Create a parser for the column names */\n $word = substr($word, 1, strlen($word) - 2);\n $column_parser = new wordParser($word);\n\n /* get column names */\n while ($column = $column_parser->getNextWord(false, $this->whitespace . \",\")) {\n $columns[] = $column;\n }\n\n /* Get values */\n if (substr($word = strtolower($this->getNextWord(true)), 0, 6) == 'values') {\n while ($word = $this->getNextWord(true, $this->whitespace . \",\")) {\n /* Create a new parser for the values */\n $values = array();\n $word = substr($word, 1, strlen($word) - 2);\n $word = str_replace('\\\\', '\\\\\\\\', $word);\n $values_parser = new wordParser($word);\n\n while ($value = $values_parser->getNextWord(true, $this->whitespace . \",\")) {\n $values[] = $value;\n }\n\n foreach ($columns as $key => $value) {\n $arguments['values'][$value] = isset($values[$key]) ? $values[$key] : 0;\n }\n\n /* Return whatever results we got back */\n return $arguments;\n }\n } else {\n $this->throwSyntaxError($arguments);\n }\n\n break;\n }\n\n /* Statement is in the form \"SET [col = value...] */\n case (strtolower(substr($word, 0, 3)) == 'set'):\n {\n if (strtolower($word) == 'set') {\n $word = $this->getNextWord(true, $this->whitespace);\n }\n\n /* Seperate all of the column/value pairs */\n $word = substr($word, strpos($word, '(') + 1);\n $word = substr($word, 0, strrpos($word, ')'));\n $word = str_replace('\\\\', '\\\\\\\\', $word);\n $set_parser = new wordParser($word);\n\n while ($column = $set_parser->getNextWord(true, $this->whitespace . \",=\")) {\n $value = $set_parser->getNextWord(true, $this->whitespace . \",=\");\n $arguments['values'][$column] = $value;\n }\n\n break;\n }\n\n /* Syntax error */\n default:\n {\n $this->throwSyntaxError($arguments);\n\n break;\n }\n }\n }", "abstract public function setValue($value);", "public function set_query_var($key, $value)\n {\n }", "function lr_set($pid, $record) {\n list($ns, $x) = explode(':', $pid);\n list($rec, $sort) = explode('.', $x);\n $db = lr_connect( );\n $table = lr_make_table($db, $ns);\n $sql = \"INSERT INTO ?n SET rec=?i, sort=?i, text=?s ON DUPLICATE KEY UPDATE text=?s\";\n $db->query($sql, $table, $rec, $sort, $record, $record);\n}", "public function setQuery(?string $value): void {\n $this->getBackingStore()->set('query', $value);\n }", "protected function _update()\n\t{\n\t\t// UPDATE 'table' SET\n\t\t$this->_query = 'UPDATE '.$this->_table.' SET ';\n\n\t\t// * / row1, row2\n\t\t$first = true;\n\t\t$vals = '';\n\t\tforeach($this->_set as $key => $value) {\n\t\t\t$this->_query .= ($first) ? ('') : (', '); \n\t\t\t$this->_query .= \"$key = '$value'\";\n\n\t\t\t$first = false;\n\t\t} // foreach\n\n\t\t// WHERE foo = 'bar'\n\t\t$this->_query .= ' WHERE ';\n\t\t$imax = count($this->_where);\n\t\t$first = true;\n\t\tfor($i=0; $i<$imax; $i++) {\n\t\t\t$this->_query .= ($first) ? ('') : (' AND '); \n\t\t\t$first = false;\n\n\t\t\t$this->_query .= $this->_where[$i]['row'].' ';\n\t\t\t$this->_query .= $this->_where[$i]['condition'].' \\'';\n\t\t\t$this->_query .= $this->_where[$i]['value'].'\\'';\n\t\t} // foreach\n\n\t\t// end ;\n\t\t$this->_query .= ';';\n\n\t\treturn $this->_query;\n\t}", "protected function doSet($value)\n {\n }", "public function updateQuestion()\r\n{\r\n $query_string = \"UPDATE questions \";\r\n $query_string .= \"SET \";\r\n $query_string .= \"quizid = :quizid, \";\r\n $query_string .= \"question = :question, \";\r\n $query_string .= \"choice1 = :choice1, \";\r\n $query_string .= \"choice2 = :choice2, \";\r\n $query_string .= \"choice3 = :choice3, \";\r\n $query_string .= \"choice4 = :choice4, \";\r\n $query_string .= \"ans = :ans \";\r\n $query_string .= \"WHERE questionid = :questionid \";\r\n\r\n return $query_string;\r\n}", "public static function SQLSet( $tConnection, $tData )\n\t{\n\t\t$tempSet = \"\";\n\t\t\n\t\t$tempIsComma = false;\n\t\tforeach ( $tData as $tempKey => $tempValue )\n\t\t{\n\t\t\tif ( $tempIsComma )\n\t\t\t{\n\t\t\t\t$tempSet .= \",\";\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$tempIsComma = true;\n\t\t\t}\n\t\t\t\n\t\t\t$tempSet .= $tConnection->escape_string( $tempKey ) . \"='\" . $tConnection->escape_string( $tempValue ) . \"'\";\n\t\t}\n\t\t\n\t\treturn \"SET \" . $tempSet;\n\t}", "public function set($id, $value);", "public function set($id, $value);", "public function update( $table, $set, $where='', $shutdown=false, $preformatted=false, $add_join=array() );", "public function update(){\n $set_param_cols_vals = $this->iniParamvalues($this->data, \",\");\n // check for extra set_column\n $extra_set = ($this->custom !== NULL) ? $this->custom : NULL ;\n if($this->custom !== NULL){\n if($this->data !== NULL){\n if(!empty($this->where)){\n $this->custom = \",$this->custom\"; \n }\n else{\n $this->custom = 'WHERE '.$this->custom; \n }\n }\n else{\n if(empty($this->where)){\n $this->custom = 'WHERE '.$this->custom; \n }\n else{\n $this->custom = $this->custom; \n }\n } \n }\n // set where cols param values\n $set_param_where = $this->update_iniParamvalues($this->where, \"and\", \"WHERE\");\n\n $sql = \"UPDATE \".self::$table.\" SET $set_param_cols_vals $this->custom $set_param_where\";\n\n // prepare sql statement\n $this->query = $this->conn->prepare($sql);\n\n // bind cols_vals param values\n $this->update_cusBindparam($this->data);\n \n // bind where param values\n if(!empty($this->data)){\n $this->cusBindparam($this->where,count($this->data)+1); \n }\n else if(!empty($this->where)){\n $this->cusBindparam($this->where); \n }\n // execute query\n $execute = $this->query->execute();\n\n if(!$execute){\n return false;\n }\n else{\n return true;\n }\n }", "private function setField()\n {\n $sql = '';\n $sql = rtrim($sql , ', ');\n\n foreach (array_keys($this->data) as $key){\n $sql .= '`' . $key . '` = ?, ';\n }\n\n $sql = rtrim($sql , ', ');\n return $sql;\n }", "private function update()\n {\n $queryString = 'UPDATE ' . $this->table . ' SET ';\n foreach ($this->data as $column => $value) {\n if ($column != self::ID) {\n $queryString .= $column . ' =:' . $column . ',';\n }\n }\n $queryString .= ' updated_at = sysdate() WHERE 1 = 1 AND ' . self::ID . ' =:' . self::ID;\n $this->query = $this->pdo->prepare($queryString);\n }", "abstract function set ($item, $data);", "abstract public function update(string $table, array $set, array $where, array $options = []): int;", "private function setQuery($sql){\n $this->isStatement = false;\n return $this->sqli->query($sql);\n }", "public function offsetSet($offset, $data) {\n\t\tthrow new Exception('Not allowed to set data on a result set');\n\t}", "public function __set( $name, $value ) {\n\t\tif( $this->getTable()->hasColumn( $name ) ) {\n\t\t\t$this->_updateBuffer[ $name ] = $value;\n\t\t}\n\t}", "function offsetSet ($i, $v) { \n if ($i === NULL) $i = count($this->operands);\n $v = self::parse_items($v);\n array_splice($this->operands, $i, 1, $v);\n $this->processed = false;\n }", "function update($query, $param_type, $param_value_array) {\n $sql = $this->connection->prepare($query);\n $this->bindQueryParams($sql, $param_type, $param_value_array);\n $sql->execute();\n }", "private function setVariable($var, $val, $is_int) {\n\t\t$stmt = $this->db->prepare ( 'SET ' . $var . ' := ?' );\n\t\tif ($is_int)\n\t\t\t$stmt->bind_param ( 'i', $val );\n\t\telse\n\t\t\t$stmt->bind_param ( 's', $val );\n\t\t$result = $stmt->execute ();\n\t}", "protected final function simple_update_query ( $sql )\n\t{\n\t\t//----------\n\t\t// Tables\n\t\t//----------\n\n\t\t$_tables = array();\n\t\tif ( !isset( $sql['tables'] ) )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\tif ( !is_array( $sql['tables'] ) )\n\t\t{\n\t\t\t$sql['tables'] = array( $sql['tables'] );\n\t\t}\n\t\tif ( !count( $sql['tables'] ) )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\tforeach ( $sql['tables'] as $_table )\n\t\t{\n\t\t\t# If \"table name aliases\" are used\n\t\t\tif ( is_array( $_table ) and count( $_table ) )\n\t\t\t{\n\t\t\t\tforeach ( $_table as $_alias=>$_table_name )\n\t\t\t\t{\n\t\t\t\t\tif ( is_numeric( $_alias ) )\n\t\t\t\t\t{\n\t\t\t\t\t\t$_tables[] = $this->db->quoteIdentifier( $this->attach_prefix( $_table_name ), true );\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$_tables[] = $this->db->quoteIdentifier( $this->attach_prefix( $_table_name ), true )\n\t\t\t\t\t\t\t. \" AS \"\n\t\t\t\t\t\t\t. $this->db->quoteIdentifier( $_alias, true );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t# If its just an array of strings - i.e. no \"table name aliases\"\n\t\t\telse\n\t\t\t{\n\t\t\t\t$_tables[] = $this->db->quoteIdentifier( $this->attach_prefix( $_table ), true );\n\t\t\t}\n\t\t}\n\n\t\t//---------\n\t\t// \"SET\"\n\t\t//---------\n\n\t\tif ( !count( $sql['set'] ) )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t$_set = array();\n\t\tforeach ( $sql['set'] as $_col => $_val )\n\t\t{\n\t\t\tif ( $_val instanceof Zend_Db_Expr )\n\t\t\t{\n\t\t\t\t$_val = $_val->__toString();\n\t\t\t\tunset( $sql['set'][ $_col ] );\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$_val = \"?\";\n\t\t\t}\n\t\t\t$_set[] = $this->db->quoteIdentifier( $_col, true ) . ' = ' . $_val;\n\t\t}\n\n\t\t//-----------\n\t\t// \"WHERE\"\n\t\t//-----------\n\n\t\t$_where = ! is_array( $sql['where'] ) ? array( $sql['where'] ) : $sql['where'];\n\n\t\tforeach ($_where as $_cond => &$_term) {\n # is $_cond an int? (i.e. Not a condition)\n if ( is_int( $_cond ) ) {\n # $_term is the full condition\n if ( $_term instanceof Zend_Db_Expr ) {\n $_term = $_term->__toString();\n }\n } else {\n # $_cond is the condition with placeholder,\n # and $_term is quoted into the condition\n $_term = $this->db->quoteInto( $_cond, $_term );\n }\n $_term = '(' . $_term . ')';\n }\n\n $_where = implode(' AND ', $_where);\n\n\t\t//------------------------------\n\t\t// Build the UPDATE statement\n\t\t//------------------------------\n\n\t\t$this->cur_query = \"UPDATE \"\n\t\t\t. implode( \", \" , $_tables )\n\t\t\t. \" SET \" . implode( \", \" , $_set )\n\t\t\t. ( $_where ? \" WHERE \" . $_where : \"\" );\n\n\t\t//----------------------------------------------------------------\n\t\t// Execute the statement and return the number of affected rows\n\t\t//----------------------------------------------------------------\n\n\t\ttry\n\t\t{\n\t\t\t$stmt = $this->db->query( $this->cur_query, array_values( $sql['set'] ) );\n\t\t\t$result = $stmt->rowCount();\n\t\t\treturn $result;\n\t\t}\n\t\tcatch ( Zend_Db_Exception $e )\n\t\t{\n\t\t\t$this->Registry->exception_handler( $e );\n\t\t\treturn false;\n\t\t}\n\t}", "public function set(string $id, $value);", "public function setquery($c = \"No comment!\", $query = \"NONEE\", $data_array = array(), $run = true){\n\t\t$this->comment = $c;\n\t\t$query = $this->securestring($query,$data_array);\n\t\t$this->query = $query;\n\t\t\n\t\tif($run)\n\t\t\treturn $this->resultset = $this->query($query);\n\t}", "abstract protected function platformUpdateStatement($table, array $sets);", "public function setQuery($query)\n {\n throw new Exception('The setQuery() method is not supported by ' . get_class($this));\n }", "public function __set($name, $value)\n\t{\n \t\tif ($this->column_data[$name] !== $value)\n\t\t{\n\t\t\t$this->column_data[$name] = $value;\n\t\t\t$this->altered_columns[$name] = $name;\n\t\t}\n\t}", "public function setQuery($query) {\r\n $this->query = $query;\r\n }", "public function setFunc($name, $value){\n //$statement = $this->db->prepare('INSERT INTO storage (name, value) VALUES (:name, :value);');\n //$statement->bindValue(':name', $name);\n //$statement->bindValue(':value', $value);\n //$statement->execute();\n $select = $this->db->prepare('SELECT * FROM storage WHERE name = :name;');\n $select->bindValue(':name', $name);\n\n $insert = $this->db->prepare('INSERT INTO storage (name, value) VALUES (:name, :value);');\n $insert->bindValue(':name', $name);\n $insert->bindValue(':value', $value);\n\n $update = $this->db->prepare('UPDATE storage SET value = :value WHERE name = :name;');\n $update->bindValue(':name', $name);\n $update->bindValue(':value', $value);\n\n $selectResult = $select->execute();\n $row = $selectResult->fetchArray();\n\n if($row){\n $update->execute();\n }else{\n $insert->execute();\n }\n }", "public function set($values, $alias = FALSE, $original = FALSE)\n\t{\n\t\t$meta = $this->meta();\n\t\t\n\t\t// Accept set('name', 'value');\n\t\tif (!is_array($values))\n\t\t{\n\t\t\t$values = array($values => $alias);\n\t\t\t$alias = FALSE;\n\t\t}\n\t\t\n\t\t// Determine where to write the data to, changed or original\n\t\tif ($original)\n\t\t{\n\t\t\t$data_location =& $this->_original;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$data_location =& $this->_changed;\n\t\t}\n\n\t\t// Why this way? Because it allows the model to have \n\t\t// multiple fields that are based on the same column\n\t\tforeach($values as $key => $value)\n\t\t{\n\t\t\t// Key is coming from a with statement\n\t\t\tif (substr($key, 0, 1) === ':')\n\t\t\t{\n\t\t\t\t$targets = explode(':', ltrim($key, ':'), 2);\n\t\t\t\t\n\t\t\t\t// Alias as it comes back in, which allows people to use with()\n\t\t\t\t// with alaised field names\n\t\t\t\t$relationship = $this->field(array_shift($targets), TRUE);\n\t\t\t\t\t\t\t\t\n\t\t\t\tif (!array_key_exists($relationship, $this->_with_values))\n\t\t\t\t{\n\t\t\t\t\t$this->_with_values[$relationship] = array();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$this->_with_values[$relationship][implode(':', $targets)] = $value;\n\t\t\t}\n\t\t\t// Key is coming from a database result\n\t\t\telse if ($alias === TRUE && !empty($meta->columns[$key]))\n\t\t\t{\n\t\t\t\t// Contains an array of fields that the column is mapped to\n\t\t\t\t// This allows multiple fields to get data from the same column\n\t\t\t\tforeach ($meta->columns[$key] as $field)\n\t\t\t\t{\n\t\t\t\t\t$data_location[$field] = $meta->fields[$field]->set($value);\n\t\t\t\t\t\n\t\t\t\t\t// Invalidate the cache\n\t\t\t\t\tif (array_key_exists($field, $this->_retrieved))\n\t\t\t\t\t{\n\t\t\t\t\t\tunset($this->_retrieved[$field]);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Standard setting of a field \n\t\t\telse if ($alias === FALSE && $field = $this->field($key))\n\t {\n\t\t\t\t$value = $field->set($value);\n\t\t\t\t\n\t\t\t\t// Ensure value has actually changed\n\t\t\t\tif ($field->in_db && $value == $this->_original[$field->name])\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$data_location[$field->name] = $value;\n\n\t\t\t\t// Invalidate the cache\n\t\t\t\tif (array_key_exists($field->name, $this->_retrieved))\n\t\t\t\t{\n\t\t\t\t\tunset($this->_retrieved[$field->name]);\n\t\t\t\t}\n \t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->_unmapped[$key] = $value;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $this;\n\t}", "private function setParams($statement, $parameters = array()){\n\t\tforeach ($parameters as $key => $value) { ///percorrer as linhas rows\n\t\t\t$this->setParam($key,$value);///percorer as colunas ID\n\t\t}\n\t}", "function update($values){\n\n $id = $values['id'];\n unset($values['id']);\n $query = \" UPDATE \" . $this->tableName;\n $separator = \" SET \";\n\n foreach ($values as $key => $value){\n $query .= $separator . $key . \" = '\" . $value . \"'\";\n $separator = \", \";\n\n }\n $query .= \" where id = $id \";\n $query .= \";\";\n return $this->dbh->query($query);\n \n }", "protected function set_query($sql) {\n $this->open_link();\n $this->conx->query($sql);\n $this->close_link();\n }", "public function __set( $key, $val )\n {\n $this->data_buffer[$key] = $val;\n\n if(isset($this->rules_objects_list[$this->table_name]))\n {\n $l_target = $this->rules_objects_list[$this->table_name];\n if($l_target->rules_error_flag)\n {\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n return UQL_RULE_FAIL;\n }\n }\n\n $l_rules_object_count = @count($this->rules_objects_list);\n if(($l_rules_object_count == 0) || (!isset($this->rules_objects_list[$this->table_name])))\n {\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n return UQL_RULE_OK;\n }\n\n $l_target_rule = $this->rules_objects_list[$this->table_name];\n\n if($l_target_rule == null)\n {\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n return UQL_RULE_OK;\n }\n\n $l_rules = $l_target_rule->getRules();\n\n if((@count($l_rules) == 0) || (strcmp($key,'UQL') == 0) || (!isset($l_rules[$key])))\n {\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n return UQL_RULE_OK;\n }\n\n $rules_list = $l_rules[$key];\n\n foreach($rules_list as $rule_name =>$rule_value)\n {\n //value not assigned\n if(!isset($this->data_buffer[$key]))\n continue;\n\n if($l_target_rule->applyRule($rule_name,$key,$this->data_buffer[$key])\n == UQL_RULE_NOT_MATCHED)\n {\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n return UQL_RULE_FAIL;\n }\n }\n\n $this->data_buffer[$key] = $this->applyInFilter($key,$this->data_buffer[$key]);\n\n return UQL_RULE_OK;\n }", "public function update(){\n if(empty($this->attributes)){\n return;\n }\n if ($this->isAutoInc) {\n $fieldsList = \" SET \";\n foreach ($this->attributes as $column => $value) {\n $fieldsList.=$column.\"=\".'\\''.$value.'\\''.\", \";\n }\n $fieldsList = str_last_replace(\", \", \"\", $fieldsList);\n $sqlQuery = \"UPDATE \".$this->table.$fieldsList.\" WHERE \".$this->idName.\"=\".$this->attributes[$this->idName];\n\n Db::instance()->execute($sqlQuery,$this->attributes);\n }\n }", "public function set(): self\n {\n $this->query = \" KEY \";\n return $this;\n }", "public function setQuery($query)\n {\n $this->query = $query;\n }", "public static function update($__tabela__ = null){\n\t self::getInstance();\n\t $__sql__ = \"UPDATE $__tabela__\";\n\t return new QSet($__sql__) ;\n\t\t}", "public function replace($table = '', $set = NULL)\n\t{\n\t\tif ($set !== NULL)\n\t\t{\n\t\t\t$this->set($set);\n\t\t}\n\n\t\tif (count($this->qb_set) === 0)\n\t\t{\n\t\t\treturn ($this->db_debug) ? $this->display_error('db_must_use_set') : FALSE;\n\t\t}\n\n\t\tif ($table === '')\n\t\t{\n\t\t\tif ( ! isset($this->qb_from[0]))\n\t\t\t{\n\t\t\t\treturn ($this->db_debug) ? $this->display_error('db_must_set_table') : FALSE;\n\t\t\t}\n\n\t\t\t$table = $this->qb_from[0];\n\t\t}\n\n\t\t$sql = $this->_replace($this->protect_identifiers($table, TRUE, NULL, FALSE), array_keys($this->qb_set), array_values($this->qb_set));\n\n\t\t$this->_reset_write();\n\t\treturn $this->query($sql);\n\t}", "function set($name, $value){\n \t $this->result[$name] = $value; \n \t}", "public function applyTo($q) {\n//\t\tprivate $valuesets = array(); // QRYvalueset array (insert/update pairs)\n\n\t\tif ($this->flags & QRY::NAMED_PARAMS) {\n\t\t\t$q->option('named_params', 1);\n\t\t}\n\n\t\tforeach ($this->tablesets as $set) {\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\t$q->FROM($elem->asName(), $elem->asAlias());\n\t\t\t}\n\t\t}\n\n\t\tforeach ($this->fieldsets as $set) {\n\t\t\t//print_r($set);\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\t//print_r($elem);\n\t\t\t\t$q->SELECT($elem->asName());\n\t\t\t}\n\t\t}\n\n\t\tforeach ($this->matchsets as $j => $set) {\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\tif (get_class($elem) == 'QRYset') {\n\t\t\t\t\t$q->WHERE_literal($elem->toString());\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$left_table = $elem->getLeft()->asTable();\n\t\t\t\t$left_name = $elem->getLeft()->asName();\n\t\t\t\t$left = $elem->getLeft()->asAlias();\n\t\t\t\t$right = $elem->getRight();\n\t\t\t\t$cmp = $elem->asCmp();\n\t\t\t\t$literal = false;\n\t\t\t\t$right_ptr = NULL;\n\t\t\t\tif ($cmp == 'IN' && get_class($right) == 'QRYset') {\n\t\t\t\t\t$param_arr = $right->toArray();\n\t\t\t\t\t$dataset = $this->getSet('data', 0);\n\t\t\t\t\t$dataset_arr = $dataset->toArray();\n\t\t\t\t\t$right_ptr = array();\n\t\t\t\t\tforeach ($param_arr as $offset => $param) {\n\t\t\t\t\t\t$name = $param->asName();\n\t\t\t\t\t\tif (isset($dataset_arr[$name])) {\n\t\t\t\t\t\t\t$right_ptr[] = $dataset_arr[$name];\n\t\t\t\t\t\t} else if (isset($dataset_arr[$offset])) {\n\t\t\t\t\t\t\t$right_ptr[] = $dataset_arr[$offset];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif ($left == $left_table . '__' . $left_name) {\n\t\t\t\t\t$left = $left_table . '.' . $left_name;\n\t\t\t\t}\n\t\t\t\t$q->WHERE_once($left, $cmp, $right_ptr, $literal);\n\t\t\t}\n\t\t}\n\t\t\n\t\tforeach ($this->ordersets as $set) {\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\t$q->ORDER_BY($elem->asName(), $elem->asOrder());\n\t\t\t}\n\t\t}\t\t\n\n\t\tforeach ($this->groupsets as $set) {\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\t$q->GROUP_BY($elem->asName());\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\t\n\t\t/* datasets */\n\t\t$matchset = $q->getSet('match', 0);\t\n\t\tforeach ($this->datasets as $j => $set) {\n\t\t\t$dataset = $q->getSet('data', $j);\t\n\t\t\tif (!$dataset) $dataset = $q->add_DATASET();\n\t\t\t$k = 0;\n\t\t\tfor ($i = 0; $i < $set->count(); $i++) {\n\t\t\t\t$match = $matchset->findByOffset($k);\n\t\t\t\tif (get_class($match) == 'QRYmatch' && $match->asCmp() == 'IN') {\t\t\t\t\t\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t$elem = $set->findByOffset($i);\n\t\t\t\t$key = $set->keyByOffset($i);\n\t\t\t\tif (is_numeric($key)) $key = null;\n\t\t\t\t$q->add_DATA($key, $elem, $dataset); \n\t\t\t\t$k++;\n\t\t\t}\n\t\t\t//$q->DATA($arr);\n\n\t\t}\n\n\t\treturn true;\n\t}", "static function Update($table,$param,$param_value,$condition){\n mysql_query(\"update $table set $param = $param_value where $condition\");\n }", "public function update() {\n $Sql = \"UPDATE \" . $this->tableName[0] . \" SET \";\n foreach ($this->fieldListArray as $Key_ => $Value_) {\n $Sql = $Sql . \"$Key_='$Value_', \";\n }\n $Sql = substr($Sql, 0, strlen($Sql) - 2);\n $Sql = $Sql . \" WHERE \";\n foreach ($this->conditionArray as $Key_ => $Value_) {\n $Sql = $Sql . \"$Key_='$Value_' AND \";\n }\n $Sql = substr($Sql, 0, strlen($Sql) - 4);\n //echo $Sql;\n return mysqli_query($this->dataBaseConnect->getConnection(), $Sql);\n }", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function setValue($value) {}", "public function dset($property,$value){\n $this->$property = $value;\n $table = $this->table;\n $id = $this->id; \n LAIKA_Database::update($table, $property, $value, \"id = $id\");\n }", "public function set(array $data) {\n if ( $this->_active_query->getType() != QueryBuilder::UPDATE_QUERY ) {\n throw new DataBaseServiceException(sprintf('Este m&eacute;todo es exclusivo de la acci&oacute;n (%s)', QueryBuilder::UPDATE_QUERY));\n }\n $this->_active_query->values($data);\n \n return $this;\n }", "public function updateSystemInformation()\r\n{\r\n $query_string = \"UPDATE voting_system \";\r\n $query_string .= \"SET \";\r\n $query_string .= \"systemname = :systemname, \";\r\n $query_string .= \"systemtypeid = :systemtypeid, \";\r\n $query_string .= \"systemsummary = :systemsummary, \";\r\n $query_string .= \"systeminformation = :systeminformation \";\r\n $query_string .= \"WHERE systemid = :systemid\";\r\n\r\n return $query_string;\r\n}", "function db_get_set_statement($mysqli, $items)\n{\n\t$escape = function($item) use ($mysqli) {\n\t\treturn array('name' => $item['name'],\n\t\t 'value' => __db_escape_values($mysqli, $item['type'], $item['value']));\n\t};\n\n\t$set = function($item) {\n\t\treturn $item['name'] . '=' . $item['value'];\n\t};\n\n\t$items = array_map($escape, $items);\n\t$items = array_map($set, $items);\n\treturn implode(',', $items);\n}", "abstract protected function handle_set($name,$value);" ]
[ "0.6577078", "0.651119", "0.649975", "0.647158", "0.6420095", "0.639119", "0.63017696", "0.62586385", "0.60579413", "0.6026459", "0.6004224", "0.5979236", "0.5977533", "0.59477216", "0.5939463", "0.58916676", "0.5887042", "0.58489305", "0.5842189", "0.58301145", "0.58284885", "0.5821256", "0.58052254", "0.5763411", "0.5740877", "0.5712503", "0.57119596", "0.5707695", "0.57012314", "0.56607515", "0.56459874", "0.5630037", "0.56162345", "0.56126356", "0.5610812", "0.5607215", "0.56001693", "0.55976635", "0.5582292", "0.5578181", "0.5573531", "0.55639666", "0.5561181", "0.55461866", "0.5536957", "0.55301404", "0.55234104", "0.55232203", "0.55232203", "0.5520786", "0.55170786", "0.5510326", "0.55042285", "0.55017054", "0.54945743", "0.54878825", "0.5482419", "0.5476792", "0.5470581", "0.54644734", "0.54531187", "0.544884", "0.54474", "0.54429954", "0.5431163", "0.5424393", "0.54110736", "0.5409915", "0.5409671", "0.5408444", "0.54052126", "0.53948796", "0.53932726", "0.5388631", "0.53799325", "0.53778183", "0.53712714", "0.53674877", "0.5357566", "0.5357433", "0.535656", "0.5356187", "0.53511465", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.5351049", "0.53504413", "0.53504413", "0.5350184", "0.5340871", "0.53380686", "0.5336211", "0.5329906" ]
0.0
-1
Make config publishment optional by merging the config from the package.
public function register() { $this->app->bind('BizimHesapB2b', function($app) { return new BizimHesapB2b(); }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function setupConfig()\n {\n $this->publishes([\n __DIR__ . '/config' => config_path(),\n ], 'config');\n\n $this->mergeConfigFrom(__DIR__ . '/../config/package-blueprint.php', 'package-blueprint');\n }", "private function mergeConfig() {\n\t\t$this->mergeConfigFrom(\n\t\t\t__DIR__ . '/../config/config.php', 'sl-upload'\n\t\t);\n\t}", "protected function publishConfig()\n {\n $this->publishes([\n $this->packagePath('config/config.php') => config_path($this->package . '.php')\n ], 'config');\n }", "private function mergeConfig()\n {\n $countries = $this->countryIso();\n $this->app->configure('priongeography');\n\n $this->mergeConfigFrom(\n __DIR__ . '/config/priongeography.php',\n 'priongeography'\n );\n }", "private function publishConfig()\n\t{\n\t\t$config = __DIR__ . '/config/workflow.php';\n\n\t\t$this->publishes([$config => config_path('workflow.php')]);\n\n\t\t$this->mergeConfigFrom($config, 'workflow');\n\t}", "private function mergeDefaultSettings(){\n\t\t//Get a copy of the default configuration.\n\t\t$defaultConfig = $this->getDefaultConfig();\n\t\t//Check for a 'general' section\n\t\tif(array_key_exists('general', $this->configuration)){\n\t\t\t//If it exists, compare the default keys to the loaded config for missing values\n\t\t\t$missingGeneral = array_diff_key($defaultConfig['general'], $this->configuration['general']);\n\t\t\t//Iterate through the missing values and attach them to the running configuration.\n\t\t\tif(count($missingGeneral) > 0){\n\t\t\t\tforeach($missingGeneral as $key=>$parameter){\n\t\t\t\t\t$this->configuration['general'][$key] = $parameter;\n\t\t\t\t}\n\t\t\t}\n\t\t}else{\n\t\t\t//Section doesn't exist, so we need to set it to the defaults.\n\t\t\t$this->configuration['general'] = $defaultConfig['general'];\n\t\t}\n\t\t//Check for a 'options' section\n\t\tif(array_key_exists('options', $this->configuration)){\n\t\t\t//If it exists, compare the default keys to the loaded config for missing values\n\t\t\t$missingOptions = array_diff_key($defaultConfig['options'], $this->configuration['options']);\n\t\t\t//Iterate through the missing values and attach them to the running configuration.\n\t\t\tif(count($missionOptions) > 0){\n\t\t\t\tforeach($missingOptions as $key=>$parameter){\n\t\t\t\t\t$this->configuration['options'][$key] = $parameter;\n\t\t\t\t}\n\t\t\t}\n\t\t}else{\n\t\t\t//Section doesn't exist, so we need to set it to the defaults.\n\t\t\t$this->configuration['options'] = $defaultConfig['options'];\n\t\t}\n\t}", "protected function configHandle()\n {\n $packageConfigPath = __DIR__.'/config/config.php';\n $appConfigPath = config_path('task-management.php');\n\n $this->mergeConfigFrom($packageConfigPath, 'task-management');\n\n $this->publishes([\n $packageConfigPath => $appConfigPath,\n ], 'config');\n }", "private function configure(): void\n {\n if (!$this->app->configurationIsCached()) {\n $this->mergeConfigFrom(__DIR__ . '/../config/paket.php', 'paket');\n }\n }", "private function mergeConfig()\n\t{\n\t\t$this->mergeConfigFrom(\n\t\t\t__DIR__ . '/../config/config.php', 'l5-sms'\n\t\t);\n\t}", "public function testNoComposerExtrasConfig()\n {\n\n $this->composer->setConfig(new Config(false, __DIR__ . '/ExcludeFolders/ValidIMLFile'));\n\n $this->io\n ->expects($this->never())\n ->method('write');\n\n $this->filesystem->expects($this->never())\n ->method('dumpFile');\n\n ExcludeFolders::update($this->event, $this->filesystem);\n }", "private function mergeConfig()\n {\n $this->mergeConfigFrom(\n __DIR__.'/../config/config.php', 'routecache'\n );\n }", "protected function publishConfig()\n {\n $path = __DIR__.'/../config/disqus.php';\n $this->mergeConfigFrom($path, 'disqus');\n $this->publishes([\n $path => config_path('disqus.php'),\n ], 'disqus');\n }", "protected function publishConfig()\n {\n $this->publishes([\n __DIR__ . '/../config/acl.php' => config_path('acl.php'),\n ], 'config');\n }", "function apsa_merge_config() {\n global $apsa_uninstall;\n global $apsa_child_uninstall;\n if (!empty($apsa_child_uninstall)) {\n $apsa_uninstall = array_merge_recursive($apsa_uninstall, $apsa_child_uninstall);\n }\n}", "protected function setPackageConfigurationFile()\n {\n $config = __DIR__ . '/Config/recaptcha.php';\n $path = config_path('recaptcha.php');\n \n $this->publishes([$config => $path], 'config'); \n $this->mergeConfigFrom( $config, 'recaptcha');\n }", "protected function mergeConfig()\n {\n $this->mergeConfigFrom(__DIR__.\"/../config/{$this->name}.php\", $this->name);\n }", "private function publishConfig()\n {\n if ($this->app->environment('testing')) {\n return;\n }\n\n $this->publishes(\n [__DIR__ . '/..' . Settings::LARAVEL_PUBLISHABLE_CONFIG => LaravelConfig::configPublishPath()],\n 'config'\n );\n }", "protected function publishConfig()\n {\n $this->publishes([\n $this->basePath('config/flare/config.php') => config_path('flare/config.php'),\n ]);\n }", "private function bootConfig(): void\n {\n $baseDir = __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR;\n $configDir = $baseDir . 'config' . DIRECTORY_SEPARATOR;\n\n $this->publishes([\n $configDir . 'laravel-database-emails.php' => config_path('laravel-database-emails.php'),\n ], 'laravel-database-emails-config');\n }", "public static function syncConfig()\n {\n $addon = self::addon();\n\n if (!self::isBackwardsCompatible() && !$addon->hasConfig('synchronize')) {\n $addon->setConfig('synchronize', false);\n\n if (\n $addon->getConfig('synchronize_actions') == true ||\n $addon->getConfig('synchronize_modules') == true ||\n $addon->getConfig('synchronize_templates') == true ||\n $addon->getConfig('synchronize_yformemails') == true\n ) {\n $addon->setConfig('synchronize', true);\n\n // Set developer synchronizing actions according to theme settings\n if ($addon->getConfig('synchronize_templates')) {\n rex_addon::get('developer')->setConfig('templates', true);\n }\n if ($addon->getConfig('synchronize_modules')) {\n rex_addon::get('developer')->setConfig('modules', true);\n }\n if ($addon->getConfig('synchronize_actions')) {\n rex_addon::get('developer')->setConfig('actions', true);\n }\n if ($addon->getConfig('synchronize_yformemails')) {\n rex_addon::get('developer')->setConfig('yform_email', true);\n }\n }\n\n $addon->removeConfig('synchronize_actions');\n $addon->removeConfig('synchronize_modules');\n $addon->removeConfig('synchronize_templates');\n $addon->removeConfig('synchronize_yformemails');\n }\n }", "protected function _initConfig()\n {\n parent::_initConfig();\n $this->_mergeConfig(array(\n 'get_descriptions' => false, // true to get descriptions for text sections\n ));\n }", "public function apply_config() {\n\t\tforeach ( $this->config as $dependency ) {\n\t\t\tif ( false == ( $download_link = $this->installer->get_download_link( $dependency ) ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$this->config[ $dependency['slug'] ]['download_link'] = $download_link;\n\t\t}\n\t}", "static protected function mergeConfig($config)\r\n {\r\n $config['all']['stylesheets'] = array_merge(isset($config['default']['stylesheets']) && is_array($config['default']['stylesheets']) ? $config['default']['stylesheets'] : array(), isset($config['all']['stylesheets']) && is_array($config['all']['stylesheets']) ? $config['all']['stylesheets'] : array());\r\n unset($config['default']['stylesheets']);\r\n\r\n $config['all']['javascripts'] = array_merge(isset($config['default']['javascripts']) && is_array($config['default']['javascripts']) ? $config['default']['javascripts'] : array(), isset($config['all']['javascripts']) && is_array($config['all']['javascripts']) ? $config['all']['javascripts'] : array());\r\n unset($config['default']['javascripts']);\r\n\r\n $config['all']['metas']['title'] = array_merge(\r\n isset($config['default']['metas']['title']) && is_array($config['default']['metas']['title']) ? $config['default']['metas']['title'] \r\n : (isset($config['default']['metas']['title']) ? array($config['default']['metas']['title']) : array()), \r\n isset($config['all']['metas']['title']) && is_array($config['all']['metas']['title']) ? $config['all']['metas']['title'] \r\n : (isset($config['all']['metas']['title']) ? array($config['all']['metas']['title']) : array())\r\n );\r\n unset($config['default']['metas']['title']);\r\n \r\n // merge default and all\r\n $config['all'] = sfToolkit::arrayDeepMerge(\r\n isset($config['default']) && is_array($config['default']) ? $config['default'] : array(),\r\n isset($config['all']) && is_array($config['all']) ? $config['all'] : array()\r\n );\r\n unset($config['default']);\r\n return self::replaceConstants($config);\r\n }", "protected function registerConfigurations()\n {\n $this->mergeConfigFrom($this->packagePath('config/tarpit.php'), 'tarpit');\n $this->publishes([$this->packagePath('config/config.php') => config_path('tarpit.php')], 'tarpit');\n }", "protected function mergeConfig()\n {\n $this->mergeConfigFrom(\n __DIR__ . '/Config/teamrole.php', 'teamrole'\n );\n }", "protected function publishConfigurationFile()\n {\n // Determine the Local Configuration Path\n $source = $this->getLocalConfigurationPath();\n\n // Determine the Application Configuration Path\n $destination = $this->getApplicationConfigPath();\n\n // Publish the Configuration File\n $this->publishes([$source => $destination], 'config');\n }", "protected function exportConfig()\n {\n if ($this->option('interactive')) {\n if (! $this->confirm('Install the package config file?')) {\n return;\n }\n }\n if (file_exists(config_path('laravel-mentor.php')) && ! $this->option('force')) {\n if (! $this->confirm('The Laravel Mentor configuration file already exists. Do you want to replace it?')) {\n return;\n }\n }\n copy(\n $this->packagePath('config/laravel-mentor.php'),\n config_path('laravel-mentor.php')\n );\n\n $this->comment('Configuration Files installed successfully.');\n }", "protected function registerConfigPublisher()\n {\n $this->app->singleton('config.publisher', function ($app) {\n $path = $app->make('path.config');\n\n $publisher = new ConfigPublisher($app->make('files'), $path);\n\n $publisher->setPackagePath($app->make('path.base') . '/src');\n\n return $publisher;\n });\n }", "function conditional_config($config_key) {\n\tif(!chevereto_config($config_key)) {\n\t\treturn false;\n\t} else {\n\t\treturn true;\n\t}\n}", "public function defaultConfig();", "protected function addConfiguration()\n {\n $this['config'] = $this->share(\n function () {\n $user_config_file = (file_exists('phpdoc.xml'))\n ? 'phpdoc.xml'\n : 'phpdoc.dist.xml';\n\n return \\Zend\\Config\\Factory::fromFiles(\n array(\n __DIR__.'/../../data/phpdoc.tpl.xml',\n $user_config_file\n ), true\n );\n }\n );\n }", "protected function configure()\n {\n $this->publishes([\n __DIR__ . '/../config/laravel-calendar.php' => config_path('laravel-calendar.php'),\n ], 'config');\n\n $this->mergeConfigFrom(\n __DIR__ . '/../config/laravel-calendar.php',\n 'laravel-calender'\n );\n }", "private function publishesConfig(): void\n {\n $this->publishes([\n __DIR__.'/../config/invite-codes.php' => config_path('invite-codes.php'),\n ], 'invite-codes-config');\n }", "function instance_allow_config() {\n\n return false;\n }", "protected function mergeConfiguration()\n {\n $this->mergeConfigFrom(\n __DIR__.'/../config/firefly.php', 'firefly'\n );\n }", "protected function registerConfigurations()\n {\n $this->mergeConfigFrom(\n $this->packagePath('config/config.php'), 'password'\n );\n $this->publishes([\n $this->packagePath('config/config.php') => config_path('password.php'),\n ], 'config');\n }", "function instance_allow_config()\r\n\t\t{\r\n\t\t\r\n\t\t}", "protected function prepareResources()\n {\n // Publish config\n $config = realpath(__DIR__.'/../config/config.php');\n\n $this->mergeConfigFrom($config, 'cartalyst.extensions');\n\n $this->publishes([\n $config => config_path('cartalyst.extensions.php'),\n ], 'config');\n }", "public function instance_allow_config() {\n return false;\n }", "protected function getConfigContainer2Extra()\n {\n }", "protected function registerConfigurations()\n {\n $this->mergeConfigFrom(\n $this->packagePath('config/laravel-deploy-helper.php'), 'laravel-deploy-helper'\n );\n $this->publishes([\n $this->packagePath('config/laravel-deploy-helper.php') => config_path('laravel-deploy-helper.php'),\n ], 'ldh-config');\n }", "protected function updateConfig() {\n $config_factory = \\Drupal::configFactory();\n $settings = $config_factory->getEditable('message_subscribe.settings');\n $settings->set('use_queue', TRUE);\n $settings->save(TRUE);\n\n $settings = $config_factory->getEditable('mailsystem.settings');\n $settings->set('defaults', [\n 'sender' => 'swiftmailer',\n 'formatter' => 'swiftmailer',\n ]);\n $settings->set('modules', [\n 'swiftmailer' => [\n 'none' => [\n 'formatter' => 'swiftmailer',\n 'sender' => 'swiftmailer',\n ],\n ],\n 'message_notify' => [\n 'none' => [\n 'formatter' => 'swiftmailer',\n 'sender' => 'swiftmailer',\n ],\n ],\n ]);\n $settings->save(TRUE);\n\n $settings = $config_factory->getEditable('swiftmailer.message');\n $settings->set('format', 'text/html');\n $settings->set('respect_format', FALSE);\n $settings->save(TRUE);\n\n $settings = $config_factory->getEditable('flag.flag.subscribe_node');\n $settings->set('status', TRUE);\n $settings->save(TRUE);\n\n $settings = $config_factory->getEditable('user.role.authenticated');\n $permissions = $settings->get('permissions');\n foreach ([\n 'flag subscribe_node',\n 'unflag subscribe_node',\n ] as $perm) {\n if (!in_array($perm, $permissions)) {\n $permissions[] = $perm;\n }\n }\n $settings->set('permissions', $permissions);\n $settings->save(TRUE);\n\n }", "public function updateConfig()\n {\n $this->aframe_assets_url = $this->composer->getConfig()->get('aframe-url') ?? '/aframe';\n \n $composer_json = $this->getVendorDir() . DIRECTORY_SEPARATOR . 'mkungla' . DIRECTORY_SEPARATOR . 'aframe-php' . DIRECTORY_SEPARATOR . 'composer.json';\n \n if (file_exists($composer_json)) {\n $config = json_decode(file_get_contents($composer_json));\n $config->config->{'aframe-dir'} = $this->getPublicRoot();\n $config->config->{'aframe-url'} = $this->aframe_assets_url;\n $config->version = self::AFRAME_PHP_VERSION;\n file_put_contents($composer_json, json_encode($config, JSON_PRETTY_PRINT));\n }\n }", "public function getConfigDefaults()\n {\n // $file = realpath(__DIR__ . '/../../data/distribution/config.dist.php');\n $file = __DIR__ . '/../../data/distribution/config.dist.php';\n\n return $this->getConfigFromFile($file);\n }", "protected function _setConfig()\n {\n if ($this->_system) {\n $config = $this->_system . DIRECTORY_SEPARATOR . 'config.php';\n } else {\n $config = false;\n }\n\n // manually look for a --config argument that overrides the default\n $found = false;\n foreach ($this->_argv as $val) {\n if ($val == '--config') {\n // found the argument\n $found = true;\n // reset the default in preparation for the next argument\n $config = false;\n continue;\n }\n \n if ($found && substr($val, 0, 1) != '-') {\n $config = $val;\n break;\n }\n \n if (substr($val, 0, 9) == '--config=') {\n $found = true;\n $config = substr($val, 9);\n break;\n }\n }\n \n // if there was a --config but no param, that's a failure\n if ($found && ! $config) {\n echo \"Please specify a config file path after the --config option.\" . PHP_EOL;\n exit(1);\n }\n \n // was there a config file at all?\n if ($config) {\n $realpath = realpath($config);\n if ($realpath) {\n $this->_config = $realpath;\n $text = \"Using config file '$realpath'.\" . PHP_EOL;\n } else {\n echo \"Could not resolve real path to config file '$config'.\" . PHP_EOL;\n exit(1);\n }\n } else {\n $text = \"Not using a config file.\" . PHP_EOL;\n }\n \n if ($this->_verbose) {\n echo $text;\n }\n }", "function instance_allow_config() {\n return true;\n }", "private function setPublishFiles()\n {\n if ($this->app->runningInConsole()) {\n $this->publishes([\n __DIR__.'/../config/config.php' => config_path('setting.php'),\n ], 'setting');\n }\n }", "protected function defaultConfig()\n\t{\n\t\t$this->config=array(\n\t\t\t'code'=>'1',\n\t\t\t'scanning'=>\"\",\n\t\t\t'scanCodes'=>array()\n\t\t);\n\t}", "protected function loadConfigsFromPackage(): void\n {\n $packageConfigs = $this->getConfigsFromPackage();\n foreach ($packageConfigs as $file){\n $filename = pathinfo($file, PATHINFO_FILENAME);\n $this->mergeConfigFrom($file, $filename);\n }\n }", "protected function registerConfigurations()\n {\n $this->mergeConfigFrom(\n $this->packagePath('config/line.php'), 'ferdhika31.linebot'\n );\n $this->publishes([\n $this->packagePath('config/line.php') => config_path('ferdhika31/linebot.php'),\n ], 'config');\n }", "public static function returnExtConfDefaults() {}", "public function hasConfig($package);", "public function getDefaultConfiguration();", "public function getDefaultConfiguration() {}", "protected function addDefaultConfigurationForConfigGeneration() {\n if (!isset($this->configuration['disabled_field_types'])) {\n /** @var \\Drupal\\search_api_solr\\Controller\\AbstractSolrEntityListBuilder $solr_field_type_list_builder */\n $solr_field_type_list_builder = $this->entityTypeManager->getListBuilder('solr_field_type');\n $this->configuration['disabled_field_types'] = array_keys($solr_field_type_list_builder->getAllNotRecommendedEntities());\n }\n\n if (!isset($this->configuration['disabled_caches'])) {\n /** @var \\Drupal\\search_api_solr\\Controller\\AbstractSolrEntityListBuilder $solr_cache_list_builder */\n $solr_cache_list_builder = $this->entityTypeManager->getListBuilder('solr_cache');\n $this->configuration['disabled_caches'] = array_keys($solr_cache_list_builder->getAllNotRecommendedEntities());\n }\n\n if (!isset($this->configuration['disabled_request_handlers'])) {\n /** @var \\Drupal\\search_api_solr\\Controller\\AbstractSolrEntityListBuilder $solr_request_handler_list_builder */\n $solr_request_handler_list_builder = $this->entityTypeManager->getListBuilder('solr_request_handler');\n $this->configuration['disabled_request_handlers'] = array_keys($solr_request_handler_list_builder->getAllNotRecommendedEntities());\n }\n\n if (!isset($this->configuration['disabled_request_dispatchers'])) {\n /** @var \\Drupal\\search_api_solr\\Controller\\AbstractSolrEntityListBuilder $solr_request_dispatcher_list_builder */\n $solr_request_dispatcher_list_builder = $this->entityTypeManager->getListBuilder('solr_request_dispatcher');\n $this->configuration['disabled_request_dispatchers'] = array_keys($solr_request_dispatcher_list_builder->getAllNotRecommendedEntities());\n }\n }", "protected function loadConfiguration()\n {\n $configPath = __DIR__ . '/../../fixture/config/twigbridge.php';\n if (!$this->isLumen()) {\n $this->publishes([$configPath => config_path('twigbridge.php')], 'config');\n }\n $this->mergeConfigFrom($configPath, 'twigbridge');\n }", "function has_config() {\n return true;\n }", "public function has_config() {\n return false;\n }", "public function has_config() {\n return false;\n }", "abstract public function getConfig();", "protected function setup_config() {\n\t\t\t// TODO: Implement setup_config() method.\n\t\t}", "private function __init_config() {\n if (empty($this->config[\"dnshaper\"][\"queue\"][$this->id][\"queue\"])) {\n $this->config[\"dnshaper\"][\"queue\"][$this->id][\"queue\"] = [];\n }\n # Check if there is no dnshaper queue array in the config\n if (empty($this->config[\"dnshaper\"][\"queue\"][$this->id][\"queue\"][\"item\"])) {\n $this->config[\"dnshaper\"][\"queue\"][$this->id][\"queue\"][\"item\"] = [];\n }\n }", "public function merge(Config $other) {\n\t\t/* merge variables */\n\t\tforeach($other->getVars() as $key => $value) {\n\t\t\t$this->vars[ $key ] = $value;\n\t\t}\n\t\t/* merge templates */\n\t\tforeach($other->getTemplates() as $one) {\n\t\t\t$this->templates[] = $one;\n\t\t}\n\t}", "protected function loadConfiguration()\n {\n $config_path = __DIR__ . '/../../config/tintin.php';\n\n if (!$this->isLumen()) {\n $this->publishes([\n $config_path => config_path('view.php')\n ], 'config');\n }\n\n $this->mergeConfigFrom($config_path, 'view');\n }", "public function applyConfigDefaults(array $config)\n {\n $defaults = array(\n 'arch' => 'all',\n 'buildId' => gmdate(self::DEFAULT_BUILDTIME_FORMAT),\n 'description' => '',\n 'depends' => array(),\n 'exclude' => array(),\n 'maintainer' => '',\n 'postinst' => '',\n 'priority' => 'optional',\n 'sources' => array(),\n 'workspaceBasedir' => self::DEFAULT_WORKSPACE_BASEDIR\n );\n $config = array_merge($defaults, $config);\n\n if ($config['postinst']) {\n $config['postinst'] = rtrim($config['postinst']) . \"\\n\";\n }\n $config['sources'] = array();\n\n $config['fullName'] = sprintf(\n '%s_%s_%s',\n $config['shortName'], $config['version'], $config['arch']\n );\n $config['versionDir'] = sprintf(\n '%s/%s/%s',\n $config['workspaceBasedir'], $config['shortName'], $config['version']\n );\n $config['buildDir'] = \"{$config['versionDir']}/\" . $config['buildId'];\n $config['pkgDir'] = \"{$config['buildDir']}/{$config['fullName']}\";\n\n return $config;\n }", "private function initConfig()\n {\n return $this->config = [\n 'api' => 'https://api.gfycat.com/v1',\n ];\n }", "static function set_config() {\n\t\tif ( file_exists( self::childpath() . 'config/wpgrade-config' . EXT ) ) {\n\t\t\tself::$configuration = include self::childpath() . 'config/wpgrade-config' . EXT;\n\t\t} elseif ( file_exists( self::themepath() . 'config/wpgrade-config' . EXT ) ) {\n\t\t\tself::$configuration = include self::themepath() . 'config/wpgrade-config' . EXT;\n\t\t} elseif ( file_exists( self::childpath() . 'wpgrade-config' . EXT ) ) {\n\t\t\tself::$configuration = include self::childpath() . 'wpgrade-config' . EXT;\n\t\t} elseif ( file_exists( self::themepath() . 'wpgrade-config' . EXT ) ) {\n\t\t\tself::$configuration = include self::themepath() . 'wpgrade-config' . EXT;\n\t\t}\n\t}", "private function init_config() {\n set_config('siteadmins', '');\n set_config('siteguest', '');\n set_config('defaultuserroleid', '');\n set_config('defaultfrontpageroleid', '');\n }", "protected function configure(): void\n {\n $this->mergeConfigFrom(\n __DIR__ . '/config/permissions_makr.php', 'permissions_makr'\n );\n }", "function plugin_initconfig_repository()\n{\n global $_CONF;\n\n $c = config::get_instance();\n if (!$c->group_exists('repository')) {\n $c->add('sg_main', NULL, 'subgroup', 0, 0, NULL, 0, true, 'repository');\n $c->add('fs_main', NULL, 'fieldset', 0, 0, NULL, 0, true, 'repository');\n $c->add('repository_moderated', 1,\n 'select', 0, 0, 0, 10, true, 'repository');\n $c->add('max_pluginpatch_upload', 2000000, \n 'text', 0, 0, 0, 60, true, 'repository'); // 2 MB\n }\n\n return true;\n}", "abstract protected function getConfig();", "protected function mergeIntoConfig($config) {\n\t\tparent::mergeIntoConfig($config);\n\t\tif ($this->config['deletion_strategy'] == '') {\n\t\t\tthrow new Exception('Can not generate: must specify the deletion_strategy config setting (Delete|Retire|Custom).');\n\t\t}\n\t}", "public function hasConfig();", "public function initConfig() {\r\n\t$config = array();\r\n\tinclude($this->name . '/config.php');\r\n\t\\app::$config = array_merge(\\app::$config, $config);\r\n }", "function expungePackageConfig( $pPackageName ) {\n\t\tif( !empty( $pPackageName ) ) {\n\t\t\t$query = \"DELETE FROM `\".BIT_DB_PREFIX.\"kernel_config` WHERE `package`=?\";\n\t\t\t$result = $this->mDb->query( $query, array( strtolower( $pPackageName ) ) );\n\t\t\t// let's force a reload of the prefs\n\t\t\tunset( $this->mConfig );\n\t\t\t$this->loadConfig();\n\t\t}\n\t}", "public function instance_allow_config() {\n return true;\n }", "public function config(Config $config = null);", "function initCustomConfig() {\n\t\tglobal $db;\n\t\t\n\t\t// Use the existing PunBB database connection:\n\t\t$this->setConfig('dbConnection', 'link', $db->link_id);\n\t}", "private function registerConfiguration()\n {\n $configPath = __DIR__ . '/../config/themify.php';\n $this->mergeConfigFrom($configPath, 'themify');\n $this->publishes([$configPath => config_path('themify.php')]);\n }", "private function registerPublishing(): void\n {\n if ($this->app->runningInConsole()) {\n $this->publishes([\n __DIR__ . '/../config/ethereum.php' => config_path('ethereum.php'),\n ], 'ethereum-config');\n }\n }", "public function setupConfig()\n {\n registry::getInstance()->set('config', $this->parseConfig());\n }", "public function writewebconfig()\n {\n //<add fileExtension=\"supersake\" allowed=\"false\"/>\n }", "function buildShowConfig(): void\n {\n // No default implementation\n }", "protected function configurePublishing()\n {\n if ($this->app->runningInConsole()) {\n $this->publishes([\n __DIR__.'/../stubs/fortify.php' => config_path('fortify.php'),\n ], 'fortify-config');\n\n $this->publishes([\n __DIR__.'/../stubs/CreateNewUser.php' => app_path('Actions/Fortify/CreateNewUser.php'),\n __DIR__.'/../stubs/FortifyServiceProvider.php' => app_path('Providers/FortifyServiceProvider.php'),\n __DIR__.'/../stubs/PasswordValidationRules.php' => app_path('Actions/Fortify/PasswordValidationRules.php'),\n __DIR__.'/../stubs/ResetUserPassword.php' => app_path('Actions/Fortify/ResetUserPassword.php'),\n __DIR__.'/../stubs/UpdateUserProfileInformation.php' => app_path('Actions/Fortify/UpdateUserProfileInformation.php'),\n __DIR__.'/../stubs/UpdateUserPassword.php' => app_path('Actions/Fortify/UpdateUserPassword.php'),\n ], 'fortify-support');\n\n $this->publishes([\n __DIR__.'/../database/migrations' => database_path('migrations'),\n ], 'fortify-migrations');\n }\n }", "public function fileclerk__config_dump()\n\t{\n\t\t$destination = Request::get('destination');\n\t\tdd($this->tasks->merge_configs($destination));\n\t}", "protected static function _initConfig($name, $config) {\n\t\t$defaults = ['priority' => true];\n\t\treturn parent::_initConfig($name, $config) + $defaults;\n\t}", "private function initialiseConfig()\n {\n $this->mergeConfigFrom(__DIR__ . '/..' . Settings::LARAVEL_REAL_CONFIG, Settings::LARAVEL_CONFIG_NAME);\n }", "protected function initConfig()\n {\n $this->config = [];\n }", "public function specialization() {\n if ($this->config === null) {\n $this->config = new stdClass();\n }\n // Set always show_dedication config settings to avoid errors.\n if (!isset($this->config->show_dedication)) {\n $this->config->show_dedication = 0;\n }\n }", "protected function offerPublishing()\n {\n if ($this->app->runningInConsole()) {\n $this->publishes([\n __DIR__ . '/../config/documentation.php' => config_path('documentation.php'),\n ], 'documentation-config');\n }\n }", "protected function initConfiguration(){\n $settings = array(\n 'user' => 'bitshok',\n 'widget_id' => '355763562850942976',\n 'tweets_limit' => 3,\n 'follow_btn' => 'on'\n );\n Configuration::updateValue($this->name.'_settings', serialize($settings));\n }", "public function boot()\n {\n $configPath = __DIR__ . '/../config/' . $this->configName . '.php';\n\n $this->publishes([$configPath => config_path($this->configName . '.php')], 'impersonate');\n }", "public function loadZkConfig()\n {\n $config = $this->getCacheConfig();\n if (empty($config)) {\n $config = $this->cacheConfig();\n }\n if ($config) {\n $config->replaceLaravelConfig($this->options['mode']);\n }\n }", "private function copyConfigFile()\n {\n $path = $this->getConfigPath();\n\n // if generatords config already exist\n if ($this->files->exists($path) && $this->option('force') === false) {\n $this->error(\"{$path} already exists! Run 'generate:publish-stubs --force' to override the config file.\");\n die;\n }\n\n File::copy(__DIR__ . '/../config/config.php', $path);\n }", "protected function addToConfig()\n {\n $path = $this->getConfigPath();\n $config = require($path);\n if (isset($config[$this->moduleId])) {\n if (\\Yii::$app->controller->confirm('Rewrite exist config?')) {\n $config[$this->moduleId] = $this->getConfigArray();\n echo 'Module config was rewrote' . PHP_EOL;\n }\n } else {\n $config[$this->moduleId] = $this->getConfigArray();\n }\n\n\n $this->writeArrayToFile($this->getConfigPath(), $config);\n }", "protected function loadConfigsForRegister(): void\n {\n $shipConfigs = $this->getConfigsFromShip();\n $containersConfigs = $this->getConfigsFromContainers();\n\n $configs = array_merge($shipConfigs, $containersConfigs);\n\n foreach ($configs as $file){\n $filename = pathinfo($file, PATHINFO_FILENAME);\n $this->mergeConfigFrom($file, $filename);\n }\n }", "public function getConfig($package);", "private function reconfigure() {\n\t\t$global = JConfig::getInstance();\n\t\tforeach ($global as $key => $value) {\n\t\t\tif (array_key_exists($key, $this->config)) {\n\t\t\t\t$this->config[$key] = $value;\n\t\t\t}\n\t\t}\n\t\ttry {\n\t\t\tif (class_exists('JPConfig')) {\n\t\t\t\t$this->config = array_merge($this->config, JPConfig::getData());\n\t\t\t}\n\t\t} catch (Exception $e) {\n\t\t\t// class JPConfig doesn't exist\n\t\t}\n\t}", "protected function resolveApplicationConfiguration($app)\n {\n parent::resolveApplicationConfiguration($app);\n\n $configs = [\n 'assets', 'cp', 'forms', 'routes', 'static_caching',\n 'sites', 'stache', 'system', 'users',\n ];\n\n foreach ($configs as $config) {\n $app['config']->set(\"statamic.$config\", require(__DIR__ . \"/../vendor/statamic/cms/config/{$config}.php\"));\n }\n\n // Setting the user repository to the default flat file system\n $app['config']->set('statamic.users.repository', 'file');\n\n // Assume the pro edition within tests\n $app['config']->set('statamic.editions.pro', true);\n\n Statamic::pushCpRoutes(function () {\n return require_once realpath(__DIR__ . '/../routes/cp.php');\n });\n\n Statamic::pushWebRoutes(function () {\n return require_once realpath(__DIR__ . '/../routes/web.php');\n });\n\n // Define butik config settings for all of our tests\n $app['config']->set(\"butik\", require(__DIR__ . \"/../config/config.php\"));\n\n // Set all layouts to null to prevent an error thrown from a layout which could not be found.\n $layouts = [\n 'layout_product-index',\n 'layout_product-category',\n 'layout_product-show',\n 'layout_cart',\n 'layout_checkout-delivery',\n 'layout_checkout-payment',\n 'layout_checkout-receipt',\n 'layout_checkout-receipt-invalid',\n ];\n\n foreach($layouts as $layout) {\n $app['config']->set('butik.' . $layout, null);\n }\n }", "function configure_propack() {\n global $quotepress_plugin;\n $quotepress_plugin->propack_enabled = true;\n }", "public function writeConfig() {\n $mergedTemplate = $this->mergeTemplate();\n file_put_contents(\"{$this->settings['paths']['hostConfigDir']}/{$this->params['name']}.cfg\", $mergedTemplate);\n file_put_contents(\"{$this->settings['paths']['hostTrackDir']}/{$this->params['type']}.inf\", \"{$this->params['name']}:{$this->params['instanceId']}\" . PHP_EOL, FILE_APPEND);\n $this->logChange();\n }" ]
[ "0.61094695", "0.60274494", "0.6017864", "0.59659356", "0.58404577", "0.5834162", "0.5826338", "0.58175045", "0.5806708", "0.57638204", "0.57378227", "0.5734405", "0.57080424", "0.5672454", "0.56511873", "0.56383306", "0.56295055", "0.56264156", "0.5611503", "0.5582038", "0.557343", "0.5544039", "0.5543076", "0.5478457", "0.54776126", "0.5463851", "0.5441513", "0.5426957", "0.5354776", "0.53491485", "0.53370374", "0.5328613", "0.53271306", "0.53156656", "0.5313499", "0.52662313", "0.52640307", "0.5245761", "0.52279043", "0.5227772", "0.5222608", "0.52208877", "0.52110493", "0.52013403", "0.5160222", "0.5148681", "0.51415616", "0.51387906", "0.513022", "0.51081425", "0.50959975", "0.50749207", "0.5074377", "0.507337", "0.5058862", "0.5051413", "0.50506866", "0.5047715", "0.5047715", "0.5041912", "0.5040723", "0.5036566", "0.5034651", "0.50277734", "0.5025711", "0.50169337", "0.5012456", "0.50120217", "0.5011136", "0.50071603", "0.5004155", "0.50038916", "0.49995312", "0.49972063", "0.49902776", "0.49847192", "0.49824786", "0.49818987", "0.49775657", "0.4975794", "0.49704134", "0.49702814", "0.49658585", "0.49635404", "0.49468344", "0.4945586", "0.49445668", "0.4940963", "0.4936303", "0.49336267", "0.49072418", "0.49065268", "0.48947746", "0.4887357", "0.48829487", "0.4881152", "0.48658696", "0.48607418", "0.48559493", "0.4851917", "0.484232" ]
0.0
-1
Coupons mass delete action
public function execute() { $pool = $this->_initObject(); if (!$pool->getId()) { $this->_forward('noroute'); } $codesIds = $this->getRequest()->getParam('ids'); if (is_array($codesIds)) { $collection = $this->_objectManager->create('Bdcrops\GiftCard\Model\ResourceModel\GiftCard\Collection') ->addFieldToFilter('giftcard_id', ['in' => $codesIds]) ->addFieldToFilter('pool_id', $pool->getId()); foreach ($collection as $giftCard) { $giftCard->delete(); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function massDeleteAction() {\n $messageIds = $this->getRequest()->getParam('connector');\n\n if (!is_array($messageIds)) {\n Mage::getSingleton('adminhtml/session')->addError(Mage::helper('adminhtml')->__('Please select item(s)'));\n } else {\n try {\n foreach ($messageIds as $messageId) {\n $notice = Mage::getModel('connector/notice')->load($messageId);\n $notice->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Total of %d record(s) were successfully deleted', count($bannerIds)));\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n }\n }\n $this->_redirect('*/*/index');\n }", "public function actionDelete() {}", "public function actionDelete() {}", "public function deleteAction() {\n \n }", "public function deleteDiscount();", "public function delete() {\n// 'missionServiceUsers' => array(self::HAS_MANY, 'MissionServiceUser', 'id_service_user'),\n// //'serviceUserConditions' => array(self::MANY_MANY, 'Condition', 'tbl_service_user_condition(id_service_user, id_condition)'),\n// 'serviceUserConditions' => array(self::HAS_MANY, 'ServiceUserCondition', 'id_service_user'),\n\n\n parent::delete();\n }", "public function deleteAction()\n {\n \n }", "public function delete(){\n $db = Database::getInstance() ;\n $db->query(\"DELETE FROM canciones WHERE idcancion=:idcan ;\",\n [\":idcan\"=>$this->idcancion]) ;\t\t\t\t \n }", "function delete_all()\n {\n $this->Admin_model->package = 'POSTS_PKG';\n $this->Admin_model->procedure = 'POST_DELETE';\n\n\n /*if ($_SERVER['REQUEST_METHOD'] == 'POST') {*/\n for ($i = 0; $i < count($this->p_delete); $i++) {\n $this->Admin_model->package = 'POSTS_PKG';\n $this->Admin_model->delete($this->p_delete[$i]);\n //Modules::run('admin/Post_Categories/delete', $this->p_delete[$i]);\n }\n\n /* } else {\n redirect('admin/Posts/display_cat');\n }\n redirect('admin/Posts/display_cat');*/\n }", "public function massDeleteAction() {\r\n $siegeIds = $this->getRequest()->getParam('siege');\r\n if(!is_array($siegeIds)) {\r\n Mage::getSingleton('adminhtml/session')->addError(Mage::helper('reseauchx_reservationreseau')->__('Please select sieges to delete.'));\r\n }\r\n else {\r\n try {\r\n foreach ($siegeIds as $siegeId) {\r\n $siege = Mage::getModel('reseauchx_reservationreseau/siege');\r\n $siege->setId($siegeId)->delete();\r\n }\r\n Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('reseauchx_reservationreseau')->__('Total of %d sieges were successfully deleted.', count($siegeIds)));\r\n }\r\n catch (Mage_Core_Exception $e){\r\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\r\n }\r\n catch (Exception $e) {\r\n Mage::getSingleton('adminhtml/session')->addError(Mage::helper('reseauchx_reservationreseau')->__('There was an error deleting sieges.'));\r\n Mage::logException($e);\r\n }\r\n }\r\n $this->_redirect('*/*/index');\r\n }", "protected function _postDelete() {}", "protected function _postDelete() {}", "protected function deleteAction()\n {\n }", "public function action_multi(){\n $ids = Arr::get($_POST, 'operate');\n if(isset($_POST['delete_all']) && count($ids)){\n $count = DB::delete( ORM::factory('BoardAbuse')->table_name() )->where('id', 'IN', $ids)->execute();\n Flash::success(__('All abuses (:count) was successfully deleted', array(':count'=>count($count) )));\n }\n $this->redirect('admin/boardAbuses' . URL::query());\n\n }", "public function undeleteAction(){\n\t}", "public function massDeleteAction()\n {\n $ifeedbackIds = $this->getRequest()->getParam('ifeedback');\n if (!is_array($ifeedbackIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_kst')->__('Please select instructor feedbacks to delete.')\n );\n } else {\n try {\n foreach ($ifeedbackIds as $ifeedbackId) {\n $ifeedback = Mage::getModel('bs_kst/ifeedback');\n $ifeedback->setId($ifeedbackId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_kst')->__('Total of %d instructor feedbacks were successfully deleted.', count($ifeedbackIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_kst')->__('There was an error deleting instructor feedbacks.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function deleteAction() {\n $post_data = $request = $this->getRequest()->getPost();\n\n $mapper = new Application_Model_DistractionMapper();\n $anzDeletedRows = $mapper->delete($post_data['id']);\n\n $this->view->success = ($anzDeletedRows > 0);\n }", "public function massDeleteAction()\n {\n $aircraftIds = $this->getRequest()->getParam('aircraft');\n if (!is_array($aircraftIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_misc')->__('Please select aircraft to delete.')\n );\n } else {\n try {\n foreach ($aircraftIds as $aircraftId) {\n $aircraft = Mage::getModel('bs_misc/aircraft');\n $aircraft->setId($aircraftId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_misc')->__('Total of %d aircraft were successfully deleted.', count($aircraftIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_misc')->__('There was an error deleting aircraft.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function massDeleteAction()\n {\n $handovertwoIds = $this->getRequest()->getParam('handovertwo');\n if (!is_array($handovertwoIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_handover')->__('Please select minutes of handovers v2 to delete.')\n );\n } else {\n try {\n foreach ($handovertwoIds as $handovertwoId) {\n $handovertwo = Mage::getModel('bs_handover/handovertwo');\n $handovertwo->setId($handovertwoId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_handover')->__('Total of %d minutes of handovers v2 were successfully deleted.', count($handovertwoIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_handover')->__('There was an error deleting minutes of handovers v2.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function destroy(Request $request)\n {\n $auth_id=Auth::id();\n if ($request->method=='delete') {\n foreach ($request->ids as $key => $id) {\n $post = Category::where('user_id',$auth_id)->findorFail($id);\n $post->delete();\n }\n }\n\n// return response()->json(['Coupon Deleted']);\n return response()->json([trans('success')]);\n }", "public function clearCoupons(): void\n {\n $this->coupons = collect();\n\n $this->save();\n }", "public function deleting()\n {\n # code...\n }", "public function actionDelete()\n {\n $session = new session();\n $no_register_perkara = $session->get('no_register_perkara');\n $arr= array();\n $id_tahap = $_POST['hapusIndex'][0];\n \n if($id_tahap=='all'){\n $id_tahapx=PdmT14::find()->select(\"no_surat_t14\")->where(['no_register_perkara'=>$no_register_perkara])->asArray()->all();\n foreach ($id_tahapx as $key => $value) {\n $arr[] = $value['no_surat_t12'];\n \n }\n $id_tahap=$arr;\n }else{\n $id_tahap = $_POST['hapusIndex'];\n }\n\n \n\n $count = 0;\n foreach($id_tahap AS $key_delete => $delete){\n try{\n PdmT14::deleteAll(['no_register_perkara' => $no_register_perkara, 'no_surat_t14'=>$delete]);\n }catch (\\yii\\db\\Exception $e) {\n $count++;\n }\n }\n if($count>0){\n Yii::$app->getSession()->setFlash('success', [\n 'type' => 'danger',\n 'duration' => 5000,\n 'icon' => 'fa fa-users',\n 'message' => $count.' Data Tidak Dapat Dihapus Karena Sudah Digunakan Di Persuratan Lainnya',\n 'title' => 'Error',\n 'positonY' => 'top',\n 'positonX' => 'center',\n 'showProgressbar' => true,\n ]);\n return $this->redirect(['index']);\n }\n\n return $this->redirect(['index']);\n }", "public function massDeleteAction()\n {\n $traineecertIds = $this->getRequest()->getParam('traineecert');\n if (!is_array($traineecertIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_traineecert')->__('Please select trainee certificates to delete.')\n );\n } else {\n try {\n foreach ($traineecertIds as $traineecertId) {\n $traineecert = Mage::getModel('bs_traineecert/traineecert');\n $traineecert->setId($traineecertId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_traineecert')->__('Total of %d trainee certificates were successfully deleted.', count($traineecertIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_traineecert')->__('There was an error deleting trainee certificates.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function deletes_category(){\n $ids = $this->input->post('checkone');\n foreach($ids as $id)\n {\n $this->delete_brand_once($id);\n }\n\t\t$this->session->set_flashdata(\"mess\", \"Xóa thành công!\");\n redirect($_SERVER['HTTP_REFERER']);\n }", "public function massDeleteAction()\n {\n $faqIds = $this->getRequest()->getParam('faqs');\n if (!is_array($faqIds)) {\n Mage::getSingleton('adminhtml/session')->addError($this->__('Please select FAQ\\'s.'));\n } else {\n try {\n foreach ($faqIds as $faqId) {\n $faq = Mage::getModel('ecomitizetest/faqs')->load($faqId);\n $faq->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n $this->__('Total of %d record(s) have been deleted.', count($faqIds))\n );\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n }\n }\n\n $this->_redirect('*/*/' . $this->getRequest()->getParam('ret', 'index'));\n }", "public function actionDelete()\n {\n $id_mata_kuliah_tayang = Yii::$app->getRequest()->getQueryParam('jk');\n $id_mahasiswa = Yii::$app->getRequest()->getQueryParam('js');\n\n $mata_kuliah_tayang = MataKuliahTayang::find()\n ->joinWith('refCpmks')\n ->where([MataKuliahTayang::tableName() . '.id' => $id_mata_kuliah_tayang])\n ->all();\n\n $count = count($mata_kuliah_tayang[0]['refCpmks']);\n\n foreach ($mata_kuliah_tayang as $key => $value) {\n foreach ($value['refCpmks'] as $key => $value) {\n $exist = CapaianMahasiswa::findOne(['id_ref_mahasiswa' => $id_mahasiswa, 'id_ref_cpmk' => $value->id]);\n // $exist->status = 0;\n $exist->delete();\n Yii::$app->session->setFlash('erro', [['Delete', 'Data Berhasil Dihapus']]);\n }\n }\n return $this->redirect(['nilai-upload', 'jk' => $id_mata_kuliah_tayang]);\n }", "public function deleteAction()\n {\n }", "public function multiDeleteAction() {\n if ($this->getRequest()->isPost()) {\n $values = $this->getRequest()->getPost();\n foreach ($values as $key => $value) {\n if ($key == 'delete_' . $value) {\n //DELETE OFFERS FROM DATABASE AND SCRIBD\n $offer_id = (int) $value;\n\t\t\t\t\tEngine_Api::_()->sitestoreoffer()->deleteContent($offer_id);\n }\n }\n }\n return $this->_helper->redirector->gotoRoute(array('action' => 'index'));\n }", "public function delete() {\n // Deleting microarticles.\n $microarticles = $this->getMicroarticles();\n if (!empty($microarticles)) {\n foreach ($microarticles as $microarticle) {\n $microarticle->delete();\n }\n }\n\n // Deleting selfservices.\n $selfServices = $this->getSelfservices();\n if (!empty($selfServices)) {\n foreach ($selfServices as $selfService) {\n $selfService->delete();\n }\n }\n\n parent::delete();\n }", "public function actionDeleteMultiple()\n {\n $request = Yii::$app->request;\n Yii::$app->response->format = Response::FORMAT_JSON;\n $js = $request->post('js');\n $jk = $request->post('jk');\n\n $mata_kuliah_tayang = MataKuliahTayang::find()\n ->joinWith('refCpmks')\n ->where([MataKuliahTayang::tableName() . '.id' => $jk])\n ->all();\n // $count = count($mata_kuliah_tayang[0]['refCpmks']);\n\n foreach ($js as $id_mahasiswa) {\n foreach ($mata_kuliah_tayang as $key => $value) {\n foreach ($value['refCpmks'] as $key => $value) {\n CapaianMahasiswa::deleteAll(['id_ref_mahasiswa' => $id_mahasiswa, 'id_ref_cpmk' => $value->id]);\n }\n }\n }\n }", "public function massDestroy(Request $request)\n {\n if (! Gate::allows('Admin_Manage')) {\n return abort(401);\n }\n if ($request->input('ids')) {\n $entries = Company::whereIn('CompanyID', $request->input('ids'))->get();\n\n foreach ($entries as $entry) {\n $entry->delete();\n }\n\n LogActivity::addToLog('Mass Destroy Company'); \n }\n }", "public function massDeleteAction()\n {\n $equipmentIds = $this->getRequest()->getParam('equipment');\n if (!is_array($equipmentIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_logistics')->__('Please select equipments to delete.')\n );\n } else {\n try {\n foreach ($equipmentIds as $equipmentId) {\n $equipment = Mage::getModel('bs_logistics/equipment');\n $equipment->setId($equipmentId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_logistics')->__('Total of %d equipments were successfully deleted.', count($equipmentIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_logistics')->__('There was an error deleting equipments.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "function delete() {\n\t\t$sql = \"DELETE FROM cost_detail\n\t\t\t\tWHERE cd_fr_id=?, cd_seq=?\";\n\t\t$this->ffm->query($sql, array($this->cd_fr_id, $this->cd_seq));\n\t}", "private function actionListDelete() {\n $put_vars = $this->actionListPutConvert();\n $this->loadModel($put_vars['id'])->delete();\n }", "public function actionBatchDelete()\r\n {\r\n if(Yii::app()->request->getIsAjaxRequest())\r\n {\r\n //$ids\r\n if(isset($_GET['ids'])){\r\n //if(isset($_POST['ids'])){\r\n //$ids = $_POST['ids'];\r\n $ids = $_GET['ids'];\r\n \r\n// if (empty($ids)) {\r\n// echo CJSON::encode(array('status' => 'failure', 'msg' => 'you should at least choice one item'));\r\n// die();\r\n// }\r\n $successCount = $failureCount = 0;\r\n foreach ($ids as $id) {\r\n //$model=$this->Delete($id);\r\n $model = $this->loadModel($id);\r\n //actualiza la cantidad disponible\r\n ProductoAlmacen::model()->actualizarCantidadDisponible($model,0); \r\n //actualizando el credito disponible\r\n Cliente::model()->actualizarCreditoDisponible($model,0);\r\n \r\n //actualizar importe, subtotal, impuesto.\r\n //obtiendo venta\r\n $_venta= Venta::model()->findByPk($model->venta_id);\r\n \r\n ($model->delete() == true) ? $successCount++ : $failureCount++;\r\n \r\n //actualizando el total, base imponible e impuesto de la venta\r\n $_total=$model->SumaTotal();\r\n $_bi= Producto::model()->getSubtotal($_total);\r\n $_venta->importe_total=$_total;//$this->SumaTotal()['total'];\r\n $_venta->base_imponible=$_bi; \r\n $_venta->impuesto=$_total-$_bi;\r\n $_venta->save();\r\n \r\n }\r\n \r\n \r\n \r\n// echo CJSON::encode(array('status' => 'success',\r\n// 'data' => array(\r\n// 'successCount' => $successCount,\r\n// 'failureCount' => $failureCount,\r\n// )));\r\n// die();\r\n } \r\n else{\r\n throw new CHttpException(400,'Invalid request. Please do not repeat this request again.');\r\n }\r\n }\r\n }", "public function _delete()\n\t {\n\t \t$this->notifyObservers(__FUNCTION__);\n\t }", "public function actionDelete() {\n// print_r($_POST);\n Comment::model()->findByPk($_POST['id'])->delete();\n echo CJSON::encode(array(\"data\" => 'berhasil'));\n// $this->loadModel($_POST['id'])->delete();\n // if AJAX request (triggered by deletion via dashboard grid view), we should not redirect the browser\n// if (!isset($_GET['ajax']))\n// $this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('dashboard'));\n }", "public function deleteAction()\n {\n if ($this->isConfirmedItem($this->_('Delete %s'))) {\n $model = $this->getModel();\n $deleted = $model->delete();\n\n $this->addMessage(sprintf($this->_('%2$u %1$s deleted'), $this->getTopic($deleted), $deleted), 'success');\n $this->_reroute(array('action' => 'index'), true);\n }\n }", "protected function delete() {\n\t}", "public function deleteConnectionWithEducations(){\n $respondent_id = $this->id;\n $sql = 'DELETE FROM '.Yii::app()->getModule('respondent')->tableRespondentsEducations.' WHERE respondent_id=:respondent';\n $command = Yii::app()->db->createCommand($sql);\n $command->bindParam(\":respondent\", $respondent_id);\n $command->execute();\n //Yii::app()->db->createCommand('DELETE FROM `tbl_users_clients` WHERE users_id=:user')->bindParam(\":user\",$model->id)->execute();\n }", "public function deleteCommission(){\n\t\t$id = $this->input->post('id');\n\n\t\t//get deleted user info\n\t\t$userInfo = singleDbTableRow($id,'commissions');\n\t\t$categoryName = $userInfo->user_id;\n\t\t// add a activity\n\t\tcreate_activity(\"Deleted {$id} commissions\");\n\t\t//Now delete permanently\n\t\t$this->db->where('id', $id)->delete('commissions');\n\t\treturn true;\n\t}", "public function delete()\n {\n if($this->contactable!=null)\n {\n $this->contactable->delete(); \n }else\n {\n parent::delete(); \n } \n }", "public function deleteAction(){\n //farewell brave knight, your cosmo will stay with us forever...\n $this->getDM()->remove($this->getKnight());\n $this->getDM()->flush();\n //go back to home (indexAction) to show the grid of knights\n $this->redirect()->toRoute(\"home\");\n }", "public function deleteAction() {\n parent::deleteAction();\n }", "public function delete($id)\n {\n\t\tif(!hasTask('admin/coupons/delete'))\n\t\t{\n\t\t\treturn view('errors.404');\n\t\t}\n $data = Coupons::find($id);\n if(!count($data))\n {\n Session::flash('message', 'Invalid Coupon Details'); \n return Redirect::to('admin/coupons');\n }\n if(file_exists(base_path().'/public/assets/admin/base/images/coupon/'.$data->coupon_image) && $data->coupon_image != '')\n {\n unlink(base_path().'/public/assets/admin/base/images/coupon/'.$data->coupon_image);\n }\n DB::table('coupon_outlet')->where('coupon_id', '=', $id)->delete();\n $data->delete();\n Session::flash('message', trans('messages.Coupon has been deleted successfully'));\n return Redirect::to('admin/coupons');\n }", "public function actionBulkDelete() {\n\n if (Yii::$app->request->post('selection')) {\n $where = ['id' => Yii::$app->request->post('selection', []), 'sender_id' => Yii::$app->user->identity->id, 'status_del' => $this->modelClass::STATUS_DEL_TRASH];\n $this->modelClass::updateAll(['status_del' => $this->modelClass::STATUS_DEL_DELETE, 'deleted_at' => time()], $where);\n\n $whereVia = ['mailbox_id' => Yii::$app->request->post('selection', []), 'receiver_id' => Yii::$app->user->identity->id, 'status_del' => $this->modelClass::STATUS_DEL_TRASH];\n $this->modelViaClass::updateAll(['status_del' => $this->modelClass::STATUS_DEL_DELETE, 'deleted_at' => time()], $whereVia);\n }\n }", "public function massDeleteAction()\r\n\t{\r\n\t\tif($eventIds = $this->getRequest()->getParam('event_ids')){\r\n\t\t\ttry{\r\n\t\t\t\tforeach ($eventIds as $eventId) {\r\n\t\t\t\t\t$eventModel = Mage::getModel('master_example/event')->load($eventId);\r\n\t\t\t\t\t$eventModel->delete();\r\n\t\t\t\t}\r\n\t\t\t\tMage::getSingleton('adminhtml/session')->addSuccess($this->__(\"your events(%d) have been deleted\", count($eventIds)));\r\n\t\t\t} catch(Exception $e){\r\n\t\t\t\tMage::getSingleton('adminhtml/session')->addError($e->getMessage());\r\n\t\t\t}\r\n\t\t} else{\r\n\t\t\tMage::getSingleton('adminhtml/session')->addError('select some events');\r\n\t\t}\r\n\t\t$this->_redirect('*/*/index');\r\n\t}", "public function actionBulkDelete()\n {\n $request = Yii::$app->request;\n \n $pks = explode(',', $request->post('pks')); \n \n foreach ($pks as $key) \n {\n \n $model=$this->findModel($key);\n $model->delete();\n } \n\n if($request->isAjax){\n /*\n * Process for ajax request\n */\n Yii::$app->response->format = Response::FORMAT_JSON;\n return ['forceClose'=>true,'forceReload'=>'true']; \n }\n else\n {\n /*\n * Process for non-ajax request\n */\n return $this->redirect(['accion_centralizada_variables/index']);\n }\n \n }", "public function massDestroy(Request $request)\n {\n if (! Gate::allows('payment_gateway_delete')) {\n return prepareBlockUserMessage();\n }\n if ($request->input('ids')) {\n $entries = PaymentGateway::whereIn('id', $request->input('ids'))->get();\n\n foreach ($entries as $entry) {\n $entry->delete();\n }\n\n flashMessage( 'success', 'deletes' );\n }\n }", "public function deleteAction()\n {\n $this->deleteParameters = $this->deleteParameters + $this->_deleteExtraParameters;\n\n parent::deleteAction();\n }", "function delete()\n {\n $GLOBALS['DB']->exec(\"DELETE FROM stores WHERE id = {$this->getId()};\");\n $GLOBALS['DB']->exec(\"DELETE FROM stores_brands WHERE store_id = {$this->getId()};\");\n }", "public function delete() {\r\n\r\n if ( ! current_user_can( 'activate_plugins' ) ) {\r\n return;\r\n }\r\n\r\n $this->deleteOrdersTable();\r\n delete_option( 'ce_option' );\r\n delete_option( 'ce_coins_alerts' );\r\n delete_transient( 'ce_flush_rules' );\r\n flush_rewrite_rules();\r\n\r\n }", "public function deleteAction() {\n\t\t$this->_notImplemented();\n\t}", "public function actionDelete(){\n $session = new session();\n $no_eksekusi = $session->get('no_eksekusi');\n $id = $_POST['hapusIndex'];\n\n if(count($id)>1){\n for ($i = 0; $i < count($id); $i++) {\n PdmD1::deleteAll(['no_surat' => $id[$i]]);\n }\n }else{\n PdmD1::deleteAll(['no_eksekusi'=>$no_eksekusi]);\n }\n return $this->redirect(['index']);\n }", "public function admin_delete($id)\r\n\t{\r\n\t\tif ($this->Coupon->delete($id))\r\n\t\t{\r\n\t\t\t$this->Session->setFlash('Record deleted.', 'default', array('class' => 'success'));\r\n\t\t\t$this->redirect('/admin/coupons');\r\n\t\t}\r\n\t\t\r\n\t\t$this->Session->setFlash('Record not deleted.', 'default', array('class' => 'failure'));\r\n\t\t$this->redirect('/admin/coupons/edit/' . $id);\t\r\n\t\t\r\n\t}", "public function delete() {\r\n }", "public function process_bulk_action() {\n\n\t\tif ( 'delete' === $this->current_action() ) {\n\n\t\t\t// In our file that handles the request, verify the nonce.\n\t\t\t$nonce = esc_attr( $_REQUEST['_wpnonce'] );\n\t\t\t\n\t\t\tif ( ! wp_verify_nonce( $nonce, 'sp_delete_customer' ) ) {\n\t\t\t\t// die( 'Go get a life script kiddies' );\n\t\t\t\t// require dirname(__FILE__).\"/functions/delete_site.php\";\n\t\t\t\techo(\"Deleted Successfully!\");\n\t\t\t}\n\t\t\telse {\n\t\t\t\tself::delete_customer( absint( $_GET['customer'] ) );\n\t\t\t\tob_clean();\n\t\t\t\twp_redirect(esc_url(add_query_arg()));\n\t\t\t\texit();\n\t\t\t}\n\n\t\t}\n\n\t\t// If the delete bulk action is triggered\n\t\tif ( ( isset( $_POST['action'] ) && $_POST['action'] == 'bulk-delete' )\n\t\t || ( isset( $_POST['action2'] ) && $_POST['action2'] == 'bulk-delete' )\n\t\t) {\n\n\t\t\t$delete_ids = esc_sql( $_POST['bulk-delete'] );\n\n\t\t\t// loop over the array of record IDs and delete them\n\t\t\tforeach ( $delete_ids as $id ) {\n\t\t\t\tself::delete_customer( $id );\n\n\t\t\t}\n\n\t\t\twp_redirect( esc_url( add_query_arg() ) );\n\t\t\texit;\n\t\t}\n\t}", "public function delete(){\n }", "public function delete() {}", "public function delete() {}", "public function delete() {}", "public function delete() {}", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function delete();", "public function DeleteAction()\n {\n\n \t//Supprime le mouvement\n \t$sm_id = $this->getRequest()->getParam('sm_id');\n \t$sm = mage::getModel('Purchase/StockMovement')->load($sm_id);\n \t$product_id = $sm->getsm_product_id();\n \t$sm->delete();\n \t\t\n \t//Met a jour le stock du produit\n \tmage::getModel('Purchase/StockMovement')->ComputeProductStock($product_id);\n \t\n \t//Redirige sur la fiche produit\n \t$this->_redirect('Purchase/Products/Edit/product_id/'.$product_id);\n \t\n }", "public function massDeleteAction()\n {\n $coursedocIds = $this->getRequest()->getParam('coursedoc');\n if (!is_array($coursedocIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_coursedoc')->__('Please select course docs to delete.')\n );\n } else {\n try {\n foreach ($coursedocIds as $coursedocId) {\n $coursedoc = Mage::getModel('bs_coursedoc/coursedoc');\n $coursedoc->setId($coursedocId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_coursedoc')->__('Total of %d course docs were successfully deleted.', count($coursedocIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_coursedoc')->__('There was an error deleting course docs.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function massDeleteAction()\n {\n $offerIds = $this->getRequest()->getParam('offer');\n if (!is_array($offerIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('mfb_myflyingbox')->__('Please select offers to delete.')\n );\n } else {\n try {\n foreach ($offerIds as $offerId) {\n $offer = Mage::getModel('mfb_myflyingbox/offer');\n $offer->setId($offerId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('mfb_myflyingbox')->__('Total of %d offers were successfully deleted.', count($offerIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('mfb_myflyingbox')->__('There was an error deleting offers.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "function deleteItemFromDB()\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $result = $_POST['itemInfo'];\n echo $this->coupon_model->delete($result);\n }\n }", "function before_delete() {}", "public function actionDelete()\n {\n $ids = Yii::$app->request->post('ids');\n if ($ids == null) {\n return new ApiResponse(ApiCode::CODE_ERROR,\"失败\");\n }\n $ids2 = explode(\",\",$ids);\n foreach ( $ids2 as $id) {\n CommodityCategory::deleteAll(['id' => $id]);\n CommodityCategory::deleteAll(['pid' => $id]);\n }\n return new ApiResponse();\n }", "public function massDeleteAction()\n {\n $kstitemIds = $this->getRequest()->getParam('kstitem');\n if (!is_array($kstitemIds)) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_kst')->__('Please select items to delete.')\n );\n } else {\n try {\n foreach ($kstitemIds as $kstitemId) {\n $kstitem = Mage::getModel('bs_kst/kstitem');\n $kstitem->setId($kstitemId)->delete();\n }\n Mage::getSingleton('adminhtml/session')->addSuccess(\n Mage::helper('bs_kst')->__('Total of %d items were successfully deleted.', count($kstitemIds))\n );\n } catch (Mage_Core_Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError($e->getMessage());\n } catch (Exception $e) {\n Mage::getSingleton('adminhtml/session')->addError(\n Mage::helper('bs_kst')->__('There was an error deleting items.')\n );\n Mage::logException($e);\n }\n }\n $this->_redirect('*/*/index');\n }", "public function deleteAction() {\n $id = (int) $this->params()->fromRoute('id', 0);\n if (!$id) {\n return $this->redirect()->toRoute('backend-guildes-list');\n }\n $oTable = $this->getTableGuilde();\n $oEntite = $oTable->findRow($id);\n $oTable->delete($oEntite);\n $this->flashMessenger()->addMessage($this->_getServTranslator()->translate(\"La guilde a été supprimée avec succès.\"), 'success');\n return $this->redirect()->toRoute('backend-guildes-list');\n }", "public function multiDeleteMemberAction() {\n\n if ($this->getRequest()->isPost()) {\n\n $values = $this->getRequest()->getPost();\n\n foreach ($values as $key => $value) {\n if ($key == 'delete_' . $value) {\n $sitepageitemofthedays = Engine_Api::_()->getItem('sitepage_itemofthedays', (int) $value);\n if (!empty($sitepageitemofthedays)) {\n $sitepageitemofthedays->delete();\n }\n }\n }\n }\n return $this->_helper->redirector->gotoRoute(array('action' => 'index'));\n }", "public function delete()\n {\n echo '客户要求减少一个需求' . PHP_EOL;\n }", "public function deleteAction(){\n $this->_helper->json(\"Esto no esta implementado\");\n }", "public function massDestroy()\n {\n $menuIds = explode(',', request()->input('indexes'));\n\n foreach ($menuIds as $menuId) {\n $velocityCategory = $this->velocityCategoryRepository->find($menuId);\n\n if (isset($velocityCategory)) {\n $this->velocityCategoryRepository->delete($menuId);\n }\n }\n\n session()->flash('success', trans('velocity::app.admin.category.mass-delete-success'));\n\n return redirect()->route($this->_config['redirect']);\n }", "public function deleteProcuct($productModel) {\n\n }", "public function conclusiones_delete($codcampeonato,$id)\n\t{\n\t\t$category = Reunion::find($id);\n\t\t$category->delete();\n return Redirect::to('/campeonato/detail/'.$codcampeonato);\n\t}", "public function delete() {\n\n }", "public function delete()\n {\n \n }", "public function delete()\n {\n if(($this->session->userdata('logged_in') != true) && ($this->session->userdata('logged_in_as') != 'admin'))\n {\n redirect('siteadmin', 'refresh');\n }\n \n $category_deletion_type = $this->input->post('category_deletion_type');\n \n /* starts to delete multiple categories */\n if ($category_deletion_type == 'multiple') \n {\n $category_id = $this->input->post('category_id');\n $c \t = 0;\n for( $i = 0; $i < count($category_id); $i++ )\n {\n $id = $category_id[$i];\n\n $check_category = $this->common_model->query_single_row_by_single_source('boutique_products', 'category_id', $id);\n if (count($check_category) == 0)\n {\n if( $this->common_model->delete_data('id', $id, 'boutique_categories') )\n $c++;\n }\n }\n if( $c == 0 )\n $this->session->set_flashdata('error_message', 'Could not delete any category!!');\n \n elseif( $c == 1 )\n $this->session->set_flashdata('success_message', 'A category was deleted successfully');\n \n elseif( $c > 1 )\n $this->session->set_flashdata('success_message', 'Multiple categories were deleted successfully');\n }\n /* ends to delete multiple category */\n \n /* starts to delete single category */\n else {\n $id = $this->input->post('single_category_id');\n $check_category = $this->common_model->query_single_row_by_single_source('boutique_products', 'category_id', $id);\n if (count($check_category) == 0)\n {\n if( $this->common_model->delete_data('id', $id, 'boutique_categories') )\n $this->session->set_flashdata('success_message', 'A category was deleted successfully');\n else\n $this->session->set_flashdata('error_message', 'Could not delete!! The category is in used');\n }\n else\n $this->session->set_flashdata('error_message', 'Could not delete the category!!');\n }\n /* ends to delete single category */ \n \n redirect(base_url().'category', 'refresh');\n }", "public function catalogProductMassDeleteAction()\n {\n $productIds = $this->_request->getParam('product');\n $productNotExclusiveIds = [];\n $productExclusiveIds = [];\n\n $productsWebsites = $this->_productFactoryRes->create()->getWebsiteIdsByProductIds($productIds);\n\n foreach ($productsWebsites as $productId => $productWebsiteIds) {\n if (!$this->_role->hasExclusiveAccess($productWebsiteIds)) {\n $productNotExclusiveIds[] = $productId;\n } else {\n $productExclusiveIds[] = $productId;\n }\n }\n\n if (!empty($productNotExclusiveIds)) {\n $productNotExclusiveIds = implode(', ', $productNotExclusiveIds);\n $message = __('More permissions are needed to delete the \"%1\" item.', $productNotExclusiveIds);\n $this->messageManager->addError($message);\n }\n\n $this->_request->setParam('product', $productExclusiveIds);\n }", "public function actionBulkDelete()\n { \n $request = Yii::$app->request;\n $pks = $request->post('pks'); // Array or selected records primary keys\n foreach (AcEspUej::findAll(json_decode($pks)) as $model) {\n $model->delete();\n }\n \n\n if($request->isAjax){\n /*\n * Process for ajax request\n */\n Yii::$app->response->format = Response::FORMAT_JSON;\n return ['forceClose'=>true,'forceReload'=>true]; \n }else{\n /*\n * Process for non-ajax request\n */\n return $this->redirect(['index']);\n }\n \n }", "public function index_delete(){\n\t\t\n\t\t}", "public function after_delete() {}", "public function delete(){\n\t\t$this->feedbacks_model->delete();\n\t}", "public function massDeleteAction()\n {\n $pageIds = $this->getRequest()->getParam('page_id');\n if(!is_array($pageIds)) {\n $this->_getSession()->addError($this->__('Please select page(s).'));\n } else {\n try {\n /** @var Training_Cms_Model_Eav_Page $pages */\n $pages = Mage::getModel('training_cms/eav_page');\n foreach ($pageIds as $pageId) {\n $pages->load($pageId);\n $pages->delete();\n }\n $this->_getSession()->addSuccess($this->__('Total of %d record(s) were deleted.', count($pageIds)));\n } catch (Exception $e) {\n $this->_getSession()->addError($e->getMessage());\n }\n }\n $this->_redirect('*/*/list');\n }" ]
[ "0.690476", "0.67048645", "0.67048645", "0.66174", "0.6605027", "0.65473646", "0.6455453", "0.6454292", "0.6434777", "0.6415248", "0.64131916", "0.64126015", "0.63622016", "0.63615674", "0.6359138", "0.63588357", "0.6326267", "0.63261616", "0.63193774", "0.63149166", "0.62988573", "0.62923497", "0.628105", "0.6271848", "0.625962", "0.62506694", "0.62480897", "0.6242264", "0.62381697", "0.623129", "0.62169045", "0.62163705", "0.6215896", "0.621365", "0.62124735", "0.62113357", "0.6209788", "0.6202091", "0.6198935", "0.6198778", "0.6187604", "0.61822647", "0.61817217", "0.6181232", "0.6168722", "0.6166182", "0.61600584", "0.6159056", "0.61589104", "0.6156214", "0.6147679", "0.6140945", "0.61308545", "0.61270535", "0.61218935", "0.61199343", "0.61193335", "0.6106551", "0.61037683", "0.60961", "0.60961", "0.6095853", "0.60958385", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.6094447", "0.608887", "0.6087202", "0.6086681", "0.6085587", "0.60853094", "0.6084173", "0.6081603", "0.6080904", "0.60805017", "0.6078003", "0.60749114", "0.6071473", "0.6068406", "0.6066955", "0.6063985", "0.6055497", "0.6054841", "0.60497916", "0.60438716", "0.60414755", "0.6033011", "0.6027423", "0.60271335" ]
0.0
-1
Init plugin options to white list our options
function ajb_options_init(){ register_setting( 'ajb_option_group', 'ajb_options', 'ajb_options_validate' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function initOptions()\n {\n }", "function initPlugin()\n {\n $this->getAdminOptions();\n }", "public function options_init() {\n\t\t\tglobal $allowedtags;\n\t\t\t$allowedtags['p'] = array();\n\t\t\t$this->allowedtags = $allowedtags;\n\n\t\t // set options equal to defaults\n\t\t $this->_options = get_option( $this->options_group[0]['options_name'] );\n\t\t if ( false === $this->_options ) {\n\t\t\t\t$this->_options = $this->get_defaults();\n\t\t }\n\t\t if ( isset( $_GET['undo'] ) && !isset( $_GET['settings-updated'] ) && is_array( $this->get_option('previous') ) ) {\n\t\t \t$this->_options = $this->get_option('previous');\n\t\t }\n\t\t update_option( $this->options_group[0]['options_name'], $this->_options );\t\t\n\t\t \n\t\t}", "public function init()\n {\n global $kong_helpdesk_options;\n $this->options = $kong_helpdesk_options;\n }", "protected function initOptions()\n {\n if ($this->kcfinder) {\n $this->registerKCFinder();\n }\n\n $options = [];\n switch ($this->preset) {\n case 'custom':\n $preset = null;\n break;\n case 'basic':\n case 'full':\n case 'standard':\n $preset = 'presets/' . $this->preset . '.php';\n break;\n default:\n $preset = 'presets/standard.php';\n }\n if ($preset !== null) {\n $options = require($preset);\n }\n $this->clientOptions = ArrayHelper::merge($options, $this->clientOptions);\n }", "public function init() {\t\t\n\t\t$this->options = new NHP_Options(\r\n\t\t\tarray(), array(\r\n\t\t\t\t\t'opt_name' => $this->cpt_slug . '-configuration',\r\n\t\t\t\t\t'page_slug' => $this->cpt_slug . '-configuration',\r\n\t\t\t\t\t'menu_title' => __( 'Configuration', WPcpt::$domain ),\r\n\t\t\t\t\t'page_title' => __( 'Configuration', WPcpt::$domain ),\r\n\t\t\t\t\t'page_cap' => 'manage_options',\r\n\t\t\t\t\t'dev_mode' => WP_DEBUG,\r\n\t\t\t\t\t'show_import_export' => false,\r\n\t\t\t\t\t'page_type' => 'submenu',\r\n\t\t\t\t\t'page_parent' => 'edit.php?post_type=' . $this->cpt_slug,\r\n\t\t\t) );\n\t}", "function wassupoptions() {\n\t\t//# initialize class variables with current options \n\t\t//# or with defaults if none\n\t\t$this->loadSettings();\n\t}", "function initialize_options()\n\t\t{\n\t\t\tglobal $config;\n\n\t\t\t$defaults = array(\n\t\t\t\t'minimum_age' => 4,\n\t\t\t\t'maximum_age' => 0,\n\t\t\t);\n\t\t\tforeach ($defaults as $option => $default)\n\t\t\t{\n\t\t\t\tif (!isset($config[$option]))\n\t\t\t\t{\n\t\t\t\t\tset_config($option, $default);\n\t\t\t\t}\n\t\t\t}\n\t\t}", "public static function init()\r\n {\r\n self::$Data = get_option(self::OPT_SETTINGS);\r\n //when the plugin updated, this will be true\r\n if (empty(self::$Data) || empty(self::$Data['version']) || version_compare(DUPLICATOR_VERSION, self::$Data['version'], '>')) {\r\n self::SetDefaults();\r\n }\r\n }", "public function load_options() {\n\t\t$this->disable_hash = get_option( 'health-check-disable-plugin-hash', null );\n\t\t$this->allowed_plugins = get_option( 'health-check-allowed-plugins', array() );\n\t\t$this->default_theme = ( 'yes' === get_option( 'health-check-default-theme', 'yes' ) ? true : false );\n\t\t$this->active_plugins = $this->get_unfiltered_plugin_list();\n\t\t$this->current_theme = get_option( 'health-check-current-theme', false );\n\t}", "function cmh_init(){\r\n\tregister_setting( 'cmh_plugin_options', 'cmh_options', 'cmh_validate_options' );\r\n}", "function TS_VCSC_Set_Plugin_Options() {\r\n\t\t// Redirect Option\r\n\t\tadd_option('ts_vcsc_extend_settings_redirect', \t\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_activation', \t\t\t\t\t\t0);\r\n\t\t// Options for Theme Authors\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypes', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeWidget',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeTeam',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeTestimonial',\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeLogo', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeSkillset',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_additions', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_codeeditors', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_fontimport', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_iconicum', \t\t\t\t \t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_dashboard', \t\t\t\t\t\t1);\r\n\t\t// Options for Custom CSS/JS Editor\r\n\t\tadd_option('ts_vcsc_extend_settings_customCSS',\t\t\t\t\t\t\t'/* Welcome to the Custom CSS Editor! Please add all your Custom CSS here. */');\r\n\t\tadd_option('ts_vcsc_extend_settings_customJS', \t\t\t\t '/* Welcome to the Custom JS Editor! Please add all your Custom JS here. */');\r\n\t\t// Other Options\r\n\t\tadd_option('ts_vcsc_extend_settings_frontendEditor', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_buffering', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_mainmenu', \t\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsDomain', \t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_previewImages',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_visualSelector',\t\t\t\t\t1);\r\n add_option('ts_vcsc_extend_settings_nativeSelector',\t\t\t\t\t1);\r\n add_option('ts_vcsc_extend_settings_nativePaginator',\t\t\t\t\t'200');\r\n\t\tadd_option('ts_vcsc_extend_settings_backendPreview',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_extended', \t\t\t\t 0);\r\n\t\tadd_option('ts_vcsc_extend_settings_systemInfo',\t\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_socialDefaults', \t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_builtinLightbox', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_lightboxIntegration', \t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowAutoUpdate', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowNotification', \t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowDeprecated', \t\t\t\t\t0);\r\n\t\t// Font Active / Inactive\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceMedia',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceIcon',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceAwesome',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceBrankic',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCountricons',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCurrencies',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceElegant',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceEntypo',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceFoundation',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceGenericons',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceIcoMoon',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceMonuments',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceSocialMedia',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceTypicons',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceFontsAll',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Awesome',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Entypo',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Linecons',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_OpenIconic',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Typicons',\t\t\t\t0);\t\t\r\n\t\t// Custom Font Data\r\n\t\tadd_option('ts_vcsc_extend_settings_IconFontSettings',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustom',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomArray',\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomJSON',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomPath',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomPHP', \t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomName',\t\t\t\t\t'Custom User Font');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomAuthor',\t\t\t\t'Custom User');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomCount',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomDate',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomDirectory',\t\t\t'');\r\n\t\t// Row + Column Extensions\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsRows',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsColumns',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsRowEffectsBreak',\t\t\t'600');\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsSmoothScroll',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsSmoothSpeed',\t\t\t\t'30');\r\n\t\t// Custom Post Types\r\n\t\tadd_option('ts_vcsc_extend_settings_customWidgets',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customTeam',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customTestimonial',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_customSkillset',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_customTimelines', \t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customLogo', \t\t\t\t\t\t0);\r\n\t\t// tinyMCE Icon Shortcode Generator\r\n\t\tadd_option('ts_vcsc_extend_settings_useIconGenerator',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_useTinyMCEMedia', \t\t\t\t\t1);\r\n\t\t// Standard Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_StandardElements',\t\t\t\t\t'');\r\n\t\t// Demo Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_DemoElements', \t\t\t\t\t\t'');\r\n\t\t// WooCommerce Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_WooCommerceUse',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_WooCommerceElements',\t\t\t\t'');\r\n\t\t// bbPress Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_bbPressUse',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_bbPressElements',\t\t\t\t\t'');\r\n\t\t// Options for External Files\r\n\t\tadd_option('ts_vcsc_extend_settings_loadForcable',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadLightbox', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadTooltip', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadFonts', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadEnqueue',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadHeader',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadjQuery', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadModernizr',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadWaypoints', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadCountTo', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadMooTools', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadDetector', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadHammerNew', \t\t\t\t\t1);\r\n\t\t// Google Font Manager Settings\r\n\t\tadd_option('ts_vcsc_extend_settings_allowGoogleManager', \t\t\t\t1);\r\n\t\t// Single Page Navigator\r\n\t\tadd_option('ts_vcsc_extend_settings_allowPageNavigator', \t\t\t\t0);\r\n\t\t// EnlighterJS - Syntax Highlighter\r\n\t\tadd_option('ts_vcsc_extend_settings_allowEnlighterJS',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowThemeBuilder',\t\t\t\t\t0);\r\n\t\t// Post Type Menu Positions\r\n\t\t$TS_VCSC_Menu_Positions_Defaults_Init = array(\r\n\t\t\t'ts_widgets'\t\t\t\t\t=> 50,\r\n\t\t\t'ts_timeline'\t\t\t\t\t=> 51,\r\n\t\t\t'ts_team'\t\t\t\t\t\t=> 52,\r\n\t\t\t'ts_testimonials'\t\t\t\t=> 53,\r\n\t\t\t'ts_skillsets'\t\t\t\t\t=> 54,\r\n\t\t\t'ts_logos'\t\t\t\t\t\t=> 55,\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_menuPositions',\t\t\t\t\t\t$TS_VCSC_Menu_Positions_Defaults_Init);\r\n\t\t// Row Toggle Settings\r\n\t\t$TS_VCSC_Row_Toggle_Defaults_Init = array(\r\n\t\t\t'Large Devices' => 1200,\r\n\t\t\t'Medium Devices' => 992,\r\n\t\t\t'Small Devices' => 768,\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_rowVisibilityLimits', \t\t\t\t$TS_VCSC_Row_Toggle_Defaults_Init);\r\n\t\t// Language Settings: Countdown\r\n\t\t$TS_VCSC_Countdown_Language_Defaults_Init = array(\r\n\t\t\t'DayPlural' => 'Days',\r\n\t\t\t'DaySingular' => 'Day',\r\n\t\t\t'HourPlural' => 'Hours',\r\n\t\t\t'HourSingular' => 'Hour',\r\n\t\t\t'MinutePlural' => 'Minutes',\r\n\t\t\t'MinuteSingular' => 'Minute',\r\n\t\t\t'SecondPlural' => 'Seconds',\r\n\t\t\t'SecondSingular' => 'Second',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsCountdown', \t\t\t$TS_VCSC_Countdown_Language_Defaults_Init);\r\n\t\t// Language Settings: Google Maps PLUS\r\n\t\t$TS_VCSC_Google_MapPLUS_Language_Defaults_Init = array(\r\n\t\t\t'ListenersStart' => 'Start Listeners',\r\n\t\t\t'ListenersStop' => 'Stop Listeners',\r\n\t\t\t'MobileShow' => 'Show Google Map',\r\n\t\t\t'MobileHide' => 'Hide Google Map',\r\n\t\t\t'StyleDefault' => 'Google Standard',\r\n\t\t\t'StyleLabel' => 'Change Map Style',\r\n\t\t\t'FilterAll' => 'All Groups',\r\n\t\t\t'FilterLabel' => 'Filter by Groups',\r\n\t\t\t'SelectLabel' => 'Zoom to Location',\r\n\t\t\t'ControlsOSM' => 'Open Street',\r\n\t\t\t'ControlsHome' => 'Home',\r\n\t\t\t'ControlsBounds' => 'Fit All',\r\n\t\t\t'ControlsBike' => 'Bicycle Trails',\r\n\t\t\t'ControlsTraffic' => 'Traffic',\r\n\t\t\t'ControlsTransit' => 'Transit',\r\n\t\t\t'TrafficMiles' => 'Miles per Hour',\r\n\t\t\t'TrafficKilometer' => 'Kilometers per Hour',\r\n\t\t\t'TrafficNone' => 'No Data Available',\r\n\t\t\t'SearchButton' => 'Search Location',\r\n\t\t\t'SearchHolder' => 'Enter address to search for ...',\r\n\t\t\t'SearchGoogle' => 'View on Google Maps',\r\n\t\t\t'SearchDirections' => 'Get Directions',\r\n\t\t\t'OtherLink' => 'Learn More!',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsGoogleMapPLUS', \t\t$TS_VCSC_Google_MapPLUS_Language_Defaults_Init);\r\n\t\t// Language Settings: Google Maps (Deprecated)\r\n\t\t$TS_VCSC_Google_Map_Language_Defaults_Init = array(\r\n\t\t\t'TextCalcShow' => 'Show Address Input',\r\n\t\t\t'TextCalcHide' => 'Hide Address Input',\r\n\t\t\t'TextDirectionShow' => 'Show Directions',\r\n\t\t\t'TextDirectionHide' => 'Hide Directions',\r\n\t\t\t'TextResetMap' => 'Reset Map',\r\n\t\t\t'PrintRouteText' \t\t\t => 'Print Route',\r\n\t\t\t'TextViewOnGoogle' => 'View on Google',\r\n\t\t\t'TextButtonCalc' => 'Show Route',\r\n\t\t\t'TextSetTarget' => 'Please enter your Start Address:',\r\n\t\t\t'TextGeoLocation' => 'Get My Location',\r\n\t\t\t'TextTravelMode' => 'Travel Mode',\r\n\t\t\t'TextDriving' => 'Driving',\r\n\t\t\t'TextWalking' => 'Walking',\r\n\t\t\t'TextBicy' => 'Bicycling',\r\n\t\t\t'TextWP' => 'Optimize Waypoints',\r\n\t\t\t'TextButtonAdd' => 'Add Stop on the Way',\r\n\t\t\t'TextDistance' => 'Total Distance:',\r\n\t\t\t'TextMapHome' => 'Home',\r\n\t\t\t'TextMapBikes' => 'Bicycle Trails',\r\n\t\t\t'TextMapTraffic' => 'Traffic',\r\n\t\t\t'TextMapSpeedMiles' => 'Miles Per Hour',\r\n\t\t\t'TextMapSpeedKM' => 'Kilometers Per Hour',\r\n\t\t\t'TextMapNoData' => 'No Data Available!',\r\n\t\t\t'TextMapMiles' => 'Miles',\r\n\t\t\t'TextMapKilometes' => 'Kilometers',\r\n\t\t\t'TextMapActivate' => 'Show Google Map',\r\n\t\t\t'TextMapDeactivate' => 'Hide Google Map',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsGoogleMap', \t\t\t$TS_VCSC_Google_Map_Language_Defaults_Init);\r\n\t\t// Language Settings: Isotope Posts\r\n\t\t$TS_VCSC_Isotope_Posts_Language_Defaults_Init = array(\r\n\t\t\t'ButtonFilter'\t\t => 'Filter Posts', \r\n\t\t\t'ButtonLayout'\t\t => 'Change Layout',\r\n\t\t\t'ButtonSort'\t\t => 'Sort Criteria',\r\n\t\t\t// Standard Post Strings\r\n\t\t\t'Date' \t\t\t\t => 'Post Date', \r\n\t\t\t'Modified' \t\t\t => 'Post Modified', \r\n\t\t\t'Title' \t\t\t => 'Post Title', \r\n\t\t\t'Author' \t\t\t => 'Post Author', \r\n\t\t\t'PostID' \t\t\t => 'Post ID', \r\n\t\t\t'Comments' \t\t\t => 'Number of Comments',\r\n\t\t\t// Layout Strings\r\n\t\t\t'SeeAll'\t\t\t => 'See All',\r\n\t\t\t'Timeline' \t\t\t => 'Timeline',\r\n\t\t\t'Masonry' \t\t\t => 'Centered Masonry',\r\n\t\t\t'FitRows'\t\t\t => 'Fit Rows',\r\n\t\t\t'StraightDown' \t\t => 'Straigt Down',\r\n\t\t\t// WooCommerce Strings\r\n\t\t\t'WooFilterProducts' => 'Filter Products',\r\n\t\t\t'WooTitle' => 'Product Title',\r\n\t\t\t'WooPrice' => 'Product Price',\r\n\t\t\t'WooRating' => 'Product Rating',\r\n\t\t\t'WooDate' => 'Product Date',\r\n\t\t\t'WooModified' => 'Product Modified',\r\n\t\t\t// General Strings\r\n\t\t\t'Categories' => 'Categories',\r\n\t\t\t'Tags' => 'Tags',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsIsotopePosts', \t\t\t$TS_VCSC_Isotope_Posts_Language_Defaults_Init);\r\n\t\t// Options for Lightbox Settings\r\n\t\t$TS_VCSC_Lightbox_Setting_Defaults_Init = array(\r\n\t\t\t'thumbs' => 'bottom',\r\n\t\t\t'thumbsize' => 50,\r\n\t\t\t'animation' => 'random',\r\n\t\t\t'captions' => 'data-title',\r\n\t\t\t'closer' => 1, // true/false\r\n\t\t\t'duration' => 5000,\r\n\t\t\t'share' => 0, // true/false\r\n\t\t\t'social' \t => 'fb,tw,gp,pin',\r\n\t\t\t'notouch' => 1, // true/false\r\n\t\t\t'bgclose'\t\t\t => 1, // true/false\r\n\t\t\t'nohashes'\t\t\t => 1, // true/false\r\n\t\t\t'keyboard'\t\t\t => 1, // 0/1\r\n\t\t\t'fullscreen'\t\t => 1, // 0/1\r\n\t\t\t'zoom'\t\t\t\t => 1, // 0/1\r\n\t\t\t'fxspeed'\t\t\t => 300,\r\n\t\t\t'scheme'\t\t\t => 'dark',\r\n\t\t\t'removelight' => 0,\r\n\t\t\t'customlight' => 0,\r\n\t\t\t'customcolor'\t\t => '#ffffff',\r\n\t\t\t'backlight' \t\t => '#ffffff',\r\n\t\t\t'usecolor' \t\t => 0, // true/false\r\n\t\t\t'background' => '',\r\n\t\t\t'repeat' => 'no-repeat',\r\n\t\t\t'overlay' => '#000000',\r\n\t\t\t'noise' => '',\r\n\t\t\t'cors' => 0, // true/false\r\n\t\t\t'scrollblock' => 'css',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_defaultLightboxSettings',\t\t\t$TS_VCSC_Lightbox_Setting_Defaults_Init);\r\n\t\tadd_option('ts_vcsc_extend_settings_defaultLightboxAnimation', \t\t\t'random');\r\n\t\t// Options for Envato Sales Data\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoData', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoInfo', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoLink', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoPrice', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoRating', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoSales', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoCheck', \t\t\t\t\t 0);\r\n\t\t$roles \t\t\t\t\t\t\t\t= get_editable_roles();\r\n\t\tforeach ($GLOBALS['wp_roles']->role_objects as $key => $role) {\r\n\t\t\tif (isset($roles[$key]) && $role->has_cap('edit_pages') && !$role->has_cap('ts_vcsc_extend')) {\r\n\t\t\t\t$role->add_cap('ts_vcsc_extend');\r\n\t\t\t}\r\n\t\t}\r\n\t}", "function initialize() {\r\n add_filter(\"slp_widget_default_options\", array($this, \"options\"));\r\n add_filter(\"slp_widget_get_settings\" , array($this, \"getSettings\"));\r\n\r\n $this->settings_array = apply_filters(\"slp_widget_default_options\", array());\r\n foreach ($this->settings_array as $setting => $setto) {\r\n $this->$setting = $setto;\r\n }\r\n }", "function __construct(){\n\t\t$this->options();\n\t}", "protected function _initOptions()\n {\n $options = [];\n\n if ($this->preset) {\n $options = CKEditorPresets::getPresets($this->preset);\n }\n\n $this->clientOptions = ArrayHelper::merge((array) $options, $this->clientOptions);\n }", "function init_integrated_options() {\n\t\t$this->permalink_sections();\n\n\t}", "public function init_options() {\n $options = array(\n 'gokeep_id',\n 'gokeep_additional_script'\n );\n\n $constructor = array();\n foreach ( $options as $option ) {\n $constructor[ $option ] = $this->$option = $this->get_option( $option );\n }\n\n return $constructor;\n }", "public function init_option() {\n\t\tglobal $wpdb;\n\n\t\t$sections = array(\n\t\t\tarray(\n\t\t\t\t'id' => 'wp_price_chart_opt',\n\t\t\t\t'title' => __( 'General', 'wp-reviews-insurance' )\n\t\t\t),\n\t\t);\n\n\t\t// Get List Symbol\n\t\t$symbol_list = $wpdb->get_results( \"SELECT SYMBOL_ID, SYMBOL FROM {$wpdb->prefix}socks_symbol\", ARRAY_A );\n\t\t$list = array();\n\t\tforeach ( $symbol_list as $r ) {\n\t\t\t$list[ $r['SYMBOL_ID'] ] = $r['SYMBOL'];\n\t\t}\n\n\t\t$fields = array(\n\t\t\t'wp_price_chart_opt' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'default_symbol',\n\t\t\t\t\t'label' => __( 'Default Symbol', 'wedevs' ),\n\t\t\t\t\t'desc' => __( 'Use [price-chart] ShortCode in WordPress', 'wedevs' ),\n\t\t\t\t\t'type' => 'select',\n\t\t\t\t\t'options' => $list\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'chart_height',\n\t\t\t\t\t'label' => __( 'Chart Height', 'wp-reviews-insurance' ),\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'default' => '130',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'default_show_ago',\n\t\t\t\t\t'label' => __( 'Show ago Hour (default)', 'wp-reviews-insurance' ),\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'default' => '5',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t),\n\t\t\t),\n\n\t\t);\n\n\t\t$this->setting = new SettingAPI();\n\n\t\t//set sections and fields\n\t\t$this->setting->set_sections( $sections );\n\t\t$this->setting->set_fields( $fields );\n\n\t\t//initialize them\n\t\t$this->setting->admin_init();\n\t}", "protected function init()\r\n {\r\n parent::init();\r\n\r\n foreach ($this->options as $name => $value) {\r\n switch ($name) {\r\n case 'query':\r\n if (!is_array($value)) {\r\n $value = array(array('query' => $value));\r\n }\r\n $this->addQueries($value);\r\n break;\r\n }\r\n }\r\n }", "private function plugin_load_settings() {\r\n\t\tif (empty($this->options)) {\r\n\t\t\t$this->options = get_option( $this->options_name );\r\n\t\t}\r\n\t\tif ( !is_array( $this->options ) ) {\r\n\t\t\t$this->options = array();\r\n\t\t}\r\n\t\t$this->options = wp_parse_args($this->options, $this->defaults);\r\n\t}", "protected function __construct() {\n\t\t\t// Full path to main file\n\t\t\t$this->plugin_file= __FILE__;\n\t\t\t$this->plugin_dir = dirname( $this->plugin_file );\n\t\t\t$this->options = $this->get_saved_options();\n\t\t}", "public function _init() {\n parent::_init();\n if(empty($this->options))\n \t $this->options = [];\n \tif (empty($this->options['class']))\n \t $this->options['class'] = '';\n \t$this->add_option($this->options['class'], 'btn');\n }", "protected function get_options()\n\t{}", "public function __construct($options = array()){ \r\n $this->setOptions($options);\r\n }", "public function options_load();", "function wikiembed_options_init() {\n\tregister_setting( 'wikiembed_options', 'wikiembed_options', 'wikiembed_options_validate' ); // the settings for wiki embed options\n}", "public function init_plugin()\n {\n }", "public function __construct() {\n\t\t$this->ryte_option = $this->get_option();\n\t}", "function init() {\n $this.getAdminOptions();\n }", "public function set_options_filter() {\n\t\t/**\n\t\t * Filter the plugin options.\n\t\t *\n\t\t * @since 10.0.0\n\t\t *\n\t\t * @return array\n\t\t */\n\t\t$config = apply_filters( 'gu_set_options', [] );\n\n\t\t/**\n\t\t * Filter the plugin options.\n\t\t *\n\t\t * @return null|array\n\t\t */\n\t\t$config = empty( $config ) ? apply_filters_deprecated( 'github_updater_set_options', [ [] ], '6.1.0', 'gu_set_options' ) : $config;\n\n\t\tforeach ( array_keys( self::$git_servers ) as $git ) {\n\t\t\tunset( $config[ \"{$git}_access_token\" ], $config[ \"{$git}_enterprise_token\" ] );\n\t\t}\n\n\t\tif ( ! empty( $config ) ) {\n\t\t\t$config = $this->sanitize( $config );\n\t\t\tself::$options = array_merge( get_site_option( 'git_updater' ), $config );\n\t\t\tupdate_site_option( 'git_updater', self::$options );\n\t\t}\n\t}", "function load_settings() {\r\n $options = get_option($this->optionsName);\r\n\r\n if ($old_setting = get_option('custom_page_extension')) {\r\n delete_option('custom_page_extension');\r\n }\r\n\r\n $defaults = array(\r\n 'extension' => ($old_setting != \"\") ? $old_setting : 'html',\r\n );\r\n\r\n $this->options = (object) wp_parse_args($options, $defaults);\r\n }", "function __construct(){\n\t\tadd_filter('lasso_custom_options',\t\tarray($this,'options'));\n\n\t\t// if you arent using aesop story engine then this filter isnt needed\n\t\tadd_filter('aesop_avail_components',\tarray($this, 'options') );\n\t}", "public function __construct()\n {\n $this->options = [];\n }", "function splashgate_admin_init(){\n\t\t\tregister_setting(\tSPLASHGATE_SETTINGS_GROUP, 'splashgate_options' ); // 'options' will be an array holding everything\n\t\t}", "public function init(array $options);", "protected function initOptions()\n {\n $this->options = array_merge([\n 'class' => 'small-box'\n ], $this->options);\n $this->theme || $this->theme = 'info';\n Html::addCssClass($this->options, 'bg-'.$this->theme);\n\n $this->linkOptions = array_merge([\n 'class' => 'small-box-footer'\n ], $this->linkOptions);\n }", "public function options() {}", "public function setDefaultOptions()\n {\n // Set event data\n foreach ($this->events as $event => $handler) {\n $this->options['data']['widget-action-' . $event] = $handler;\n }\n\n if($this->jsWidget) {\n $this->options['data']['ui-widget'] = $this->jsWidget;\n }\n\n if($this->fadeIn) {\n $fadeIn = $this->fadeIn === true ? 'fast' : $this->fadeIn;\n $this->options['data']['widget-fade-in'] = $fadeIn;\n $this->visible = false;\n }\n\n if (!empty($this->init)) {\n $this->options['data']['ui-init'] = $this->init;\n }\n }", "protected function _construct()\n {\n $this->_init('bundle/option');\n }", "private function initOptions()\n {\n $this->optionsResolver->setDefaults([\n 'collection' => [],\n ]);\n\n $this->optionsResolver->setAllowedTypes('collection', 'array');\n }", "protected function initOptions()\n {\n Html::addCssClass($this->options, 'uk-alert uk-alert-'.$this->type);\n $this->options['uk-alert'] = true;\n }", "public function configureOptions();", "static function optionsIns();", "public static function init()\n\t{\n\t\t$self = new self;\n\t\tadd_action('init', [$self, 'registerOptionsPage']);\n\t}", "protected function get_registered_options()\n {\n }", "function wpdc_my_settings_init() {\r\n // register the settins for the plugin here (you might want to give it more unique names)\r\n\t\tregister_setting( 'wpdc_plugin_options_group', 'wpdc_options', 'wpdc_sanitize_wpdc_validate_options' );\r\n }", "public function options();", "public function options();", "public function options();", "public function options();", "public function options();", "public function register_options() {\n\t\tparent::register_options();\n\n\t}", "public function __construct($options = array()) {\n $this->options = $options + $this->defaults;\n }", "function __construct($option = array());", "function __construct(array $options=array()) {\n $this->options = $options + static::getDefaults();\n }", "public function initOptions()\n {\n $this->setOption('className', '%CLASS%' . $this->getRelationName());\n }", "public function plugin_register_options() {\r\n\t\tregister_setting( $this->options_group, $this->options_name , array(&$this, 'plugin_validate_options' ));\r\n\t}", "public function __construct( $plugin, $options = array() )\n\t{\n\t\t$this->plugin = $plugin;\n\t\t\n\t\tif ( count( $options ) > 0 )\n\t\t{\n\t\t\t$this->set( $options );\n\t\t}\n\t}", "protected function loadDefaultOptions()\r\n {\r\n $this->options = [\r\n 'offsettop' => 0,\r\n 'offsetleft' => 0,\r\n 'merge' => false,\r\n 'backcolor' => 0xffffff,\r\n ];\r\n }", "function populate_options(array $options = array())\n {\n }", "public function initializePlugin();", "public function load_options( $options = array() ) {}", "function techfak_theme_options_init() {\n\tregister_setting(\n\t\t'techfak_options', // Options group, see settings_fields() call in theme_options_render_page()\n\t\t'techfak_theme_options', // Database option, see techfak_get_theme_options()\n\t\t'techfak_theme_options_validate' // The sanitization callback, see techfak_theme_options_validate()\n\t);\n}", "protected function _initOptions()\n\t{\n\t\t\n\t\t$this->options = array_merge( [\n\t\t\t'role' => 'dialog',\n\t\t\t'tabindex' => false,\n\t\t], $this->options );\n\t\t\n\t\tHtml::addCssClass( $this->options, [ 'type' => 'fade modal' ] );\n\t\t\n\t\tif( is_array( $this->clientOptions ) ) {\n\t\t\t$this->clientOptions = array_merge( [ 'show' => false ], $this->clientOptions );\n\t\t}\n\t\t\n\t\tif( is_array( $this->url ) ) {\n\t\t\t$this->url = Url::to( $this->url );\n\t\t}\n\t\t\n\t\tif( is_array( $this->closeButton ) ) {\n\t\t\t\n\t\t\t$this->closeButton = array_merge( [\n\t\t\t\t'data-dismiss' => 'modal',\n\t\t\t\t'aria-hidden' => 'true',\n\t\t\t\t'class' => 'close',\n\t\t\t], $this->closeButton );\n\t\t\t\n\t\t}\n\t\t\n\t\tif( is_array( $this->toggleButton ) ) {\n\t\t\t\n\t\t\t$this->toggleButton = array_merge( [\n\t\t\t\t'data-toggle' => 'modal',\n\t\t\t], $this->toggleButton );\n\t\t\t\n\t\t\tif( !isset( $this->toggleButton['data-target'] ) && !isset( $this->toggleButton['href'] ) ) {\n\t\t\t\t$this->toggleButton['data-target'] = '#' . $this->options['id'];\n\t\t\t}\n\t\t}\n\t\t\n\t}", "function pm_initialize_options() {\n if( false == get_option( 'pm_display_options' ) ) {\n add_option( 'pm_display_options' );\n } // end if \n \n // First, we register a section. This is necessary since all future options must belong to a \n add_settings_section( \n 'general_settings_section',\t\t\t// ID used to identify this section and with which to register options \n 'Display Options',\t\t\t\t\t// Title to be displayed on the administration page \n 'pm_general_options_callback',\t\t// Callback used to render the description of the section \n 'pm_display_options'\t\t\t\t// Page on which to add this section of options \n ); \n \n // Next, we'll introduce the fields for toggling the visibility of content elements. \n add_settings_field( \n 'walled_garden',\t\t\t\t\t// ID used to identify the field throughout the theme \n 'Walled Garden',\t\t\t\t\t// The label to the left of the option interface element \n 'pm_toggle_walled_garden_callback',\t// The name of the function responsible for rendering the option interface \n 'pm_display_options',\t\t\t\t// The page on which this option will be displayed \n 'general_settings_section',\t\t\t// The name of the section to which this field belongs \n array(\t\t\t\t\t\t\t\t// The array of arguments to pass to the callback. In this case, just a description. \n 'Require users to be logged-in to access the site.' \n ) \n ); \n\n // Finally, we register the fields with WordPress \n register_setting( \n 'pm_display_options', \n 'pm_display_options' \n ); \n \n}", "function activate() {\n\t\t\tadd_option('h2utp_options', json_encode($this->options));\n\t\t}", "private function init() {\n $options = $this->options;\n if ($options === false) $options = array();\n if (isset($options['defaultFolder'])) {\n $this->defaultIconsFolder = $options['defaultFolder'];\n }\n }", "function init()\n\t{\n\t\tglobal $Options, $User_Options;\n\t\t$Options\t= $this->options\t=\t$this->get( NULL , NULL , TRUE );\n\t\t// Only when aauth is enabled\n\t\tif( Modules::is_active( 'aauth' ) )\n\t\t{\n\t\t\t$User_Options = $this->user_options = $this->get( NULL , $this->events->apply_filters( 'user_id' , 0 ) );\n\t\t}\n\t\t\n\t\t\n\t\t/**\n\t\t * If language is set on dashboard\n\t\t * @since 3.0.5\n\t\t**/\n\t\tif( riake( 'site_language', $Options ) ) {\n\t\t\tget_instance()->config->set_item( 'site_language', $Options[ 'site_language' ] );\n\t\t}\n\n\t\t/** \n\t \t * Load Language\n\t\t**/\n\t\t\n\t\t$this->lang->load( 'system' );\t\n\t}", "public function register_options(){\n\t\tparent::register_options();\n\t\t//$orgzr = \\WBF\\modules\\options\\Organizer::getInstance();\n\t\t//Do stuff...\n\t}", "protected function _construct()\n\t{\n\t\tparent::_construct();\n\n\t\t$data = array();\n\t\t\n\t\tforeach($this->_optionFields as $key) {\n\t\t\tif ($key !== '') {\n\t\t\t\t$key = '_' . $key;\n\t\t\t}\n\n\t\t\t$options = Mage::helper('wordpress')->getWpOption('wpseo' . $key);\n\t\t\t\n\t\t\tif ($options && ($options = unserialize($options))) {\n\t\t\t\tforeach($options as $key => $value) {\n\t\t\t\t\tif (strpos($key, '-') !== false) {\n\t\t\t\t\t\tunset($options[$key]);\n\t\t\t\t\t\t$options[str_replace('-', '_', $key)] = $value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif (is_array($options)) {\n \t\t\t\t$data = array_merge($data, $options);\n }\n\t\t\t}\n\t\t}\n\n\t\t$this->setData($data);\n\t}", "public function init_settings()\n {\n /** @noinspection PhpUndefinedClassInspection */\n parent::init_settings();\n\n $sharedOptions = get_option(SharedPersistor::OPTION_NAME, []) ?: [];\n $this->settings = array_merge($this->settings, $sharedOptions);\n }", "function of_option_setup()\t{\n\t\n\tglobal $of_options, $options_machine;\n\t\n\t$options_machine = new Options_Machine($of_options);\n\t\t\n\tif (!get_option(OPTIONS)){\n\t\t\n\t\t$defaults = (array) $options_machine->Defaults;\n\t\tupdate_option(OPTIONS,$defaults);\n\t\tgenerate_options_css($defaults); \n\t\t\n\t}\n\t\n\t\n}", "function get_options() \n {\n // don't forget to set up the default options\n if ( ! $the_options = get_option( $this->options_name) ) {\n $the_options = array(\n 'bbquotations-slug' =>'quotes',\n 'use-css-file' => false\n );\n update_option($this->options_name, $the_options);\n }\n $this->options = $the_options;\n }", "public function initialize_settings() {\n\n\t\t$default_settings = array();\n\n\t\tforeach ($this->settings as $id => $setting) {\n\t\t\tif ($setting['type'] != 'heading')\n\t\t\t\t$default_settings['$id'] = $setting['std'];\n\t\t}\n\n\t\tupdate_option('eaboot_options', $default_settings);\n\t}", "public function __construct($options) { }", "public function init_group_options() {\r\n\t\tif ( ! empty( $this->settings['options'] ) ) {\r\n\r\n\t\t\tif ( is_array( $this->settings['options'] ) ) {\r\n\r\n\t\t\t\tforeach ( $this->settings['options'] as $settings ) {\r\n\r\n\t\t\t\t\tif ( ! apply_filters( 'tf_create_option_continue_' . $this->getOptionNamespace(), true, $settings ) ) {\r\n\t\t\t\t\t\tcontinue;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t$obj = TitanFrameworkOption::factory( $settings, $this->owner );\r\n\t\t\t\t\t$this->options[] = $obj;\r\n\r\n\t\t\t\t\tdo_action( 'tf_create_option_' . $this->getOptionNamespace(), $obj );\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "function __construct($options = null)\n {\n if ($options !== null)\n $this->optsData()->import($options);\n }", "protected function getOptions() {}", "protected function getOptions() {}", "protected function getOptions() {}", "function myplugin_activate_options( $options ) {\n\n\tforeach ($options as $option => $default_value) {\n\t\tadd_option( $option, $default_value );\n\t}\n}", "protected function configureOptions(): void\n {\n }", "private function skyword_defaults() {\n\t\t$tmp = get_option('skyword_plugin_options');\n\t if(!is_array($tmp)) {\n\t\t\t$arr = array(\n\t\t\t\"skyword_api_key\"=>null, \n\t\t\t\"skyword_enable_ogtags\" => true, \n\t\t\t\"skyword_enable_metatags\" => true, \n\t\t\t\"skyword_enable_googlenewstag\" => true,\n\t\t\t\"skyword_enable_pagetitle\" => true,\n\t\t\t\"skyword_enable_sitemaps\" => true,\n\t\t\t\"skyword_generate_all_sitemaps\" => true,\n\t\t\t\"skyword_generate_news_sitemaps\" => true,\n\t\t\t\"skyword_generate_pages_sitemaps\" => true,\n\t\t\t\"skyword_generate_categories_sitemaps\" => true,\n\t\t\t\"skyword_generate_tags_sitemaps\" => true\n\t\t\t);\n\t\t\tupdate_option('skyword_plugin_options', $arr);\n\t\t}\n\t}", "function __construct(array $options = array()) {\n\t\t$this->_options = $options;\n\t}", "private function __construct($options = false)\n {\n $this->options = $options;\n }", "protected function defineOptions() {\n return parent::defineOptions();\n }", "public function init(){\n\t\tadd_action( 'admin_init', array( $this, 'init_plugin' ), 20 );\n\t}", "public static function add_options(){\n\n \t\t$settings = array(\n \t\t\t'foundation' => 0\n \t\t);\n\n \t\tadd_option( 'zip_downloads', $settings ); \n\t}", "public function initialize() {\r\n\t\tparent::initialize();\r\n\t\t$this->settings = $this->pluginSettingsDemandService->getSettings();\r\n\t}", "function load_default_options() {\n foreach ($this->modules as $name => $data) {\n $this->modules->$name->options = new stdClass();\n $saved_options = get_option($this->clientele_prefix . $name . '_options');\n if ($saved_options) {\n $this->modules->$name->options = (object) array_merge((array) $this->modules->$name->options, (array) $saved_options);\n }\n foreach ($data->default_options as $default_key => $default_value) {\n if (!isset($this->modules->$name->options->$default_key)) {\n $this->modules->$name->options->$default_key = $default_value;\n }\n }\n $this->$name->module = $this->modules->$name;\n }\n do_action('clientele_default_options_loaded');\n // Initialise modules if enabled.\n foreach ($this->modules as $name => $data) {\n if ($data->options->enabled == 'on') {\n if (method_exists($this->$name, 'init')) {\n $this->$name->init();\n }\n }\n }\n do_action('clientele_initialised');\n }", "function admin_init(){\r\n // whitelist options\r\n register_setting( 'twitlink_options_group', $this->db_option ,array(&$this,'options_sanitize' ) );\r\n // admin scripts\r\n wp_register_script( 'twitlink_script', $this->plugin_url.'js/script.js',array('jquery'),$this->version );\r\n //wp_register_script( 'twitlink_fancybox', $this->plugin_url.'js/jquery.fancybox.js',array('jquery'),$this->version );\r\n //wp_register_script( 'twitlink_fancybox-media', $this->plugin_url.'js/jquery.fancybox-media.js',array('jquery'),$this->version );\r\n // admin styles\r\n //wp_register_style( 'twitlink_fancybox_style', $this->plugin_url.'style/jquery.fancybox.css',NULL,$this->version);\r\n // plugin settings\r\n $settings = array ('plugin_name' => 'twitlink','author_name' => 'Andy Bailey', 'home_page' => 'http://www.commentluv.com',\r\n 'twitter_id' => 'commentluv','linkedin_id' => 'commentluv','facebook_page' => 'http://www.facebook.com/CommentLuv',\r\n 'helpdesk_link' => 'https://commentluv.zendesk.com/','show_sidebar' => 'yes','show_subscribe_form' => 'yes',\r\n 'aweber_list_name' => 'ab_prem_plugin','video_url'=>'http://www.youtube.com/embed/e5u4xQdxgQ8?autoplay=1');\r\n\r\n foreach($settings as $key => $value){\r\n $this->$key = $value; \r\n } \r\n }", "public function __construct($options = NULL)\n\t{\n\t $this\n\t \t->setOptions($options)\n\t \t->_init()\n\t ;\n\t}", "public function init()\n {\n // TODO: initialize by config ordering\n foreach ($this->plugins as $name => $plugin) {\n $plugin->init();\n }\n }", "public function __construct()\n\t{\n\t\t$this->options = array(\n\t\t\t'class.first' => 'first',\n\t\t\t'class.last' => 'last',\n\t\t\t'class.single' => 'single',\n\t\t);\n\t}", "function cbstdsys_init(){\n\tregister_setting( 'cbstdsys_plugin_options', 'cbstdsys_options', 'cbstdsys_validate_options' );\n}", "public static function set_options() {\r\n\t\tself::add_option(\"my_option\", \"foo\");\r\n\t}", "public function init() \n\t{\n\t\t$params = parent::getPluginInstance()->getParams();\t\t\n\t\t\n\t\t$this->isPluginActive = $params->isActive;\n\t\tif( $this->isPluginActive ) {\n\t\t\t$this->isPluginReady = $params->isReady;\n\t\t}\n\t\t\n\t\tif( $this->isPluginActive && $this->isPluginReady ) {\n\t\t\t\n\t\t\t/*\n\t\t\t \n\t\t\t The $params parameter should be an object as follows: \n\t\t\t \n\t\t\t\t$params->isActive\n\t\t\t\t$params->isReady\n\t\t\t\t$params->defaultCode\n\t\t\t\t$params->defaultLocale\n\t\t\t\t$params->activeCode\n\t\t\t\t$params->activeLocale\n\t\t\t\t$params->allCodes\n\t\t\t\t$params->allLocales\n\t\t\t\t\n\t\t\t*/\n\t\t\t\n\t\t\t$this->setParamsDefault( $params->defaultCode, $params->defaultLocale );\n\t\t\t$this->setParamsActive( $params->activeCode, $params->activeLocale );\n\t\t\t$this->setParamsAll( $params->allCodes, $params->allLocales );\n\n\t\t\t// @todo: fix termonology codes vs langs\n\t\t\t$this->gdprcLocales = parent::getLangsOption();\n\t\t\t\n\t\t\t$this->isAll = ( 'all' === $params->activeCode ) ? true : false;\n\t\t\n\t\t\tif( !$this->isAll ) {\n\t\t\t\tif( !empty( $this->gdprcLocales ) ) {\n\t\t\t\t\t$exist = parent::getLangSyncStatusses( $this->gdprcLocales );\n\t\t\t\t\t\n\t\t\t\t\t$removed = array_keys( $exist, 2 );\n\t\t\t\t\tif( !empty( $removed ) ) {\n\t\t\t\t\t\t$this->removedCodes = $removed;\n\t\t\t\t\t\t$this->hasRemovedLang = true;\n\t\t\t\t\t}\n\t\t\t\t\t$new = array_keys( $exist, 0, true);\n\t\t\t\t\tif( !empty( $new ) ) {\n\t\t\t\t\t\t$this->newCodes = $new;\n\t\t\t\t\t\t$this->hasNewLang = true;\n\t\t\t\t\t}\t\t\t\t\n\t\t\t\t}\n\t\t\t} elseif( $this->isAll ) {\n\t\t\t\t// if the current active language (code) is 'all',\n\t\t\t\t// set the params to the default language\n\t\t\t\t// if activating, switch the language also\n\t\t\t\t\n\t\t\t\tif( $this->activating || get_option( 'gdprc_activating_' . $this->nameSpace ) ) {\n\t\t\t\t\t$newCode = parent::getPluginInstance()->switchToDefault();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$this->setParamsActive( $params->defaultCode, $params->defaultLocale );\n\t\t\t}\t\t\t\n\t\t}\t\n\n\t\tif( $this->activating ) {\n\t\t\t$this->activatePlugin();\n\t\t}\t\t\n\t\tif( !$this->isPluginActive ) {\n\t\t\tparent::deleteLangsOption();\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\treturn true;\t\n\t}", "public function setArguments() {\n\n $theme = wp_get_theme(); // For use with some settings. Not necessary.\n\n $this->args = array(\n // TYPICAL -> Change these values as you need/desire\n 'opt_name' => 'tb_options',\n // This is where your data is stored in the database and also becomes your global variable name.\n 'display_name' => $theme->get( 'Name' ),\n // Name that appears at the top of your panel\n 'display_version' => $theme->get( 'Version' ),\n // Version that appears at the top of your panel\n 'menu_type' => 'menu',\n //Specify if the admin menu should appear or not. Options: menu or submenu (Under appearance only)\n 'allow_sub_menu' => true,\n // Show the sections below the admin menu item or not\n 'menu_title' => __( 'Theme Options', 'slova' ),\n 'page_title' => __( 'Theme Options', 'slova' ),\n // You will need to generate a Google API key to use this feature.\n // Please visit: https://developers.google.com/fonts/docs/developer_api#Auth\n 'google_api_key' => '',\n // Set it you want google fonts to update weekly. A google_api_key value is required.\n 'google_update_weekly' => false,\n // Must be defined to add google fonts to the typography module\n 'async_typography' => true,\n // Use a asynchronous font on the front end or font string\n //'disable_google_fonts_link' => true, // Disable this in case you want to create your own google fonts loader\n 'admin_bar' => true,\n // Show the panel pages on the admin bar\n 'admin_bar_icon' => 'dashicons-portfolio',\n // Choose an icon for the admin bar menu\n 'admin_bar_priority' => 50,\n // Choose an priority for the admin bar menu\n 'global_variable' => '',\n // Set a different name for your global variable other than the opt_name\n 'dev_mode' => false,\n // Show the time the page took to load, etc\n 'update_notice' => false,\n // If dev_mode is enabled, will notify developer of updated versions available in the GitHub Repo\n 'customizer' => true,\n // Enable basic customizer support\n //'open_expanded' => true, // Allow you to start the panel in an expanded way initially.\n //'disable_save_warn' => true, // Disable the save warning when a user changes a field\n\n // OPTIONAL -> Give you extra features\n 'page_priority' => null,\n // Order where the menu appears in the admin area. If there is any conflict, something will not show. Warning.\n 'page_parent' => 'themes.php',\n // For a full list of options, visit: http://codex.wordpress.org/Function_Reference/add_submenu_page#Parameters\n 'page_permissions' => 'manage_options',\n // Permissions needed to access the options panel.\n 'menu_icon' => '',\n // Specify a custom URL to an icon\n 'last_tab' => '',\n // Force your panel to always open to a specific tab (by id)\n 'page_icon' => 'icon-themes',\n // Icon displayed in the admin panel next to your menu_title\n 'page_slug' => '_options',\n // Page slug used to denote the panel\n 'save_defaults' => true,\n // On load save the defaults to DB before user clicks save or not\n 'default_show' => false,\n // If true, shows the default value next to each field that is not the default value.\n 'default_mark' => '',\n // What to print by the field's title if the value shown is default. Suggested: *\n 'show_import_export' => true,\n // Shows the Import/Export panel when not used as a field.\n\n // CAREFUL -> These options are for advanced use only\n 'transient_time' => 60 * MINUTE_IN_SECONDS,\n 'output' => true,\n // Global shut-off for dynamic CSS output by the framework. Will also disable google fonts output\n 'output_tag' => true,\n // Allows dynamic CSS to be generated for customizer and google fonts, but stops the dynamic CSS from going to the head\n // 'footer_credit' => '', // Disable the footer credit of Redux. Please leave if you can help it.\n\n // FUTURE -> Not in use yet, but reserved or partially implemented. Use at your own risk.\n 'database' => '',\n // possible: options, theme_mods, theme_mods_expanded, transient. Not fully functional, warning!\n 'system_info' => false,\n // REMOVE\n\n // HINTS\n 'hints' => array(\n 'icon' => 'icon-question-sign',\n 'icon_position' => 'right',\n 'icon_color' => 'lightgray',\n 'icon_size' => 'normal',\n 'tip_style' => array(\n 'color' => 'light',\n 'shadow' => true,\n 'rounded' => false,\n 'style' => '',\n ),\n 'tip_position' => array(\n 'my' => 'top left',\n 'at' => 'bottom right',\n ),\n 'tip_effect' => array(\n 'show' => array(\n 'effect' => 'slide',\n 'duration' => '500',\n 'event' => 'mouseover',\n ),\n 'hide' => array(\n 'effect' => 'slide',\n 'duration' => '500',\n 'event' => 'click mouseleave',\n ),\n ),\n )\n );\n\t\t\t\t\n // SOCIAL ICONS -> Setup custom links in the footer for quick links in your panel footer icons.\n $this->args['share_icons'][] = array(\n 'url' => '#',\n 'title' => 'Visit us on GitHub',\n 'icon' => 'el-icon-github'\n //'img' => '', // You can use icon OR img. IMG needs to be a full URL.\n );\n $this->args['share_icons'][] = array(\n 'url' => '#',\n 'title' => 'Like us on Facebook',\n 'icon' => 'el-icon-facebook'\n );\n $this->args['share_icons'][] = array(\n 'url' => '#',\n 'title' => 'Follow us on Twitter',\n 'icon' => 'el-icon-twitter'\n );\n $this->args['share_icons'][] = array(\n 'url' => '#',\n 'title' => 'Find us on LinkedIn',\n 'icon' => 'el-icon-linkedin'\n );\n }", "public function init() {\n\n\t\t// Register theme options\n\t\t$this->addOption('typography', 'radio', array(\n\t\t\t'label' => 'plugins.themes.default.option.typography.label',\n\t\t\t'description' => 'plugins.themes.default.option.typography.description',\n\t\t\t'options' => array(\n\t\t\t\t'notoSans' => 'plugins.themes.default.option.typography.notoSans',\n\t\t\t\t'notoSerif' => 'plugins.themes.default.option.typography.notoSerif',\n\t\t\t\t'notoSerif_notoSans' => 'plugins.themes.default.option.typography.notoSerif_notoSans',\n\t\t\t\t'notoSans_notoSerif' => 'plugins.themes.default.option.typography.notoSans_notoSerif',\n\t\t\t\t'lato' => 'plugins.themes.default.option.typography.lato',\n\t\t\t\t'lora' => 'plugins.themes.default.option.typography.lora',\n\t\t\t\t'lora_openSans' => 'plugins.themes.default.option.typography.lora_openSans',\n\t\t\t)\n\t\t));\n\n\t\t$this->addOption('baseColour', 'colour', array(\n\t\t\t'label' => 'plugins.themes.default.option.colour.label',\n\t\t\t'description' => 'plugins.themes.default.option.colour.description',\n\t\t\t'default' => '#1E6292',\n\t\t));\n\n\t\t// Load primary stylesheet\n\t\t$this->addStyle('stylesheet', 'styles/index.less');\n\n\t\t// Store additional LESS variables to process based on options\n\t\t$additionalLessVariables = array();\n\n\t\t// Load fonts from Google Font CDN\n\t\t// To load extended latin or other character sets, see:\n\t\t// https://www.google.com/fonts#UsePlace:use/Collection:Noto+Sans\n\t\tif (Config::getVar('general', 'enable_cdn')) {\n\n\t\t\tif ($this->getOption('typography') === 'notoSerif') {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontNotoSerif',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Noto+Serif:400,400i,700,700i',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\t\t\t\t$additionalLessVariables[] = '@font: \"Noto Serif\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", \"Roboto\", \"Oxygen-Sans\", \"Ubuntu\", \"Cantarell\", \"Helvetica Neue\", sans-serif;';\n\n\t\t\t} elseif (strpos($this->getOption('typography'), 'notoSerif') !== false) {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontNotoSansNotoSerif',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Noto+Sans:400,400i,700,700i|Noto+Serif:400,400i,700,700i',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\n\t\t\t\t// Update LESS font variables\n\t\t\t\tif ($this->getOption('typography') == 'notoSerif_notoSans') {\n\t\t\t\t\t$additionalLessVariables[] = '@font-heading: \"Noto Serif\", serif;';\n\t\t\t\t} elseif ($this->getOption('typography') == 'notoSans_notoSerif') {\n\t\t\t\t\t$additionalLessVariables[] = '@font: \"Noto Serif\", serif;@font-heading: \"Noto Sans\", serif;';\n\t\t\t\t}\n\n\t\t\t} elseif ($this->getOption('typography') == 'lato') {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontLato',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Lato:400,400i,900,900i',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\t\t\t\t$additionalLessVariables[] = '@font: Lato, sans-serif;';\n\n\t\t\t} elseif ($this->getOption('typography') == 'lora') {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontLora',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Lora:400,400i,700,700i',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\t\t\t\t$additionalLessVariables[] = '@font: Lora, serif;';\n\n\t\t\t} elseif ($this->getOption('typography') == 'lora_openSans') {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontLoraOpenSans',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Lora:400,400i,700,700i|Open+Sans:400,400i,700,700i',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\t\t\t\t$additionalLessVariables[] = '@font: \"Open Sans\", sans-serif;@font-heading: Lora, serif;';\n\n\t\t\t} else {\n\t\t\t\t$this->addStyle(\n\t\t\t\t\t'fontNotoSans',\n\t\t\t\t\t'//fonts.googleapis.com/css?family=Noto+Sans:400,400italic,700,700italic',\n\t\t\t\t\tarray('baseUrl' => '')\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\t// Update colour based on theme option\n\t\tif ($this->getOption('baseColour') !== '#1E6292') {\n\t\t\t$additionalLessVariables[] = '@bg-base:' . $this->getOption('baseColour') . ';';\n\t\t\tif (!$this->isColourDark($this->getOption('baseColour'))) {\n\t\t\t\t$additionalLessVariables[] = '@text-bg-base:rgba(0,0,0,0.84);';\n\t\t\t}\n\t\t}\n\n\t\t// Pass additional LESS variables based on options\n\t\tif (!empty($additionalLessVariables)) {\n\t\t\t$this->modifyStyle('stylesheet', array('addLessVariables' => join($additionalLessVariables)));\n\t\t}\n\n\t\t$request = Application::getRequest();\n\n\t\t// Load icon font FontAwesome - http://fontawesome.io/\n\t\tif (Config::getVar('general', 'enable_cdn')) {\n\t\t\t$url = 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.css';\n\t\t} else {\n\t\t\t$url = $request->getBaseUrl() . '/lib/pkp/styles/fontawesome/fontawesome.css';\n\t\t}\n\t\t$this->addStyle(\n\t\t\t'fontAwesome',\n\t\t\t$url,\n\t\t\tarray('baseUrl' => '')\n\t\t);\n\n\t\t// Load jQuery from a CDN or, if CDNs are disabled, from a local copy.\n\t\t$min = Config::getVar('general', 'enable_minified') ? '.min' : '';\n\t\tif (Config::getVar('general', 'enable_cdn')) {\n\t\t\t$jquery = '//ajax.googleapis.com/ajax/libs/jquery/' . CDN_JQUERY_VERSION . '/jquery' . $min . '.js';\n\t\t\t$jqueryUI = '//ajax.googleapis.com/ajax/libs/jqueryui/' . CDN_JQUERY_UI_VERSION . '/jquery-ui' . $min . '.js';\n\t\t} else {\n\t\t\t// Use OJS's built-in jQuery files\n\t\t\t$jquery = $request->getBaseUrl() . '/lib/pkp/lib/vendor/components/jquery/jquery' . $min . '.js';\n\t\t\t$jqueryUI = $request->getBaseUrl() . '/lib/pkp/lib/vendor/components/jqueryui/jquery-ui' . $min . '.js';\n\t\t}\n\t\t// Use an empty `baseUrl` argument to prevent the theme from looking for\n\t\t// the files within the theme directory\n\t\t$this->addScript('jQuery', $jquery, array('baseUrl' => ''));\n\t\t$this->addScript('jQueryUI', $jqueryUI, array('baseUrl' => ''));\n\t\t$this->addScript('jQueryTagIt', $request->getBaseUrl() . '/lib/pkp/js/lib/jquery/plugins/jquery.tag-it.js', array('baseUrl' => ''));\n\n\t\t// Load Bootsrap's dropdown\n\t\t$this->addScript('popper', 'js/lib/popper/popper.js');\n\t\t$this->addScript('bsUtil', 'js/lib/bootstrap/util.js');\n\t\t$this->addScript('bsDropdown', 'js/lib/bootstrap/dropdown.js');\n\n\t\t// Load custom JavaScript for this theme\n\t\t$this->addScript('default', 'js/main.js');\n\n\t\t// Add navigation menu areas for this theme\n\t\t$this->addMenuArea(array('primary', 'user'));\n\t}", "public function __construct($options = array()) {\n $this->setOptions($options);\n }" ]
[ "0.8195154", "0.79217416", "0.785508", "0.7719746", "0.75310856", "0.7501629", "0.7243645", "0.7240843", "0.723372", "0.7205982", "0.72027165", "0.7192137", "0.71620595", "0.7143902", "0.7118917", "0.70838684", "0.70469517", "0.70284235", "0.7027191", "0.70163244", "0.7005055", "0.70023835", "0.6940532", "0.69371265", "0.6898268", "0.68931574", "0.6867071", "0.6828237", "0.6811365", "0.68106824", "0.6788213", "0.67849565", "0.67652774", "0.6758229", "0.67515117", "0.67473376", "0.6716144", "0.6715694", "0.671249", "0.6707038", "0.6701112", "0.66991085", "0.6697441", "0.6694927", "0.6690223", "0.667495", "0.6657857", "0.6657857", "0.6657857", "0.6657857", "0.6657857", "0.6654993", "0.66442555", "0.66280496", "0.6617765", "0.6605477", "0.6598107", "0.6595109", "0.65939176", "0.6573156", "0.6567584", "0.6556958", "0.6555523", "0.6551974", "0.65450644", "0.65383875", "0.6534493", "0.6495944", "0.64951575", "0.6493295", "0.64839894", "0.6474383", "0.64733726", "0.64713186", "0.6464877", "0.64525086", "0.64470094", "0.6424688", "0.6424544", "0.6424544", "0.6423926", "0.6422608", "0.6416619", "0.64094734", "0.64038587", "0.6402386", "0.64013153", "0.6399107", "0.6397821", "0.6394641", "0.63937074", "0.63888323", "0.63877374", "0.6387629", "0.6385074", "0.6383062", "0.63818705", "0.6381577", "0.6367741", "0.63619334" ]
0.6849884
27
fix the edit_theme_options/manage_options bug using new WP 3.2 filter
function ajb_get_options_page_cap() { return 'edit_theme_options'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function filter_theme_options( $args ) {\r\n $args['settings'] = array_merge($args['settings'], $this->get_theme_option_args());\r\n \r\n return $args;\r\n }", "function bf_update_options() {\r\n\tglobal $bf_options;\r\n\tupdate_option(THEME_ID . '_options', maybe_serialize($bf_options));\r\n}", "function custom_theme_options()\n{\n\tif ( ! defined( 'UNCODE_SLIM' ) ) {\n\t\treturn;\n\t}\n\n\tglobal $wpdb, $uncode_colors, $uncode_post_types;\n\n\tif (!isset($uncode_post_types)) $uncode_post_types = uncode_get_post_types();\n\t/**\n\t * Get a copy of the saved settings array.\n\t */\n\t$saved_settings = get_option(ot_settings_id() , array());\n\n\t/**\n\t * Custom settings array that will eventually be\n\t * passes to the OptionTree Settings API Class.\n\t */\n\n\tif (!function_exists('ot_filter_measurement_unit_types'))\n\t{\n\t\tfunction ot_filter_measurement_unit_types($array, $field_id)\n\t\t{\n\t\t\treturn array(\n\t\t\t\t'px' => 'px',\n\t\t\t\t'%' => '%'\n\t\t\t);\n\t\t}\n\t}\n\n\tadd_filter('ot_measurement_unit_types', 'ot_filter_measurement_unit_types', 10, 2);\n\n\tfunction run_array_to($array, $key = '', $value = '')\n\t{\n\t\t$array[$key] = $value;\n\t\treturn $array;\n\t}\n\n\t$stylesArrayMenu = array(\n\t\tarray(\n\t\t\t'value' => 'light',\n\t\t\t'label' => esc_html__('Light', 'uncode') ,\n\t\t\t'src' => ''\n\t\t) ,\n\t\tarray(\n\t\t\t'value' => 'dark',\n\t\t\t'label' => esc_html__('Dark', 'uncode') ,\n\t\t\t'src' => ''\n\t\t)\n\t);\n\n\t$menus = get_terms( 'nav_menu', array( 'hide_empty' => true ) );\n\t$menus_array = array();\n\t$menus_array[] = array(\n\t\t'value' => '',\n\t\t'label' => esc_html__('Inherit', 'uncode')\n\t);\n\tforeach ($menus as $menu)\n\t{\n\t\t$menus_array[] = array(\n\t\t\t'value' => $menu->slug,\n\t\t\t'label' => $menu->name\n\t\t);\n\t}\n\n\t$uncodeblock = array(\n\t\t'value' => 'header_uncodeblock',\n\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t);\n\n\t$uncodeblocks = array(\n\t\tarray(\n\t\t\t'value' => '','label' => esc_html__('Inherit', 'uncode')\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'none','label' => esc_html__('None', 'uncode')\n\t\t)\n\t);\n\n\t$blocks_query = new WP_Query( 'post_type=uncodeblock&posts_per_page=-1&post_status=publish&orderby=title&order=ASC' );\n\n\tforeach ($blocks_query->posts as $block) {\n\t\t$uncodeblocks[] = array(\n\t\t\t'value' => $block->ID,\n\t\t\t'label' => $block->post_title,\n\t\t\t'postlink' => get_edit_post_link($block->ID),\n\t\t);\n\t}\n\n\tif ($blocks_query->post_count === 0) {\n\t\t$uncodeblocks[] = array(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('No Content Blocks found', 'uncode')\n\t\t);\n\t}\n\n\t$uncodeblock_404 = array(\n\t\t'id' => '_uncode_404_body',\n\t\t'label' => esc_html__('404 content', 'uncode') ,\n\t\t'desc' => esc_html__('Specify a content for the 404 page.', 'uncode'),\n\t\t'std' => '',\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Default', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'body_uncodeblock',\n\t\t\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t\t\t),\n\t\t),\n\t\t'section' => 'uncode_404_section',\n\t);\n\n\t$uncodeblocks_404 = array(\n\t\t'id' => '_uncode_404_body_block',\n\t\t'label' => esc_html__('404 Content Block', 'uncode') ,\n\t\t'desc' => esc_html__('Specify a content for the 404 page.', 'uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => $uncodeblocks,\n\t\t'section' => 'uncode_404_section',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_404_body:is(body_uncodeblock)',\n\t);\n\n\tif ( class_exists( 'RevSliderFront' ) )\n\t{\n\n\t\t$revslider = array(\n\t\t\t'value' => 'header_revslider',\n\t\t\t'label' => esc_html__('Revolution Slider', 'uncode') ,\n\t\t);\n\n\t\t$rs = $wpdb->get_results(\"SELECT id, title, alias FROM \" . $wpdb->prefix . \"revslider_sliders WHERE type != 'template' ORDER BY id ASC LIMIT 999\");\n\t\t$revsliders = array();\n\t\tif ($rs)\n\t\t{\n\t\t\tforeach ($rs as $slider)\n\t\t\t{\n\t\t\t\t$revsliders[] = array(\n\t\t\t\t\t'value' => $slider->alias,\n\t\t\t\t\t'label' => $slider->title,\n\t\t\t\t\t'postlink' => admin_url( 'admin.php?page=revslider&view=slider&id=' . $slider->id ),\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$revsliders[] = array(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('No Revolution Sliders found', 'uncode')\n\t\t\t);\n\t\t}\n\t}\n\telse $revslider = $revsliders = '';\n\n\tif ( class_exists( 'LS_Config' ) )\n\t{\n\n\t\t$layerslider = array(\n\t\t\t'value' => 'header_layerslider',\n\t\t\t'label' => esc_html__('LayerSlider', 'uncode') ,\n\t\t);\n\n\t\t$ls = $wpdb->get_results(\"SELECT id, name FROM \" . $wpdb->prefix . \"layerslider WHERE flag_deleted != '1' ORDER BY id ASC LIMIT 999\");\n\t\t$layersliders = array();\n\t\tif ($ls)\n\t\t{\n\t\t\tforeach ($ls as $slider)\n\t\t\t{\n\t\t\t\t$layersliders[] = array(\n\t\t\t\t\t'value' => $slider->id,\n\t\t\t\t\t'label' => $slider->name,\n\t\t\t\t\t'postlink' => admin_url( 'admin.php?page=layerslider&action=edit&id=' . $slider->id ),\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$layersliders[] = array(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('No LayerSliders found', 'uncode')\n\t\t\t);\n\t\t}\n\t}\n\telse $layerslider = $layersliders = '';\n\n\t$title_size = array(\n\t\tarray(\n\t\t\t'value' => 'h1',\n\t\t\t'label' => esc_html__('h1', 'uncode')\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'h2',\n\t\t\t'label' => esc_html__('h2', 'uncode'),\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'h3',\n\t\t\t'label' => esc_html__('h3', 'uncode'),\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'h4',\n\t\t\t'label' => esc_html__('h4', 'uncode'),\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'h5',\n\t\t\t'label' => esc_html__('h5', 'uncode'),\n\t\t),\n\t\tarray(\n\t\t\t'value' => 'h6',\n\t\t\t'label' => esc_html__('h6', 'uncode'),\n\t\t),\n\t);\n\n\t$font_sizes = ot_get_option('_uncode_heading_font_sizes');\n\tif (!empty($font_sizes)) {\n\t\tforeach ($font_sizes as $key => $value) {\n\t\t\t$title_size[] = array(\n\t\t\t\t'value' => $value['_uncode_heading_font_size_unique_id'],\n\t\t\t\t'label' => $value['title'],\n\t\t\t);\n\t\t}\n\t}\n\n\t$title_size[] = array(\n\t\t'value' => 'bigtext',\n\t\t'label' => esc_html__('BigText', 'uncode'),\n\t);\n\n\t$title_height = array(\n\t\tarray(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('Default CSS', \"uncode\")\n\t\t),\n\t);\n\n\t$font_heights = ot_get_option('_uncode_heading_font_heights');\n\tif (!empty($font_heights)) {\n\t\tforeach ($font_heights as $key => $value) {\n\t\t\t$title_height[] = array(\n\t\t\t\t'value' => $value['_uncode_heading_font_height_unique_id'],\n\t\t\t\t'label' => $value['title'],\n\t\t\t);\n\t\t}\n\t}\n\n\t$title_spacing = array(\n\t\tarray(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('Default CSS', \"uncode\")\n\t\t),\n\t);\n\n\t$btn_letter_spacing = $title_spacing;\n\t$btn_letter_spacing[] = array(\n\t\t'value' => 'uncode-fontspace-zero',\n\t\t'label' => esc_html__('Letter Spacing 0', \"uncode\")\n\t);\n\n\t$font_spacings = ot_get_option('_uncode_heading_font_spacings');\n\tif (!empty($font_spacings)) {\n\t\tforeach ($font_spacings as $key => $value) {\n\t\t\t$btn_letter_spacing[] = $title_spacing[] = array(\n\t\t\t\t'value' => $value['_uncode_heading_font_spacing_unique_id'],\n\t\t\t\t'label' => $value['title'],\n\t\t\t);\n\t\t}\n\t}\n\n\t$fonts = get_option('uncode_font_options');\n\t$title_font = array();\n\n\tif (isset($fonts['font_stack']) && $fonts['font_stack'] !== '[]')\n\t{\n\t\t$font_stack_string = $fonts['font_stack'];\n\t\t$font_stack = json_decode(str_replace('&quot;', '\"', $font_stack_string) , true);\n\n\t\tforeach ($font_stack as $font)\n\t\t{\n\t\t\tif ($font['source'] === 'Font Squirrel')\n\t\t\t{\n\t\t\t\t$variants = explode(',', $font['variants']);\n\t\t\t\t$label = (string)$font['family'] . ' - ';\n\t\t\t\t$weight = array();\n\t\t\t\tforeach ($variants as $variant)\n\t\t\t\t{\n\t\t\t\t\tif (strpos(strtolower($variant) , 'hairline') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 100;\n\t\t\t\t\t}\n\t\t\t\t\telse if (strpos(strtolower($variant) , 'light') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 200;\n\t\t\t\t\t}\n\t\t\t\t\telse if (strpos(strtolower($variant) , 'regular') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 400;\n\t\t\t\t\t}\n\t\t\t\t\telse if (strpos(strtolower($variant) , 'semibold') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 500;\n\t\t\t\t\t}\n\t\t\t\t\telse if (strpos(strtolower($variant) , 'bold') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 600;\n\t\t\t\t\t}\n\t\t\t\t\telse if (strpos(strtolower($variant) , 'black') !== false)\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 800;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$weight[] = 400;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$label.= implode(',', $weight);\n\t\t\t\t$title_font[] = array(\n\t\t\t\t\t'value' => urlencode((string)$font['family']),\n\t\t\t\t\t'label' => $label\n\t\t\t\t);\n\t\t\t}\n\t\t\telse if ($font['source'] === 'Google Web Fonts')\n\t\t\t{\n\t\t\t\t$label = (string)$font['family'] . ' - ' . $font['variants'];\n\t\t\t\t$title_font[] = array(\n\t\t\t\t\t'value' => urlencode((string)$font['family']),\n\t\t\t\t\t'label' => $label\n\t\t\t\t);\n\t\t\t}\n\t\t\telse if ($font['source'] === 'Adobe Fonts' || $font['source'] === 'Typekit' )\n\t\t\t{\n\t\t\t\t$label = (string)$font['family'] . ' - ';\n\t\t\t\t$variants = explode(',', $font['variants']);\n\t\t\t\tforeach ($variants as $key => $variant) {\n\t\t\t\t\tif ( $variants[$key] !== '' ) {\n\t\t\t\t\t\tpreg_match(\"|\\d+|\", $variants[$key], $weight);\n\t\t\t\t\t\t$variants[$key] = $weight[0] . '00';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$label.= implode(',', $variants);\n\t\t\t\t$title_font[] = array(\n\t\t\t\t\t'value' => urlencode(str_replace('\"', '', (string)$font['stub'])),\n\t\t\t\t\t'label' => $label\n\t\t\t\t);\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$title_font[] = array(\n\t\t\t\t\t'value' => urlencode((string)$font['family']),\n\t\t\t\t\t'label' => (string)$font['family']\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\t}\n\telse\n\t{\n\t\t$title_font = array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('No fonts activated.', \"uncode\"),\n\t\t\t)\n\t\t);\n\t}\n\n\t$title_font[] = array(\n\t\t'value' => 'manual',\n\t\t'label' => esc_html__('Manually entered','uncode')\n\t);\n\n\t$custom_fonts = array(\n\t\tarray(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('Default CSS', \"uncode\"),\n\t\t)\n\t);\n\n\t$custom_fonts_array = ot_get_option('_uncode_font_groups');\n\tif (!empty($custom_fonts_array)) {\n\t\tforeach ($custom_fonts_array as $key => $value) {\n\t\t\t$custom_fonts[] = array(\n\t\t\t\t'value' => $value['_uncode_font_group_unique_id'],\n\t\t\t\t'label' => $value['title'],\n\t\t\t);\n\t\t}\n\t}\n\n\t$title_weight = array(\n\t\tarray(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('Default CSS', \"uncode\"),\n\t\t),\n\t\tarray(\n\t\t\t'value' => 100,\n\t\t\t'label' => '100',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 200,\n\t\t\t'label' => '200',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 300,\n\t\t\t'label' => '300',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 400,\n\t\t\t'label' => '400',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 500,\n\t\t\t'label' => '500',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 600,\n\t\t\t'label' => '600',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 700,\n\t\t\t'label' => '700',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 800,\n\t\t\t'label' => '800',\n\t\t),\n\t\tarray(\n\t\t\t'value' => 900,\n\t\t\t'label' => '900',\n\t\t)\n\t);\n\n\t$menu_section_title = array(\n\t\t'id' => '_uncode_%section%_menu_block_title',\n\t\t'label' => ' <i class=\"fa fa-menu\"></i> ' . esc_html__('Menu', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$menu = array(\n\t\t'id' => '_uncode_%section%_menu',\n\t\t'label' => esc_html__('Menu', 'uncode') ,\n\t\t'desc' => esc_html__('Override the primary menu created in \\'Appearance -> Menus\\'.','uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => $menus_array,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$menu_width = array(\n\t\t'id' => '_uncode_%section%_menu_width',\n\t\t'label' => esc_html__('Menu width', 'uncode') ,\n\t\t'desc' => esc_html__('Override the menu width.', 'uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Inherit', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'full',\n\t\t\t\t'label' => esc_html__('Full', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'limit',\n\t\t\t\t'label' => esc_html__('Limit', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$menu_opaque = array(\n\t\t'id' => '_uncode_%section%_menu_opaque',\n\t\t'label' => esc_html__('Remove transparency', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Override to remove the transparency eventually declared in \\'Customize -> Light/Dark skin\\'.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$menu_no_padding = array(\n\t\t'id' => '_uncode_%section%_menu_no_padding',\n\t\t'label' => esc_html__('Remove menu content padding', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Remove the additional menu padding in the header.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$menu_no_padding_mobile = array(\n\t\t'id' => '_uncode_%section%_menu_no_padding_mobile',\n\t\t'label' => esc_html__('Remove menu content padding on mobile', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Remove the additional menu padding in the header on mobile.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$title_archive_custom_activate = array(\n\t\t'id' => '_uncode_%section%_custom_title_activate',\n\t\t'label' => esc_html__('Activate custom title and subtitle', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Activate this to enable the custom title and subtitle.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$title_archive_custom_text = array(\n\t\t'id' => '_uncode_%section%_custom_title_text',\n\t\t'label' => esc_html__('Custom title', 'uncode') ,\n\t\t'type' => 'text',\n\t\t'desc' => esc_html__('Insert your custom main archive page title.', 'uncode') ,\n\t\t'std' => '',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_custom_title_activate:is(on)',\n\t);\n\n\t$subtitle_archive_custom_text = array(\n\t\t'id' => '_uncode_%section%_custom_subtitle_text',\n\t\t'label' => esc_html__('Custom subtitle', 'uncode') ,\n\t\t'type' => 'text',\n\t\t'desc' => esc_html__('Insert your custom main archive page subtitle.', 'uncode') ,\n\t\t'std' => '',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_custom_title_activate:is(on)',\n\t);\n\n\t$header_section_title = array(\n\t\t'id' => '_uncode_%section%_header_block_title',\n\t\t'label' => '<i class=\"fa fa-columns2\"></i> ' . esc_html__('Header', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_type = array(\n\t\t'id' => '_uncode_%section%_header',\n\t\t'label' => esc_html__('Type', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the header type.', 'uncode'),\n\t\t'std' => 'none',\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => 'none',\n\t\t\t\t'label' => esc_html__('Select…', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header_basic',\n\t\t\t\t'label' => esc_html__('Basic', 'uncode') ,\n\t\t\t) ,\n\t\t\t$uncodeblock,\n\t\t\t$revslider,\n\t\t\t$layerslider,\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_uncode_block = array(\n\t\t'id' => '_uncode_%section%_blocks',\n\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the Content Block.', 'uncode') ,\n\t\t'type' => 'custom-post-type-select',\n\t\t'condition' => '_uncode_%section%_header:is(header_uncodeblock)',\n\t\t'operator' => 'or',\n\t\t'post_type' => 'uncodeblock',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_revslider = array(\n\t\t'id' => '_uncode_%section%_revslider',\n\t\t'label' => esc_html__('Revslider', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the RevSlider.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_revslider)',\n\t\t'operator' => 'or',\n\t\t'choices' => $revsliders,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_layerslider = array(\n\t\t'id' => '_uncode_%section%_layerslider',\n\t\t'label' => esc_html__('LayerSlider', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the LayerSlider.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_layerslider)',\n\t\t'operator' => 'or',\n\t\t'choices' => $layersliders,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title = array(\n\t\t'label' => esc_html__('Title in header', 'uncode') ,\n\t\t'id' => '_uncode_%section%_header_title',\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Activate to show title in the header.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_title_text = array(\n\t\t'id' => '_uncode_%section%_header_title_text',\n\t\t'label' => esc_html__('Custom text', 'uncode') ,\n\t\t'desc' => esc_html__('Add custom text for the header. Every newline in the field is a new line in the title.', 'uncode') ,\n\t\t'type' => 'textarea-simple',\n\t\t'rows' => '15',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t);\n\n\t$header_style = array(\n\t\t'id' => '_uncode_%section%_header_style',\n\t\t'label' => esc_html__('Skin', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the header text skin.', 'uncode') ,\n\t\t'std' => 'light',\n\t\t'type' => 'select',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'and',\n\t\t'choices' => $stylesArrayMenu\n\t);\n\n\t$header_width = array(\n\t\t'id' => '_uncode_%section%_header_width',\n\t\t'label' => esc_html__('Header width', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Inherit', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'full',\n\t\t\t\t'label' => esc_html__('Full', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'limit',\n\t\t\t\t'label' => esc_html__('Limit', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'desc' => esc_html__('Override the header width.', 'uncode') ,\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:contains(header)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_content_width = array(\n\t\t'id' => '_uncode_%section%_header_content_width',\n\t\t'label' => esc_html__('Content full width', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Activate to expand the header content to full width.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'and',\n\t);\n\n\t$header_custom_width = array(\n\t\t'id' => '_uncode_%section%_header_custom_width',\n\t\t'label' => esc_html__('Custom inner width','uncode'),\n\t\t'desc' => esc_html__('Adjust the inner content width in %.', 'uncode') ,\n\t\t'std' => '100',\n\t\t'type' => 'numeric-slider',\n\t\t'min_max_step' => '0,100,1',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'and',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_align = array(\n\t\t'id' => '_uncode_%section%_header_align',\n\t\t'label' => esc_html__('Content alignment', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the text/content alignment.', 'uncode') ,\n\t\t'std' => 'center',\n\t\t'type' => 'select',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => 'left',\n\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'center',\n\t\t\t\t'label' => esc_html__('Center', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'right',\n\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t)\n\t\t)\n\t);\n\n\t$header_height = array(\n\t\t'id' => '_uncode_%section%_header_height',\n\t\t'label' => esc_html__('Height', 'uncode') ,\n\t\t'desc' => esc_html__('Define the height of the header in px or in % (relative to the window height).', 'uncode') ,\n\t\t'type' => 'measurement',\n\t\t'std' => array(\n\t\t\t'60',\n\t\t\t'%'\n\t\t) ,\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_min_height = array(\n\t\t'id' => '_uncode_%section%_header_min_height',\n\t\t'label' => esc_html__('Minimal height', 'uncode') ,\n\t\t'desc' => esc_html__('Enter a minimun height for the header in pixel.', 'uncode') ,\n\t\t'type' => 'text',\n\t\t'std' => '300',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_position = array(\n\t\t'id' => '_uncode_%section%_header_position',\n\t\t'label' => esc_html__('Position', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the position of the header content inside the container.', 'uncode') ,\n\t\t'std' => 'header-center header-middle',\n\t\t'type' => 'select',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => 'header-left header-top',\n\t\t\t\t'label' => esc_html__('Left Top', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-left header-center',\n\t\t\t\t'label' => esc_html__('Left Center', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-left header-bottom',\n\t\t\t\t'label' => esc_html__('Left Bottom', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-center header-top',\n\t\t\t\t'label' => esc_html__('Center Top', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-center header-middle',\n\t\t\t\t'label' => esc_html__('Center Center', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-center header-bottom',\n\t\t\t\t'label' => esc_html__('Center Bottom', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-right header-top',\n\t\t\t\t'label' => esc_html__('Right Top', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-right header-center',\n\t\t\t\t'label' => esc_html__('Right Center', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'header-right header-bottom',\n\t\t\t\t'label' => esc_html__('Right Bottom', 'uncode') ,\n\t\t\t) ,\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_font = array(\n\t\t'id' => '_uncode_%section%_header_title_font',\n\t\t'label' => esc_html__('Title font family', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the font for the title.', 'uncode') ,\n\t\t'std' => 'font-555555',\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => $custom_fonts,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_size = array(\n\t\t'id' => '_uncode_%section%_header_title_size',\n\t\t'label' => esc_html__('Title font size', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the font size for the title.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => $title_size,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_height = array(\n\t\t'id' => '_uncode_%section%_header_title_height',\n\t\t'label' => esc_html__('Title line height', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the line height for the title.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => $title_height,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_spacing = array(\n\t\t'id' => '_uncode_%section%_header_title_spacing',\n\t\t'label' => esc_html__('Title letter spacing', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the letter spacing for the title.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => $title_spacing,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_weight = array(\n\t\t'id' => '_uncode_%section%_header_title_weight',\n\t\t'label' => esc_html__('Title font weight', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the font weight for the title.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => $title_weight,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_title_italic = array(\n\t\t'id' => '_uncode_%section%_header_title_italic',\n\t\t'label' => esc_html__('Title italic', 'uncode') ,\n\t\t'desc' => esc_html__('Activate the font style italic for the title.', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t);\n\n\t$header_title_transform = array(\n\t\t'id' => '_uncode_%section%_header_title_transform',\n\t\t'label' => esc_html__('Title text transform', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the title text transformation.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Default CSS', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'uppercase',\n\t\t\t\t'label' => esc_html__('Uppercase', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'lowercase',\n\t\t\t\t'label' => esc_html__('Lowercase', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'capitalize',\n\t\t\t\t'label' => esc_html__('Capitalize', 'uncode') ,\n\t\t\t) ,\n\t\t)\n\t);\n\n\t$header_text_animation = array(\n\t\t'id' => '_uncode_%section%_header_text_animation',\n\t\t'label' => esc_html__('Text animation', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the entrance animation of the title text.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on)',\n\t\t'operator' => 'and',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Select…', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'top-t-bottom',\n\t\t\t\t'label' => esc_html__('Top to bottom', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'left-t-right',\n\t\t\t\t'label' => esc_html__('Left to right', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'right-t-left',\n\t\t\t\t'label' => esc_html__('Right to left', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'bottom-t-top',\n\t\t\t\t'label' => esc_html__('Bottom to top', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'zoom-in',\n\t\t\t\t'label' => esc_html__('Zoom in', 'uncode') ,\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'value' => 'zoom-out',\n\t\t\t\t'label' => esc_html__('Zoom out', 'uncode') ,\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'value' => 'alpha-anim',\n\t\t\t\t'label' => esc_html__('Alpha', 'uncode') ,\n\t\t\t)\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_animation_delay = array(\n\t\t'id' => '_uncode_%section%_header_animation_delay',\n\t\t'label' => esc_html__('Animation delay', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the entrance animation delay of the title text in milliseconds.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on),_uncode_%section%_header_text_animation:not()',\n\t\t'operator' => 'and',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('None', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '100',\n\t\t\t\t'label' => esc_html__('ms 100', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '200',\n\t\t\t\t'label' => esc_html__('ms 200', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '300',\n\t\t\t\t'label' => esc_html__('ms 300', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '400',\n\t\t\t\t'label' => esc_html__('ms 400', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '500',\n\t\t\t\t'label' => esc_html__('ms 500', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '600',\n\t\t\t\t'label' => esc_html__('ms 600', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '700',\n\t\t\t\t'label' => esc_html__('ms 700', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '800',\n\t\t\t\t'label' => esc_html__('ms 800', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '900',\n\t\t\t\t'label' => esc_html__('ms 900', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1000',\n\t\t\t\t'label' => esc_html__('ms 1000', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1100',\n\t\t\t\t'label' => esc_html__('ms 1100', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1200',\n\t\t\t\t'label' => esc_html__('ms 1200', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1300',\n\t\t\t\t'label' => esc_html__('ms 1300', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1400',\n\t\t\t\t'label' => esc_html__('ms 1400', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1500',\n\t\t\t\t'label' => esc_html__('ms 1500', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1600',\n\t\t\t\t'label' => esc_html__('ms 1600', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1700',\n\t\t\t\t'label' => esc_html__('ms 1700', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1800',\n\t\t\t\t'label' => esc_html__('ms 1800', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1900',\n\t\t\t\t'label' => esc_html__('ms 1900', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '2000',\n\t\t\t\t'label' => esc_html__('ms 2000', 'uncode') ,\n\t\t\t) ,\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_animation_speed = array(\n\t\t'id' => '_uncode_%section%_header_animation_speed',\n\t\t'label' => esc_html__('Animation speed', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the entrance animation speed of the title text in milliseconds.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header_title:is(on),_uncode_%section%_header_text_animation:not()',\n\t\t'operator' => 'and',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Default (400)', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '100',\n\t\t\t\t'label' => esc_html__('ms 100', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '200',\n\t\t\t\t'label' => esc_html__('ms 200', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '300',\n\t\t\t\t'label' => esc_html__('ms 300', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '400',\n\t\t\t\t'label' => esc_html__('ms 400', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '500',\n\t\t\t\t'label' => esc_html__('ms 500', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '600',\n\t\t\t\t'label' => esc_html__('ms 600', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '700',\n\t\t\t\t'label' => esc_html__('ms 700', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '800',\n\t\t\t\t'label' => esc_html__('ms 800', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '900',\n\t\t\t\t'label' => esc_html__('ms 900', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '1000',\n\t\t\t\t'label' => esc_html__('ms 1000', 'uncode') ,\n\t\t\t) ,\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$header_featured = array(\n\t\t'label' => esc_html__('Featured media in header', 'uncode') ,\n\t\t'id' => '_uncode_%section%_header_featured',\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Activate to use the featured image in the header.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_background = array(\n\t\t'id' => '_uncode_%section%_header_background',\n\t\t'label' => esc_html__('Background', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the background media and color.', 'uncode') ,\n\t\t'type' => 'background',\n\t\t'std' => array(\n\t\t\t'background-color' => 'color-gyho',\n\t\t\t'background-repeat' => '',\n\t\t\t'background-attachment' => '',\n\t\t\t'background-position' => '',\n\t\t\t'background-size' => '',\n\t\t\t'background-image' => '',\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_parallax = array(\n\t\t'id' => '_uncode_%section%_header_parallax',\n\t\t'label' => esc_html__('Parallax', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'desc' => esc_html__('Activate the background parallax effect.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_kburns = array(\n\t\t'id' => '_uncode_%section%_header_kburns',\n\t\t'label' => esc_html__('Zoom Effect', 'uncode') ,\n\t\t'desc' => esc_html__('Select the background zoom effect you prefer.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('None', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'on',\n\t\t\t\t'label' => esc_html__('Ken Burns', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'zoom',\n\t\t\t\t'label' => esc_html__('Zoom Out', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_overlay_color = array(\n\t\t'id' => '_uncode_%section%_header_overlay_color',\n\t\t'label' => esc_html__('Overlay color', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the overlay background color.', 'uncode') ,\n\t\t'type' => 'uncode_color',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_overlay_color_alpha = array(\n\t\t'id' => '_uncode_%section%_header_overlay_color_alpha',\n\t\t'label' => esc_html__('Overlay color opacity', 'uncode') ,\n\t\t'desc' => esc_html__('Set the overlay opacity.', 'uncode') ,\n\t\t'std' => '100',\n\t\t'min_max_step' => '0,100,1',\n\t\t'type' => 'numeric-slider',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_scroll_opacity = array(\n\t\t'id' => '_uncode_%section%_header_scroll_opacity',\n\t\t'label' => esc_html__('Scroll opacity', 'uncode') ,\n\t\t'desc' => esc_html__('Activate alpha animation when scrolling down.', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:is(header_basic),_uncode_%section%_header:is(header_uncodeblock)',\n\t\t'operator' => 'or',\n\t);\n\n\t$header_scrolldown = array(\n\t\t'id' => '_uncode_%section%_header_scrolldown',\n\t\t'label' => esc_html__('Scroll down arrow', 'uncode') ,\n\t\t'desc' => esc_html__('Activate the scroll down arrow button.', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'std' => 'off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_header:not(none)',\n\t\t'operator' => 'or',\n\t);\n\n\t$show_breadcrumb = array(\n\t\t'id' => '_uncode_%section%_breadcrumb',\n\t\t'label' => esc_html__('Show breadcrumb', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the navigation breadcrumb.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$breadcrumb_align = array(\n\t\t'id' => '_uncode_%section%_breadcrumb_align',\n\t\t'label' => esc_html__('Breadcrumb align', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the breadcrumb alignment','uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'center',\n\t\t\t\t'label' => esc_html__('Center', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'left',\n\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_breadcrumb:is(on)',\n\t\t'operator' => 'or',\n\t);\n\n\t$show_title = array(\n\t\t'id' => '_uncode_%section%_title',\n\t\t'label' => esc_html__('Show title', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the title in the content area.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'operator' => 'or'\n\t);\n\n\t$remove_pagination = array(\n\t\t'id' => '_uncode_%section%_remove_pagination',\n\t\t'label' => esc_html__('Remove pagination', 'uncode') ,\n\t\t'desc' => esc_html__('Activate this to remove the pagination (useful when you use a custom Content Block with Pagination or Load More options).', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'operator' => 'or'\n\t);\n\n\t$products_per_page = array(\n\t\t'id' => '_uncode_%section%_ppp',\n\t\t'label' => esc_html__('Number of products', 'uncode') ,\n\t\t'desc' => esc_html__('Set the number of items to display on product archives. \\'Inherit\\' inherits the WordPress Settings > Readings > Blog Number of Posts', 'uncode') ,\n\t\t'std' => '0',\n\t\t'min_max_step' => '0,100,1',\n\t\t'type' => 'numeric-slider',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$show_media = array(\n\t\t'id' => '_uncode_%section%_media',\n\t\t'label' => esc_html__('Show media', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the medias in the content area.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$show_featured_media = array(\n\t\t'id' => '_uncode_%section%_featured_media',\n\t\t'label' => esc_html__('Show featured image', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the featured image in the content area.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'condition' => '_uncode_%section%_media:not(on)',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$show_tags = array(\n\t\t'id' => '_uncode_%section%_tags',\n\t\t'label' => esc_html__('Show tags', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the tags and choose visbility by post to post bases.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$show_tags_align = array(\n\t\t'id' => '_uncode_%section%_tags_align',\n\t\t'label' => esc_html__('Tags alignment', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the tags alignment.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => 'left',\n\t\t\t\t'label' => esc_html__('Left align', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'center',\n\t\t\t\t'label' => esc_html__('Center align', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'right',\n\t\t\t\t'label' => esc_html__('Right align', 'uncode') ,\n\t\t\t\t'src' => ''\n\t\t\t)\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_tags:is(on)',\n\t\t'operator' => 'or',\n\t);\n\n\t$show_comments = array(\n\t\t'id' => '_uncode_%section%_comments',\n\t\t'label' => esc_html__('Show comments', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the comments and choose visbility by post to post bases.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$show_share = array(\n\t\t'id' => '_uncode_%section%_share',\n\t\t'label' => esc_html__('Show share', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the share module.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$image_layout = array(\n\t\t'id' => '_uncode_%section%_image_layout',\n\t\t'label' => esc_html__('Media layout', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the layout mode for the product images section.', 'uncode') ,\n\t\t'std' => '',\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Standard', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'stack',\n\t\t\t\t'label' => esc_html__('Stack', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$media_size = array(\n\t\t'id' => '_uncode_%section%_media_size',\n\t\t'label' => esc_html__('Media layout size', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the size of the media layout area.', 'uncode') ,\n\t\t'std' => '6',\n\t\t'min_max_step' => '1,11,1',\n\t\t'type' => 'numeric-slider',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$enable_sticky_desc = array(\n\t\t'id' => '_uncode_%section%_sticky_desc',\n\t\t'label' => esc_html__('Sticky content', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to enable sticky effect for product description.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_image_layout:is(stack)',\n\t);\n\n\t$enable_woo_zoom = array(\n\t\t'id' => '_uncode_%section%_enable_zoom',\n\t\t'label' => esc_html__('Zoom', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to enable drag zoom effect on product image.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$thumb_cols = array(\n\t\t'id' => '_uncode_%section%_thumb_cols',\n\t\t'label' => esc_html__('Thumbnails columns', 'uncode') ,\n\t\t'desc' => esc_html__('Specify how many columns to display for your product gallery thumbs.', 'uncode') ,\n\t\t'std' => '',\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '2',\n\t\t\t\t'label' => '2',\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => '3',\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '4',\n\t\t\t\t'label' => '4',\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '5',\n\t\t\t\t'label' => '5',\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '6',\n\t\t\t\t'label' => '6',\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_image_layout:is()',\n\t);\n\n\t$enable_woo_slider = array(\n\t\t'id' => '_uncode_%section%_enable_slider',\n\t\t'label' => esc_html__('Thumbnails carousel', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to enable carousel slider when you click gallery thumbs.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_image_layout:is()',\n\t);\n\n\t$body_section_title = array(\n\t\t'id' => '_uncode_%section%_body_title',\n\t\t'label' => '<i class=\"fa fa-layout\"></i> ' . esc_html__('Content', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_uncode_block = array(\n\t\t'id' => '_uncode_%section%_content_block',\n\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t\t'desc' => esc_html__('Define the Content Block to use. NB. Select \"Inherit\" to use the default template.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => $uncodeblocks,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_uncode_block_before = array(\n\t\t'id' => '_uncode_%section%_content_block_before',\n\t\t'label' => esc_html__('Content Block - Before Content', 'uncode') ,\n\t\t'desc' => esc_html__('Define the Content Block to use.', 'uncode') ,\n\t\t'type' => 'custom-post-type-select',\n\t\t'post_type' => 'uncodeblock',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_uncode_block_after_pre = array(\n\t\t'id' => '_uncode_%section%_content_block_after_pre',\n\t\t'label' => esc_html__('After Content (ex: Author Profile)', 'uncode') ,\n\t\t'desc' => esc_html__('Define the Content Block to use.', 'uncode') ,\n\t\t'type' => 'custom-post-type-select',\n\t\t'post_type' => 'uncodeblock',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_uncode_block_after = array(\n\t\t'id' => '_uncode_%section%_content_block_after',\n\t\t'label' => esc_html__('After Content (ex: Related Posts)', 'uncode') ,\n\t\t'desc' => esc_html__('Define the Content Block to use.', 'uncode') ,\n\t\t'type' => 'custom-post-type-select',\n\t\t'post_type' => 'uncodeblock',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_layout_width = array(\n\t\t'id' => '_uncode_%section%_layout_width',\n\t\t'label' => esc_html__('Content width', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the content width.', 'uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Inherit', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'full',\n\t\t\t\t'label' => esc_html__('Full', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'limit',\n\t\t\t\t'label' => esc_html__('Limit', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_layout_width_custom = array(\n\t\t'id' => '_uncode_%section%_layout_width_custom',\n\t\t'label' => esc_html__('Custom width', 'uncode') ,\n\t\t'desc' => esc_html__('Define the custom width for the content area in px or in %. This option takes effect with normal contents (not Page Builder).', 'uncode') ,\n\t\t'type' => 'measurement',\n\t\t'condition' => '_uncode_%section%_layout_width:is(limit)',\n\t\t'operator' => 'or',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_single_post_width = array(\n\t\t'id' => '_uncode_%section%_single_width',\n\t\t'label' => esc_html__('Single post width', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the single post width from 1 to 12.', 'uncode'),\n\t\t'type' => 'select',\n\t\t'std' => '4',\n\t\t'condition' => '_uncode_%section%_content_block:is(),_uncode_%section%_content_block:is(none)',\n\t\t'operator' => 'or',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '1',\n\t\t\t\t'label' => '1' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '2',\n\t\t\t\t'label' => '2' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '3',\n\t\t\t\t'label' => '3' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '4',\n\t\t\t\t'label' => '4' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '5',\n\t\t\t\t'label' => '5' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '6',\n\t\t\t\t'label' => '6' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '7',\n\t\t\t\t'label' => '7' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '8',\n\t\t\t\t'label' => '8' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '9',\n\t\t\t\t'label' => '9' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '10',\n\t\t\t\t'label' => '10' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '11',\n\t\t\t\t'label' => '11' ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => '12',\n\t\t\t\t'label' => '12' ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$body_single_text_lenght = array(\n\t\t'id' => '_uncode_%section%_single_text_length',\n\t\t'label' => esc_html__('Single teaser text length', 'uncode') ,\n\t\t'desc' => esc_html__('Enter the number of words you want for the teaser. If nothing in entered the full content will be showed.', 'uncode') ,\n\t\t'type' => 'text',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_content_block:is(),_uncode_%section%_content_block:is(none)',\n\t\t'operator' => 'or',\n\t);\n\n\t$sidebar_section_title = array(\n\t\t'id' => '_uncode_%section%_sidebar_title',\n\t\t'label' => '<i class=\"fa fa-content-right\"></i> ' . esc_html__('Sidebar', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$sidebar_activate = array(\n\t\t'id' => '_uncode_%section%_activate_sidebar',\n\t\t'label' => esc_html__('Activate the sidebar', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the sidebar.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$sidebar_widget = array(\n\t\t'id' => '_uncode_%section%_sidebar',\n\t\t'label' => esc_html__('Sidebar', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the sidebar.', 'uncode') ,\n\t\t'type' => 'sidebar-select',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t);\n\n\t$sidebar_position = array(\n\t\t'id' => '_uncode_%section%_sidebar_position',\n\t\t'label' => esc_html__('Position', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the position of the sidebar.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => 'sidebar_right',\n\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'sidebar_left',\n\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$sidebar_size = array(\n\t\t'id' => '_uncode_%section%_sidebar_size',\n\t\t'label' => esc_html__('Size', 'uncode') ,\n\t\t'desc' => esc_html__('Set the size of the sidebar.', 'uncode') ,\n\t\t'std' => '4',\n\t\t'min_max_step' => '1,11,1',\n\t\t'type' => 'numeric-slider',\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$sidebar_sticky = array(\n\t\t'id' => '_uncode_%section%_sidebar_sticky',\n\t\t'label' => esc_html__('Sticky sidebar', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to have a sticky sidebar.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$sidebar_style = array(\n\t\t'id' => '_uncode_%section%_sidebar_style',\n\t\t'label' => esc_html__('Skin', 'uncode') ,\n\t\t'desc' => esc_html__('Override the sidebar text skin color.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Inherit', \"uncode\") ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'light',\n\t\t\t\t'label' => esc_html__('Light', \"uncode\") ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'dark',\n\t\t\t\t'label' => esc_html__('Dark', \"uncode\") ,\n\t\t\t)\n\t\t),\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t);\n\n\t$sidebar_bgcolor = array(\n\t\t'id' => '_uncode_%section%_sidebar_bgcolor',\n\t\t'label' => esc_html__('Background color', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the sidebar background color.', 'uncode') ,\n\t\t'type' => 'uncode_color',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'condition' => '_uncode_%section%_activate_sidebar:not(off)',\n\t);\n\n\t$sidebar_fill = array(\n\t\t'id' => '_uncode_%section%_sidebar_fill',\n\t\t'label' => esc_html__('Sidebar filling space', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to remove padding around the sidebar and fill the height.', 'uncode') ,\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'std' => 'off',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_%section%_sidebar_bgcolor:not(),_uncode_%section%_activate_sidebar:not(off)',\n\t);\n\n\t$navigation_section_title = array(\n\t\t'id' => '_uncode_%section%_navigation_title',\n\t\t'label' => '<i class=\"fa fa-location\"></i> ' . esc_html__('Navigation', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$navigation_activate = array(\n\t\t'id' => '_uncode_%section%_navigation_activate',\n\t\t'label' => esc_html__('Navigation bar', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the navigation bar.', 'uncode') ,\n\t\t'std' => 'on',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$navigation_page_index = array(\n\t\t'id' => '_uncode_%section%_navigation_index',\n\t\t'label' => esc_html__('Navigation index', 'uncode') ,\n\t\t'desc' => esc_html__('Specify the page you want to use as index.', 'uncode'),\n\t\t'type' => 'page-select',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_%section%_navigation_activate:not(off)',\n\t);\n\n\t$navigation_index_label = array(\n\t\t'id' => '_uncode_%section%_navigation_index_label',\n\t\t'label' => esc_html__('Index custom label', 'uncode') ,\n\t\t'desc' => esc_html__('Enter a custom label for the index button.', 'uncode') ,\n\t\t'type' => 'text',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_%section%_navigation_activate:not(off)',\n\t);\n\n\t$navigation_nextprev_title = array(\n\t\t'id' => '_uncode_%section%_navigation_nextprev_title',\n\t\t'label' => esc_html__('Navigation titles', 'uncode') ,\n\t\t'desc' => esc_html__('Activate to show the next/prev post title.', 'uncode') ,\n\t\t'std' => 'off',\n\t\t'type' => 'on-off',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'operator' => 'and',\n\t\t'condition' => '_uncode_%section%_navigation_activate:not(off)',\n\t);\n\n\t$footer_section_title = array(\n\t\t'id' => '_uncode_%section%_footer_block_title',\n\t\t'label' => '<i class=\"fa fa-ellipsis\"></i> ' . esc_html__('Footer', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$footer_uncode_block = array(\n\t\t'id' => '_uncode_%section%_footer_block',\n\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t\t'desc' => esc_html__('Override the Content Block.', 'uncode') ,\n\t\t'type' => 'select',\n\t\t'choices' => $uncodeblocks,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$footer_width = array(\n\t\t'id' => '_uncode_%section%_footer_width',\n\t\t'label' => esc_html__('Footer width', 'uncode') ,\n\t\t'desc' => esc_html__('Override the footer width.' ,'uncode'),\n\t\t'type' => 'select',\n\t\t'choices' => array(\n\t\t\tarray(\n\t\t\t\t'value' => '',\n\t\t\t\t'label' => esc_html__('Inherit', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'full',\n\t\t\t\t'label' => esc_html__('Full', 'uncode') ,\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'value' => 'limit',\n\t\t\t\t'label' => esc_html__('Limit', 'uncode') ,\n\t\t\t) ,\n\t\t) ,\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$custom_fields_section_title = array(\n\t\t'id' => '_uncode_%section%_cf_title',\n\t\t'label' => '<i class=\"fa fa-pencil3\"></i> ' . esc_html__('Custom fields', 'uncode') ,\n\t\t'desc' => '' ,\n\t\t'type' => 'textblock-titled',\n\t\t'class' => 'section-title',\n\t\t'section' => 'uncode_%section%_section',\n\t);\n\n\t$custom_fields_list = array(\n\t\t'id' => '_uncode_%section%_custom_fields',\n\t\t'class' => 'uncode-custom-fields-list',\n\t\t'label' => esc_html__('Custom fields', 'uncode') ,\n\t\t'desc' => esc_html__('Create here all the custom fields that can be used inside the posts module.', 'uncode') ,\n\t\t'type' => 'list-item',\n\t\t'section' => 'uncode_%section%_section',\n\t\t'settings' => array(\n\t\t\tarray(\n\t\t\t\t'id' => '_uncode_cf_unique_id',\n\t\t\t\t'class' => 'unique_id',\n\t\t\t\t'std' => 'detail-',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'label' => esc_html__('Unique custom field ID','uncode') ,\n\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t),\n\t\t)\n\t);\n\n\t$portfolio_cpt_name = ot_get_option('_uncode_portfolio_cpt');\n\tif ($portfolio_cpt_name == '') $portfolio_cpt_name = 'portfolio';\n\n\t$cpt_single_sections = array();\n\t$cpt_index_sections = array();\n\t$cpt_single_options = array();\n\t$cpt_index_options = array();\n\n\tif (count($uncode_post_types) > 0) {\n\t\tforeach ($uncode_post_types as $key => $value) {\n\t\t\tif ($value !== 'portfolio' && $value !== 'product') {\n\t\t\t\t$cpt_obj = get_post_type_object($value);\n\n\t\t\t\tif ( is_object($cpt_obj) ) {\n\t\t\t\t\t$cpt_name = $cpt_obj->labels->name;\n\t\t\t\t\t$cpt_sing_name = $cpt_obj->labels->singular_name;\n\t\t\t\t\t$cpt_single_sections[] = array(\n\t\t\t\t\t\t'id' => 'uncode_'.$value.'_section',\n\t\t\t\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-paper\"></i> ' . ucfirst($cpt_sing_name) . '</span>',\n\t\t\t\t\t\t'group' => esc_html__('Single', 'uncode')\n\t\t\t\t\t);\n\t\t\t\t\t$cpt_index_sections[] = array(\n\t\t\t\t\t\t'id' => 'uncode_'.$value.'_index_section',\n\t\t\t\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . ucfirst($cpt_name) . '</span>',\n\t\t\t\t\t\t'group' => esc_html__('Archives', 'uncode')\n\t\t\t\t\t);\n\t\t\t\t} elseif ( $value == 'author' ) {\n\t\t\t\t\t$cpt_index_sections[] = array(\n\t\t\t\t\t\t'id' => 'uncode_'.$value.'_index_section',\n\t\t\t\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . esc_html__('Authors', 'uncode') . '</span>',\n\t\t\t\t\t\t'group' => esc_html__('Archives', 'uncode')\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tforeach ($uncode_post_types as $key => $value) {\n\t\t\tif ($value !== 'portfolio' && $value !== 'product' && $value !== 'author') {\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $menu_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $menu);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $menu_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $menu_opaque);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_type);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_uncode_block);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_revslider);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_layerslider);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_height);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_min_height);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_style);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_content_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_custom_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_align);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_position);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_font);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_size);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_height);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_spacing);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_weight);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_transform);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_title_italic);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_text_animation);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_animation_speed);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_animation_delay);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_featured);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_background);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_parallax);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_kburns);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_overlay_color);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_overlay_color_alpha);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_scroll_opacity);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $header_scrolldown);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $body_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $body_layout_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $body_layout_width_custom);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $show_breadcrumb);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $breadcrumb_align);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, run_array_to($show_title, 'std', 'on'));\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $show_media);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $show_featured_media);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $show_comments);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $show_share);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $image_layout);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $media_size);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $enable_sticky_desc);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $enable_woo_zoom);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $thumb_cols);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $enable_woo_slider);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $body_uncode_block_after_pre);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $body_uncode_block_after);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_activate);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_widget);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_position);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_size);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_sticky);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_style);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_bgcolor);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $sidebar_fill);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $navigation_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $navigation_activate);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $navigation_page_index);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $navigation_index_label);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $navigation_nextprev_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $footer_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $footer_uncode_block);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $footer_width);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $custom_fields_section_title);\n\t\t\t\t$cpt_single_options[] = str_replace('%section%', $value, $custom_fields_list);\n\t\t\t}\n\t\t}\n\t\tforeach ($uncode_post_types as $key => $value) {\n\t\t\tif ($value !== 'portfolio' && $value !== 'product') {\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu_section_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu_opaque);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_section_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', run_array_to($header_type, 'std', 'header_basic'));\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_uncode_block);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_revslider);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_layerslider);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_height);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_min_height);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_style);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_content_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_custom_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_align);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_position);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_font);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_size);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_height);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_spacing);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_weight);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_transform);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_title_italic);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_text_animation);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_animation_speed);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_animation_delay);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_featured);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_background);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_parallax);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_kburns);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_overlay_color);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_overlay_color_alpha);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_scroll_opacity);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $header_scrolldown);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu_no_padding);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $menu_no_padding_mobile);\n\t\t\t\tif ($value !== 'author') {\n\t\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $title_archive_custom_activate);\n\t\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $title_archive_custom_text);\n\t\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $subtitle_archive_custom_text);\n\t\t\t\t}\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $body_section_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $show_breadcrumb);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $breadcrumb_align);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $body_uncode_block);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $body_layout_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $body_single_post_width);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $body_single_text_lenght);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $show_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $remove_pagination);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_section_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', run_array_to($sidebar_activate, 'std', 'on'));\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_widget);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_position);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_size);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_sticky);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_style);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_bgcolor);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $sidebar_fill);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $footer_section_title);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $footer_uncode_block);\n\t\t\t\t$cpt_index_options[] = str_replace('%section%', $value . '_index', $footer_width);\n\t\t\t}\n\t\t}\n\t}\n\n\t$custom_settings_section_one = array(\n\t\tarray(\n\t\t\t'id' => 'uncode_header_section',\n\t\t\t'title' => '<i class=\"fa fa-heart3\"></i> ' . esc_html__('Navbar', 'uncode'),\n\t\t\t'group' => esc_html__('General', 'uncode'),\n\t\t\t'group_icon' => 'fa-layout'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_main_section',\n\t\t\t'title' => '<i class=\"fa fa-layers\"></i> ' . esc_html__('Layout', 'uncode'),\n\t\t\t'group' => esc_html__('General', 'uncode'),\n\t\t) ,\n\t\t// array(\n\t\t// \t'id' => 'uncode_header_section',\n\t\t// \t'title' => '<i class=\"fa fa-menu\"></i> ' . esc_html__('Menu', 'uncode'),\n\t\t// \t'group' => esc_html__('General', 'uncode')\n\t\t// ) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_footer_section',\n\t\t\t'title' => '<i class=\"fa fa-ellipsis\"></i> ' . esc_html__('Footer', 'uncode'),\n\t\t\t'group' => esc_html__('General', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_post_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-paper\"></i> ' . esc_html__('Post', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Single', 'uncode'),\n\t\t\t'group_icon' => 'fa-file2'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_page_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-paper\"></i> ' . esc_html__('Page', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Single', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_portfolio_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-paper\"></i> ' . ucfirst($portfolio_cpt_name) . '</span>',\n\t\t\t'group' => esc_html__('Single', 'uncode')\n\t\t) ,\n\t);\n\n\t$custom_settings_section_one = array_merge( $custom_settings_section_one, $cpt_single_sections );\n\n\t$custom_settings_section_two = array(\n\t\tarray(\n\t\t\t'id' => 'uncode_post_index_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . esc_html__('Posts', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Archives', 'uncode'),\n\t\t\t'group_icon' => 'fa-archive2'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_page_index_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . esc_html__('Pages', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Archives', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_portfolio_index_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . ucfirst($portfolio_cpt_name) . 's</span>',\n\t\t\t'group' => esc_html__('Archives', 'uncode')\n\t\t) ,\n\t);\n\n\t$custom_settings_section_one = array_merge( $custom_settings_section_one, $custom_settings_section_two );\n\t$custom_settings_section_one = array_merge( $custom_settings_section_one, $cpt_index_sections );\n\n\t$custom_settings_section_three = array(\n\t\tarray(\n\t\t\t'id' => 'uncode_search_index_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . esc_html__('Search', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Archives', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_404_section',\n\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-help\"></i> ' . esc_html__('404', 'uncode') . '</span>',\n\t\t\t'group' => esc_html__('Single', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_colors_section',\n\t\t\t'title' => '<i class=\"fa fa-drop\"></i> ' . esc_html__('Palette', 'uncode'),\n\t\t\t'group' => esc_html__('Visual', 'uncode'),\n\t\t\t'group_icon' => 'fa-eye2'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_typography_section',\n\t\t\t'title' => '<i class=\"fa fa-font\"></i> ' . esc_html__('Typography', 'uncode'),\n\t\t\t'group' => esc_html__('Visual', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_customize_section',\n\t\t\t'title' => '<i class=\"fa fa-box\"></i> ' . esc_html__('Customize', 'uncode'),\n\t\t\t'group' => esc_html__('Visual', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_extra_section',\n\t\t\t'title' => esc_html__('Extra', 'uncode'),\n\t\t\t'group' => esc_html__('Visual', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_sidebars_section',\n\t\t\t'title' => '<i class=\"fa fa-content-right\"></i> ' . esc_html__('Sidebars', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode'),\n\t\t\t'group_icon' => 'fa-cog2'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_connections_section',\n\t\t\t'title' => '<i class=\"fa fa-share2\"></i> ' . esc_html__('Socials', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_gmaps_section',\n\t\t\t'title' => '<i class=\"fa fa-map-o\"></i> ' . esc_html__('Google Maps', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_redirect_section',\n\t\t\t'title' => '<i class=\"fa fa-reply2\"></i> ' . esc_html__('Redirect', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_cssjs_section',\n\t\t\t'title' => '<i class=\"fa fa-code\"></i> ' . esc_html__('CSS & JS', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode')\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => 'uncode_performance_section',\n\t\t\t'title' => '<i class=\"fa fa-loader\"></i> ' . esc_html__('Performance', 'uncode'),\n\t\t\t'group' => esc_html__('Utility', 'uncode')\n\t\t) ,\n\t);\n\n\t$custom_settings_section_one = array_merge( $custom_settings_section_one, $custom_settings_section_three );\n\n\t$custom_settings_one = array(\n\t\tarray(\n\t\t\t'id' => '_uncode_general_block_title',\n\t\t\t'label' => '<i class=\"fa fa-globe3\"></i> ' . esc_html__('General', 'uncode') ,\n\t\t\t'desc' => '',\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_main_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_main_width',\n\t\t\t'label' => esc_html__('Site width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter the width of your site.', 'uncode') ,\n\t\t\t'std' => array(\n\t\t\t\t'1200',\n\t\t\t\t'px'\n\t\t\t) ,\n\t\t\t'type' => 'measurement',\n\t\t\t'section' => 'uncode_main_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_main_align',\n\t\t\t'label' => esc_html__('Site layout align', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the alignment of the content area when is less then 100% width.', 'uncode') ,\n\t\t\t'std' => 'center',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_main_section',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t'label' => esc_html__('Left align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'center',\n\t\t\t\t\t'label' => esc_html__('Center align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t'label' => esc_html__('Right align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_boxed',\n\t\t\t'label' => esc_html__('Boxed', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate for the boxed layout.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_main_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_border',\n\t\t\t'label' => esc_html__('Body frame', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the thickness of the frame around the body', 'uncode') ,\n\t\t\t'std' => '0',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '0,36,9',\n\t\t\t'section' => 'uncode_main_section',\n\t\t\t'condition' => '_uncode_boxed:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_border_color',\n\t\t\t'label' => esc_html__('Body frame color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the body frame color.', 'uncode') ,\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_main_section',\n\t\t\t'condition' => '_uncode_boxed:is(off),_uncode_body_border:not(0)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tstr_replace('%section%', 'main', run_array_to($header_section_title, 'condition', '_uncode_boxed:is(off)')),\n\t\tarray(\n\t\t\t'id' => '_uncode_header_full',\n\t\t\t'label' => esc_html__('Container full width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to expand the header container to full width.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_main_section',\n\t\t\t'condition' => '_uncode_boxed:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tstr_replace('%section%', 'main', run_array_to($body_section_title, 'condition', '_uncode_boxed:is(off)')),\n\t\tarray(\n\t\t\t'id' => '_uncode_body_full',\n\t\t\t'label' => esc_html__('Content area full width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to expand the content area to full width.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_main_section',\n\t\t\t'condition' => '_uncode_boxed:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_logo_block_title',\n\t\t\t'label' => '<i class=\"fa fa-heart3\"></i> ' . esc_html__('Logo', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_switch',\n\t\t\t'label' => esc_html__('Switchable logo', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to upload different logo for each skin.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo',\n\t\t\t'label' => esc_html__('Logo', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo. You can use Images, SVG code or HTML code.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_switch:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_light',\n\t\t\t'label' => esc_html__('Logo - Light', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo for the light skin.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_switch:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_dark',\n\t\t\t'label' => esc_html__('Logo - Dark', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo for the dark skin.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_switch:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_mobile_switch',\n\t\t\t'label' => esc_html__('Different Logo Mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to upload different logo for mobile devices.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_mobile',\n\t\t\t'label' => esc_html__('Logo Mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo for mobile. You can use Images, SVG code or HTML code.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_mobile_switch:is(on),_uncode_logo_switch:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_mobile_light',\n\t\t\t'label' => esc_html__('Logo Mobile - Light', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo mobile for the light skin.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_mobile_switch:is(on),_uncode_logo_switch:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_mobile_dark',\n\t\t\t'label' => esc_html__('Logo Mobile - Dark', 'uncode') ,\n\t\t\t'desc' => esc_html__('Upload a logo mobile for the dark skin.', 'uncode') ,\n\t\t\t'type' => 'upload',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_logo_mobile_switch:is(on),_uncode_logo_switch:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_height',\n\t\t\t'label' => esc_html__('Logo height', 'uncode'),\n\t\t\t'desc' => esc_html__('Enter the height of the logo in px.', 'uncode') ,\n\t\t\t'std' => '20',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_height_mobile',\n\t\t\t'label' => esc_html__('Logo height mobile', 'uncode'),\n\t\t\t'desc' => esc_html__('Enter the height of the logo in px for mobile version.', 'uncode') ,\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_headers_block_title',\n\t\t\t'label' => '<i class=\"fa fa-menu\"></i> ' . esc_html__('Menu', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_headers',\n\t\t\t'desc' => esc_html__('Specify the menu layout.', 'uncode') ,\n\t\t\t'label' => '' ,\n\t\t\t'std' => 'hmenu-right',\n\t\t\t'type' => 'radio-image',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_hmenu_position',\n\t\t\t'label' => esc_html__('Menu horizontal position', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the horizontal position of the menu.', 'uncode') ,\n\t\t\t'std' => 'left',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(hmenu)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_vmenu_position',\n\t\t\t'label' => esc_html__('Menu horizontal position', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the horizontal position of the menu.', 'uncode') ,\n\t\t\t'std' => 'left',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(vmenu),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_vmenu_v_position',\n\t\t\t'label' => esc_html__('Menu vertical alignment', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the vertical alignment of the menu.', 'uncode') ,\n\t\t\t'std' => 'middle',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(vmenu),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'top',\n\t\t\t\t\t'label' => esc_html__('Top', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'middle',\n\t\t\t\t\t'label' => esc_html__('Middle', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'bottom',\n\t\t\t\t\t'label' => esc_html__('Bottom', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_vmenu_align',\n\t\t\t'label' => esc_html__('Menu horizontal alignment', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the horizontal alignment of the menu.', 'uncode') ,\n\t\t\t'std' => 'left',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(vmenu),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t'label' => esc_html__('Left Align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'center',\n\t\t\t\t\t'label' => esc_html__('Center Align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t'label' => esc_html__('Right Align', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_vmenu_width',\n\t\t\t'label' => esc_html__('Vertical menu width','uncode') ,\n\t\t\t'desc' => esc_html__('Vertical menu width in px', 'uncode') ,\n\t\t\t'std' => '252',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'rows' => '',\n\t\t\t'post_type' => '',\n\t\t\t'taxonomy' => '',\n\t\t\t'min_max_step' => '108,504,12',\n\t\t\t'class' => '',\n\t\t\t'condition' => '_uncode_headers:contains(vmenu)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_accordion_active',\n\t\t\t'label' => esc_html__('Vertical menu open', 'uncode') ,\n\t\t\t'desc' => esc_html__('Open the accordion menu at the current item menu on page loading.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:is(vmenu)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_full',\n\t\t\t'label' => esc_html__('Menu full width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to expand the menu to full width. (Only for the horizontal menus).', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_boxed:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_visuals_block_title',\n\t\t\t'label' => '<i class=\"fa fa-eye2\"></i> ' . esc_html__('Visuals', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_shadows',\n\t\t\t'label' => esc_html__('Menu divider shadow', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the menu divider shadow.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_submenu_shadows',\n\t\t\t'label' => esc_html__('Menu dropdown shadow', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this for the shadow effect on menu dropdown on desktop view. NB. this option works for horizontal menus only.', 'uncode') ,\n\t\t\t'std' => 'none',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'std' => '',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'label' => esc_html__('None', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'xs',\n\t\t\t\t\t'label' => esc_html__('Extra Small', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'sm',\n\t\t\t\t\t'label' => esc_html__('Small', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'std',\n\t\t\t\t\t'label' => esc_html__('Standard', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'lg',\n\t\t\t\t\t'label' => esc_html__('Large', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'xl',\n\t\t\t\t\t'label' => esc_html__('Extra Large', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t),\n\t\t\t'condition' => '_uncode_headers:contains(hmenu),_uncode_headers:is(vmenu-offcanvas),_uncode_headers:is(menu-overlay)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_submenu_darker_shadows',\n\t\t\t'label' => esc_html__('Menu dropdown darker shadow', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this for the dark shadow effect on menu dropdown on desktop view.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_submenu_shadows:not()',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_borders',\n\t\t\t'label' => esc_html__('Menu borders', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the menu borders.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_no_arrows',\n\t\t\t'label' => esc_html__('Hide dropdown arrows', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to hide the dropdow arrows.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_mobile_transparency',\n\t\t\t'label' => esc_html__('Menu mobile transparency', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the menu transparency when possible.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_custom_padding',\n\t\t\t'label' => esc_html__('Custom vertical padding', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate custom padding above and below the logo.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_custom_padding_desktop',\n\t\t\t'label' => esc_html__('Padding on desktop', 'uncode') ,\n\t\t\t'desc' => esc_html__('Set custom padding on desktop devices.', 'uncode') ,\n\t\t\t'std' => '27',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '0,36,9',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_custom_padding:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_custom_padding_mobile',\n\t\t\t'label' => esc_html__('Padding on mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Set custom padding on mobile devices.', 'uncode') ,\n\t\t\t'std' => '27',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '0,36,9',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_custom_padding:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_animation_block_title',\n\t\t\t'label' => '<i class=\"fa fa-fast-forward2\"></i> ' . esc_html__('Animation', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t// 'condition' => '_uncode_headers:contains(hmenu),_uncode_headers:is(vmenu-offcanvas),_uncode_headers:is(menu-overlay)',\n\t\t\t// 'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_sticky',\n\t\t\t'label' => esc_html__('Menu sticky', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the sticky menu. This is a menu that is locked into place so that it does not disappear when the user scrolls down the page.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(hmenu),_uncode_headers:is(vmenu-offcanvas),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_sticky_mobile',\n\t\t\t'label' => esc_html__('Menu sticky mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the sticky menu on mobile devices. This is a menu that is locked into place so that it does not disappear when the user scrolls down the page.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_mobile_centered',\n\t\t\t'label' => esc_html__('Menu centered mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the centered style for mobile menu. NB. You need to have the Menu Sticky Mobile active.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_sticky_mobile:is(on)',\n\t\t\t'operator' => 'and',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_hide',\n\t\t\t'label' => esc_html__('Menu hide', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the autohide menu. This is a menu that is hiding after the user have scrolled down the page.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(hmenu),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center),_uncode_headers:is(vmenu-offcanvas)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_hide_mobile',\n\t\t\t'label' => esc_html__('Menu hide mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the autohide menu on mobile devices. This is a menu that is hiding after the user have scrolled down the page.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_shrink',\n\t\t\t'label' => esc_html__('Menu shrink', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the shrink menu. This is a menu where the logo shrinks after the user have scrolled down the page.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:contains(hmenu),_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center),_uncode_headers:is(vmenu-offcanvas)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_li_animation',\n\t\t\t'label' => esc_html__('Menu sub-levels animated', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the animation for menu sub-levels. NB. this option works for horizontal menus only.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:not(vmenu)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_mobile_animation',\n\t\t\t'label' => esc_html__('Menu open items animation', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu items animation when opening.', 'uncode') ,\n\t\t\t'std' => 'none',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_sticky_mobile:is(on),_uncode_menu_hide_mobile:is(on)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'none',\n\t\t\t\t\t'label' => esc_html__('None', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'scale',\n\t\t\t\t\t'label' => esc_html__('Scale', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_overlay_animation',\n\t\t\t'label' => esc_html__('Menu overlay animation', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the overlay menu animation when opening and closing.', 'uncode') ,\n\t\t\t'std' => 'sequential',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '3d',\n\t\t\t\t\t'label' => esc_html__('3D', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'sequential',\n\t\t\t\t\t'label' => esc_html__('Flat', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_min_logo',\n\t\t\t'label' => esc_html__('Minimum logo height', 'uncode'),\n\t\t\t'desc' => esc_html__('Enter the minimal height of the shrinked logo in <b>px</b>.', 'uncode') ,\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_shrink:is(on),_uncode_headers:not(vmenu)',\n\t\t\t'operator' => 'and',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_add_block_title',\n\t\t\t'label' => '<i class=\"fa fa-square-plus\"></i> ' . esc_html__('Additionals', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_no_secondary',\n\t\t\t'label' => esc_html__('Hide secondary menu', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to hide the secondary menu.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_no_cta',\n\t\t\t'label' => esc_html__('Hide Call To Action menu', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to hide the Call To Action menu.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_secondary_padding',\n\t\t\t'label' => esc_html__('Secondary menu padding', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to increase secondary menu padding.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_menu_no_secondary:is(off)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_socials',\n\t\t\t'label' => esc_html__('Social icons', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the social connection icons in the menu bar.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_search',\n\t\t\t'label' => esc_html__('Search icon', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the search icon in the menu bar.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_search_animation',\n\t\t\t'label' => esc_html__('Search overlay animation', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the search overlay animation when opening and closing.', 'uncode') ,\n\t\t\t'std' => 'sequential',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '3d',\n\t\t\t\t\t'label' => esc_html__('3D', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'sequential',\n\t\t\t\t\t'label' => esc_html__('Flat', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t) ,\n\t\t\t'condition' => '_uncode_menu_search:is(on)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_woocommerce_cart',\n\t\t\t'label' => esc_html__('Woocommerce cart', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the Woocommerce icon in the menu bar.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_woocommerce_cart_desktop',\n\t\t\t'label' => esc_html__('Woocommerce cart on menu bar', 'uncode') ,\n\t\t\t'desc' => esc_html__('Show the cart icon in the menu bar when layout is on desktop mode (only for Overlay and Offcanvas menu).', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_woocommerce_cart:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_woocommerce_cart_mobile',\n\t\t\t'label' => esc_html__('Woocommerce cart on menu bar for mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Show the cart icon in the menu bar when layout is on mobile mode.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_woocommerce_cart:is(on)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_bloginfo',\n\t\t\t'label' => esc_html__('Top line text', 'uncode') ,\n\t\t\t'desc' => esc_html__('Insert additional text on top of the menu.','uncode') ,\n\t\t\t'type' => 'textarea',\n\t\t\t'section' => 'uncode_header_section',\n\t\t\t'condition' => '_uncode_headers:is(hmenu-right),_uncode_headers:is(hmenu-left),_uncode_headers:is(hmenu-justify),_uncode_headers:is(hmenu-center),_uncode_headers:is(hmenu-center-split)',\n\t\t\t'operator' => 'or'\n\t\t) ,\n\t\t//////////////////////\n\t\t// Post Single\t\t///\n\t\t//////////////////////\n\t\tstr_replace('%section%', 'post', $menu_section_title),\n\t\tstr_replace('%section%', 'post', $menu),\n\t\tstr_replace('%section%', 'post', $menu_width),\n\t\tstr_replace('%section%', 'post', $menu_opaque),\n\t\tstr_replace('%section%', 'post', $header_section_title),\n\t\tstr_replace('%section%', 'post', run_array_to($header_type, 'std', 'header_basic')),\n\t\tstr_replace('%section%', 'post', $header_uncode_block),\n\t\tstr_replace('%section%', 'post', $header_revslider),\n\t\tstr_replace('%section%', 'post', $header_layerslider),\n\n\t\tstr_replace('%section%', 'post', $header_width),\n\t\tstr_replace('%section%', 'post', $header_height),\n\t\tstr_replace('%section%', 'post', $header_min_height),\n\t\tstr_replace('%section%', 'post', $header_title),\n\t\tstr_replace('%section%', 'post', $header_style),\n\t\tstr_replace('%section%', 'post', $header_content_width),\n\t\tstr_replace('%section%', 'post', $header_custom_width),\n\t\tstr_replace('%section%', 'post', $header_align),\n\t\tstr_replace('%section%', 'post', $header_position),\n\t\tstr_replace('%section%', 'post', $header_title_font),\n\t\tstr_replace('%section%', 'post', $header_title_size),\n\t\tstr_replace('%section%', 'post', $header_title_height),\n\t\tstr_replace('%section%', 'post', $header_title_spacing),\n\t\tstr_replace('%section%', 'post', $header_title_weight),\n\t\tstr_replace('%section%', 'post', $header_title_transform),\n\t\tstr_replace('%section%', 'post', $header_title_italic),\n\t\tstr_replace('%section%', 'post', $header_text_animation),\n\t\tstr_replace('%section%', 'post', $header_animation_speed),\n\t\tstr_replace('%section%', 'post', $header_animation_delay),\n\t\tstr_replace('%section%', 'post', $header_featured),\n\t\tstr_replace('%section%', 'post', $header_background),\n\t\tstr_replace('%section%', 'post', $header_parallax),\n\t\tstr_replace('%section%', 'post', $header_kburns),\n\t\tstr_replace('%section%', 'post', $header_overlay_color),\n\t\tstr_replace('%section%', 'post', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'post', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'post', $header_scrolldown),\n\n\t\tstr_replace('%section%', 'post', $body_section_title),\n\t\tstr_replace('%section%', 'post', $body_layout_width),\n\t\tstr_replace('%section%', 'post', $body_layout_width_custom),\n\t\tstr_replace('%section%', 'post', $show_breadcrumb),\n\t\tstr_replace('%section%', 'post', $breadcrumb_align),\n\t\t// str_replace('%section%', 'post', $body_uncode_block_before),\n\t\tstr_replace('%section%', 'post', $show_title),\n\t\tstr_replace('%section%', 'post', $show_media),\n\t\tstr_replace('%section%', 'post', $show_featured_media),\n\t\tstr_replace('%section%', 'post', $show_comments),\n\t\tstr_replace('%section%', 'post', $show_share),\n\t\tstr_replace('%section%', 'post', $show_tags),\n\t\tstr_replace('%section%', 'post', $show_tags_align),\n\t\tstr_replace('%section%', 'post', $body_uncode_block_after_pre),\n\t\tstr_replace('%section%', 'post', $body_uncode_block_after),\n\t\tstr_replace('%section%', 'post', $sidebar_section_title),\n\t\tstr_replace('%section%', 'post', run_array_to($sidebar_activate, 'std', 'on')),\n\t\tstr_replace('%section%', 'post', $sidebar_widget),\n\t\tstr_replace('%section%', 'post', $sidebar_position),\n\t\tstr_replace('%section%', 'post', $sidebar_size),\n\t\tstr_replace('%section%', 'post', $sidebar_sticky),\n\t\tstr_replace('%section%', 'post', $sidebar_style),\n\t\tstr_replace('%section%', 'post', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'post', $sidebar_fill),\n\n\t\tstr_replace('%section%', 'post', $navigation_section_title),\n\t\tstr_replace('%section%', 'post', $navigation_activate),\n\t\tstr_replace('%section%', 'post', $navigation_page_index),\n\t\tstr_replace('%section%', 'post', $navigation_index_label),\n\t\tstr_replace('%section%', 'post', $navigation_nextprev_title),\n\t\tstr_replace('%section%', 'post', $footer_section_title),\n\t\tstr_replace('%section%', 'post', $footer_uncode_block),\n\t\tstr_replace('%section%', 'post', $footer_width),\n\t\tstr_replace('%section%', 'post', $custom_fields_section_title),\n\t\tstr_replace('%section%', 'post', $custom_fields_list),\n\t\t///////////////\n\t\t// Page\t\t///\n\t\t///////////////\n\t\tstr_replace('%section%', 'page', $menu_section_title),\n\t\tstr_replace('%section%', 'page', $menu),\n\t\tstr_replace('%section%', 'page', $menu_width),\n\t\tstr_replace('%section%', 'page', $menu_opaque),\n\t\tstr_replace('%section%', 'page', $header_section_title),\n\t\tstr_replace('%section%', 'page', $header_type),\n\t\tstr_replace('%section%', 'page', $header_uncode_block),\n\t\tstr_replace('%section%', 'page', $header_revslider),\n\t\tstr_replace('%section%', 'page', $header_layerslider),\n\n\t\tstr_replace('%section%', 'page', $header_width),\n\t\tstr_replace('%section%', 'page', $header_height),\n\t\tstr_replace('%section%', 'page', $header_min_height),\n\t\tstr_replace('%section%', 'page', $header_title),\n\t\tstr_replace('%section%', 'page', $header_style),\n\t\tstr_replace('%section%', 'page', $header_content_width),\n\t\tstr_replace('%section%', 'page', $header_custom_width),\n\t\tstr_replace('%section%', 'page', $header_align),\n\t\tstr_replace('%section%', 'page', $header_position),\n\t\tstr_replace('%section%', 'page', $header_title_font),\n\t\tstr_replace('%section%', 'page', $header_title_size),\n\t\tstr_replace('%section%', 'page', $header_title_height),\n\t\tstr_replace('%section%', 'page', $header_title_spacing),\n\t\tstr_replace('%section%', 'page', $header_title_weight),\n\t\tstr_replace('%section%', 'page', $header_title_transform),\n\t\tstr_replace('%section%', 'page', $header_title_italic),\n\t\tstr_replace('%section%', 'page', $header_text_animation),\n\t\tstr_replace('%section%', 'page', $header_animation_speed),\n\t\tstr_replace('%section%', 'page', $header_animation_delay),\n\t\tstr_replace('%section%', 'page', $header_featured),\n\t\tstr_replace('%section%', 'page', $header_background),\n\t\tstr_replace('%section%', 'page', $header_parallax),\n\t\tstr_replace('%section%', 'page', $header_kburns),\n\t\tstr_replace('%section%', 'page', $header_overlay_color),\n\t\tstr_replace('%section%', 'page', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'page', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'page', $header_scrolldown),\n\t\tstr_replace('%section%', 'page', $body_section_title),\n\t\tstr_replace('%section%', 'page', $body_layout_width),\n\t\tstr_replace('%section%', 'page', $body_layout_width_custom),\n\t\tstr_replace('%section%', 'page', $show_breadcrumb),\n\t\tstr_replace('%section%', 'page', $breadcrumb_align),\n\t\tstr_replace('%section%', 'page', run_array_to($show_title, 'std', 'on')),\n\t\tstr_replace('%section%', 'page', $show_media),\n\t\tstr_replace('%section%', 'page', $show_featured_media),\n\t\tstr_replace('%section%', 'page', $show_comments),\n\t\tstr_replace('%section%', 'page', $body_uncode_block_after),\n\t\tstr_replace('%section%', 'page', $sidebar_section_title),\n\t\tstr_replace('%section%', 'page', $sidebar_activate),\n\t\tstr_replace('%section%', 'page', $sidebar_widget),\n\t\tstr_replace('%section%', 'page', $sidebar_position),\n\t\tstr_replace('%section%', 'page', $sidebar_size),\n\t\tstr_replace('%section%', 'page', $sidebar_sticky),\n\t\tstr_replace('%section%', 'page', $sidebar_style),\n\t\tstr_replace('%section%', 'page', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'page', $sidebar_fill),\n\t\tstr_replace('%section%', 'page', $footer_section_title),\n\t\tstr_replace('%section%', 'page', $footer_uncode_block),\n\t\tstr_replace('%section%', 'page', $footer_width),\n\t\tstr_replace('%section%', 'page', $custom_fields_section_title),\n\t\tstr_replace('%section%', 'page', $custom_fields_list),\n\t\t///////////////////////////\n\t\t// Portfolio Single\t\t///\n\t\t///////////////////////////\n\t\tstr_replace('%section%', 'portfolio', $menu_section_title),\n\t\tstr_replace('%section%', 'portfolio', $menu),\n\t\tstr_replace('%section%', 'portfolio', $menu_width),\n\t\tstr_replace('%section%', 'portfolio', $menu_opaque),\n\t\tstr_replace('%section%', 'portfolio', $header_section_title),\n\t\tstr_replace('%section%', 'portfolio', $header_type),\n\t\tstr_replace('%section%', 'portfolio', $header_uncode_block),\n\t\tstr_replace('%section%', 'portfolio', $header_revslider),\n\t\tstr_replace('%section%', 'portfolio', $header_layerslider),\n\n\t\tstr_replace('%section%', 'portfolio', $header_width),\n\t\tstr_replace('%section%', 'portfolio', $header_height),\n\t\tstr_replace('%section%', 'portfolio', $header_min_height),\n\t\tstr_replace('%section%', 'portfolio', $header_title),\n\t\tstr_replace('%section%', 'portfolio', $header_style),\n\t\tstr_replace('%section%', 'portfolio', $header_content_width),\n\t\tstr_replace('%section%', 'portfolio', $header_custom_width),\n\t\tstr_replace('%section%', 'portfolio', $header_align),\n\t\tstr_replace('%section%', 'portfolio', $header_position),\n\t\tstr_replace('%section%', 'portfolio', $header_title_font),\n\t\tstr_replace('%section%', 'portfolio', $header_title_size),\n\t\tstr_replace('%section%', 'portfolio', $header_title_height),\n\t\tstr_replace('%section%', 'portfolio', $header_title_spacing),\n\t\tstr_replace('%section%', 'portfolio', $header_title_weight),\n\t\tstr_replace('%section%', 'portfolio', $header_title_transform),\n\t\tstr_replace('%section%', 'portfolio', $header_title_italic),\n\t\tstr_replace('%section%', 'portfolio', $header_text_animation),\n\t\tstr_replace('%section%', 'portfolio', $header_animation_speed),\n\t\tstr_replace('%section%', 'portfolio', $header_animation_delay),\n\t\tstr_replace('%section%', 'portfolio', $header_featured),\n\t\tstr_replace('%section%', 'portfolio', $header_background),\n\t\tstr_replace('%section%', 'portfolio', $header_parallax),\n\t\tstr_replace('%section%', 'portfolio', $header_kburns),\n\t\tstr_replace('%section%', 'portfolio', $header_overlay_color),\n\t\tstr_replace('%section%', 'portfolio', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'portfolio', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'portfolio', $header_scrolldown),\n\n\t\tstr_replace('%section%', 'portfolio', $body_section_title),\n\t\tstr_replace('%section%', 'portfolio', $body_layout_width),\n\t\tstr_replace('%section%', 'portfolio', $body_layout_width_custom),\n\t\tstr_replace('%section%', 'portfolio', $show_breadcrumb),\n\t\tstr_replace('%section%', 'portfolio', $breadcrumb_align),\n\t\tstr_replace('%section%', 'portfolio', run_array_to($show_title, 'std', 'on')),\n\t\tstr_replace('%section%', 'portfolio', $show_media),\n\t\tstr_replace('%section%', 'portfolio', $show_featured_media),\n\t\tstr_replace('%section%', 'portfolio', run_array_to($show_comments, 'std', 'off')),\n\t\tstr_replace('%section%', 'portfolio', $show_share),\n\t\tstr_replace('%section%', 'portfolio', $body_uncode_block_after),\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_details_title',\n\t\t\t'label' => '<i class=\"fa fa-briefcase3\"></i> ' . esc_html__('Details', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_details',\n\t\t\t'label' => ucfirst($portfolio_cpt_name) . ' ' . esc_html__('details', 'uncode') ,\n\t\t\t'desc' => sprintf(esc_html__('Create here all the %s details label that you need.', 'uncode') , $portfolio_cpt_name) ,\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_portfolio_detail_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'detail-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => sprintf(esc_html__('Unique %s detail ID','uncode') , $portfolio_cpt_name) ,\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_position',\n\t\t\t'label' => ucfirst($portfolio_cpt_name) . ' ' . esc_html__('details layout', 'uncode') ,\n\t\t\t'desc' => sprintf(esc_html__('Specify the layout template for all the %s posts.', 'uncode') , $portfolio_cpt_name) ,\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'label' => esc_html__('Select…', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'portfolio_top',\n\t\t\t\t\t'label' => esc_html__('Details on the top', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'sidebar_right',\n\t\t\t\t\t'label' => esc_html__('Details on the right', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'portfolio_bottom',\n\t\t\t\t\t'label' => esc_html__('Details on the bottom', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'sidebar_left',\n\t\t\t\t\t'label' => esc_html__('Details on the left', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_sidebar_size',\n\t\t\t'label' => esc_html__('Sidebar size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Set the sidebar size.', 'uncode') ,\n\t\t\t'std' => '4',\n\t\t\t'min_max_step' => '1,12,1',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'operator' => 'and',\n\t\t\t'condition' => '_uncode_portfolio_position:not(),_uncode_portfolio_position:contains(sidebar)',\n\t\t) ,\n\t\tstr_replace('%section%', 'portfolio', run_array_to($sidebar_sticky, 'condition', '_uncode_portfolio_position:not(),_uncode_portfolio_position:contains(sidebar)')),\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_style',\n\t\t\t'label' => esc_html__('Skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the sidebar text skin color.', 'uncode') ,\n\t\t\t'type' => 'select',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'label' => esc_html__('Inherit', \"uncode\") ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'light',\n\t\t\t\t\t'label' => esc_html__('Light', \"uncode\") ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'dark',\n\t\t\t\t\t'label' => esc_html__('Dark', \"uncode\") ,\n\t\t\t\t)\n\t\t\t),\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'condition' => '_uncode_portfolio_position:not()',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_bgcolor',\n\t\t\t'label' => esc_html__('Sidebar color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the sidebar background color.', 'uncode') ,\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'condition' => '_uncode_portfolio_position:not()',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_sidebar_fill',\n\t\t\t'label' => esc_html__('Sidebar filling space', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to remove padding around the sidebar and fill the height.', 'uncode') ,\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_portfolio_section',\n\t\t\t'std' => 'off',\n\t\t\t'operator' => 'and',\n\t\t\t'condition' => '_uncode_portfolio_position:not(),_uncode_portfolio_sidebar_bgcolor:not(),_uncode_portfolio_position:contains(sidebar)',\n\t\t),\n\t\tstr_replace('%section%', 'portfolio', $navigation_section_title),\n\t\tstr_replace('%section%', 'portfolio', $navigation_activate),\n\t\tstr_replace('%section%', 'portfolio', $navigation_page_index),\n\t\tstr_replace('%section%', 'portfolio', $navigation_index_label),\n\t\tstr_replace('%section%', 'portfolio', $navigation_nextprev_title),\n\t\tstr_replace('%section%', 'portfolio', $footer_section_title),\n\t\tstr_replace('%section%', 'portfolio', $footer_uncode_block),\n\t\tstr_replace('%section%', 'portfolio', $footer_width),\n\t\tstr_replace('%section%', 'portfolio', $custom_fields_section_title),\n\t\tstr_replace('%section%', 'portfolio', $custom_fields_list),\n\t);\n\n\t$custom_settings_one = array_merge( $custom_settings_one, $cpt_single_options );\n\n\t$custom_settings_two = array(\n\t\t///////////////////\n\t\t// Page 404\t\t///\n\t\t///////////////////\n\t\tstr_replace('%section%', '404', $menu_section_title),\n\t\tstr_replace('%section%', '404', $menu),\n\t\tstr_replace('%section%', '404', $menu_width),\n\t\tstr_replace('%section%', '404', $menu_opaque),\n\t\tstr_replace('%section%', '404', $header_section_title),\n\t\tstr_replace('%section%', '404', $header_type),\n\t\tstr_replace('%section%', '404', $header_uncode_block),\n\t\tstr_replace('%section%', '404', $header_revslider),\n\t\tstr_replace('%section%', '404', $header_layerslider),\n\n\t\tstr_replace('%section%', '404', $header_width),\n\t\tstr_replace('%section%', '404', $header_height),\n\t\tstr_replace('%section%', '404', $header_min_height),\n\t\tstr_replace('%section%', '404', $header_title),\n\t\tstr_replace('%section%', '404', $header_title_text),\n\t\tstr_replace('%section%', '404', $header_style),\n\t\tstr_replace('%section%', '404', $header_content_width),\n\t\tstr_replace('%section%', '404', $header_custom_width),\n\t\tstr_replace('%section%', '404', $header_align),\n\t\tstr_replace('%section%', '404', $header_position),\n\t\tstr_replace('%section%', '404', $header_title_font),\n\t\tstr_replace('%section%', '404', $header_title_size),\n\t\tstr_replace('%section%', '404', $header_title_height),\n\t\tstr_replace('%section%', '404', $header_title_spacing),\n\t\tstr_replace('%section%', '404', $header_title_weight),\n\t\tstr_replace('%section%', '404', $header_title_transform),\n\t\tstr_replace('%section%', '404', $header_title_italic),\n\t\tstr_replace('%section%', '404', $header_text_animation),\n\t\tstr_replace('%section%', '404', $header_animation_speed),\n\t\tstr_replace('%section%', '404', $header_animation_delay),\n\t\tstr_replace('%section%', '404', $header_background),\n\t\tstr_replace('%section%', '404', $header_parallax),\n\t\tstr_replace('%section%', '404', $header_kburns),\n\t\tstr_replace('%section%', '404', $header_overlay_color),\n\t\tstr_replace('%section%', '404', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', '404', $header_scroll_opacity),\n\t\tstr_replace('%section%', '404', $header_scrolldown),\n\n\t\tstr_replace('%section%', '404', $body_section_title),\n\t\tstr_replace('%section%', '404', $body_layout_width),\n\t\tstr_replace('%section%', '404', $uncodeblock_404),\n\t\tstr_replace('%section%', '404', $uncodeblocks_404),\n\t\tstr_replace('%section%', '404', $footer_section_title),\n\t\tstr_replace('%section%', '404', $footer_uncode_block),\n\t\tstr_replace('%section%', '404', $footer_width),\n\t\t//////////////////////\n\t\t// Posts Index\t\t///\n\t\t//////////////////////\n\t\tstr_replace('%section%', 'post_index', $menu_section_title),\n\t\tstr_replace('%section%', 'post_index', $menu),\n\t\tstr_replace('%section%', 'post_index', $menu_width),\n\t\tstr_replace('%section%', 'post_index', $menu_opaque),\n\t\tstr_replace('%section%', 'post_index', $header_section_title),\n\t\tstr_replace('%section%', 'post_index', run_array_to($header_type, 'std', 'header_basic')),\n\t\tstr_replace('%section%', 'post_index', $header_uncode_block),\n\t\tstr_replace('%section%', 'post_index', $header_revslider),\n\t\tstr_replace('%section%', 'post_index', $header_layerslider),\n\n\t\tstr_replace('%section%', 'post_index', $header_width),\n\t\tstr_replace('%section%', 'post_index', $header_height),\n\t\tstr_replace('%section%', 'post_index', $header_min_height),\n\t\tstr_replace('%section%', 'post_index', $header_title),\n\t\tstr_replace('%section%', 'post_index', $header_style),\n\t\tstr_replace('%section%', 'post_index', $header_content_width),\n\t\tstr_replace('%section%', 'post_index', $header_custom_width),\n\t\tstr_replace('%section%', 'post_index', $header_align),\n\t\tstr_replace('%section%', 'post_index', $header_position),\n\t\tstr_replace('%section%', 'post_index', $header_title_font),\n\t\tstr_replace('%section%', 'post_index', $header_title_size),\n\t\tstr_replace('%section%', 'post_index', $header_title_height),\n\t\tstr_replace('%section%', 'post_index', $header_title_spacing),\n\t\tstr_replace('%section%', 'post_index', $header_title_weight),\n\t\tstr_replace('%section%', 'post_index', $header_title_transform),\n\t\tstr_replace('%section%', 'post_index', $header_title_italic),\n\t\tstr_replace('%section%', 'post_index', $header_text_animation),\n\t\tstr_replace('%section%', 'post_index', $header_animation_speed),\n\t\tstr_replace('%section%', 'post_index', $header_animation_delay),\n\t\tstr_replace('%section%', 'post_index', $header_featured),\n\t\tstr_replace('%section%', 'post_index', $header_background),\n\t\tstr_replace('%section%', 'post_index', $header_parallax),\n\t\tstr_replace('%section%', 'post_index', $header_kburns),\n\t\tstr_replace('%section%', 'post_index', $header_overlay_color),\n\t\tstr_replace('%section%', 'post_index', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'post_index', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'post_index', $header_scrolldown),\n\t\tstr_replace('%section%', 'post_index', $menu_no_padding),\n\t\tstr_replace('%section%', 'post_index', $menu_no_padding_mobile),\n\t\tstr_replace('%section%', 'post_index', $title_archive_custom_activate),\n\t\tstr_replace('%section%', 'post_index', $title_archive_custom_text),\n\t\tstr_replace('%section%', 'post_index', $subtitle_archive_custom_text),\n\n\t\tstr_replace('%section%', 'post_index', $body_section_title),\n\t\tstr_replace('%section%', 'post_index', $show_breadcrumb),\n\t\tstr_replace('%section%', 'post_index', $breadcrumb_align),\n\t\tstr_replace('%section%', 'post_index', $body_uncode_block),\n\t\tstr_replace('%section%', 'post_index', $body_layout_width),\n\t\tstr_replace('%section%', 'post_index', $body_single_post_width),\n\t\tstr_replace('%section%', 'post_index', $body_single_text_lenght),\n\t\tstr_replace('%section%', 'post_index', $show_title),\n\t\tstr_replace('%section%', 'post_index', $remove_pagination),\n\t\tstr_replace('%section%', 'post_index', $sidebar_section_title),\n\t\tstr_replace('%section%', 'post_index', run_array_to($sidebar_activate, 'std', 'on')),\n\t\tstr_replace('%section%', 'post_index', $sidebar_widget),\n\t\tstr_replace('%section%', 'post_index', $sidebar_position),\n\t\tstr_replace('%section%', 'post_index', $sidebar_size),\n\t\tstr_replace('%section%', 'post_index', $sidebar_sticky),\n\t\tstr_replace('%section%', 'post_index', $sidebar_style),\n\t\tstr_replace('%section%', 'post_index', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'post_index', $sidebar_fill),\n\t\tstr_replace('%section%', 'post_index', $footer_section_title),\n\t\tstr_replace('%section%', 'post_index', $footer_uncode_block),\n\t\tstr_replace('%section%', 'post_index', $footer_width),\n\t\t//////////////////////\n\t\t// Pages Index\t\t///\n\t\t//////////////////////\n\t\tstr_replace('%section%', 'page_index', $menu_section_title),\n\t\tstr_replace('%section%', 'page_index', $menu),\n\t\tstr_replace('%section%', 'page_index', $menu_width),\n\t\tstr_replace('%section%', 'page_index', $menu_opaque),\n\t\tstr_replace('%section%', 'page_index', $header_section_title),\n\t\tstr_replace('%section%', 'page_index', run_array_to($header_type, 'std', 'header_basic')),\n\t\tstr_replace('%section%', 'page_index', $header_uncode_block),\n\t\tstr_replace('%section%', 'page_index', $header_revslider),\n\t\tstr_replace('%section%', 'page_index', $header_layerslider),\n\n\t\tstr_replace('%section%', 'page_index', $header_width),\n\t\tstr_replace('%section%', 'page_index', $header_height),\n\t\tstr_replace('%section%', 'page_index', $header_min_height),\n\t\tstr_replace('%section%', 'page_index', $header_title),\n\t\tstr_replace('%section%', 'page_index', $header_style),\n\t\tstr_replace('%section%', 'page_index', $header_content_width),\n\t\tstr_replace('%section%', 'page_index', $header_custom_width),\n\t\tstr_replace('%section%', 'page_index', $header_align),\n\t\tstr_replace('%section%', 'page_index', $header_position),\n\t\tstr_replace('%section%', 'page_index', $header_title_font),\n\t\tstr_replace('%section%', 'page_index', $header_title_size),\n\t\tstr_replace('%section%', 'page_index', $header_title_height),\n\t\tstr_replace('%section%', 'page_index', $header_title_spacing),\n\t\tstr_replace('%section%', 'page_index', $header_title_weight),\n\t\tstr_replace('%section%', 'page_index', $header_title_transform),\n\t\tstr_replace('%section%', 'page_index', $header_title_italic),\n\t\tstr_replace('%section%', 'page_index', $header_text_animation),\n\t\tstr_replace('%section%', 'page_index', $header_animation_speed),\n\t\tstr_replace('%section%', 'page_index', $header_animation_delay),\n\t\tstr_replace('%section%', 'page_index', $header_featured),\n\t\tstr_replace('%section%', 'page_index', $header_background),\n\t\tstr_replace('%section%', 'page_index', $header_parallax),\n\t\tstr_replace('%section%', 'page_index', $header_kburns),\n\t\tstr_replace('%section%', 'page_index', $header_overlay_color),\n\t\tstr_replace('%section%', 'page_index', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'page_index', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'page_index', $header_scrolldown),\n\t\tstr_replace('%section%', 'page_index', $menu_no_padding),\n\t\tstr_replace('%section%', 'page_index', $menu_no_padding_mobile),\n\n\t\tstr_replace('%section%', 'page_index', $body_section_title),\n\t\tstr_replace('%section%', 'page_index', $show_breadcrumb),\n\t\tstr_replace('%section%', 'page_index', $breadcrumb_align),\n\t\tstr_replace('%section%', 'page_index', $body_uncode_block),\n\t\tstr_replace('%section%', 'page_index', $body_layout_width),\n\t\tstr_replace('%section%', 'page_index', $body_single_post_width),\n\t\tstr_replace('%section%', 'page_index', $body_single_text_lenght),\n\t\tstr_replace('%section%', 'page_index', $show_title),\n\t\tstr_replace('%section%', 'page_index', $remove_pagination),\n\t\tstr_replace('%section%', 'page_index', $sidebar_section_title),\n\t\tstr_replace('%section%', 'page_index', run_array_to($sidebar_activate, 'std', 'on')),\n\t\tstr_replace('%section%', 'page_index', $sidebar_widget),\n\t\tstr_replace('%section%', 'page_index', $sidebar_position),\n\t\tstr_replace('%section%', 'page_index', $sidebar_size),\n\t\tstr_replace('%section%', 'page_index', $sidebar_sticky),\n\t\tstr_replace('%section%', 'page_index', $sidebar_style),\n\t\tstr_replace('%section%', 'page_index', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'page_index', $sidebar_fill),\n\t\tstr_replace('%section%', 'page_index', $footer_section_title),\n\t\tstr_replace('%section%', 'page_index', $footer_uncode_block),\n\t\tstr_replace('%section%', 'page_index', $footer_width),\n\t\t////////////////////////\n\t\t// Archive Index\t\t///\n\t\t////////////////////////\n\t\tstr_replace('%section%', 'portfolio_index', $menu_section_title),\n\t\tstr_replace('%section%', 'portfolio_index', $menu),\n\t\tstr_replace('%section%', 'portfolio_index', $menu_width),\n\t\tstr_replace('%section%', 'portfolio_index', $menu_opaque),\n\t\tstr_replace('%section%', 'portfolio_index', $header_section_title),\n\t\tstr_replace('%section%', 'portfolio_index', run_array_to($header_type, 'std', 'header_basic')),\n\t\tstr_replace('%section%', 'portfolio_index', $header_uncode_block),\n\t\tstr_replace('%section%', 'portfolio_index', $header_revslider),\n\t\tstr_replace('%section%', 'portfolio_index', $header_layerslider),\n\n\t\tstr_replace('%section%', 'portfolio_index', $header_width),\n\t\tstr_replace('%section%', 'portfolio_index', $header_height),\n\t\tstr_replace('%section%', 'portfolio_index', $header_min_height),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title),\n\t\tstr_replace('%section%', 'portfolio_index', $header_style),\n\t\tstr_replace('%section%', 'portfolio_index', $header_content_width),\n\t\tstr_replace('%section%', 'portfolio_index', $header_custom_width),\n\t\tstr_replace('%section%', 'portfolio_index', $header_align),\n\t\tstr_replace('%section%', 'portfolio_index', $header_position),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_font),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_size),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_height),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_spacing),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_weight),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_transform),\n\t\tstr_replace('%section%', 'portfolio_index', $header_title_italic),\n\t\tstr_replace('%section%', 'portfolio_index', $header_text_animation),\n\t\tstr_replace('%section%', 'portfolio_index', $header_animation_speed),\n\t\tstr_replace('%section%', 'portfolio_index', $header_animation_delay),\n\t\tstr_replace('%section%', 'portfolio_index', $header_featured),\n\t\tstr_replace('%section%', 'portfolio_index', $header_background),\n\t\tstr_replace('%section%', 'portfolio_index', $header_parallax),\n\t\tstr_replace('%section%', 'portfolio_index', $header_kburns),\n\t\tstr_replace('%section%', 'portfolio_index', $header_overlay_color),\n\t\tstr_replace('%section%', 'portfolio_index', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'portfolio_index', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'portfolio_index', $header_scrolldown),\n\t\tstr_replace('%section%', 'portfolio_index', $menu_no_padding),\n\t\tstr_replace('%section%', 'portfolio_index', $menu_no_padding_mobile),\n\t\tstr_replace('%section%', 'portfolio_index', $title_archive_custom_activate),\n\t\tstr_replace('%section%', 'portfolio_index', $title_archive_custom_text),\n\t\tstr_replace('%section%', 'portfolio_index', $subtitle_archive_custom_text),\n\n\t\tstr_replace('%section%', 'portfolio_index', $body_section_title),\n\t\tstr_replace('%section%', 'portfolio_index', $show_breadcrumb),\n\t\tstr_replace('%section%', 'portfolio_index', $breadcrumb_align),\n\t\tstr_replace('%section%', 'portfolio_index', $body_uncode_block),\n\t\tstr_replace('%section%', 'portfolio_index', $body_layout_width),\n\t\tstr_replace('%section%', 'portfolio_index', $body_single_post_width),\n\t\tstr_replace('%section%', 'portfolio_index', $show_title),\n\t\tstr_replace('%section%', 'portfolio_index', $remove_pagination),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_section_title),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_activate),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_widget),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_position),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_size),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_sticky),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_style),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'portfolio_index', $sidebar_fill),\n\t\tstr_replace('%section%', 'portfolio_index', $footer_section_title),\n\t\tstr_replace('%section%', 'portfolio_index', $footer_uncode_block),\n\t\tstr_replace('%section%', 'portfolio_index', $footer_width),\n\t);\n\n\t$custom_settings_one = array_merge( $custom_settings_one, $custom_settings_two );\n\t$custom_settings_one = array_merge( $custom_settings_one, $cpt_index_options );\n\n\t$custom_settings_three = array(\n\t\t///////////////////////\n\t\t// Search Index\t\t///\n\t\t///////////////////////\n\t\tstr_replace('%section%', 'search_index', $menu_section_title),\n\t\tstr_replace('%section%', 'search_index', $menu),\n\t\tstr_replace('%section%', 'search_index', $menu_width),\n\t\tstr_replace('%section%', 'search_index', $menu_opaque),\n\t\tstr_replace('%section%', 'search_index', $header_section_title),\n\t\tstr_replace('%section%', 'search_index', run_array_to($header_type, 'std', 'header_basic')),\n\t\tstr_replace('%section%', 'search_index', $header_uncode_block),\n\t\tstr_replace('%section%', 'search_index', $header_revslider),\n\t\tstr_replace('%section%', 'search_index', $header_layerslider),\n\n\t\tstr_replace('%section%', 'search_index', $header_width),\n\t\tstr_replace('%section%', 'search_index', $header_height),\n\t\tstr_replace('%section%', 'search_index', $header_min_height),\n\t\tstr_replace('%section%', 'search_index', $header_title),\n\t\tstr_replace('%section%', 'search_index', $header_title_text),\n\t\tstr_replace('%section%', 'search_index', $header_style),\n\t\tstr_replace('%section%', 'search_index', $header_content_width),\n\t\tstr_replace('%section%', 'search_index', $header_custom_width),\n\t\tstr_replace('%section%', 'search_index', $header_align),\n\t\tstr_replace('%section%', 'search_index', $header_position),\n\t\tstr_replace('%section%', 'search_index', $header_title_font),\n\t\tstr_replace('%section%', 'search_index', $header_title_size),\n\t\tstr_replace('%section%', 'search_index', $header_title_height),\n\t\tstr_replace('%section%', 'search_index', $header_title_spacing),\n\t\tstr_replace('%section%', 'search_index', $header_title_weight),\n\t\tstr_replace('%section%', 'search_index', $header_title_transform),\n\t\tstr_replace('%section%', 'search_index', $header_title_italic),\n\t\tstr_replace('%section%', 'search_index', $header_text_animation),\n\t\tstr_replace('%section%', 'search_index', $header_animation_speed),\n\t\tstr_replace('%section%', 'search_index', $header_animation_delay),\n\t\tstr_replace('%section%', 'search_index', $header_background),\n\t\tstr_replace('%section%', 'search_index', $header_parallax),\n\t\tstr_replace('%section%', 'search_index', $header_kburns),\n\t\tstr_replace('%section%', 'search_index', $header_overlay_color),\n\t\tstr_replace('%section%', 'search_index', $header_overlay_color_alpha),\n\t\tstr_replace('%section%', 'search_index', $header_scroll_opacity),\n\t\tstr_replace('%section%', 'search_index', $header_scrolldown),\n\t\tstr_replace('%section%', 'search_index', $menu_no_padding),\n\t\tstr_replace('%section%', 'search_index', $menu_no_padding_mobile),\n\t\tstr_replace('%section%', 'search_index', $title_archive_custom_activate),\n\t\tstr_replace('%section%', 'search_index', $title_archive_custom_text),\n\t\tstr_replace('%section%', 'search_index', $subtitle_archive_custom_text),\n\n\t\tstr_replace('%section%', 'search_index', $body_section_title),\n\t\tstr_replace('%section%', 'search_index', $body_uncode_block),\n\t\tstr_replace('%section%', 'search_index', $body_layout_width),\n\t\tstr_replace('%section%', 'search_index', $remove_pagination),\n\t\tstr_replace('%section%', 'search_index', $sidebar_section_title),\n\t\tstr_replace('%section%', 'search_index', $sidebar_activate),\n\t\tstr_replace('%section%', 'search_index', $sidebar_widget),\n\t\tstr_replace('%section%', 'search_index', $sidebar_position),\n\t\tstr_replace('%section%', 'search_index', $sidebar_size),\n\t\tstr_replace('%section%', 'search_index', $sidebar_sticky),\n\t\tstr_replace('%section%', 'search_index', $sidebar_style),\n\t\tstr_replace('%section%', 'search_index', $sidebar_bgcolor),\n\t\tstr_replace('%section%', 'search_index', $sidebar_fill),\n\t\tstr_replace('%section%', 'search_index', $footer_section_title),\n\t\tstr_replace('%section%', 'search_index', $footer_uncode_block),\n\t\tstr_replace('%section%', 'search_index', $footer_width),\n\n\t\tarray(\n\t\t\t'id' => '_uncode_sidebars',\n\t\t\t'label' => esc_html__('Site sidebars', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the sidebars you will need. A default sidebar is already defined.', 'uncode') ,\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_sidebars_section',\n\t\t\t'class' => 'list-item',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_sidebar_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'sidebar-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique sidebar ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_font_groups',\n\t\t\t'label' => esc_html__('Custom fonts', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the fonts you will need.', 'uncode') ,\n\t\t\t'std' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'title' => 'Font Default',\n\t\t\t\t\t'_uncode_font_group_unique_id' => 'font-555555',\n\t\t\t\t\t'_uncode_font_group' => 'manual',\n\t\t\t\t\t'_uncode_font_manual' => '-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif'\n\t\t\t\t),\n\t\t\t),\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_font_group_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'font-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique font ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_font_group',\n\t\t\t\t\t'label' => esc_html__('Uncode font', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Specify a font.', 'uncode') ,\n\t\t\t\t\t'type' => 'select',\n\t\t\t\t\t'choices' => $title_font,\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_font_manual',\n\t\t\t\t\t'label' => esc_html__('Font family', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Enter a font family.', 'uncode') ,\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'condition' => '_uncode_font_group:is(manual)',\n\t\t\t\t\t'operator' => 'and'\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_font_size',\n\t\t\t'label' => esc_html__('Default font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for p,li,dt,dd,dl,address,label,small,pre in px.', 'uncode') ,\n\t\t\t'std' => '15',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_large_text_size',\n\t\t\t'label' => esc_html__('Large text font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for large text in px.', 'uncode') ,\n\t\t\t'std' => '18',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h1',\n\t\t\t'label' => esc_html__('Font size H1', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H1 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '35',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h2',\n\t\t\t'label' => esc_html__('Font size H2', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H2 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '29',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h3',\n\t\t\t'label' => esc_html__('Font size H3', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H3 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '24',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h4',\n\t\t\t'label' => esc_html__('Font size H4', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H4 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '20',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h5',\n\t\t\t'label' => esc_html__('Font size H5', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H5 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '17',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_h6',\n\t\t\t'label' => esc_html__('Font size H6', 'uncode') ,\n\t\t\t'desc' => esc_html__('Font size for H6 in <b>px</b>.', 'uncode') ,\n\t\t\t'std' => '14',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_font_sizes',\n\t\t\t'label' => esc_html__('Custom font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the additional font sizes you will need.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_size_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'fontsize-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique font size ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_size',\n\t\t\t\t\t'label' => esc_html__('Font size', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Font size in <b>px</b>.', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_font_heights',\n\t\t\t'label' => esc_html__('Custom line height', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the additional font line heights you will need.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_height_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'fontheight-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique font height ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_height',\n\t\t\t\t\t'label' => esc_html__('Font line height', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Insert a line height.', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_font_spacings',\n\t\t\t'label' => esc_html__('Custom letter spacing', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the letter spacings you will need.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_typography_section',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_spacing_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'fontspace-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique letter spacing ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_heading_font_spacing',\n\t\t\t\t\t'label' => esc_html__('Letter spacing', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Letter spacing with the unit (em or px). Ex. 0.2em', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_colors_list',\n\t\t\t'label' => esc_html__('Color palettes', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define all the colors you will need.', 'uncode') ,\n\t\t\t'std' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Black','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-jevc',\n\t\t\t\t\t'_uncode_custom_color' => '#000000',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Dark 1','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-nhtu',\n\t\t\t\t\t'_uncode_custom_color' => '#101213',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Dark 2','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-wayh',\n\t\t\t\t\t'_uncode_custom_color' => '#141618',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Dark 3','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-rgdb',\n\t\t\t\t\t'_uncode_custom_color' => '#1b1d1f',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Dark 4','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-prif',\n\t\t\t\t\t'_uncode_custom_color' => '#303133',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('White','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-xsdn',\n\t\t\t\t\t'_uncode_custom_color' => '#ffffff',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Light 1','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-lxmt',\n\t\t\t\t\t'_uncode_custom_color' => '#f7f7f7',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Light 2','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-gyho',\n\t\t\t\t\t'_uncode_custom_color' => '#eaeaea',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Light 3','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-uydo',\n\t\t\t\t\t'_uncode_custom_color' => '#dddddd',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Light 4','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-wvjs',\n\t\t\t\t\t'_uncode_custom_color' => '#777',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Cerulean','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-vyce',\n\t\t\t\t\t'_uncode_custom_color' => '#0cb4ce',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'title' => esc_html__('Blue Ribbon','uncode'),\n\t\t\t\t\t'_uncode_custom_color_unique_id' => 'color-210407',\n\t\t\t\t\t'_uncode_custom_color' => '#006cff',\n\t\t\t\t\t'_uncode_custom_color_regular' => 'on',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_colors_section',\n\t\t\t'class' => 'list-colors',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_custom_color_unique_id',\n\t\t\t\t\t'std' => 'color-',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique color ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_custom_color_regular',\n\t\t\t\t\t'label' => esc_html__('Monochrome', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Activate to assign a monochromatic color, otherwise a gradient will be used.', 'uncode') ,\n\t\t\t\t\t'std' => 'on',\n\t\t\t\t\t'type' => 'on-off',\n\t\t\t\t\t'section' => 'uncode_customize_section',\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_custom_color',\n\t\t\t\t\t'label' => esc_html__('Colorpicker', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Specify the color for this palette. You can also define a color with the alpha value.', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'condition' => '_uncode_custom_color_regular:is(on)',\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_custom_color_gradient',\n\t\t\t\t\t'label' => esc_html__('Gradient', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Specify the gradient color for this palette. NB. You can use a gradient color only as a background color.', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'gradientpicker',\n\t\t\t\t\t'condition' => '_uncode_custom_color_regular:is(off)',\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_light_block_title',\n\t\t\t'label' => '<i class=\"fa fa-square-o\"></i> ' . esc_html__('Light skin', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_color_light',\n\t\t\t'label' => esc_html__('SVG/Text logo color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the logo color if it\\'s a SVG or textual.', 'uncode') ,\n\t\t\t'std' => 'color-prif',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_color_light',\n\t\t\t'label' => esc_html__('Menu text color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu text color.', 'uncode') ,\n\t\t\t'std' => 'color-prif',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_bg_color_light',\n\t\t\t'label' => esc_html__('Primary menu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary menu background color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_bg_alpha_light',\n\t\t\t'label' => esc_html__('Primary menu background opacity', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the primary menu background transparency.', 'uncode') ,\n\t\t\t'std' => '100',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_submenu_bg_color_light',\n\t\t\t'label' => esc_html__('Primary submenu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary submenu background color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_border_color_light',\n\t\t\t'label' => esc_html__('Primary menu border color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary menu border color.', 'uncode') ,\n\t\t\t'std' => 'color-gyho',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_border_alpha_light',\n\t\t\t'label' => esc_html__('Primary menu border opacity', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the primary menu border transparency.', 'uncode') ,\n\t\t\t'std' => '100',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_secmenu_bg_color_light',\n\t\t\t'label' => esc_html__('Secondary menu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the secondary menu background color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_color_light',\n\t\t\t'label' => esc_html__('Headings color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the headings text color.', 'uncode') ,\n\t\t\t'std' => 'color-prif',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_text_color_light',\n\t\t\t'label' => esc_html__('Content text color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the content area text color.', 'uncode') ,\n\t\t\t'std' => 'color-wvjs',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_background_color_light',\n\t\t\t'label' => esc_html__('Content background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the content background color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_dark_block_title',\n\t\t\t'label' => '<i class=\"fa fa-square\"></i> ' . esc_html__('Dark skin', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_logo_color_dark',\n\t\t\t'label' => esc_html__('SVG/Text logo color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the logo color if it\\'s a SVG or textual.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_color_dark',\n\t\t\t'label' => esc_html__('Menu text color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu text color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_bg_color_dark',\n\t\t\t'label' => esc_html__('Primary menu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary menu background color.', 'uncode') ,\n\t\t\t'std' => 'color-wayh',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_bg_alpha_dark',\n\t\t\t'label' => esc_html__('Primary menu background opacity', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the primary menu background transparency.', 'uncode') ,\n\t\t\t'std' => '100',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_submenu_bg_color_dark',\n\t\t\t'label' => esc_html__('Primary submenu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary submenu background color.', 'uncode') ,\n\t\t\t'std' => 'color-rgdb',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_border_color_dark',\n\t\t\t'label' => esc_html__('Primary menu border color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary menu border color.', 'uncode') ,\n\t\t\t'std' => 'color-prif',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_border_alpha_dark',\n\t\t\t'label' => esc_html__('Primary menu border opacity', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the primary menu border transparency.', 'uncode') ,\n\t\t\t'std' => '100',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_secmenu_bg_color_dark',\n\t\t\t'label' => esc_html__('Secondary menu background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the secondary menu background color.', 'uncode') ,\n\t\t\t'std' => 'color-wayh',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_color_dark',\n\t\t\t'label' => esc_html__('Headings color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the headings text color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_text_color_dark',\n\t\t\t'label' => esc_html__('Content text color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the content area text color.', 'uncode') ,\n\t\t\t'std' => 'color-xsdn',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_background_color_dark',\n\t\t\t'label' => esc_html__('Content background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the content background color.', 'uncode') ,\n\t\t\t'std' => 'color-wayh',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_general_block_title',\n\t\t\t'label' => '<i class=\"fa fa-globe3\"></i> ' . esc_html__('General', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_background',\n\t\t\t'label' => esc_html__('HTML body background', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the body background color and media.', 'uncode') ,\n\t\t\t'type' => 'background',\n\t\t\t'std' => array(\n\t\t\t\t'background-color' => 'color-lxmt',\n\t\t\t\t'background-repeat' => '',\n\t\t\t\t'background-attachment' => '',\n\t\t\t\t'background-position' => '',\n\t\t\t\t'background-size' => '',\n\t\t\t\t'background-image' => '',\n\t\t\t),\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_accent_color',\n\t\t\t'label' => esc_html__('Accent color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the accent color.', 'uncode') ,\n\t\t\t'std' => 'color-210407',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_link_color',\n\t\t\t'label' => esc_html__('Links color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the color of links in page textual contents.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'label' => esc_html__('Default', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'accent',\n\t\t\t\t\t'label' => esc_html__('Accent color', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_font_family',\n\t\t\t'label' => esc_html__('Body font family', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the body font family.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_body_font_weight',\n\t\t\t'label' => esc_html__('Body font weight', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the body font weight.', 'uncode') ,\n\t\t\t'std' => '400',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $title_weight\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_ui_font_family',\n\t\t\t'label' => esc_html__('UI font family', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the UI font family.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_ui_font_weight',\n\t\t\t'label' => esc_html__('UI font weight', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the UI font weight.', 'uncode') ,\n\t\t\t'std' => '600',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $title_weight\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_font_family',\n\t\t\t'label' => esc_html__('Headings font family', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the headings font family.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_heading_font_weight',\n\t\t\t'label' => esc_html__('Headings font weight', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the Headings font weight.', 'uncode') ,\n\t\t\t'std' => '600',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $title_weight\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_letter_spacing',\n\t\t\t'label' => esc_html__('Headings letter spacing', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the letter spacing in EMs.', 'uncode') ,\n\t\t\t'std' => '0.00',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_input_underline',\n\t\t\t'label' => esc_html__('Input text underlined', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to style all the input text with the underline.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_fallback_font',\n\t\t\t'label' => esc_html__('Fallback font', 'uncode') ,\n\t\t\t'desc' => esc_html__('Select a font to use as fallback when Google Fonts import is not available.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_style_block_title',\n\t\t\t'label' => '<i class=\"fa fa-menu\"></i> ' . esc_html__('Menu', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_overlay_menu_style',\n\t\t\t'label' => esc_html__('Overlay menu skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the overlay menu skin.', 'uncode') ,\n\t\t\t'std' => 'light',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'condition' => '_uncode_headers:is(menu-overlay),_uncode_headers:is(menu-overlay-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $stylesArrayMenu\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_color_hover',\n\t\t\t'label' => esc_html__('Menu highlight color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu active and hover effect color (If not specified an opaque version of the menu color will be used).', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_primary_menu_style',\n\t\t\t'label' => esc_html__('Primary menu skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary menu skin.', 'uncode') ,\n\t\t\t'std' => 'light',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'choices' => $stylesArrayMenu\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_primary_submenu_style',\n\t\t\t'label' => esc_html__('Primary submenu skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the primary submenu skin.', 'uncode') ,\n\t\t\t'std' => 'light',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'choices' => $stylesArrayMenu\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_secondary_menu_style',\n\t\t\t'label' => esc_html__('Secondary menu skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the secondary menu skin.', 'uncode') ,\n\t\t\t'std' => 'dark',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'condition' => '_uncode_headers:is(hmenu-right),_uncode_headers:is(hmenu-left),_uncode_headers:is(hmenu-justify),_uncode_headers:is(hmenu-center)',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $stylesArrayMenu\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_font_size',\n\t\t\t'label' => esc_html__('Menu font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu font size. NB: the Overlay menu font size is automatic relative to the viewport.', 'uncode') ,\n\t\t\t'std' => '12',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_submenu_font_size',\n\t\t\t'label' => esc_html__('Submenu font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the submenu font size. NB: the Overlay submenu font size is automatic relative to the viewport.', 'uncode') ,\n\t\t\t'std' => '12',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_mobile_font_size',\n\t\t\t'label' => esc_html__('Mobile menu font size', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu font size for mobile (when the Navbar > Animation > is not Menu Centered Mobile).', 'uncode') ,\n\t\t\t'std' => '12',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_font_family',\n\t\t\t'label' => esc_html__('Menu font family', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu font family.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_font_weight',\n\t\t\t'label' => esc_html__('Menu font weight', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the menu font weight.', 'uncode') ,\n\t\t\t'std' => '600',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $title_weight\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_letter_spacing',\n\t\t\t'label' => esc_html__('Menu letter spacing', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the letter spacing in EMs (the default value is 0.05).', 'uncode') ,\n\t\t\t'std' => '0.05',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_first_uppercase',\n\t\t\t'label' => esc_html__('Menu first level uppercase', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to transform the first menu level to uppercase.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_menu_other_uppercase',\n\t\t\t'label' => esc_html__('Menu other levels uppercase', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to transform all the others menu level to uppercase.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_content_block_title',\n\t\t\t'label' => '<i class=\"fa fa-layout\"></i> ' . esc_html__('Content', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_general_style',\n\t\t\t'label' => esc_html__('Skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the content skin.', 'uncode') ,\n\t\t\t'std' => 'light',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'light',\n\t\t\t\t\t'label' => esc_html__('Light', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'dark',\n\t\t\t\t\t'label' => esc_html__('Dark', 'uncode') ,\n\t\t\t\t\t'src' => ''\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_general_bg_color',\n\t\t\t'label' => esc_html__('Background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify a custom content background color.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_buttons_block_title',\n\t\t\t'label' => '<i class=\"fa fa-download3\"></i> ' . esc_html__('Buttons and Forms', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_buttons_font_family',\n\t\t\t'label' => esc_html__('Buttons font family', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the buttons font family.', 'uncode') ,\n\t\t\t'std' => 'font-555555',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $custom_fonts\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_buttons_font_weight',\n\t\t\t'label' => esc_html__('Buttons font weight', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the buttons font weight.', 'uncode') ,\n\t\t\t'std' => '600',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $title_weight\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_buttons_text_transform',\n\t\t\t'label' => esc_html__('Buttons text transform', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the buttons text transform.', 'uncode') ,\n\t\t\t'std' => 'uppercase',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'initial',\n\t\t\t\t\t'label' => esc_html__('Default', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'uppercase',\n\t\t\t\t\t'label' => esc_html__('Uppercase', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'lowercase',\n\t\t\t\t\t'label' => esc_html__('Lowercase', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'capitalize',\n\t\t\t\t\t'label' => esc_html__('Capitalize', 'uncode') ,\n\t\t\t\t) ,\n\t\t\t) ,\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_buttons_letter_spacing',\n\t\t\t'label' => esc_html__('Buttons letter spacing', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the letter spacing value.', 'uncode') ,\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'operator' => 'or',\n\t\t\t'choices' => $btn_letter_spacing,\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_buttons_border_width',\n\t\t\t'label' => esc_html__('Button and form fields border', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the width of the borders for buttons and form fields', 'uncode') ,\n\t\t\t'std' => '1',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '1,5,1',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_button_hover',\n\t\t\t'label' => esc_html__('Button hover effect', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify an effect on hover state.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => '',\n\t\t\t\t\t'label' => esc_html__('Outlined', 'uncode')\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'full-colored',\n\t\t\t\t\t'label' => esc_html__('Flat', 'uncode')\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_style_block_title',\n\t\t\t'label' => '<i class=\"fa fa-ellipsis\"></i> ' . esc_html__('Footer', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_last_style',\n\t\t\t'label' => esc_html__('Copyright area skin', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the copyright area skin color.', 'uncode') ,\n\t\t\t'std' => 'dark',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and',\n\t\t\t'choices' => $stylesArrayMenu\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_bg_color',\n\t\t\t'label' => esc_html__('Copyright area custom background color', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify a custom copyright area background color.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'uncode_color',\n\t\t\t'section' => 'uncode_customize_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_customize_extra_block_title',\n\t\t\t'label' => '<i class=\"fa fa-download3\"></i> ' . esc_html__('Scroll & Parallax', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_scroll_constant',\n\t\t\t'label' => esc_html__('ScrollTo constant speed', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this to always have a constant speed when scrolling to point.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_scroll_constant_factor',\n\t\t\t'label' => esc_html__('ScrollTo constant speed factor', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the constant scroll speed factor. Default 2', 'uncode') ,\n\t\t\t'std' => '2',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '1,15,0.25',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_scroll_constant:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_scroll_speed_value',\n\t\t\t'label' => esc_html__('ScrollTo speed fixed', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the scroll speed time in milliseconds.', 'uncode') ,\n\t\t\t'std' => '1000',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_scroll_constant:is(off)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_parallax_factor',\n\t\t\t'label' => esc_html__('Parallax speed factor', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the parallax speed factor. Default 2.5', 'uncode') ,\n\t\t\t'std' => '2.5',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '0.5,3,0.5',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_portfolio_block_title',\n\t\t\t'label' => '<i class=\"fa fa-briefcase3\"></i> ' . ucfirst($portfolio_cpt_name) . ' ' . esc_html__('CPT', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_cpt',\n\t\t\t'label' => ucfirst($portfolio_cpt_name) . ' ' . esc_html__('CPT label', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter a custom portfolio post type label.', 'uncode') ,\n\t\t\t'std' => 'portfolio',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_portfolio_cpt_slug',\n\t\t\t'label' => ucfirst($portfolio_cpt_name) . ' ' . esc_html__('CPT slug', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter a custom portfolio post type slug.', 'uncode') ,\n\t\t\t'std' => 'portfolio',\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t)\n\t);\n\n\tif (class_exists('WooCommerce')) {\n\n\t\t$custom_settings_three[] = array(\n\t\t\t'id' => '_uncode_woocommerce_block_title',\n\t\t\t'label' => '<i class=\"fa fa-shopping-cart\"></i> ' . esc_html__('WooCommerce', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t);\n\n\t\t$custom_settings_three[] = array(\n\t\t\t'id' => '_uncode_woocommerce_cart_icon',\n\t\t\t'label' => esc_html__('Cart icon', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the cart icon', 'uncode') ,\n\t\t\t'std' => 'fa fa-bag',\n\t\t\t'type' => 'text',\n\t\t\t'class' => 'button_icon_container',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t);\n\n\t\t$custom_settings_three[] = array(\n\t\t\t'id' => '_uncode_woocommerce_hooks',\n\t\t\t'label' => esc_html__('Enable Hooks', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this to enable default WooCommerce hooks on product loops.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t);\n\n\t\t$custom_settings_three[] = array(\n\t\t\t'id' => '_uncode_woocommerce_enhanced_atc',\n\t\t\t'label' => esc_html__('Enhance Add To Cart Button', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this to enable the enhanced Add To Cart button on loops.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t);\n\t}\n\n\t$custom_settings_four = array(\n\t\tarray(\n\t\t\t'id' => '_uncode_customize_admin_block_title',\n\t\t\t'label' => '<i class=\"fa fa-dashboard\"></i> ' . esc_html__('Admin', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_admin_help',\n\t\t\t'label' => esc_html__('Help button in admin bar', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to show the Uncode help button in the WP admin bar.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_extra_section',\n\t\t) ,\n\t);\n\n\t$custom_settings_five = array(\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_layout_block_title',\n\t\t\t'label' => '<i class=\"fa fa-layers\"></i> ' . esc_html__('Layout', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_full',\n\t\t\t'label' => esc_html__('Footer full width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Expand the footer to full width.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t\t'condition' => '_uncode_boxed:is(off)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_content_block_title',\n\t\t\t'label' => '<i class=\"fa fa-cog2\"></i> ' . esc_html__('Widget area', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_block',\n\t\t\t'label' => esc_html__('Content Block', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the Content Block to use as a footer content.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'custom-post-type-select',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t\t'post_type' => 'uncodeblock',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_last_block_title',\n\t\t\t'label' => '<i class=\"fa fa-copyright\"></i> ' . esc_html__('Copyright area', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_copy_hide',\n\t\t\t'label' => esc_html__('Hide Copyright Area', 'uncode') ,\n\t\t\t'type' => 'on-off',\n\t\t\t'desc' => esc_html__('Activate this to hide the Copyright Area.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_copyright',\n\t\t\t'label' => esc_html__('Automatic copyright text', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to use an automatic copyright text.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_text',\n\t\t\t'label' => esc_html__('Custom copyright text', 'uncode') ,\n\t\t\t'desc' => esc_html__('Insert a custom text for the footer copyright area.', 'uncode') ,\n\t\t\t'type' => 'textarea',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_footer_copyright:is(off)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_position',\n\t\t\t'label' => esc_html__('Content alignment', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the footer copyright text alignment.', 'uncode') ,\n\t\t\t'std' => 'left',\n\t\t\t'type' => 'select',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t\t'choices' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t'label' => esc_html__('Left', 'uncode')\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'center',\n\t\t\t\t\t'label' => esc_html__('Center', 'uncode')\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t'label' => esc_html__('Right', 'uncode')\n\t\t\t\t)\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_social',\n\t\t\t'label' => esc_html__('Social links', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to have the social icons in the footer copyright area.', 'uncode') ,\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_add_block_title',\n\t\t\t'label' => '<i class=\"fa fa-square-plus\"></i> ' . esc_html__('Additionals', 'uncode') ,\n\t\t\t'type' => 'textblock-titled',\n\t\t\t'class' => 'section-title',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_uparrow',\n\t\t\t'label' => esc_html__('Scroll up button', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to add a scroll up button in the footer.', 'uncode') ,\n\t\t\t'type' => 'on-off',\n\t\t\t'std' => 'on',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_footer_uparrow_mobile',\n\t\t\t'label' => esc_html__('Scroll up button on mobile', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to add a scroll up button in the footer for mobile devices.', 'uncode') ,\n\t\t\t'type' => 'on-off',\n\t\t\t'std' => 'on',\n\t\t\t'condition' => '_uncode_footer_uparrow:is(on)',\n\t\t\t'operator' => 'and',\n\t\t\t'section' => 'uncode_footer_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_social_list',\n\t\t\t'label' => esc_html__('Social Networks', 'uncode') ,\n\t\t\t'desc' => esc_html__('Define here all the social networks you will need.', 'uncode') ,\n\t\t\t'type' => 'list-item',\n\t\t\t'section' => 'uncode_connections_section',\n\t\t\t'class' => 'list-social',\n\t\t\t'settings' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_social_unique_id',\n\t\t\t\t\t'class' => 'unique_id',\n\t\t\t\t\t'std' => 'social-',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'label' => esc_html__('Unique social ID','uncode'),\n\t\t\t\t\t'desc' => esc_html__('This value is created automatically and it shouldn\\'t be edited unless you know what you are doing.','uncode'),\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_social',\n\t\t\t\t\t'label' => esc_html__('Social Network Icon', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Specify the social network icon.', 'uncode') ,\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'class' => 'button_icon_container',\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_link',\n\t\t\t\t\t'label' => esc_html__('Social Network Link', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Enter your social network link.', 'uncode') ,\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'condition' => '',\n\t\t\t\t\t'operator' => 'and'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '_uncode_menu_hidden',\n\t\t\t\t\t'label' => esc_html__('Hide In The Menu', 'uncode') ,\n\t\t\t\t\t'desc' => esc_html__('Activate to hide the social icon in the menu (if the social connections in the menu is active).', 'uncode') ,\n\t\t\t\t\t'std' => 'off',\n\t\t\t\t\t'type' => 'on-off',\n\t\t\t\t\t'condition' => '',\n\t\t\t\t\t'operator' => 'and'\n\t\t\t\t) ,\n\t\t\t)\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_gmaps_api',\n\t\t\t'label' => esc_html__('Google Maps API KEY', 'uncode') ,\n\t\t\t'desc' => sprintf( wp_kses(__( 'To use Uncode custom styled Google Maps you need to create <a href=\"%s\" target=\"_blank\">here the Google API KEY</a> and paste it in this field.', 'uncode' ), array( 'a' => array( 'href' => array(),'target' => array() ) ) ), 'https://developers.google.com/maps/documentation/javascript/get-api-key#get-an-api-key' ),\n\t\t\t'type' => 'text',\n\t\t\t'section' => 'uncode_gmaps_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_css',\n\t\t\t'label' => esc_html__('CSS', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter here your custom CSS.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'css',\n\t\t\t'section' => 'uncode_cssjs_section',\n\t\t\t'rows' => '20',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_js',\n\t\t\t'label' => esc_html__('Javascript', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter here your custom Javacript code.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'textarea-simple',\n\t\t\t'section' => 'uncode_cssjs_section',\n\t\t\t'rows' => '20',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_custom_tracking',\n\t\t\t'label' => esc_html__('Tracking', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter here your custom Tracking code.', 'uncode') ,\n\t\t\t'std' => '',\n\t\t\t'type' => 'textarea-simple',\n\t\t\t'section' => 'uncode_cssjs_section',\n\t\t\t'rows' => '20',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive',\n\t\t\t'label' => esc_html__('Adaptive images', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to take advantage of the Adaptive Images system. Adaptive Images detects your visitor\\'s screen size and automatically delivers device appropriate re-scaled images.', 'uncode') ,\n\t\t\t'std' => 'on',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_async',\n\t\t\t'label' => esc_html__('Asynchronous adaptive image system', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to load the adaptive images asynchronously, this will improve the loading performance and it\\'s necessary if using an aggresive caching system.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_adaptive:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_async_blur',\n\t\t\t'label' => esc_html__('Asynchronous loading blur effect', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to use a bluring effect when loading the images.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'and',\n\t\t\t'condition' => '_uncode_adaptive:is(on),_uncode_adaptive_async:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_mobile_advanced',\n\t\t\t'label' => esc_html__('Mobile settings', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to set specific mobile options.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_adaptive:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_use_orientation_width',\n\t\t\t'label' => esc_html__('Use current mobile orientation width', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to use the current mobile orientation width (portrait or landscape) instead of the max device\\'s width (landscape).', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'and',\n\t\t\t'condition' => '_uncode_adaptive:is(on),_uncode_adaptive_mobile_advanced:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_limit_density',\n\t\t\t'label' => esc_html__('Limit device density', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to limit the pixel density to 2 when generating the most appropriate image for high pixel density displays.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'and',\n\t\t\t'condition' => '_uncode_adaptive:is(on),_uncode_adaptive_mobile_advanced:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_quality',\n\t\t\t'label' => esc_html__('Image quality', 'uncode') ,\n\t\t\t'desc' => esc_html__('Adjust the images compression quality.', 'uncode') ,\n\t\t\t'std' => '90',\n\t\t\t'type' => 'numeric-slider',\n\t\t\t'min_max_step'=> '60,100,1',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_adaptive:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_adaptive_sizes',\n\t\t\t'label' => esc_html__('Image sizes range', 'uncode') ,\n\t\t\t'desc' => esc_html__('Enter all the image sizes you want use for the Adaptive Images system. NB. The values needs to be comma separated.', 'uncode') ,\n\t\t\t'type' => 'text',\n\t\t\t'std' => '258,516,720,1032,1440,2064,2880',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'operator' => 'or',\n\t\t\t'condition' => '_uncode_adaptive:is(on)',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_htaccess',\n\t\t\t'label' => esc_html__('Apache Server Configs', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate the enhanced .htaccess, this will improve the web site\\'s performance and security.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_production',\n\t\t\t'label' => esc_html__('Production mode', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate this to switch to production mode, the CSS and JS will be cached by the browser and the JS minified.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_performance_section',\n\t\t\t'condition' => '',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_redirect',\n\t\t\t'label' => esc_html__('Activate page redirect', 'uncode') ,\n\t\t\t'desc' => esc_html__('Activate to redirect all the website calls to a specific page. NB. This can only be visible when the user is not logged in.', 'uncode') ,\n\t\t\t'std' => 'off',\n\t\t\t'type' => 'on-off',\n\t\t\t'section' => 'uncode_redirect_section',\n\t\t) ,\n\t\tarray(\n\t\t\t'id' => '_uncode_redirect_page',\n\t\t\t'label' => esc_html__('Redirect page', 'uncode') ,\n\t\t\t'desc' => esc_html__('Specify the redirect page. NB. This page will be presented without menu and footer.', 'uncode') ,\n\t\t\t'type' => 'page_select',\n\t\t\t'section' => 'uncode_redirect_section',\n\t\t\t'post_type' => 'page',\n\t\t\t'condition' => '_uncode_redirect:is(on)',\n\t\t\t'operator' => 'and'\n\t\t) ,\n\t);\n\n\t$custom_settings_one = array_merge( $custom_settings_one, $custom_settings_three );\n\n\tif ( ! defined('ENVATO_HOSTED_SITE') )\n\t\t$custom_settings_one = array_merge( $custom_settings_one, $custom_settings_four );\n\n\t$custom_settings_one = array_merge( $custom_settings_one, $custom_settings_five );\n\n\t$custom_settings = array(\n\t\t'sections' => $custom_settings_section_one,\n\t\t'settings' => $custom_settings_one,\n\t);\n\n\tif (class_exists('WooCommerce'))\n\t{\n\n\t\t$woo_section = array(\n\t\t\t// array(\n\t\t\t// \t'id' => 'uncode_woocommerce_section',\n\t\t\t// \t'title' => '<i class=\"fa fa-shopping-cart\"></i> ' . esc_html__('WooCommerce', 'uncode')\n\t\t\t// ),\n\t\t\tarray(\n\t\t\t\t'id' => 'uncode_product_section',\n\t\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-paper\"></i> ' . esc_html__('Product', 'uncode') . '</span>',\n\t\t\t\t'group' => esc_html__('Single', 'uncode'),\n\t\t\t) ,\n\t\t\tarray(\n\t\t\t\t'id' => 'uncode_product_index_section',\n\t\t\t\t'title' => '<span class=\"smaller\"><i class=\"fa fa-archive2\"></i> ' . esc_html__('Products', 'uncode') . '</span>',\n\t\t\t\t'group' => esc_html__('Archives', 'uncode'),\n\t\t\t) ,\n\t\t);\n\n\t\t$menus_array[] = array(\n\t\t\t'value' => '',\n\t\t\t'label' => esc_html__('Select…', 'uncode')\n\t\t);\n\t\t$menu_array = array();\n\t\t$nav_menus = get_registered_nav_menus();\n\n\t\tforeach ($nav_menus as $location => $description)\n\t\t{\n\n\t\t\t$menu_array['value'] = $location;\n\t\t\t$menu_array['label'] = $description;\n\t\t\t$menus_array[] = $menu_array;\n\t\t}\n\n\t\t$menus_array[] = array(\n\t\t\t'value' => 'social',\n\t\t\t'label' => esc_html__('Social Menu', 'uncode')\n\t\t);\n\n\t\t$woocommerce_post = array(\n\t\t\t/////////////////////////\n\t\t\t// Product Single\t\t///\n\t\t\t/////////////////////////\n\t\t\tstr_replace('%section%', 'product', $menu_section_title),\n\t\t\tstr_replace('%section%', 'product', $menu),\n\t\t\tstr_replace('%section%', 'product', $menu_width),\n\t\t\tstr_replace('%section%', 'product', $menu_opaque),\n\t\t\tstr_replace('%section%', 'product', $header_section_title),\n\t\t\tstr_replace('%section%', 'product', $header_type),\n\t\t\tstr_replace('%section%', 'product', $header_uncode_block),\n\t\t\tstr_replace('%section%', 'product', $header_revslider),\n\t\t\tstr_replace('%section%', 'product', $header_layerslider),\n\n\t\t\tstr_replace('%section%', 'product', $header_width),\n\t\t\tstr_replace('%section%', 'product', $header_height),\n\t\t\tstr_replace('%section%', 'product', $header_min_height),\n\t\t\tstr_replace('%section%', 'product', $header_title),\n\t\t\tstr_replace('%section%', 'product', $header_style),\n\t\t\tstr_replace('%section%', 'product', $header_content_width),\n\t\t\tstr_replace('%section%', 'product', $header_custom_width),\n\t\t\tstr_replace('%section%', 'product', $header_align),\n\t\t\tstr_replace('%section%', 'product', $header_position),\n\t\t\tstr_replace('%section%', 'product', $header_title_font),\n\t\t\tstr_replace('%section%', 'product', $header_title_size),\n\t\t\tstr_replace('%section%', 'product', $header_title_height),\n\t\t\tstr_replace('%section%', 'product', $header_title_spacing),\n\t\t\tstr_replace('%section%', 'product', $header_title_weight),\n\t\t\tstr_replace('%section%', 'product', $header_title_transform),\n\t\t\tstr_replace('%section%', 'product', $header_title_italic),\n\t\t\tstr_replace('%section%', 'product', $header_text_animation),\n\t\t\tstr_replace('%section%', 'product', $header_animation_speed),\n\t\t\tstr_replace('%section%', 'product', $header_animation_delay),\n\t\t\tstr_replace('%section%', 'product', $header_featured),\n\t\t\tstr_replace('%section%', 'product', $header_background),\n\t\t\tstr_replace('%section%', 'product', $header_parallax),\n\t\t\tstr_replace('%section%', 'product', $header_kburns),\n\t\t\tstr_replace('%section%', 'product', $header_overlay_color),\n\t\t\tstr_replace('%section%', 'product', $header_overlay_color_alpha),\n\t\t\tstr_replace('%section%', 'product', $header_scroll_opacity),\n\t\t\tstr_replace('%section%', 'product', $header_scrolldown),\n\n\t\t\tstr_replace('%section%', 'product', $body_section_title),\n\t\t\tstr_replace('%section%', 'product', $body_layout_width),\n\t\t\tstr_replace('%section%', 'product', $body_layout_width_custom),\n\t\t\tstr_replace('%section%', 'product', $show_breadcrumb),\n\t\t\tstr_replace('%section%', 'product', $breadcrumb_align),\n\t\t\tstr_replace('%section%', 'product', $show_title),\n\t\t\tstr_replace('%section%', 'product', $show_share),\n\t\t\tstr_replace('%section%', 'product', $image_layout),\n\t\t\tstr_replace('%section%', 'product', $media_size),\n\t\t\tstr_replace('%section%', 'product', $enable_sticky_desc),\n\t\t\tstr_replace('%section%', 'product', $enable_woo_zoom),\n\t\t\tstr_replace('%section%', 'product', $thumb_cols),\n\t\t\tstr_replace('%section%', 'product', $enable_woo_slider),\n\t\t\tstr_replace('%section%', 'product', $body_uncode_block_after),\n\t\t\tstr_replace('%section%', 'product', $navigation_section_title),\n\t\t\tstr_replace('%section%', 'product', $navigation_activate),\n\t\t\tstr_replace('%section%', 'product', $navigation_page_index),\n\t\t\tstr_replace('%section%', 'product', $navigation_index_label),\n\t\t\tstr_replace('%section%', 'product', $navigation_nextprev_title),\n\t\t\tstr_replace('%section%', 'product', $footer_section_title),\n\t\t\tstr_replace('%section%', 'product', $footer_uncode_block),\n\t\t\tstr_replace('%section%', 'product', $footer_width),\n\t\t\tstr_replace('%section%', 'product', $custom_fields_section_title),\n\t\t\tstr_replace('%section%', 'product', $custom_fields_list),\n\t\t\t/////////////////////////\n\t\t\t// Products Index\t\t///\n\t\t\t/////////////////////////\n\t\t\tstr_replace('%section%', 'product_index', $menu_section_title),\n\t\t\tstr_replace('%section%', 'product_index', $menu),\n\t\t\tstr_replace('%section%', 'product_index', $menu_width),\n\t\t\tstr_replace('%section%', 'product_index', $menu_opaque),\n\t\t\tstr_replace('%section%', 'product_index', $header_section_title),\n\t\t\tstr_replace('%section%', 'product_index', run_array_to($header_type, 'std', 'header_basic')),\n\t\t\tstr_replace('%section%', 'product_index', $header_uncode_block),\n\t\t\tstr_replace('%section%', 'product_index', $header_revslider),\n\t\t\tstr_replace('%section%', 'product_index', $header_layerslider),\n\n\t\t\tstr_replace('%section%', 'product_index', $header_width),\n\t\t\tstr_replace('%section%', 'product_index', $header_height),\n\t\t\tstr_replace('%section%', 'product_index', $header_min_height),\n\t\t\tstr_replace('%section%', 'product_index', $header_title),\n\t\t\tstr_replace('%section%', 'product_index', $header_style),\n\t\t\tstr_replace('%section%', 'product_index', $header_content_width),\n\t\t\tstr_replace('%section%', 'product_index', $header_custom_width),\n\t\t\tstr_replace('%section%', 'product_index', $header_align),\n\t\t\tstr_replace('%section%', 'product_index', $header_position),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_font),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_size),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_height),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_spacing),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_weight),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_transform),\n\t\t\tstr_replace('%section%', 'product_index', $header_title_italic),\n\t\t\tstr_replace('%section%', 'product_index', $header_text_animation),\n\t\t\tstr_replace('%section%', 'product_index', $header_animation_speed),\n\t\t\tstr_replace('%section%', 'product_index', $header_animation_delay),\n\t\t\tstr_replace('%section%', 'product_index', $header_featured),\n\t\t\tstr_replace('%section%', 'product_index', $header_background),\n\t\t\tstr_replace('%section%', 'product_index', $header_parallax),\n\t\t\tstr_replace('%section%', 'product_index', $header_kburns),\n\t\t\tstr_replace('%section%', 'product_index', $header_overlay_color),\n\t\t\tstr_replace('%section%', 'product_index', $header_overlay_color_alpha),\n\t\t\tstr_replace('%section%', 'product_index', $header_scroll_opacity),\n\t\t\tstr_replace('%section%', 'product_index', $header_scrolldown),\n\t\t\tstr_replace('%section%', 'product_index', $menu_no_padding),\n\t\t\tstr_replace('%section%', 'product_index', $menu_no_padding_mobile),\n\t\t\tstr_replace('%section%', 'product_index', $title_archive_custom_activate),\n\t\t\tstr_replace('%section%', 'product_index', $title_archive_custom_text),\n\t\t\tstr_replace('%section%', 'product_index', $subtitle_archive_custom_text),\n\n\t\t\tstr_replace('%section%', 'product_index', $body_section_title),\n\t\t\tstr_replace('%section%', 'product_index', $show_breadcrumb),\n\t\t\tstr_replace('%section%', 'product_index', $breadcrumb_align),\n\t\t\tstr_replace('%section%', 'product_index', $body_uncode_block),\n\t\t\tstr_replace('%section%', 'product_index', $body_layout_width),\n\t\t\tstr_replace('%section%', 'product_index', $body_single_post_width),\n\t\t\tstr_replace('%section%', 'product_index', $show_title),\n\t\t\tstr_replace('%section%', 'product_index', $remove_pagination),\n\t\t\tstr_replace('%section%', 'product_index', $products_per_page),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_section_title),\n\t\t\tstr_replace('%section%', 'product_index', run_array_to($sidebar_activate, 'std', 'on')),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_widget),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_position),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_size),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_sticky),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_style),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_bgcolor),\n\t\t\tstr_replace('%section%', 'product_index', $sidebar_fill),\n\t\t\tstr_replace('%section%', 'product_index', $footer_section_title),\n\t\t\tstr_replace('%section%', 'product_index', $footer_uncode_block),\n\t\t\tstr_replace('%section%', 'product_index', $footer_width),\n\t\t);\n\n\t\t$custom_settings['sections'] = array_merge( $custom_settings['sections'], $woo_section );\n\t\t// array_push($custom_settings['settings'], $woocommerce_cart_icon);\n\t\t// array_push($custom_settings['settings'], $woocommerce_hooks);\n\t\t$custom_settings['settings'] = array_merge( $custom_settings['settings'], $woocommerce_post );\n\n\t}\n\n\t$custom_settings['settings'] = array_filter( $custom_settings['settings'], 'uncode_is_not_null' );\n\n\t/* allow settings to be filtered before saving */\n\t$custom_settings = apply_filters(ot_settings_id() . '_args', $custom_settings);\n\n\t/* settings are not the same update the DB */\n\tif ($saved_settings !== $custom_settings)\n\t{\n\t\tupdate_option(ot_settings_id() , $custom_settings);\n\t}\n\n\t/**\n\t * Filter on layout images.\n\t */\n\tfunction filter_layout_radio_images($array, $layout)\n\t{\n\n\t\t/* only run the filter where the field ID is my_radio_images */\n\t\tif ($layout == '_uncode_headers')\n\t\t{\n\t\t\t$array = array(\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-right',\n\t\t\t\t\t'label' => esc_html__('Right', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-right.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-justify',\n\t\t\t\t\t'label' => esc_html__('Justify', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-justify.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-left',\n\t\t\t\t\t'label' => esc_html__('Left', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-left.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-center',\n\t\t\t\t\t'label' => esc_html__('Center', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-center.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-center-split',\n\t\t\t\t\t'label' => esc_html__('Center Split', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-splitted.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'hmenu-center-double',\n\t\t\t\t\t'label' => esc_html__('Center Double', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/hmenu-center-double.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'vmenu',\n\t\t\t\t\t'label' => esc_html__('Lateral', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/vmenu.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'vmenu-offcanvas',\n\t\t\t\t\t'label' => esc_html__('Offcanvas', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/offcanvas.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'menu-overlay',\n\t\t\t\t\t'label' => esc_html__('Overlay', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/overlay.jpg'\n\t\t\t\t) ,\n\t\t\t\tarray(\n\t\t\t\t\t'value' => 'menu-overlay-center',\n\t\t\t\t\t'label' => esc_html__('Overlay Center', 'uncode') ,\n\t\t\t\t\t'src' => get_template_directory_uri() . '/core/assets/images/layout/overlay-center.jpg'\n\t\t\t\t) ,\n\t\t\t);\n\t\t}\n\t\treturn $array;\n\t}\n\tadd_filter('ot_radio_images', 'filter_layout_radio_images', 10, 2);\n}", "function theme_options_init(){\n\tregister_setting( 'sample_options', 'site_description', 'theme_options_validate' );\n\tregister_setting( 'ga_options', 'ga_account', 'ga_validate' );\n\tadd_filter('site_description', 'stripslashes');\n}", "function theme_options_init(){\n\tregister_setting( 'htmlks4wp_options', 'htmlks4wp_theme_options', 'theme_options_validate' );\n}", "function custom_theme_options() {\n\n \n\n /* OptionTree is not loaded yet */\n\n if ( ! function_exists( 'ot_settings_id' ) )\n\n return false;\n\n \n\n /**\n\n * Get a copy of the saved settings array. \n\n */\n\n $saved_settings = get_option( ot_settings_id(), array() );\n\n \n\n /**\n\n * Custom settings array that will eventually be \n\n * passes to the OptionTree Settings API Class.\n\n */\n\n $custom_settings = array( \n\n 'contextual_help' => array( \n\n 'sidebar' => ''\n\n ),\n\n 'sections' => array( \n\n array(\n\n 'id' => 'general',\n\n 'title' => __( 'General', 'theme-options.php' )\n\n ),\n\n\n array(\n\n 'id' => 'slider',\n\n 'title' => __( 'Slider', 'theme-options.php' )\n\n ),\n\n array(\n\n 'id' => 'footer',\n\n 'title' => __( 'Footer', 'theme-options.php' )\n\n ),\n\n array(\n\n 'id' => 'social_links',\n\n 'title' => __( 'Social Links', 'theme-options.php' )\n\n )\n\n ),\n\n 'settings' => array( \n\n array(\n\n 'id' => 'theme_logo',\n\n 'label' => __( 'Theme Logo', 'theme-options.php' ),\n\n 'desc' => __( 'Upload your Logo Image Here.Logo Dimension width:223px,Height:52px.', 'theme-options.php' ),\n\n 'std' => '',\n\n 'type' => 'upload',\n\n 'section' => 'general',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\n array(\n\n 'id' => 'alert',\n\n 'label' => __( 'Add or Change Alert Box Text from Home Page', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'general',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\n array(\n\n 'id' => 'column_one_direction',\n\n 'label' => __( 'Add Column One Hours & Direction ', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'textarea',\n\n 'section' => 'general',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\t array(\n\n 'id' => 'column_two_direction',\n\n 'label' => __( 'Add Column Two Hours & Direction With Button', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'textarea',\n\n 'section' => 'general',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\t\n\t array(\n\n 'id' => 'mail_chimp',\n\n 'label' => __( 'Add Mailchimp Form Image:Dimension: width:340px & Height:151px', 'theme-options.php' ),\n\n 'desc' => __( '.', 'theme-options.php' ),\n\n 'std' => '',\n\n 'type' => 'upload',\n\n 'section' => 'general',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n \n\n\t array(\n\n 'id' => 'slide',\n\n 'label' => __( 'Slide', 'theme-options.php' ),\n\n 'desc' => 'Click Add New Button to add the slider Images.Slider Image Dimention - Width:1400px Height:573px',\n\n 'std' => '',\n\n 'type' => 'slider',\n\n 'section' => 'slider',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n \n\n\t \n\n array(\n\n 'id' => 'copyright',\n\n 'label' => __( 'Add Your Footer Bottom Copyright Text', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'footer',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\t array(\n\n 'id' => 'address',\n\n 'label' => __( 'Add Your Footer Address Here', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'footer',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\t array(\n\n 'id' => 'phone',\n\n 'label' => __( 'Add Your Footer Phone Number Here', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'footer',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\n\n array(\n\n 'id' => 'soc_pintrest',\n\n 'label' => __( 'Add Your Pintrest Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\t array(\n\n 'id' => 'soc_instagram',\n\n 'label' => __( 'Add Your instagram Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\t array(\n\n 'id' => 'soc_google',\n\n 'label' => __( 'Add Your Google Plus Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n array(\n\n 'id' => 'soc_facebook',\n\n 'label' => __( 'Add Your Facebook Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n array(\n\n 'id' => 'soc_twitter',\n\n 'label' => __( 'Add Your Twitter Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n ),\n\n\n\n array(\n\n 'id' => 'soc_youtube',\n\n 'label' => __( 'Add Your YouTube Profile link', 'theme-options.php' ),\n\n 'desc' => '',\n\n 'std' => '',\n\n 'type' => 'text',\n\n 'section' => 'social_links',\n\n 'rows' => '',\n\n 'post_type' => '',\n\n 'taxonomy' => '',\n\n 'min_max_step'=> '',\n\n 'class' => '',\n\n 'condition' => '',\n\n 'operator' => 'and'\n\n )\n\n )\n\n );\n\n \n\n /* allow settings to be filtered before saving */\n\n $custom_settings = apply_filters( ot_settings_id() . '_args', $custom_settings );\n\n \n\n /* settings are not the same update the DB */\n\n if ( $saved_settings !== $custom_settings ) {\n\n update_option( ot_settings_id(), $custom_settings ); \n\n }\n\n \n\n /* Lets OptionTree know the UI Builder is being overridden */\n\n global $ot_has_custom_theme_options;\n\n $ot_has_custom_theme_options = true;\n\n \n\n}", "function options_sanitize($options){\r\n // do checks here \r\n //debugbreak(); \r\n if($options['reset'] == 'reset'){\r\n add_settings_error('reset_settings','reset_settings',__('Settings have been reset back to default values',$this->plugin_domain),'updated');\r\n return $this->get_options(true);\r\n }\r\n $options['clickable'] = $options['clickable'] == 'yes' ? 'yes' : 'no'; \r\n $options['dofollow'] = isset($options['dofollow']) ? 'on' : 'off'; \r\n $options['newwindow'] = isset($options['newwindow']) ? 'on' : 'off'; \r\n $options['del_options'] = isset($options['del_options']) ? 'on' : 'off';\r\n $options['del_table'] = isset($options['del_table']) ? 'on' : 'off';\r\n return $options;\r\n }", "function update_options() {\n\t\tif ( get_current_blog_id() !== $this->options_blog_id ) {\n\t\t\treturn;\n\t\t}\n\n\t\tupdate_option( $this->option_name, $this->options );\n\t}", "function custom_theme_options() {\n \n /* OptionTree is not loaded yet */\n if ( ! function_exists( 'ot_settings_id' ) )\n return false;\n \n /**\n * Get a copy of the saved settings array. \n */\n $saved_settings = get_option( ot_settings_id(), array() );\n \n /**\n * Custom settings array that will eventually be \n * passes to the OptionTree Settings API Class.\n */\n $custom_settings = array( \n 'contextual_help' => array( \n 'sidebar' => ''\n ),\n 'sections' => array( \n array(\n 'id' => 'general_default',\n 'title' => '基本设置'\n ),\n array(\n 'id' => 'advanced_settings',\n 'title' => '高级设置'\n ),\n array(\n 'id' => 'appearance',\n 'title' => '外观样式'\n ),\n array(\n 'id' => 'social_icons',\n 'title' => '社交网络'\n ),\n array(\n 'id' => 'analytics_seo',\n 'title' => '统计代码&amp;SEO'\n )\n ),\n 'settings' => array( \n array(\n 'id' => 'owner_photo',\n 'label' => '首页头像',\n 'desc' => '请填写图片网址或者上传图片,建议尺寸:100x100',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'owner_first_name',\n 'label' => '姓氏',\n 'desc' => '将显示在头像的左侧。建议1-4个字,或者留空',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'owner_last_name',\n 'label' => '名字',\n 'desc' => '将显示在头像的右侧。建议1-4个字,或者留空',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'contact_info',\n 'label' => '欢迎辞/网站公告',\n 'desc' => '填写后将出现在首页右上角、社交图标的上方',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general_default',\n 'rows' => '5',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'copyright_text',\n 'label' => '页脚文字',\n 'desc' => '显示于每个页面的最下方,可以是版权信息、站点地图链接等,支持HTML代码',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general_default',\n 'rows' => '5',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'profile_page',\n 'label' => '指定首页页面',\n 'desc' => '首页内容一般为简要的自我介绍。新建相应页面后,在这里选中,网站首页显示的即为该页面的内容',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'resume_page',\n 'label' => '指定简历页面',\n 'desc' => '新建相应页面后,在这里选中,“简历”显示的即为该页面的内容',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'portfolio_page',\n 'label' => '指定作品页面',\n 'desc' => '新建相应页面(页面的模板必须为“Portofolio 模版”)后,在这里选中,新建的“作品”将显示在该页面内',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'blog_page',\n 'label' => '指定博客页面',\n 'desc' => '新建相应页面(页面的模板必须为“Blog 模版”)后,在这里选中,新建的“文章”将显示在该页面内',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'contact_page',\n 'label' => '指定留言页面',\n 'desc' => '新建相应页面(页面的模板为“Contact 模版”)后,在这里选中,将其指定为“留言”页面',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'general_default',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'if_ajaxify',\n 'label' => '是否开启全站Ajax',\n 'desc' => '如果希望全站播放背景音乐,请务必开启此项',\n 'std' => '',\n 'type' => 'on-off',\n 'section' => 'advanced_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'custom_reloadjs',\n 'label' => '重载JS',\n 'desc' => '开启全站Ajax后可能导致某些document.ready触发的功能失效(比如百度推荐),请在此处粘贴相应JS代码',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'advanced_settings',\n 'rows' => '6',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'bgm',\n 'label' => '背景音乐列表',\n 'desc' => '请填写js列表网址或直接上传文件,此处留空则不播放背景音乐。js列表格式请参照“无需上传文件”文件夹中的 radio_content_example.js',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'advanced_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'work_items_link_status',\n 'label' => '作品链接至详情页面',\n 'desc' => '勾选后点击作品的名字可以进入该作品页面。适用于每个作品都有详细介绍的情况',\n 'std' => '',\n 'type' => 'on-off',\n 'section' => 'advanced_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'blog_sidebar',\n 'label' => '博客侧边栏小工具',\n 'desc' => '是否启用博客页面的侧边栏小工具',\n 'std' => '',\n 'type' => 'on-off',\n 'section' => 'advanced_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'duoshuo_domain',\n 'label' => '多说域名(×××.duoshuo.com)',\n 'desc' => '填写后多说“最近访客”小工具才能正常使用。已经注册过多说的用户直接填写×××处内容,未注册的请先到 <a href=\"http://duoshuo.com/create-site/\" title=\"创建多说站点\" target=\"_blank\">这里</a> 创建站点,然后填写',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'advanced_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'background_pattern',\n 'label' => '背景图片',\n 'desc' => '请填写图片网址或者上传图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'background_grid',\n 'label' => '背景网点',\n 'desc' => '背景图上是否加一层网点',\n 'std' => '',\n 'type' => 'radio',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and',\n 'choices' => array( \n array(\n 'value' => 'bright',\n 'label' => '灰色网点(偏亮)',\n 'src' => ''\n ),\n array(\n 'value' => 'dark',\n 'label' => '黑色网点(偏暗)',\n 'src' => ''\n ),\n array(\n 'value' => 'no',\n 'label' => '不使用',\n 'src' => ''\n )\n )\n ),\n array(\n 'id' => 'custom_css',\n 'label' => '自定义CSS',\n 'desc' => '请直接粘贴你的CSS源代码',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'appearance',\n 'rows' => '8',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'fav_icon',\n 'label' => 'Favicon图标',\n 'desc' => '请填写图标网址或者上传图标,建议尺寸:16x16',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'apple_touch_icon',\n 'label' => 'Favicon图标(57x57)',\n 'desc' => '请填写图标网址或者上传图标,建议尺寸:57x57',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'apple_touch_icon_72',\n 'label' => 'Favicon图标(72x72)',\n 'desc' => '请填写图标网址或者上传图标,建议尺寸:72x72',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'apple_touch_icon_114',\n 'label' => 'Favicon图标(114x114)',\n 'desc' => '请填写图标网址或者上传图标,建议尺寸:114x114',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'appearance',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'sina_id',\n 'label' => '新浪微博(http://weibo.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'tencent_id',\n 'label' => '腾讯微博(http://t.qq.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'baidu_id',\n 'label' => '百度贴吧(http://www.baidu.com/p/×××?from=tieba 或者 http://tieba.baidu.com/home/main?id=×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'renren_id',\n 'label' => '人人(http://www.renren.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'kaixin_id',\n 'label' => '开心网(http://www.kaixin001.com/home/?uid=×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'qq_id',\n 'label' => 'QQ',\n 'desc' => '请填写数字QQ号。如果不想在网址中暴露QQ号,请到 <a href=\"http://shang.qq.com/v3/widget.html\" target=\"_blank\">这里</a> ——设置——安全级别设置,选择“安全加密”,保存后刷新网页,到“QQ通讯组件”获取代码,并在此处填入您的IDKEY(代码中IDKEY=后面的48位字符串)',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'qq_qr',\n 'label' => '手机QQ二维码',\n 'desc' => '请填写您的QQ二维码网址,在此处上传,或者直接使用媒体库中的图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'twitter_id',\n 'label' => 'Twitter(https://twitter.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'facebook_id',\n 'label' => 'Facebook(https://www.facebook.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'gplus_id',\n 'label' => 'Google Plus(https://plus.google.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'skype_id',\n 'label' => 'Skype',\n 'desc' => '请填写您的Skype帐号。访客点击后默认会启动Skype打开和您的文字聊天窗口。',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'youku_id',\n 'label' => '优酷(http://i.youku.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'tudou_id',\n 'label' => '土豆(http://www.tudou.com/home/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'bilibili_id',\n 'label' => '哔哩哔哩(http://space.bilibili.tv/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'xiami_id',\n 'label' => '虾米(http://www.xiami.com/u/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'songtaste_id',\n 'label' => 'SongTaste(http://www.songtaste.com/user/×××/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'huaban_id',\n 'label' => '花瓣(http://huaban.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'youtube_id',\n 'label' => 'Youtube(https://www.youtube.com/user/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'vimeo_id',\n 'label' => 'Vimeo(http://vimeo.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'soundcloud_id',\n 'label' => 'SoundCloud(https://soundcloud.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'flickr_id',\n 'label' => 'Flickr(https://www.flickr.com/photos/×××/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'instagram_id',\n 'label' => 'Instagram(http://instagram.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'f500px_id',\n 'label' => '500px(http://500px.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'pinterest_id',\n 'label' => 'Pinterest(http://www.pinterest.com/×××/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'zhihu_id',\n 'label' => '知乎(http://www.zhihu.com/people/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'guokr_id',\n 'label' => '果壳(http://www.guokr.com/i/×××/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'douban_id',\n 'label' => '豆瓣(http://www.douban.com/people/×××/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'zcool_id',\n 'label' => '站酷(http://www.zcool.com.cn/u/××× 或 http://×××.zcool.com.cn/)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'yiyan_id',\n 'label' => '译言(http://user.yeeyan.org/u/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'segmentfault_id',\n 'label' => 'SegmentFault(http://segmentfault.com/u/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'quora_id',\n 'label' => 'Quora(https://www.quora.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'dropbox_id',\n 'label' => 'Dropbox 邀请链接(https://db.tt/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'linkedin_id',\n 'label' => 'Linkedin(http://www.linkedin.com/pub/×××/×××/×××/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'dribbble_id',\n 'label' => 'Dribbble(http://dribbble.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'github_id',\n 'label' => 'Github(https://github.com/×××)',\n 'desc' => '请填写完整URL,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'stackexchange_id',\n 'label' => 'StackExchange(http://stackexchange.com/users/×××)',\n 'desc' => '请填写完整URL,包含http(s)://。注意这里是总站StackExchange的,不要填成了StackOverflow的',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'wechat_qr',\n 'label' => '微信',\n 'desc' => '请填写您的微信二维码网址,在此处上传,或者直接使用媒体库中的图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'yixin_qr',\n 'label' => '易信',\n 'desc' => '请填写您的易信二维码网址,在此处上传,或者直接使用媒体库中的图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'line_qr',\n 'label' => 'Line',\n 'desc' => '请填写您的Line二维码网址,在此处上传,或者直接使用媒体库中的图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'whatsapp_qr',\n 'label' => 'Whatsapp',\n 'desc' => '请填写您的Whatsapp二维码网址,在此处上传,或者直接使用媒体库中的图片',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'mail_address',\n 'label' => 'E-mail',\n 'desc' => '请填写邮箱地址(如[email protected])或者在线写信类网址(如QQ邮箱“邮我”,在设置——账户的最下方开启该功能并获取代码后,在此处填入href=之后,双引号之间的那个网址)',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'rss_feed',\n 'label' => 'RSS Feed',\n 'desc' => '请填写完整网址,包含http(s)://。一般为“您的博客网址/feed/”',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'any_url',\n 'label' => '自定义链接',\n 'desc' => '请填写完整网址,包含http(s)://',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'social_icons',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'header_analytics_code',\n 'label' => '页头统计代码',\n 'desc' => '适用于任何要求在页头(head)部分加载的统计代码,如谷歌统计,百度统计异步代码。请直接粘贴您的代码(包含script标签),支持多个统计代码,但建议只用一个',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'analytics_seo',\n 'rows' => '4',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'footer_analytics',\n 'label' => '页尾统计代码',\n 'desc' => '适用于任何要求在页尾(footer)部分加载的统计代码,如腾讯统计,百度统计普通代码。请直接粘贴您的代码(包含script标签),支持多个统计代码,但建议只用一个',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'analytics_seo',\n 'rows' => '4',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'baidu_tuijian',\n 'label' => '百度推荐',\n 'desc' => '在<a href=\"http://tuijian.baidu.com\" target=\"_blank\">百度推荐</a>获取异步代码后,填写id=\"hm_t_×××\"引号中的内容',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'analytics_seo',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'site_description',\n 'label' => '站点描述',\n 'desc' => '适当、准确地描述你的网站。如果不想出现 Description 标签用于SEO,此处请留空',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'analytics_seo',\n 'rows' => '4',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'site_keywords',\n 'label' => '关键词',\n 'desc' => '网站关键词,关键词之间用半角英文逗号隔开。如果不想出现 Keywords 标签用于SEO,此处请留空',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'analytics_seo',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n array(\n 'id' => 'site_author',\n 'label' => '作者',\n 'desc' => '网站作者或者所有者的名字。如果不想出现 Author 标签用于SEO,此处请留空',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'analytics_seo',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n )\n )\n );\n \n /* allow settings to be filtered before saving */\n $custom_settings = apply_filters( ot_settings_id() . '_args', $custom_settings );\n \n /* settings are not the same update the DB */\n if ( $saved_settings !== $custom_settings ) {\n update_option( ot_settings_id(), $custom_settings ); \n }\n \n /* Lets OptionTree know the UI Builder is being overridden */\n global $ot_has_custom_theme_options;\n $ot_has_custom_theme_options = true;\n \n}", "function PricerrTheme_general_options()\n{\n $id_icon = 'icon-options-general2';\n $ttl_of_stuff = 'PricerrTheme - ' . __('General Settings', 'PricerrTheme');\n global $menu_admin_PricerrTheme_theme_bull;\n $arr = array(\"yes\" => __(\"Yes\", 'PricerrTheme'), \"no\" => __(\"No\", 'PricerrTheme'));\n\n //------------------------------------------------------\n\n echo '<div class=\"wrap\">';\n echo '<div class=\"icon32\" id=\"' . $id_icon . '\"><br/></div>';\n echo '<h2 class=\"my_title_class_sitemile\">' . $ttl_of_stuff . '</h2>';\n\n if (isset($_POST['PricerrTheme_save1'])) {\n update_option('PricerrTheme_show_views', trim($_POST['PricerrTheme_show_views']));\n update_option('PricerrTheme_admin_approve_job', trim($_POST['PricerrTheme_admin_approve_job']));\n update_option('PricerrTheme_admin_approve_request', trim($_POST['PricerrTheme_admin_approve_request']));\n update_option('PricerrTheme_enable_blog', trim($_POST['PricerrTheme_enable_blog']));\n\n update_option('PricerrTheme_enable_extra', trim($_POST['PricerrTheme_enable_extra']));\n update_option('PricerrTheme_max_time_to_wait', trim($_POST['PricerrTheme_max_time_to_wait']));\n update_option('PricerrTheme_job_listing', trim($_POST['PricerrTheme_job_listing']));\n update_option('PricerrTheme_featured_job_listing', trim($_POST['PricerrTheme_featured_job_listing']));\n update_option('PricerrTheme_for_strg', trim($_POST['PricerrTheme_for_strg']));\n update_option('PricerrTheme_i_will_strg', trim($_POST['PricerrTheme_i_will_strg']));\n update_option('PricerrTheme_show_limit_job_cnt', trim($_POST['PricerrTheme_show_limit_job_cnt']));\n update_option('PricerrTheme_en_country_flags', trim($_POST['PricerrTheme_en_country_flags']));\n update_option('PricerrTheme_ip_key_db', trim($_POST['PricerrTheme_ip_key_db']));\n update_option('PricerrTheme_default_nr_of_pics', trim($_POST['PricerrTheme_default_nr_of_pics']));\n update_option('PricerrTheme_mandatory_pics_for_jbs', trim($_POST['PricerrTheme_mandatory_pics_for_jbs']));\n update_option('PricerrTheme_taxonomy_page_with_sdbr', trim($_POST['PricerrTheme_taxonomy_page_with_sdbr']));\n update_option('PricerrTheme_enable_second_footer', trim($_POST['PricerrTheme_enable_second_footer']));\n update_option('PricerrTheme_enable_instant_deli', trim($_POST['PricerrTheme_enable_instant_deli']));\n update_option('PricerrTheme_show_pagination_homepage', trim($_POST['PricerrTheme_show_pagination_homepage']));\n\n update_option('PricerrTheme_jobs_permalink', trim($_POST['PricerrTheme_jobs_permalink']));\n update_option('PricerrTheme_location_permalink', trim($_POST['PricerrTheme_location_permalink']));\n update_option('PricerrTheme_category_permalink', trim($_POST['PricerrTheme_category_permalink']));\n\n update_option('PricerrTheme_nrpostsPage_home_page', trim($_POST['PricerrTheme_nrpostsPage_home_page']));\n\n\n $PricerrTheme_get_total_extras = $_POST['PricerrTheme_get_total_extras'];\n if ($PricerrTheme_get_total_extras > 10 or !is_numeric($PricerrTheme_get_total_extras)) $PricerrTheme_get_total_extras = 10;\n\n update_option('PricerrTheme_get_total_extras', trim($PricerrTheme_get_total_extras));\n\n do_action('PricerrTheme_general_settings_main_details_options_save');\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n if (isset($_POST['PricerrTheme_save2'])) {\n update_option('PricerrTheme_filter_emails_private_messages', trim($_POST['PricerrTheme_filter_emails_private_messages']));\n update_option('PricerrTheme_filter_urls_private_messages', trim($_POST['PricerrTheme_filter_urls_private_messages']));\n update_option('PricerrTheme_filter_emails_chat_box', trim($_POST['PricerrTheme_filter_emails_chat_box']));\n update_option('PricerrTheme_filter_urls_chat_box', trim($_POST['PricerrTheme_filter_urls_chat_box']));\n\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n if (isset($_POST['PricerrTheme_save3'])) {\n update_option('PricerrTheme_enable_shipping', trim($_POST['PricerrTheme_enable_shipping']));\n update_option('PricerrTheme_enable_flat_shipping', trim($_POST['PricerrTheme_enable_flat_shipping']));\n update_option('PricerrTheme_enable_location_based_shipping', trim($_POST['PricerrTheme_enable_location_based_shipping']));\n\n\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n\n if (isset($_POST['PricerrTheme_save4'])) {\n update_option('PricerrTheme_enable_facebook_login', trim($_POST['PricerrTheme_enable_facebook_login']));\n update_option('PricerrTheme_facebook_app_id', trim($_POST['PricerrTheme_facebook_app_id']));\n update_option('PricerrTheme_facebook_app_secret', trim($_POST['PricerrTheme_facebook_app_secret']));\n\n\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n\n if (isset($_POST['PricerrTheme_save5'])) {\n update_option('PricerrTheme_enable_twitter_login', trim($_POST['PricerrTheme_enable_twitter_login']));\n update_option('PricerrTheme_twitter_consumer_key', trim($_POST['PricerrTheme_twitter_consumer_key']));\n update_option('PricerrTheme_twitter_consumer_secret', trim($_POST['PricerrTheme_twitter_consumer_secret']));\n\n\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n if (isset($_POST['PricerrTheme_save_n'])) {\n update_option('PricerrTheme_level1_extras', trim($_POST['PricerrTheme_level1_extras']));\n update_option('PricerrTheme_level2_extras', trim($_POST['PricerrTheme_level2_extras']));\n update_option('PricerrTheme_level3_extras', trim($_POST['PricerrTheme_level3_extras']));\n update_option('PricerrTheme_default_level_nr', trim($_POST['PricerrTheme_default_level_nr']));\n\n update_option('PricerrTheme_level1_vds', trim($_POST['PricerrTheme_level1_vds']));\n update_option('PricerrTheme_level2_vds', trim($_POST['PricerrTheme_level2_vds']));\n update_option('PricerrTheme_level3_vds', trim($_POST['PricerrTheme_level3_vds']));\n\n\n echo '<div class=\"saved_thing\">' . __('Settings saved!', 'PricerrTheme') . '</div>';\n }\n\n do_action('PricerrTheme_general_options_actions');\n\n ?>\n\n<div id=\"usual2\" class=\"usual\">\n <ul>\n <li><a href=\"#tabs1\"><?php _e('Main Settings', 'PricerrTheme'); ?></a></li>\n <li><a href=\"#tabs_new\"><?php _e('Level Settings', 'PricerrTheme'); ?></a></li>\n <li><a href=\"#tabs2\"><?php _e('Filters', 'PricerrTheme'); ?></a></li>\n <li><a href=\"#tabs3\"><?php _e('Shipping', 'PricerrTheme'); ?></a></li>\n <li><a href=\"#tabs4\"><?php _e('Facebook Connect', 'PricerrTheme'); ?></a></li>\n <li><a href=\"#tabs5\"><?php _e('Twitter Connect', 'PricerrTheme'); ?></a></li>\n <?php do_action('PricerrTheme_general_options_tabs'); ?>\n </ul>\n\n <div id=\"tabs_new\">\n <form method=\"post\" action=\"<?php bloginfo('siteurl'); ?>/wp-admin/admin.php?page=general-options&active_tab=tabs_new\">\n <table width=\"100%\" class=\"sitemile-table\">\n\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 10 max.'); ?></td>\n <td width=\"200\"><?php _e('Default User Level:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"3\" name=\"PricerrTheme_default_level_nr\" value=\"<?php echo get_option('PricerrTheme_default_level_nr'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 10 max.'); ?></td>\n <td width=\"200\"><?php _e('Level 1 Allowed Extras:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_level1_extras\" value=\"<?php echo get_option('PricerrTheme_level1_extras'); ?>\"/>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 10 max.'); ?></td>\n <td><?php _e('Level 2 Allowed Extras:', 'PricerrTheme'); ?></td>\n <td><input type=\"text\" size=\"5\" name=\"PricerrTheme_level2_extras\"\n value=\"<?php echo get_option('PricerrTheme_level2_extras'); ?>\"/></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 10 max.'); ?></td>\n <td><?php _e('Level 3 Allowed Extras:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_level3_extras\" value=\"<?php echo get_option('PricerrTheme_level3_extras'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td colspan=\"3\"></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 3 max.'); ?></td>\n <td width=\"200\"><?php _e('Level 1 Allowed Videos:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_level1_vds\" value=\"<?php echo get_option('PricerrTheme_level1_vds'); ?>\"/>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 3 max.'); ?></td>\n <td width=\"200\"><?php _e('Level 2 Allowed Videos:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_level2_vds\" value=\"<?php echo get_option('PricerrTheme_level2_vds'); ?>\"/>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Set a value up to 3 max.'); ?></td>\n <td width=\"200\"><?php _e('Level 3 Allowed Videos:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_level3_vds\" value=\"<?php echo get_option('PricerrTheme_level3_vds'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td></td>\n <td></td>\n <td>\n <input type=\"submit\" name=\"PricerrTheme_save_n\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/>\n </td>\n </tr>\n\n </table>\n </form>\n\n </div>\n\n <div id=\"tabs1\">\n\n\n <form method=\"post\" action=\"\">\n <table width=\"100%\" class=\"sitemile-table\">\n\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet('Show homepage pagination.'); ?></td>\n <td width=\"240\"><?php _e('Homepage Pagination:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_show_pagination_homepage'); ?></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td><?php _e('Number of Homepage Lessons:', 'PricerrTheme'); ?></td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_nrpostsPage_home_page\" value=\"<?php echo get_option('PricerrTheme_nrpostsPage_home_page'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet('This enables or disables the sidebar in the category and archive pages.'); ?>\n </td>\n <td width=\"240\">\n <?php _e('Enable instant delivery file:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_instant_deli'); ?>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Number of Extras:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_get_total_extras\" value=\"<?php echo get_option('PricerrTheme_get_total_extras'); ?>\"/>\n ( max number is 10 )\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet('This enables or disables the sidebar in the category and archive pages.'); ?>\n </td>\n <td width=\"240\">\n <?php _e('Category Pages have sidebars?:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_taxonomy_page_with_sdbr'); ?>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet('This enables or disables the sidebar in the category and archive pages.'); ?>\n </td>\n <td width=\"240\">\n <?php _e('Enable second footer area?:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_second_footer'); ?>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Mandatory to upload pictures for jobs:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_mandatory_pics_for_jbs'); ?>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Enable country flags:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_en_country_flags'); ?>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('IPI Info DB Key:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"22\" name=\"PricerrTheme_ip_key_db\" value=\"<?php echo get_option('PricerrTheme_ip_key_db'); ?>\"/>\n ( register a key: http://www.ipinfodb.com/register.php )\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Max Amount of Pictures:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"5\" name=\"PricerrTheme_default_nr_of_pics\" value=\"<?php echo get_option('PricerrTheme_default_nr_of_pics'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Show views in each job page:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_show_views'); ?>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Admin approves each job:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_admin_approve_job'); ?>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Admin approves each request:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_admin_approve_request'); ?>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Enable Blog:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_blog'); ?>\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Enable Extra Services:', 'PricerrTheme'); ?>\n </td>\n <td>\n <?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_extra'); ?>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Auto-mark job as completed after:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"6\" name=\"PricerrTheme_max_time_to_wait\" value=\"<?php echo get_option('PricerrTheme_max_time_to_wait'); ?>\"/>\n hours\n </td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(__('After the time expires the job will be closed and your users can repost it. Leave 0 for never-expire jobs.', 'PricerrTheme')); ?>\n </td>\n <td><?php _e('Lesson listing period:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"6\" name=\"PricerrTheme_job_listing\" value=\"<?php echo get_option('PricerrTheme_job_listing'); ?>\"/>\n days\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Featured job listing period:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"6\" name=\"PricerrTheme_featured_job_listing\" value=\"<?php echo get_option('PricerrTheme_featured_job_listing'); ?>\"/>\n days\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Number of jobs show on homepage:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" name=\"PricerrTheme_show_limit_job_cnt\" size=\"10\" value=\"<?php echo get_option('PricerrTheme_show_limit_job_cnt'); ?>\"/>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Translation for \"I will provide\":', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" name=\"PricerrTheme_i_will_strg\" size=\"40\" value=\"<?php echo get_option('PricerrTheme_i_will_strg'); ?>\"/>\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td width=\"240\">\n <?php _e('Translation for \"for\":', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" name=\"PricerrTheme_for_strg\" size=\"40\" value=\"<?php echo get_option('PricerrTheme_for_strg'); ?>\"/>\n </td>\n </tr>\n\n\n <tr>\n <td colspan=\"3\"></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Slug for Lessons Permalink:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"30\" name=\"PricerrTheme_jobs_permalink\" value=\"<?php echo get_option('PricerrTheme_jobs_permalink'); ?>\"/>\n *if left empty will show 'jobs'\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Slug for Location Permalink:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"30\" name=\"PricerrTheme_location_permalink\" value=\"<?php echo get_option('PricerrTheme_location_permalink'); ?>\"/>\n *if left empty will show 'location'\n </td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\">\n <?php PricerrTheme_theme_bullet(); ?>\n </td>\n <td>\n <?php _e('Slug for Category Permalink:', 'PricerrTheme'); ?>\n </td>\n <td>\n <input type=\"text\" size=\"30\" name=\"PricerrTheme_category_permalink\" value=\"<?php echo get_option('PricerrTheme_category_permalink'); ?>\"/>\n *if left empty will show 'section'\n </td>\n </tr>\n\n\n <?php do_action('PricerrTheme_general_settings_main_details_options'); ?>\n\n <tr>\n <td></td>\n <td></td>\n <td>\n <input type=\"submit\" name=\"PricerrTheme_save1\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/>\n </td>\n </tr>\n\n </table>\n </form>\n\n\n </div>\n\n <div id=\"tabs2\">\n\n <form method=\"post\" action=\"<?php bloginfo('siteurl'); ?>/wp-admin/admin.php?page=general-options&active_tab=tabs2\">\n <table width=\"100%\" class=\"sitemile-table\">\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Filter Email Addresses (private messages):', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_filter_emails_private_messages'); ?></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Filter URLs (private messages):', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_filter_urls_private_messages'); ?></td>\n </tr>\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Filter Email Addresses (chat box):', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_filter_emails_chat_box'); ?></td>\n </tr>\n\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Filter URLs (chat box):', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_filter_urls_chat_box'); ?></td>\n </tr>\n\n\n <tr>\n <td></td>\n <td></td>\n <td>\n <input type=\"submit\" name=\"PricerrTheme_save2\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/>\n </td>\n </tr>\n\n </table>\n </form>\n\n </div>\n\n <div id=\"tabs3\">\n\n <form method=\"post\" action=\"<?php bloginfo('siteurl'); ?>/wp-admin/admin.php?page=general-options&active_tab=tabs3\">\n <table width=\"100%\" class=\"sitemile-table\">\n\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"200\"><?php _e('Enable Shipping:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_shipping'); ?></td>\n </tr>\n <!-- \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Enable only a flat fee:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_flat_shipping'); ?></td>\n </tr>\n \n <tr>\n <td colspan=\"3\"><?php _e('OR', 'PricerrTheme'); ?></td>\n </tr>\n \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Location based:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_location_based_shipping'); ?></td>\n </tr>\n -->\n\n <tr>\n <td></td>\n <td></td>\n <td>\n <input type=\"submit\" name=\"PricerrTheme_save3\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/>\n </td>\n </tr>\n\n </table>\n </form>\n\n </div>\n\n <div id=\"tabs4\">\n For facebook connect, install this plugin: <a\n href=\"http://wordpress.org/extend/plugins/wordpress-social-login/\">WordPress Social Login</a>\n <!-- \n \t<form method=\"post\" action=\"<?php bloginfo('siteurl'); ?>/wp-admin/admin.php?page=general-options&active_tab=tabs4\">\n <table width=\"100%\" class=\"sitemile-table\">\n \t\t\t\t\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"200\"><?php _e('Enable Facebook Login:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_facebook_login'); ?></td>\n </tr>\n \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Facebook App ID:', 'PricerrTheme'); ?></td>\n <td><input type=\"text\" size=\"35\" name=\"PricerrTheme_facebook_app_id\" value=\"<?php echo get_option('PricerrTheme_facebook_app_id'); ?>\"/></td>\n </tr>\n \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Facebook Secret Key:', 'PricerrTheme'); ?></td>\n <td><input type=\"text\" size=\"35\" name=\"PricerrTheme_facebook_app_secret\" value=\"<?php echo get_option('PricerrTheme_facebook_app_secret'); ?>\"/></td>\n </tr>\n \n <tr>\n <td ></td>\n <td ></td>\n <td><input type=\"submit\" name=\"PricerrTheme_save4\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/></td>\n </tr>\n \n </table> \n \t</form>\n -->\n </div>\n\n <div id=\"tabs5\">\n For twitter connect, install this plugin: <a href=\"http://wordpress.org/extend/plugins/wordpress-social-login/\">WordPress\n Social Login</a> <!--\n <form method=\"post\" action=\"<?php bloginfo('siteurl'); ?>/wp-admin/admin.php?page=general-options&active_tab=tabs5\">\n <table width=\"100%\" class=\"sitemile-table\">\n \t\t\t\t\n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"200\"><?php _e('Enable Twitter Login:', 'PricerrTheme'); ?></td>\n <td><?php echo PricerrTheme_get_option_drop_down($arr, 'PricerrTheme_enable_twitter_login'); ?></td>\n </tr>\n \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Twitter Consumer Key:', 'PricerrTheme'); ?></td>\n <td><input type=\"text\" size=\"35\" name=\"PricerrTheme_twitter_consumer_key\" value=\"<?php echo get_option('PricerrTheme_twitter_consumer_key'); ?>\"/></td>\n </tr>\n \n <tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Twitter Consumer Secret:', 'PricerrTheme'); ?></td>\n <td><input type=\"text\" size=\"35\" name=\"PricerrTheme_twitter_consumer_secret\" value=\"<?php echo get_option('PricerrTheme_twitter_consumer_secret'); ?>\"/></td>\n </tr>\n \n \n \t\t\t\t\t\t<tr>\n <td valign=top width=\"22\"><?php PricerrTheme_theme_bullet(); ?></td>\n <td width=\"250\"><?php _e('Callback URL:', 'PricerrTheme'); ?></td>\n <td><?php echo get_bloginfo('template_url'); ?>/lib/social/twitter/callback.php</td>\n </tr>\n \n \t\t\t\t\n <tr>\n <td ></td>\n <td ></td>\n <td><input type=\"submit\" name=\"PricerrTheme_save5\" value=\"<?php _e('Save Options', 'PricerrTheme'); ?>\"/></td>\n </tr>\n \n </table> \n \t</form> -->\n </div>\n\n<?php do_action('PricerrTheme_general_options_div_content'); ?>\n\n <?php\n echo '</div>';\n\n}", "public static function getOldVersionOptions(){\n\n\t\t$options = WordpressConnect::getDefaultOptions();\n\n\t\t// general options\n\t\t$language = get_option( WPC_OPTIONS_LANGUAGE );\n\t\tif ( $language !== FALSE ){\n\t\t\t$options[ WPC_OPTIONS ][ WPC_OPTIONS_LANGUAGE ] = $language; \n\t\t\tdelete_option( WPC_OPTIONS_LANGUAGE ); \n\t\t}\n\n\t\t$app_id = get_option( WPC_OPTIONS_APP_ID );\n\t\tif ( $app_id !== FALSE ){ \n\t\t\t$options[ WPC_OPTIONS ][ WPC_OPTIONS_APP_ID ] = $app_id;\n\t\t\tdelete_option( WPC_OPTIONS_APP_ID ); \n\t\t}\n\n\t\t$app_admins = get_option( WPC_OPTIONS_APP_ADMINS );\n\t\tif ( $app_admins !== FALSE ){ \n\t\t\t$options[ WPC_OPTIONS ][ WPC_OPTIONS_APP_ADMINS ] = $app_admins;\n\t\t\tdelete_option( WPC_OPTIONS_APP_ADMINS ); \n\t\t}\n\n\t\t$image = get_option( WPC_OPTIONS_IMAGE_URL );\n\t\tif ( $image !== FALSE ){ \n\t\t\t$options[ WPC_OPTIONS ][ WPC_OPTIONS_IMAGE_URL ] = $image;\n\t\t\tdelete_option( WPC_OPTIONS_IMAGE_URL ); \n\t\t}\n\n\t\t$description = get_option( WPC_OPTIONS_DESCRIPTION );\n\t\tif ( $description !== FALSE ){\n\t\t\t$options[ WPC_OPTIONS ][ WPC_OPTIONS_DESCRIPTION ] = $description;\n\t\t\tdelete_option( WPC_OPTIONS_DESCRIPTION ); \n\t\t}\n\n\t\t// comments\n\n\t\t$comments_number = get_option( WPC_OPTIONS_COMMENTS_NUMBER );\n\t\tif ( $comments_number !== FALSE && is_int( $comments_number ) ){\n\t\t\t$options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_COMMENTS_NUMBER ] = $comments_number;\n\t\t\tdelete_option( WPC_OPTIONS_COMMENTS_NUMBER );\n\t\t}\n\n\t\t$comments_width = get_option( WPC_OPTIONS_COMMENTS_WIDTH );\n\t\tif ( $comments_width !== FALSE && is_int( $comments_width ) ){\n\t\t\t$options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_COMMENTS_WIDTH ] = $comments_width;\n\t\t\tdelete_option( WPC_OPTIONS_COMMENTS_WIDTH );\n\t\t}\n\n\t\t$comments_display_homepage = get_option( WPC_OPTIONS_COMMENTS_SHOW_ON_HOMEPAGE );\n\t\tif ( $comments_display_homepage !== FALSE && !empty( $comments_display_homepage ) ){\n\t\t\t$options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_DISPLAY_HOMEPAGE ] = 'on';\n\t\t}\n\t\telse { $options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_DISPLAY_HOMEPAGE ] = ''; }\n\t\tdelete_option( WPC_OPTIONS_COMMENTS_SHOW_ON_HOMEPAGE );\n\n\t\t$comments_display_categories = get_option( WPC_OPTIONS_COMMENTS_SHOW_ON_CATEGORIES );\n\t\tif ( $comments_display_homepage !== FALSE && !empty( $comments_display_homepage ) ){\n\t\t\t$options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_DISPLAY_CATEGORIES ] = 'on';\n\t\t}\n\t\telse { $options[ WPC_OPTIONS_COMMENTS ][ WPC_OPTIONS_DISPLAY_CATEGORIES ] = ''; }\n\t\tdelete_option( WPC_OPTIONS_COMMENTS_SHOW_ON_CATEGORIES );\n\t\t\n\t\t// like button\n\n\t\t$like_layout = get_option( WPC_OPTIONS_LIKE_BUTTON_LAYOUT );\n\t\tif ( $like_layout !== FALSE ){ \n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_LIKE_BUTTON_LAYOUT ] = $like_layout; \n\t\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_LAYOUT );\n\t\t}\n\n\t\t$like_width = get_option( WPC_OPTIONS_LIKE_BUTTON_WIDTH );\n\t\tif ( $like_width !== FALSE && is_int( $like_width ) ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_COMMENTS_WIDTH ] = $like_width;\n\t\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_WIDTH );\n\t\t}\n\n\t\t$like_show_faces = get_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_FACES );\n\t\tif ( $like_show_faces !== FALSE && !empty( $like_show_faces ) ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_LIKE_BUTTON_FACES ] = WPC_OPTION_ENABLED;\n\t\t}\n\t\telse { $options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_LIKE_BUTTON_FACES ] = WPC_OPTION_DISABLED; }\n\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_FACES );\n\t\t\n\t\t$like_verb = get_option( WPC_OPTIONS_LIKE_BUTTON_VERB );\n\t\tif ( $like_verb !== FALSE ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_LIKE_BUTTON_VERB ] = $like_verb;\n\t\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_VERB );\n\t\t}\n\n\t\t$like_font = get_option( WPC_OPTIONS_LIKE_BUTTON_FONT );\n\t\tif ( $like_font !== FALSE ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_LIKE_BUTTON_FONT ] = $like_font;\n\t\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_FONT );\n\t\t}\n\n\t\t$like_display_homepage = get_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_ON_HOMEPAGE );\n\t\tif ( $like_display_homepage !== FALSE && !empty( $like_display_homepage ) ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_DISPLAY_HOMEPAGE ] = 'on';\n\t\t}\n\t\telse { $options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_DISPLAY_HOMEPAGE ] = ''; }\n\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_ON_HOMEPAGE );\n\n\n\t\t$like_display_categories = get_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_ON_CATEGORIES );\n\t\tif ( $like_display_categories !== FALSE && !empty( $like_display_categories ) ){\n\t\t\t$options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_DISPLAY_CATEGORIES ] = 'on';\n\t\t}\n\t\telse { $options[ WPC_OPTIONS_LIKE_BUTTON ][ WPC_OPTIONS_DISPLAY_CATEGORIES ] = ''; }\n\t\tdelete_option( WPC_OPTIONS_LIKE_BUTTON_SHOW_ON_CATEGORIES );\n\t\t\n\t\treturn $options;\n\n\t}", "function get_common_theme_options() {\r\n\r\n\t?>\r\n <style>\r\n .form-table th {\r\n display: none !important;\r\n }\r\n .table-no-border tr td {\r\n border: none !important;\r\n }\r\n </style>\r\n <nav class=\"nav-tab-wrapper wp-clearfix\" aria-label=\"Secondary menu\">\r\n <a style=\"background: #ffffff; border-bottom-color: transparent\"\r\n href=\"<?php echo admin_url( 'admin.php?page=theme-options-common' ); ?>\" class=\"nav-tab nav-tab-active\"\r\n aria-current=\"page\">Common Options\r\n </a>\r\n </nav>\r\n <div class=\"col-md-10 mx-auto\">\r\n <span> <?php settings_errors(); ?></span>\r\n <form action=\"<?php echo admin_url( 'options.php' ); ?>\" method=\"POST\" enctype=\"multipart/form-data\">\r\n\t\t\t<?php\r\n\t\t\tsettings_fields( \"common_settings_section\" );\r\n\t\t\tdo_settings_sections( \"common-theme-options\" );\r\n\t\t\t?>\r\n <div class=\"text-left\">\r\n <button type=\"submit\" class=\"btn btn-success\"> Update Theme Options</button>\r\n </div>\r\n </form>\r\n </div>\r\n\t<?php\r\n}", "function appthemes_admin_options() {\r\n\tglobal $wpdb, $app_abbr, $app_theme;\r\n\r\n\tif ( !current_user_can('manage_options') ) return;\r\n\r\n\tadd_menu_page($app_theme, $app_theme, 'manage_options', basename(__FILE__), 'cp_dashboard', FAVICON, THE_POSITION );\r\n\tadd_submenu_page( basename(__FILE__), __('Dashboard','appthemes'), __('Dashboard','appthemes'), 'manage_options', basename(__FILE__), 'cp_dashboard' );\r\n\tadd_submenu_page( basename(__FILE__), __('General Settings','appthemes'), __('Settings','appthemes'), 'manage_options', 'settings', 'cp_settings' );\r\n\tadd_submenu_page( basename(__FILE__), __('Emails','appthemes'), __('Emails','appthemes'), 'manage_options', 'emails', 'cp_emails' );\r\n\tadd_submenu_page( basename(__FILE__), __('Pricing Settings','appthemes'), __('Pricing','appthemes'), 'manage_options', 'pricing', 'cp_pricing' );\r\n\tadd_submenu_page( basename(__FILE__), __('Packages','appthemes'), __('Packages','appthemes'), 'manage_options', 'packages', 'cp_ad_packs' );\r\n\t\r\n\t//edite by dazake add menu page \r\n // add_submenu_page( basename(__FILE__), __('Dazake Packages','appthemes'), __('Dazake Packages','appthemes'), 'manage_options', 'dazake_packages', 'cp_ad_dazake_packs' );\r\n add_submenu_page( basename(__FILE__), __('Premium Packages','appthemes'), __('Premium Packages','appthemes'), 'manage_options', 'premium_packages', 'cp_ad_premium_packs' );\r\n\t//end edite by dazake \r\n\t\r\n\tadd_submenu_page( basename(__FILE__), __('Coupons','appthemes'), __('Coupons','appthemes'), 'manage_options', 'coupons', 'cp_coupons' );\r\n\tadd_submenu_page( basename(__FILE__), __('Payment Gateway Options','appthemes'), __('Gateways','appthemes'), 'manage_options', 'gateways', 'cp_gateways' );\r\n\tadd_submenu_page( basename(__FILE__), __('Form Layouts','appthemes'), __('Form Layouts','appthemes'), 'manage_options', 'layouts', 'cp_form_layouts' );\r\n\tadd_submenu_page( basename(__FILE__), __('Custom Fields','appthemes'), __('Custom Fields','appthemes'), 'manage_options', 'fields', 'cp_custom_fields' );\r\n\tadd_submenu_page( basename(__FILE__), __('Transactions','appthemes'), __('Transactions','appthemes'), 'manage_options', 'transactions', 'cp_transactions' );\r\n\tappthemes_add_submenu_page(); // do_action hook\r\n\tadd_submenu_page( basename(__FILE__), __('System Info','appthemes'), __('System Info','appthemes'), 'manage_options', 'sysinfo', 'cp_system_info' );\r\n}", "function update_settings_tab(){\n woocommerce_update_options($this->get_settings());\n }", "function themeoptions_admin_menu() {\n\tadd_theme_page ( \"Theme Options\", \"Theme Options\", 'edit_themes', basename ( __FILE__ ), 'themeoptions_page' );\n}", "function propanel_siteoptions_add_admin() {\n\n global $query_string;\n \n if ( isset($_REQUEST['page']) && $_REQUEST['page'] == 'siteoptions' ) {\n\t\tif (isset($_REQUEST['of_save']) && 'reset' == $_REQUEST['of_save']) {\n\t\t\t$options = get_option('of_template'); \n\t\t\tpropanel_of_reset_options($options,'siteoptions');\n\t\t\theader(\"Location: admin.php?page=siteoptions&reset=true\");\n\t\t\tdie;\n\t\t}\n }\n\t\t\n $tt_page = add_theme_page('Site Options', 'Site Options', 'edit_theme_options', 'siteoptions','propanel_siteoptions_options_page');\n\tadd_action(\"admin_print_scripts-$tt_page\", 'propanel_of_load_only');\n\tadd_action(\"admin_print_styles-$tt_page\",'propanel_of_style_only');\n}", "public function process_admin_options() {\n \t\t\tif( isset( $_POST['jigoshop_tgm_custom_gateway_enabled'] ) ) update_option( 'jigoshop_tgm_custom_gateway_enabled', jigowatt_clean( $_POST['jigoshop_tgm_custom_gateway_enabled'] ) ); else @delete_option( 'jigoshop_tgm_custom_gateway_enabled' );\n \t\t\tif( isset( $_POST['jigoshop_tgm_custom_gateway_title'] ) ) update_option( 'jigoshop_tgm_custom_gateway_title', jigowatt_clean( $_POST['jigoshop_tgm_custom_gateway_title'] ) ); else @delete_option( 'jigoshop_tgm_custom_gateway_title' );\n \t\t\tif( isset( $_POST['jigoshop_tgm_custom_gateway_description'] ) ) update_option( 'jigoshop_tgm_custom_gateway_description', \tjigowatt_clean( $_POST['jigoshop_tgm_custom_gateway_description'] ) ); else @delete_option( 'jigoshop_tgm_custom_gateway_description' );\n \t}", "function TS_VCSC_Set_Plugin_Options() {\r\n\t\t// Redirect Option\r\n\t\tadd_option('ts_vcsc_extend_settings_redirect', \t\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_activation', \t\t\t\t\t\t0);\r\n\t\t// Options for Theme Authors\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypes', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeWidget',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeTeam',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeTestimonial',\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeLogo', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_posttypeSkillset',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_additions', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_codeeditors', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_fontimport', \t\t\t\t 1);\r\n\t\tadd_option('ts_vcsc_extend_settings_iconicum', \t\t\t\t \t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_dashboard', \t\t\t\t\t\t1);\r\n\t\t// Options for Custom CSS/JS Editor\r\n\t\tadd_option('ts_vcsc_extend_settings_customCSS',\t\t\t\t\t\t\t'/* Welcome to the Custom CSS Editor! Please add all your Custom CSS here. */');\r\n\t\tadd_option('ts_vcsc_extend_settings_customJS', \t\t\t\t '/* Welcome to the Custom JS Editor! Please add all your Custom JS here. */');\r\n\t\t// Other Options\r\n\t\tadd_option('ts_vcsc_extend_settings_frontendEditor', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_buffering', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_mainmenu', \t\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsDomain', \t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_previewImages',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_visualSelector',\t\t\t\t\t1);\r\n add_option('ts_vcsc_extend_settings_nativeSelector',\t\t\t\t\t1);\r\n add_option('ts_vcsc_extend_settings_nativePaginator',\t\t\t\t\t'200');\r\n\t\tadd_option('ts_vcsc_extend_settings_backendPreview',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_extended', \t\t\t\t 0);\r\n\t\tadd_option('ts_vcsc_extend_settings_systemInfo',\t\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_socialDefaults', \t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_builtinLightbox', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_lightboxIntegration', \t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowAutoUpdate', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowNotification', \t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowDeprecated', \t\t\t\t\t0);\r\n\t\t// Font Active / Inactive\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceMedia',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceIcon',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceAwesome',\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceBrankic',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCountricons',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCurrencies',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceElegant',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceEntypo',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceFoundation',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceGenericons',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceIcoMoon',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceMonuments',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceSocialMedia',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceTypicons',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceFontsAll',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Awesome',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Entypo',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Linecons',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_OpenIconic',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceVC_Typicons',\t\t\t\t0);\t\t\r\n\t\t// Custom Font Data\r\n\t\tadd_option('ts_vcsc_extend_settings_IconFontSettings',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustom',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomArray',\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomJSON',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomPath',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomPHP', \t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomName',\t\t\t\t\t'Custom User Font');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomAuthor',\t\t\t\t'Custom User');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomCount',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomDate',\t\t\t\t\t'');\r\n\t\tadd_option('ts_vcsc_extend_settings_tinymceCustomDirectory',\t\t\t'');\r\n\t\t// Row + Column Extensions\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsRows',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsColumns',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsRowEffectsBreak',\t\t\t'600');\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsSmoothScroll',\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_additionsSmoothSpeed',\t\t\t\t'30');\r\n\t\t// Custom Post Types\r\n\t\tadd_option('ts_vcsc_extend_settings_customWidgets',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customTeam',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customTestimonial',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_customSkillset',\t\t\t\t\t0);\t\t\r\n\t\tadd_option('ts_vcsc_extend_settings_customTimelines', \t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_customLogo', \t\t\t\t\t\t0);\r\n\t\t// tinyMCE Icon Shortcode Generator\r\n\t\tadd_option('ts_vcsc_extend_settings_useIconGenerator',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_useTinyMCEMedia', \t\t\t\t\t1);\r\n\t\t// Standard Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_StandardElements',\t\t\t\t\t'');\r\n\t\t// Demo Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_DemoElements', \t\t\t\t\t\t'');\r\n\t\t// WooCommerce Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_WooCommerceUse',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_WooCommerceElements',\t\t\t\t'');\r\n\t\t// bbPress Elements\r\n\t\tadd_option('ts_vcsc_extend_settings_bbPressUse',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_bbPressElements',\t\t\t\t\t'');\r\n\t\t// Options for External Files\r\n\t\tadd_option('ts_vcsc_extend_settings_loadForcable',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadLightbox', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadTooltip', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadFonts', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadEnqueue',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadHeader',\t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadjQuery', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadModernizr',\t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadWaypoints', \t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadCountTo', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadMooTools', \t\t\t\t\t\t1);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadDetector', \t\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_loadHammerNew', \t\t\t\t\t1);\r\n\t\t// Google Font Manager Settings\r\n\t\tadd_option('ts_vcsc_extend_settings_allowGoogleManager', \t\t\t\t1);\r\n\t\t// Single Page Navigator\r\n\t\tadd_option('ts_vcsc_extend_settings_allowPageNavigator', \t\t\t\t0);\r\n\t\t// EnlighterJS - Syntax Highlighter\r\n\t\tadd_option('ts_vcsc_extend_settings_allowEnlighterJS',\t\t\t\t\t0);\r\n\t\tadd_option('ts_vcsc_extend_settings_allowThemeBuilder',\t\t\t\t\t0);\r\n\t\t// Post Type Menu Positions\r\n\t\t$TS_VCSC_Menu_Positions_Defaults_Init = array(\r\n\t\t\t'ts_widgets'\t\t\t\t\t=> 50,\r\n\t\t\t'ts_timeline'\t\t\t\t\t=> 51,\r\n\t\t\t'ts_team'\t\t\t\t\t\t=> 52,\r\n\t\t\t'ts_testimonials'\t\t\t\t=> 53,\r\n\t\t\t'ts_skillsets'\t\t\t\t\t=> 54,\r\n\t\t\t'ts_logos'\t\t\t\t\t\t=> 55,\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_menuPositions',\t\t\t\t\t\t$TS_VCSC_Menu_Positions_Defaults_Init);\r\n\t\t// Row Toggle Settings\r\n\t\t$TS_VCSC_Row_Toggle_Defaults_Init = array(\r\n\t\t\t'Large Devices' => 1200,\r\n\t\t\t'Medium Devices' => 992,\r\n\t\t\t'Small Devices' => 768,\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_rowVisibilityLimits', \t\t\t\t$TS_VCSC_Row_Toggle_Defaults_Init);\r\n\t\t// Language Settings: Countdown\r\n\t\t$TS_VCSC_Countdown_Language_Defaults_Init = array(\r\n\t\t\t'DayPlural' => 'Days',\r\n\t\t\t'DaySingular' => 'Day',\r\n\t\t\t'HourPlural' => 'Hours',\r\n\t\t\t'HourSingular' => 'Hour',\r\n\t\t\t'MinutePlural' => 'Minutes',\r\n\t\t\t'MinuteSingular' => 'Minute',\r\n\t\t\t'SecondPlural' => 'Seconds',\r\n\t\t\t'SecondSingular' => 'Second',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsCountdown', \t\t\t$TS_VCSC_Countdown_Language_Defaults_Init);\r\n\t\t// Language Settings: Google Maps PLUS\r\n\t\t$TS_VCSC_Google_MapPLUS_Language_Defaults_Init = array(\r\n\t\t\t'ListenersStart' => 'Start Listeners',\r\n\t\t\t'ListenersStop' => 'Stop Listeners',\r\n\t\t\t'MobileShow' => 'Show Google Map',\r\n\t\t\t'MobileHide' => 'Hide Google Map',\r\n\t\t\t'StyleDefault' => 'Google Standard',\r\n\t\t\t'StyleLabel' => 'Change Map Style',\r\n\t\t\t'FilterAll' => 'All Groups',\r\n\t\t\t'FilterLabel' => 'Filter by Groups',\r\n\t\t\t'SelectLabel' => 'Zoom to Location',\r\n\t\t\t'ControlsOSM' => 'Open Street',\r\n\t\t\t'ControlsHome' => 'Home',\r\n\t\t\t'ControlsBounds' => 'Fit All',\r\n\t\t\t'ControlsBike' => 'Bicycle Trails',\r\n\t\t\t'ControlsTraffic' => 'Traffic',\r\n\t\t\t'ControlsTransit' => 'Transit',\r\n\t\t\t'TrafficMiles' => 'Miles per Hour',\r\n\t\t\t'TrafficKilometer' => 'Kilometers per Hour',\r\n\t\t\t'TrafficNone' => 'No Data Available',\r\n\t\t\t'SearchButton' => 'Search Location',\r\n\t\t\t'SearchHolder' => 'Enter address to search for ...',\r\n\t\t\t'SearchGoogle' => 'View on Google Maps',\r\n\t\t\t'SearchDirections' => 'Get Directions',\r\n\t\t\t'OtherLink' => 'Learn More!',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsGoogleMapPLUS', \t\t$TS_VCSC_Google_MapPLUS_Language_Defaults_Init);\r\n\t\t// Language Settings: Google Maps (Deprecated)\r\n\t\t$TS_VCSC_Google_Map_Language_Defaults_Init = array(\r\n\t\t\t'TextCalcShow' => 'Show Address Input',\r\n\t\t\t'TextCalcHide' => 'Hide Address Input',\r\n\t\t\t'TextDirectionShow' => 'Show Directions',\r\n\t\t\t'TextDirectionHide' => 'Hide Directions',\r\n\t\t\t'TextResetMap' => 'Reset Map',\r\n\t\t\t'PrintRouteText' \t\t\t => 'Print Route',\r\n\t\t\t'TextViewOnGoogle' => 'View on Google',\r\n\t\t\t'TextButtonCalc' => 'Show Route',\r\n\t\t\t'TextSetTarget' => 'Please enter your Start Address:',\r\n\t\t\t'TextGeoLocation' => 'Get My Location',\r\n\t\t\t'TextTravelMode' => 'Travel Mode',\r\n\t\t\t'TextDriving' => 'Driving',\r\n\t\t\t'TextWalking' => 'Walking',\r\n\t\t\t'TextBicy' => 'Bicycling',\r\n\t\t\t'TextWP' => 'Optimize Waypoints',\r\n\t\t\t'TextButtonAdd' => 'Add Stop on the Way',\r\n\t\t\t'TextDistance' => 'Total Distance:',\r\n\t\t\t'TextMapHome' => 'Home',\r\n\t\t\t'TextMapBikes' => 'Bicycle Trails',\r\n\t\t\t'TextMapTraffic' => 'Traffic',\r\n\t\t\t'TextMapSpeedMiles' => 'Miles Per Hour',\r\n\t\t\t'TextMapSpeedKM' => 'Kilometers Per Hour',\r\n\t\t\t'TextMapNoData' => 'No Data Available!',\r\n\t\t\t'TextMapMiles' => 'Miles',\r\n\t\t\t'TextMapKilometes' => 'Kilometers',\r\n\t\t\t'TextMapActivate' => 'Show Google Map',\r\n\t\t\t'TextMapDeactivate' => 'Hide Google Map',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsGoogleMap', \t\t\t$TS_VCSC_Google_Map_Language_Defaults_Init);\r\n\t\t// Language Settings: Isotope Posts\r\n\t\t$TS_VCSC_Isotope_Posts_Language_Defaults_Init = array(\r\n\t\t\t'ButtonFilter'\t\t => 'Filter Posts', \r\n\t\t\t'ButtonLayout'\t\t => 'Change Layout',\r\n\t\t\t'ButtonSort'\t\t => 'Sort Criteria',\r\n\t\t\t// Standard Post Strings\r\n\t\t\t'Date' \t\t\t\t => 'Post Date', \r\n\t\t\t'Modified' \t\t\t => 'Post Modified', \r\n\t\t\t'Title' \t\t\t => 'Post Title', \r\n\t\t\t'Author' \t\t\t => 'Post Author', \r\n\t\t\t'PostID' \t\t\t => 'Post ID', \r\n\t\t\t'Comments' \t\t\t => 'Number of Comments',\r\n\t\t\t// Layout Strings\r\n\t\t\t'SeeAll'\t\t\t => 'See All',\r\n\t\t\t'Timeline' \t\t\t => 'Timeline',\r\n\t\t\t'Masonry' \t\t\t => 'Centered Masonry',\r\n\t\t\t'FitRows'\t\t\t => 'Fit Rows',\r\n\t\t\t'StraightDown' \t\t => 'Straigt Down',\r\n\t\t\t// WooCommerce Strings\r\n\t\t\t'WooFilterProducts' => 'Filter Products',\r\n\t\t\t'WooTitle' => 'Product Title',\r\n\t\t\t'WooPrice' => 'Product Price',\r\n\t\t\t'WooRating' => 'Product Rating',\r\n\t\t\t'WooDate' => 'Product Date',\r\n\t\t\t'WooModified' => 'Product Modified',\r\n\t\t\t// General Strings\r\n\t\t\t'Categories' => 'Categories',\r\n\t\t\t'Tags' => 'Tags',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_translationsIsotopePosts', \t\t\t$TS_VCSC_Isotope_Posts_Language_Defaults_Init);\r\n\t\t// Options for Lightbox Settings\r\n\t\t$TS_VCSC_Lightbox_Setting_Defaults_Init = array(\r\n\t\t\t'thumbs' => 'bottom',\r\n\t\t\t'thumbsize' => 50,\r\n\t\t\t'animation' => 'random',\r\n\t\t\t'captions' => 'data-title',\r\n\t\t\t'closer' => 1, // true/false\r\n\t\t\t'duration' => 5000,\r\n\t\t\t'share' => 0, // true/false\r\n\t\t\t'social' \t => 'fb,tw,gp,pin',\r\n\t\t\t'notouch' => 1, // true/false\r\n\t\t\t'bgclose'\t\t\t => 1, // true/false\r\n\t\t\t'nohashes'\t\t\t => 1, // true/false\r\n\t\t\t'keyboard'\t\t\t => 1, // 0/1\r\n\t\t\t'fullscreen'\t\t => 1, // 0/1\r\n\t\t\t'zoom'\t\t\t\t => 1, // 0/1\r\n\t\t\t'fxspeed'\t\t\t => 300,\r\n\t\t\t'scheme'\t\t\t => 'dark',\r\n\t\t\t'removelight' => 0,\r\n\t\t\t'customlight' => 0,\r\n\t\t\t'customcolor'\t\t => '#ffffff',\r\n\t\t\t'backlight' \t\t => '#ffffff',\r\n\t\t\t'usecolor' \t\t => 0, // true/false\r\n\t\t\t'background' => '',\r\n\t\t\t'repeat' => 'no-repeat',\r\n\t\t\t'overlay' => '#000000',\r\n\t\t\t'noise' => '',\r\n\t\t\t'cors' => 0, // true/false\r\n\t\t\t'scrollblock' => 'css',\r\n\t\t);\r\n\t\tadd_option('ts_vcsc_extend_settings_defaultLightboxSettings',\t\t\t$TS_VCSC_Lightbox_Setting_Defaults_Init);\r\n\t\tadd_option('ts_vcsc_extend_settings_defaultLightboxAnimation', \t\t\t'random');\r\n\t\t// Options for Envato Sales Data\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoData', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoInfo', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoLink', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoPrice', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoRating', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoSales', \t\t\t\t\t '');\r\n\t\tadd_option('ts_vcsc_extend_settings_envatoCheck', \t\t\t\t\t 0);\r\n\t\t$roles \t\t\t\t\t\t\t\t= get_editable_roles();\r\n\t\tforeach ($GLOBALS['wp_roles']->role_objects as $key => $role) {\r\n\t\t\tif (isset($roles[$key]) && $role->has_cap('edit_pages') && !$role->has_cap('ts_vcsc_extend')) {\r\n\t\t\t\t$role->add_cap('ts_vcsc_extend');\r\n\t\t\t}\r\n\t\t}\r\n\t}", "function custom_theme_options() {\n /**\n * Get a copy of the saved settings array. \n */\n $saved_settings = get_option( 'option_tree_settings', array() );\n \n /**\n * Custom settings array that will eventually be \n * passed to the OptionTree Settings API Class.\n */\n $custom_settings = array( \n 'contextual_help' => array( \n 'sidebar' => ''\n ),\n 'sections' => array( \n array(\n 'id' => 'general',\n 'title' => 'General'\n ),\n array(\n 'id' => 'style',\n 'title' => 'Style'\n ),\n array(\n 'id' => 'homepage_settings',\n 'title' => 'Homepage Settings'\n ),\n array(\n 'id' => 'home_slider',\n 'title' => 'Home Slider'\n ),\n array(\n 'id' => 'portfolio_settings',\n 'title' => 'Portfolio Settings'\n ),\n array(\n 'id' => 'slider_settings',\n 'title' => 'Global Slider Settings'\n ),\n array(\n 'id' => 'blog',\n 'title' => 'Blog'\n ),\n array(\n 'id' => 'social',\n 'title' => 'Social Accounts'\n ),\n array(\n 'id' => 'contact_settings',\n 'title' => 'Contact Infos'\n ),\n array(\n 'id' => 'woocommerce_settings',\n 'title' => 'WooCommerce'\n )\n ),\n 'settings' => array( \n array(\n 'id' => 'logo',\n 'label' => 'Logo',\n 'desc' => 'Upload a logo for your site.',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'full_width_menu',\n 'label' => 'Full Width Menu',\n 'desc' => 'Enable full width menu or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Full Width Menu',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'favicon',\n 'label' => 'Favicon',\n 'desc' => 'Upload a favicon for your site.',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'enable_top_bar',\n 'label' => 'Enable Top Bar',\n 'desc' => 'Enable top bar or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Enable Top Bar',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'top_bar_info',\n 'label' => 'Top Bar Info',\n 'desc' => 'Enter the info you would like to display in top bar of your site.',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'header_info',\n 'label' => 'Header Info',\n 'desc' => 'Enter the info you would like to display in the header of your site.',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'info_under_the_footer',\n 'label' => 'Info Under the Footer',\n 'desc' => '<p>Enter the info you would like to display under the footer of your site.</p>',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'footer_info',\n 'label' => 'Footer Info',\n 'desc' => 'Enter the info you would like to display in the footer of your site.',\n 'std' => 'Copyright &copy; 2012. All Rights Reserved.',\n 'type' => 'textarea',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'sub_footer_info',\n 'label' => 'Sub-Footer Info',\n 'desc' => 'Enter the info you would like to display in the sub-footer of your site.',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'tracking_code',\n 'label' => 'Tracking Code',\n 'desc' => 'Paste your Google Analytics (or other) tracking code here.',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'section' => 'general',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'primary_typography',\n 'label' => 'Primary Typography',\n 'desc' => 'The Primary Typography option type is for adding typographic styles to your site. The most important one though is Google Fonts to create custom font stacks. Default color is #111111.',\n 'std' => array(\n 'font-color' => '#111111'\n ),\n 'type' => 'typography',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'google_font_family',\n 'label' => 'Google Web Font Primary Typography',\n 'desc' => '<p class=\"warning\">Paste Google Web Font link to your website.</p><p><b>Read more:</b> <a href=\"http://www.google.com/webfonts\" target=\"_blank\"><code>http://www.google.com/webfonts</code></a></p>',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'google_font_name',\n 'label' => 'Google Web Font Name for Primary Typography',\n 'desc' => 'Enter the Google Web Font name for primary typography.',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'header_typography',\n 'label' => 'Header Typography',\n 'desc' => 'The Header Typography option type is for adding typographic styles for headers to your site. The most important one though is Google Fonts to create custom font stacks. Default color is #111111.',\n 'std' => '',\n 'type' => 'typography',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'header_google_font_family',\n 'label' => 'Google Web Font Header Typography',\n 'desc' => '<p class=\"warning\">Paste Google Web Font link for headings to your website.</p><p><b>Read more:</b> <a href=\"http://www.google.com/webfonts\" target=\"_blank\"><code>http://www.google.com/webfonts</code></a></p>',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'header_google_font_name',\n 'label' => 'Google Web Font Name for Header Typography',\n 'desc' => 'Enter the Google Web Font name for header typography.',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'primary_link_color',\n 'label' => 'Primary Link Color',\n 'desc' => 'Choose a color for primary link color. Default value is #ababab.',\n 'std' => '#ababab',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'secondary_link_color',\n 'label' => 'Secondary Link Color',\n 'desc' => 'Choose a value for secondary link color. Default value is #111111.',\n 'std' => '#111111',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'secondary_link_color_hover',\n 'label' => 'Secondary Link Color &mdash; Hover/Active',\n 'desc' => 'Choose a value for secondary link color &mdash; hover/active. Default value is #bca474.',\n 'std' => '#bca474',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'navigation_link_color',\n 'label' => 'Navigation Link Color &mdash; Hover/Active',\n 'desc' => 'Choose a value for navigation link color &mdash; hover/active. Default value is #bca474.',\n 'std' => '#bca474',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'secondary_text_color',\n 'label' => 'Secondary Text Color',\n 'desc' => 'Choose a value for secondary text color. Default value is #777777.',\n 'std' => '#777777',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'primary_borders_color',\n 'label' => 'Primary Borders Color',\n 'desc' => 'Choose a value for primary borders color. Default value is #cfcfcf.',\n 'std' => '#cfcfcf',\n 'type' => 'colorpicker',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'background',\n 'label' => 'Background',\n 'desc' => 'Upload a background for your site.',\n 'std' => '',\n 'type' => 'background',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'custom_css',\n 'label' => 'Custom CSS',\n 'desc' => 'Quickly add some CSS to your theme by adding it to this block.',\n 'std' => '',\n 'type' => 'css',\n 'section' => 'style',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_welcome_message',\n 'label' => 'Home Welcome Message',\n 'desc' => '<p>The large welcome message that appears above the slider.</p>',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'homepage_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_portfolios_per_page',\n 'label' => 'Portfolio Items',\n 'desc' => 'Enter the amount of portfolio items you would like to show on the homepage.',\n 'std' => '16',\n 'type' => 'text',\n 'section' => 'homepage_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'view_more_projects_text',\n 'label' => '&ldquo;View more projects&rdquo; link',\n 'desc' => 'Enter the title of the &ldquo;View more projects&rdquo; link.',\n 'std' => '',\n 'type' => 'text',\n 'section' => 'homepage_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'enable_home_slider',\n 'label' => 'Enable Slideshow',\n 'desc' => 'Enable slideshow or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'home_slider',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Enable Slideshow',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'home_slider_height',\n 'label' => 'Slider Height',\n 'desc' => '<p>Customize height of slideshow.</p><p>Note: The optimal dimensions for your slideshow images are 959px wide by 370px high.</p>',\n 'std' => '370',\n 'type' => 'text',\n 'section' => 'home_slider',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_slider_list',\n 'label' => 'Home Slider',\n 'desc' => '<p>You can create as many slides as your project requires and use them how you see fit.</p><p>All of the slides can be sorted and rearranged to your liking with Drag &amp; Drop. Don\\'t worry about the order in which you create your slides, you can always reorder them.</p>',\n 'std' => '',\n 'type' => 'list-item',\n 'section' => 'home_slider',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'settings' => array( \n array(\n 'id' => 'home_slider_image',\n 'label' => 'Image',\n 'desc' => '',\n 'std' => '',\n 'type' => 'upload',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_slider_highlight_color',\n 'label' => 'Title highlight color',\n 'desc' => 'Choose a value for title highlight color. Default value is #111111.',\n 'std' => '#111111',\n 'type' => 'colorpicker',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_slider_link',\n 'label' => 'Link',\n 'desc' => '',\n 'std' => 'javascript:void(null);',\n 'type' => 'text',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_slider_description',\n 'label' => 'Description',\n 'desc' => '',\n 'std' => '',\n 'type' => 'textarea',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n )\n )\n ),\n array(\n 'id' => 'portfolio_message',\n 'label' => 'Portfolio Message',\n 'desc' => '<p>The large message that appears above the portfolio items.</p>',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'portfolio_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'portfolios_per_page',\n 'label' => 'Portfolio pages show at most',\n 'desc' => 'Enter the number of Portfolios to show per page.',\n 'std' => '12',\n 'type' => 'text',\n 'section' => 'portfolio_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'portfolio_filtering',\n 'label' => 'Portfolio Filtering',\n 'desc' => 'Display portfolio filtering or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'portfolio_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Portfolio Filtering',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'portfolio_meta',\n 'label' => 'Portfolio Meta',\n 'desc' => 'Select what information to display for each portfolio item on the portfolio page just under their title.',\n 'std' => '',\n 'type' => 'select',\n 'section' => 'portfolio_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'categories',\n 'label' => 'Categories',\n 'src' => ''\n ),\n array(\n 'value' => 'none',\n 'label' => 'None',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'portfolio_page',\n 'label' => 'Portfolio Page',\n 'desc' => 'Select the portfolio page. Used for the \"Back to portfolio\" link.',\n 'std' => '',\n 'type' => 'page-select',\n 'section' => 'portfolio_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'autoplay',\n 'label' => 'Autoplay',\n 'desc' => '<p>Enable autoplay or not?</p>',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'slider_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Autoplay',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'pause_on_hover',\n 'label' => 'Pause on Hover',\n 'desc' => '<p>Pause autoplay on hover?</p>',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'slider_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Pause on Hover',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'delay',\n 'label' => 'Delay between slides in ms',\n 'desc' => '<p>Delay between items in ms.</p>',\n 'std' => '4500',\n 'type' => 'text',\n 'section' => 'slider_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'control_navigation',\n 'label' => 'Control Navigation',\n 'desc' => '<p>Select navigation type.</p>',\n 'std' => '',\n 'type' => 'select',\n 'section' => 'slider_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'bullets',\n 'label' => 'Bullets',\n 'src' => ''\n ),\n array(\n 'value' => 'thumbnails',\n 'label' => 'Thumbnails',\n 'src' => ''\n ),\n array(\n 'value' => 'none',\n 'label' => 'None',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'enable_blog_title',\n 'label' => 'Enable Title / Welcome Message',\n 'desc' => 'Enable Title / Welcome Message or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'blog',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Enable Title / Welcome Message',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'blog_message',\n 'label' => 'Blog Message',\n 'desc' => '<p>The large message that appears above posts.</p>',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'blog',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'social_accounts',\n 'label' => 'Social Accounts',\n 'desc' => '<p>Which links would you like to display?</p>',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'facebook',\n 'label' => 'Facebook',\n 'src' => ''\n ),\n array(\n 'value' => 'twitter',\n 'label' => 'Twitter',\n 'src' => ''\n ),\n array(\n 'value' => 'gplus',\n 'label' => 'Google Plus',\n 'src' => ''\n ),\n array(\n 'value' => 'linkedin',\n 'label' => 'LinkedIn',\n 'src' => ''\n ),\n array(\n 'value' => 'dribbble',\n 'label' => 'Dribbble',\n 'src' => ''\n ),\n array(\n 'value' => 'pinterest',\n 'label' => 'Pinterest',\n 'src' => ''\n ),\n array(\n 'value' => 'foursquare',\n 'label' => 'Foursquare',\n 'src' => ''\n ),\n array(\n 'value' => 'instagram',\n 'label' => 'Instagram',\n 'src' => ''\n ),\n array(\n 'value' => 'vimeo',\n 'label' => 'Vimeo',\n 'src' => ''\n ),\n array(\n 'value' => 'flickr',\n 'label' => 'Flickr',\n 'src' => ''\n ),\n array(\n 'value' => 'github',\n 'label' => 'GitHub',\n 'src' => ''\n ),\n array(\n 'value' => 'tumblr',\n 'label' => 'Tumblr',\n 'src' => ''\n ),\n array(\n 'value' => 'forrst',\n 'label' => 'Forrst',\n 'src' => ''\n ),\n array(\n 'value' => 'lastfm',\n 'label' => 'Last.fm',\n 'src' => ''\n ),\n array(\n 'value' => 'stumbleupon',\n 'label' => 'StumbleUpon',\n 'src' => ''\n ),\n array(\n 'value' => 'feed',\n 'label' => 'RSS',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'facebook_url',\n 'label' => 'Facebook Address (URL)',\n 'desc' => '',\n 'std' => 'http://www.facebook.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'twitter_url',\n 'label' => 'Twitter Address (URL)',\n 'desc' => '',\n 'std' => 'https://twitter.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'gplus_url',\n 'label' => 'Google Plus Address (URL)',\n 'desc' => '',\n 'std' => 'https://plus.google.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'linkedin_url',\n 'label' => 'LinkedIn Address (URL)',\n 'desc' => '',\n 'std' => 'http://www.linkedin.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'dribbble_url',\n 'label' => 'Dribbble Address (URL)',\n 'desc' => '',\n 'std' => 'http://dribbble.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'pinterest_url',\n 'label' => 'Pinterest Address (URL)',\n 'desc' => '',\n 'std' => 'http://pinterest.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'foursquare_url',\n 'label' => 'Foursquare Address (URL)',\n 'desc' => '',\n 'std' => 'https://foursquare.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'instagram_url',\n 'label' => 'Instagram Address (URL)',\n 'desc' => '',\n 'std' => 'http://instagram.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'vimeo_url',\n 'label' => 'Vimeo Address (URL)',\n 'desc' => '',\n 'std' => 'https://vimeo.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'flickr_url',\n 'label' => 'Flickr Address (URL)',\n 'desc' => '',\n 'std' => 'http://www.flickr.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'github_url',\n 'label' => 'GitHub Address (URL)',\n 'desc' => '',\n 'std' => 'https://github.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'tumblr_url',\n 'label' => 'Tumblr Address (URL)',\n 'desc' => '',\n 'std' => 'https://www.tumblr.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'forrst_url',\n 'label' => 'Forrst Address (URL)',\n 'desc' => '',\n 'std' => 'http://forrst.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'lastfm_url',\n 'label' => 'Last.fm Address (URL)',\n 'desc' => '',\n 'std' => 'http://www.lastfm.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'stumbleupon_url',\n 'label' => 'StumbleUpon Address (URL)',\n 'desc' => '',\n 'std' => 'http://www.stumbleupon.com/',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'feed_url',\n 'label' => 'RSS Address (URL)',\n 'desc' => '',\n 'std' => 'javascript:void(null);',\n 'type' => 'text',\n 'section' => 'social',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'contact_message',\n 'label' => 'Contact Message',\n 'desc' => '<p>The large message that appears above the map.</p>',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'map_address',\n 'label' => 'Adress',\n 'desc' => '<p>Insert your Adress here. Example:</p><p>13/2 Elizabeth Street, Melbourne VIC 3000</p>',\n 'std' => '3/2 Elizabeth Street, Melbourne VIC 3000',\n 'type' => 'text',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'map_height',\n 'label' => 'Map Height',\n 'desc' => 'Insert map height.',\n 'std' => '401',\n 'type' => 'text',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'map_content',\n 'label' => 'Map Info Content',\n 'desc' => 'Insert Map Info Content here. Example:<p>Envato (FlashDen Pty Ltd) 13/2 Elizabeth Street, Melbourne VIC 3000 (03) 9023 0074 &middot; envato.com</p>',\n 'std' => 'Envato (FlashDen Pty Ltd) 13/2 Elizabeth Street, Melbourne VIC 3000 (03) 9023 0074 &middot; envato.com',\n 'type' => 'textarea-simple',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'map_grayscale',\n 'label' => 'Grayscale',\n 'desc' => '<p>Enable grayscale or not?</p>',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Grayscale',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'map_custom_marker',\n 'label' => 'Custom Marker',\n 'desc' => 'Upload a custom marker for your address.',\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'contact_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'woo_account',\n 'label' => 'Display My Account link',\n 'desc' => '<p>Displays a link to the user account section?</p><br><p>If the user is not logged in the link will display &ldquo;Login / Registration&rdquo; and take the use to the login / signup page. If the user is logged in the link will display &ldquo;My account&rdquo; and take them directly to their account.</p>',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'woocommerce_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Account',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'enable_home_banners_shop',\n 'label' => 'Enable Banners',\n 'desc' => 'Enable banners or not?',\n 'std' => '',\n 'type' => 'checkbox',\n 'section' => 'woocommerce_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'choices' => array( \n array(\n 'value' => 'yes',\n 'label' => 'Enable Banners',\n 'src' => ''\n )\n ),\n ),\n array(\n 'id' => 'home_banners_shop_list',\n 'label' => 'Banners',\n 'desc' => '<p>You can create as many banners as your project requires and use them how you see fit.</p><p>Note: The optimal dimensions for your banner images are 300px wide by 280px high.</p><p>All of the banners can be sorted and rearranged to your liking with Drag &amp; Drop. Don\\'t worry about the order in which you create your slides, you can always reorder them.</p>',\n 'std' => '',\n 'type' => 'list-item',\n 'section' => 'woocommerce_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => '',\n 'settings' => array( \n array(\n 'id' => 'home_banner_image',\n 'label' => 'Image',\n 'desc' => '',\n 'std' => '',\n 'type' => 'upload',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_banner_highlight_color',\n 'label' => 'Title highlight color',\n 'desc' => 'Choose a value for title highlight color. Default value is #E0CE79.',\n 'std' => '#E0CE79',\n 'type' => 'colorpicker',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_banner_link',\n 'label' => 'Link',\n 'desc' => '',\n 'std' => '',\n 'type' => 'text',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'home_banner_description',\n 'label' => 'Description',\n 'desc' => '',\n 'std' => '',\n 'type' => 'textarea-simple',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n )\n )\n ),\n array(\n 'id' => 'account_benefits_info',\n 'label' => 'Account Benefits Info',\n 'desc' => 'Enter the info you would like to display under the <strong>&ldquo;Create an account&rdquo;</strong> form of your site.',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'woocommerce_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n ),\n array(\n 'id' => 'returning_customer_info',\n 'label' => 'Returning Customer Info',\n 'desc' => 'Enter the info you would like to display under the <strong>&ldquo;Returning Customer Info&rdquo;</strong> form of your site.',\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'woocommerce_settings',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'class' => ''\n )\n )\n );\n \n /* allow settings to be filtered before saving */\n $custom_settings = apply_filters( 'option_tree_settings_args', $custom_settings );\n \n /* settings are not the same update the DB */\n if ( $saved_settings !== $custom_settings ) {\n update_option( 'option_tree_settings', $custom_settings ); \n }\n \n}", "function load_settings() {\r\n $options = get_option($this->optionsName);\r\n\r\n if ($old_setting = get_option('custom_page_extension')) {\r\n delete_option('custom_page_extension');\r\n }\r\n\r\n $defaults = array(\r\n 'extension' => ($old_setting != \"\") ? $old_setting : 'html',\r\n );\r\n\r\n $this->options = (object) wp_parse_args($options, $defaults);\r\n }", "function wp_protect_special_option($option)\n {\n }", "function wcnc2015_options_check() {\n\tif ( ! get_option( 'my-options-data' ) ) {\n\t\t$options_defaults['extra_tagline'] \t= '';\n\t\t$options_defaults['footer_text']\t= '';\n\n\t\tupdate_option( 'my-options-data', $options_defaults );\n\t}\n}", "function theme_save_settings()\n\t{\n\t\tglobal $pagenow;\n\t\t\n\t\tif ( $pagenow == 'themes.php' && $_GET['page'] == 'theme-options' )\n\t\t{\n\t\t\tif ( isset ( $_GET['tab'] ) )\n\t\t\t{\n\t\t\t\t$tab = $_GET['tab'];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$tab = 'general';\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tswitch ( $tab )\n\t\t\t{\n\t\t\t\tcase 'general' :\n\t\t\t\t\n\t\t\t\t\tupdate_option( 'logo_image', $_POST['logo_image'] );\n\t\t\t\t\tupdate_option( 'header_background_image', $_POST['header_background_image'] );\n\t\t\t\t\tupdate_option( 'select_text_logo', $_POST['select_text_logo'] );\n\t\t\t\t\tupdate_option( 'theme_site_title', $_POST['theme_site_title'] );\n\t\t\t\t\tupdate_option( 'select_tagline', $_POST['select_tagline'] );\n\t\t\t\t\tupdate_option( 'theme_tagline', $_POST['theme_tagline'] );\n\t\t\t\t\tupdate_option( 'logo_login', $_POST['logo_login'] );\n\t\t\t\t\tupdate_option( 'logo_login_hide', $_POST['logo_login_hide'] );\n\t\t\t\t\tupdate_option( 'favicon', $_POST['favicon'] );\n\t\t\t\t\tupdate_option( 'apple_touch_icon', $_POST['apple_touch_icon'] );\n\t\t\t\t\tupdate_option( 'google_map_api_key', $_POST['google_map_api_key'] );\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'style' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'char_set_latin', $_POST['char_set_latin'] );\n\t\t\t\t\tupdate_option( 'char_set_latin_ext', $_POST['char_set_latin_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_cyrillic', $_POST['char_set_cyrillic'] );\n\t\t\t\t\tupdate_option( 'char_set_cyrillic_ext', $_POST['char_set_cyrillic_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_greek', $_POST['char_set_greek'] );\n\t\t\t\t\tupdate_option( 'char_set_greek_ext', $_POST['char_set_greek_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_vietnamese', $_POST['char_set_vietnamese'] );\n\t\t\t\t\tupdate_option( 'extra_font_styles', $_POST['extra_font_styles'] );\n\t\t\t\t\tupdate_option( 'classic_navigation_menu', $_POST['classic_navigation_menu'] );\n\t\t\t\t\tupdate_option( 'mobile_zoom', $_POST['mobile_zoom'] );\n\t\t\t\t\tupdate_option( 'custom_css', $_POST['custom_css'] );\n\t\t\t\t\tupdate_option( 'external_css', $_POST['external_css'] );\n\t\t\t\t\tupdate_option( 'external_js', $_POST['external_js'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'animation' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'classic_layout', $_POST['classic_layout'] );\n\t\t\t\t\tupdate_option( 'mobile_only_classic_layout', $_POST['mobile_only_classic_layout'] );\n\t\t\t\t\tupdate_option( 'pf_details_page_in_animation', $_POST['pf_details_page_in_animation'] );\n\t\t\t\t\tupdate_option( 'pf_details_page_out_animation', $_POST['pf_details_page_out_animation'] );\n\t\t\t\t\tupdate_option( 'pixelwars__ajax', $_POST['pixelwars__ajax'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'blog' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'theme_excerpt', $_POST['theme_excerpt'] );\n\t\t\t\t\tupdate_option( 'pagination', $_POST['pagination'] );\n\t\t\t\t\tupdate_option( 'about_the_author_module', $_POST['about_the_author_module'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'seo' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'theme_og_protocol', $_POST['theme_og_protocol'] );\n\t\t\t\t\tupdate_option( 'theme_seo_fields', $_POST['theme_seo_fields'] );\n\t\t\t\t\tupdate_option( 'site_description', $_POST['site_description'] );\n\t\t\t\t\tupdate_option( 'site_keywords', $_POST['site_keywords'] );\n\t\t\t\t\tupdate_option( 'tracking_code_head', $_POST['tracking_code_head'] );\n\t\t\t\t\tupdate_option( 'tracking_code_body', $_POST['tracking_code_body'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t}", "function wpex_customizer_options_sanitize( $options ) {\n\t\tif ( $options ) {\n\t\t\t// Delete options if import set to -1\n\t\t\tif ( '-1' == $options['reset'] ) {\n\t\t\t\t// Get menu locations\n\t\t\t\t$locations = get_theme_mod( 'nav_menu_locations' );\n\t\t\t\t$save_menus = array();\n\t\t\t\tforeach( $locations as $key => $val ) {\n\t\t\t\t\t$save_menus[$key] = $val;\n\t\t\t\t}\n\t\t\t\t// Remove all mods\n\t\t\t\tremove_theme_mods();\n\t\t\t\t// Re-add the menus\n\t\t\t\tset_theme_mod( 'nav_menu_locations', array_map( 'absint', $save_menus ) );\n\t\t\t\t// Error messages\n\t\t\t\t$error_msg = __( 'All theme customizer settings have been reset.', 'wpex-zero' );\n\t\t\t\t$error_type = 'updated';\n\t\t\t}\n\t\t\t// Set theme mods based on json data\n\t\t\telseif( ! empty( $options['import'] ) ) {\n\t\t\t\t// Decode input data\n\t\t\t\t$theme_mods = json_decode( $options['import'], true );\n\t\t\t\t// Validate json file then set new theme options\n\t\t\t\tif ( '0' == json_last_error() ) {\n\t\t\t\t\tforeach ( $theme_mods as $theme_mod => $value ) {\n\t\t\t\t\t\tset_theme_mod( $theme_mod, $value );\n\t\t\t\t\t}\n\t\t\t\t\t$error_msg = __( 'Theme customizer settings imported successfully.', 'wpex-zero' );\n\t\t\t\t\t$error_type = 'updated';\n\t\t\t\t}\n\t\t\t\t// Display invalid json data error\n\t\t\t\telse {\n\t\t\t\t\t$error_msg = __( 'Invalid Import Data.', 'wpex-zero' );\n\t\t\t\t\t$error_type = 'error';\n\t\t\t\t}\n\t\t\t}\n\t\t\t// No json data entered\n\t\t\telse {\n\t\t\t\t$error_msg = __( 'No import data found.', 'wpex-zero' );\n\t\t\t\t$error_type = 'error';\n\t\t\t}\n\t\t\t// Make sure the settings data is reset! \n\t\t\t$options = array(\n\t\t\t\t'import'\t=> '',\n\t\t\t\t'reset'\t\t=> '',\n\t\t\t);\n\t\t}\n\t\t// Display message\n\t\tadd_settings_error(\n\t\t\t'wpex-customizer-notices',\n\t\t\tesc_attr( 'settings_updated' ),\n\t\t\t$error_msg,\n\t\t\t$error_type\n\t\t);\n\n\t\t// Return options\n\t\treturn $options;\n\t}", "function optionsframework_option_name() {\n $optionsframework_settings = get_option( 'optionsframework' );\n $optionsframework_settings[\"id\"] = 'options_wpex_themes';\n update_option( 'optionsframework', $optionsframework_settings );\n}", "function thb_custom_theme_options() {\n \n /**\n * Get a copy of the saved settings array. \n */\n $saved_settings = get_option( 'option_tree_settings', array() );\n \n /**\n * Create a custom settings array that we pass to \n * the OptionTree Settings API Class.\n */\n $custom_settings = array(\n 'sections' => array(\n array(\n 'title' => esc_html__('Blog', 'werkstatt'),\n 'id' => 'blog'\n ),\n array(\n 'title' => esc_html__('Header & Menu', 'werkstatt'),\n 'id' => 'header'\n ),\n array(\n 'title' => esc_html__('Portfolio', 'werkstatt'),\n 'id' => 'portfolio'\n ),\n array(\n 'title' => esc_html__('Shop', 'werkstatt'),\n 'id' => 'shop'\n ),\n array(\n 'title' => esc_html__('Footer', 'werkstatt'),\n 'id' => 'footer'\n ),\n array(\n 'title' => esc_html__('Typography', 'werkstatt'),\n 'id' => 'typography'\n ),\n array(\n 'title' => esc_html__('Customization', 'werkstatt'),\n 'id' => 'customization'\n ),\n array(\n 'title' => esc_html__('Sound & Music', 'werkstatt'),\n 'id' => 'sounds'\n ),\n array(\n 'title' => esc_html__('Misc', 'werkstatt'),\n 'id' => 'misc'\n ),\n array(\n 'title' => esc_html__('Demo Content', 'werkstatt'),\n 'id' => 'import'\n )\n ),\n 'settings' => array(\n \tarray(\n \t 'id' => 'blog_tab0',\n \t 'label' => esc_html__('Blog Listing', 'werkstatt'),\n \t 'type' => 'tab',\n \t 'section' => 'blog'\n \t),\n \tarray(\n \t 'label' => esc_html__('Blog Style', 'werkstatt'),\n \t 'id' => 'blog_style',\n \t 'type' => 'radio',\n \t 'desc' => esc_html__('You can choose different blog styles here', 'werkstatt'),\n \t 'choices' => array(\n \t array(\n \t 'label' => esc_html__('Style 1 - Grid', 'werkstatt'),\n \t 'value' => 'style1'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 2 - Vertical', 'werkstatt'),\n \t 'value' => 'style2'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 3 - Left Thumbnail', 'werkstatt'),\n \t 'value' => 'style3'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 4 - Hover List', 'werkstatt'),\n \t 'value' => 'style4'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 5 - Masonry', 'werkstatt'),\n \t 'value' => 'style5'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 6 - Hover Grid', 'werkstatt'),\n \t 'value' => 'style6'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 7 - Large Left Thumbnail', 'werkstatt'),\n \t 'value' => 'style7'\n \t ),\n \t array(\n \t 'label' => esc_html__('Style 8 - Border Grid', 'werkstatt'),\n \t 'value' => 'style8'\n \t ),\n \t ),\n \t 'std' => 'style1',\n \t 'section' => 'blog'\n \t),\n \tarray(\n \t 'label' => esc_html__('Blog Pagination Style', 'werkstatt'),\n \t 'id' => 'blog_pagination_style',\n \t 'type' => 'radio',\n \t 'desc' => esc_html__('You can choose different blog pagination styles here. The regular pagination will be used for archive pages.', 'werkstatt'),\n \t 'choices' => array(\n \t array(\n \t 'label' => esc_html__('Regular Pagination', 'werkstatt'),\n \t 'value' => 'style1'\n \t ),\n \t array(\n \t 'label' => esc_html__('Load More Button', 'werkstatt'),\n \t 'value' => 'style2'\n \t ),\n \t array(\n \t 'label' => esc_html__('Infinite Scroll', 'werkstatt'),\n \t 'value' => 'style3'\n \t )\n \t ),\n \t 'std' => 'style1',\n \t 'section' => 'blog'\n \t),\n array(\n 'id' => 'blog_tab1',\n 'label' => esc_html__('Article Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Article Style', 'werkstatt'),\n 'id' => 'article_style',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose a default Article Style here.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Title Overlay - No Post Formats', 'werkstatt'),\n 'value' => 'style1'\n ),\n array(\n 'label' => esc_html__('Full Image', 'werkstatt'),\n 'value' => 'style2'\n ),\n array(\n 'label' => esc_html__('Full Image with Sidebar', 'werkstatt'),\n 'value' => 'style3'\n ),\n array(\n 'label' => esc_html__('Medium Image with Sidebar', 'werkstatt'),\n 'value' => 'style4'\n ),\n array(\n 'label' => esc_html__('Small Image with Sidebar', 'werkstatt'),\n 'value' => 'style5'\n ),\n ),\n 'std' => 'style1',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Use Header Animation?', 'werkstatt'),\n 'id' => 'blog_header_animation',\n 'type' => 'on_off',\n 'desc' => esc_html__('When scrolling down, the header will transform to display the sharing icons.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Display Tags?', 'werkstatt'),\n 'id' => 'article_tags',\n 'type' => 'on_off',\n 'desc' => esc_html__('Displays article tags at the bottom', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Display Author Info?', 'werkstatt'),\n 'id' => 'article_author',\n 'type' => 'on_off',\n 'desc' => esc_html__('Displays author information at the bottom. Will only be displayed if the author description is filled.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Display Related Posts?', 'werkstatt'),\n 'id' => 'article_related',\n 'type' => 'on_off',\n 'desc' => esc_html__('Displays related posts at the bottom.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'blog'\n ),\n array(\n 'label' => esc_html__('Display Article Navigation?', 'werkstatt'),\n 'id' => 'blog_nav',\n 'type' => 'on_off',\n 'desc' => esc_html__('Displays article navigation at the bottom', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'blog'\n ),\n array(\n 'id' => 'blog_tab2',\n 'label' => esc_html__('Sharing Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'blog'\n ),\n array(\n 'label' => 'Sharing buttons',\n 'id' => 'sharing_buttons',\n 'type' => 'checkbox',\n 'desc' => 'You can choose which social networks to display and get counts from. Please visit <strong>Theme Options > Misc</strong> to fill out application details for the social media sites you choose.',\n 'choices' => array(\n array(\n 'label' => 'Facebook',\n 'value' => 'facebook'\n ),\n array(\n 'label' => 'Twitter',\n 'value' => 'twitter'\n ),\n array(\n 'label' => 'Pinterest',\n 'value' => 'pinterest'\n ),\n array(\n 'label' => 'Google Plus',\n 'value' => 'google-plus'\n ),\n array(\n 'label' => 'Linkedin',\n 'value' => 'linkedin'\n ),\n array(\n 'label' => 'Vkontakte',\n 'value' => 'vkontakte'\n ),\n array(\n 'label' => 'WhatsApp',\n 'value' => 'whatsapp'\n ),\n array(\n 'label' => 'E-Mail',\n 'value' => 'email'\n )\n ),\n 'section' => 'blog'\n ),\n array(\n 'id' => 'portfolio_tab0',\n 'label' => esc_html__('General', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Portfolio Slug', 'werkstatt'),\n 'id' => 'portfolio_slug',\n 'type' => 'text',\n 'desc' => esc_html__('The portfolio slug used for the portfolio permalinks', 'werkstatt'),\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Portfolio Main Page Selection', 'werkstatt'),\n 'id' => 'portfolio_main',\n 'type' => 'page-select',\n 'desc' => esc_html__('The page that the portfolio navigation links back to. This can be overridden inside individual portfolio items.', 'werkstatt'),\n 'section' => 'portfolio'\n ),\n array(\n 'id' => 'portfolio_tab1',\n 'label' => esc_html__('Detail', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Use Header Animation?', 'werkstatt'),\n 'id' => 'portfolio_header_animation',\n 'type' => 'on_off',\n 'desc' => esc_html__('When scrolling down, the header will transform to display the sharing icons.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Portfolio Title / Description Animation', 'werkstatt'),\n 'id' => 'portfolio_title_animation',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can toggle the title animations for the portfolio pages here.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Display Portfolio Navigation?', 'werkstatt'),\n 'id' => 'portfolio_nav',\n 'type' => 'on_off',\n 'desc' => esc_html__('Displays portfolio navigation at the bottom', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'portfolio'\n ),\n array(\n 'label' => esc_html__('Limit Navigation to Same Categories?', 'werkstatt'),\n 'id' => 'portfolio_nav_cat',\n 'type' => 'on_off',\n 'desc' => esc_html__('When enabled, the portfolio navigation will be limited within same categories', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'portfolio',\n 'condition' => 'portfolio_nav:is(on)'\n ),\n array(\n 'id' => 'shop_tab0',\n 'label' => esc_html__('General', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Product Title Color', 'werkstatt'),\n 'id' => 'product_style1_color',\n 'type' => 'radio',\n 'desc' => esc_html__('If you have dark product images, you can use the Light option..', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Light', 'werkstatt'),\n 'value' => 'light'\n ),\n array(\n 'label' => esc_html__('Dark', 'werkstatt'),\n 'value' => 'dark'\n )\n ),\n 'std' => 'dark',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Shop Sidebar', 'werkstatt' ),\n 'id' => 'shop_sidebar',\n 'type' => 'radio',\n 'desc' => esc_html__('Would you like to display sidebar on shop main and category pages?', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('No Sidebar', 'werkstatt'),\n 'value' => 'no'\n ),\n array(\n 'label' => esc_html__('Right Sidebar', 'werkstatt'),\n 'value' => 'right'\n ),\n array(\n 'label' => esc_html__('Left Sidebar', 'werkstatt'),\n 'value' => 'left'\n )\n ),\n 'std' => 'no',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Products Per Page', 'werkstatt' ),\n 'id' => 'products_per_page',\n 'type' => 'text',\n 'section' => 'shop',\n 'std' \t\t\t\t=> '12'\n ),\n array(\n \t'label' => esc_html__('Products Per Row', 'werkstatt' ),\n 'id' => 'products_per_row',\n 'std' => '4',\n 'type' => 'numeric-slider',\n 'section' => 'shop',\n 'min_max_step'=> '2,6,1'\n ),\n array(\n 'id' => 'shop_tab1',\n 'label' => esc_html__('Product Page', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Product Style', 'werkstatt' ),\n 'id' => 'product_style',\n 'type' => 'radio',\n 'desc' => esc_html__('This changes the layout of the product pages.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Style 1', 'werkstatt'),\n 'value' => 'style1'\n ),\n array(\n 'label' => esc_html__('Style 2', 'werkstatt'),\n 'value' => 'style2'\n )\n ),\n 'std' => 'style1',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Product Image Position Style', 'werkstatt' ),\n 'id' => 'product_image_position',\n 'type' => 'radio',\n 'desc' => esc_html__('This changes the position of the image', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Left', 'werkstatt'),\n 'value' => 'left'\n ),\n array(\n 'label' => esc_html__('Right', 'werkstatt'),\n 'value' => 'right'\n )\n ),\n 'std' => 'left',\n 'section' => 'shop'\n ),\n array(\n 'label' => esc_html__('Product Image Size', 'werkstatt' ),\n 'id' => 'product_image_size',\n 'type' => 'radio',\n 'desc' => esc_html__('This changes the space image takes up', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Small', 'werkstatt'),\n 'value' => '4'\n ),\n array(\n 'label' => esc_html__('Medium', 'werkstatt'),\n 'value' => '6'\n ),\n array(\n 'label' => esc_html__('Large', 'werkstatt'),\n 'value' => '8'\n )\n ),\n 'std' => '6',\n 'section' => 'shop'\n ),\n array(\n 'id' => 'header_tab1',\n 'label' => esc_html__('Menu Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Header Style', 'werkstatt'),\n 'id' => 'header_style',\n 'type' => 'radio',\n 'desc' => esc_html__('Which header style would you like to use?', 'werkstatt'),\n 'choices' => array(\n \t\tarray(\n \t\t\t'label' => esc_html__('Style 1 (Left Logo)', 'werkstatt'),\n \t\t\t'value' => 'style1'\n \t\t),\n \t\tarray(\n \t\t\t'label' => esc_html__('Style 2 (Center Logo)', 'werkstatt'),\n \t\t\t'value' => 'style2'\n \t\t)\n ),\n 'std' => 'style1',\n 'section'\t => 'header'\n ),\n array(\n 'label' => esc_html__('Header Search', 'werkstatt'),\n 'id' => 'header_search',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can toggle the search icon here.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Header Cart', 'werkstatt'),\n 'id' => 'header_cart',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can toggle the cart icon here.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Menu Style', 'werkstatt'),\n 'id' => 'menu_style',\n 'type' => 'radio',\n 'desc' => esc_html__('Which menu style would you like to use?', 'werkstatt'),\n 'choices' => array(\n \t\tarray(\n \t\t\t'label' => esc_html__('Style 1 (Mobile Menu)', 'werkstatt'),\n \t\t\t'value' => 'menu_style1'\n \t\t),\n \t\tarray(\n \t\t\t'label' => esc_html__('Style 2 (Full Menu)', 'werkstatt'),\n \t\t\t'value' => 'menu_style2'\n \t\t)\n ),\n 'std' => 'menu_style1',\n 'section'\t => 'header'\n ),\n array(\n 'label' => esc_html__('Full Menu Social Links', 'werkstatt' ),\n 'id' => 'fullmenu_social_link',\n 'type' => 'social-links',\n 'desc' => esc_html__('Add your desired Social Links next to the full menu here', 'werkstatt' ),\n 'section' => 'header',\n 'condition' => 'menu_style:is(menu_style2)'\n ),\n array(\n 'label' => esc_html__('Language Switcher', 'werkstatt'),\n 'id' => 'thb_ls',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can toggle the language switcher here. Requires that you have WPML installed.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'header'\n ),\n array(\n 'id' => 'header_tab2',\n 'label' => esc_html__('Mobile Menu Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Style', 'werkstatt'),\n 'id' => 'mobile_menu_style',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose your mobile menu style here', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Style 1 (Half-page)', 'werkstatt'),\n 'value' => 'style1'\n ),\n array(\n 'label' => esc_html__('Style 2 (Full Screen)', 'werkstatt'),\n 'value' => 'style2'\n )\n ),\n 'std' => 'style1',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Mobile Submenu Behaviour', 'werkstatt'),\n 'id' => 'submenu_behaviour',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose how your arrows signs work', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Default - Clickable parent links', 'werkstatt'),\n 'value' => 'thb-default'\n ),\n array(\n 'label' => esc_html__('Open Submenu - Parent links open submenus', 'werkstatt'),\n 'value' => 'thb-submenu'\n )\n ),\n 'std' => 'thb-default',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Secondary Menu Style', 'werkstatt'),\n 'id' => 'secondary_menu_style',\n 'type' => 'radio',\n 'desc' => esc_html__('This will change the secondary menu that is under the main menu. You can choose to have 1 or 2 columns.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('2 columns', 'werkstatt'),\n 'value' => '2'\n ),\n array(\n 'label' => esc_html__('1 column', 'werkstatt'),\n 'value' => '1'\n )\n ),\n 'std' => '2',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Color', 'werkstatt'),\n 'id' => 'mobile_menu_color',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose your mobile menu color here.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Light', 'werkstatt'),\n 'value' => 'light'\n ),\n array(\n 'label' => esc_html__('Dark', 'werkstatt'),\n 'value' => 'dark'\n )\n ),\n 'std' => 'dark',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Link Animation', 'werkstatt'),\n 'id' => 'mobile_menu_link_animation',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose your mobile menu link animation here. If Background Fill is selected, the mobile menu background will change according to image defined for each menu item in Appearance > Menus.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Link Fill', 'werkstatt'),\n 'value' => 'link-fill'\n ),\n array(\n 'label' => esc_html__('Background Fill', 'werkstatt'),\n 'value' => 'bg-fill'\n )\n ),\n 'std' => 'link-fill',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Link Fill Color', 'werkstatt'),\n 'id' => 'mobile_menu_link_fill',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('Hover color for the Link Fill setting', 'werkstatt'),\n 'section' => 'header',\n 'condition' => 'mobile_menu_link_animation:is(link-fill)'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Footer', 'werkstatt'),\n 'id' => 'menu_footer',\n 'type' => 'textarea',\n 'desc' => esc_html__('This content appears at the bottom of the menu. You can use your shortcodes here.', 'werkstatt'),\n 'rows' => '4',\n 'section' => 'header'\n ),\n array(\n 'id' => 'header_tab3',\n 'label' => esc_html__('Logo Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Logo Height', 'werkstatt'),\n 'id' => 'logo_height',\n 'type' => 'measurement',\n 'desc' => esc_html__('You can modify the logo height from here. This is maximum height, so your logo may get smaller depending on spacing inside header', 'werkstatt'),\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Dark Logo Upload (black)', 'werkstatt'),\n 'id' => 'logo',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own logo here. Since this theme is retina-ready, <strong>please upload a double the size you set above.</strong>', 'werkstatt'),\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Light Logo Upload (white)', 'werkstatt'),\n 'id' => 'logo_light',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own logo here. Since this theme is retina-ready, <strong>please upload a double the size you set above.</strong>', 'werkstatt'),\n 'section' => 'header'\n ),\n array(\n 'id' => 'header_tab4',\n 'label' => esc_html__('Measurements', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Icon Size', 'werkstatt'),\n 'id' => 'mobile_menu_icon_size',\n 'type' => 'numeric-slider',\n 'desc' => esc_html__('This changes the size of the mobile menu icon', 'werkstatt'),\n \t'min_max_step'=> '1,10,1',\n 'std' => '1',\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Header Padding', 'werkstatt'),\n 'id' => 'header_padding',\n 'type' => 'spacing',\n 'desc' => esc_html__('This affects header on large screens. The values are in px.', 'werkstatt'),\n 'section' => 'header'\n ),\n array(\n 'label' => esc_html__('Half Page Mobile Menu Width', 'werkstatt'),\n 'id' => 'mobile_menu_width',\n 'type' => 'numeric-slider',\n 'desc' => esc_html__('This changes the width of the mobile menu on desktop screens', 'werkstatt'),\n \t'min_max_step'=> '30,100,5',\n 'std' => '50',\n 'section' => 'header'\n ),\n array(\n 'id' => 'footer_tab0',\n 'label' => esc_html__('Footer Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Display Footer', 'werkstatt'),\n 'id' => 'footer',\n 'type' => 'on_off',\n 'desc' => esc_html__('Would you like to display the Footer?', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Footer Effect', 'werkstatt'),\n 'id' => 'footer_effect',\n 'type' => 'on_off',\n 'desc' => esc_html__('Would you like to use the fold effect? This also affects the sub-footer', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Footer Max-Width', 'werkstatt'),\n 'id' => 'footer_max_width',\n 'type' => 'on_off',\n 'desc' => esc_html__('Disabling this will make the footer full-width on large screens', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'footer',\n 'condition' => 'footer:is(on)'\n ),\n array(\n 'label' => esc_html__('Footer Columns', 'werkstatt'),\n 'id' => 'footer_columns',\n 'type' => 'radio-image',\n 'desc' => esc_html__('You can change the layout of footer columns here', 'werkstatt'),\n 'std' => 'threecolumns',\n 'section' => 'footer',\n 'condition' => 'footer:is(on)'\n ),\n array(\n 'label' => esc_html__('Footer Color', 'werkstatt'),\n 'id' => 'footer_color',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose your footer color here. You can also change your footer background from \"Customization\"', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Light', 'werkstatt'),\n 'value' => 'light'\n ),\n array(\n 'label' => esc_html__('Dark', 'werkstatt'),\n 'value' => 'dark'\n )\n ),\n 'std' => 'light',\n 'section' => 'footer',\n 'condition' => 'footer:is(on)'\n ),\n array(\n 'label' => esc_html__('Footer Shadow', 'werkstatt'),\n 'id' => 'footer_shadow',\n 'type' => 'radio',\n 'desc' => esc_html__('You can change the footer shadow here', 'werkstatt'),\n 'choices' => array(\n \tarray(\n \t 'label' => esc_html__('None', 'werkstatt'),\n \t 'value' => 'none'\n \t),\n array(\n 'label' => esc_html__('Light', 'werkstatt'),\n 'value' => 'light'\n ),\n array(\n 'label' => esc_html__('Heavy', 'werkstatt'),\n 'value' => 'heavy'\n )\n ),\n 'std' => 'heavy',\n 'section' => 'footer',\n 'condition' => 'footer:is(on)'\n ),\n array(\n 'id' => 'footer_tab1',\n 'label' => esc_html__('Call-to-Action', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Display Call-to-Action', 'werkstatt'),\n 'id' => 'call_to_action',\n 'type' => 'on_off',\n 'desc' => esc_html__('Would you like to display the Call-to-Action? <small>You can customize the colors on \"Customization\"</small>', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Text', 'werkstatt' ),\n 'id' => 'call_to_action_text',\n 'type' => 'textarea',\n 'desc' => esc_html__('Content to be displayed on the Call-to-Action', 'werkstatt' ),\n 'section' => 'footer',\n 'std' \t\t\t\t=> sprintf(esc_html__('\n \t%1$sReady to take your WordPress site to the next level?%2$s', 'werkstatt'),\n \t'<h3 style=\"color:#fff\">',\n \t'</h3>'\n ),\n 'condition' => 'call_to_action:is(on)'\n ),\n array(\n 'label' => esc_html__('Button Style', 'werkstatt' ),\n 'id' => 'call_to_action_button_style',\n 'type' => 'radio',\n 'choices' => array(\n \tarray(\n \t 'label' => esc_html__('Default', 'werkstatt'),\n \t 'value' => ''\n \t),\n array(\n 'label' => esc_html__('Border Button with Solid Fill', 'werkstatt'),\n 'value' => 'thb-border-style'\n ),\n array(\n 'label' => esc_html__('Text with Border Fill', 'werkstatt'),\n 'value' => 'thb-text-style'\n ),\n array(\n 'label' => esc_html__('3d Effect', 'werkstatt'),\n 'value' => 'thb-3d-style'\n ),\n array(\n 'label' => esc_html__('Fill Effect', 'werkstatt'),\n 'value' => 'thb-fill-style'\n )\n ),\n 'std' => '',\n 'desc' => esc_html__('Call-to-Action Button Style', 'werkstatt' ),\n 'section' => 'footer',\n 'condition' => 'call_to_action:is(on)'\n ),\n array(\n 'label' => esc_html__('Button Color', 'werkstatt' ),\n 'id' => 'call_to_action_button_color',\n 'type' => 'radio',\n 'choices' => array(\n \tarray(\n \t 'label' => esc_html__('Black', 'werkstatt'),\n \t 'value' => ''\n \t),\n array(\n 'label' => esc_html__('White', 'werkstatt'),\n 'value' => 'white'\n ),\n array(\n 'label' => esc_html__('Accent', 'werkstatt'),\n 'value' => 'accent'\n )\n ),\n 'std' => 'white',\n 'desc' => esc_html__('Call-to-Action Button Color', 'werkstatt' ),\n 'section' => 'footer',\n 'condition' => 'call_to_action:is(on)'\n ),\n array(\n 'label' => esc_html__('Button Text', 'werkstatt' ),\n 'id' => 'call_to_action_button_text',\n 'type' => 'text',\n 'desc' => esc_html__('Call-to-Action Button Text', 'werkstatt' ),\n 'section' => 'footer',\n 'std' \t\t\t\t=> esc_html__('Purchase Now', 'werkstatt'),\n 'condition' => 'call_to_action:is(on)'\n ),\n array(\n 'label' => esc_html__('Button Link', 'werkstatt' ),\n 'id' => 'call_to_action_button_link',\n 'type' => 'text',\n 'desc' => esc_html__('Call-to-Action Button link', 'werkstatt' ),\n 'section' => 'footer',\n 'std' \t\t\t\t=> esc_html__('https://themeforest.net/item/werkstatt-creative-portfolio-theme/17870799?ref=fuelthemes', 'werkstatt'),\n 'condition' => 'call_to_action:is(on)'\n ),\n array(\n 'id' => 'footer_tab2',\n 'label' => esc_html__('Sub-Footer Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Display Sub-Footer', 'werkstatt'),\n 'id' => 'subfooter',\n 'type' => 'on_off',\n 'desc' => esc_html__('Would you like to display the Sub-Footer?', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'footer'\n ),\n array(\n 'label' => esc_html__('Sub-Footer Max-Width', 'werkstatt'),\n 'id' => 'subfooter_max_width',\n 'type' => 'on_off',\n 'desc' => esc_html__('Disabling this will make the sub-footer full-width on large screens', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'footer',\n 'condition' => 'subfooter:is(on)'\n ),\n array(\n 'label' => esc_html__('Sub-Footer Color', 'werkstatt'),\n 'id' => 'subfooter_color',\n 'type' => 'radio',\n 'desc' => esc_html__('You can choose your sub-footer color here. You can also change your sub-footer background from \"Customization\"', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Light', 'werkstatt'),\n 'value' => 'light'\n ),\n array(\n 'label' => esc_html__('Dark', 'werkstatt'),\n 'value' => 'dark'\n )\n ),\n 'std' => 'light',\n 'section' => 'footer',\n 'condition' => 'subfooter:is(on)'\n ),\n array(\n 'label' => esc_html__('Subfooter Text', 'werkstatt' ),\n 'id' => 'subfooter_text',\n 'type' => 'textarea',\n 'desc' => esc_html__('Content to be displayed on the subfooter', 'werkstatt' ),\n 'section' => 'footer',\n 'std' \t\t\t\t=> esc_html__('&copy; 2016 Werkstatt', 'werkstatt'),\n 'condition' => 'subfooter:is(on)'\n ),\n array(\n 'label' => esc_html__('Social Links', 'werkstatt' ),\n 'id' => 'subfooter_social_link',\n 'type' => 'social-links',\n 'desc' => esc_html__('Add your desired Social Links for the subfooter here', 'werkstatt' ),\n 'section' => 'footer',\n 'condition' => 'subfooter:is(on)'\n ),\n array(\n 'id' => 'misc_tab0',\n 'label' => esc_html__('General', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Google Maps API Key', 'werkstatt'),\n 'id' => 'map_api_key',\n 'type' => 'text',\n 'desc' => esc_html__('Please enter the Google Maps Api Key. <small>You need to create a browser API key. For more information, please visit: <a href=\"https://developers.google.com/maps/documentation/javascript/get-api-key\">https://developers.google.com/maps/documentation/javascript/get-api-key</a></small>', 'werkstatt'),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Scroll To Top?', 'werkstatt'),\n 'id' => 'scroll_to_top',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Scroll To Top button here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Extra CSS', 'werkstatt'),\n 'id' => 'extra_css',\n 'type' => 'css',\n 'desc' => esc_html__('Any CSS that you would like to add to the theme.', 'werkstatt'),\n 'section' => 'misc'\n ),\n array(\n 'id' => 'misc_tab1',\n 'label' => esc_html__('Instagram Settings', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Instagram ID', 'werkstatt' ),\n 'id' => 'instagram_id',\n 'type' => 'text',\n 'desc' => sprintf(esc_html__('Your Instagram ID, you can find your ID from here: %1$shttp://www.otzberg.net/iguserid/%2$s', 'werkstatt' ),\n \t'<a href=\"http://www.otzberg.net/iguserid/\">',\n \t'</a>'\n \t),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Instagram Username', 'werkstatt' ),\n 'id' => 'instagram_username',\n 'type' => 'text',\n 'desc' => esc_html__('Your Instagram Username', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Access Token', 'werkstatt' ),\n 'id' => 'instagram_accesstoken',\n 'type' => 'text',\n 'desc' => sprintf(esc_html__('Visit %1$sthis link%2$s in a new tab, sign in with your Instagram account, click on Create a new application and create your own keys in case you dont have already. After that, you can get your Access Token using %3$shttp://instagram.pixelunion.net/%4$s', 'werkstatt' ),\n \t'<a href=\"http://instagr.am/developer/register/\" target=\"_blank\">',\n \t'</a>',\n \t'<a href=\"http://instagram.pixelunion.net/\" target=\"_blank\">',\n \t'</a>'\n \t),\n 'section' => 'misc'\n ),\n array(\n 'id' => 'misc_tab2',\n 'label' => esc_html__('Twitter Settings', 'werkstatt' ),\n 'type' => 'tab',\n 'section' => 'misc'\n ),\n array(\n 'id' => 'twitter_text',\n 'label' => esc_html__('About the Twitter Settings', 'werkstatt' ),\n 'desc' => esc_html__('You should fill out these settings if you want to use the Twitter related widgets or Visual Composer Elements', 'werkstatt' ),\n 'type' => 'textblock',\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Twitter Sharing Cache', 'thevoux'),\n 'id' => 'twitter_cache',\n 'type' => 'select',\n 'desc' => esc_html__('Amount of time before the new tweets are fetched.', 'thevoux'),\n 'choices' => array(\n \tarray(\n \t 'label' => esc_html__('1 Hour', 'thevoux'),\n \t 'value' => '1h'\n \t),\n array(\n 'label' => esc_html__('1 Day', 'thevoux'),\n 'value' => '1'\n ),\n array(\n 'label' => esc_html__('7 Days', 'thevoux'),\n 'value' => '7'\n ),\n array(\n 'label' => esc_html__('30 Days', 'thevoux'),\n 'value' => '30'\n )\n ),\n 'std' => '1',\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Twitter Username', 'werkstatt' ),\n 'id' => 'twitter_bar_username',\n 'type' => 'text',\n 'desc' => esc_html__('Username to pull tweets for', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Consumer Key', 'werkstatt' ),\n 'id' => 'twitter_bar_consumerkey',\n 'type' => 'text',\n 'desc' => esc_html__('Visit <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">this link</a> in a new tab, sign in with your account, click on Create a new application and create your own keys in case you dont have already', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Consumer Secret', 'werkstatt' ),\n 'id' => 'twitter_bar_consumersecret',\n 'type' => 'text',\n 'desc' => esc_html__('Visit <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">this link</a> in a new tab, sign in with your account, click on Create a new application and create your own keys in case you dont have already', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Access Token', 'werkstatt' ),\n 'id' => 'twitter_bar_accesstoken',\n 'type' => 'text',\n 'desc' => esc_html__('Visit <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">this link</a> in a new tab, sign in with your account, click on Create a new application and create your own keys in case you dont have already', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Access Token Secret', 'werkstatt' ),\n 'id' => 'twitter_bar_accesstokensecret',\n 'type' => 'text',\n 'desc' => esc_html__('Visit <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">this link</a> in a new tab, sign in with your account, click on Create a new application and create your own keys in case you dont have already', 'werkstatt' ),\n 'section' => 'misc'\n ),\n array(\n 'label' => esc_html__('Select Your Demo', 'werkstatt'),\n 'id' => 'demo-select',\n 'type' => 'radio-image',\n 'std' => '0',\n 'section' => 'import'\n ),\n array(\n 'id' => 'demo_import',\n 'label' => esc_html__('About Importing Demo Content', 'werkstatt'),\n 'desc' => esc_html__('\n <div id=\"thb-import-messages\"></div>\n <p style=\"text-align:center;\"><a class=\"button button-primary button-hero\" id=\"import-demo-content\" href=\"#\">Import Demo Content</a><br /><br />\n <small>Please press only once, and wait till you get the success message above.<br />If you \\'re having trouble with import, please see: <a href=\"https://fuelthemes.ticksy.com/article/2706/\">What To Do If Demo Content Import Fails</a></p>', 'werkstatt'),\n 'type' => 'textblock',\n 'section' => 'import'\n ),\n array(\n 'id' => 'typography_tab1',\n 'label' => esc_html__('Typography', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Google Font Subsets', 'werkstatt'),\n 'id' => 'font_subsets',\n 'type' => 'radio',\n 'desc' => esc_html__('You can add additional character subset specific to your language.', 'werkstatt'),\n 'choices' => array(\n \tarray(\n \t 'label' => esc_html__('No Subset', 'werkstatt'),\n \t 'value' => 'no-subset'\n \t),\n \tarray(\n \t 'label' => esc_html__('Latin Extended', 'werkstatt'),\n \t 'value' => 'latin-ext'\n \t),\n array(\n 'label' => esc_html__('Greek', 'werkstatt'),\n 'value' => 'greek'\n ),\n array(\n 'label' => esc_html__('Cyrillic', 'werkstatt'),\n 'value' => 'cyrillic'\n ),\n array(\n 'label' => esc_html__('Vietnamese', 'werkstatt'),\n 'value' => 'vietnamese'\n )\n ),\n 'std' => 'no-subset',\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Primary Font', 'werkstatt'),\n 'id' => 'primary_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the primary font. Affects all headings.', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Secondary Font', 'werkstatt'),\n 'id' => 'secondary_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the secondary font', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Button Font', 'werkstatt'),\n 'id' => 'button_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the button. Uses the Secondary Font by default', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Menu Font', 'werkstatt'),\n 'id' => 'menu_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the menu. This also overrides the header font. Uses the Secondary Font by default', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Body Font', 'werkstatt'),\n 'id' => 'body_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the body.', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Full Menu Font', 'werkstatt'),\n 'id' => 'fullmenu_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the full menu style', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Footer Widget Title Font', 'werkstatt'),\n 'id' => 'footer_widget_title_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Family Setting for the footer widget titles', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'id' => 'typography_tab2',\n 'label' => esc_html__('Heading Typography', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'typography'\n ),\n array(\n 'id' => 'heading_text',\n 'label' => esc_html__('About Heading Typography', 'werkstatt'),\n 'desc' => esc_html__('These affect all h* tags inside the theme, so use wisely. Some particular headings may need additional css to target.', 'werkstatt'),\n 'type' => 'textblock',\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 1', 'werkstatt'),\n 'id' => 'h1_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H1 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 2', 'werkstatt'),\n 'id' => 'h2_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H2 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 3', 'werkstatt'),\n 'id' => 'h3_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H3 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 4', 'werkstatt'),\n 'id' => 'h4_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H4 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 5', 'werkstatt'),\n 'id' => 'h5_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H5 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Heading 6', 'werkstatt'),\n 'id' => 'h6_type',\n 'type' => 'typography',\n 'desc' => esc_html__('Font Settings for the H6 tag', 'werkstatt'),\n 'section' => 'typography'\n ),\n array(\n 'id' => 'typography_tab3',\n 'label' => esc_html__('Typekit Support', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'typography'\n ),\n array(\n 'id' => 'typekit_text',\n 'label' => esc_html__('About Typekit Support', 'werkstatt'),\n 'desc' => esc_html__('Please make sure that you enter your Typekit ID or the fonts wont work. After adding Typekit Font Names, these names will appear on the font selection dropdown on the Typography tab.', 'werkstatt'),\n 'std' => '',\n 'type' => 'textblock',\n 'section' => 'typography'\n ),\n array(\n 'label' => esc_html__('Typekit Kit ID', 'werkstatt'),\n 'id' => 'typekit_id',\n 'type' => 'text',\n 'desc' => esc_html__('Paste the provided Typekit Kit ID. <small>Usually 6-7 random letters</small>', 'werkstatt'),\n 'section' => 'typography',\n ),\n array(\n 'label' => esc_html__('Typekit Font Names', 'werkstatt'),\n 'id' => 'typekit_fonts',\n 'type' => 'text',\n 'desc' => esc_html__('Enter your Typekit Font Name, seperated by comma. For example: futura-pt,aktiv-grotesk <strong>Do not leave spaces between commas</strong>', 'werkstatt'),\n 'section' => 'typography',\n ),\n array(\n 'id' => 'customization_tab1',\n 'label' => esc_html__('Backgrounds', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Header Background', 'werkstatt'),\n 'id' => 'header_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the header.', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Footer Background', 'werkstatt'),\n 'id' => 'footer_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the footer', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Sub - Footer Background', 'werkstatt'),\n 'id' => 'subfooter_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the subfooter', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Background', 'werkstatt'),\n 'id' => 'mobilemenu_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the Mobile Menu', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Call-to-Action Background', 'werkstatt'),\n 'id' => 'call_to_action_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the Call-to-Action inside Footer', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('404 Page Background', 'werkstatt'),\n 'id' => 'notfound_bg',\n 'type' => 'background',\n 'class'\t\t\t\t=> 'ot-colorpicker-opacity',\n 'desc' => esc_html__('Background settings for the 404 Page', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'id' => 'customization_tab2',\n 'label' => esc_html__('Colors', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Accent Color', 'werkstatt'),\n 'id' => 'accent_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('You can modify the accent color here, default red you see in some areas.', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Mobile Menu Icon Color', 'werkstatt'),\n 'id' => 'mobile_menu_icon_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('You can modify the hamburger menu icon color here.', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Footer Widget Title Color', 'werkstatt'),\n 'id' => 'footer_widget_title_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('You can modify the footer widget title color here', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Footer Text Color', 'werkstatt'),\n 'id' => 'footer_text_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('You can modify the footer text color here', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('General Link Color', 'werkstatt'),\n 'id' => 'general_link_color',\n 'type' => 'link_color',\n 'desc' => esc_html__('You can modify the general link color here', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Footer Link Color', 'werkstatt'),\n 'id' => 'footer_link_color',\n 'type' => 'link_color',\n 'desc' => esc_html__('You can modify the footer link color here', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'id' => 'typography_tab4',\n 'label' => esc_html__('Measurements', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Footer Padding', 'werkstatt'),\n 'id' => 'footer_padding',\n 'type' => 'spacing',\n 'desc' => esc_html__('You can modify the footer padding here', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'id' => 'customization_tab4',\n 'label' => esc_html__('Preloaders', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Preloader', 'werkstatt' ),\n 'id' => 'thb_preloader',\n 'type' => 'radio',\n 'desc' => esc_html__('This is the hexagon preloader you see on some areas.', 'werkstatt'),\n 'choices' => array(\n array(\n 'label' => esc_html__('Hexagon', 'werkstatt'),\n 'value' => 'hexagon'\n ),\n array(\n 'label' => esc_html__('Circle', 'werkstatt'),\n 'value' => 'circle'\n ),\n array(\n 'label' => esc_html__('No Preloader', 'werkstatt'),\n 'value' => 'no'\n )\n ),\n 'std' => 'hexagon',\n 'section' => 'customization'\n ),\n array(\n 'id' => 'customization_tab5',\n 'label' => esc_html__('Other', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Use Custom Scrollbar?', 'werkstatt'),\n 'id' => 'custom_scrollbar',\n 'type' => 'on_off',\n 'desc' => esc_html__('This only works for Webkit (Chrome, Safari).', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Google Theme Color', 'werkstatt'),\n 'id' => 'thb_google_theme_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('Applied only on Android mobile devices, click <a href=\"https://developers.google.com/web/updates/2014/11/Support-for-theme-color-in-Chrome-39-for-Android\" target=\"_blank\">here</a> to learn more about this', 'werkstatt'),\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Site Border', 'werkstatt'),\n 'id' => 'site_borders',\n 'type' => 'on_off',\n 'desc' => esc_html__('This will add borders around the viewport.', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'customization'\n ),\n array(\n 'label' => esc_html__('Border Width', 'werkstatt'),\n 'id' => 'site_borders_width',\n 'type' => 'measurement',\n 'desc' => esc_html__('You can modify border width here', 'werkstatt'),\n 'section' => 'customization',\n 'condition' => 'site_borders:is(on)'\n ),\n array(\n 'label' => esc_html__('Border Color', 'werkstatt'),\n 'id' => 'site_borders_color',\n 'type' => 'colorpicker',\n 'desc' => esc_html__('You can modify the border color here', 'werkstatt'),\n 'section' => 'customization',\n 'condition' => 'site_borders:is(on)'\n ),\n array(\n 'id' => 'sounds_tab0',\n 'label' => esc_html__('Website Music', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Enable Background Music?', 'werkstatt'),\n 'id' => 'music_sound',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Background Music Here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Restrict Background Music to Homepage', 'werkstatt'),\n 'id' => 'music_sound_toggle_home',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can restrict background music to homepage if desired.', 'werkstatt'),\n 'std' => 'on',\n 'section' => 'sounds',\n 'condition' => 'music_sound:is(on)'\n ),\n array(\n 'label' => esc_html__('Display Background Music Toggle?', 'werkstatt'),\n 'id' => 'music_sound_toggle',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Background Music Here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds',\n 'condition' => 'music_sound:is(on)'\n ),\n array(\n 'label' => esc_html__('Background Music Upload', 'werkstatt'),\n 'id' => 'music_sound_file',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own MP3 file here.', 'werkstatt'),\n 'section' => 'sounds',\n 'condition' => 'music_sound:is(on)'\n ),\n array(\n 'id' => 'sounds_tab1',\n 'label' => esc_html__('General Sounds', 'werkstatt'),\n 'type' => 'tab',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Click Sound', 'werkstatt'),\n 'id' => 'click_sound',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Click Sound here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Click Sound Upload', 'werkstatt'),\n 'id' => 'click_sound_file',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own MP3 file here.', 'werkstatt'),\n 'section' => 'sounds',\n 'condition' => 'click_sound:is(on)'\n ),\n array(\n 'label' => esc_html__('Menu Item Hover Sound', 'werkstatt'),\n 'id' => 'menu_item_hover_sound',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Menu Item Hover Sound here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Menu Item Hover Sound Upload', 'werkstatt'),\n 'id' => 'menu_item_hover_sound_file',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own MP3 file here.', 'werkstatt'),\n 'section' => 'sounds',\n 'condition' => 'menu_item_hover_sound:is(on)'\n ),\n array(\n 'label' => esc_html__('Menu Open Sound', 'werkstatt'),\n 'id' => 'menu_open_sound',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Menu Open Sound here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Menu Open Sound Upload', 'werkstatt'),\n 'id' => 'menu_open_sound_file',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own MP3 file here.', 'werkstatt'),\n 'section' => 'sounds',\n 'condition' => 'menu_open_sound:is(on)'\n ),\n array(\n 'label' => esc_html__('Menu Close Sound', 'werkstatt'),\n 'id' => 'menu_close_sound',\n 'type' => 'on_off',\n 'desc' => esc_html__('You can enable the Menu Close Sound here', 'werkstatt'),\n 'std' => 'off',\n 'section' => 'sounds'\n ),\n array(\n 'label' => esc_html__('Menu Close Sound Upload', 'werkstatt'),\n 'id' => 'menu_close_sound_file',\n 'type' => 'upload',\n 'desc' => esc_html__('You can upload your own MP3 file here.', 'werkstatt'),\n 'section' => 'sounds',\n 'condition' => 'menu_close_sound:is(on)'\n )\n )\n );\n \n /* settings are not the same update the DB */\n if ( $saved_settings !== $custom_settings ) {\n update_option( 'option_tree_settings', $custom_settings ); \n }\n}", "function theme_save_settings()\n\t{\n\t\tglobal $pagenow;\n\t\t\n\t\tif ( $pagenow == 'themes.php' && $_GET['page'] == 'theme-options' )\n\t\t{\n\t\t\tif ( isset ( $_GET['tab'] ) )\n\t\t\t{\n\t\t\t\t$tab = $_GET['tab'];\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$tab = 'general';\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\tswitch ( $tab )\n\t\t\t{\n\t\t\t\tcase 'general' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'logo_type', $_POST['logo_type'] );\n\t\t\t\t\tupdate_option( 'select_text_logo', $_POST['select_text_logo'] );\n\t\t\t\t\tupdate_option( 'theme_site_title', $_POST['theme_site_title'] );\n\t\t\t\t\tupdate_option( 'logo_image', $_POST['logo_image'] );\n\t\t\t\t\tupdate_option( 'select_tagline', $_POST['select_tagline'] );\n\t\t\t\t\tupdate_option( 'theme_tagline', $_POST['theme_tagline'] );\n\t\t\t\t\tupdate_option( 'logo_login', $_POST['logo_login'] );\n\t\t\t\t\tupdate_option( 'logo_login_hide', $_POST['logo_login_hide'] );\n\t\t\t\t\tupdate_option( 'favicon', $_POST['favicon'] );\n\t\t\t\t\tupdate_option( 'apple_touch_icon', $_POST['apple_touch_icon'] );\n\t\t\t\t\tupdate_option( 'copyright_text', $_POST['copyright_text'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'style' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'char_set_latin', $_POST['char_set_latin'] );\n\t\t\t\t\tupdate_option( 'char_set_latin_ext', $_POST['char_set_latin_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_cyrillic', $_POST['char_set_cyrillic'] );\n\t\t\t\t\tupdate_option( 'char_set_cyrillic_ext', $_POST['char_set_cyrillic_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_greek', $_POST['char_set_greek'] );\n\t\t\t\t\tupdate_option( 'char_set_greek_ext', $_POST['char_set_greek_ext'] );\n\t\t\t\t\tupdate_option( 'char_set_vietnamese', $_POST['char_set_vietnamese'] );\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'nav_menu_search', $_POST['nav_menu_search'] );\n\t\t\t\t\tupdate_option( 'extra_font_styles', $_POST['extra_font_styles'] );\n\t\t\t\t\tupdate_option( 'footer_widget_locations', $_POST['footer_widget_locations'] );\n\t\t\t\t\tupdate_option( 'footer_widget_columns', $_POST['footer_widget_columns'] );\n\t\t\t\t\tupdate_option( 'mobile_zoom', $_POST['mobile_zoom'] );\n\t\t\t\t\tupdate_option( 'custom_css', $_POST['custom_css'] );\n\t\t\t\t\tupdate_option( 'external_css', $_POST['external_css'] );\n\t\t\t\t\tupdate_option( 'external_js', $_POST['external_js'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'blog' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'blog_type', $_POST['blog_type'] );\n\t\t\t\t\tupdate_option( 'post_sidebar', $_POST['post_sidebar'] );\n\t\t\t\t\tupdate_option( 'theme_excerpt', $_POST['theme_excerpt'] );\n\t\t\t\t\tupdate_option( 'pagination', $_POST['pagination'] );\n\t\t\t\t\tupdate_option( 'all_formats_homepage', $_POST['all_formats_homepage'] );\n\t\t\t\t\tupdate_option( 'about_the_author_module', $_POST['about_the_author_module'] );\n\t\t\t\t\tupdate_option( 'post_share_links_single', $_POST['post_share_links_single'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'portfolio' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'pf_ajax', $_POST['pf_ajax'] );\n\t\t\t\t\tupdate_option( 'pf_item_per_page', $_POST['pf_item_per_page'] );\n\t\t\t\t\tupdate_option( 'pf_content_editor', $_POST['pf_content_editor'] );\n\t\t\t\t\tupdate_option( 'pf_share_links_single', $_POST['pf_share_links_single'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'gallery' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'gl_ajax', $_POST['gl_ajax'] );\n\t\t\t\t\tupdate_option( 'gl_item_per_page', $_POST['gl_item_per_page'] );\n\t\t\t\t\tupdate_option( 'gl_ajax_single', $_POST['gl_ajax_single'] );\n\t\t\t\t\tupdate_option( 'gl_item_per_page_single', $_POST['gl_item_per_page_single'] );\n\t\t\t\t\tupdate_option( 'gl_slideshow_interval_single', $_POST['gl_slideshow_interval_single'] );\n\t\t\t\t\tupdate_option( 'gl_circular_single', $_POST['gl_circular_single'] );\n\t\t\t\t\tupdate_option( 'gl_next_on_click_image_single', $_POST['gl_next_on_click_image_single'] );\n\t\t\t\t\tupdate_option( 'gl_content_editor', $_POST['gl_content_editor'] );\n\t\t\t\t\tupdate_option( 'gl_share_links_single', $_POST['gl_share_links_single'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'sidebar' :\n\t\t\t\t\n\t\t\t\t\tupdate_option( 'no_sidebar_name', esc_attr( $_POST['new_sidebar_name'] ) );\n\t\t\t\t\t\n\t\t\t\t\tif ( esc_attr( $_POST['new_sidebar_name'] ) != \"\" )\n\t\t\t\t\t{\n\t\t\t\t\t\tif ( get_option( 'sidebars_with_commas' ) == \"\" )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tupdate_option( 'sidebars_with_commas', esc_attr( $_POST['new_sidebar_name'] ) );\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tupdate_option( 'sidebars_with_commas', get_option( 'sidebars_with_commas' ) . ',' . esc_attr( $_POST['new_sidebar_name'] ) );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'seo' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'theme_og_protocol', $_POST['theme_og_protocol'] );\n\t\t\t\t\tupdate_option( 'theme_seo_fields', $_POST['theme_seo_fields'] );\n\t\t\t\t\tupdate_option( 'site_description', $_POST['site_description'] );\n\t\t\t\t\tupdate_option( 'site_keywords', $_POST['site_keywords'] );\n\t\t\t\t\tupdate_option( 'tracking_code_head', $_POST['tracking_code_head'] );\n\t\t\t\t\tupdate_option( 'tracking_code', $_POST['tracking_code'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\t\tcase 'contact' :\n\t\t\t\t\t\n\t\t\t\t\tupdate_option( 'map_embed_code', $_POST['map_embed_code'] );\n\t\t\t\t\tupdate_option( 'enable_map', $_POST['enable_map'] );\n\t\t\t\t\tupdate_option( 'contact_form_email', $_POST['contact_form_email'] );\n\t\t\t\t\tupdate_option( 'contact_form_captcha', $_POST['contact_form_captcha'] );\n\t\t\t\t\tupdate_option( 'disable_contact_form', $_POST['disable_contact_form'] );\n\t\t\t\t\t\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t// end switch\n\t\t}\n\t\t// end if\n\t}", "function bf_flush_options() {\r\n\tglobal $bf_options;\r\n\t\r\n\t$bf_options = new BF_Options();\r\n\t$bf_options->get_options();\r\n\t\r\n\tif ( !get_option(THEME_ID . '_options') ) $bf_options->default_options();\r\n}", "function custom_theme_options() {\n\n /* OptionTree is not loaded yet, or this is not an admin request */\n if ( ! function_exists( 'ot_settings_id' ) || ! is_admin() )\n return false;\n\n /**\n * Get a copy of the saved settings array. \n */\n $saved_settings = get_option( ot_settings_id(), array() );\n \n /**\n * Custom settings array that will eventually be \n * passes to the OptionTree Settings API Class.\n */\n $custom_settings = array( \n \n\t\n 'sections' => array( \n\t array(\n 'id' => 'home_page_setting',\n 'title' => __( 'Home page setting', 'theme-text-domain' )\n ),\n array(\n 'id' => 'option_body',\n 'title' => __( 'Body Section', 'theme-text-domain' )\n ),\n\t array(\n 'id' => 'header_section',\n 'title' => __( 'Header Section', 'theme-text-domain' )\n ),\n\t array(\n 'id' => 'footer_section',\n 'title' => __( 'Footer Section', 'theme-text-domain' )\n ),\n\t array(\n 'id' => 'contact_info',\n 'title' => __( 'Contact Info', 'theme-text-domain' )\n )\n ),\n 'settings' => array( \n\t\t\t\n\t\t array(\n 'label' => __( 'Home Slider', 'theme-text-domain' ),\n 'id' => 'home_slider',\n 'type' => 'gallery',\n 'desc' => sprintf( __( 'This is a slider Picture option type. It displays when %s.', 'theme-text-domain' ), '<code>demo_show_gallery:is(on)</code>' ),\n 'section' => 'home_page_setting'\n ),\n\t\t array(\n 'id' => 'slider_on_off',\n 'label' => __( 'Slider On/Off', 'theme-text-domain' ),\n 'desc' => sprintf( __( 'The On/Off option type displays a simple switch that can be used to turn things on or off. The saved return value is either %s or %s.', 'theme-text-domain' ), '<code>on</code>', '<code>off</code>' ),\n 'std' => '',\n 'type' => 'on-off',\n 'section' => 'home_page_setting',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n\t \n \n\tarray(\n 'id' => 'fashion_typography',\n 'label' => __( 'Typography', 'theme-text-domain' ),\n 'desc' => sprintf( __( 'The Typography option type is for adding typography styles to your theme either dynamically via the CSS option type above or manually with %s. The Typography option type has filters that allow you to remove fields or change the defaults. For example, you can filter %s to remove unwanted fields from all Background options or an individual one. You can also filter %s. These filters allow you to fine tune the select lists for your specific needs.', 'theme-text-domain' ), '<code>ot_get_option()</code>', '<code>ot_recognized_typography_fields</code>', '<code>ot_recognized_font_families</code>, <code>ot_recognized_font_sizes</code>, <code>ot_recognized_font_styles</code>, <code>ot_recognized_font_variants</code>, <code>ot_recognized_font_weights</code>, <code>ot_recognized_letter_spacing</code>, <code>ot_recognized_line_heights</code>, <code>ot_recognized_text_decorations</code> ' . __( 'and', 'theme-text-domain' ) . ' <code>ot_recognized_text_transformations</code>' ),\n 'std' => '',\n 'type' => 'typography',\n 'section' => 'option_body',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n\t array(\n 'id' => 'header_logo',\n 'label' => __( 'Logo Upload', 'theme-text-domain' ),\n 'desc' => sprintf( __('You Should logo height 25px and width 135px') ),\n 'std' => '',\n 'type' => 'upload',\n 'section' => 'header_section'\n ),\n\t array(\n 'id' => 'header_text_color',\n 'label' => __( 'Header Text Color', 'theme-text-domain' ),\n 'desc' => sprintf( __('Header Text color under Logo') ),\n 'std' => '',\n 'type' => 'colorpicker',\n 'section' => 'header_section'\n ),\n\t \n\t \n array(\n 'id' => 'footer_social_links',\n 'label' => __( 'Social Links', 'theme-text-domain' ),\n 'desc' => '<p>' . sprintf( __( 'The Social Links option type utilizes a drag & drop interface to create a list of social links.', 'theme-text-domain' ) ) . '</p>',\n 'std' => '',\n 'type' => 'social-links',\n 'section' => 'footer_section',\n 'rows' => '',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n\t \n array(\n 'id' => 'footer_copyright_text',\n 'label' => __( 'Footer Copyright Text', 'theme-text-domain' ),\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'footer_section'\n ),\n\t \n array(\n 'id' => 'fashion_javascript',\n 'label' => __( 'JavaScript', 'theme-text-domain' ),\n 'desc' => '<p>' . sprintf( __( 'The JavaScript option type is a textarea that uses the %s code editor to highlight your JavaScript and display errors as you type.', 'theme-text-domain' ), '<code>ace.js</code>' ) . '</p>',\n 'std' => '',\n 'type' => 'javascript',\n 'section' => 'footer_section',\n 'rows' => '20',\n 'post_type' => '',\n 'taxonomy' => '',\n 'min_max_step'=> '',\n 'class' => '',\n 'condition' => '',\n 'operator' => 'and'\n ),\n\t array(\n 'id' => 'contact_email',\n 'label' => __( 'Contact Email', 'theme-text-domain' ),\n 'desc' =>__( 'Contact Email for Contact page' ),\n 'std' => '',\n 'type' => 'text',\n 'section' => 'contact_info'\n ),\n\t array(\n 'id' => 'contact_address',\n 'label' => __( 'Contact Address', 'theme-text-domain' ),\n 'desc' =>__( 'Contact Address for Contact page' ),\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'contact_info'\n ),\n\t array(\n 'id' => 'contact_phone',\n 'label' => __( 'Contact Phone', 'theme-text-domain' ),\n 'desc' =>__( 'Contact Phone for Contact page' ),\n 'std' => '',\n 'type' => 'text',\n 'section' => 'contact_info'\n ),\n\t \n\t array(\n 'id' => 'contact_googlemap',\n 'label' => __( 'Google Map', 'theme-text-domain' ),\n 'desc' =>__( 'please give iframe of google for your address. Go to https://www.google.com/maps/ and find the required location using the search tool in the top left corner. go Setting-> Share or Embed -> Open ‘Embed Map’ tab and copy the code and past this text area' ),\n 'std' => '',\n 'type' => 'textarea',\n 'section' => 'contact_info'\n ),\n\t \n\t array(\n 'id' => 'contact_title',\n 'label' => __( 'Contact body Title', 'theme-text-domain' ),\n 'desc' =>__( 'Contact body Title for Contact page' ),\n 'std' => '',\n 'type' => 'text',\n 'section' => 'contact_info'\n ),\n\t array(\n 'id' => 'contact_subtitle',\n 'label' => __( 'Contact Body Subtitle', 'theme-text-domain' ),\n 'desc' =>__( 'Contact Body Subtitle for Contact page' ),\n 'std' => '',\n 'type' => 'text',\n 'section' => 'contact_info'\n ),\n )\n\t\n );\n \n /* allow settings to be filtered before saving */\n $custom_settings = apply_filters( ot_settings_id() . '_args', $custom_settings );\n \n /* settings are not the same update the DB */\n if ( $saved_settings !== $custom_settings ) {\n update_option( ot_settings_id(), $custom_settings ); \n }\n \n /* Lets OptionTree know the UI Builder is being overridden */\n global $ot_has_custom_theme_options;\n $ot_has_custom_theme_options = true;\n \n}", "function tsc_theme_options() {\n\tadd_theme_page( 'Theme Options', 'Theme Options', 'edit_theme_options', 'theme_options', 'tsc_theme_options_page' );\n}", "public function options_update() {\n\t\tregister_setting( $this->plugin_name, $this->plugin_name, array($this, 'validate', 'default' => array( \"url_nerd_instance\" => \"\", \"category_weight\" => \"0.04\", \"entity_weight\" => \"0.7\" ) ) );\n\t}", "function nxt_posts_p_add_options(){\n\n\tadd_option( 'nxt_post_option_template_select', 'themes/theme_1.php');\n\tadd_option( 'nxt_post_plugin_enable');\n}", "function lgmac_save_options() {\n\n//var_dump($_POST); die();\n\tif(!current_user_can('publish_pages')) {\n\t\twp_die('Vous n\\'êtes pas autorisé à effectuer cette opération');\n\t}\n\n\tcheck_admin_referer('lgmac_options_verify');\n\n\t$opts = get_option('lgmac_opts');\n\n\t//sauvegarde légende\n\t$opts['legend_01'] = sanitize_text_field($_POST['lgmac_legend_01']);\n\n\t//sauvegarde image\n\t$opts['image_01_url'] = sanitize_text_field($_POST['lgmac_image_url_01']);\n\n\t//valeur de legende dans la bdd\n\tupdate_option('lgmac_opts', $opts);\n\n\t// redirection vers la page des options avec l'url de la page\n\twp_redirect(admin_url('admin.php?page=lgmac_theme_opts&status=1'));\n\texit;\n\n}", "function product_customization_options_callback() {\r\n\t//update_option( 'grade_b_patterns', '' );\r\n\t//update_option( 'grade_c_patterns', '' );\r\n?>\r\n <div class=\"wrap\">\r\n \t<h2><?php echo __('Product Customization Options'); ?></h2>\r\n\t\t<script type='text/javascript'>\r\n jQuery(document).ready(function(){\r\n\t\t\t\tvar site_url = jQuery(\"#wp-admin-bar-view-site > a\").attr(\"href\");\r\n jQuery(\".pattern-item .delete\").click(function( event ){\r\n //event.preventDefault();\r\n\t\t\t\t\tvar pattern = jQuery(this).parent().attr(\"data-pattern\");\r\n\t\t\t\t\twindow.location = site_url+\"wp-admin/edit.php?post_type=product&page=product-customization&del_patt=\"+pattern;\r\n });\r\n jQuery(\".foam-item .delete\").click(function( event ){\r\n //event.preventDefault();\r\n\t\t\t\t\tvar foam = jQuery(this).parent().attr(\"data-foam\");\r\n\t\t\t\t\twindow.location = site_url+\"wp-admin/edit.php?post_type=product&page=product-customization&del_foam=\"+foam;\r\n });\r\n jQuery(\".grade-item .delete\").click(function( event ){\r\n //event.preventDefault();\r\n\t\t\t\t\tvar grade = jQuery(this).parent().attr(\"data-grade\");\r\n\t\t\t\t\twindow.location = site_url+\"wp-admin/edit.php?post_type=product&page=product-customization&del_grade=\"+grade;\r\n });\r\n jQuery(\".grade-item .edit\").click(function( event ){\r\n //event.preventDefault();\r\n\t\t\t\t\tvar grade = jQuery(this).parent().attr(\"data-grade\");\r\n\t\t\t\t\twindow.location = site_url+\"wp-admin/edit.php?post_type=product&page=product-customization&edit_grade=\"+grade;\r\n });\r\n jQuery(\".foam-item .edit\").click(function( event ){\r\n //event.preventDefault();\r\n\t\t\t\t\tvar foam = jQuery(this).parent().attr(\"data-foam\");\r\n\t\t\t\t\twindow.location = site_url+\"wp-admin/edit.php?post_type=product&page=product-customization&edit_foam=\"+foam;\r\n });\r\n\t\t\t});\r\n\t\t</script>\r\n <?php\r\n\t\t\tif(isset($_GET['del_patt'])) {\r\n\t\t\t\t$pattern = $_GET['del_patt'];\r\n\t\t\t\t//echo $pattern;\r\n\t\t\t\t$caluco_patterns = explode(\",\", get_option('caluco_pattern'));\r\n\t\t\t\t$index = array_search($pattern, $caluco_patterns);\r\n\t\t\t\tunset($caluco_patterns[$index]);\r\n\t\t\t\tupdate_option( 'caluco_pattern', implode(\",\", $caluco_patterns) );\r\n\r\n\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n\t\t\t\tforeach($grade_of_fabrics as $grade_of_fabric) {\r\n\r\n\t\t\t\t\t$option_name = strtolower(str_replace(\" \", \"_\", $grade_of_fabric)).\"_patterns\";\r\n\t\t\t\t\t\r\n\t\t\t\t\tif(get_option($option_name)) {\r\n\t\t\t\t\t\t$fabric_patterns_grade = explode(\",\", get_option($option_name));\r\n\t\t\t\t\t\tif(in_array($pattern, $fabric_patterns_grade)) {\r\n\t\t\t\t\t\t\t$index = array_search($pattern, $fabric_patterns_grade);\r\n\t\t\t\t\t\t\tunset($fabric_patterns_grade[$index]);\r\n\t\t\t\t\t\t\tupdate_option( $option_name, implode(\",\", $fabric_patterns_grade) );\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\techo \"<div class='updated'><p>Successfully Removed</p></div>\";\r\n\t\t\t}\r\n\t\t\tif(isset($_GET['unassign_pattern'])) {\r\n\t\t\t\t$pattern = $_GET['unassign_pattern'];\r\n\t\t\t\t$option_name = $_GET['option_name'];\r\n\r\n\t\t\t\tif(get_option($option_name)) {\r\n\t\t\t\t\t$fabric_patterns_grade = explode(\",\", get_option($option_name));\r\n\t\t\t\t\tif(in_array($pattern, $fabric_patterns_grade)) {\r\n\t\t\t\t\t\t$index = array_search($pattern, $fabric_patterns_grade);\r\n\t\t\t\t\t\tunset($fabric_patterns_grade[$index]);\r\n\t\t\t\t\t\tupdate_option( $option_name, implode(\",\", $fabric_patterns_grade) );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\techo \"<div class='updated'><p>Successfully Removed</p></div>\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif(isset($_GET['del_foam'])) {\r\n\t\t\t\t$foam = $_GET['del_foam'];\r\n\t\t\t\t//echo $foam;\r\n\t\t\t\t$caluco_foams = explode(\",\", get_option('caluco_foam'));\r\n\t\t\t\t$index = array_search($foam, $caluco_foams);\r\n\t\t\t\tunset($caluco_foams[$index]);\r\n\t\t\t\tupdate_option( 'caluco_foam', implode(\",\", $caluco_foams) );\r\n\t\t\t\techo \"<div class='updated'><p>Successfully Removed</p></div>\";\r\n\t\t\t}\r\n\r\n\t\t\tif(isset($_GET['del_grade'])) {\r\n\t\t\t\t$grade = $_GET['del_grade'];\r\n\t\t\t\t//echo $grade;\r\n\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n\t\t\t\t$index = array_search($grade, $grade_of_fabrics);\r\n\t\t\t\tunset($grade_of_fabrics[$index]);\r\n\t\t\t\tupdate_option( 'grade_of_fabric', implode(\",\", $grade_of_fabrics) );\r\n\t\t\t\techo \"<div class='updated'><p>Successfully Removed</p></div>\";\r\n\t\t\t}\r\n\t\t?>\r\n\t\t<?php\r\n if(isset($_POST['pc_options_submit'])){\r\n\t\t\t\tif(get_option('grade_of_fabric') != \"\") {\r\n \tupdate_option( 'grade_of_fabric', get_option('grade_of_fabric').','.$_POST['grade_of_fabric'] );\r\n\t\t\t\t} else {\r\n \tupdate_option( 'grade_of_fabric', $_POST['grade_of_fabric'] );\r\n\t\t\t\t}\r\n \r\n echo \"<div class='updated'><p>Successfully Saved</p></div>\";\r\n }\r\n ?>\r\n\t\t<?php\r\n if(isset($_POST['pc_grade_price_submit'])) {\r\n\t\t\t\t$grade_name = $_POST['edited_grade_name'];\r\n\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n if(in_array($grade_name, $grade_of_fabrics)) {\r\n $index = array_search($grade_name, $grade_of_fabrics);\r\n\t\t\t\t\t$grade_arr = explode(\"$\", $grade_of_fabrics[$index]);\r\n\t\t\t\t\t$grade_label = trim($grade_arr[0]);\r\n\t\t\t\t\t$new_grade_price = $grade_label.' $'.$_POST['edit_grade_price'];\r\n\t\t\t\t\t\r\n\t\t\t\t\t$grade_of_fabrics[$index] = $new_grade_price;\r\n\t\t\t\t\tupdate_option( 'grade_of_fabric', implode(\",\", $grade_of_fabrics) );\r\n\t\t\t\t\techo \"<div class='updated'><p>Successfully Updated</p></div>\";\r\n\t\t\t\t}\r\n\t\t\t}\r\n if(isset($_GET['edit_grade'])) {\r\n $grade = $_GET['edit_grade'];\r\n //echo $grade;\r\n\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n if(in_array($grade, $grade_of_fabrics)) {\r\n $arr_index = array_search($grade, $grade_of_fabrics);\r\n\t\t\t\t\t$grade_price = explode(\"$\", $grade_of_fabrics[$arr_index]);\r\n ?>\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Edit Price'); ?>\r\n </th>\r\n <td>\r\n \t<form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n \t<input type=\"text\" name=\"edit_grade_price\" value=\"<?php echo trim($grade_price[1]); ?>\" style=\"border:1px solid #0C6;\" /> \r\n <input type=\"hidden\" name=\"edited_grade_name\" value=\"<?php echo $grade_of_fabrics[$arr_index]; ?>\" />\r\n <input type=\"submit\" name=\"pc_grade_price_submit\" class=\"button-primary\" value=\"<?php _e('Update') ?>\" />\r\n </form>\r\n </td>\r\n </tr>\r\n </table>\r\n <?php\r\n }\r\n }\r\n if(isset($_POST['pc_foam_price_submit'])) {\r\n\t\t\t\t$foam_name = $_POST['edited_foam_name'];\r\n\t\t\t\t$caluco_foams = explode(\",\", get_option('caluco_foam'));\r\n if(in_array($foam_name, $caluco_foams)) {\r\n $index = array_search($foam_name, $caluco_foams);\r\n\t\t\t\t\t$foam_arr = explode(\"$\", $caluco_foams[$index]);\r\n\t\t\t\t\t$foam_label = trim($foam_arr[0]);\r\n\t\t\t\t\t$new_foam_price = $foam_label.' $'.$_POST['edit_foam_price'];\r\n\t\t\t\t\t\r\n\t\t\t\t\t$caluco_foams[$index] = $new_foam_price;\r\n\t\t\t\t\tupdate_option( 'caluco_foam', implode(\",\", $caluco_foams) );\r\n\t\t\t\t\techo \"<div class='updated'><p>Successfully Updated</p></div>\";\r\n\t\t\t\t}\r\n\t\t\t}\r\n if(isset($_GET['edit_foam'])) {\r\n $foam = $_GET['edit_foam'];\r\n //echo $foam;\r\n\t\t\t\t$caluco_foams = explode(\",\", get_option('caluco_foam'));\r\n if(in_array($foam, $caluco_foams)) {\r\n $arr_index = array_search($foam, $caluco_foams);\r\n\t\t\t\t\t$foam_price = explode(\"$\", $caluco_foams[$arr_index]);\r\n ?>\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Edit Foam Price'); ?>\r\n </th>\r\n <td>\r\n \t<form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n \t<input type=\"text\" name=\"edit_foam_price\" value=\"<?php echo trim($foam_price[1]); ?>\" style=\"border:1px solid #0C6;\" /> \r\n <input type=\"hidden\" name=\"edited_foam_name\" value=\"<?php echo $caluco_foams[$arr_index]; ?>\" />\r\n <input type=\"submit\" name=\"pc_foam_price_submit\" class=\"button-primary\" value=\"<?php _e('Update') ?>\" />\r\n </form>\r\n </td>\r\n </tr>\r\n </table>\r\n <?php\r\n }\r\n }\r\n ?>\r\n <form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Grade of Fabric List'); ?>\r\n </th>\r\n <td>\r\n \t<!--<select name=\"fabric_grade_list\" id=\"fabric_grade_list\">-->\r\n \t<?php\r\n\t\t\t\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n\t\t\t\t\t\t\tforeach($grade_of_fabrics as $grade_of_fabric) {\r\n\t\t\t\t\t\t\t\t$dollar_exist = substr(trim($grade_of_fabric), -1);\r\n\t\t\t\t\t\t\t\t// if last character is $ no need to show it\r\n\t\t\t\t\t\t\t\tif($dollar_exist == '$') {\r\n\t\t\t\t\t\t\t\t\t$grade_of_fabric = trim($grade_of_fabric, '$');\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t\t//echo '<option value=\"'.$grade_of_fabric.'\">'.$grade_of_fabric.'</option>';\r\n\t\t\t\t\t\t\t\techo '<span class=\"grade-item\" data-grade=\"'.$grade_of_fabric.'\">'.$grade_of_fabric.' <strong class=\"delete\">x</strong></span>';/* <strong class=\"edit\" title=\"Edit\">+</strong> */\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t?>\r\n <!--</select>-->\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Grade of Fabric'); ?>\r\n </th>\r\n <td>\r\n <input type=\"text\" name=\"grade_of_fabric\" size=\"40\" />\r\n <br />\r\n <small style=\"color:#777777;\">Ex: Grade A <!--$50 || 30--></small>\r\n <!--<br />\r\n <small style=\"color:#999999;\">For the example above, \"50\" is Regular price and \"30\" is Wholesale price</small>-->\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">&nbsp;</th>\r\n <td>\r\n <input type=\"submit\" name=\"pc_options_submit\" class=\"button-primary\" value=\"<?php _e('Add Grade') ?>\" />\r\n </td>\r\n </tr>\r\n </table>\r\n </form>\r\n <hr />\r\n\t\t<?php\r\n if(isset($_POST['pc_pattern_submit'])){\r\n\t\t\t\tif(get_option('caluco_pattern') != \"\") {\r\n \tupdate_option( 'caluco_pattern', get_option('caluco_pattern').','.$_POST['caluco_pattern'] );\r\n\t\t\t\t} else {\r\n \tupdate_option( 'caluco_pattern', $_POST['caluco_pattern'] );\r\n\t\t\t\t}\r\n \r\n echo \"<div class='updated'><p>Successfully Saved</p></div>\";\r\n }\r\n ?>\r\n <style type=\"text/css\">\r\n\t\t\t.pattern-item, .foam-item, .grade-item { background: #e6e6e6; display: inline-block; margin-right: 3px; padding: 3px 5px; }\r\n\t\t\t.pattern-item > strong, .foam-item > strong, .grade-item > strong { color: red; cursor: pointer; }\r\n\t\t\t.grade-item > strong.edit, .foam-item > strong.edit { color: green; font-size: 16px; font-weight: 700; }\r\n\t\t\t.assigned-pattern a { color: red; font-weight: 700; text-decoration: none; }\r\n\t\t</style>\r\n <form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Patterns'); ?>\r\n </th>\r\n <td>\r\n \t<!--<select name=\"pattern_list\" id=\"pattern_list\">-->\r\n \t<?php\r\n\t\t\t\t\t\t\t$caluco_patterns = explode(\",\", get_option('caluco_pattern'));\r\n\t\t\t\t\t\t\tsort($caluco_patterns);\r\n\t\t\t\t\t\t\tforeach($caluco_patterns as $pattern) {\r\n\t\t\t\t\t\t\t\t//echo '<option value=\"'.$pattern.'\">'.$pattern.'</option>';\r\n\t\t\t\t\t\t\t\techo '<span class=\"pattern-item\" data-pattern=\"'.$pattern.'\">'.$pattern.' <strong class=\"delete\">x</strong></span>';\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t?>\r\n <!--</select>-->\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Pattern'); ?>\r\n </th>\r\n <td>\r\n <input type=\"text\" name=\"caluco_pattern\" size=\"40\" />\r\n <br />\r\n <small style=\"color:#777777;\">Ex: Astoria Lagoon</small>\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">&nbsp;</th>\r\n <td>\r\n <input type=\"submit\" name=\"pc_pattern_submit\" class=\"button-primary\" value=\"<?php _e('Add Pattern') ?>\" />\r\n </td>\r\n </tr>\r\n </table>\r\n </form>\r\n <hr />\r\n <hr />\r\n\t\t<?php\r\n if(isset($_POST['pc_pattern_grade_submit'])){\r\n\t\t\t\t$fabric_grade = $_POST['fabric_grade_list'];\r\n\t\t\t\t$option_name = strtolower(str_replace(\" \", \"_\", $fabric_grade)).\"_patterns\";\r\n\t\t\t\t$pattern = $_POST['pattern_list'];\r\n\t\t\t\t\r\n\t\t\t\tif(get_option($option_name)) {\r\n\t\t\t\t\t$fabric_patterns_grade = explode(\",\", get_option($option_name));\r\n\t\t\t\t\tif(in_array($pattern, $fabric_patterns_grade)) {\r\n\t\t\t\t\t\t// do nothing\r\n\t\t\t\t\t} else {\r\n \t\tupdate_option( $option_name, get_option($option_name).','.$pattern );\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\tupdate_option( $option_name, $pattern );\r\n\t\t\t\t}\r\n\t\t\t\t\r\n echo \"<div class='updated'><p>Successfully Saved</p></div>\";\r\n }\r\n ?>\r\n <form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Assign Pattern / Grade'); ?>\r\n </th>\r\n <td>\r\n \t<select name=\"fabric_grade_list\" id=\"fabric_grade_list\">\r\n \t<?php\r\n\t\t\t\t\t\t\t$grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n\t\t\t\t\t\t\tforeach($grade_of_fabrics as $grade_of_fabric) {\r\n\t\t\t\t\t\t\t\t$grade_price = explode(\"$\", $grade_of_fabric);\r\n\t\t\t\t\t\t\t\techo '<option value=\"'.trim($grade_price[0]).'\">'.trim($grade_price[0]).'</option>';\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t?>\r\n </select>\r\n </td>\r\n <td>\r\n \t<select name=\"pattern_list\" id=\"pattern_list\">\r\n \t<?php\r\n\t\t\t\t\t\t\t$caluco_patterns = explode(\",\", get_option('caluco_pattern'));\r\n\t\t\t\t\t\t\tsort($caluco_patterns);\r\n\t\t\t\t\t\t\tforeach($caluco_patterns as $pattern) {\r\n\t\t\t\t\t\t\t\techo '<option value=\"'.$pattern.'\">'.$pattern.'</option>';\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t?>\r\n </select>\r\n <br />\r\n <small style=\"color:#777777;\">Pattern</small>\r\n </td>\r\n <td>\r\n <input type=\"submit\" name=\"pc_pattern_grade_submit\" class=\"button-primary\" value=\"<?php _e('Submit') ?>\" />\r\n </td>\r\n </tr>\r\n </table>\r\n </form>\r\n <hr />\r\n <hr />\r\n <table class=\"form-table\">\r\n \t<tr valign=\"top\">\r\n\t\t\t\t<?php\r\n $grade_of_fabrics = explode(\",\", get_option('grade_of_fabric'));\r\n\t\t\t\t\tsort($grade_of_fabrics);\r\n foreach($grade_of_fabrics as $grade_of_fabric) {\r\n\t\t\t\t\t\techo '<td>';\r\n $grade_price = explode(\"$\", $grade_of_fabric);\r\n\t\t\t\t\t\techo '<h3 style=\"margin-top: 0; margin-bottom: 10px;\">'.trim($grade_price[0]).' Patterns</h3>';\r\n\r\n\t\t\t\t\t\t$option_name = strtolower(str_replace(\" \", \"_\", trim($grade_price[0]))).\"_patterns\";\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif(get_option($option_name)) {\r\n\t\t\t\t\t\t\t$fabric_patterns_grade = explode(\",\", get_option($option_name));\r\n\t\t\t\t\t\t\tsort($fabric_patterns_grade);\r\n\t\t\t\t\t\t\tforeach($fabric_patterns_grade as $pattern) {\r\n\t\t\t\t\t\t\t\techo '<span class=\"assigned-pattern\">'.$pattern.' <a class=\"delete\" href=\"'.admin_url('/edit.php?post_type=product&page=product-customization&unassign_pattern='.$pattern.'&option_name='.$option_name).'\">x</a></span><br>';\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\techo '</td>';\r\n }\r\n ?>\r\n </tr>\r\n </table>\r\n <hr />\r\n\t\t<?php\r\n if(isset($_POST['pc_foam_submit'])){\r\n\t\t\t\tif(get_option('caluco_foam') != \"\") {\r\n \tupdate_option( 'caluco_foam', get_option('caluco_foam').','.$_POST['caluco_foam'] );\r\n\t\t\t\t} else {\r\n \tupdate_option( 'caluco_foam', $_POST['caluco_foam'] );\r\n\t\t\t\t}\r\n \r\n echo \"<div class='updated'><p>Successfully Saved</p></div>\";\r\n }\r\n ?>\r\n <form action=\"<?php echo admin_url('/edit.php?post_type=product&page=product-customization'); ?>\" method=\"post\">\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Foams'); ?>\r\n </th>\r\n <td>\r\n \t<!--<select name=\"foam_list\" id=\"foam_list\">-->\r\n \t<?php\r\n\t\t\t\t\t\t\t$caluco_foams = explode(\",\", get_option('caluco_foam'));\r\n\t\t\t\t\t\t\tforeach($caluco_foams as $foam) {\r\n\t\t\t\t\t\t\t\t//echo '<option value=\"'.$foam.'\">'.$foam.'</option>';\r\n\t\t\t\t\t\t\t\techo '<span class=\"foam-item\" data-foam=\"'.$foam.'\"><strong class=\"edit\" title=\"Edit\">+</strong> '.$foam.' <strong class=\"delete\">x</strong></span>';\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t?>\r\n <!--</select>-->\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">\r\n <?php echo __('Foam'); ?>\r\n </th>\r\n <td>\r\n <input type=\"text\" name=\"caluco_foam\" size=\"40\" />\r\n <br />\r\n <small style=\"color:#777777;\">Ex: Dry Fast Foam $100 || 70</small>\r\n <br />\r\n <small style=\"color:#999999;\">For the example above, \"100\" is Regular price and \"70\" is Wholesale price</small>\r\n </td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\">&nbsp;</th>\r\n <td>\r\n <input type=\"submit\" name=\"pc_foam_submit\" class=\"button-primary\" value=\"<?php _e('Add Foam') ?>\" />\r\n </td>\r\n </tr>\r\n </table>\r\n </form>\r\n </div>\r\n<?php\r\n}", "function wpmantis_update_options()\n{\n\t$options = get_option('wp_mantis_options');\n\n\t$options['mantis_user'] = $_REQUEST['mantis_user'];\n\t$options['mantis_password'] = $_REQUEST['mantis_password'];\n\t$options['mantis_soap_url'] = $_REQUEST['mantis_soap_url'];\n\t$options['mantis_base_url'] = $_REQUEST['mantis_base_url'];\n\t$options['mantis_max_desc_lenght'] = $_REQUEST['mantis_max_desc_lenght'];\n\t$options['mantis_enable_pagination'] = isset($_REQUEST['mantis_enable_pagination']);\n\t$options['mantis_bugs_per_page'] = $_REQUEST['mantis_bugs_per_page'];\n\t$options['mantis_colors'] = $_REQUEST['color'];\n\t\n\t//Check to see that the base URL ends with a trailing slash if not, add it\n\tif (substr($options['mantis_base_url'], -1, 1) != '/') { $options['mantis_base_url'] .= '/'; }\n\n\tupdate_option('wp_mantis_options', $options);\n\n\t?>\n\t<div id=\"message\" class=\"updated fade\">\n\t<p><?php _e('Options saved.', 'wp-mantis'); ?></p>\n\t</div>\n\t<?php\n}", "function pu_theme_menu()\n{\n add_theme_page( 'Theme Option', 'Edycja danych motywu', 'manage_options', 'pu_theme_options.php', 'pu_theme_page'); \n}", "function CustomPostOrder_updateOptions(){\n $settings = CustomPostOrder_settings();\n $settings_keys = array_keys ( $settings );\n if ( !get_option ( 'CustomPostOrder-settings' ) ) {\n //add the settings to options\n add_option ( 'CustomPostOrder-settings', $settings );\n }\n else\n $settings = get_option ( 'CustomPostOrder-settings' );\n \n $input = $settings;\n \n \n foreach ( $_POST as $key => $value ) {\n $input[$key] = $settings[$key];\n }\n if ( $_POST['orderElement'] || $_POST['orderType'] || $_POST['applyTo'] || $_POST['applyArray']) {\n $input['orderElement'] = $_POST['orderElement'];\n $input['orderType'] = $_POST['orderType'];\n $input['applyTo'] = $_POST['applyTo'];\n $input['applyArray'] = $_POST['applyArray'];\n update_option ( 'CustomPostOrder-settings', $input );\n }\n return $input;\n}", "function gssettings_theme_options() {\n global $_gssettings_settings_pagehook;\n $_gssettings_settings_pagehook = add_submenu_page( 'genesis', 'Sandbox Settings', 'Sandbox Settings', 'edit_theme_options', GSSETTINGS_SETTINGS_FIELD, 'gssettings_theme_options_page' );\n \n //add_action( 'load-'.$_gssettings_settings_pagehook, 'gssettings_settings_styles' );\n add_action( 'load-'.$_gssettings_settings_pagehook, 'gssettings_settings_scripts' );\n add_action( 'load-'.$_gssettings_settings_pagehook, 'gssettings_settings_boxes' );\n }", "function pu_theme_menu()\n{\n add_theme_page('Theme Option', 'Theme Options', 'manage_options', 'pu_theme_options.php', 'pu_theme_page');\n}", "function admin_menu_link() {\n //If you change this from add_options_page, MAKE SURE you change the filter_plugin_actions function (below) to\n //reflect the page filename (ie - options-general.php) of the page your plugin is under!\n add_options_page('HITS- IE6 PNG Fix', 'HITS- IE6 PNG Fix', 'edit_pages', basename(__FILE__), array(&$this,'admin_options_page'));\n add_filter( 'plugin_action_links_' . plugin_basename(__FILE__), array(&$this, 'filter_plugin_actions'), 10, 2 );\n }", "function theme_options($param) {\n if(get_option('amc_theme_options')){\n $amc_theme_options=get_option('amc_theme_options');\n }\n else{\n add_option('amc_theme_options',array(\n 'social'=>array(\n 'facebook_url'=>'',\n 'twitter_url'=>'',\n 'googleplus_url'=>'',\n 'pinterest_url'=>'',\n 'linkedin_url'=>''\n ),\n 'contact'=>array(\n 'freephone'=>'',\n 'telephone'=>'',\n 'email'=>'',\n 'fax'=>'',\n 'company_address'=>''\n ),\n 'pages'=>array(\n 'home'=>array(\n 'latest-projects'=>'',\n ),\n 'about'=>array(\n ),\n 'services'=>array(\n ),\n 'projects'=>array(\n ),\n 'contacts'=>array(\n ),\n ), \n 'theme_layout'=>'',\n 'logo'=>'',\n 'background_image'=>'',\n 'top_slider_id'=>'',\n 'map_iframe'=>'',\n 'footer_text'=>''\n ));\n $amc_theme_options=get_option('amc_theme_options');\n \n }\n if(isset($_POST['submit'])){\n $uploads_dir = get_stylesheet_directory().'/images';\n foreach($_FILES as $key=>$file){\n \n if($file['name']==''){\n $_FILES[$key]['name']=get_option('amc_theme_options')[$key];\n }\n else {\n \n }\n\n\n $tmp_name = $_FILES[$key][\"tmp_name\"];\n $name = $_FILES[$key]['name'];\n move_uploaded_file($tmp_name, $uploads_dir.'/'.$name);\n\n }\n if(isset($_POST['layout'])){\n $layout='default';\n }\n $updated_options=array(\n 'social'=>array(\n 'facebook_url'=>$_POST['facebook_url'],\n 'twitter_url'=>$_POST['twitter_url'],\n 'googleplus_url'=>$_POST['googleplus_url'],\n 'pinterest_url'=>$_POST['pinterest_url'],\n 'linkedin_url'=>$_POST['linkedin_url'],\n ),\n 'contact'=>array(\n 'freephone'=>$_POST['freephone'],\n 'telephone'=>$_POST['telephone'],\n 'email'=>$_POST['email'],\n 'fax'=>$_POST['fax'],\n 'company_address'=>$_POST['company_address']\n ),\n 'pages'=>array(\n 'home'=>array(\n 'latest-projects'=>$_POST['latest-projects'],\n ),\n ), \n 'theme_layout'=>$layout,\n 'logo'=>$_FILES['logo']['name'],\n 'background'=>$_FILES['background']['name'],\n 'top_slider_id'=>$_POST['top_slider'],\n 'map_iframe'=>$_POST['map_iframe'],\n 'footer_text'=>$_POST['footer_text']\n \n );\n update_option('amc_theme_options',$updated_options);\n $amc_theme_options=$updated_options;\n }\n \n \n?>\n<div class=\"wrap theme_options_panel\">\n <div class=\"\">\n <h2>Theme Options</h2>\n <form action=\"themes.php?page=themeoptions\" method=\"post\" enctype=\"multipart/form-data\">\n <div class=\"aside \" id=\"tabs\">\n <ul class=\"menu aside_body \">\n <li>\n <a href=\"#general\">General</a>\n </li>\n <li>\n <a href=\"#social\">Social</a>\n </li>\n <li class=\"\">\n <a href=\"#pages\">Pages</a>\n </li>\n <li>\n <a href=\"#customcssjs\">Custom CSS/JS</a>\n </li>\n <li>\n <a href=\"#contact\">Contact Us</a>\n </li>\n </ul>\n \n <div id=\"general\" class=\"main\">\n <h2>General</h2>\n <table class=\"form-table\">\n <tr>\n <td>\n <label for=\"layout\">Website Layout</label>\n </td>\n <td>\n <input type=\"checkbox\" name=\"layout\" id=\"layout\" value=\"default\" <?php if(isset($_POST['layout'])) echo 'checked=\"checked\"'; ?> />\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"logo\">Website Logo</label>\n </td>\n <td>\n <input type=\"file\" name=\"logo\" id=\"logo\">\n <?php if(get_option('amc_theme_options')['logo']):?>\n <img id=\"background_image\" class=\"theme_img\" src=\"<?php bloginfo('template_directory') ?>/img/<?php echo get_option('amc_theme_options')['logo']; ?>\">\n <?php endif;?>\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"background\">Background Image</label>\n </td>\n <td>\n <input type=\"file\" name=\"background\" id=\"background\">\n <?php if(get_option('amc_theme_options')['background']):?>\n <img id=\"background_image\" class=\"theme_img\" src=\"<?php bloginfo('template_directory') ?>/img/<?php echo get_option('amc_theme_options')['background']; ?>\">\n <?php endif;?>\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"top_slider\">Top Slider</label>\n </td>\n <td>\n <select name=\"top_slider\" >\n <?php $sliders=new WP_Query(array(\n 'post_type'=>'slider'\n ));\n while($sliders->have_posts()){\n $sliders->the_post();\n if($amc_theme_options['top_slider_id']==get_the_ID()){ \n $selected='selected';\n\n }\n else {\n $selected='';\n\n }\n echo '<option value=\"'.get_the_ID().'\" '.$selected.'>'.get_the_title().'</option>';\n }\n ?>\n </select>\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"map_iframe\">Map Iframe Source</label>\n </td>\n <td>\n <input type=\"text\" name=\"map_iframe\" id=\"map_iframe\" value=\"<?php echo $amc_theme_options['map_iframe']; ?>\">\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"footer_text\">Footer Text</label>\n </td>\n <td>\n <input type=\"text\" name=\"footer_text\" id=\"footer_text\" value=\"<?php echo $amc_theme_options['footer_text']; ?>\">\n </td>\n </tr>\n </table>\n </div>\n \n <div class=\"main\" id=\"social\">\n <h2>Social</h2>\n <table class=\"form-table\">\n <tr>\n <td>\n <label for=\"facebook_url\">Facebook URL</label>\n </td>\n <td>\n <input type=\"text\" name=\"facebook_url\" id=\"facebook_url\" value=\"<?php echo $amc_theme_options['social']['facebook_url']; ?>\">\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"twitter_url\">Twitter URL</label>\n </td>\n <td>\n <input type=\"text\" name=\"twitter_url\" id=\"twitter_url\" value=\"<?php echo $amc_theme_options['social']['twitter_url']; ?>\">\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"pinterest_url\">Pinterest URL</label>\n </td>\n <td>\n <input type=\"text\" name=\"pinterest_url\" id=\"pinterest_url\" value=\"<?php echo $amc_theme_options['social']['pinterest_url']; ?>\">\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"googleplus_url\">Google Plus URL</label>\n </td>\n <td>\n <input type=\"text\" name=\"googleplus_url\" id=\"googleplus_url\" value=\"<?php echo $amc_theme_options['social']['googleplus_url']; ?>\">\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"linkedin_url\">LinkedIn URL</label>\n </td>\n <td>\n <input type=\"text\" name=\"linkedin_url\" id=\"linkedin_url\" value=\"<?php echo $amc_theme_options['social']['linkedin_url']; ?>\">\n </td>\n </tr>\n </table>\n </div>\n \n <div class=\"main\" id=\"pages\">\n <h2>Pages</h2>\n \n <div id=\"accordion\">\n <h3>Home</h3>\n <div>\n <input type=\"text\" name=\"latest-projects\" id=\"latest-projects\" value=\"<?php echo $amc_theme_options['pages']['home']['latest-projects']; ?> \" placeholder=\"Latest Projects Text\">\n \n </div>\n \n <h3>About</h3>\n <div>\n \n </div>\n \n <h3>Services</h3>\n <div>\n \n </div>\n \n <h3>Projects</h3>\n <div>\n \n </div>\n \n <h3>Contacts</h3>\n <div>\n \n </div>\n\n \n </div>\n </div>\n \n <div class=\"main\" id=\"customcssjs\">\n <h2>Custom CSS/JS</h2>\n <table class=\"form-table\">\n <tr>\n <td>\n <label for=\"css_js\">CSS/JS</label>\n </td>\n <td>\n <textarea name=\"css_js\" id=\"css_js\"\"></textarea>\n </td>\n </tr>\n </table>\n </div>\n \n <div class=\"main\" id=\"contact\">\n <h2>Contact Us</h2>\n <table class=\"form-table\">\n <tr>\n <td>\n <label for=\"freephone\">Freephone:</label>\n </td>\n <td>\n <input type=\"text\" name=\"freephone\" id=\"freephone\" value=\"<?php echo $amc_theme_options['contact']['freephone']; ?>\">\n\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"telephone\">Telephone:</label>\n </td>\n <td>\n <input type=\"text\" name=\"telephone\" id=\"telephone\" value=\"<?php echo $amc_theme_options['contact']['telephone']; ?>\">\n\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"email\">Email:</label>\n </td>\n <td>\n <input type=\"email\" name=\"email\" id=\"email\" value=\"<?php echo $amc_theme_options['contact']['email']; ?>\">\n\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"fax\">Fax:</label>\n </td>\n <td>\n <input type=\"text\" name=\"fax\" id=\"fax\" value=\"<?php echo $amc_theme_options['contact']['fax']; ?>\">\n\n </td>\n </tr>\n <tr>\n <td>\n <label for=\"company_address\">Company Address:</label>\n </td>\n <td>\n <input type=\"text\" name=\"company_address\" id=\"company_address\" value=\"<?php echo $amc_theme_options['contact']['company_address']; ?>\">\n\n </td>\n </tr>\n </table>\n </div>\n\n </div>\n <div class=\"text-right submit-container\">\n <input type=\"submit\" name=\"submit\" value=\"Save Changes\"/>\n </div>\n </form>\n </div>\n \n</div>\n<?php\n \n \n \n}", "public function options_init() {\n\t\t\tglobal $allowedtags;\n\t\t\t$allowedtags['p'] = array();\n\t\t\t$this->allowedtags = $allowedtags;\n\n\t\t // set options equal to defaults\n\t\t $this->_options = get_option( $this->options_group[0]['options_name'] );\n\t\t if ( false === $this->_options ) {\n\t\t\t\t$this->_options = $this->get_defaults();\n\t\t }\n\t\t if ( isset( $_GET['undo'] ) && !isset( $_GET['settings-updated'] ) && is_array( $this->get_option('previous') ) ) {\n\t\t \t$this->_options = $this->get_option('previous');\n\t\t }\n\t\t update_option( $this->options_group[0]['options_name'], $this->_options );\t\t\n\t\t \n\t\t}", "function cp_update_options($options) {\r\n $toolsMessage = '';\r\n\r\n if (isset($_POST['submitted']) && $_POST['submitted'] == 'yes') {\r\n\r\n foreach ( $options as $value ) {\r\n if ( isset($_POST[$value['id']]) ) {\r\n //echo $value['id'] . '<-- value ID | ' . $_POST[$value['id']] . '<-- $_POST value ID <br/><br/>'; // FOR DEBUGGING\r\n update_option( $value['id'], appthemes_clean($_POST[$value['id']]) );\r\n } else {\r\n @delete_option( $value['id'] );\r\n }\r\n }\r\n\r\n // do a separate update for price per cats since it's not in the $options array\r\n if ( isset($_POST['catarray']) ) {\r\n foreach ( $_POST['catarray'] as $key => $value ) {\r\n // echo $key .'<-- key '. $value .'<-- value<br/>'; // FOR DEBUGGING\r\n update_option( $key, appthemes_clean($value) );\r\n }\r\n }\r\n\r\n // clean all values from the post and store them into a wordpress option as a serialized array of cat ID's\r\n if ( isset($_POST['catreqarray']) ) {\r\n foreach ( $_POST['catreqarray'] as $key => $value ) {\r\n $catreqarray[absint($value)] = '';\r\n }\r\n update_option('cp_required_categories', $catreqarray);\r\n } else if (isset($_POST['cp_required_membership_type'])){\r\n delete_option('cp_required_categories');\r\n }\r\n\r\n\t\t\tif ( get_option('cp_tools_run_expiredcheck') == 'yes' ) {\r\n\t\t\t\t\tupdate_option('cp_tools_run_expiredcheck', 'no');\r\n\t\t\t\t\tcp_check_expired_cron();\r\n\t\t\t\t\t$toolsMessage = '';\r\n\t\t\t\t\t$toolsMessage .= __('Ads Expired Check was executed.');\r\n\t\t\t}\r\n\r\n\t\t\t// flush out the cache so changes can be visible\r\n\t\t\tcp_flush_all_cache();\r\n\r\n echo '<div class=\"updated\"><p>'.__('Your settings have been saved.','appthemes'). ' ' . $toolsMessage . '</p></div>';\r\n\r\n } elseif ( isset($_POST['submitted']) && $_POST['submitted'] == 'convertToCustomPostType' ) {\r\n\t\tupdate_option('cp_tools_run_convertToCustomPostType', 'no');\r\n\t\t$toolsMessage .= cp_convert_posts2Ads();\r\n\t\techo $toolsMessage;\r\n\t}\r\n}", "function handleOptions ()\n\t{\n\t\t$default_options = $this->default_options;\n\n\t\t// Get options from WP options\n\t\t$options_from_table = get_option( $this->db_options_name_core );\n\n\t\tif ( empty( $options_from_table ) ) {\n\t\t\t$options_from_table = $this->default_options; // New installation\n\t\t} else {\n\n\t\t\t// As of version 2.2 I changed the way I store the default options.\n\t\t\t// I need to upgrade the options before setting the options but we don't update the version yet.\n\t\t\tif ( ! $options_from_table['general'] ) {\n\t\t\t\t$this->upgradeDefaultOptions_2_2();\n\t\t\t\t$options_from_table = get_option( $this->db_options_name_core ); // Get the new options\n\t\t\t}\n\n\t\t\t// Update default options by getting not empty values from options table\n\t\t\tforeach ( $default_options as $section_key => $section_array ) {\n\t\t\t\tforeach ( $section_array as $name => $value ) {\n\n\t\t\t\t\tif ( isset( $options_from_table[$section_key][$name] ) && (! is_null( $options_from_table[$section_key][$name] )) ) {\n\t\t\t\t\t\tif ( is_int( $value ) ) {\n\t\t\t\t\t\t\t$default_options[$section_key][$name] = ( int ) $options_from_table[$section_key][$name];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$default_options[$section_key][$name] = $options_from_table[$section_key][$name];\n\t\t\t\t\t\t\tif ( 'associated_id' == $name ) {\n\t\t\t\t\t\t\t\tif ( 'blogavirtualh-20' == $options_from_table[$section_key][$name] )\n\t\t\t\t\t\t\t\t\t$default_options[$section_key][$name] = 'avh-amazon-20';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// If a newer version is running do upgrades if neccesary and update the database.\n\t\t\tif ( $this->version > $options_from_table['general']['version'] ) {\n\t\t\t\t// Starting with version 2.1 I switched to a new way of storing the widget options in the database. We need to convert these.\n\t\t\t\tif ( $options_from_table['general']['version'] < '2.1' ) {\n\t\t\t\t\t$this->upgradeWidgetOptions_2_1();\n\t\t\t\t}\n\n\t\t\t\tif ( $options_from_table['general']['version'] < '2.4' ) {\n\t\t\t\t\t$this->doRemoveCacheFolder();\n\t\t\t\t}\n\t\t\t\tif ( $options_from_table['general']['version'] < '3.0' ) {\n\t\t\t\t\t$this->upgradeWidgetSettings_3_0();\n\t\t\t\t}\n\n\t\t\t\t// Write the new default options and the proper version to the database\n\t\t\t\t$default_options['general']['version'] = $this->version;\n\t\t\t\tupdate_option( $this->db_options_name_core, $default_options );\n\t\t\t}\n\t\t}\n\t\t// Set the class property for options\n\t\t$this->options = $default_options;\n\t}", "function wp_translate_options_page() {\r\n\r\n // variables for the field and option names \r\n $opt_name = 'mt_translate_main';\r\n\t$opt_name_4 = 'mt_translate_title';\r\n $opt_name_5 = 'mt_translate_plugin_support';\r\n $hidden_field_name = 'mt_translate_submit_hidden';\r\n $data_field_name = 'mt_translate_main';\r\n\t$data_field_name_4 = 'mt_translate_title';\r\n $data_field_name_5 = 'mt_translate_plugin_support';\r\n\r\n // Read in existing option value from database\r\n $opt_val = get_option( $opt_name );\r\n\t$opt_val_4 = get_option($opt_name_4);\r\n $opt_val_5 = get_option($opt_name_5);\r\n\r\n // See if the user has posted us some information\r\n // If they did, this hidden field will be set to 'Y'\r\n if( $_POST[ $hidden_field_name ] == 'Y' ) {\r\n // Read their posted value\r\n $opt_val = $_POST[ $data_field_name ];\r\n\t\t$opt_val_4 = $_POST[$data_field_name_4];\r\n $opt_val_5 = $_POST[$data_field_name_5];\r\n\r\n // Save the posted value in the database\r\n update_option( $opt_name, $opt_val );\r\n\t\tupdate_option( $opt_name_4, $opt_val_4 );\r\n update_option( $opt_name_5, $opt_val_5 );\r\n\r\n // Put an options updated message on the screen\r\n\r\n?>\r\n<div class=\"updated\"><p><strong><?php _e('Options saved.', 'mt_trans_domain' ); ?></strong></p></div>\r\n<?php\r\n\r\n }\r\n\r\n // Now display the options editing screen\r\n\r\n echo '<div class=\"wrap\">';\r\n\r\n // header\r\n\r\n echo \"<h2>\" . __( 'WP Translate Plugin Settings', 'mt_trans_domain' ) . \"</h2>\";\r\n\n // options form\r\n \r\n\r\n $change1 = get_option(\"mt_translate_plugin_support\");\r\n\r\nif ($change1==\"Yes\" || $change1==\"\") {\r\n$change1=\"checked\";\r\n$change11=\"\";\r\n} else {\r\n$change1=\"\";\r\n$change11=\"checked\";\r\n}\r\n\r\n ?>\r\n<form name=\"form1\" method=\"post\" action=\"\">\r\n<input type=\"hidden\" name=\"<?php echo $hidden_field_name; ?>\" value=\"Y\">\r\n\r\n<p><?php _e(\"Widget Title:\", 'mt_trans_domain' ); ?> \r\n<input type=\"text\" name=\"<?php echo $data_field_name_4; ?>\" value=\"<?php echo $opt_val_4; ?>\" size=\"50\">\r\n</p><hr />\r\n\r\n<p><?php _e(\"Support the Plugin?\", 'mt_trans_domain' ); ?> \r\n<input type=\"radio\" name=\"<?php echo $data_field_name_5; ?>\" value=\"Yes\" <?php echo $change1; ?>>Yes\r\n<input type=\"radio\" name=\"<?php echo $data_field_name_5; ?>\" value=\"No\" <?php echo $change11; ?>>No\r\n</p><hr />\r\n\r\n<p class=\"submit\">\r\n<input type=\"submit\" name=\"Submit\" value=\"<?php _e('Update Options', 'mt_trans_domain' ) ?>\" />\r\n</p><hr />\r\n\r\n</form>\r\n</div>\r\n<?php\r\n \r\n}", "public function pluginSettingsMenu()\n {\n $hook_suffix = add_options_page(__('Rundizable WP Features', 'rundizable-wp-features'), __('Rundizable WP Features', 'rundizable-wp-features'), 'manage_options', 'rundizable-wp-features-settings', [$this, 'pluginSettingsPage']);\n add_action('load-' . $hook_suffix, [$this, 'registerScripts']);\n unset($hook_suffix);\n\n //add_options_page(__('Rundizable WP Features read settings value', 'rundizable-wp-features'), __('Rundizable WP Features read settings', 'rundizable-wp-features'), 'manage_options', 'rundizable-wp-features-read-settings', [$this, 'pluginReadSettingsPage']);\n }", "function _after_switch_theme(){\n\t// GET DESIGN FROM FUNCTION\n\t$core_admin_values = childtheme_designchanges();\n\t// SAVE VALUES\n\t//update_option('core_admin_values',$core_admin_values);\n\t\t\n}", "function clix_uppe_admin_menu_page() {\r\n?>\r\n<div class=\"wrap\">\r\n<h2>ClixCorp Ultimate Post Category Excluder</h2>\r\n\r\n<form method=\"post\" action=\"options.php\">\r\n <?php settings_fields( 'clix_uppe_settings' ); ?>\r\n <table class=\"form-table\">\r\n <tr valign=\"top\">\r\n <th scope=\"row\">Display this when not logged in &amp; content is restricted: but yet we let them know it is available.</th>\r\n <td><textarea name=\"clix_content_fail\" rows='10' cols='80'><?php echo get_option('clix_content_fail'); ?></textarea></td>\r\n </tr>\r\n\r\n <tr valign=\"top\">\r\n <th scope=\"row\">Ditto for the RSS Feed.</th>\r\n <td><textarea name=\"clix_rss_fail\" rows='3' cols='80'><?php echo get_option('clix_rss_fail'); ?></textarea></td>\r\n </tr>\r\n </table>\r\n <p class=\"submit\">\r\n <input type=\"submit\" class=\"button-primary\" value=\"<?php _e('Save Changes') ?>\" />\r\n </p>\r\n</form>\r\n<br />\r\nPlease visit <a href=\"http://clixcorp.com/wordpress/plugins/UPE\" target='_blank'>ClixCorp.Com</a> for updates,\r\nsuggestions, or to report any problems you may be having with this plug-in.\r\n</div>\r\n<?php }", "function owa_options_menu() {\r\n\t\r\n\tif (function_exists('add_options_page')):\r\n\t\tadd_options_page('Options', 'OWA', 8, basename(__FILE__), 'owa_options_page');\r\n\tendif;\r\n \r\n return;\r\n}", "function update_gtpressMenu_options() {\r\n\tupdate_option('gtpressMenu_disabled_menu_items', isset($_POST['disabled_menu_items']) ? $_POST['disabled_menu_items'] : array()\r\n\t);\r\n\tupdate_option('gtpressMenu_disabled_submenu_items', \r\n\t\tisset($_POST['disabled_submenu_items']) ? $_POST['disabled_submenu_items'] : array()\r\n\t);\r\n\tupdate_option('gtpressMenu_disabled_metas', \r\n\t\tisset($_POST['disabled_metas']) ? $_POST['disabled_metas'] : array()\r\n\t);\r\n\tupdate_option('gtpressMenu_admins_see_everything',\r\n\t\tisset($_POST['gtpressMenu_admins_see_everything']) ? true : false\r\n\t);\r\n}", "function cmh_add_defaults() {\r\n\t$tmp = get_option('cmh_options');\r\n if( !is_array($tmp) ) {\r\n\t\tdelete_option('cmh_options'); // so we don't have to reset all the 'off' checkboxes too! (don't think this is needed but leave for now)\r\n\t\t$arr = array(\t\r\n\t\t\t\"rdo_group_one\" => \"h2\"\r\n\t\t);\r\n\t\tupdate_option('cmh_options', $arr);\r\n\t}\r\n}", "function em_ms_admin_options_page() {\n\tglobal $wpdb,$EM_Notices;\n\t//Check for uninstall/reset request\n\tif( !empty($_REQUEST['action']) && $_REQUEST['action'] == 'uninstall' ){\n\t\tem_admin_options_uninstall_page();\n\t\treturn;\n\t}\t\n\tif( !empty($_REQUEST['action']) && $_REQUEST['action'] == 'reset' ){\n\t\tem_admin_options_reset_page();\n\t\treturn;\n\t}\t\n\t//TODO place all options into an array\n\t$events_placeholders = '<a href=\"'.EM_ADMIN_URL .'&amp;events-manager-help#event-placeholders\">'. __('Event Related Placeholders','events-manager') .'</a>';\n\t$locations_placeholders = '<a href=\"'.EM_ADMIN_URL .'&amp;events-manager-help#location-placeholders\">'. __('Location Related Placeholders','events-manager') .'</a>';\n\t$bookings_placeholders = '<a href=\"'.EM_ADMIN_URL .'&amp;events-manager-help#booking-placeholders\">'. __('Booking Related Placeholders','events-manager') .'</a>';\n\t$categories_placeholders = '<a href=\"'.EM_ADMIN_URL .'&amp;events-manager-help#category-placeholders\">'. __('Category Related Placeholders','events-manager') .'</a>';\n\t$events_placeholder_tip = \" \". sprintf(__('This accepts %s and %s placeholders.','events-manager'),$events_placeholders, $locations_placeholders);\n\t$locations_placeholder_tip = \" \". sprintf(__('This accepts %s placeholders.','events-manager'), $locations_placeholders);\n\t$categories_placeholder_tip = \" \". sprintf(__('This accepts %s placeholders.','events-manager'), $categories_placeholders);\n\t$bookings_placeholder_tip = \" \". sprintf(__('This accepts %s, %s and %s placeholders.','events-manager'), $bookings_placeholders, $events_placeholders, $locations_placeholders);\n\t\n\tglobal $save_button;\n\t$save_button = '<tr><th>&nbsp;</th><td><p class=\"submit\" style=\"margin:0px; padding:0px; text-align:right;\"><input type=\"submit\" class=\"button-primary\" name=\"Submit\" value=\"'. __( 'Save Changes', 'events-manager') .' ('. __('All','events-manager') .')\" /></p></td></tr>';\n\t//Do some multisite checking here for reuse\n\t?>\t\n\t<script type=\"text/javascript\" charset=\"utf-8\"><?php include(EM_DIR.'/includes/js/admin-settings.js'); ?></script>\n\t<script type=\"text/javascript\" charset=\"utf-8\">\n\t\tjQuery(document).ready(function($){\n\t\t\t//events\n\t\t\t$('input[name=\"dbem_ms_global_events\"]').change(function(){\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_global_events\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tr#dbem_ms_global_events_links_row\").show();\n\t\t\t\t\t$('input:radio[name=\"dbem_ms_global_events_links\"]:checked').trigger('change');\n\t\t\t\t}else{\n\t\t\t\t\t$(\"tr#dbem_ms_global_events_links_row, tr#dbem_ms_events_slug_row\").hide();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}).first().trigger('change');\n\t\t\t$('input[name=\"dbem_ms_global_events_links\"]').change(function(){\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_global_events_links\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tr#dbem_ms_events_slug_row\").hide();\t\n\t\t\t\t}else{\t\t\t\t\n\t\t\t\t\t$(\"tr#dbem_ms_events_slug_row\").show();\n\t\t\t\t}\n\t\t\t}).first().trigger('change');\n\t\t\t//locations\n\t\t\t$('input[name=\"dbem_ms_mainblog_locations\"]').change(function(){\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_mainblog_locations\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tbody.em-global-locations\").hide();\n\t\t\t\t}else{\n\t\t\t\t\t$(\"tbody.em-global-locations\").show();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}).first().trigger('change');\n\t\t\t$('input[name=\"dbem_ms_global_locations\"]').change(function(){\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_global_locations\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tr#dbem_ms_global_locations_links_row\").show();\n\t\t\t\t\t$('input:radio[name=\"dbem_ms_global_locations_links\"]:checked').trigger('change');\n\t\t\t\t}else{\n\t\t\t\t\t$(\"tr#dbem_ms_global_locations_links_row, tr#dbem_ms_locations_slug_row\").hide();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}).first().trigger('change');\n\t\t\t$('input[name=\"dbem_ms_global_locations_links\"]').change(function(){\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_global_locations_links\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tr#dbem_ms_locations_slug_row\").hide();\t\n\t\t\t\t}else{\n\t\t\t\t\t$(\"tr#dbem_ms_locations_slug_row\").show();\t\t\t\t\n\t\t\t\t}\n\t\t\t});\t\t\n\t\t\t//MS Mode selection hiders \n\t\t\t$('input[name=\"dbem_ms_global_table\"]').change(function(){ //global\n\t\t\t\tif( $('input:radio[name=\"dbem_ms_global_table\"]:checked').val() == 1 ){\n\t\t\t\t\t$(\"tbody.em-global-options\").show();\n\t\t\t\t\t$('input:radio[name=\"dbem_ms_mainblog_locations\"]:checked').trigger('change');\n\t\t\t\t}else{\n\t\t\t\t\t$(\"tbody.em-global-options\").hide();\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}).first().trigger('change');\t\n\t\t});\n\t</script>\n\t<style type=\"text/css\">.postbox h3 { cursor:pointer; }</style>\n\t<div class=\"wrap <?php if(empty($tabs_enabled)) echo 'tabs-active' ?>\">\n\t\t<div id='icon-options-general' class='icon32'><br /></div>\n\t\t<h1 id=\"em-options-title\"><?php _e ( 'Event Manager Options', 'events-manager'); ?></h1>\n\t\t<h2 class=\"nav-tab-wrapper\">\n\t\t\t<?php\n\t\t\t$tabs_enabled = defined('EM_SETTINGS_TABS') && EM_SETTINGS_TABS;\n\t\t\tif( $tabs_enabled ){\n\t\t\t\t$general_tab_link = esc_url(add_query_arg( array('em_tab'=>'general')));\n\t\t\t}else{\n\t\t\t\t$general_tab_link = '';\n\t\t\t}\n\t\t\t?>\n\t\t\t<a href=\"<?php echo $general_tab_link ?>#general\" id=\"em-menu-general\" class=\"nav-tab nav-tab-active\"><?php esc_html_e('General','events-manager'); ?></a>\n\t\t\t<?php\n\t\t\t$custom_tabs = apply_filters('em_ms_options_page_tabs', array());\n\t\t\tforeach( $custom_tabs as $tab_key => $tab_name ){\n\t\t\t\t$tab_link = !empty($tabs_enabled) ? esc_url(add_query_arg( array('em_tab'=>$tab_key))) : '';\n\t\t\t\t$active_class = !empty($tabs_enabled) && !empty($_GET['em_tab']) && $_GET['em_tab'] == $tab_key ? 'nav-tab-active':'';\n\t\t\t\techo \"<a href='$tab_link#$tab_key' id='em-menu-$tab_key' class='nav-tab $active_class'>$tab_name</a>\";\n\t\t\t}\n\t\t\t?>\n\t\t</h2>\n\t\t<?php echo $EM_Notices; ?>\n\t\t<form id=\"em-options-form\" method=\"post\" action=\"\">\n\t\t\t<div class=\"metabox-holder\"> \n\t\t\t<!-- // TODO Move style in css -->\n\t\t\t<div class='postbox-container' style='width: 99.5%'>\n\t\t\t<div id=\"\">\n\t\t\t<?php if( !$tabs_enabled || ($tabs_enabled && (empty($_REQUEST['em_tab']) || $_REQUEST['em_tab'] == 'general')) ): //make less changes for now, since we don't have any core tabs to add yet ?>\n\t\t \t<div class=\"em-menu-general em-menu-group\">\n\t\t\t\t<div class=\"postbox \" id=\"em-opt-ms-options\" >\n\t\t\t\t\t<div class=\"handlediv\" title=\"<?php __('Click to toggle', 'events-manager'); ?>\"><br /></div><h3><span><?php _e ( 'Multi Site Options', 'events-manager'); ?></span></h3>\n\t\t\t\t\t<div class=\"inside\">\n\t\t\t <table class=\"form-table\">\n\t\t\t\t\t\t\t<?php \n\t\t\t\t\t\t\tem_options_radio_binary ( __( 'Enable global tables mode?', 'events-manager'), 'dbem_ms_global_table', __( 'Setting this to yes will make all events save in the main site event tables (EM must also be activated). This allows you to share events across different blogs, such as showing events in your network whilst allowing users to display and manage their events within their own blog. Bear in mind that activating this will mean old events created on the sub-blogs will not be accessible anymore, and if you switch back they will be but new events created during global events mode will only remain on the main site.','events-manager') );\n\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t<tbody class=\"em-global-options\">\n\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tglobal $current_site;\n\t\t\t\t\t\t\t$global_slug_tip = __('%s belonging to other sub-sites will have an extra slug prepended to it so that your main site can differentiate between its own %s and those belonging to other sites in your network.','events-manager');\n\t\t\t\t\t\t\t$global_link_tip = __( 'When displaying global %s on the main site you have the option of users viewing the %s details on the main site or being directed to the sub-site.','events-manager');\n\t\t\t\t\t\t\t$global_post_tip = __( 'Displays %s from all sites on the network by default. You can still restrict %s by blog using shortcodes and template tags coupled with the <code>blog</code> attribute. Requires global tables to be turned on.','events-manager');\n\t\t\t\t\t\t\t$global_link_tip2 = __('You <strong>must</strong> have assigned a %s page in your <a href=\"%s\">main blog settings</a> for this to work.','events-manager');\n\t\t\t\t\t\t\t$options_page_link = get_admin_url($current_site->blog_id, 'edit.php?post_type='.EM_POST_TYPE_EVENT.'&page=events-manager-options#pages');\n\t\t\t\t\t\t\t?><tr class=\"em-header\"><td><h4><?php echo sprintf(__('%s Options','events-manager'),__('Event','events-manager')); ?></h4></td></tr><?php\n\t\t\t\t\t\t\tem_options_radio_binary ( sprintf(__( 'Display global events on main blog?', 'events-manager'), __('events','events-manager')), 'dbem_ms_global_events', sprintf($global_post_tip, __('events','events-manager'), __('events','events-manager')) );\n\t\t\t\t\t\t\tem_options_radio_binary ( sprintf(__( 'Link sub-site %s directly to sub-site?', 'events-manager'), __('events','events-manager')), 'dbem_ms_global_events_links', sprintf($global_link_tip, __('events','events-manager'), __('event','events-manager')).sprintf($global_link_tip2, __('event','events-manager'), $options_page_link) );\n\t\t\t\t\t\t\tem_options_input_text ( sprintf(__( 'Global %s slug', 'events-manager'),__('event','events-manager')), 'dbem_ms_events_slug', sprintf($global_slug_tip, __('Events','events-manager'), __('events','events-manager')).__('Example:','events-manager').'<code>http://yoursite.com/events/<strong>event</strong>/subsite-event-slug/', EM_EVENT_SLUG );\n\t\t\t\t\t\t\t?><tr class=\"em-header\"><td><h4><?php echo sprintf(__('%s Options','events-manager'),__('Location','events-manager')); ?></h4></td></tr><?php\n\t\t\t\t\t\t\tem_options_radio_binary ( sprintf(__( 'Locations on main blog?', 'events-manager'), __('locations','events-manager')), 'dbem_ms_mainblog_locations', __('If you would prefer all your locations to belong to your main blog, users in sub-sites will still be able to create locations, but the actual locations are created and reside in the main blog.','events-manager') );\n\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t</tbody>\n\t\t\t\t\t\t\t<tbody class=\"em-global-options em-global-locations\">\n\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tem_options_radio_binary ( sprintf(__( 'Display global %s on main blog?', 'events-manager'), __('locations','events-manager')), 'dbem_ms_global_locations', sprintf($global_post_tip, __('locations','events-manager'), __('locations','events-manager')) );\n\t\t\t\t\t\t\tem_options_radio_binary ( sprintf(__( 'Link sub-site %s directly to sub-site?', 'events-manager'), __('locations','events-manager')), 'dbem_ms_global_locations_links', sprintf($global_link_tip, __('locations','events-manager'), __('location','events-manager')).sprintf($global_link_tip2, __('location','events-manager'), $options_page_link) );\n\t\t\t\t\t\t\tem_options_input_text ( sprintf(__( 'Global %s slug', 'events-manager'),__('location','events-manager')), 'dbem_ms_locations_slug', sprintf($global_slug_tip, __('Locations','events-manager'), __('locations','events-manager')).__('Example:','events-manager').'<code>http://yoursite.com/locations/<strong>location</strong>/subsite-location-slug/', EM_LOCATION_SLUG );\n\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t</tbody>\n\t\t\t\t\t\t\t<?php echo $save_button; ?>\n\t\t\t\t\t\t</table>\n\t\t\t\t\t\t \n\t\t\t\t\t</div> <!-- . inside --> \n\t\t\t\t</div> <!-- .postbox --> \n\t\t\t\t\n\t\t\t\t<?php \n\t\t\t\t//including shared MS/non-MS boxes\n\t\t\t\tem_admin_option_box_caps();\n\t\t\t\tem_admin_option_box_image_sizes();\n\t\t\t\tem_admin_option_box_email();\n\t\t\t\tem_admin_option_box_uninstall();\n\t\t\t\t?>\n\t\t\t\t\n\t\t\t\t<?php do_action('em_ms_options_page_footer'); ?>\n\t\t\t</div> <!-- .em-menu-general -->\n\t\t\t<?php endif; ?>\n\t\t\t<?php\n\t\t\t//other tabs\n\t\t\tif( $tabs_enabled ){\n\t\t\t\tif( array_key_exists($_REQUEST['em_tab'], $custom_tabs) ){\n\t\t\t\t\t?>\n\t\t\t\t\t<div class=\"em-menu-bookings em-menu-group\">\n\t\t\t\t\t\t<?php do_action('em_ms_options_page_tab_'. $_REQUEST['em_tab']); ?>\n\t\t\t\t\t</div>\n\t\t\t\t\t<?php\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\tforeach( $custom_tabs as $tab_key => $tab_name ){\n\t\t\t\t\t?>\n\t\t\t\t\t<div class=\"em-menu-<?php echo esc_attr($tab_key) ?> em-menu-group\" style=\"display:none;\">\n\t\t\t\t\t\t<?php do_action('em_ms_options_page_tab_'. $tab_key); ?>\n\t\t\t\t\t</div>\n\t\t\t\t\t<?php\n\t\t\t\t}\n\t\t\t}\n\t\t\t?>\n\n\t\t\t<p class=\"submit\">\n\t\t\t\t<input type=\"submit\" class=\"button-primary\" name=\"Submit\" value=\"<?php esc_attr_e( 'Save Changes', 'events-manager'); ?>\" />\n\t\t\t\t<input type=\"hidden\" name=\"em-submitted\" value=\"1\" />\n\t\t\t\t<input type=\"hidden\" name=\"_wpnonce\" value=\"<?php echo wp_create_nonce('events-manager-options'); ?>\" />\n\t\t\t</p> \n\t\t\t\n\t\t\t</div> <!-- .metabox-sortables -->\n\t\t\t</div> <!-- .postbox-container -->\n\t\t\t\n\t\t\t</div> <!-- .metabox-holder -->\t\n\t\t</form>\n\t</div>\n\t<?php\n}", "function wtr_validate_options( $input ) {\r\n\r\n\t\t\tswitch( $_POST['submitControl'] ){\r\n\r\n\t\t\t\t//restore default settings\r\n\t\t\t\tcase 'default-settings':\r\n\t\t\t\t\tupdate_option( $this->settings->get_WP_ERROR(), 'default' );\r\n\t\t\t\t\tupdate_option( $this->settings->get_WP_REWRITE_FLUSH(), 1 );\r\n\t\t\t\t\tdo_action( 'wtr_default_settings' );\r\n\t\t\t\t\treturn null;\r\n\t\t\t\tbreak;\r\n\r\n\t\t\t\t// writing by ajax\r\n\t\t\t\tcase 'ajax':\r\n\t\t\t\t\t$opt_a = $this->settings->get( 'opt_a' );\r\n\t\t\t\tbreak;\r\n\r\n\t\t\t\t// restore settings from the backup system\r\n\t\t\t\tcase 'import-auto':\r\n\t\t\t\t\t$opt_a = $this->settings->get( 'opt_a' );\r\n\t\t\t\t\t$input = wtr_get_export_theme_settings( $_POST[ 'wtr_export_theme_settings' ] );\r\n\t\t\t\t\t$status = 'import_data' ;\r\n\t\t\t\tbreak;\r\n\r\n\t\t\t\t// restore settings from text\r\n\t\t\t\tcase 'import-text':\r\n\t\t\t\t\t$opt_a = $this->settings->get( 'opt_a' );\r\n\t\t\t\t\t$input = wtr_decode_theme_settings( wp_remote_fopen( $_POST[ 'wtr_admin_import_settings_text' ] ) );\r\n\t\t\t\t\t$status = 'import_data' ;\r\n\t\t\t\tbreak;\r\n\r\n\t\t\t\tdefault:\r\n\t\t\t\t\t$opt_a = $this->settings->get( 'opt_a' );\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\r\n\t\t\t$flaga\t\t\t= false;\r\n\t\t\t$new_opt\t\t= array();\r\n\t\t\t$status_flush\t= 0;\r\n\t\t\t$opt\t\t\t= $this->settings->get( 'opt' );\r\n\r\n\r\n\t\t\tforeach ( $opt as $group ) {\r\n\t\t\t\tforeach ( (array ) $group->get('sections') as $section ) {\r\n\t\t\t\t\tforeach ( ( array ) $section->get('fields') as $field ) {\r\n\r\n\t\t\t\t\t\t$id_field\t= $field->get( 'id' );\r\n\t\t\t\t\t\t$allow\t\t= $field->get( 'allow' );\r\n\t\t\t\t\t\t$value\t\t= $field->get( 'value' );\r\n\r\n\t\t\t\t\t\tif( isset( $input[ $id_field ] ) ){\r\n\t\t\t\t\t\t\t$new_value = ( ! is_array( $input[ $id_field ] ) ) ? trim ( $input[ $id_field ] ) : $input[ $id_field ];\r\n\r\n\t\t\t\t\t\t\tif( $allow == 'between' ){\r\n\t\t\t\t\t\t\t\t$min\t\t\t= $field->get( 'min' );\r\n\t\t\t\t\t\t\t\t$max\t\t\t= $field->get( 'max' );\r\n\t\t\t\t\t\t\t\t$has_attr\t\t= $field->get( 'has_attr' );\r\n\t\t\t\t\t\t\t\t//$input[ $key ]\t= trim( $input[ $key ] );\r\n\r\n\t\t\t\t\t\t\t\t$flaga = WTR_Validate::check( $allow, $new_value, $max, $min, $has_attr );\r\n\t\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t\t$flaga = WTR_Validate::check( $allow, $new_value ) ;\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t//default value\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t$new_value\t= $field->get( 'default_value' );\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t$new_opt[ $id_field ]\t= $new_value;\r\n\t\t\t\t\t\t$new_opt\t\t\t\t= $this->settings->set_opt_a( $new_opt, $field, $new_value );\r\n\r\n\t\t\t\t\t\t//checking slug\r\n\t\t\t\t\t\tif( $status_flush != 1 AND strpos( $id_field, '_Slug' ) AND $value != $new_value ){\r\n\t\t\t\t\t\t\t$status_flush = 1;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif( ! $flaga ){\r\n\t\t\t\t\t\t\tbreak 3;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tif( ! $flaga ){\r\n\r\n\t\t\t\t$new_opt = $this->settings->get( 'opt_a' );\r\n\r\n\t\t\t\tif( isset( $status ) AND 'import_data' == $status ) {\r\n\t\t\t\t\tupdate_option( $this->settings->get_WP_ERROR(), 'import_error' );\r\n\t\t\t\t}\r\n\r\n\t\t\t\tif( empty( $status ) OR 'import_data' != $status ){\r\n\t\t\t\t\techo 'wtr_save_option_error';\r\n\t\t\t\t\texit;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\telse if ( isset( $status ) ){\r\n\r\n\t\t\t\tupdate_option( $this->settings->get_WP_ERROR(), $status );\r\n\t\t\t\tdo_action( 'wtr_import_data', $input );\r\n\t\t\t}\r\n\r\n\t\t\tif( $flaga AND isset( $status_flush ) ){\r\n\t\t\t\tupdate_option( $this->settings->get_WP_REWRITE_FLUSH(), $status_flush );\r\n\t\t\t}\r\n\r\n\t\t\treturn base64_encode( serialize( $new_opt ) );\r\n\t\t}", "function mxpress_add_admin_page() {\r\n //add_filter('template_include','start_buffer_capture',1);\r\n $page = add_submenu_page('themes.php', 'Mxit Options', 'Mxit Options', 'manage_options', 'mxpress_plugin', 'mxpress_options_page');\r\n add_action('admin_print_styles-' . $page, 'mxpress_admin_styles');\r\n add_action(\"admin_print_scripts-{$page}\", 'mxpress_page_scripts');\r\n\r\n if (check_upload_image_context('mxpress-logo-image')) {\r\n // mxpress_debug('check_upload_image_context');\r\n add_filter('media_upload_tabs', 'mxpress_image_tabs', 10, 1);\r\n add_filter('attachment_fields_to_edit', 'mxpress_action_button', 20, 2);\r\n add_filter('media_send_to_editor', 'mxpress_image_selected', 10, 3);\r\n } else {\r\n // mxpress_debug('NOT check_upload_image_context');\r\n }\r\n}", "public function set_options_filter() {\n\t\t/**\n\t\t * Filter the plugin options.\n\t\t *\n\t\t * @since 10.0.0\n\t\t *\n\t\t * @return array\n\t\t */\n\t\t$config = apply_filters( 'gu_set_options', [] );\n\n\t\t/**\n\t\t * Filter the plugin options.\n\t\t *\n\t\t * @return null|array\n\t\t */\n\t\t$config = empty( $config ) ? apply_filters_deprecated( 'github_updater_set_options', [ [] ], '6.1.0', 'gu_set_options' ) : $config;\n\n\t\tforeach ( array_keys( self::$git_servers ) as $git ) {\n\t\t\tunset( $config[ \"{$git}_access_token\" ], $config[ \"{$git}_enterprise_token\" ] );\n\t\t}\n\n\t\tif ( ! empty( $config ) ) {\n\t\t\t$config = $this->sanitize( $config );\n\t\t\tself::$options = array_merge( get_site_option( 'git_updater' ), $config );\n\t\t\tupdate_site_option( 'git_updater', self::$options );\n\t\t}\n\t}", "function bsb_custom_theme_options() {\n\t\t$saved_settings = get_option('option_tree_settings', array());\n\t\t\n\t\t/**\n\t\t * Custom settings array that will eventually be \n\t\t * passes to the OptionTree Settings API Class.\n\t\t */\n\t\t$custom_settings = array(\n\t\t\t'contextual_help' => array(\n\t\t\t\t\n\t\t\t\t'sidebar' => ''\n\t\t\t),\n\t\t\t'sections' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'general',\n\t\t\t\t\t'title' => 'General'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'typography',\n\t\t\t\t\t'title' => 'Typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'design',\n\t\t\t\t\t'title' => 'Backgrounds'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'headerdesign',\n\t\t\t\t\t'title' => 'Header Design'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'blogdesign',\n\t\t\t\t\t'title' => 'Blog Design'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'footerdesign',\n\t\t\t\t\t'title' => 'Footer Design'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'social',\n\t\t\t\t\t'title' => 'Social'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'thumbnails',\n\t\t\t\t\t'title' => 'Thumbnails'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'behavior',\n\t\t\t\t\t'title' => 'Behavior'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'advanced',\n\t\t\t\t\t'title' => 'Advanced'\n\t\t\t\t)\n\t\t\t),\n\t\t\t'settings' => array(\n\t\t\t\t array(\n\t\t\t\t\t'label' => 'Custom Thumbnails',\n\t\t\t\t\t'id' => 'customthumbnails',\n\t\t\t\t\t'type' => 'list-item',\n\t\t\t\t\t'desc' => 'Use this tool to add custom thumbnails to your site.',\n\t\t\t\t\t'section'\t => 'thumbnails',\n\t\t\t\t\t'settings' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'label' => 'ID',\n\t\t\t\t\t\t\t'id' => 'thumbnailid',\n\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t'desc' => 'Enter the ID of the thumbnail. This is used so that the thumbnail can be accessed programatically. NOTE: Only enter lowercase characters and underscores and do not use native WordPress thumbnail identifiers (thumb, thumbnail, medium, large, post-thumbnail).',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'label' => 'Width',\n\t\t\t\t\t\t\t'id' => 'thumbnailwidth',\n\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t'desc' => 'Enter the width of the thumbnail in pixels. NOTE: Only enter a numeric value.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'label' => 'Height',\n\t\t\t\t\t\t\t'id' => 'thumbnailheight',\n\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t'desc' => 'Enter the height of the thumbnail in pixels. NOTE: Only enter a numeric value.',\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'label' => 'Fixed Crop',\n\t\t\t\t\t\t\t'id' => 'fixedcrop',\n\t\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t\t'desc' => 'If enabled, this will keep the thumbnail size the EXACT dimensions regardless of image size.',\n\t\t\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\t\t array (\n\t\t\t\t\t\t\t\t'label' => 'Enabled',\n\t\t\t\t\t\t\t\t'value' => 'enabled'\n\t\t\t\t\t\t\t )\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t )\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'logo',\n\t\t\t\t\t'label' => 'Logo',\n\t\t\t\t\t'desc' => 'Upload a logo for your site or Boostrap Base will use the default site name.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'logotitle',\n\t\t\t\t\t'label' => 'Logo Title / Alt Text',\n\t\t\t\t\t'desc' => 'Use a good text description for the logo',\n\t\t\t\t\t'std' => 'Testing Defaults',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'latitude',\n\t\t\t\t\t'label' => 'Latitude Coordinate',\n\t\t\t\t\t'desc' => \"Enter the lat coordinate to take advantage of Bing's geo location features. \",\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'longitude',\n\t\t\t\t\t'label' => 'Longitude Coordinate',\n\t\t\t\t\t'desc' => \"Enter the long coordinate to take advantage of Bing's geo location features. \",\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'favicon',\n\t\t\t\t\t'label' => 'Favicon 16x16',\n\t\t\t\t\t'desc' => 'For nokia devices and desktop/laptop web browsers',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'favicon57',\n\t\t\t\t\t'label' => 'Favicon 57x57',\n\t\t\t\t\t'desc' => 'For non-Retina iPhone, iPod Touch, and Android 2.1+ devices',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'favicon72',\n\t\t\t\t\t'label' => 'Favicon 72x72',\n\t\t\t\t\t'desc' => 'For first-generation iPad',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'favicon114',\n\t\t\t\t\t'label' => 'Favicon 114x114',\n\t\t\t\t\t'desc' => 'For iPhone 4 with high-resolution Retina display',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'favicon144',\n\t\t\t\t\t'label' => 'Favicon 144x144',\n\t\t\t\t\t'desc' => 'For third generation iPad Retina Display',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'footertext',\n\t\t\t\t\t'label' => 'Footer Credit Text',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'textarea',\n\t\t\t\t\t'section' => 'general',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'mainfont',\n\t\t\t\t\t'label' => 'Main Font',\n\t\t\t\t\t'desc' => 'You know what this does :)',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'morefooterfont',\n\t\t\t\t\t'label' => 'More Footer Font',\n\t\t\t\t\t'desc' => 'You know what this does :)',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'endfooterfont',\n\t\t\t\t\t'label' => 'End Footer Font',\n\t\t\t\t\t'desc' => 'You know what this does :)',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'links',\n\t\t\t\t\t'label' => 'Links',\n\t\t\t\t\t'desc' => 'Default link normal state',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'linkhover',\n\t\t\t\t\t'label' => 'Link Hover',\n\t\t\t\t\t'desc' => 'Default link hover state',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'caption',\n\t\t\t\t\t'label' => 'Image Captions',\n\t\t\t\t\t'desc' => 'Font treatments that will be used for Image captions',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'minimumthreshold',\n\t\t\t\t\t'label' => 'Font Minimum Threshold',\n\t\t\t\t\t'desc' => 'When headers are scaled, they will not be scaled smaller than this value. NOTE: Only use an integer for best results',\n\t\t\t\t\t'std' => '14',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'largedesktoppercentage',\n\t\t\t\t\t'label' => 'Large Desktop Font Ratio',\n\t\t\t\t\t'desc' => 'NOTE: This number is multipled. At most use 1 smallest can be some decimal.',\n\t\t\t\t\t'std' => '1',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'normaldesktoppercentage',\n\t\t\t\t\t'label' => 'Normal Desktop Font Ratio',\n\t\t\t\t\t'desc' => 'NOTE: This number is multipled. At most use 1 smallest can be some decimal.',\n\t\t\t\t\t'std' => '1',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'tabletpercentage',\n\t\t\t\t\t'label' => 'Tablet Font Ratio',\n\t\t\t\t\t'desc' => 'NOTE: This number is multipled. At most use 1 smallest can be some decimal.',\n\t\t\t\t\t'std' => '.8',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'landscapephonepercentage',\n\t\t\t\t\t'label' => 'Landscape Phone Font Ratio',\n\t\t\t\t\t'desc' => 'NOTE: This number is multipled. At most use 1 smallest can be some decimal.',\n\t\t\t\t\t'std' => '.7',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'portraitphonepercentage',\n\t\t\t\t\t'label' => 'Portrait Phone Font Ratio',\n\t\t\t\t\t'desc' => 'NOTE: This number is multipled. At most use 1 smallest can be some decimal.',\n\t\t\t\t\t'std' => '.6',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'typography'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'entrytitle',\n\t\t\t\t\t'label' => 'Primary Titles',\n\t\t\t\t\t'desc' => 'This font will be used for the main headings on entries such as post titles, pages titles, etc. Make sure to use the .entry-title class in your theme to take advantage of this.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'subheader',\n\t\t\t\t\t'label' => 'Subheader',\n\t\t\t\t\t'desc' => 'This font will be used for the sub header on entries such as post titles, pages titles, etc. The subheader can be accessed via CSS with the .entry-subheader class.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'secondarytitle',\n\t\t\t\t\t'label' => 'Secondary Titles',\n\t\t\t\t\t'desc' => 'This font will be used for the secondary headings in content areas and h2 tags.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'tertiarytitle',\n\t\t\t\t\t'label' => 'Tertiary Titles',\n\t\t\t\t\t'desc' => 'This font will be used for the tertiary headings such as sidebars and h3 tags.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'typography',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'background',\n\t\t\t\t\t'label' => 'Body Background',\n\t\t\t\t\t'desc' => 'This will be used in the body tag.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'backgroundlayer1',\n\t\t\t\t\t'label' => 'Layer 1 Backround',\n\t\t\t\t\t'desc' => 'This will be used in the layer 1 div.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'backgroundlayer2',\n\t\t\t\t\t'label' => 'Layer 2 Backround',\n\t\t\t\t\t'desc' => 'This will be used in the layer 2 div.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'headerbackground',\n\t\t\t\t\t'label' => 'Header Background',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'morefooterbackground',\n\t\t\t\t\t'label' => 'More Footer Background',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'endfooterbackground',\n\t\t\t\t\t'label' => 'End Footer Background',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'background',\n\t\t\t\t\t'section' => 'design',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'font_awesome',\n\t\t\t\t\t'label' => 'Font Awesome',\n\t\t\t\t\t'desc' => 'Enable this option to take advantage of the font awesome library.',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'advanced',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'animate',\n\t\t\t\t\t'label' => 'Animate.css',\n\t\t\t\t\t'desc' => 'Enable this option to take advantage of the animate.css library.',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'advanced',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'pricing',\n\t\t\t\t\t'label' => 'Pricing.css',\n\t\t\t\t\t'desc' => 'Enable this option to enable custom pricing grids.',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'advanced',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'htmlnamespace',\n\t\t\t\t\t'label' => 'HTML Namespace',\n\t\t\t\t\t'desc' => 'Use this for Facebook and other app integrations',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'advanced'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'customcss',\n\t\t\t\t\t'label' => 'Custom CSS',\n\t\t\t\t\t'desc' => '',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'css',\n\t\t\t\t\t'section' => 'advanced',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'iconset',\n\t\t\t\t\t'label' => 'Icon Set',\n\t\t\t\t\t'desc' => 'Choose the social icon set to use.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'select',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'icontexto-inside',\n\t\t\t\t\t\t\t'label' => 'Icontexto Inside'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'wp-zoom',\n\t\t\t\t\t\t\t'label' => 'WPZoom'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'feed',\n\t\t\t\t\t'label' => 'Display Feed',\n\t\t\t\t\t'desc' => 'Enable this option to display the feed in the social icon section.',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'facebook',\n\t\t\t\t\t'label' => 'Facebook URL',\n\t\t\t\t\t'desc' => 'Use your entire Facebook URL.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'twitter',\n\t\t\t\t\t'label' => 'Twitter Username',\n\t\t\t\t\t'desc' => 'Use just your twitter username. Do not include the @ sign.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'linkedin',\n\t\t\t\t\t'label' => 'LinkedIn URL',\n\t\t\t\t\t'desc' => 'Use your entire LinkedIn URL.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'googleplus',\n\t\t\t\t\t'label' => 'Google+ ID',\n\t\t\t\t\t'desc' => 'Just the Google+ ID',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'youtube',\n\t\t\t\t\t'label' => 'YouTube URL',\n\t\t\t\t\t'desc' => 'Use your entire YouTube URL.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'Vimeo',\n\t\t\t\t\t'label' => 'Vimeo URL',\n\t\t\t\t\t'desc' => 'Use your entire Vimeo URL.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'instagram',\n\t\t\t\t\t'label' => 'Instagram URL',\n\t\t\t\t\t'desc' => 'Use just your Instagram username.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'section' => 'social',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => ''\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'logoposition',\n\t\t\t\t\t'label' => 'Menu / Logo Layout',\n\t\t\t\t\t'desc' => 'This option controls how to the logo sits within the menu. If center is selected a left and right menu option will be enabled.',\n\t\t\t\t\t'std' => 'left',\n\t\t\t\t\t'type' => 'radio-image',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t\t\t'label' => 'Left',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/logo-left.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'center',\n\t\t\t\t\t\t\t'label' => 'Center',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/logo-center.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t\t\t'label' => 'Right',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/logo-right.jpg'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'menuposition',\n\t\t\t\t\t'label' => 'Header Position',\n\t\t\t\t\t'desc' => 'Control how your menu sits on the page. Standard, Absolute, Fixed',\n\t\t\t\t\t'std' => 'standard',\n\t\t\t\t\t'type' => 'radio',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'standard',\n\t\t\t\t\t\t\t'label' => 'Standard'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'absolute',\n\t\t\t\t\t\t\t'label' => 'Absolute'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'fixed',\n\t\t\t\t\t\t\t'label' => 'Fixed'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Header Top Margin',\n\t\t\t\t\t'id' => 'menutopmargin',\n\t\t\t\t\t'type' => 'measurement',\n\t\t\t\t\t'desc' => 'This will assign a top margin to the header. Use this value to move the entire menu / header down. NOTE: Only use numbers.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Menu Background Color',\n\t\t\t\t\t'id' => 'menubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the entire menu',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Menu Background Opacity',\n\t\t\t\t\t'id' => 'menubackgroundopacity',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'desc' => 'Change the menus background opacity. NOTE: Only use numbers (.1 - 1).',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'menuitemalignment',\n\t\t\t\t\t'label' => 'Menu Item Alignment',\n\t\t\t\t\t'desc' => 'Control how your menu items align in dektop modes',\n\t\t\t\t\t'std' => 'right',\n\t\t\t\t\t'type' => 'radio',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t\t\t'label' => 'Left'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t\t\t'label' => 'Right'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Menu Item Top Margin',\n\t\t\t\t\t'id' => 'menuitemtopmargin',\n\t\t\t\t\t'type' => 'measurement',\n\t\t\t\t\t'desc' => 'This will assign a top margin to the menu. Use this value to vertically align menu items with the logo. NOTE: Only use numbers.',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t => array(\n\t\t\t\t\t\t0\t=> 20,\n\t\t\t\t\t\t1\t=> 'px'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Menu Item Border Radius',\n\t\t\t\t\t'id' => 'menuitemborderradius',\n\t\t\t\t\t'type' => 'measurement',\n\t\t\t\t\t'desc' => 'This will assign a border radius to the menu. NOTE: Only use numbers.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'normalstatemenufont',\n\t\t\t\t\t'label' => 'Normal State Menu Font',\n\t\t\t\t\t'desc' => 'This will determine the font to be used for the normal menu item state.',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Normal State Menu Background Color',\n\t\t\t\t\t'id' => 'normalstatemenubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the normal menu item state.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Normal State Caret Color',\n\t\t\t\t\t'id' => 'normalstatecaretcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Color of the caret for the normal drop-down menu state.',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t\t=> '#666666'\n\t\t\t\t),\n\t\t\t\t\n\t\t\t\tarray(\n\t\t\t\t\t'id'\t\t=>\t'hoverstatemenufont',\n\t\t\t\t\t'label'\t\t=> \t'Hover State Menu Font',\n\t\t\t\t\t'desc'\t\t=>\t'This will determine the font to be used for the hover menu item state.',\n\t\t\t\t\t'type'\t\t=>\t'typography',\n\t\t\t\t\t'section'\t=>\t'headerdesign',\n\t\t\t\t\t'std'\t\t=>\tarray(\n\t\t\t\t\t\t'font-color' => '#ffffff'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' \t=> 'Hover State Menu Background Color',\n\t\t\t\t\t'id' \t=> 'hoverstatemenubackgroundcolor',\n\t\t\t\t\t'type' \t=> 'colorpicker',\n\t\t\t\t\t'desc' \t=> 'Assign a background color to the hover menu item state.',\n\t\t\t\t\t'section'\t\t=> 'headerdesign',\n\t\t\t\t\t'std'\t\t\t=> '#000000'\n\t\t\t\t),\n\t\t\t\t\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Hover State Caret Color',\n\t\t\t\t\t'id' => 'hoverstatecaretcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Color of the caret for the hover drop-down menu state.',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t\t=> '#ffffff'\n\t\t\t\t),\n\t\t\t\t\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'activestatemenufont',\n\t\t\t\t\t'label' => 'Active State Menu Font',\n\t\t\t\t\t'desc' => 'This will determine the font to be used for the active menu item state.',\n\t\t\t\t\t'type' => 'typography',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t=>\tarray(\n\t\t\t\t\t\t'font-color' => '#ffffff'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Active State Menu Background Color',\n\t\t\t\t\t'id' => 'activestatemenubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the active menu item state.',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t\t=> '#5454ff'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Active State Caret Color',\n\t\t\t\t\t'id' => 'activestatecaretcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Color of the caret for the active drop-down menu state.',\n\t\t\t\t\t'section' => 'headerdesign',\n\t\t\t\t\t'std'\t\t\t=> '#ffffff'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label'\t\t => 'Drop Down Normal State Menu Font',\n\t\t\t\t\t'id'\t\t => 'dropdownnormalstatemenufont',\n\t\t\t\t\t'type'\t\t => 'typography',\n\t\t\t\t\t'desc'\t\t => 'This will determine the font to be used for the normal menu item state of drop downs.',\n\t\t\t\t\t'section'\t => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Drop Down Normal State Menu Background Color',\n\t\t\t\t\t'id' => 'dropdownnormalstatemenubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the normal menu item state of drop downs.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label'\t\t => 'Drop Down Hover State Menu Font',\n\t\t\t\t\t'id'\t\t => 'dropdownhoverstatemenufont',\n\t\t\t\t\t'type'\t\t => 'typography',\n\t\t\t\t\t'desc'\t\t => 'This will determine the font to be used for the hover menu item state of drop downs.',\n\t\t\t\t\t'section'\t => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Drop Down Hover State Menu Background Color',\n\t\t\t\t\t'id' => 'dropdownhoverstatemenubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the hover menu item state of drop downs.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label'\t\t => 'Drop Down Active State Menu Font',\n\t\t\t\t\t'id'\t\t => 'dropdownactivestatemenufont',\n\t\t\t\t\t'type'\t\t => 'typography',\n\t\t\t\t\t'desc'\t\t => 'This will determine the font to be used for the active menu item state of drop downs.',\n\t\t\t\t\t'section'\t => 'headerdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Drop Down Active State Menu Background Color',\n\t\t\t\t\t'id' => 'dropdownactivestatemenubackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Assign a background color to the active menu item state of drop downs.',\n\t\t\t\t\t'section' => 'headerdesign'\n\t\t\t\t),\n\t\t\t\t\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '3dbackground',\n\t\t\t\t\t'label' => 'Enable 3D Background',\n\t\t\t\t\t'desc' => 'This will enable a sweet scrolling effect',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'behavior',\n\t\t\t\t\t'class' => '3dbackground',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => '3dlayer',\n\t\t\t\t\t'label' => '3D Layer',\n\t\t\t\t\t'desc' => 'Select which layer will have the 3D scroll effect.',\n\t\t\t\t\t'std' => 'body',\n\t\t\t\t\t'type' => 'radio',\n\t\t\t\t\t'section' => 'behavior',\n\t\t\t\t\t'class' => 'layer',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'body',\n\t\t\t\t\t\t\t'label' => '<body> tag'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '#layer1',\n\t\t\t\t\t\t\t'label' => '#layer1'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '#layer2',\n\t\t\t\t\t\t\t'label' => '#layer2'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Scroll Offset',\n\t\t\t\t\t'id' => 'scrolloffset',\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'desc' => 'This value will determine the 3D scroll offset. Please use ONLY numbers. NOTE: A lower number will create a more dramatic effect.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'rows' => '',\n\t\t\t\t\t'post_type' => '',\n\t\t\t\t\t'taxonomy' => '',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'section' => 'behavior'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'nicemobilemenu',\n\t\t\t\t\t'label' => 'Enable Nice Mobile Menu',\n\t\t\t\t\t'desc' => 'Make your mobile menu look awesome.',\n\t\t\t\t\t'std' => 'enabled',\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'section' => 'behavior',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'enabled',\n\t\t\t\t\t\t\t'label' => 'Enabled'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id' => 'morefooterlayout',\n\t\t\t\t\t'label' => 'More Footer Layout',\n\t\t\t\t\t'desc' => 'Select a layout for the More Footer Section. Depending on which layout you select will determine what kind of widget areas will be available.',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'type' => 'radio-image',\n\t\t\t\t\t'section' => 'footerdesign',\n\t\t\t\t\t'class' => '',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'full',\n\t\t\t\t\t\t\t'label' => 'Full',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/full.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '5050',\n\t\t\t\t\t\t\t'label' => '50 / 50',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/5050.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '25252525',\n\t\t\t\t\t\t\t'label' => '25 / 25 / 25 / 25',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/25252525.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '255025',\n\t\t\t\t\t\t\t'label' => '25 / 50 / 25',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/255025.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '252550',\n\t\t\t\t\t\t\t'label' => '25 / 25 / 50',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/252550.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '502525',\n\t\t\t\t\t\t\t'label' => '50 / 25 / 25',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/502525.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '333333',\n\t\t\t\t\t\t\t'label' => '33 / 33 / 33',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/333333.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '6633',\n\t\t\t\t\t\t\t'label' => '66 / 33',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/6633.jpg'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '3366',\n\t\t\t\t\t\t\t'label' => '33 / 66',\n\t\t\t\t\t\t\t'src'\t=> BSB_ROOT_PATH . '/option-tree/assets/images/3366.jpg'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id'\t\t=> 'blogsidebarposition',\n\t\t\t\t\t'label'\t\t=> 'Blog Sidebar Position',\n\t\t\t\t\t'desc'\t\t=> 'Select a position for the blog sidebar.',\n\t\t\t\t\t'type'\t\t=> 'radio',\n\t\t\t\t\t'section'\t=> 'blogdesign',\n\t\t\t\t\t'std'\t\t=> 'right',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t\t\t'label' => 'Right'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t\t\t'label' => 'Left'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id'\t\t=> 'blogsidebarcolumnwidth',\n\t\t\t\t\t'label'\t\t=> 'Blog Sidebar Column Width',\n\t\t\t\t\t'desc'\t\t=> 'Select a width for the blog sidebar. These widths are based off of Bootstraps 12 column grid system.',\n\t\t\t\t\t'type'\t\t=> 'radio',\n\t\t\t\t\t'std'\t\t=> '3',\n\t\t\t\t\t'section'\t=> 'blogdesign',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '3',\n\t\t\t\t\t\t\t'label' => '3 Column'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '4',\n\t\t\t\t\t\t\t'label' => '4 Column'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '5',\n\t\t\t\t\t\t\t'label' => '5 Column'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => '6',\n\t\t\t\t\t\t\t'label' => '6 Column'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id'\t\t=> 'blogarchiveitemtitle',\n\t\t\t\t\t'label'\t\t=> 'Blog Archive Item Title',\n\t\t\t\t\t'desc'\t\t=> 'This will determine the font to be used for the blog archive article headers.',\n\t\t\t\t\t'type'\t\t=> 'typography',\n\t\t\t\t\t'section'\t=> 'blogdesign'\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Archive Featured Image Size',\n\t\t\t\t\t'id' => 'archivefeaturedimagesize',\n\t\t\t\t\t'type' => 'measurement',\n\t\t\t\t\t'desc' => 'Determine the dimensions of the featured image in the archives page.',\n\t\t\t\t\t'section' => 'blogdesign',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'id'\t\t=> 'archivethumbnailposition',\n\t\t\t\t\t'label'\t\t=> 'Archive Thumbnail Position',\n\t\t\t\t\t'desc'\t\t=> 'Select a position for the archive thumbnail position.',\n\t\t\t\t\t'type'\t\t=> 'radio',\n\t\t\t\t\t'section'\t=> 'blogdesign',\n\t\t\t\t\t'std'\t\t=> 'right',\n\t\t\t\t\t'choices' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'right',\n\t\t\t\t\t\t\t'label' => 'Right'\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'value' => 'left',\n\t\t\t\t\t\t\t'label' => 'Left'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Comment Item Border Radius',\n\t\t\t\t\t'id' => 'commentitemborderradius',\n\t\t\t\t\t'type' => 'measurement',\n\t\t\t\t\t'desc' => 'The border radius of comment items.',\n\t\t\t\t\t'section' => 'blogdesign',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'label' => 'Comment Item Background Color',\n\t\t\t\t\t'id' => 'commentitembackgroundcolor',\n\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t'desc' => 'Comment item background color.',\n\t\t\t\t\t'section' => 'blogdesign'\n\t\t\t\t)\n\t\t\t)\n\t\t);\n\t\t\n\t\t/* settings are not the same update the DB */\n\t\tif ($saved_settings !== $custom_settings) {\n\t\t\tupdate_option('option_tree_settings', $custom_settings);\n\t\t}\n\t\t\n\t}", "public function flow_process_admin_options() {\r\n\r\n $hasFile = false;\r\n $nombrePlugin = basename(__DIR__);\r\n $idFileInput = \"woocommerce_\" . $this->id . \"_logo-small\";\r\n if (isset($_FILES[$idFileInput])) {\r\n $file = $_FILES[$idFileInput];\r\n $hasFile = $file['size']>0;\r\n if ($hasFile) {\r\n move_uploaded_file($file['tmp_name'], PLUGIN_DIR_flow.\"images/custom-logo-small.png\");\r\n }\r\n }\r\n\r\n $post_data = $this->get_post_data();\r\n $anyErrors = false;\r\n\r\n if(empty($post_data['woocommerce_'.$this->id.'_api_key'])){\r\n update_option('woocommerce_flow_api_key_valid', false);\r\n $anyErrors = true;\r\n }\r\n else{\r\n update_option('woocommerce_flow_api_key_valid', true);\r\n }\r\n\r\n if(empty($post_data['woocommerce_'.$this->id.'_secret_key'])){\r\n update_option('woocommerce_flow_secret_key_valid', false);\r\n $anyErrors = true;\r\n }\r\n else{\r\n update_option('woocommerce_flow_secret_key_valid', true);\r\n }\r\n\r\n if(!$anyErrors)\r\n $this->process_admin_options();\r\n\r\n return ;\r\n\r\n }", "function eazy_legal_opt_page() {\n\tadd_menu_page( 'Privacy & Cookies', 'Privacy & Cookies', 'manage_options', 'eazy_legal_options', 'eazy_legal_display_opt_page', 'dashicons-visibility', 100 );\n // Call register settings function\n add_action( 'admin_init', 'eazy_legal_register_options_settings' );\n}", "function eventspractice_options() {\n\n $options = array (\n 'Option 1' => 'A',\n 'Option 2' => 'B',\n 'Option 3' => 'C'\n );\n\n if ( !get_option( 'eventspractice_options' ) ){\n add_option( 'eventspractice_option', $options );\n }\n update_option( 'eventspractice_option', $options );\n\n\n // add_option( 'eventspractice_option', 'My NEW Plugin Options' );\n // update_option( 'eventspractice_option', 'This is a test with the Options API' );\n // delete_option( 'eventspractice_option' );\n\n}", "function update_sss_options() {\n\t$sss_options = get_option('sss_plugin_options');\n\tif(!$sss_options)\n\t\t$sss_options = array();\n\t\n\tif ($_POST['sss_set_max_width']) { \n\t\t$safe_val_max_width = intval(addslashes(strip_tags($_POST['sss_set_max_width'])));\n\t\t$sss_options['max_width'] = $safe_val_max_width;\n\t}\n\telse\n\t\t$sss_options['max_width'] = 560;\n\tif ($_POST['sss_start_showing_from']) { \n\t\t$safe_val_start_showing_from = intval(addslashes(strip_tags($_POST['sss_start_showing_from'])));\n\t\t$sss_options['start_showing_from'] = $safe_val_start_showing_from;\n\t}\n\telse\n\t\t$sss_options['start_showing_from'] = 6;\n\tif ($_POST['sss_twitter_name']) { \n\t\t$safe_val_twitter_name = addslashes(strip_tags($_POST['sss_twitter_name']));\n\t\t$sss_options['twitter_name'] = $safe_val_twitter_name;\n\t}\n\telse\n\t\t$sss_options['twitter_name'] = '';\n\tif ($_POST['sss_story_source']) { \n\t\t$safe_val_story_source = addslashes(strip_tags($_POST['sss_story_source']));\n\t\t$sss_options['story_source'] = $safe_val_story_source;\n\t}\n\telse\n\t\t$sss_options['story_source'] = get_bloginfo('name');\n\tif ($_POST['sss_show_where']) { \n\t\t$safe_val_show_where = addslashes(strip_tags($_POST['sss_show_where']));\n\t\t$sss_options['show_where'] = $safe_val_show_where;\n\t}\n\telse\n\t\t$sss_options['show_where'] = 'both';\n\t\t\n\t// button selection settings\n\tif ($buttons_arr = $_POST['sss_which_buttons']) {\n\t\t$sss_options['which_buttons'] = array();\n\t\tforeach ($buttons_arr as $btn) {\n\t\t\tarray_push($sss_options['which_buttons'], addslashes(strip_tags($btn)));\n\t\t}\n\t}\n\telse\n\t\t$sss_options['which_buttons'] = array();\n\t\n\t//excluding IDs\n\tif ($_POST['sss_exclude_ids']) { \n\t\t$safe_val_exclude_ids = addslashes(strip_tags(preg_replace('/\\s+/', '', $_POST['sss_exclude_ids'])));\n\t\t$sss_exclude_ids = array();\n\t\t$sss_exclude_ids_temp = explode(',', $safe_val_exclude_ids);\n\t\tforeach($sss_exclude_ids_temp as $single_id)\n\t\t\tif(strlen($single_id) > 0 && intval($single_id) > 0)\n\t\t\t\tarray_push($sss_exclude_ids, intval($single_id));\n\t\t$sss_options['exclude_ids'] = array_unique($sss_exclude_ids);\n\t}\n\telse\n\t\t$sss_options['exclude_ids'] = array();\n\t\n\tif (update_option('sss_plugin_options', $sss_options)) {\n\t\techo '<div id=\"message\" class=\"updated fade\">';\n\t\techo '<p>Updated!</p>';\n\t\techo '</div>';\n\t} /*else {\n\t\techo '<div id=\"message\" class=\"error fade\">';\n\t\techo '<p>Unable to update. My bad.</p>';\n\t\techo '</div>';\n\t}*/\n}", "function lg_mac_activ_options()\n\t{\n\t\t$theme_opts =get_option('lgmac_opts');\n\t\tif(!$theme_opts) //si le theme est désactivé et réactivé plus tard il ne sera pas nécessaire de reactiver le theme\n\t\t\t{\t\t\t//afin de créer l'option\n\t\t\t\t\n\t\t\t\t//\n\t\t\t\t$opts =array(\n\t\t\t\t'image_01_url' => '',\n\t\t\t\t'slider_shortcode' =>'',\n\t\t\t\t'HeaderC' =>'',\n\t\t\t\t'FooterColor'=>'',\n\t\t\t\t'FooterCopyright'=>'',\n\t\t\t\t'lgmac_img_FirstBlock'=>'',\n\t\t\t\t'lgmac_img_firstblock133'=>'',\n\n\n\t\t\t\t);\n\t\t\t\tadd_option('lgmac_opts',$opts);\n\t\t\t}\n\t}", "public function handle_post_action_options() {\n\t\tIggoGrid::check_nonce( 'options' );\n\n\t\tif ( ! current_user_can( 'iggogrid_access_options_screen' ) ) {\n\t\t\twp_die( __( 'You do not have sufficient permissions to access this page.', 'default' ) );\n\t\t}\n\n\t\tif ( empty( $_POST['options'] ) || ! is_array( $_POST['options'] ) ) {\n\t\t\tIggoGrid::redirect( array( 'action' => 'options', 'message' => 'error_save' ) );\n\t\t} else {\n\t\t\t$posted_options = wp_unslash( $_POST['options'] );\n\t\t}\n\n\t\t// Valid new options that will be merged into existing ones\n\t\t$new_options = array();\n\n\t\t// Check each posted option value, and (maybe) add it to the new options\n\t\tif ( ! empty( $posted_options['admin_menu_parent_page'] ) && '-' != $posted_options['admin_menu_parent_page'] ) {\n\t\t\t$new_options['admin_menu_parent_page'] = $posted_options['admin_menu_parent_page'];\n\t\t\t// re-init parent information, as IggoGrid::redirect() URL might be wrong otherwise\n\t\t\t/** This filter is documented in classes/class-controller.php */\n\t\t\t$this->parent_page = apply_filters( 'iggogrid_admin_menu_parent_page', $posted_options['admin_menu_parent_page'] );\n\t\t\t$this->is_top_level_page = in_array( $this->parent_page, array( 'top', 'middle', 'bottom' ), true );\n\t\t}\n\t\tif ( ! empty( $posted_options['plugin_language'] ) && '-' != $posted_options['plugin_language'] ) {\n\t\t\t// only allow \"auto\" language and all values that have a translation\n\t\t\tif ( 'auto' == $posted_options['plugin_language'] || array_key_exists( $posted_options['plugin_language'], $this->get_plugin_languages() ) ) {\n\t\t\t\t$new_options['plugin_language'] = $posted_options['plugin_language'];\n\t\t\t}\n\t\t}\n\n\t\t// Custom CSS can only be saved if the user is allowed to do so\n\t\t$update_custom_css_files = false;\n\t\tif ( current_user_can( 'iggogrid_edit_options' ) ) {\n\t\t\t// Checkbox\n\t\t\t$new_options['use_custom_css'] = ( isset( $posted_options['use_custom_css'] ) && 'true' === $posted_options['use_custom_css'] );\n\n\t\t\tif ( isset( $posted_options['custom_css'] ) ) {\n\t\t\t\t$new_options['custom_css'] = $posted_options['custom_css'];\n\n\t\t\t\t$iggogrid_css = IggoGrid::load_class( 'IggoGrid_CSS', 'class-css.php', 'classes' );\n\t\t\t\t$new_options['custom_css'] = $iggogrid_css->sanitize_css( $new_options['custom_css'] ); // Sanitize and tidy up Custom CSS\n\t\t\t\t$new_options['custom_css_minified'] = $iggogrid_css->minify_css( $new_options['custom_css'] ); // Minify Custom CSS\n\n\t\t\t\t// Maybe update CSS files as well\n\t\t\t\t$custom_css_file_contents = $iggogrid_css->load_custom_css_from_file( 'normal' );\n\t\t\t\tif ( false === $custom_css_file_contents ) {\n\t\t\t\t\t$custom_css_file_contents = '';\n\t\t\t\t}\n\t\t\t\tif ( $new_options['custom_css'] !== $custom_css_file_contents ) { // don't write to file if it already has the desired content\n\t\t\t\t\t$update_custom_css_files = true;\n\t\t\t\t\t// Set to false again. As it was set here, it will be set true again, if file saving succeeds\n\t\t\t\t\t$new_options['use_custom_css_file'] = false;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// save gathered new options (will be merged into existing ones), and flush caches of caching plugins, to make sure that the new Custom CSS is used\n\t\tif ( ! empty( $new_options ) ) {\n\t\t\tIggoGrid::$model_options->update( $new_options );\n\t\t\tIggoGrid::$model_table->_flush_caching_plugins_caches();\n\t\t}\n\n\t\tif ( $update_custom_css_files ) { // capability check is performed above\n\t\t\tIggoGrid::redirect( array( 'action' => 'options', 'item' => 'save_custom_css' ), true );\n\t\t}\n\n\t\tIggoGrid::redirect( array( 'action' => 'options', 'message' => 'success_save' ) );\n\t}", "function ffw_port_settings_sanitize( $input = array() ) {\n\n global $ffw_port_settings;\n\n parse_str( $_POST['_wp_http_referer'], $referrer );\n\n $output = array();\n $settings = ffw_port_get_registered_settings();\n $tab = isset( $referrer['tab'] ) ? $referrer['tab'] : 'general';\n $post_data = isset( $_POST[ 'ffw_port_settings_' . $tab ] ) ? $_POST[ 'ffw_port_settings_' . $tab ] : array();\n\n $input = apply_filters( 'ffw_port_settings_' . $tab . '_sanitize', $post_data );\n\n // Loop through each setting being saved and pass it through a sanitization filter\n foreach( $input as $key => $value ) {\n\n // Get the setting type (checkbox, select, etc)\n $type = isset( $settings[ $key ][ 'type' ] ) ? $settings[ $key ][ 'type' ] : false;\n\n if( $type ) {\n // Field type specific filter\n $output[ $key ] = apply_filters( 'ffw_port_settings_sanitize_' . $type, $value, $key );\n }\n\n // General filter\n $output[ $key ] = apply_filters( 'ffw_port_settings_sanitize', $value, $key );\n }\n\n\n // Loop through the whitelist and unset any that are empty for the tab being saved\n if( ! empty( $settings[ $tab ] ) ) {\n foreach( $settings[ $tab ] as $key => $value ) {\n\n // settings used to have numeric keys, now they have keys that match the option ID. This ensures both methods work\n if( is_numeric( $key ) ) {\n $key = $value['id'];\n }\n\n if( empty( $_POST[ 'ffw_port_settings_' . $tab ][ $key ] ) ) {\n unset( $ffw_port_settings[ $key ] );\n }\n\n }\n }\n\n // Merge our new settings with the existing\n $output = array_merge( $ffw_port_settings, $output );\n\n // @TODO: Get Notices Working in the backend.\n add_settings_error( 'ffw_port-notices', '', __( 'Settings Updated', 'ffw_port' ), 'updated' );\n\n return $output;\n\n}", "function theme_options_validate($input) {\n $options = get_option('theme_options');\n $options['theme-w3css'] = trim($input['theme-w3css']);\n // if (!preg_match('/^[a-z\\-]{32}$/i', $options['theme-w3css']) ) {\n // $options['theme-w3css'] = '';\n // }\n return $options;\n}", "function kleo_bp_page_options()\n {\n\n $current_page_id = kleo_bp_get_page_id();\n\n if (!$current_page_id) {\n return false;\n }\n\n $topbar_status = get_cfield('topbar_status', $current_page_id);\n //Top bar\n if (isset($topbar_status)) {\n if ($topbar_status === '1') {\n add_filter('kleo_show_top_bar', create_function('', 'return 1;'));\n } elseif ($topbar_status === '0') {\n add_filter('kleo_show_top_bar', create_function('', 'return 0;'));\n }\n }\n //Header and Footer settings\n if (get_cfield('hide_header', $current_page_id) == 1) {\n remove_action('kleo_header', 'kleo_show_header');\n }\n if (get_cfield('hide_footer', $current_page_id) == 1) {\n add_filter('kleo_footer_hidden', create_function('$status', 'return true;'));\n }\n if (get_cfield('hide_socket', $current_page_id) == 1) {\n remove_action('kleo_after_footer', 'kleo_show_socket');\n }\n\n //Custom logo\n if (get_cfield('logo', $current_page_id)) {\n global $kleo_custom_logo;\n $kleo_custom_logo = get_cfield('logo', $current_page_id);\n add_filter('kleo_logo', create_function(\"\", 'global $kleo_custom_logo; return $kleo_custom_logo;'));\n }\n\n //Transparent menu\n if (get_cfield('transparent_menu', $current_page_id)) {\n add_filter('body_class', create_function('$classes', '$classes[]=\"navbar-transparent\"; return $classes;'));\n }\n\n //Remove shop icon\n if (get_cfield('hide_shop_icon', $current_page_id) && get_cfield('hide_shop_icon', $current_page_id) == 1) {\n remove_filter('wp_nav_menu_items', 'kleo_woo_header_cart', 9);\n remove_filter('kleo_mobile_header_icons', 'kleo_woo_mobile_icon', 10);\n }\n //Remove search icon\n if (get_cfield('hide_search_icon', $current_page_id) && get_cfield('hide_search_icon', $current_page_id) == 1) {\n remove_filter('wp_nav_menu_items', 'kleo_search_menu_item', 10);\n }\n }", "function hestia_child_get_parent_options() {\r\n\t\t$hestia_mods = get_option( 'theme_mods_hestia-pro' );\r\n\t\t\tif ( ! empty( $hestia_mods ) ) {\r\n\t\t\t\t\t\tforeach ( $hestia_mods as $hestia_mod_k => $hestia_mod_v ) {\r\n\t\t\t\t\t\t\t\t\t\tset_theme_mod( $hestia_mod_k, $hestia_mod_v );\r\n\t\t\t\t\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t}\r\n}", "function load_plugin() {\n global $fb_opt_name, $gp_opt_name, $popup_fb_page, $popup_delay, $fb_popup_box;\n \n if(is_admin()&& get_option('Activated_Plugin')=='Plugin-Slug') {\n delete_option('Activated_Plugin');\n add_option($fb_opt_name,'on');\n add_option($gp_opt_name,'on');\n add_option($popup_fb_page,'codesamplez');\n add_option($popup_delay,'2');\n add_option($fb_popup_box,'on');\n }\n}", "function ci_cptr_plugin_options() {\n\t\n\tif ( !current_user_can('manage_options') )\n\t{\n\t\twp_die( __('You do not have sufficient permissions to access this page.') );\n\t}\n\t?>\n\t<div class=\"wrap\" id=\"cptr-options\">\n\t\t<!--<h2><?php echo sprintf(__('CSSIgniter Custom Post Types Relationships v%s - Settings', 'cptr'), CPTR_VERSION); ?></h2>-->\n\t\t<h2><?php echo sprintf(__('CSSIgniter Custom Post Types Relationships', 'cptr'), CPTR_VERSION); ?></h2>\n\t\t<p><?php _e(\"In this page you can define general options for the Custom Post Types Relationships plugin. All options here can be overridden manually by passing the appropriate parameters to the shortcode or the theme function. If you find yourself making changes here that don't have any effect, it's because your WordPress theme has hardcoded options for you, so check with the theme's developer.\", 'cptr'); ?></p>\n\t\t<p><?php echo sprintf(__('For complete usage instructions, please visit the <a href=\"%s\">plugin\\'s homepage</a>.', 'cptr'), 'http://www.cssigniter.com/ignite/custom-post-types-relationships/'); ?></p>\n\t\t<form method=\"post\" action=\"options.php\">\n\t\t\t<?php settings_fields('ci_cptr_plugin_settings'); ?>\n\t\n\t\t\t<?php\n\t\t\t\t$options = get_option(CI_CPTR_PLUGIN_OPTIONS);\n\t\t\t\t$options = ci_cptr_plugin_settings_validate($options);\n\t\t\t?>\n\n\t\t\t<table class=\"form-table\">\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Max number of displayed related posts:', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[limit]\" type=\"text\" value=\"<?php echo $options['limit']; ?>\" class=\"small-text\" />\n\t\t\t\t\t\t<p><?php _e('Set to 0 for no limit.', 'cptr'); ?></p>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Show the excerpt for each post?', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[excerpt]\" type=\"checkbox\" value=\"1\" <?php checked($options['excerpt'], 1); ?> />\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('How many words the excerpt should be?', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[words]\" type=\"text\" value=\"<?php echo $options['words']; ?>\" class=\"small-text\" />\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Display the thumbnail?', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[thumb]\" type=\"checkbox\" value=\"1\" <?php checked($options['thumb'], 1); ?> />\n\t\t\t\t\t\t<p><?php _e('The thumbnail will be displayed after the title and before the excerpt.', 'cptr'); ?></p>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Thumbnail size', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<label><?php _e('Width', 'cptr'); ?></label>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[width]\" type=\"text\" value=\"<?php echo $options['width']; ?>\" class=\"small-text\" />\n\t\t\t\t\t\t<label><?php _e('Height', 'cptr'); ?></label>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[height]\" type=\"text\" value=\"<?php echo $options['height']; ?>\" class=\"small-text\" />\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><h3><?php _e('Display Options', 'cptr'); ?></h3></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t&nbsp;\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Metabox title', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input name=\"<?php echo CI_CPTR_PLUGIN_OPTIONS; ?>[metabox_name]\" type=\"text\" value=\"<?php echo $options['metabox_name']; ?>\" class=\"regular-text\" />\n\t\t\t\t\t\t<p><?php _e('This is the title of the metabox that the users will see while in the post edit screens.', 'cptr'); ?></p>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Allowed roles', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<p><?php _e('Select the roles that will have access to the plugin (i.e. can create/delete relationships).', 'cptr'); ?></p>\n\t\t\t\t\t\t<fieldset class=\"allowed-roles\">\n\t\t\t\t\t\t\t<?php cptr_checkbox_roles(CI_CPTR_PLUGIN_OPTIONS.'[allowed_roles][]', $options['allowed_roles']); ?>\n\t\t\t\t\t\t</fieldset>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<tr valign=\"top\">\n\t\t\t\t\t<th scope=\"row\"><?php _e('Allowed post types', 'cptr'); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<p><?php _e('Select the post types that the plugin will be available to.', 'cptr'); ?></p>\n\t\t\t\t\t\t<fieldset class=\"allowed-post-types\">\n\t\t\t\t\t\t\t<?php cptr_checkbox_post_types(CI_CPTR_PLUGIN_OPTIONS.'[allowed_post_types][]', $options['allowed_post_types']); ?>\n\t\t\t\t\t\t</fieldset>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t</table>\n\t\n\t\t\t<p class=\"submit\">\n\t\t\t\t<input type=\"submit\" class=\"button-primary\" value=\"<?php _e('Save Changes') ?>\" />\n\t\t\t</p>\n\t\t</form>\n\t</div>\n\t\n\t<?php\n}", "function template_options()\n{\n\tglobal $context, $settings, $options, $scripturl, $txt;\n\n\t$context['theme_options'] = array(\n\t\tarray(\n\t\t\t'id' => 'show_board_desc',\n\t\t\t'label' => $txt['board_desc_inside'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'show_children',\n\t\t\t'label' => $txt['show_children'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'use_sidebar_menu',\n\t\t\t'label' => $txt['use_sidebar_menu'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'show_no_avatars',\n\t\t\t'label' => $txt['show_no_avatars'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'show_no_signatures',\n\t\t\t'label' => $txt['show_no_signatures'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'show_no_censored',\n\t\t\t'label' => $txt['show_no_censored'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'return_to_post',\n\t\t\t'label' => $txt['return_to_post'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'no_new_reply_warning',\n\t\t\t'label' => $txt['no_new_reply_warning'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'view_newest_first',\n\t\t\t'label' => $txt['recent_posts_at_top'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'view_newest_pm_first',\n\t\t\t'label' => $txt['recent_pms_at_top'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'posts_apply_ignore_list',\n\t\t\t'label' => $txt['posts_apply_ignore_list'],\n\t\t\t'default' => false,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'wysiwyg_default',\n\t\t\t'label' => $txt['wysiwyg_default'],\n\t\t\t'default' => false,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'popup_messages',\n\t\t\t'label' => $txt['popup_messages'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'copy_to_outbox',\n\t\t\t'label' => $txt['copy_to_outbox'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'pm_remove_inbox_label',\n\t\t\t'label' => $txt['pm_remove_inbox_label'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'auto_notify',\n\t\t\t'label' => $txt['auto_notify'],\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'topics_per_page',\n\t\t\t'label' => $txt['topics_per_page'],\n\t\t\t'options' => array(\n\t\t\t\t0 => $txt['per_page_default'],\n\t\t\t\t5 => 5,\n\t\t\t\t10 => 10,\n\t\t\t\t25 => 25,\n\t\t\t\t50 => 50,\n\t\t\t),\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'messages_per_page',\n\t\t\t'label' => $txt['messages_per_page'],\n\t\t\t'options' => array(\n\t\t\t\t0 => $txt['per_page_default'],\n\t\t\t\t5 => 5,\n\t\t\t\t10 => 10,\n\t\t\t\t25 => 25,\n\t\t\t\t50 => 50,\n\t\t\t),\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'calendar_start_day',\n\t\t\t'label' => $txt['calendar_start_day'],\n\t\t\t'options' => array(\n\t\t\t\t0 => $txt['days'][0],\n\t\t\t\t1 => $txt['days'][1],\n\t\t\t\t6 => $txt['days'][6],\n\t\t\t),\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'display_quick_reply',\n\t\t\t'label' => $txt['display_quick_reply'],\n\t\t\t'options' => array(\n\t\t\t\t0 => $txt['display_quick_reply1'],\n\t\t\t\t1 => $txt['display_quick_reply2'],\n\t\t\t\t2 => $txt['display_quick_reply3']\n\t\t\t),\n\t\t\t'default' => true,\n\t\t),\n\t\tarray(\n\t\t\t'id' => 'display_quick_mod',\n\t\t\t'label' => $txt['display_quick_mod'],\n\t\t\t'options' => array(\n\t\t\t\t0 => $txt['display_quick_mod_none'],\n\t\t\t\t1 => $txt['display_quick_mod_check'],\n\t\t\t\t2 => $txt['display_quick_mod_image'],\n\t\t\t),\n\t\t\t'default' => true,\n\t\t),\n\t);\n}", "static function get_options(){\n\t\t\t\tglobal $gdlr_core_item_pdb;\n\t\t\t\t\n\t\t\t\treturn array(\n\t\t\t\t\t'general' => array(\n\t\t\t\t\t\t'title' => esc_html__('General', 'goodlayers-core'),\n\t\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t\t'image' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Image', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'upload',\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'thumbnail-size' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Thumbnail Size', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'combobox',\n\t\t\t\t\t\t\t\t'options' => 'thumbnail-size',\n\t\t\t\t\t\t\t\t'default' => 'full'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'title' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Title', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t\t'default' => esc_html__('Promo Box Item Title', 'goodlayers-core'),\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'content' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Content', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'tinymce',\n\t\t\t\t\t\t\t\t'default' => esc_html__('Promo box item sample content', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'wrapper-class' => 'gdlr-core-fullsize'\n\t\t\t\t\t\t\t),\t\n\t\t\t\t\t\t\t'text-align' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Text Align', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'radioimage',\n\t\t\t\t\t\t\t\t'options' => 'text-align',\n\t\t\t\t\t\t\t\t'default' => 'center'\n\t\t\t\t\t\t\t),\t\t\t\t\t\n\t\t\t\t\t\t)\n\t\t\t\t\t),\n\t\t\t\t\t'frame' => array(\n\t\t\t\t\t\t'title' => esc_html__('Frame Style', 'goodlayers-core'),\n\t\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t\t'enable-frame' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Enable Frame', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t\t\t'default' => 'enable'\n\t\t\t\t\t\t\t), \n\t\t\t\t\t\t\t'enable-shadow' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Enable Shadow', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t\t\t'default' => 'enable',\n\t\t\t\t\t\t\t\t'condition' => array( 'enable-frame' => 'enable' )\n\t\t\t\t\t\t\t), \n\t\t\t\t\t\t\t'frame-padding' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Frame Padding', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'custom',\n\t\t\t\t\t\t\t\t'item-type' => 'padding',\n\t\t\t\t\t\t\t\t'data-input-type' => 'pixel',\n\t\t\t\t\t\t\t\t'default' => array( 'top'=>'30px', 'right'=>'30px', 'bottom'=>'10px', 'left'=>'30px', 'settings'=>'unlink' ),\n\t\t\t\t\t\t\t\t'condition' => array( 'enable-frame' => 'enable' )\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'frame-background-color' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Frame Background Color', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t\t\t'condition' => array( 'enable-frame' => 'enable' )\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'frame-border-width' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Frame Border Width', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'custom',\n\t\t\t\t\t\t\t\t'item-type' => 'padding',\n\t\t\t\t\t\t\t\t'data-input-type' => 'pixel',\n\t\t\t\t\t\t\t\t'default' => array( 'top'=>'0px', 'right'=>'1px', 'bottom'=>'1px', 'left'=>'1px', 'settings'=>'unlink' ),\n\t\t\t\t\t\t\t\t'condition' => array( 'enable-frame' => 'enable' )\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'frame-border-color' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Frame Border Color', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t\t\t'condition' => array( 'enable-frame' => 'enable' )\n\t\t\t\t\t\t\t), \n\t\t\t\t\t\t)\n\t\t\t\t\t),\n\t\t\t\t\t'typography' => array(\n\t\t\t\t\t\t'title' => esc_html__('Typography', 'goodlayers-core'),\n\t\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t\t'title-size' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Title Size', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'fontslider',\n\t\t\t\t\t\t\t\t'default' => '14px'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'content-size' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Content Size', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'fontslider',\n\t\t\t\t\t\t\t\t'default' => '14px'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t)\n\t\t\t\t\t),\n\t\t\t\t\t'color' => array(\n\t\t\t\t\t\t'title' => esc_html__('Color', 'goodlayers-core'),\n\t\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t\t'title-color' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Title Color', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'colorpicker'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'content-color' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Content Color', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'colorpicker'\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t\t),\n\t\t\t\t\t'spacing' => array(\n\t\t\t\t\t\t'title' => esc_html__('Spacing', 'goodlayers-core'),\n\t\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t\t'padding-bottom' => array(\n\t\t\t\t\t\t\t\t'title' => esc_html__('Padding Bottom ( Item )', 'goodlayers-core'),\n\t\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t\t'data-input-type' => 'pixel',\n\t\t\t\t\t\t\t\t'default' => $gdlr_core_item_pdb\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t}", "public function defineOptionsAlter(&$options) {\n // options_definition() doesn't work for display_extender plugins.\n // see http://drupal.org/node/681468#comment-4384814\n // and http://drupal.org/node/1616540\n //var_dump($this->config->options_definition());exit();\n // var_dump( $this->config->options_definition());\n // var_dump( $options);\n // exit('ici');\n // done in defineOptions\n // $options = array_merge($options, $this->config->options_definition());\n }", "function cinerama_edge_init_theme_options() {\n\t\tglobal $cinerama_edge_global_options;\n\t\tglobal $cinerama_edge_global_Framework;\n\t\tif ( isset( $cinerama_edge_global_options['reset_to_defaults'] ) ) {\n\t\t\tif ( $cinerama_edge_global_options['reset_to_defaults'] == 'yes' ) {\n\t\t\t\tdelete_option( \"edgtf_options_cinerama\" );\n\t\t\t}\n\t\t}\n\n\t\tif ( ! get_option( \"edgtf_options_cinerama\" ) ) {\n\t\t\tadd_option( \"edgtf_options_cinerama\", $cinerama_edge_global_Framework->edgtOptions->options );\n\n\t\t\t$cinerama_edge_global_options = $cinerama_edge_global_Framework->edgtOptions->options;\n\t\t}\n\t}", "function ahr_menu() {\r\n \r\n\tglobal $AHR_SLUG;\r\n\t\r\n add_options_page( 'Advanced Https Redirection', 'Advanced Https Redirection', 'manage_options', $AHR_SLUG, 'ahr_render_options_page' );\r\n \r\n}", "public function theme_options($options){\n\n\t\t$options[] = array(\n\t\t\t'name' => 'Legal Information',\n\t\t\t'desc' => '',\n\t\t\t'type' => 'info'\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Company Name', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_name]', 'waboot' ),\n\t\t\t'id' => $this->name.'_company_name',\n\t\t\t'std' => '',\n\t\t\t'type' => 'text'\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Company Address', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_address]', 'waboot' ),\n\t\t\t'id' => $this->name.'_address',\n\t\t\t'std' => '',\n\t\t\t'type' => 'text',\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Company Mail', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_mail]', 'waboot' ),\n\t\t\t'id' => $this->name.'_mail',\n\t\t\t'std' => '',\n\t\t\t'type' => 'text'\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Company Telephone', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_tel]', 'waboot' ),\n\t\t\t'id' => $this->name.'_tel',\n\t\t\t'std' => '',\n\t\t\t'type' => 'text'\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Domain Name', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_siteurl]', 'waboot' ),\n\t\t\t'id' => $this->name.'_siteurl',\n\t\t\t'std' => preg_replace('/http:\\/\\//', '', get_bloginfo('url') ),\n\t\t\t'type' => 'text'\n\t\t);\n\t\t$options[] = array(\n\t\t\t'name' => __( 'Legal Representative', 'waboot' ),\n\t\t\t'desc' => __( '[wb_legal_rep]', 'waboot' ),\n\t\t\t'id' => $this->name.'_rep',\n\t\t\t'std' => '',\n\t\t\t'type' => 'text'\n\t\t);\n\n\t\treturn $options;\n\t}", "function pu_theme_menu() {\n add_theme_page('Theme Option', 'Theme Options', 'manage_options', 'pu_theme_options.php', 'pu_theme_page');\n}", "function categ_url_hack_options() {\n\t\t $redirects = get_option('categ_url_hack');\n\n $categ_redirect = $redirects['categ'];\n\t\t $categ_url_url = $redirects['url'];\n \n $args = array(\n \t'hide_empty' => 0, \n \t'hierarchical' => 1, \n \t'name' => 'categ_url_hack[categ]',\n \t'id' => 'categ_redirect',\n \t'selected' => $categ_redirect,\n \t'show_option_none' => '-- ' . __('No redirect', 'categ_url_hack') . ' --'\n );\n ?>\n \n \n <div class=\"wrap\">\n <div id=\"icon-edit\" class=\"icon32\"></div>\n <h2><?php _e( 'Category redirect settings', 'categ_url_hack' ); ?></h2> \n <form method=\"post\" action=\"options-general.php?page=category-redirect\">\n <p><label for=\"categ_redirect\"><?php _e('Choose a category to redirect', 'categ_url_hack');?></label>&nbsp;<?php wp_dropdown_categories( $args ) ?></p>\n <p><label for=\"categ_url_url\"><?php _e(\"URL to redirect to:\", 'categ_url_hack' ); ?></label>&nbsp;<input type=\"text\" id=\"categ_url_url\" name=\"categ_url_hack[url]\" value=\"<?php echo $categ_url_url; ?>\" placeholder=\"<?php _e('Relative or Absolute URL', 'categ_url_hack' );?>\" size=\"20\">&nbsp;<?php _e(\"eg: /my-page or https://www.smol.org\" ); ?></p> \n \n <p class=\"submit\"><input type=\"submit\" name=\"submit_categ_url\" value=\"<?php _e('Save settings', 'categ_url_hack' ) ?>\" /></p>\n </form>\n </div>\n\t\t<?php\n\t\t}", "function optionsframework_option_name() {\r\n\r\n\t// This gets the theme name from the stylesheet\r\n\t$themename = wp_get_theme();\r\n\t$themename = preg_replace(\"/\\W/\", \"_\", strtolower( $themename ) );\r\n\r\n\t$optionsframework_settings = get_option( 'optionsframework' );\r\n\t$optionsframework_settings['id'] = $themename;\r\n\tupdate_option( 'optionsframework', $optionsframework_settings );\r\n\r\n}", "function create_theme_options_page() {\n global $lulisaurus_settings_page;\n\n $lulisaurus_settings_page = add_menu_page('Optionen', 'Optionen', 'read', 'lulisaurus_settings', 'build_options_page', 'dashicons-lightbulb');\n\n // Add contextual help\n add_action( 'load-' . $lulisaurus_settings_page, 'add_contextual_theme_help' );\n}", "function ilibrary_replace_menu_func() {\n add_options_page('Library Import', 'WP iLibrary', 'manage_options', basename(__FILE__), 'ilibrary_options_page');\n}", "function admin_zevioo_settings(){\n\tif ( isset( $_POST['fields_submitted'] ) && $_POST['fields_submitted'] == 'submitted' ) {\n\t\tforeach ( $_POST as $key => $value ) {\n\t\t\tif ( get_option( $key ) != $value ) {\n\t\t\t\tupdate_option( $key, $value );\n\t\t\t} else {\n\t\t\t\tadd_option( $key, $value, '', 'no' );\n\t\t\t}\n\t\t}\n\t}\n?>\n<style>table td p {padding:0px !important;} table.dymocheck{width:100%;border:1px solid #ccc !important;text-align:center;margin:0 0 20px 0}.dymocheck tr th{border-bottom:1px solid #ccc !important;background:#ccc;}</style>\n<div class=\"wrap\">\n\t<div id=\"icon-options-general\" class=\"icon32\"></div>\n\t<h2>Zevioo settings</h2>\n\t\n\t<?php if ( isset( $_POST['fields_submitted'] ) && $_POST['fields_submitted'] == 'submitted' ) { ?>\n\t<div id=\"message\" class=\"updated fade\"><p><strong>Your settings have been saved.</strong></p></div>\n\t<?php } \n\t?>\n\t\n\t<div id=\"content\">\n\t\t<form method=\"post\" action=\"\" id=\"settings\">\n\t\t\t<input type=\"hidden\" name=\"fields_submitted\" value=\"submitted\">\n\t\t\t<div id=\"poststuff\">\n\t\t\t\t<div style=\"float:left; width:80%; padding-right:1%;\">\n\t\t\t\t\t<div class=\"postbox\">\n\t\t\t\t\t\t<h3>Account Settings</h3>\n\t\t\t\t\t\t<div class=\"inside dymo-settings\">\n\t\t\t\t\t\t\t<table class=\"form-table\">\n\t\t\t\t\t\t\t\t<tr>\n \t\t\t\t\t\t\t\t<th>\n \t\t\t\t\t\t\t\t\t<label for=\"zevioo_username\"><b>Zevioo Username</b></label>\n \t\t\t\t\t\t\t\t</th>\n \t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"zevioo_username\" id=\"zevioo_username\" value=\"<?php echo get_option( 'zevioo_username' );?>\" size=\"40\"/>\n \t\t\t\t\t\t\t\t</td>\n \t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n \t\t\t\t\t\t\t\t<th>\n \t\t\t\t\t\t\t\t\t<label for=\"zevioo_password\"><b>Zevioo Password</b></label>\n \t\t\t\t\t\t\t\t</th>\n \t\t\t\t\t\t\t\t<td>\n\t\t\t\t\t\t\t\t\t\t<input type=\"text\" name=\"zevioo_password\" id=\"zevioo_password\" value=\"<?php echo get_option( 'zevioo_password' );?>\" size=\"40\"/>\n \t\t\t\t\t\t\t\t</td>\n \t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t\t<tr>\n\t\t\t\t\t\t\t\t\t<td colspan=2>\n\t\t\t\t\t\t\t\t\t\t<p class=\"submit\"><input type=\"submit\" name=\"Submit\" class=\"button-primary\" value=\"Save Changes\" /></p>\n\t\t\t\t\t\t\t\t\t</td>\n\t\t\t\t\t\t\t\t</tr>\n\t\t\t\t\t\t\t</table>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\n\t\t\t\t\t</div>\n\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</form>\n\t</div>\n</div>\n<?php \n}", "public function addAdminPage() {\n\t\t\t// global $themename, $shortname, $options;\n\t\t\tif ( current_user_can( 'edit_theme_options' ) && isset( $_GET['page'] ) && $_GET['page'] == basename(__FILE__) ) {\n\t\t\t\tif ( ! empty( $_REQUEST['save-theme-options-nonce'] ) && wp_verify_nonce( $_REQUEST['save-theme-options-nonce'], 'save-theme-options' ) && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'save' ) {\n\t\t\t\t\tforeach ($this->options as $value) {\n\t\t\t\t\t\tif ( array_key_exists('id', $value) ) {\n\t\t\t\t\t\t\tif ( isset( $_REQUEST[ $value['id'] ] ) ) {\n\t\t\t\t\t\t\t\tif (\n\t\t\t\t\t\t\t\t\tin_array(\n\t\t\t\t\t\t\t\t\t\t$value['id'],\n\t\t\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\t\t$this->shortname.'_background_color',\n\t\t\t\t\t\t\t\t\t\t\t$this->shortname.'_hover_color',\n\t\t\t\t\t\t\t\t\t\t\t$this->shortname.'_link_color',\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\t$opt_value = preg_match( '/^#([a-zA-Z0-9]){3}$|([a-zA-Z0-9]){6}$/', trim( $_REQUEST[ $value['id'] ] ) ) ? trim( $_REQUEST[ $value['id'] ] ) : '';\n\t\t\t\t\t\t\t\t\tupdate_option( $value['id'], $opt_value );\n\t\t\t\t\t\t\t\t} elseif (\n\t\t\t\t\t\t\t\t\tin_array(\n\t\t\t\t\t\t\t\t\t\t$value['id'],\n\t\t\t\t\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t\t\t\t$this->shortname.'_categories_to_exclude',\n\t\t\t\t\t\t\t\t\t\t\t$this->shortname.'_pages_to_exclude',\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t) {\n\t\t\t\t\t\t\t\t\t$opt_value = implode(',', array_filter( array_map( 'intval', explode(',', $_REQUEST[ $value['id'] ] ) ) ) );\n\t\t\t\t\t\t\t\t\tupdate_option( $value['id'], $opt_value );\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tupdate_option( $value['id'], stripslashes( $_REQUEST[ $value['id'] ] ) );\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tdelete_option( $value['id'] );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\twp_redirect(\"themes.php?page=\".basename(__FILE__).\"&saved=true\");\n\t\t\t\t\texit;\n\t\t\t\t} else if ( ! empty( $_REQUEST['reset-theme-options-nonce'] ) && wp_verify_nonce( $_REQUEST['reset-theme-options-nonce'], 'reset-theme-options' ) && isset( $_REQUEST['action'] ) && $_REQUEST['action'] == 'reset' ) {\n\t\t\t\t\tforeach ($this->options as $value) {\n\t\t\t\t\t\tif ( array_key_exists('id', $value) ) {\n\t\t\t\t\t\t\tdelete_option( $value['id'] );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\twp_redirect(\"themes.php?page=\".basename(__FILE__).\"&reset=true\");\n\t\t\t\t\texit;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tadd_theme_page(\n\t\t\t\t__( 'Theme Options' ),\n\t\t\t\t__( 'Theme Options' ),\n\t\t\t\t'edit_theme_options',\n\t\t\t\tbasename(__FILE__),\n\t\t\t\tarray(&$this, 'adminPage' )\n\t\t\t);\n\t\t}", "function optionsframework_options() {\n\t\t$options_pages = array(); \n\t\t$options_pages_obj = get_pages('sort_column=post_parent,menu_order');\n\t\t$options_pages[''] = 'Select a page:';\n\t\tforeach ($options_pages_obj as $page):\n\t\t\t$options_pages[$page->ID] = $page->post_title;\n\t\tendforeach;\n\t\n\t\t// If using image radio buttons, define a directory path\n\t\t$imagepath = get_template_directory_uri() . '/lib/assets/images/icons/';\n\t\n\t\t$options = array();\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('General Settings', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Favicon', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To upload your favicon to the site, simply add the URL to it or upload and select it using the Upload button here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_favicon',\n\t\t\t'type' \t\t=> 'upload');\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('RSS Link', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Add in the URL of your RSS feed here to overwrite the defaut WordPress ones.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_rss',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Custom CSS', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Not 100% happy with our lovely styles? Here you can add some custom CSS if you require minor changes to the ones we\\'ve created. We won\\'t be offended, honest :)', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_css',\n\t\t\t'type' \t\t=> 'textarea');\t\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Google Analytics (or custom Javascript)', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If you\\'re hooked up with Google Analytics you can paste the Javascript includes for it here (without the script tags). Or alternatively if you just want some custom Javascript added on top of ours, add that here too.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_js',\n\t\t\t'type' \t\t=> 'textarea');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Breadcrumb Trail?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the breadcrumb trail on all pages in the header.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_breadcrumbs',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Application Form ID', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_application_form_id',\n\t\t\t'desc'\t\t=> 'If you have added an applcation form for the jobs section of your site using the Contact Form & plugin, you can add the ID of the form here for it to be pulled out automatically.',\n\t\t\t'std' \t\t=> '',\n\t\t\t'type' \t\t=> 'text');\t\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Header', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Custom Logo', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To upload a custom logo, simply add the URL to it or upload and select it using the Upload button here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_logo',\n\t\t\t'type' \t\t=> 'upload');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Header Text', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_header_text',\n\t\t\t'des'\t\t=> 'You can add some text to the header if you like. Keep it short and sweet mind; nobody likes a waffler :)',\n\t\t\t'std' \t\t=> '',\n\t\t\t'type' \t\t=> 'text');\t\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Contact Telephone', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your contact telephone number here to go in the header.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_header_phone',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Footer', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __('Copyright Text', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the text for your copyright here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_footer_copyright',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Hide FrogsThemes Link?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will hide our link :\\'( <--sad face', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_hide_ft_link',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Blog', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Style', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Select if you prefer the blog to be as a list or in masonry.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_blog_style',\n\t\t\t'options' \t=> array('list' => __('List', 'frogsthemes'), 'masonry' => __('Masonry', 'frogsthemes')),\n\t\t\t'std'\t\t=> 'list',\n\t\t\t'type' \t\t=> 'select');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Share Links?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the share links on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_share_links',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Author Box?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the author box on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_author',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Next/Previous Links?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the next/previous post links on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_next_prev',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Related Posts?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the related posts section. These are related by tag.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_related_posts',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Slider', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Speed of Transition', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the speed you would like the transition to be in milliseconds (1000 = 1 second).', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_speed',\n\t\t\t'std'\t\t=> '600',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Pause Time', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the time you would like the gallery to pause between transitions in milliseconds (1000 = 1 second).', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_pause',\n\t\t\t'std'\t\t=> '7000',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Auto Start?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will automatically start the gallery.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_auto_start',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Auto Loop?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will automatically loop through the gallery.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_loop',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t/*\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Animation Type', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Select which effect you would like to use when going between slides.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_transition',\n\t\t\t'options' \t=> array('fade' => __('Fade', 'frogsthemes'), 'slide' => __('Slide', 'frogsthemes')),\n\t\t\t'std'\t\t=> 'fade',\n\t\t\t'type' \t\t=> 'select');\n\t\t*/\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Connections', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Facebook URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Facebook URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_facebook',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Twitter URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Twitter URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_twitter',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Google+ URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Google+ URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_google_plus',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'LinkedIn URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full LinkedIn URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_linkedin',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Pinterest URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Pinterest URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_pinterest',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'YouTube URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full YouTube URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_youtube',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Twitter API Options', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Twitter API', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To use the Twitter API, you need to sign up for an <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">app with Twitter</a>.', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'info');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Consumer Key', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'consumer_key',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Consumer Secret', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'consumer_secret',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Access Token', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'access_token',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Access Token Secret', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'access_token_secret',\n\t\t\t'type' \t\t=> 'text');\n\t\n\t\treturn apply_filters('optionsframework_options', $options);\n\t}", "function kt_action_theme_include_custom_option_types() {\n if (is_admin()) {\n require_once get_stylesheet_directory() . '/framework-customizations/includes/option-types/new-icon/class-fw-option-type-new-icon.php';\n\t\trequire_once get_stylesheet_directory() . '/framework-customizations/includes/option-types/custom-multi-select/class-fw-option-type-custom-multi-select.php';\n // and all other option types\n }\n}", "function beaver_extender_custom_options() {\n\t\n\t$custom_functions = get_option( 'beaver_extender_custom_functions' );\n\t$custom_js = get_option( 'beaver_extender_custom_js' );\n\t$custom_templates = beaver_extender_get_templates();\n\t$custom_labels = beaver_extender_get_labels();\n\t$custom_conditionals = beaver_extender_get_conditionals();\n\t$custom_widgets = beaver_extender_get_widgets();\n\t$custom_hooks = beaver_extender_get_hooks();\n?>\n\t<div class=\"wrap\">\n\t\t\n\t\t<div id=\"beaver-extender-custom-saved\" class=\"beaver-extender-update-box\"></div>\n\n\t\t<?php\n\t\tif ( ! empty( $_POST['action'] ) && $_POST['action'] == 'reset' ) {\n\t\t\t\n\t\t\tbeaver_extender_reset_delete_template();\n\t\t\tupdate_option( 'beaver_extender_custom_css', beaver_extender_custom_css_options_defaults() );\n\t\t\tupdate_option( 'beaver_extender_custom_functions', beaver_extender_custom_functions_options_defaults() );\n\t\t\tupdate_option( 'beaver_extender_custom_js', beaver_extender_custom_js_options_defaults() );\n\t\t\tupdate_option( 'beaver_extender_custom_templates', array() );\n\t\t\tupdate_option( 'beaver_extender_custom_labels', array() );\n\t\t\tupdate_option( 'beaver_extender_custom_conditionals', array() );\n\t\t\tupdate_option( 'beaver_extender_custom_widget_areas', array() );\n\t\t\tupdate_option( 'beaver_extender_custom_hook_boxes', array() );\n\n\t\t\tbeaver_extender_get_custom_css( null, $args = array( 'cached' => false, 'array' => false ) );\n\t\t\t$custom_functions = get_option( 'beaver_extender_custom_functions' );\n\t\t\t$custom_js = get_option( 'beaver_extender_custom_js' );\n\t\t\t$custom_templates = beaver_extender_get_templates();\n\t\t\t$custom_labels = beaver_extender_get_labels();\n\t\t\t$custom_conditionals = beaver_extender_get_conditionals();\n\t\t\t$custom_widgets = beaver_extender_get_widgets();\n\t\t\t$custom_hooks = beaver_extender_get_hooks();\n\n\t\t\tbeaver_extender_write_files( $css = true );\n\t\t?>\n\t\t\t<script type=\"text/javascript\">jQuery(document).ready(function($){ $('#beaver-extender-custom-saved').html('Custom Options Reset').css(\"position\", \"fixed\").fadeIn('slow');window.setTimeout(function(){$('#beaver-extender-custom-saved').fadeOut( 'slow' );}, 2222); });</script>\n\t\t<?php\n\t\t}\n\n\t\tif ( ! empty( $_GET['activetab'] ) ) { ?>\n\t\t\t<script type=\"text/javascript\">jQuery(document).ready(function($) { $('#<?php echo $_GET['activetab']; ?>').click(); });</script>\t\n\t\t<?php\n\t\t} ?>\n\t\t\n\t\t<div id=\"icon-options-general\" class=\"icon32\"></div>\n\t\t\n\t\t<h2 id=\"beaver-extender-admin-heading\"><?php _e( 'Extender - Custom Options', 'extender' ); ?></h2>\n\t\t\n\t\t<div class=\"beaver-extender-css-builder-button-wrap\">\n\t\t\t<span id=\"show-hide-custom-css-builder\" class=\"button\"><?php _e( 'CSS Builder', 'extender' ); ?></span>\n\t\t</div>\n\n\t\t<div class=\"beaver-extender-php-builder-button-wrap\">\n\t\t\t<span id=\"show-hide-custom-php-builder\" class=\"button\"><?php _e( 'PHP Builder', 'extender' ); ?></span>\n\t\t</div>\n\t\t\n\t\t<div id=\"beaver-extender-admin-wrap\">\n\t\t\n\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-css-builder.php' ); ?>\n\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-php-builder.php' ); ?>\n\t\t\t\n\t\t\t<form action=\"/\" id=\"custom-options-form\" name=\"custom-options-form\">\n\t\t\t\n\t\t\t\t<input type=\"hidden\" name=\"action\" value=\"beaver_extender_custom_options_save\" />\n\t\t\t\t<input type=\"hidden\" name=\"security\" value=\"<?php echo wp_create_nonce( 'custom-options' ); ?>\" />\n\t\t\t\n\t\t\t\t<div id=\"beaver-extender-floating-save\">\n\t\t\t\t\t<input type=\"submit\" value=\"<?php _e( 'Save Changes', 'extender' ); ?>\" name=\"Submit\" alt=\"Save Changes\" class=\"beaver-extender-save-button button button-primary\"/>\n\t\t\t\t\t<img class=\"beaver-extender-ajax-save-spinner\" src=\"<?php echo site_url() . '/wp-admin/images/spinner-2x.gif'; ?>\" />\n\t\t\t\t\t<span class=\"beaver-extender-saved\"></span>\n\t\t\t\t</div>\n\t\t\t\t\t\n\t\t\t\t<div id=\"beaver-extender-custom-options-nav\" class=\"beaver-extender-admin-nav\">\n\t\t\t\t\t<ul>\n\t\t\t\t\t\t<li id=\"beaver-extender-custom-options-nav-css\" class=\"beaver-extender-options-nav-all beaver-extender-options-nav-active\"><a href=\"#\">CSS</a></li><li id=\"beaver-extender-custom-options-nav-functions\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">Functions</a></li><li id=\"beaver-extender-custom-options-nav-js\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">JS</a></li><li id=\"beaver-extender-custom-options-nav-templates\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">Templates</a></li><li id=\"beaver-extender-custom-options-nav-labels\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">Labels</a></li><li id=\"beaver-extender-custom-options-nav-conditionals\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">Conditionals</a></li><li id=\"beaver-extender-custom-options-nav-widget-areas\" class=\"beaver-extender-options-nav-all\"><a href=\"#\">Widget Areas</a></li><li id=\"beaver-extender-custom-options-nav-hook-boxes\" class=\"beaver-extender-options-nav-all\"><a class=\"beaver-extender-options-nav-last\" href=\"#\">Hook Boxes</a></li>\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\t\t\t\t\n\t\t\t\t<div class=\"beaver-extender-custom-options-wrap\">\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-css.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-functions.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-js.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-templates.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-labels.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-conditionals.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-widget-areas.php' ); ?>\n\t\t\t\t\t<?php require_once( BBEXT_PATH . 'lib/admin/boxes/custom-hook-boxes.php' ); ?>\n\t\t\t\t</div>\n\t\t\t\n\t\t\t</form>\n\n\t\t\t<div id=\"beaver-extender-admin-footer\">\n\t\t\t\t<p>\n\t\t\t\t\t<a href=\"https://cobaltapps.com\" target=\"_blank\">CobaltApps.com</a> | <a href=\"http://extenderdocs.cobaltapps.com/\" target=\"_blank\">Docs</a> | <a href=\"https://cobaltapps.com/my-account/\" target=\"_blank\">My Account</a> | <a href=\"https://cobaltapps.com/forum/\" target=\"_blank\">Community Forum</a> | <a href=\"https://cobaltapps.com/affiliates/\" target=\"_blank\">Affiliates</a> &middot;\n\t\t\t\t\t<a><span id=\"show-options-reset\" class=\"beaver-extender-options-reset-button button\" style=\"margin:0; float:none !important;\"><?php _e( 'Custom Options Reset', 'extender' ); ?></span></a><a href=\"http://extenderdocs.cobaltapps.com/article/156-custom-options-reset\" class=\"tooltip-mark\" target=\"_blank\">[?]</a>\n\t\t\t\t</p>\n\t\t\t</div>\n\t\t\t\n\t\t\t<div style=\"display:none; width:160px; border:none; background:none; margin:0 auto; padding:0; float:none; position:inherit;\" id=\"show-options-reset-box\" class=\"beaver-extender-custom-fonts-box\">\n\t\t\t\t<form style=\"float:left;\" id=\"beaver-extender-reset-custom-options\" method=\"post\">\n\t\t\t\t\t<input style=\"background:#D54E21; width:160px !important; color:#FFFFFF !important; -webkit-box-shadow:none; box-shadow:none;\" type=\"submit\" value=\"<?php _e( 'Reset Custom Options', 'extender' ); ?>\" class=\"beaver-extender-reset button\" name=\"Submit\" onClick='return confirm(\"<?php _e( 'Are you sure your want to reset your Beaver Extender Custom Options?', 'extender' ); ?>\")'/><input type=\"hidden\" name=\"action\" value=\"reset\" />\n\t\t\t\t</form>\n\t\t\t</div>\n\t\t</div>\n\t</div> <!-- Close Wrap -->\n<?php\n}", "function setup_framework_options(){\n$args = array();\n\n//Set it to dev mode to view the class settings/info in the form - default is false\n$args['dev_mode'] = false;\n\n//google api key MUST BE DEFINED IF YOU WANT TO USE GOOGLE WEBFONTS\n//$args['google_api_key'] = '***';\n\n//Remove the default stylesheet? make sure you enqueue another one all the page will look whack!\n//$args['stylesheet_override'] = true;\n\n//Choose to disable the import/export feature\n$args['show_import_export'] = false;\n\n//Choose a custom option name for your theme options, the default is the theme name in lowercase with spaces replaced by underscores\n$args['opt_name'] = 'paraiso_linux';\n\n//Custom menu icon\n//$args['menu_icon'] = '';\n\n//Custom menu title for options page - default is \"Options\"\n$args['menu_title'] = __('Opciones del tema', 'nhp-opts');\n\n//Custom Page Title for options page - default is \"Options\"\n$args['page_title'] = __('Opciones del theme de Paraiso Linux', 'nhp-opts');\n\n//Custom page slug for options page (wp-admin/themes.php?page=***) - default is \"nhp_theme_options\"\n$args['page_slug'] = 'pl_theme_options';\n\n//Custom page capability - default is set to \"manage_options\"\n//$args['page_cap'] = 'manage_options';\n\n//page type - \"menu\" (adds a top menu section) or \"submenu\" (adds a submenu) - default is set to \"menu\"\n//$args['page_type'] = 'submenu';\n\n//parent menu - default is set to \"themes.php\" (Appearance)\n//the list of available parent menus is available here: http://codex.wordpress.org/Function_Reference/add_submenu_page#Parameters\n//$args['page_parent'] = 'themes.php';\n\n//custom page location - default 100 - must be unique or will override other items\n$args['page_position'] = 27;\n\n//Custom page icon class (used to override the page icon next to heading)\n//$args['page_icon'] = 'icon-themes';\n\n//Want to disable the sections showing as a submenu in the admin? uncomment this line\n//$args['allow_sub_menu'] = false;\n\t\t\n//Set the Help Sidebar for the options page - no sidebar by default\t\t\t\t\t\t\t\t\t\t\n$args['help_sidebar'] = __('<p>This is the sidebar content, HTML is allowed.</p>', 'nhp-opts');\n\n\n\n$sections = array();\n\t\t\t\t\n$sections[] = array(\n\t\t\t\t'icon' => NHP_OPTIONS_URL.'img/glyphicons/glyphicons_107_text_resize.png',\n\t\t\t\t'title' => __('Adsense', 'nhp-opts'),\n\t\t\t\t'desc' => __('<p class=\"description\">Bloques de adsense</p>', 'nhp-opts'),\n\t\t\t\t'fields' => array(\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'id' => 'adsense-bloque-superior',\n\t\t\t\t\t\t'type' => 'textarea',\n\t\t\t\t\t\t'title' => __('Bloque superior', 'nhp-opts'), \n\t\t\t\t\t\t'sub_desc' => __('HTML Allowed (wp_kses)', 'nhp-opts')\t\n\t\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'id' => 'adsense-bloque-inferior',\n\t\t\t\t\t\t'type' => 'textarea',\n\t\t\t\t\t\t'title' => __('Bloque inferior', 'nhp-opts'), \n\t\t\t\t\t\t'sub_desc' => __('HTML Allowed (wp_kses)', 'nhp-opts')\n\t\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'id' => 'adsense-analytics',\n\t\t\t\t\t\t'type' => 'textarea',\n\t\t\t\t\t\t'title' => __('Analytics', 'nhp-opts'), \n\t\t\t\t\t\t'sub_desc' => __('HTML Allowed (wp_kses)', 'nhp-opts')\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t);\t\t\t\t\n\t\t\t\t\n\t$tabs = array();\n\t\t\t\n\t\n\tif(file_exists(trailingslashit(get_stylesheet_directory()).'README.html')){\n\t\t$tabs['theme_docs'] = array(\n\t\t\t\t\t\t'icon' => NHP_OPTIONS_URL.'img/glyphicons/glyphicons_071_book.png',\n\t\t\t\t\t\t'title' => __('Documentation', 'nhp-opts'),\n\t\t\t\t\t\t'content' => nl2br(file_get_contents(trailingslashit(get_stylesheet_directory()).'README.html'))\n\t\t\t\t\t\t);\n\t}//if\n\n\tglobal $NHP_Options;\n\t$NHP_Options = new NHP_Options($sections, $args, $tabs);\n\n}", "function pbi_setting_theme_w3css() {\n $themes = array('indigo','dark-grey','brown','blue-grey','deep-purple','blue'\n ,'teal','red','deep-orange','pink','light-blue','green','purple','cyan'\n ,'light-green','lime','khaki','yellow','amber','orange','grey','black','w3school');\n $options = get_option('theme_options');\n echo '<select id=\"theme-w3css\" name=\"theme_options[theme-w3css]\">';\n foreach ($themes as $theme) {\n echo '<option value=\"'.$theme.'\"'\n .($theme==$options[\"theme-w3css\"] ? \" selected\" : \"\")\n .'>'.$theme.'</option>';\n }\n // echo \"<input id='theme-w3css' name='theme_options[theme-w3css]' size='40' type='text' value='{$options['theme-w3css']}' />\";\n}", "function set_gtpressMenu_options() {\r\n\tadd_option('gtpressMenu_default_menu');\r\n\tadd_option('gtpressMenu_default_submenu');\r\n\tadd_option('gtpressMenu_disabled_menu_items');\r\n\tadd_option('gtpressMenu_disabled_submenu_items');\r\n\tadd_option('gtpressMenu_disabled_metas');\r\n\tadd_option('gtpressMenu_admins_see_everything');\r\n\r\n\tupdate_option('gtpressMenu_disabled_menu_items', array());\r\n\tupdate_option('gtpressMenu_disabled_submenu_items', array());\r\n\tupdate_option('gtpressMenu_disabled_metas', array());\r\n\tupdate_option('gtpressMenu_admins_see_everything', false);\r\n}", "function lb_woo_options_add() {\r\n if(is_admin()) {\r\n global $woo_options;\r\n//pr($woo_options);\r\n if(is_array($woo_options)) {\r\n\r\n $shortname = 'woo';\r\n $i = 0;\r\n $array = array();\r\n\r\n \r\n while(list($key, $value) = each($woo_options)) {\r\n if($value['name'] == __( 'Disable Archive Header RSS link', 'woothemes' )) {\r\n $array[$i] = $value;\r\n $i++;\r\n\r\n $array[$i] = array( \"name\" => __( 'Archive Page Layout', 'woothemes' ),\r\n \"desc\" => __( 'Select main content and sidebar alignment for archive pages. Choose between 1, 2 or 3 column layout.', 'woothemes' ),\r\n \"id\" => $shortname . \"_wc_archive_layout\",\r\n \"std\" => \"two-col-left\",\r\n \"type\" => \"images\",\r\n \"options\" => array(\r\n 'one-col' => $images_dir . '1c.png',\r\n 'two-col-left' => $images_dir . '2cl.png',\r\n 'two-col-right' => $images_dir . '2cr.png',\r\n 'three-col-left' => $images_dir . '3cl.png',\r\n 'three-col-middle' => $images_dir . '3cm.png',\r\n 'three-col-right' => $images_dir . '3cr.png')\r\n );\r\n } else {\r\n $array[$i] = $value;\r\n }\r\n\r\n $i++;\r\n }\r\n }\r\n \r\n $woo_options = $array;\r\n }\r\n}", "public function manage_admin_menu_options() {\n\n global $submenu;\n\n remove_meta_box(\"dashboard_primary\", \"dashboard\", \"side\"); // WordPress.com blog\n remove_meta_box(\"dashboard_secondary\", \"dashboard\", \"side\"); // Other WordPress news\n add_post_type_support('prompts', 'comments');\n remove_menu_page('index.php'); // Remove the dashboard link from the Wordpress sidebar.\n remove_menu_page('edit.php'); // remove default post type.\n remove_menu_page('edit.php?post_type=page'); // remove default page type.\n remove_menu_page('upload.php'); // remove default post type.\n\n add_menu_page('artworks', 'Artworks', 'manage_options', 'edit-tags.php?taxonomy=artworks&post_type=prompts', '', 'dashicons-format-image', 5);\n\n if ( !current_user_can( 'administrator' ) ) {\n\n if ( isset( $submenu['themes.php']) ) {\n foreach ($submenu['themes.php'] as $key => $menu_item ) {\n if ( in_array('Customize', $menu_item ) ) {\n unset( $submenu['themes.php'][$key] );\n }\n if ( in_array('Themes', $menu_item ) ) {\n unset( $submenu['themes.php'][$key] );\n }\n }\n }\n\n }\n\n }", "function add_option_update_handler($option_group, $option_name, $sanitize_callback = '')\n {\n }", "function storms_define_relevanssi_options() {\n\t\t\tif ( ! current_user_can( 'manage_options' ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tupdate_option( 'relevanssi_index_post_types', array( 'product', 'product_variation', /* 'post', 'page' */ ) );\n\t\t\tupdate_option( 'relevanssi_index_taxonomies_list', array( 'product_cat', 'product_tag' ) );\n\t\t\tupdate_option( 'relevanssi_index_fields', '_sku, _product_attributes' );\n\t\t\tupdate_option( 'relevanssi_index_author', 'off' );\n\t\t\tupdate_option( 'relevanssi_index_excerpt', 'on' );\n\t\t\tupdate_option( 'relevanssi_punctuation', array( 'quotes' => 'replace', 'hyphens' => 'replace', 'ampersands' => 'replace', 'decimals' => 'remove', ) );\n\t\t\tupdate_option( 'relevanssi_post_type_weights', array( 'post_tag' => 1, 'category' => 1, ) );\n\t\t\tupdate_option( 'relevanssi_log_queries', 'on' );\n\t\t\tupdate_option( 'relevanssi_log_queries_with_ip', 'on' );\n\t\t\tupdate_option( 'relevanssi_trim_logs', 90 );\n\t\t\tupdate_option( 'relevanssi_excerpts', 'off' );\n\t\t\tupdate_option( 'relevanssi_expand_shortcodes', 'off' );\n\t\t\tupdate_option( 'relevanssi_log_queries_with_ip', 'off' );\n\t\t}", "function wwm_2015_optionsframework_option_name() {\r\n\r\n\t// This gets the theme name from the stylesheet (lowercase and without spaces)\r\n\t$themename = get_option( 'stylesheet' );\r\n\t$themename = preg_replace(\"/\\W/\", \"_\", strtolower($themename) );\r\n\r\n\t$optionsframework_settings = get_option('optionsframework');\r\n\t$optionsframework_settings['id'] = $themename;\r\n\tupdate_option('optionsframework', $optionsframework_settings);\r\n\r\n}", "function theme_options_do_page() {\n\tglobal $select_options, $radio_options;\n\n\tif ( ! isset( $_REQUEST['settings-updated'] ) )\n\t\t$_REQUEST['settings-updated'] = false;\n\n\t?>\n\t<div class=\"wrap\">\n\t\t<?php screen_icon(); echo \"<h2>\" . get_current_theme() . ' -- ' . __( 'Theme Options', 'htmlks4wp' ) . \"</h2>\"; ?>\n\n\t\t<?php if ( false !== $_REQUEST['settings-updated'] ) : ?>\n\t\t<div class=\"updated fade\"><p><strong><?php _e( 'Options saved', 'htmlks4wp' ); ?></strong></p></div>\n\t\t<?php endif; ?>\n\n\t\t<form method=\"post\" action=\"options.php\">\n\t\t\t<?php settings_fields( 'htmlks4wp_options' ); ?>\n\t\t\t<?php $options = get_option( 'htmlks4wp_theme_options' ); ?>\n\n\t\t\t<table class=\"form-table\">\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * [header] Google analytics code\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\"><th scope=\"row\"><?php _e( '[header] Google analytics code', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input id=\"htmlks4wp_theme_options[gacode]\" class=\"regular-text\" type=\"text\" name=\"htmlks4wp_theme_options[gacode]\" value=\"<?php esc_attr_e( $options['gacode'] ); ?>\" />\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[gacode]\"><?php _e( '(e.g. \"UA-5668xxxx-1\", etc.)', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * [footer] Year(s) in the copyright\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\"><th scope=\"row\"><?php _e( '[footer] Year(s) in the copyright', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input id=\"htmlks4wp_theme_options[copyrightyear]\" class=\"regular-text\" type=\"text\" name=\"htmlks4wp_theme_options[copyrightyear]\" value=\"<?php esc_attr_e( $options['copyrightyear'] ); ?>\" />\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[copyrightyear]\"><?php _e( '(e.g. \"2015\", \"2010-2015\", etc.)', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * [footer] Sitename in the copyright\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\"><th scope=\"row\"><?php _e( '[footer] Sitename in the copyright', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input id=\"htmlks4wp_theme_options[copyrightname]\" class=\"regular-text\" type=\"text\" name=\"htmlks4wp_theme_options[copyrightname]\" value=\"<?php esc_attr_e( $options['copyrightname'] ); ?>\" />\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[copyrightname]\"><?php _e( 'Your sitename', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * A sample checkbox option\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\" style=\"display: none;\"><th scope=\"row\"><?php _e( 'A checkbox', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input id=\"htmlks4wp_theme_options[option1]\" name=\"htmlks4wp_theme_options[option1]\" type=\"checkbox\" value=\"1\" <?php checked( '1', $options['option1'] ); ?> />\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[option1]\"><?php _e( 'Sample checkbox', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * A sample text input option\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\" style=\"display: none;\"><th scope=\"row\"><?php _e( 'Some text', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<input id=\"htmlks4wp_theme_options[sometext]\" class=\"regular-text\" type=\"text\" name=\"htmlks4wp_theme_options[sometext]\" value=\"<?php esc_attr_e( $options['sometext'] ); ?>\" />\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[sometext]\"><?php _e( 'Sample text input', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * A sample select input option\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\" style=\"display: none;\"><th scope=\"row\"><?php _e( 'Select input', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<select name=\"htmlks4wp_theme_options[selectinput]\">\n\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t\t$selected = $options['selectinput'];\n\t\t\t\t\t\t\t\t$p = '';\n\t\t\t\t\t\t\t\t$r = '';\n\n\t\t\t\t\t\t\t\tforeach ( $select_options as $option ) {\n\t\t\t\t\t\t\t\t\t$label = $option['label'];\n\t\t\t\t\t\t\t\t\tif ( $selected == $option['value'] ) // Make default first in list\n\t\t\t\t\t\t\t\t\t\t$p = \"\\n\\t<option style=\\\"padding-right: 10px;\\\" selected='selected' value='\" . esc_attr( $option['value'] ) . \"'>$label</option>\";\n\t\t\t\t\t\t\t\t\telse\n\t\t\t\t\t\t\t\t\t\t$r .= \"\\n\\t<option style=\\\"padding-right: 10px;\\\" value='\" . esc_attr( $option['value'] ) . \"'>$label</option>\";\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\techo $p . $r;\n\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t</select>\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[selectinput]\"><?php _e( 'Sample select input', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * A sample of radio buttons\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\" style=\"display: none;\"><th scope=\"row\"><?php _e( 'Radio buttons', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<fieldset><legend class=\"screen-reader-text\"><span><?php _e( 'Radio buttons', 'htmlks4wp' ); ?></span></legend>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tif ( ! isset( $checked ) )\n\t\t\t\t\t\t\t\t$checked = '';\n\t\t\t\t\t\t\tforeach ( $radio_options as $option ) {\n\t\t\t\t\t\t\t\t$radio_setting = $options['radioinput'];\n\n\t\t\t\t\t\t\t\tif ( '' != $radio_setting ) {\n\t\t\t\t\t\t\t\t\tif ( $options['radioinput'] == $option['value'] ) {\n\t\t\t\t\t\t\t\t\t\t$checked = \"checked=\\\"checked\\\"\";\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t$checked = '';\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t?>\n\t\t\t\t\t\t\t\t<label class=\"description\"><input type=\"radio\" name=\"htmlks4wp_theme_options[radioinput]\" value=\"<?php esc_attr_e( $option['value'] ); ?>\" <?php echo $checked; ?> /> <?php echo $option['label']; ?></label><br />\n\t\t\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t?>\n\t\t\t\t\t\t</fieldset>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\n\t\t\t\t<?php\n\t\t\t\t/**\n\t\t\t\t * A sample textarea option\n\t\t\t\t */\n\t\t\t\t?>\n\t\t\t\t<tr valign=\"top\" style=\"display: none;\"><th scope=\"row\"><?php _e( 'A textbox', 'htmlks4wp' ); ?></th>\n\t\t\t\t\t<td>\n\t\t\t\t\t\t<textarea id=\"htmlks4wp_theme_options[sometextarea]\" class=\"large-text\" cols=\"50\" rows=\"10\" name=\"htmlks4wp_theme_options[sometextarea]\"><?php echo esc_textarea( $options['sometextarea'] ); ?></textarea>\n\t\t\t\t\t\t<label class=\"description\" for=\"htmlks4wp_theme_options[sometextarea]\"><?php _e( 'Sample text box', 'htmlks4wp' ); ?></label>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</table>\n\n\t\t\t<p class=\"submit\">\n\t\t\t\t<input type=\"submit\" class=\"button-primary\" value=\"<?php _e( 'Save Options', 'htmlks4wp' ); ?>\" />\n\t\t\t</p>\n\t\t</form>\n\t</div>\n\t<?php\n}", "function pu_display_setting($args)\n{\n extract( $args );\n\n $option_name = 'pu_theme_options';\n\n $options = get_option( $option_name );\n\n switch ( $type ) { \n case 'text': \n $options[$id] = stripslashes($options[$id]); \n $options[$id] = esc_attr( $options[$id]); \n echo \"<input class='regular-text$class' type='text' id='$id' name='\" . $option_name . \"[$id]' value='$options[$id]' />\"; \n echo ($desc != '') ? \"<br /><span class='description'>$desc</span>\" : \"\";\n break;\n case 'textarea': \n $options[$id] = stripslashes($options[$id]); \n //$options[$id] = esc_attr( $options[$id]);\n $options[$id] = esc_html( $options[$id]); \n\n printf(\n \twp_editor($options[$id], $id, \n \t\tarray('textarea_name' => $option_name . \"[$id]\",\n \t\t\t'style' => 'width: 200px'\n \t\t\t)) \n\t\t\t\t);\n // echo \"<textarea id='$id' name='\" . $option_name . \"[$id]' rows='10' cols='50'>\".$options[$id].\"</textarea>\"; \n // echo ($desc != '') ? \"<br /><span class='description'>$desc</span>\" : \"\"; \n break; \n }\n}", "function hide_developer(){\n\tadd_action( 'admin_menu', 'devhelper_remove_developer_options', 999 );\n}", "function optionsframework_option_name() {\n\n // 从样式表获取主题名称\n $themename = wp_get_theme();\n $themename = preg_replace(\"/\\W/\", \"_\", strtolower($themename) );\n\n $optionsframework_settings = get_option( 'optionsframework' );\n $optionsframework_settings['id'] = $themename;\n update_option( 'optionsframework', $optionsframework_settings );\n}", "function gssettings_sanitize_inputs() {\n genesis_add_option_filter( 'one_zero', GSSETTINGS_SETTINGS_FIELD, array( 'gssettings_move_primary_nav', 'gssettings_move_subnav' ) );\n }", "function wporphanageex_menu_settings() {\n\tinclude_once( dirname( __FILE__ ) . '/wp-orphanage-extended-options.php' );\n}", "function pre_update_option($value, $option, $old_value)\n {\n }", "function action_customize_register_for_dynamic_settings() {\n\t\tadd_filter( 'customize_dynamic_setting_args', array( $this, 'filter_customize_dynamic_setting_args_for_test_dynamic_settings' ), 10, 2 );\n\t\tadd_filter( 'customize_dynamic_setting_class', array( $this, 'filter_customize_dynamic_setting_class_for_test_dynamic_settings' ), 10, 3 );\n\t}" ]
[ "0.7034645", "0.69735634", "0.6917836", "0.686713", "0.680478", "0.6800002", "0.6764749", "0.67034596", "0.6699744", "0.6688453", "0.6661837", "0.6660011", "0.6637654", "0.66300976", "0.6589491", "0.6577982", "0.65754133", "0.65586126", "0.6523037", "0.65218836", "0.65089405", "0.6498575", "0.64876217", "0.64746857", "0.6471278", "0.6463413", "0.6436607", "0.64312136", "0.64259994", "0.64241457", "0.6423314", "0.6412464", "0.6409888", "0.6406524", "0.6402657", "0.63989353", "0.6393667", "0.63824224", "0.6351146", "0.6340316", "0.6324403", "0.63216114", "0.63190484", "0.63167584", "0.6315032", "0.6295619", "0.6295465", "0.6286515", "0.6283783", "0.6278532", "0.6274782", "0.6266318", "0.62596506", "0.6254611", "0.62487525", "0.6248387", "0.62471193", "0.62431645", "0.6240969", "0.6240748", "0.62404156", "0.6233016", "0.62322235", "0.62266195", "0.6224232", "0.6219012", "0.62180334", "0.6209612", "0.62085116", "0.6206861", "0.6203003", "0.6202406", "0.61954856", "0.6190898", "0.6189708", "0.617704", "0.6176569", "0.61748457", "0.6168394", "0.6167604", "0.61665213", "0.6163184", "0.61630553", "0.61590016", "0.61577004", "0.6153765", "0.6148827", "0.61484134", "0.6148209", "0.6146001", "0.6143785", "0.61365527", "0.6133863", "0.6133258", "0.6132983", "0.6131815", "0.61302364", "0.61232483", "0.6123145", "0.6117904" ]
0.62851834
48
Load the menu page
function ajb_options_add_page() { add_theme_page( __( 'Homepage Options', 'ajb' ), __( 'Theme Options', 'ajb' ), ajb_get_options_page_cap(), 'ajb_options', 'ajb_options_do_page' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function loadMenu() {\n\t\t$m = array();\n\t\t$menu = new Menu();\t\t\n\t\t$m['menu'] = $menu->getMenu();\n //loadView carrega um view qualquer\n //nesse caso vai ser o view menu\n\t\t$this->loadView(\"menu\", $m);\t\t\n\t}", "public function setLoadControllerMenu()\r\n {\r\n add_menu_page(\r\n $_SESSION['controller_data_current']['page_title'], // Title of the page\r\n $_SESSION['controller_data_current']['page_menu_text'], // Text to show on the menu link\r\n $_SESSION['controller_data_current']['page_capability'], // Capability requirement to see the link\r\n $_SESSION['controller_data_current']['page_slug'],\r\n $_SESSION['controller_data_current']['page_render'],\r\n $_SESSION['controller_data_current']['page_menu_icon'],\r\n $_SESSION['controller_data_current']['page_menu_position']\r\n );\r\n }", "public static function load() {\n\n\t\tadd_menu_page( self::TA_PAGE_TITLE, self::TA_TITLE, 'administrator', self::TA_SLUG, array(__CLASS__, 'makeAdmin'), self::asset('img/') . self::TA_ICON_URL, self::TA_POSITION );\n\t}", "public function menu()\n\t{\n\t\t$partial = new Inoves_Partial('Content/view/menu/contentMain.phtml');\n\n\t\t$partial->slug = Inoves_URS::$params[0];\n\t\t\n\t\tInoves_View::prepend('#content', $partial);\n\t}", "private function init_menu()\n {\n // it's a sample code you can init some other part of your page\n }", "protected function _load()\r\n {\r\n $page = new Model_Page();\r\n $children = $page->getChildren($this->_parentId);\r\n if ($children != null && $children->count() > 0) {\r\n foreach ($children as $child) {\r\n if ($child->show_on_menu == 1) {\r\n $this->items[] = new Digitalus_Menu_Item($child);\r\n }\r\n }\r\n }\r\n }", "protected function _menu()\n\t{\n\t\tif (ee()->view->disabled('ee_menu'))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tee()->view->cp_main_menu = ee()->menu->generate_menu();\n\t}", "function loadMenu($arg_menu_name)\n{\n\tINCLUDE('menus/' . $arg_menu_name . '.mnu');\n\treturn $menu;\n}", "public function loadPage() {\n //We have to insert the following pages.\n /*\n * 1. Header\n\t\t *\t-> Admin Ajax / User Ajax\n * 2. Navigation Bar\n\t\t *\t-> Admin navBar / User navBar\n * 3. Main Body\n * 4. Footer\n */\n\t\t//First we decide whether the page is an admin page or not.\n\t\tglobal $session;\n\t\tif(stripos($this->pageName, 'admin') === false)\t{\n\t\t\t$navBarType = 'user';\n\t\t\t$this->setTemplateVar('isadmin', 0);\n\t\t\t//We Load the data for the top fixed infobar.\n\t\t\t$this->setTemplateVar('currentBalance', getCurrentBalance());\n\t\t\t$this->setTemplateVar('prodQueueCount', getProdQueueCount());\n\t\t\t$this->setTemplateVar('username', $session->getUserName());\n\t\t} else {\n\t\t\t$navBarType = 'admin';\n\t\t\t$this->setTemplateVar('isadmin', 1);\n\t\t}\n\t\t\n\t\t//Now we also have to note wheather the user is an admin user or not.\n\t\t$this->setTemplateVar('isAdminUser', ($session->isAdminUser() ? 1 : 0));\n\t\t\n\t\t//Now we load all the pages.\n\t\tinclude $this->rootPath.'templates/header.php';\n\t\tinclude $this->rootPath.'templates/'.$navBarType.'_navbar.php';\n\t\tinclude $this->rootPath.'templates/t_'.$this->pageName.'.php';\n\t\tinclude $this->rootPath.'templates/footer.html';\n }", "public function menu() {\n $data['menus'] = $this->allmenus();\n $this->load->view('Dashboard/header');\n $this->load->view('Menu/menu', $data);\n $this->load->view('Dashboard/footer');\n }", "public function menu( )\n {\n\n if( $this->view->isType( View::SUBWINDOW ) )\n {\n $view = $this->view->newWindow('WebfrapMainMenu', 'Default');\n }\n else if( $this->view->isType( View::MAINTAB ) )\n {\n $view = $this->view->newMaintab('WebfrapMainMenu', 'Default');\n $view->setLabel('Explorer');\n }\n else\n {\n $view = $this->view;\n }\n\n $view->setTitle('Webfrap Main Menu');\n\n $view->setTemplate( 'webfrap/menu/modmenu' );\n\n $modMenu = $view->newItem( 'modMenu', 'MenuFolder' );\n $modMenu->setData( DaoFoldermenu::get('webfrap/root',true) );\n\n }", "public function loadMenu()\n\t{\n\t\t$request = array(\n\t\t\t't_location' => ( isset( \\IPS\\Request::i()->t_location ) ) ? \\IPS\\Request::i()->t_location : null,\n\t\t\t't_group' => ( isset( \\IPS\\Request::i()->t_group ) ) ? \\IPS\\Request::i()->t_group : null,\n\t\t\t't_key' \t => ( isset( \\IPS\\Request::i()->t_key ) ) ? \\IPS\\Request::i()->t_key : null,\n\t\t\t't_type' => ( isset( \\IPS\\Request::i()->t_type ) ) ? \\IPS\\Request::i()->t_type : 'templates',\n\t\t);\n\n\t\tswitch( $request['t_type'] )\n\t\t{\n\t\t\tdefault:\n\t\t\tcase 'template':\n\t\t\t\t$flag = \\IPS\\cms\\Templates::RETURN_ONLY_TEMPLATE;\n\t\t\t\tbreak;\n\t\t\tcase 'js':\n\t\t\t\t$flag = \\IPS\\cms\\Templates::RETURN_ONLY_JS;\n\t\t\t\tbreak;\n\t\t\tcase 'css':\n\t\t\t\t$flag = \\IPS\\cms\\Templates::RETURN_ONLY_CSS;\n\t\t\t\tbreak;\n\t\t}\n\n\t\t$templates = \\IPS\\cms\\Templates::buildTree( \\IPS\\cms\\Templates::getTemplates( $flag + \\IPS\\cms\\Templates::RETURN_DATABASE_ONLY ) );\n\n\t\t$current = new \\IPS\\cms\\Templates;\n\t\t\n\t\tif ( ! empty( $request['t_key'] ) )\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\t$current = \\IPS\\cms\\Templates::load( $request['t_key'] );\n\t\t\t}\n\t\t\tcatch( \\OutOfRangeException $ex )\n\t\t\t{\n\t\t\t\t\n\t\t\t}\n\t\t}\n\n\t\t\\IPS\\Output::i()->output = \\IPS\\Theme::i()->getTemplate( 'templates' )->menu( $templates, $current, $request );\n\t}", "private function menu()\n {\n $data['links'] = ['create', 'read', 'update', 'delete'];\n\n return $this->view->render($data, 'home/menu');\n }", "public function initMenu()\n {\n add_menu_page(\n 'Flickr Group Gallery',\n 'Flickr Group Gallery',\n 'administrator',\n 'flickr-group-gallery',\n array($this, 'render'),\n 'dashicons-admin-generic'\n );\n }", "private function loadMenu()\n\t{\n\t\tglobal $txt, $context, $modSettings, $settings;\n\n\t\t// Need these to do much\n\t\trequire_once(SUBSDIR . '/Menu.subs.php');\n\n\t\t// Define the menu structure - see subs/Menu.subs.php for details!\n\t\t$admin_areas = array(\n\t\t\t'forum' => array(\n\t\t\t\t'title' => $txt['admin_main'],\n\t\t\t\t'permission' => array('admin_forum', 'manage_permissions', 'moderate_forum', 'manage_membergroups', 'manage_bans', 'send_mail', 'edit_news', 'manage_boards', 'manage_smileys', 'manage_attachments'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'index' => array(\n\t\t\t\t\t\t'label' => $txt['admin_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_home',\n\t\t\t\t\t\t'class' => 'i-home i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'credits' => array(\n\t\t\t\t\t\t'label' => $txt['support_credits_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_credits',\n\t\t\t\t\t\t'class' => 'i-support i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'maillist' => array(\n\t\t\t\t\t\t'label' => $txt['mail_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMaillist',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-envelope-blank i-admin',\n\t\t\t\t\t\t'permission' => array('approve_emails', 'admin_forum'),\n\t\t\t\t\t\t'enabled' => featureEnabled('pe'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'emaillist' => array($txt['mm_emailerror'], 'approve_emails'),\n\t\t\t\t\t\t\t'emailfilters' => array($txt['mm_emailfilters'], 'admin_forum'),\n\t\t\t\t\t\t\t'emailparser' => array($txt['mm_emailparsers'], 'admin_forum'),\n\t\t\t\t\t\t\t'emailtemplates' => array($txt['mm_emailtemplates'], 'approve_emails'),\n\t\t\t\t\t\t\t'emailsettings' => array($txt['mm_emailsettings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'news' => array(\n\t\t\t\t\t\t'label' => $txt['news_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageNews',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-post-text i-admin',\n\t\t\t\t\t\t'permission' => array('edit_news', 'send_mail', 'admin_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'editnews' => array($txt['admin_edit_news'], 'edit_news'),\n\t\t\t\t\t\t\t'mailingmembers' => array($txt['admin_newsletters'], 'send_mail'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'packages' => array(\n\t\t\t\t\t\t'label' => $txt['package'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\Packages\\\\Packages',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-package i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['browse_packages']),\n\t\t\t\t\t\t\t'installed' => array($txt['installed_packages']),\n\t\t\t\t\t\t\t'options' => array($txt['package_settings']),\n\t\t\t\t\t\t\t'servers' => array($txt['download_packages']),\n\t\t\t\t\t\t\t'upload' => array($txt['upload_packages']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'packageservers' => array(\n\t\t\t\t\t\t'label' => $txt['package_servers'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\Packages\\\\PackageServers',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-package i-admin',\n\t\t\t\t\t\t'hidden' => true,\n\t\t\t\t\t),\n\t\t\t\t\t'search' => array(\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_search',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-search i-admin',\n\t\t\t\t\t\t'select' => 'index'\n\t\t\t\t\t),\n\t\t\t\t\t'adminlogoff' => array(\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Admin',\n\t\t\t\t\t\t'function' => 'action_endsession',\n\t\t\t\t\t\t'label' => $txt['admin_logoff'],\n\t\t\t\t\t\t'enabled' => empty($modSettings['securityDisable']),\n\t\t\t\t\t\t'class' => 'i-sign-out i-admin',\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'config' => array(\n\t\t\t\t'title' => $txt['admin_config'],\n\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'corefeatures' => array(\n\t\t\t\t\t\t'label' => $txt['core_settings_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\CoreFeatures',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-cog i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'featuresettings' => array(\n\t\t\t\t\t\t'label' => $txt['modSettings_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageFeatures',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-switch-on i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'basic' => array($txt['mods_cat_features']),\n\t\t\t\t\t\t\t'layout' => array($txt['mods_cat_layout']),\n\t\t\t\t\t\t\t'pmsettings' => array($txt['personal_messages']),\n\t\t\t\t\t\t\t'karma' => array($txt['karma'], 'enabled' => featureEnabled('k')),\n\t\t\t\t\t\t\t'likes' => array($txt['likes'], 'enabled' => featureEnabled('l')),\n\t\t\t\t\t\t\t'mention' => array($txt['mention']),\n\t\t\t\t\t\t\t'sig' => array($txt['signature_settings_short']),\n\t\t\t\t\t\t\t'profile' => array($txt['custom_profile_shorttitle'], 'enabled' => featureEnabled('cp')),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'serversettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_server_settings'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageServer',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-menu i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['general_settings']),\n\t\t\t\t\t\t\t'database' => array($txt['database_paths_settings']),\n\t\t\t\t\t\t\t'cookie' => array($txt['cookies_sessions_settings']),\n\t\t\t\t\t\t\t'cache' => array($txt['caching_settings']),\n\t\t\t\t\t\t\t'loads' => array($txt['loadavg_settings']),\n\t\t\t\t\t\t\t'phpinfo' => array($txt['phpinfo_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'securitysettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_security_moderation'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSecurity',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-lock i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['mods_cat_security_general']),\n\t\t\t\t\t\t\t'spam' => array($txt['antispam_title']),\n\t\t\t\t\t\t\t'moderation' => array($txt['moderation_settings_short'], 'enabled' => !empty($modSettings['warning_enable'])),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'theme' => array(\n\t\t\t\t\t\t'label' => $txt['theme_admin'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageThemes',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'custom_url' => getUrl('admin', ['action' => 'admin', 'area' => 'theme']),\n\t\t\t\t\t\t'class' => 'i-modify i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'admin' => array($txt['themeadmin_admin_title']),\n\t\t\t\t\t\t\t'list' => array($txt['themeadmin_list_title']),\n\t\t\t\t\t\t\t'reset' => array($txt['themeadmin_reset_title']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'current_theme' => array(\n\t\t\t\t\t\t'label' => $txt['theme_current_settings'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageThemes',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'custom_url' => getUrl('admin', ['action' => 'admin', 'area' => 'theme', 'sa' => 'list', 'th' => $settings['theme_id']]),\n\t\t\t\t\t\t'class' => 'i-paint i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'languages' => array(\n\t\t\t\t\t\t'label' => $txt['language_configuration'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageLanguages',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-language i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'edit' => array($txt['language_edit']),\n\t\t\t\t\t\t\t// 'add' => array($txt['language_add']),\n\t\t\t\t\t\t\t'settings' => array($txt['language_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'addonsettings' => array(\n\t\t\t\t\t\t'label' => $txt['admin_modifications'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\AddonSettings',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-puzzle i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'general' => array($txt['mods_cat_modifications_misc']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'layout' => array(\n\t\t\t\t'title' => $txt['layout_controls'],\n\t\t\t\t'permission' => array('manage_boards', 'admin_forum', 'manage_smileys', 'manage_attachments', 'moderate_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'manageboards' => array(\n\t\t\t\t\t\t'label' => $txt['admin_boards'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageBoards',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-directory i-admin',\n\t\t\t\t\t\t'permission' => array('manage_boards'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'main' => array($txt['boardsEdit']),\n\t\t\t\t\t\t\t'newcat' => array($txt['mboards_new_cat']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'postsettings' => array(\n\t\t\t\t\t\t'label' => $txt['manageposts'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePosts',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'class' => 'i-post-text i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'posts' => array($txt['manageposts_settings']),\n\t\t\t\t\t\t\t'censor' => array($txt['admin_censored_words']),\n\t\t\t\t\t\t\t'topics' => array($txt['manageposts_topic_settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'editor' => array(\n\t\t\t\t\t\t'label' => $txt['editor_manage'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageEditor',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-modify i-admin',\n\t\t\t\t\t\t'permission' => array('manage_bbc'),\n\t\t\t\t\t),\n\t\t\t\t\t'smileys' => array(\n\t\t\t\t\t\t'label' => $txt['smileys_manage'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSmileys',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-smiley i-admin',\n\t\t\t\t\t\t'permission' => array('manage_smileys'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'editsets' => array($txt['smiley_sets']),\n\t\t\t\t\t\t\t'addsmiley' => array($txt['smileys_add'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'editsmileys' => array($txt['smileys_edit'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'setorder' => array($txt['smileys_set_order'], 'enabled' => !empty($modSettings['smiley_enable'])),\n\t\t\t\t\t\t\t'editicons' => array($txt['icons_edit_message_icons'], 'enabled' => !empty($modSettings['messageIcons_enable'])),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'manageattachments' => array(\n\t\t\t\t\t\t'label' => $txt['attachments_avatars'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageAttachments',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-paperclip i-admin',\n\t\t\t\t\t\t'permission' => array('manage_attachments'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['attachment_manager_browse']),\n\t\t\t\t\t\t\t'attachments' => array($txt['attachment_manager_settings']),\n\t\t\t\t\t\t\t'avatars' => array($txt['attachment_manager_avatar_settings']),\n\t\t\t\t\t\t\t'attachpaths' => array($txt['attach_directories']),\n\t\t\t\t\t\t\t'maintenance' => array($txt['attachment_manager_maintenance']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'managesearch' => array(\n\t\t\t\t\t\t'label' => $txt['manage_search'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSearch',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-search i-admin',\n\t\t\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'weights' => array($txt['search_weights']),\n\t\t\t\t\t\t\t'method' => array($txt['search_method']),\n\t\t\t\t\t\t\t'managesphinx' => array($txt['search_sphinx']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'members' => array(\n\t\t\t\t'title' => $txt['admin_manage_members'],\n\t\t\t\t'permission' => array('moderate_forum', 'manage_membergroups', 'manage_bans', 'manage_permissions', 'admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'viewmembers' => array(\n\t\t\t\t\t\t'label' => $txt['admin_users'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMembers',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-user i-admin',\n\t\t\t\t\t\t'permission' => array('moderate_forum'),\n\t\t\t\t\t),\n\t\t\t\t\t'membergroups' => array(\n\t\t\t\t\t\t'label' => $txt['admin_groups'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMembergroups',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-users',\n\t\t\t\t\t\t'permission' => array('manage_membergroups'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'index' => array($txt['membergroups_edit_groups'], 'manage_membergroups'),\n\t\t\t\t\t\t\t'add' => array($txt['membergroups_new_group'], 'manage_membergroups'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'permissions' => array(\n\t\t\t\t\t\t'label' => $txt['edit_permissions'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePermissions',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-lock i-admin',\n\t\t\t\t\t\t'permission' => array('manage_permissions'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'index' => array($txt['permissions_groups'], 'manage_permissions'),\n\t\t\t\t\t\t\t'board' => array($txt['permissions_boards'], 'manage_permissions'),\n\t\t\t\t\t\t\t'profiles' => array($txt['permissions_profiles'], 'manage_permissions'),\n\t\t\t\t\t\t\t'postmod' => array($txt['permissions_post_moderation'], 'manage_permissions', 'enabled' => $modSettings['postmod_active']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'ban' => array(\n\t\t\t\t\t\t'label' => $txt['ban_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageBans',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-thumbdown i-admin',\n\t\t\t\t\t\t'permission' => 'manage_bans',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'list' => array($txt['ban_edit_list']),\n\t\t\t\t\t\t\t'add' => array($txt['ban_add_new']),\n\t\t\t\t\t\t\t'browse' => array($txt['ban_trigger_browse']),\n\t\t\t\t\t\t\t'log' => array($txt['ban_log']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'regcenter' => array(\n\t\t\t\t\t\t'label' => $txt['registration_center'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageRegistration',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-user-plus i-admin',\n\t\t\t\t\t\t'permission' => array('admin_forum', 'moderate_forum'),\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'register' => array($txt['admin_browse_register_new'], 'moderate_forum'),\n\t\t\t\t\t\t\t'agreement' => array($txt['registration_agreement'], 'admin_forum'),\n\t\t\t\t\t\t\t'privacypol' => array($txt['privacy_policy'], 'admin_forum'),\n\t\t\t\t\t\t\t'reservednames' => array($txt['admin_reserved_set'], 'admin_forum'),\n\t\t\t\t\t\t\t'settings' => array($txt['settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'sengines' => array(\n\t\t\t\t\t\t'label' => $txt['search_engines'],\n\t\t\t\t\t\t'enabled' => featureEnabled('sp'),\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageSearchEngines',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-website i-admin',\n\t\t\t\t\t\t'permission' => 'admin_forum',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'stats' => array($txt['spider_stats']),\n\t\t\t\t\t\t\t'logs' => array($txt['spider_logs']),\n\t\t\t\t\t\t\t'spiders' => array($txt['spiders']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'paidsubscribe' => array(\n\t\t\t\t\t\t'label' => $txt['paid_subscriptions'],\n\t\t\t\t\t\t'enabled' => featureEnabled('ps'),\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManagePaid',\n\t\t\t\t\t\t'class' => 'i-credit i-admin',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'permission' => 'admin_forum',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'view' => array($txt['paid_subs_view']),\n\t\t\t\t\t\t\t'settings' => array($txt['settings']),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'maintenance' => array(\n\t\t\t\t'title' => $txt['admin_maintenance'],\n\t\t\t\t'permission' => array('admin_forum'),\n\t\t\t\t'areas' => array(\n\t\t\t\t\t'maintain' => array(\n\t\t\t\t\t\t'label' => $txt['maintain_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Maintenance',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-cog i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'routine' => array($txt['maintain_sub_routine'], 'admin_forum'),\n\t\t\t\t\t\t\t'database' => array($txt['maintain_sub_database'], 'admin_forum'),\n\t\t\t\t\t\t\t'members' => array($txt['maintain_sub_members'], 'admin_forum'),\n\t\t\t\t\t\t\t'topics' => array($txt['maintain_sub_topics'], 'admin_forum'),\n\t\t\t\t\t\t\t'hooks' => array($txt['maintain_sub_hooks_list'], 'admin_forum'),\n\t\t\t\t\t\t\t'attachments' => array($txt['maintain_sub_attachments'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'logs' => array(\n\t\t\t\t\t\t'label' => $txt['logs'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\AdminLog',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-comments i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'errorlog' => array($txt['errlog'], 'admin_forum', 'enabled' => !empty($modSettings['enableErrorLogging']), 'url' => getUrl('admin', ['action' => 'admin', 'area' => 'logs', 'sa' => 'errorlog', 'desc'])),\n\t\t\t\t\t\t\t'adminlog' => array($txt['admin_log'], 'admin_forum', 'enabled' => featureEnabled('ml')),\n\t\t\t\t\t\t\t'modlog' => array($txt['moderation_log'], 'admin_forum', 'enabled' => featureEnabled('ml')),\n\t\t\t\t\t\t\t'banlog' => array($txt['ban_log'], 'manage_bans'),\n\t\t\t\t\t\t\t'spiderlog' => array($txt['spider_logs'], 'admin_forum', 'enabled' => featureEnabled('sp')),\n\t\t\t\t\t\t\t'tasklog' => array($txt['scheduled_log'], 'admin_forum'),\n\t\t\t\t\t\t\t'pruning' => array($txt['pruning_title'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'scheduledtasks' => array(\n\t\t\t\t\t\t'label' => $txt['maintain_tasks'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageScheduledTasks',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-calendar i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'tasks' => array($txt['maintain_tasks'], 'admin_forum'),\n\t\t\t\t\t\t\t'tasklog' => array($txt['scheduled_log'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'mailqueue' => array(\n\t\t\t\t\t\t'label' => $txt['mailqueue_title'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\ManageMail',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-envelope-blank i-admin',\n\t\t\t\t\t\t'subsections' => array(\n\t\t\t\t\t\t\t'browse' => array($txt['mailqueue_browse'], 'admin_forum'),\n\t\t\t\t\t\t\t'settings' => array($txt['mailqueue_settings'], 'admin_forum'),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'reports' => array(\n\t\t\t\t\t\t'enabled' => featureEnabled('rg'),\n\t\t\t\t\t\t'label' => $txt['generate_reports'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\Reports',\n\t\t\t\t\t\t'function' => 'action_index',\n\t\t\t\t\t\t'class' => 'i-pie-chart i-admin',\n\t\t\t\t\t),\n\t\t\t\t\t'repairboards' => array(\n\t\t\t\t\t\t'label' => $txt['admin_repair'],\n\t\t\t\t\t\t'controller' => '\\\\ElkArte\\\\AdminController\\\\RepairBoards',\n\t\t\t\t\t\t'function' => 'action_repairboards',\n\t\t\t\t\t\t'select' => 'maintain',\n\t\t\t\t\t\t'hidden' => true,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\n\t\t$this->_events->trigger('addMenu', array('admin_areas' => &$admin_areas));\n\n\t\t// Any files to include for administration?\n\t\tcall_integration_include_hook('integrate_admin_include');\n\n\t\t$menuOptions = array(\n\t\t\t'hook' => 'admin',\n\t\t);\n\n\t\t// Actually create the menu!\n\t\t$menu = new Menu();\n\t\t$menu->addMenuData($admin_areas);\n\t\t$menu->addOptions($menuOptions);\n\t\t$admin_include_data = $menu->prepareMenu();\n\t\t$menu->setContext();\n\t\tunset($admin_areas);\n\n\t\t// Make a note of the Unique ID for this menu.\n\t\t$context['admin_menu_id'] = $context['max_menu_id'];\n\t\t$context['admin_menu_name'] = 'menu_data_' . $context['admin_menu_id'];\n\n\t\t// Where in the admin are we?\n\t\t$context['admin_area'] = $admin_include_data['current_area'];\n\n\t\treturn $admin_include_data;\n\t}", "public function menu(){\n $data=[];\n $data['title']=\"Menu || Admin Panel\";\n $data['menuList'] = $this->header->selectMenuheader();\n $data['userlistAll'] = $this->header->userlistAll();\n $this->load->view(\"header\", $data); //100% need\n\n $selectMenu['selectMenu'] = $this->header->selectMenu();\n $this->load->view('menu', $selectMenu); //important\n\n $this->load->view(\"footer\");\n }", "private function loadPage()\n\t{\n\t $data = $this->getData();\n \t \n\t $this->load->view('index', $data);\n\t}", "public function load_mega_menu() {\n include plugin_dir_path(dirname(__FILE__)) . 'includes/mega-menu/menu-functions.php';\n include plugin_dir_path(dirname(__FILE__)) . 'includes/mega-menu/custom-walker.php';\n }", "static function adminMenuPage()\n {\n // Include the view for this menu page.\n include PROJECTEN_PLUGIN_ADMIN_VIEWS_DIR . '/admin_main.php';\n }", "public function menu_page() {\n\t\tinclude EPT_PATH . 'views/troubleshoot.php';\n\t}", "public function afficheMenu()\r\n\t\t{\r\n\t\t//appel de la vue du menu\r\n\t\trequire 'Vues/menu.php';\r\n\t\t}", "static public function _MENU(){\n if (b_reg::$current_module == VM_MODULE) start_VM();\n return loader::_fromCache('APImenu_vm'); \n }", "protected function menus()\n {\n\n }", "function show_menu() {\n\n\tglobal $T, $DB, $Global;\n\t\n\t// Define variables\n\t$T->Set( 'command', 'oncommand=\"menuAction (this.id,'. \"'\" . \n\t\t\t $Global[ 'session'] . \"'\" .', ' . \"'\" . $Global['project'] . \n\t\t\t \"'\" . ')\"'); \n\t// Start a xul page\n\t\n\t$Obj = new Y_Engine();\n\n\t$file = \"project/\" . $Global['project'] . \"/data.menu__.base.php\";\n\tinclude_once ( $file );\n\t\n\t$file = \"engine/\".$Global['lang'].\"/data.devmenu__.php\";\n\tif( file_exists( $file )){\n\t\tinclude_once ( $file );\n\t}\n\telse{\n\t\t$file = \"engine/en/data.devmenu__.php\";\n\t\tinclude_once ( $file );\n\t}\n\n\t$T->Set( 'version', $Global['version'] );\n\n\t// Making a menu\n\t$T->Set( 'user'\t\t, $Global['username'] ) ;\n\t$T->Set( 'title' \t, $Obj->GetAlias());\n\t$T->Set( 'project'\t, $Global['project'] );\n\t$T->Show('start_menu');\n\n\n//print_r( $Obj );\n\n\t$key = array_keys( $Obj->element );\n\tfor( $i=0; $i< count( $key ); $i++ ) {\n\t\t$i_element = $key[$i];\n\n\t\tif ( $Global['oper'] != MENU_ONLY_ ) {\n\t\t\t$T->Set( 'disabled', 'disabled=\"true\"' );\n\t\t}\n\t\t\t\t\n\t\t// Menu header\n\t\tif ( $Obj->element[ $key[$i] ] [ F_TYPE_ ] == \"header\" ) {\n\n\t\t\t$headername = $Obj->Get( $i_element, F_ALIAS_ );\n\t\t\tif ( ($Global['oper'] != MENU_ONLY_ ) && \n\t\t\t\t ( $headername != \"+\" ) ) {\n\t\t\t\t$T->Set( 'disabled', 'disabled=\"true\"' );\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$T->Set( 'disabled', '' );\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t$T->Set( 'alias', $Obj->Get( $i_element, F_ALIAS_ ) );\n\t\t\t$T->Set( 'name', $Obj->Get( $i_element, F_NAME_ ) );\n\t\t\t\t\n\t\t\t\t// se houver problemas com os popups pode ser NAME\n\t\t\t$T->Set( 'popup', $Obj->Get( $i_element, F_ALIAS_ ) . \".popup\" );\t\n\t\t\t$T->Set( 'help', $Obj->Get( $i_element, F_HELP_ ) );\n\t\t\t$oper = $Obj->Get( $i_element, F_OPER_ );\n\t\t\tif ( empty( $oper ) ) {\n\t\t\t\t$oper = BROWSE_;\n\t\t\t}\n\t\t\t\n\t\t\t$t_oper = explode( \"_\", $oper );\n\t\t\t$oper = $t_oper[0];\n\t\t\t\n\t\t\t\n\t\t\t$T->Set( 'command', 'oncommand=\"menuAction ('.$oper.','. \"'\" . \n\t\t\t\t $Global[ 'session'] . \"'\" .', ' . \"'\" . $Global['project'] . \n\t\t\t\t \"','\" . $Obj->Get( $i_element, F_LINK_ ) . \"',0\" . ')\"'); \n\t\t\t\n\t\t\t// Define trustee\n\t\t\t$trustee['header'] = check_trustee( \n\t\t\t\t\t$Obj->Get( $i_element, G_SHOW_ ) )\t;\t\t\n\t\t\tif ( $trustee['header'] ) {\n\t\t\t\t$T->Show( 'menu_header' );\n\t\t\t}\n\t\t\t\n\t\t\t// Menu Elements\n\t\t\t$header = $Obj->Get( $i_element, F_NAME_) ;\n\t\t\t$element = \"0_\";\n//\t\t\tfor ( $b=$i; $b< count( $Obj->element ); $b++ ){\n\t\t\tfor ( $b=0; $b< count( $Obj->element ); $b++ ){\n\t\t\t\t$b_element = $key[$b];\t\t\t\n\t\t\t\tif ( ($Obj->Get( $b_element, F_TYPE_ ) == \"menu\" ) &&\n\t\t\t\t\t ($Obj->Get( $b_element, R_TABLE_ ) == $header )) {\n\t\t\t\t\t$T->Set( 'e_alias', $Obj->Get( $b_element, F_ALIAS_) );\n\t\t\t\t\t$T->Set( 'e_name', \t$Obj->Get( $b_element, F_NAME_) );\n\t\t\t\t\t$T->Set( 'e_popup', $Obj->Get( $b_element, F_ALIAS_) . \".popup\" );\t\n\t\t\t\t\t$T->Set( 'e_help', \t$Obj->Get( $b_element, F_HELP_ ) );\n\t\t\t\t\t$oper = $Obj->Get( $b_element, F_OPER_ );\n\n\t\t\t\t\t\n\t\t\t\t\tif ( $Global['oper'] != MENU_ONLY_ ) {\n\t\t\t\t\t\tif ( $headername != \"+\" ) {\n\t\t\t\t\t\t\tbreak; \n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\tif ( empty( $oper ) ) {\n\t\t\t\t\t\t$oper = BROWSE_;\n\t\t\t\t\t}\n\n\n\t\t\t\t\t$t_oper = explode( \"_\", $oper );\n\t\t\t\t\t$oper = $t_oper[0];\n\t\n\n\t\n\n// # 162\n\t\t\t\t\t\n\t\t\t\t\t$T->Set( 'command', 'oncommand=\"menuAction ('.$oper.\n\t\t\t\t\t\t','. \"'\" . $Global[ 'session'] . \"'\" .', ' . \n\t\t\t\t\t\t\"'\" . $Global['project'] . \t\"','\" . \n\t\t\t\t\t\t$Obj->Get( $b_element, F_LINK_ ) . \"',0,'\" . \n\t\t\t\t\t\t$Obj->Get( $b_element, F_FILTER_ ).\"'\".')\"'); \n\t\t\t\t\t\n/* OLD\n\t\t\t\t\t$T->Set( 'command', 'oncommand=\"menuAction ('.$oper.\n\t\t\t\t\t\t','. \"'\" . $Global[ 'session'] . \"'\" .', ' . \n\t\t\t\t\t\t\"'\" . $Global['project'] . \n\t\t\t\t\t\t\"','\" . $Obj->Get( $b_element, F_LINK_ ) . \"',0\" . ')\"'); \n*/\n// # 162 end \n\n\n\t\t\t\t\t// Define trustee\n\t\t\t\t\t$trustee['element'] = check_trustee( \n\t\t\t\t\t$Obj->Get( $b_element, G_SHOW_ ) )\t;\t\t\n\t\t\t\t\t\n\t\t\t\t\tif ( ($element == \"0_\") && ( $trustee['header'] )) {\n\t\t\t\t\t\t$T->Show( 'menu_header_startpopup' );\n\t\t\t\t\t}\t\n\n\t\t\t\t\t// Submenus\n\t\t\t\t\t$element = $Obj->Get( $b_element, F_NAME_ );\n\t\t\t\t\t$submenu = \"0_\";\n//\t\t\t\t\tfor ( $c=$b; $c< count( $Obj->element ); $c++ ){\n\t\t\t\t\tfor ( $c=0; $c< count( $Obj->element ); $c++ ){\n\t\t\t\t\t\t$c_element = $key[$c];\t\t\t\t\t\n\t\t\t\t\t\tif (($Obj->Get( $c_element, F_TYPE_) == \"submenu\") &&\n\t\t\t\t\t\t \t\t($Obj->Get( $c_element, R_TABLE_) ==\n\t\t\t\t\t\t\t\t $element)) {\n\t\t\t\t\t\t\t$T->Set( 'alias', $Obj->Get( $c_element, F_ALIAS_) );\n\t\t\t\t\t\t\t$T->Set( 'name', $Obj->Get( $c_element,F_NAME_) );\n\t\t\t\t\t\t\t$T->Set( 'help', $Obj->Get( $c_element, F_HELP_ ) );\n\t\t\t\t\t\t\t$oper = $Obj->Get( $c_element, F_OPER_ );\n\t\t\t\t\t\t\t\n// # 162\n\t\t\t\t\t\t\t$filter = $Obj->Get( $c_element, F_FILTER_ );\n// # 162 \t\t\t\t\t\t\t\n\n\t\t\t\t\t\t\tif ( empty( $oper ) ) {\n\t\t\t\t\t\t\t\t$oper = BROWSE_;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$t_oper = explode( \"_\", $oper );\n\t\t\t\t\t\t\t$oper = $t_oper[0];\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\n// # 162\t\t\n\t\t\t\t\t\t\t$T->Set('command','oncommand=\"menuAction('.$oper.\n\t\t\t\t\t\t\t\t','.\"'\". \n\t\t\t\t\t\t\t \t$Global[ 'session'] . \"'\" .', ' . \"'\" .\n\t\t\t\t\t\t\t \t$Global['project'] . \"','\" . \n\t\t\t\t\t\t\t\t$Obj->Get( $c_element, F_LINK_ ) . \"',0,'\" . \n\t\t\t\t\t\t\t\t$Obj->Get( $c_element, F_FILTER_ ).\"'\".')\"'); \n/*\tOLD\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t$T->Set('command','oncommand=\"menuAction('.$oper.\n\t\t\t\t\t\t\t\t','.\"'\". \n\t\t\t\t\t\t\t \t$Global[ 'session'] . \"'\" .', ' . \"'\" .\n\t\t\t\t\t\t\t \t$Global['project'] . \"','\" . \n\t\t\t\t\t\t\t\t$Obj->Get( $c_element, F_LINK_ ) . \"',0\" . ')\"'); \n*/\n// # 162 end\n\t\t\t\t\t\t\t// Define trustee\n\t\t\t\t\t\t\t$trustee['submenu'] = check_trustee( \n\t\t\t\t\t\t\t\t$Obj->Get( $c_element, G_SHOW_ ) )\t;\t\t\n\t\t\t\t\t\t\tif (($submenu == \"0_\") && ($trustee['element'])){\n\t\t\t\t\t\t\t\t$T->Show( 'menu_element' );\t\t\t\n\t\t\t\t\t\t\t\t$T->Show( 'menu_element_startpopup' );\n\t\t\t\t\t\t\t\t$submenu = \"1\";\n\t\t\t\t\t\t\t}\t\n\t\t\t\t\t\t\tif ( $trustee['submenu'] ) {\n\t\t\t\t\t\t\t\t$T->Show( 'submenu' );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\tif (($submenu != \"0_\") && ($trustee['element'])) {\n\t\t\t\t\t\t$T->Show( 'menu_element_endpopup' );\n\t\t\t\t\t\t$T->Show( 'menu_element_end');\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tif ( $trustee['element'] ) {\t\t\t\t\t\n\t\t\t\t\t\t\t$T->Show( 'menu_element_item' );\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ( ($element != \"0_\") && ($trustee['header']) ) {\n\t\t\t\t$T->Show( 'menu_header_endpopup' );\n\t\t\t}\n\t\t\tif ( $trustee['header'] ) {\n\t\t\t\t$T->Show( 'menu_header_end' );\n\t\t\t}\n\t\t}\n\t}\n\t\n\t$T->Show('end_menu');\n \n}", "public function setLoadControllerMenuSub()\r\n {\r\n add_submenu_page(\r\n $_SESSION['controller_data_sub']['page_slug_current'],\r\n $_SESSION['controller_data_sub']['page_title'], // Title of the page\r\n $_SESSION['controller_data_sub']['page_menu_text'], // Text to show on the menu link\r\n $_SESSION['controller_data_sub']['page_capability'], // Capability requirement to see the link\r\n $_SESSION['controller_data_sub']['page_slug'],\r\n $_SESSION['controller_data_sub']['page_render'],\r\n $_SESSION['controller_data_sub']['page_menu_position']\r\n );\r\n }", "public function menu()\n {\n $this->load->view('admin/header');\n $data['all_module'] = $this->common_model->getAll('sett_modules','status',1);\n $data['menu_all_module'] = $this->common_model->getAll('sett_menu');\n $data['all_main_menu'] = $this->common_model->getAll('sett_menu','type',0);\n $this->load->view('admin/menu',$data);\n $this->load->view('admin/footer');\n }", "public function addMenu(){\n\t\tadd_menu_page(\n\t\t\t$this->plugin->name,\n\t\t\t$this->plugin->name,\n\t\t\t'publish_pages',\n\t\t\t$this->plugin->varName,\n\t\t\tarray($this, 'page'),\n\t\t\t$this->plugin->uri . 'assets/images/icn-menu.png'\n\t\t);\n\t}", "public function add_menu() {\n\t\t\tadd_menu_page(\n\t\t\t\t'Amazon Affiliate | Products',\n\t\t\t\t'Products',\n\t\t\t\t'manage_options',\n\t\t\t\t'amz-affiliate/pages/product.php',\n\t\t\t\tarray( &$this, 'load_product_page' ),\n\t\t\t\tplugins_url( 'amz-affiliate/img/icon.png' ),\n\t\t\t\t50\n\t\t\t);\n\t\t\tadd_submenu_page(\n\t\t\t\t'amz-affiliate/pages/product.php',\n\t\t\t\t'Amazon Affiliate | Tables',\n\t\t\t\t'Tables',\n\t\t\t\t'manage_options',\n\t\t\t\t'amz-affiliate/pages/table.php',\n\t\t\t\tarray( &$this, 'load_table_page' )\n\t\t\t);\n\t\t}", "public function get_list_menu()\n {\n if ($this->request->isAJAX())\n {\n $param['MenuModel'] = $this->MenuModel->get();\n echo view(\"backend/option/menu/page-list\", $param);\n } \n else\n {\n echo \"No access permits\";\n }\n }", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "protected function generateMenu() {}", "public function page(){\n\t\t$pageLoader = $this->plugin->library('Page');\n\t\t$pageLoader->load('admin/settings');\n\t}", "function add_menu() {\n add_menu_page(\"Polls\", \"Polls\", \"administrator\", \"polls\", \"managePollsPage\");\n}", "function mainMenu() \r\n\t\t{\r\n\t\t\tif($this->RequestAction('/external_functions/verifiedAccess/'.$this->Auth->user('id').\"/1/mainMenu\") == true)\r\n\t\t\t{\r\n\t\t\t\t$this->set('title_for_layout', 'Fondos por rendir :: Menu Principal');\r\n\t\t\t\t$this->set('userAdmin', $this->Auth->user('admin'));\r\n\t\t\t}\r\n\t\t\telse\r\n\t\t\t{\r\n\t\t\t\t$this->Session->setFlash('No tienes permisos para ver esta pagina, consulta con el administrador del sistema.', 'flash_alert');\r\n\t\t\t\t$this->redirect(array('controller' => 'dashboard', 'action' => 'index'));\r\n\t\t\t}\r\n\t\t}", "function menuFlow() {\n\t\tincludeFile('templates/mainmenu');\n\t\techo PHP_EOL;\n\t}", "public static function installPageMenu()\n\t{\n\t\t$pagemenulinks = self::parseModules(GWF_ModuleLoader::loadModulesFS());\n\t\treturn self::installPageMenu2($pagemenulinks);\n\t}", "public function load_admin_page()\n {\n include 'admin-page.html';\n }", "public function load()\n {\n if (is_admin()) {\n add_action('admin_menu', array($this, 'addMenus'), 100);\n }\n }", "public function modMenu() {}", "public function modMenu() {}", "public function modMenu() {}", "function showMenu($page) {\n $menu = $this->getArray('sys_menu_group', 'status=1', 'position asc');\n $strscript = '';\n echo '<div id=\"myslidemenu\" class=\"jqueryslidemenu\">';\n if (count($menu) > 0) {\n echo '<ul>';\n foreach ($menu as $value) {\n $classUL = 'li_' . $value[\"id\"] . '';\n echo '<li class=\"' . $classUL . '\" style=\"display:none\"><span style=\"float:left; padding:8px 30px; border-right:1px solid #ccc; cursor: pointer;\">' . $value[\"title\"] . '</span>';\n $submenu = $this->getArray('sys_table', \"menu=1 AND menu_group_id='\" . $value[\"id\"] . \"'\", 'position asc');\n if (count($submenu) > 0) {\n echo '<ul class=\"sub\">';\n $ili = 0;\n foreach ($submenu as $v) {\n $id = $v['id'];\n if ($_SESSION[\"user_login\"][\"role_id\"] == 11) {\n $_SESSION['permission'][$id]['is_list'] = 1;\n $_SESSION['permission'][$id]['is_edit'] = 1;\n $_SESSION['permission'][$id]['is_insert'] = 1;\n $_SESSION['permission'][$id]['is_delete'] = 1;\n }\n if ($_SESSION['permission'][$id]['is_list']) {\n if ($ili == 0) {\n $strscript .= \"<script>\n\n\n\n\n\n\n\n\t\t\t\t\t\t\t\t\t\t\tjQuery('.\" . $classUL . \"').css({'display':'block'});\n\n\n\n\n\n\n\n\t\t\t\t\t\t\t\t\t\t</script>\";\n }\n echo \"\";\n echo '<li><a class=\"sub\" href=\"' . (($v['custom_link']) ? $v['custom_link'] : 'mngMain.php') . '?table_name=' . stripslashes($v[\"table_name\"]) . '\">' . $v[\"title\"] . '</a></li><br/>';\n $ili++;\n }\n//echo '<li><a class=\"sub\" href=\"mngMain.php?table_name='.stripslashes($v[\"table_name\"]).'\">'.$v[\"table_name\"].'</a></li>';\n }\n echo '</ul>';\n }\n echo '</li>';\n }\n echo '</ul>';\n }\n echo $strscript;\n echo '</div>';\n }", "public function loadAdminMenu()\n {\n\t\t$file = $this->xoops_root_path . '/modules/' . $this->getInfo('dirname') . '/' . $this->getInfo('adminmenu');\n if ($this->getInfo('adminmenu') && $this->getInfo('adminmenu') != '' && \\XoopsLoad::fileExists($file)) {\n $adminmenu = array();\n include $file;\n $this->adminmenu = $adminmenu;\n }\n }", "private function PH_PageMenu(){\n $site_menu = self::$xvi_api->GetSiteMenu();\n $page_menu = self::$xvi_api->GetPageMenu();\n \n $menu =\"\";\n foreach($site_menu as $menu_item=>$menu_path) {\n if (strcmp($menu_item,$page_menu[\"item\"])) { /*not selected menu item*/\n $menu .= \"<li><a href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n } else { /* it is selected menu*/\n $menu .= \"<li><a class=\\\"sel\\\" href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n }\n }\n return $menu;\n }", "public function menuAction()\n {\n $site = $this->getSessionVar('site');\n /* @var $repo \\Allegro\\SitesBundle\\Repository\\SiteRepository */\n $repo = $this->getRepo('Site');\n\n /* @var $siteEntity Allegro\\SitesBundle\\Entity\\Site */\n $siteEntity = $repo->getSiteBySlug($site);\n return $this->render($this->getTemplate('menu.html'), array(\n 'site' => $siteEntity,\n '_locale' => $this->getSessionVar('_locale')\n ));\n }", "private function imprimeMenu ()\n {\n $this->load->view(\"menu/index\");\n return 0;\n }", "public function index()\n {\n $data = $this->user->getUserData();\n $data['title'] = 'Menu Management';\n $data['menu'] = $this->menu->getMenuByUser($data['role_id']);\n $data['submenu'] = $this->menu->getAllSubmenu();\n $this->template->load('menu/menuManagement', $data, 'menu/JS_menu');\n }", "public function beforeContent() {\n\t\t$menu = $this->document->getElementById($this->id);\n\t\tif($menu) {\n\t\t\t$this->document->addCss('public/css/simplemenu.css');\n\t\t\t$menu->removeAttribute('style');\n\n\t\t\t$menuList = $this->document->createElement('ul');\n\n\t\t\t$rq = new RequestHandler(DEFAULTPAGE, $this->basepath);\n\n\t\t\tforeach($this->menuItems as $lbl => $page) {\n\t\t\t\t$li = $this->document->createElement('li');\n\t\t\t\t$a = $this->document->createElement('a', $lbl);\n\t\t\t\t$a->setAttribute('href', $this->basepath.'/'.$page);\n\t\t\t\tif($rq->getPage() == $page)\n\t\t\t\t\t$li->setAttribute('class', 'selected');\n\t\t\t\t$li->appendChild($a);\n\t\t\t\t$menuList->appendChild($li);\n\t\t\t}\n\t\t\t$menu->appendChild($menuList);\n\t\t}\n\t}", "public static function func_ajax_load_menu() {\n\t\t\t \n\t\t\t\tglobal $wpdb;\n\t\t\t\t\n\t\t\t\tif(!defined('DOING_AJAX')){\n wp_redirect (site_url());\n exit;\n } else {\n\t\t\t\t echo self::load_listings();\n\t\t\t\t die();\n\t\t\t\t}\n\t\t\n\t\t}", "public function load_admin_page() {\n\t \t\n\t\t// determine the action from either the GET parameter (for sub-menu entries, and the main admin menu entry)\n\t\t$action = ( ! empty( $_GET['action'] ) ) ? $_GET['action'] : 'list'; // default action is list\n\t\t\n\t\tif ( $this->is_top_level_page ) {\n\t\t\t// or for sub-menu entry of an admin menu \"IggoGrid\" entry, get it from the \"page\" GET parameter\n\t\t\tif ( 'iggogrid' !== $_GET['page'] ) {\n\t\t\t\t\n\t\t\t\t// actions that are top-level entries, but don't have an action GET parameter (action is after last _ in string)\n\t\t\t\t$action = substr( $_GET['page'], 9 ); // $_GET['page'] has the format 'iggogrid_{$action}'\n\t\t\t}\n\t\t} else {\n\t\t\t// do this here in the else-part, instead of adding another if ( ! $this->is_top_level_page ) check\n\t\t\t$this->init_i18n_support(); // done here, as for sub menu admin pages this is the first time translated strings are needed\n\t\t\t$this->init_view_actions(); // for top-level menu entries, this has been done above, just like init_i18n_support()\n\t\t}\n\t\t\n\t\t// check if action is a supported action, and whether the user is allowed to access this screen\n\t\tif ( ! isset( $this->view_actions[ $action ] ) || ! current_user_can( $this->view_actions[ $action ]['required_cap'] ) ) {\n\t\t\twp_die( __( 'You do not have sufficient permissions to access this page.', 'default' ) );\n\t\t}\n\t\t\n\t\t// changes current screen ID and pagenow variable in JS, to enable automatic meta box JS handling\n\t\tset_current_screen( \"iggogrid_{$action}\" );\n\n\t\t// pre-define some table data\n\t\t$data = array(\n\t\t\t'view_actions' => $this->view_actions,\n\t\t\t'message' => ( ! empty( $_GET['message'] ) ) ? $_GET['message'] : false,\n\t\t);\n\t\t\n\t\t// depending on action, load more necessary data for the corresponding view\n\t\tswitch ( $action ) {\n\t\t\tcase 'list':\n\t\t\t\t$data['table_id'] = ( ! empty( $_GET['table_id'] ) ) ? $_GET['table_id'] : false;\n\t\t\t\t$data['table_ids'] = IggoGrid::$model_table->load_all( true ); // Prime the post meta cache for cached loading of last_editor\n\t\t\t\t$data['messages']['first_visit'] = IggoGrid::$model_options->get( 'message_first_visit' );\n\t\t\t\tif ( current_user_can( 'iggogrid_import_tables_wptr' ) ) {\n\t\t\t\t\t$data['messages']['wp_table_reloaded_warning'] = is_plugin_active( 'wp-table-reloaded/wp-table-reloaded.php' ); // check if WP-Table Reloaded is activated\n\t\t\t\t} else {\n\t\t\t\t\t$data['messages']['wp_table_reloaded_warning'] = false;\n\t\t\t\t}\n\t\t\t\t$data['messages']['show_plugin_update'] = IggoGrid::$model_options->get( 'message_plugin_update' );\n\t\t\t\t$data['messages']['plugin_update_message'] = IggoGrid::$model_options->get( 'message_plugin_update_content' );\n\t\t\t\t$data['messages']['donation_message'] = $this->maybe_show_donation_message();\n\t\t\t\t$data['table_count'] = count( $data['table_ids'] );\n\t\t\t\tbreak;\n\t\t\tcase 'about':\n\t\t\t\t$data['plugin_languages'] = $this->get_plugin_languages();\n\t\t\t\t$data['first_activation'] = IggoGrid::$model_options->get( 'first_activation' );\n// \t\t\t\t$exporter = IggoGrid::load_class( 'IggoGrid_Export', 'class-export.php', 'classes' );\n// \t\t\t\t$data['zip_support_available'] = $exporter->zip_support_available;\n\t\t\t\tbreak;\n\t\t\tcase 'options':\n\t\t\t\t// Maybe try saving \"Custom CSS\" to a file:\n\t\t\t\t// (called here, as the credentials form posts to this handler again, due to how request_filesystem_credentials() works)\n\t\t\t\tif ( isset( $_GET['item'] ) && 'save_custom_css' == $_GET['item'] ) {\n\t\t\t\t\tIggoGrid::check_nonce( 'options', $_GET['item'] ); // nonce check here, as we don't have an explicit handler, and even viewing the screen needs to be checked\n\t\t\t\t\t$action = 'options_custom_css'; // to load a different view\n\t\t\t\t\t// try saving \"Custom CSS\" to a file, otherwise this gets the HTML for the credentials form\n\t\t\t\t\t$iggogrid_css = IggoGrid::load_class( 'IggoGrid_CSS', 'class-css.php', 'classes' );\n\t\t\t\t\t$result = $iggogrid_css->save_custom_css_to_file_plugin_options( IggoGrid::$model_options->get( 'custom_css' ), IggoGrid::$model_options->get( 'custom_css_minified' ) );\n\t\t\t\t\tif ( is_string( $result ) ) {\n\t\t\t\t\t\t$data['credentials_form'] = $result; // this will only be called if the save function doesn't do a redirect\n\t\t\t\t\t} elseif ( true === $result ) {\n\t\t\t\t\t\t// at this point, saving was successful, so enable usage of CSS in files again,\n\t\t\t\t\t\t// and also increase the \"Custom CSS\" version number (for cache busting)\n\t\t\t\t\t\tIggoGrid::$model_options->update( array(\n\t\t\t\t\t\t\t'use_custom_css_file' => true,\n\t\t\t\t\t\t\t'custom_css_version' => IggoGrid::$model_options->get( 'custom_css_version' ) + 1,\n\t\t\t\t\t\t) );\n\t\t\t\t\t\tIggoGrid::redirect( array( 'action' => 'options', 'message' => 'success_save' ) );\n\t\t\t\t\t} else { // leaves only $result = false\n\t\t\t\t\t\tIggoGrid::redirect( array( 'action' => 'options', 'message' => 'success_save_error_custom_css' ) );\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t$data['frontend_options']['use_custom_css'] = IggoGrid::$model_options->get( 'use_custom_css' );\n\t\t\t\t$data['frontend_options']['custom_css'] = IggoGrid::$model_options->get( 'custom_css' );\n\t\t\t\t$data['user_options']['parent_page'] = $this->parent_page;\n\t\t\t\t$data['user_options']['plugin_language'] = IggoGrid::$model_options->get( 'plugin_language' );\n\t\t\t\t$data['user_options']['plugin_languages'] = $this->get_plugin_languages();\n\t\t\t\tbreak;\n\t\t\tcase 'edit':\n\t\t\t\tif ( ! empty( $_GET['table_id'] ) ) {\n\t\t\t\t\t$data['table'] = IggoGrid::$model_table->load( $_GET['table_id'], true, true ); // Load table, with table data, options, and visibility settings\n// \t\t\t\t\tprint_r($data['table']);die;\n\t\t\t\t\tif ( is_wp_error( $data['table'] ) ) {\n\t\t\t\t\t\tIggoGrid::redirect( array( 'action' => 'list', 'message' => 'error_load_table' ) );\n\t\t\t\t\t}\n\t\t\t\t\tif ( ! current_user_can( 'iggogrid_edit_table', $_GET['table_id'] ) ) {\n\t\t\t\t\t\twp_die( __( 'You do not have sufficient permissions to access this page.', 'default' ) );\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tIggoGrid::redirect( array( 'action' => 'list', 'message' => 'error_no_table' ) );\n\t\t\t\t}\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\t/**\n\t\t * Filter the data that is passed to the current IggoGrid View.\n\t\t *\n\t\t * @since 1.0.0\n\t\t *\n\t\t * @param array $data Data for the view.\n\t\t * @param string $action The current action for the view.\n\t\t */\n\t\t$data = apply_filters( 'iggogrid_view_data', $data, $action );\n\t\t\n\t\t// prepare and initialize the view\n\t\t$this->view = IggoGrid::load_view( $action, $data );\n\t}", "protected function getModuleMenu() {}", "protected function getModuleMenu() {}", "protected function getModuleMenu() {}", "public function index() {\n $data['parentmenu'] = $this->parentmenus();\n $data['menus'] = $this->allmenus();\n $data['pages'] = $this->allpages();\n $this->load->view('Dashboard/header');\n $this->load->view('Menu/menu', $data);\n $this->load->view('Dashboard/footer');\n }", "public function menustoreAction() {\n $panel_pages = array();\n $menut = Model_Menu::getInstance();\n $panel_names = $menut->panels();\n $pages = array();\n // at this point have selected all the menus of all active modules\n // return a tree of pages from each top level page sorted by sort_by and label\n foreach($panel_names as $panel):\n $panel_data = array('id' => $panel, 'label' => ucwords(str_replace('_', ' ', $panel)),\n 'children' => array());\n foreach($menut->find(array('panel' => $panel, 'parent' => 0), 'sort_by') as $menu):\n $panel_data['children'][] = $menu->pages_tree();\n endforeach;\n $pages[] = $panel_data;\n endforeach;\n $this->view->data = new Zend_Dojo_Data('id', $pages, 'label');\n $this->_helper->layout->disableLayout();\n }", "function init_menu() {\n if (func_num_args()>0) {\n $arg_list = func_get_args();\n }\n\n // menu entries\n module::set_menu($this->module, \"RAD Facility\", \"LIBRARIES\", \"_rad_facility\");\n module::set_menu($this->module, \"RAD DX Codes\", \"LIBRARIES\", \"_rad_dxcodes\");\n module::set_menu($this->module, \"RAD DX Codes\", \"LIBRARIES\", \"_rad_\");\n\n // add more detail\n module::set_detail($this->description, $this->version, $this->author, $this->module);\n\n }", "function menu(){\n\t$pd = new ParsedownExtra();\n\t$page_id = \"./application/menu.md\";\n\t$lines = file($page_id);\n\techo \"<nav>\".\"\\n\";\n\techo \"<ul>\".\"\\n\";\n\t//We put the menu in a for loop to separate the links into the nav properly.\n\tforeach($lines as $line_num => $line){\n\t\t$line2 = $pd->text($line);\n\t\techo \"<li>\".$line2.\"</li>\".\"\\n\";\n\t}\n\techo \"</ul>\".\"\\n\";\n\techo \"</nav>\".\"\\n\";\n}", "public function setPageMenu() {\n\t\t\tglobal $factory_impressive_page_menu;\n\n\t\t\t$dashicon = ( ! empty( $this->page_menu_dashicon ) ) ? ' ' . $this->page_menu_dashicon : '';\n\t\t\t$short_description = ( ! empty( $this->page_menu_short_description ) ) ? ' ' . $this->page_menu_short_description : '';\n\n\t\t\tif ( is_multisite() && is_network_admin() && ! $this->network ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t$factory_impressive_page_menu[ $this->getMenuScope() ][ $this->getResultId() ] = [\n\t\t\t\t'type' => $this->type, // page, options\n\t\t\t\t'url' => $this->getBaseUrl(),\n\t\t\t\t'title' => $this->getPageTitle() . ' <span class=\"dashicons' . $dashicon . '\"></span>',\n\t\t\t\t'short_description' => $short_description,\n\t\t\t\t'position' => $this->page_menu_position,\n\t\t\t\t'parent' => $this->page_parent_page\n\t\t\t];\n\t\t}", "function get_menu($param = NULL)\n\t{\n\t\tif (isset($param[\"icon\"]) and substr($param[\"icon\"], 0, 4) === \"http\")\n\t\t{\n\t\t\t$icon = $param[\"icon\"];\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$icon_name = empty($param[\"icon\"]) ? \"cog\" : $param[\"icon\"];\n\t\t\t$icon = icons::get_std_icon_url($icon_name);\n\t\t}\n\n\n\t\t$is = \"\";\n\t\tforeach($this->menus as $parent => $menudata)\n\t\t{\n\t\t\t$is .= '<div id=\"'.$parent.'\" class=\"menu\" onmouseover=\"menuMouseover(event)\">'.\"\\n${menudata}</div>\\n\";\n\t\t};\n\t\t$this->vars(array(\n\t\t\t\"ss\" => $is,\n\t\t\t\"menu_id\" => $this->menu_id,\n\t\t\t\"menu_icon\" => $icon,\n\t\t\t\"alt\" => isset($param[\"alt\"]) ? $param[\"alt\"] : null\n\t\t));\n\n\t\tif (!empty($param[\"text\"]))\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"text\" => $param[\"text\"]\n\t\t\t));\n\t\t\t$this->vars(array(\n\t\t\t\t\"HAS_TEXT\" => $href_ct = $this->parse(\"HAS_TEXT\")\n\t\t\t));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"HAS_ICON\" => $href_ct = $this->parse(\"HAS_ICON\")\n\t\t\t));\n\t\t}\n\n\t\tif (!empty($param[\"is_toolbar\"]))\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"IS_TOOLBAR\" => $this->parse(\"IS_TOOLBAR\")\n\t\t\t));\n\t\t}\n\t\t\n\t\tif (aw_template::bootstrap())\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"DROPDOWN\" => $this->__parse_dropdown($this->menu_id),\n\t\t\t));\n\t\t}\n\n\t\tif (is_array($param) && !empty($param[\"load_on_demand_url\"]))\n\t\t{\n\t\t\tstatic $lod_num;\n\t\t\t$lod_num++;\n\t\t\treturn \"<div id='lod_\".$this->menu_id.\"'><a href='javascript:void(0);' onClick='tb_lod\".$lod_num.\"()' class='nupp'>$href_ct</a></div>\n\t\t\t<script language=javascript>\n\t\t\tfunction tb_lod\".$lod_num.\"()\n\t\t\t{\n\t\t\t\tel = document.getElementById(\\\"lod_\".$this->menu_id.\"\\\");\n\t\t\t\tel.innerHTML=aw_get_url_contents(\\\"\".$param[\"load_on_demand_url\"].\"\\\");\n\t\t\t\tnhr=document.getElementById(\\\"href_\".$this->menu_id.\"\\\");\n\t\t\t\tif (document.createEvent) {evObj = document.createEvent(\\\"MouseEvents\\\");evObj.initEvent( \\\"click\\\", true, true );nhr.dispatchEvent(evObj);}\n\t\t\t\telse {\n\t\t\t\t\tnhr.fireEvent(\\\"onclick\\\");\n\t\t\t\t}\n\t\t\t}\n\t\t\t</script>\n\t\t\t\";\n\t\t}\n\n\t\treturn $this->parse();\n\t}", "public function initializePage()\n\t{\n\t\tadd_menu_page('Thema opties', 'Thema opties', 'manage_options', 'theme-options');\n\t}", "static function iniPage($username, $menu ){\r\n\t\t\t?>\r\n\t\t\t\r\n\t\t\t<div class=\"header navbar navbar-inverse navbar-fixed-top\">\r\n\t\t\t\t<!-- BEGIN TOP NAVIGATION BAR -->\r\n\t\t\t\t<div class=\"navbar-inner\">\r\n\t\t\t\t\t<div class=\"container-fluid\">\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t<?php echo GuiHeaderHelper::logo(); ?>\r\n\t\t\t\t\t\t<?php echo GuiHeaderHelper::menuToggler(); ?>\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t<!-- BEGIN TOP NAVIGATION MENU -->\t\t\t\t\t\r\n\t\t\t\t\t\t<?php echo GuiHeaderHelper::topNavegationMenu(); ?>\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t<!-- BEGIN NOTIFICATION DROPDOWN -->\t\r\n\t\t\t\t\t\t\t<?php //echo GuiNotificationBarHelper::show(); ?>\r\n\t\t\t\t\t\t\t<!-- END NOTIFICATION DROPDOWN -->\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t<!-- BEGIN INBOX DROPDOWN -->\r\n\t\t\t\t\t\t\t<?php //echo GuiInboxBarHelper::show(); ?>\r\n\t\t\t\t\t\t\t<!-- END INBOX DROPDOWN -->\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t<!-- BEGIN TODO DROPDOWN -->\r\n\t\t\t\t\t\t\t<?php //echo GuiTaskBarHelper::show(); ?>\r\n\t\t\t\t\t\t\t<!-- END TODO DROPDOWN -->\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t<!-- Display user dropdown -->\r\n\t\t\t\t\t\t\t<?php \r\n\t\t\t\t\t\t\t\techo GuiUserDropdownHelper::show($username); \r\n\t\t\t\t\t\t\t?>\r\n\t\t\t\t\t\t\t\r\n\t\t\t\r\n\t\t\t\t\t\t<?php echo GuiHeaderHelper::endTopNavegationMenu(); ?>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<!-- END TOP NAVIGATION BAR -->\r\n\t\t\t</div>\r\n\t\t\t<!-- END HEADER -->\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t<!-- BEGIN CONTAINER -->\r\n\t\t\t<div class=\"page-container row-fluid\">\r\n\t\t\t\t<!-- BEGIN SIDEBAR -->\r\n\t\t\t\t<?php GuiLeftHelper::initLeftPanel(); ?>\r\n\t\t\t\t\t<?php GuiLeftHelper::showSearchForm(); ?>\t\r\n\t\t\t\t\t<?php echo $menu; ?>\t\r\n\t\t\t\t<?php GuiLeftHelper::endLeftPanel(); ?>\r\n\t\t\t\t\r\n\t\t\t\t<!-- END SIDEBAR -->\r\n\t\t<?php\r\n\t}", "public function indexAction()\n {\n $this->_helper->layout->setLayout('pbo/pbo');\n \n $chapId = Zend_Auth::getInstance()->getIdentity()->id; \n \n $menuModel = new Pbo_Model_WlMenuItems();\n $menu = 0;\n //assign query results to $menu variable\n $menuItems = $menuModel->getAllMenus($chapId);\n \n //pass heading to the view\n $this->view->title = \"Pages : Manage Menus\";\n \n //set pagination \n $pagination = Zend_Paginator::factory($menuItems);\n \n if(count($pagination)) \n { \n $pagination->setCurrentPageNumber($this->_request->getParam('page', 1));\n $pagination->setItemCountPerPage(20);\n \n $this->view->menus = $pagination;\n unset($pagination);\n }\n\n $this->view->menuMessages = $this->_helper->flashMessenger->getMessages();\n }", "function getMenuItems()\n {\n $this->menuitem(\"xp\", \"\", \"main\", array(\"xp.story\", \"admin\"));\n $this->menuitem(\"stories\", dispatch_url(\"xp.story\", \"admin\"), \"xp\", array(\"xp.story\", \"admin\"));\n }", "function displayMenu()\n\t{\n\t\tshowInfo();\n\t\tshowActions();\n\t}", "function admin_page_load() {\n\t\t$this->jetpack->admin_page_load();\n\t}", "public function getMenu();", "function menu() {\n\t\tob_start();\n\t\tinclude('templates/menu.php');\n\t\t$output = ob_get_clean();\n\t\treturn $output;\n\t}", "public function load_option_pages()\n {\n if (is_admin() || is_admin_bar_showing()) {\n include OXY_THEME_DIR . 'inc/option-pages.php';\n }\n }", "public function admin_menu() {\n\t\t// Load abstract page class.\n\t\trequire_once SF_ABSPATH . '/includes/settings/class-socialflow-admin-settings-page.php';\n\t\t// Load page classes.\n\t\trequire_once SF_ABSPATH . '/includes/settings/class-socialflow-admin-settings-general.php';\n\t\trequire_once SF_ABSPATH . '/includes/settings/class-socialflow-admin-settings-accounts.php';\n\t\trequire_once SF_ABSPATH . '/includes/settings/class-socialflow-admin-settings-messages.php';\n\t\trequire_once SF_ABSPATH . '/includes/settings/class-socialflow-admin-settings-categories.php';\n\n\t\t// Init menu classes.\n\t\tnew SocialFlow_Admin_Settings_General();\n\t\tnew SocialFlow_Admin_Settings_Accounts();\n\t\t// new SocialFlow_Admin_Settings_Categories.\n\t\t// new SocialFlow_Admin_Settings_Messages.\n\t}", "protected function registerMenu()\n {\n }", "function getSubMenuPageContent() {\n \tif(isSet($_GET['page'])) {\n \t\tswitch($_GET['page']) {\n \t\t\tcase 'lepress-my-subscriptions':\n \t\t\tcase 'lepress':\n \t\t\t\trequire_once('student_include/subscriptions.php');\n \t\t\t\tbreak;\n \t\t\tcase 'lepress-assignments':\n \t\t\t\trequire_once('student_include/assignments.php');\n \t\t\t\tbreak;\n \t\t\tcase 'lepress-groups':\n \t\t\t\trequire_once('student_include/my-groups.php');\n \t\t\t\tbreak;\n \t\t\tdefault:\n \t\t\t\techo \"tere\";\n \t\t\t\tbreak;\n \t\t}\n \t}\n }", "public function index()\n\t{\n\t\t$this->layout = 'home';\n\t\t$this->loadModel(\"Menu\");\n\t\t$menu = $this->Menu->find(\"all\", array(\n\t\t\t\"order\" => array(\"sort asc\")));\n\t\t$menu = Set::extract(\"/Menu/.\",$menu);\n\t\t$this->set(compact('menu'));\n\t}", "public function getMenu()\n {\n if($slug){\n $page = Page::where('slug', $slug)->first();\n return view('page')->with('page', $page);\n }else{\n return view('errors.404');\n }\n \n }", "public function set_menu_list()\r\n {\r\n $controllerData = $this->setUrlController;\r\n $controllerData = urldecode($controllerData);\r\n $getUrlSegment = explode('/', $controllerData);\r\n $controllerSet = isset($_GET['page']) && trim($_GET['page']) !== '' ?\r\n $_GET['page'] : $this->config['controller_default'];\r\n\r\n $methodSet = isset($_GET['method']) && trim($_GET['method']) !== '' ?\r\n $_GET['method'] : $this->config['method_default'];\r\n\r\n $realControllerName = ucfirst($controllerSet);\r\n $realControllerName = str_replace('-', '_', $realControllerName);\r\n\r\n include $this->bootstrap->base_config_dir . 'Routes.php';\r\n\r\n //add menu by foreach all menu list item array\r\n // list main menu plugin\r\n $xCounterMenu = 0;\r\n foreach ($menu_list as $keyItem => $valueItem) {\r\n if ($valueItem['menu_item']['page_slug'] !== $controllerSet) {\r\n add_menu_page(\r\n $valueItem['menu_item']['page_title'], // Title of the page\r\n $valueItem['menu_item']['page_menu_text'], // Text to show on the menu link\r\n $valueItem['menu_item']['page_capability'], // Capability requirement to see the link\r\n $valueItem['menu_item']['page_slug'], // The 'slug' - file to display when clicking the link,\r\n $valueItem['menu_item']['page_render'],\r\n $valueItem['menu_item']['page_menu_icon'], // icon plugin\r\n $valueItem['menu_item']['page_menu_position'] // item position\r\n );\r\n }\r\n $xCounterMenu++;\r\n }\r\n\r\n // list sub main menu plugin\r\n $yCounterMenu = 0;\r\n foreach ($menu_list_sub as $keyItem => $valueItem) {\r\n\r\n if ($valueItem['menu_item']['page_slug'] !== $controllerSet) {\r\n add_submenu_page(\r\n $valueItem['menu_item']['page_slug_current'], // slug current menu\r\n $valueItem['menu_item']['page_title'], // Title of the page\r\n $valueItem['menu_item']['page_menu_text'], // Text to show on the menu link\r\n $valueItem['menu_item']['page_capability'], // Capability requirement to see the link\r\n $valueItem['menu_item']['page_slug'], // The 'slug' - file to display when clicking the link,\r\n $valueItem['menu_item']['page_render'],\r\n $valueItem['menu_item']['page_menu_position'] // item position\r\n );\r\n }else{\r\n add_submenu_page(\r\n $_SESSION['controller_data_sub']['page_slug_current'], // slug current menu\r\n $_SESSION['controller_data_sub']['page_title'], // Title of the page\r\n $_SESSION['controller_data_sub']['page_menu_text'], // Text to show on the menu link\r\n $_SESSION['controller_data_sub']['page_capability'], // Capability requirement to see the link\r\n $_SESSION['controller_data_sub']['page_slug'], // The 'slug' - file to display when clicking the link,\r\n $_SESSION['controller_data_sub']['page_render'], // render\r\n $_SESSION['controller_data_sub']['page_menu_position'] // item position\r\n );\r\n }\r\n \r\n $yCounterMenu++;\r\n }\r\n }", "function Menu() {\r\n parent::Controller();\r\n $this->load->helper('html');\r\n $this->lang->load('userauth', $this->session->userdata('ua_language'));\r\n $this->lang->load('validation', $this->session->userdata('ua_language'));\r\n }", "public function index() {\n\t\t\t/* Get list of menu items */\n\t\t\t$this->menuList = $this->getThreadedList();\n\t\t\t$this->set('menuList', $this->menuList);\n\t\t}", "function loading_page_settings_menu(){\n\t\tadd_options_page('Loading Page', 'Loading Page', 'manage_options', basename(__FILE__), 'loading_page_settings_page');\n }", "public function MenuSoumission(){\n\t\t\tparent::view('Home/Menu2');\n\t\t}", "public function mainMenu() {\n return $this->render(\"mainMenu.twig\", []);\n }", "public function displayPage()\n\t{\n\t\t$this->assign('rightMenu', $this->rightMenu);\n\t\t$this->assign('content', $this->content);\n\t\t$this->display(\"main.tpl\");\n\t}", "public function create_menu()\n\t{\n\t\t$obj = $this; // PHP 5.3 doesn't allow $this usage in closures\n\n\t\t// Add main menu page\n\t\tadd_menu_page(\n\t\t\t'Testimonials plugin', // page title\n\t\t\t'Testimonials', // menu title\n\t\t\t'manage_options', // minimal capability to see it\n\t\t\t'jststm_main_menu', // unique menu slug\n\t\t\tfunction() use ($obj){\n\t\t\t\t$obj->render('main_menu'); // render main menu page template\n\t\t\t},\n\t\t\tplugins_url('images/theater.png', dirname(__FILE__)), // dashboard menu icon\n\t\t\t'25.777' // position in the dahsboard menu (just after the Comments)\n\t\t);\n\t\t// Add help page\n\t\tadd_submenu_page(\n\t\t\t'jststm_main_menu', // parent page slug\n\t\t\t'Testimonials plugin help', // page title\n\t\t\t'What is this?', // menu title\n\t\t\t'manage_options', // capability\n\t\t\t'jststm_help', // slug\n\t\t\tfunction() use ($obj){\n\t\t\t\t$obj->render('help_page');\n\t\t\t}\n\t\t);\n\t}", "public function admin_menu_open() {\n\n\t\t$this->content = $this->render_template(\n\t\t\t'collections/js-holder.php', [\n\t\t\t\t'all_collections' => [],\n\t\t\t]\n\t\t);\n\t\t$this->header = $this->render_template( 'collections/header.php' );\n\t\techo $this->render_template( 'wrapper.php' );\n\n\t}", "private function left_menu()\n\t\t{\n\t\t\t $page_name = functions::get_page_name();\n\t\t\techo '\n\t\t\t\t<ul>\n\t\t\t\t\t';\n\t\t\t\t\t\n\t\t\t\t\t$content_module = array('manage_content.php', 'register_content.php', 'manage_page_content.php', 'register_page_content.php','manage_content_option.php', 'register_content_option.php'\n\t\t\t\t\t,'manage_category.php', 'register_category.php');\n\t\t\t\t\tif(in_array($page_name, $content_module))\n\t\t\t\t\t{\n\t\t\t\t\t\techo '\n\t\t\t\t\t\t<li>\n\t\t\t\t\t\t<img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" />\n\t\t\t\t\t\t<a href=\"manage_content.php\">CMS</a>\n\t\t\t\t\t\t<ul>\n\t\t\t\t\t\t<li><a href=\"manage_page_content.php\">Page Content</a></li>\n\t\t\t\t\t\t<li><a href=\"manage_category.php\">Category</a></li>\n\t\t\t\t\t\t\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t\t</li>';\n\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\techo '<li><img src=\"images/icon-content.png\" alt=\"Manage CMS\" title=\"Manage CMS\" width=\"24\" height=\"24\" /><a href=\"manage_content.php\" >CMS</a></li>';\n\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\techo '<li><img src=\"images/icon-member.png\" alt=\"Manage Member\" title=\"Manage Member\" width=\"24\" height=\"24\" /><a href=\"manage_member.php\" >Member</a></li>\n\t\t\t\t\t<!--<li><img src=\"images/icon-property.png\" alt=\"Manage Property Type\" title=\"Manage Property Type\" width=\"24\" height=\"24\" /><a href=\"manage_property_type.php\" >Property Type</a></li>-->\n\t\t\t\t\t\n\t\t\t\t\t<li><img src=\"images/icon-property.png\" alt=\"Manage Hotel\" title=\"Manage Hotel\" width=\"24\" height=\"24\" /><a href=\"manage_hotel.php\" >Hotel</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-restaurant.jpg\" alt=\"Manage Restaurant\" title=\"Manage Restaurant\" width=\"24\" height=\"24\" /><a href=\"manage_restaurant.php\" >Restaurant</a></li>\n\t\t\t\t\t<li><img src=\"images/icon-venue.png\" alt=\"Manage Venue\" title=\"Manage Venue\" width=\"24\" height=\"24\" /><a href=\"manage_venue.php\" >Venue</a></li>\n\t\t\t\t\t';\n\t\t\t\t\t\t\n\t\techo '</ul>';\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t}", "public function init() {\n $this->view->jQuery()->enable();\n $this->view->jQuery()->uiEnable();\n $auth = Zend_Auth::getInstance()->setStorage(new Zend_Auth_Storage_Session('admin'));\n $user = $auth->getIdentity();\n $menu = '';\n if ($user->code_groupe == 'nn_tegcp_pbf') {\n $menu = '<li><a href=\"/eu-echange/escompte\">Escompte</a></li>';\n $this->view->placeholder(\"menu\")->set($menu);\n }\n }", "public function MenuConfig(){\n\t\t\tparent::view('Home/Menu4');\n\t\t}", "public function makeMenu() {}", "private function _showPublic(){\n $omenu = D('Menu');\n $amodules = $omenu->getModules();\n $this->assign('modules',$amodules);\n $amenu = $omenu->getMenuByModelName(MODULE_NAME);\n $asubNav = array();\n $amenus = array();\n $asubmenus = array();\n $temp = array();\n foreach($amenu as $v){\n if(!$this->_auth($v['name'])) continue;\n switch(count(explode(',',$v['level']))){\n case 2:\n $amenus[$v['id']] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL'],\n 'icon' => $v['icon']\n );\n if(MODULE_NAME == $v['name']){\n $anav[] = array(\n 'title' => $amodules[$v['pId']]['title'],\n 'URL' => $amodules[$v['pId']]['URL'],\n 'icon' => $amodules[$v['pId']]['icon']\n );\n $anav[] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL']\n );\n $amenus[$v['id']]['active'] = true;\n $icon = $v['icon'];\n }else{\n $amenus[$v['id']]['active'] = false;\n }\n break;\n case 3:\n $amenus[$v['pId']]['submenu'][$v['id']] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL']\n );\n if($foundSubNav){\n $stop = true;\n break;\n }else{\n $asubNav = array();\n }\n\n if($v['name'] == MODULE_NAME.'_'.ACTION_NAME){\n $bnatchNav || $bmatchNav = true;\n $foundSubNav = true;\n $anav[] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL'],\n 'class' => 'current'\n );\n $tcontentTitle = $v['title'];\n }else{\n $temp = array(\n 'title' => $v['title'],\n 'URL' => $v['URL'],\n );\n $bmatchNav && $bmatchNav = false;\n }\n break;\n case 4:\n if($foundSubNav && $stop) break;\n if($bmatchNav){\n $asubNav[] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL']\n );\n $tsubContentTitle = $tcontentTitle;\n }else{\n $asubNav[] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL']\n );\n //$tsubContentTitle = $temp['name'];\n if(MODULE_NAME.'_'.ACTION_NAME == $v['name']){\n $foundSubNav = true;\n $tsubContentTitle = $v['title'];\n $tcontentTitle = $temp['title'];\n $anav[] = array(\n 'title' => $temp['title'],\n 'URL' => $temp['URL']\n );\n $anav[] = array(\n 'title' => $v['title'],\n 'URL' => $v['URL'],\n 'class' => 'current'\n );\n $asubNav[count($asubNav)-1]['active'] = true;\n }\n }\n break;\n }\n }\n $this->assign('menu',$amenus);\n $this->assign('nav',$anav);\n $this->assign('contentTitle',$tcontentTitle);\n $this->assign('subnav',$asubNav);\n $this->assign('subContentTitle',$tsubContentTitle);\n $this->assign('icon',$icon);\n }", "function init_menu() {\n if (func_num_args()>0) {\n $arg_list = func_get_args();\n }\n\n // menu entries\n module::set_menu($this->module, \"Drug Formulation\", \"LIBRARIES\", \"_drug_formulation\");\n module::set_menu($this->module, \"Drug Preparation\", \"LIBRARIES\", \"_drug_preparation\");\n module::set_menu($this->module, \"Drug Manufacturer\", \"LIBRARIES\", \"_drug_manufacturer\");\n module::set_menu($this->module, \"Drug Source\", \"LIBRARIES\", \"_drug_source\");\n module::set_menu($this->module, \"Drugs\", \"LIBRARIES\", \"_drugs\");\n\n // add more detail\n module::set_detail($this->description, $this->version, $this->author, $this->module);\n\n }", "function init_menu() {\n if (func_num_args()>0) {\n $arg_list = func_get_args();\n }\n\n // menu entries\n module::set_menu($this->module, \"Drug Formulation\", \"LIBRARIES\", \"_drug_formulation\");\n module::set_menu($this->module, \"Drug Preparation\", \"LIBRARIES\", \"_drug_preparation\");\n module::set_menu($this->module, \"Drug Manufacturer\", \"LIBRARIES\", \"_drug_manufacturer\");\n module::set_menu($this->module, \"Drug Source\", \"LIBRARIES\", \"_drug_source\");\n module::set_menu($this->module, \"Drugs\", \"LIBRARIES\", \"_drugs\");\n\n // add more detail\n module::set_detail($this->description, $this->version, $this->author, $this->module);\n\n }", "function init_menu() {\n if (func_num_args()>0) {\n $arg_list = func_get_args();\n }\n\n // menu entries\n module::set_menu($this->module, \"Notifiable Diseases\", \"LIBRARIES\", \"_notifiable\");\n\n // add more detail\n module::set_detail($this->description, $this->version, $this->author, $this->module);\n\n }", "public static function display()\n {\n $page = self::getCurrentPage();\n\n template::serveTemplate('header');\n\n if (session::has('user') === FALSE) {\n user::setLoginUrl('~url::adminurl~');\n if (session::has('viewPage') === FALSE) {\n session::set('viewPage', $page);\n }\n user::process();\n return;\n }\n\n if (session::has('viewPage') === TRUE) {\n $page = session::get('viewPage');\n session::remove('viewPage');\n }\n\n /**\n * Set the default page title to nothing.\n * This is used for including extra information (eg the post subject).\n */\n template::setKeyword('header', 'pagetitle', '');\n\n $menuItems = array(\n '/' => array(\n 'name' => 'Home',\n 'selected' => TRUE,\n ),\n '/adminpost' => array(\n 'name' => 'Posts',\n ),\n '/admincomments' => array(\n 'name' => 'Comments',\n ),\n '/adminstats' => array(\n 'name' => 'Stats',\n ),\n );\n\n if (empty($page) === FALSE) {\n $bits = explode('/', $page);\n\n // Get rid of the '/admin' bit.\n array_shift($bits);\n\n if (empty($bits[0]) === FALSE) {\n $system = array_shift($bits);\n\n /**\n * Uhoh! Someone's trying to find something that\n * doesn't exist.\n */\n if (loadSystem($system, 'admin') === TRUE) {\n $url = '/'.$system;\n if (isset($menuItems[$url]) === TRUE) {\n $menuItems[$url]['selected'] = TRUE;\n unset($menuItems['/']['selected']);\n }\n\n $bits = implode('/', $bits);\n if (isValidSystem($system) === TRUE) {\n call_user_func_array(array($system, 'process'), array($bits));\n }\n } else {\n $url = '';\n if (isset($_SERVER['PHP_SELF']) === TRUE) {\n $url = $_SERVER['PHP_SELF'];\n }\n $msg = \"Unable to find system '\".$system.\"' for url '\".$url.\"'. page is '\".$page.\"'. server info:\".var_export($_SERVER, TRUE);\n messagelog::LogMessage($msg);\n template::serveTemplate('404');\n }\n }\n } else {\n // No page or default system?\n // Fall back to 'index'.\n template::serveTemplate('header');\n template::serveTemplate('index');\n }\n\n $menu = '';\n foreach ($menuItems as $url => $info) {\n $class = '';\n if (isset($info['selected']) === TRUE && $info['selected'] === TRUE) {\n $class = 'here';\n }\n\n $menu .= '<li class=\"'.$class.'\">';\n $menu .= '<a href=\"~url::adminurl~'.$url.'\">'.$info['name'].'</a>';\n $menu .= '</li>';\n $menu .= \"\\n\";\n }\n\n template::setKeyword('header', 'menu', $menu);\n\n template::serveTemplate('footer');\n template::display();\n\n }", "function xgb_manage_articles_main_menu_page() {\n\t\trequire_once( plugin_dir_path(__FILE__) . \"manage-requests-incoming.php\" );\n\t}", "public function index()\n {\n $this->title .= ' view';\n $this->vars = array_add($this->vars, 'menu', $this->rep->make());\n }", "public function initPage( OutputPage $out ) {\n\t\tparent::initPage( $out );\n\n\t\t$out->addModules( 'skins.nimbus.menu' );\n\t}", "public function testmenuAction()\n {\n parent::login();\n $this->clickAt(\"link=CMS\", \"\");\n $this->click(\"link=Menus\");\n $this->waitForPageToLoad(\"30000\");\n $this->isElementPresent(\"id=sortable1\");\n $this->isElementPresent(\"id=sortable2\");\n parent::logout();\n }", "public function init() {\n $menu = \"<li><a href=\\\" /eu-type-acteur/new \\\">Nouveau</a></li>\";\n $this->view->placeholder(\"menu\")->set($menu);\n $this->view->jQuery()->enable();\n $this->view->jQuery()->uiEnable(); \n }", "function menus();" ]
[ "0.79517525", "0.78417647", "0.7612577", "0.7512621", "0.74848497", "0.736236", "0.7271628", "0.72449535", "0.7154331", "0.7099905", "0.70819706", "0.7013921", "0.6985644", "0.69646823", "0.6910317", "0.68967056", "0.68950367", "0.6861447", "0.68227625", "0.6799826", "0.67963463", "0.676795", "0.67615455", "0.67520523", "0.67480123", "0.6719986", "0.6709038", "0.6699181", "0.66713643", "0.66590196", "0.66590196", "0.66590196", "0.66590196", "0.66590196", "0.66590196", "0.66289103", "0.6614301", "0.66136706", "0.6612743", "0.6611843", "0.65991974", "0.6568146", "0.65362084", "0.65358645", "0.6534838", "0.6526138", "0.6522868", "0.65003294", "0.64948785", "0.64915705", "0.648469", "0.6455717", "0.6441892", "0.6440378", "0.64372575", "0.64371496", "0.64371496", "0.6428203", "0.64269644", "0.6419344", "0.64188963", "0.64056265", "0.6399857", "0.6397332", "0.6373881", "0.6370807", "0.6369872", "0.6369526", "0.63651544", "0.6364046", "0.6358228", "0.63567185", "0.6352499", "0.63498145", "0.6343686", "0.63279617", "0.63176244", "0.63160414", "0.63139904", "0.6311977", "0.6310464", "0.63098586", "0.6299524", "0.62956583", "0.62932056", "0.628131", "0.62798613", "0.6271839", "0.62565017", "0.62540233", "0.624071", "0.6239127", "0.6239127", "0.6236421", "0.6229568", "0.6224966", "0.62213814", "0.62158495", "0.6215146", "0.6214526", "0.6208624" ]
0.0
-1
Create the options page
function ajb_options_do_page() { if ( ! isset( $_REQUEST['settings-updated'] ) ) $_REQUEST['settings-updated'] = false ; ?> <div class="wrap"> <?php screen_icon(); echo "<h2>" . get_current_theme() . __( ' Theme Options', 'ajb' ) . "</h2>"; ?> <?php if ( false !== $_REQUEST['settings-updated'] ) : ?> <div class="updated fade"><p><strong><?php _e( 'Options saved', 'ajb' ); ?></strong></p></div> <?php endif; ?> <form method="post" action="options.php"> <?php settings_fields( 'ajb_option_group' ); ?> <?php $options = get_option( 'ajb_options' ); _e( '<p>The <em>Community is...</em> section shows links to 5 pages. Enter here the information for these links.</p>', 'ajb' ); ?> <table class="form-table"> <?php /** * button link */ for ( $i=1; $i<=5; $i++ ) { ?> <tr valign="top"> <th scope="row"><?php _e( 'Button ' . $i . ' Link', 'ajb' ); ?></th> <td> <input id="ajb_options[button_<?php echo $i; ?>_link]" class="regular-text" type="text" name="ajb_options[button_<?php echo $i; ?>_link]" value="<?php esc_attr_e( $options['button_' . $i . '_link'] ); ?>" /> <label class="description" for="ajb_options[button_<?php echo $i; ?>_link]"><?php _e( 'Link for link button ' . $i . '', 'ajb' ); ?></label> </td> </tr> <?php } ?> </table> <p class="submit"> <input type="submit" class="button-primary" value="<?php _e( 'Save Options', 'ajb' ); ?>" /> </p> </form> </div> <?php }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create_options_page() {\n print '<div class=\"wrap\">';\n screen_icon();\n printf( '<h2>%s</h2>', __( 'Instagram Settings', 'bii-instagram' ) );\n print '<form method=\"post\" action=\"options.php\">';\n settings_fields( 'bii_instagram' );\n do_settings_sections( 'bii-instagram' );\n submit_button();\n print '</form>';\n print '</div>';\n }", "public function create_options_page() {\r\n\r\n\t\tadd_menu_page(\r\n\t\t\t$this->settings['heading'],\r\n\t\t\t$this->settings['menu_title'],\r\n\t\t\t'edit_theme_options',\r\n\t\t\t$this->settings['page_slug'],\r\n\t\t\tarray( $this, 'render_options_page' ),\r\n\t\t\t$this->settings['dashicon'],\r\n\t\t\t999 // Place at the bottom of the dash menu\r\n\t\t);\r\n\r\n\t}", "public function add_options_page()\n {\n }", "public function options_page() {\n\t\t$this->render_settings();\n\t}", "public function optionsPage()\r\n {\r\n $this->updateOptions();\r\n include_once($this->path . '/views/options.php');\r\n }", "public function render_options_page() {\r\n\r\n\t\tinclude( Views::load_view( TBSC_OPTIONS_PLUGIN_DIR . 'src/views/options-page/options-page.php' ) );\r\n\r\n\t}", "public function setup_options_page() {\n\t\tacf_add_options_sub_page( [\n\t\t\t'page_title' \t=> _x( 'Promotions', 'Promotions page title in WP Admin', 'my-listing' ),\n\t\t\t'menu_title'\t=> _x( 'Promotions', 'Promotions menu title in WP Admin', 'my-listing' ),\n\t\t\t'menu_slug' \t=> 'theme-promotions-settings',\n\t\t\t'capability'\t=> 'manage_options',\n\t\t\t'redirect'\t\t=> false,\n\t\t\t'parent_slug' => 'case27/tools.php',\n\t\t] );\n\t}", "public static function _options_page(){\n\t\tif( isset($_POST['urls']) ){\n\t\t\tself::updateUrls($_POST['urls']);\n\t\t}\n\t\t\n\t\t$vars = (object) array();\n\t\t$vars->messages = implode( \"\\n\", self::$messages );\n\t\t$vars->path = self::$path;\n\t\t$vars->urls = self::getUrls();\n\t\tself::render( 'admin', $vars );\n\t}", "public function create_options_page() \n\t{\n\t\t$title = 'Netlify';\n\t\t$slug = 'netlify';\n\t\t$sectionId = 'Netlify';\n\t\t\n\t\t// Add options page\n\t\tadd_options_page(\n\t\t\t$title, \n\t\t\t$title, \n\t\t\t'manage_options', \n\t\t\t$slug, \n\t\t\tarray($this, 'render_options_page')\n\t\t);\n\n\t\t// Add settings section to the created options page\n\t\tadd_settings_section(\n\t\t\t$sectionId, \n\t\t\t'Netlify',\n\t\t\tfunction() {\n\t\t\t\techo \"<p>Add a build hook below or <a href='https://www.netlify.com/docs/webhooks/#incoming-webhooks'>read about configuring one</a>.</p>\";\n\t\t\t},\n\t\t\t$slug\n\t );\n\n\t\t// Add the settings field\n\t\tadd_settings_field( \n\t\t\t'netlify_build_hook_url',\n\t\t\t'Build Hook URL',\n\t\t\tarray($this, 'addSettingsFieldCallback'),\n\t\t\t$slug,\n\t\t\t$sectionId,\n\t\t\tarray( 'netlify_build_hook_url' )\n\t\t);\n\n\t\t// Register the created fields\n\t\tregister_setting( $slug, 'netlify_build_hook_url' );\n\t}", "public function renderOptions() {\n $tab \t\t= sienna_mikado_get_admin_tab();\n $active_page \t= sienna_mikado_framework()->mkdOptions->getAdminPageFromSlug($tab);\n $current_theme \t= wp_get_theme();\n\n if ($active_page == null) return;\n ?>\n <div class=\"mkdf-options-page mkdf-page\">\n\n <?php $this->getHeader($current_theme->get('Name'), $current_theme->get('Version')); ?>\n\n <div class=\"mkdf-page-content-wrapper\">\n <div class=\"mkdf-page-content\">\n <div class=\"mkdf-page-navigation mkdf-tabs-wrapper vertical left clearfix\">\n\n <?php $this->getPageNav($tab); ?>\n <?php $this->getPageContent($active_page, $tab); ?>\n\n\n </div> <!-- close div.mkdf-page-navigation -->\n\n </div> <!-- close div.mkdf-page-content -->\n\n </div> <!-- close div.mkdf-page-content-wrapper -->\n\n </div> <!-- close div.mkd-options-page -->\n\n <a id='back_to_top' href='#'>\n <span class=\"fa-stack\">\n <span class=\"fa fa-angle-up\"></span>\n </span>\n </a>\n <?php }", "public function create_options_menu() {\n add_options_page(\n 'CaseSwap Core', // page title\n 'CaseSwap Core', // menu name\n 'edit_theme_options', // Capability Required\n $this->options_page_slug, // Slug\n array( &$this, \"render_options_menu\" ) // Displaying function\n );\n }", "function cmh_add_options_page() {\r\n\tadd_options_page('Correct My Headings Options Page', 'Correct My Headings', 'manage_options', __FILE__, 'cmh_render_form');\r\n}", "public function add_options_page() {\n add_options_page($this->title, $this->title, 'manage_options', $this->page, array(&$this, 'display_options_page'));\n }", "public function add_options_page() {\n $this->options_page = add_menu_page( $this->title, $this->title, 'manage_options', self::$key, array( $this, 'admin_page_display' ) );\n }", "public function add_options_page() {\n $this->options_page = add_menu_page( $this->title, $this->title, 'manage_options', $this->key, array( $this, 'admin_page_display' ) );\n }", "public function kiwip_create_page(){\n\t\t/* Define options_args */\n\t\t$options_args = array();\n\t\t$options_args['option_name'] = 'Kiwip';\n\t\t/* Define sections */\n\t\t$options_sections[] = array(\n\t\t\t'icon' => KIWIP_URL.'/img/icons/pen.png',\n\t\t\t'title' => 'Posts Configurations',\n\t\t\t'slug' => 'posts_section',\n\t\t\t'desc' => '<p class=\"description\">Some additionnal options for posts management in WordPress</p>',\n\t\t\t'fields' => array(\n\t\t\t\tarray(\n\t\t\t\t\t\"id\" => 'delete_revisions',\n\t\t\t\t\t\"title\" => 'Do you want to delete all posts revision ?',\n\t\t\t\t\t\"desc\" => 'This will run the SQL query:<br />DELETE FROM wp_posts WHERE post_type = \"revision\";',\n\t\t\t\t\t\"type\" => \"checkbox\",\n\t\t\t\t\t\"std\" => 0\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t);\n\n\t\t$options_args['custom_html_header'] = KIWIP_PATH.'Framework_Options/header.php';\n\t\t$options_args['page_position'] = 101;\n\n\t\t$options_args['help_tabs'][] = array(\n\t\t\t\t\t\t\t\t\t'id' => 'kiwip-options-framework-1',\n\t\t\t\t\t\t\t\t\t'title' => 'Information Framework',\n\t\t\t\t\t\t\t\t\t'content' => '<p>This is the tab content, HTML is allowed. Information 1</p>'\n\t\t\t\t\t\t\t\t\t);\n\t\t$options_args['help_tabs'][] = array(\n\t\t\t\t\t\t\t\t\t'id' => 'kiwip-options-framework-1',\n\t\t\t\t\t\t\t\t\t'title' => 'Information Framework',\n\t\t\t\t\t\t\t\t\t'content' => '<p>This is the tab content, HTML is allowed. Information 2</p>'\n\t\t\t\t\t\t\t\t\t);\n\n\t\t//Set the Help Sidebar for the options page - no sidebar by default\t\t\t\t\t\t\t\t\t\t\n\t\t$options_args['help_sidebar'] = '<p>This is the sidebar content, HTML is allowed.</p>';\n\n\t\t$options_extra_tabs = array();\n\n\t\t/* Create page */\n\t\t$kiwip_options = new Kiwip_Theme_Options($options_args, $options_sections, $options_extra_tabs);\n\t}", "function optionPage() {\r\n\t\t$out = $uninstall = '';\r\n\r\n\t\t// Check write permissions\r\n\t\t$this->_checkDir();\r\n\r\n\t\t// Settings update or delete\r\n\t\tif(isset($_POST['options_update'])) { // options update\r\n\t\t\t// strip slashes array\r\n\t\t\t$_POST = $this->stripArray($_POST);\r\n\r\n\t\t\t$this->options['user_lvl'] = $_POST['vp_userlevel'];\r\n\t\t\t$this->options['show_option'] = $_POST['vp_show'];\r\n\t\t\t$this->options['class_name'] = $_POST['vp_classname'];\r\n\t\t\t$this->options['class_name_with_type'] = $_POST['vp_classwithtype'];\r\n\t\t\t$this->options['ins_shortcode'] = (isset($_POST['vp_shortcode']) && $_POST['vp_shortcode']=='1' ? '1' : '0');\r\n\t\t\t$this->updateOptions();\r\n\r\n\t\t\t$_POST = '';\r\n\t\t\t$this->note .= __('<strong>Done!</strong>', $this->textdomain_name);\r\n\r\n\t\t} elseif(isset($_POST['uninst'])) { // uninstall\r\n\t\t\t$this->deleteOptions();\r\n\t\t\tif (file_exists($this->data_dir))\r\n\t\t\t\t$this->_removeDir($this->data_dir);\r\n\t\t\t$this->note .= __('All files and folders have (probably) been deleted. Now click <strong>Plugins</strong> in the admin panel above and <b>Deactivate</b> the VideoPop plugin.', $this->textdomain_name);\r\n\t\t\t$this->note .= \"<br />\" . $this->data_dir;\r\n\t\t\t$this->error++;\r\n\t\t\t$this->initOptions();\r\n\t\t\terror_reporting(0);\r\n\t\t}\r\n\r\n\t\t// Add Options\r\n\t\t$out .= \"<div class=\\\"wrap\\\">\\n\";\r\n\t\t$out .= \"<h2>\".__('VideoPop+ Options', $this->textdomain_name).\"</h2><br />\\n\";\r\n\t\t$out .= \"<form method=\\\"post\\\" id=\\\"update_options\\\" action=\\\"\".$this->admin_action.\"\\\">\\n\";\r\n\t\t$out .= \"<table class=\\\"optiontable form-table\\\" style=\\\"margin-top:0;\\\"><tbody>\\n\";\r\n\r\n\t\t// Add User Level\r\n\t\t// Permission -- Subscriber = 0, Contributor = 1, Author = 2, Editor = 7, Administrator = 9\r\n\t\t$out .= \"<tr>\\n\";\r\n\t\t$out .= \"<td><strong>\".__('User Level', $this->textdomain_name).\"</strong></td>\";\r\n\t\t$out .= \"<td><select name=\\\"vp_userlevel\\\">\";\r\n\t\t$out .= \"<option value=\\\"0\\\"\".$this->_setOptionSelected($this->options['user_lvl'],'0').\">\".__('subscriber', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"1\\\"\".$this->_setOptionSelected($this->options['user_lvl'],'1').\">\".__('contributor', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"2\\\"\".$this->_setOptionSelected($this->options['user_lvl'],'2').\">\".__('author', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"7\\\"\".$this->_setOptionSelected($this->options['user_lvl'],'7').\">\".__('editor', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"9\\\"\".$this->_setOptionSelected($this->options['user_lvl'],'9').\">\".__('administrator', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"</select>&nbsp;</td>\";\r\n\t\t$out .= \"<td>\".__('Set the user level the user needs to have (at least) to manage/upload/delete videos', $this->textdomain_name).\"</td>\\n\";\r\n\t\t$out .= \"</tr>\\n\";\r\n\r\n\t\t// Add Method of display\r\n\t\t$out .= \"<tr>\\n\";\r\n\t\t$out .= \"<td><strong>\".__('Method of display', $this->textdomain_name).\"</strong></td>\";\r\n\t\t$out .= \"<td><select name=\\\"vp_show\\\">\";\r\n\t\t$out .= \"<option value=\\\"popup\\\"\" .$this->_setOptionSelected($this->options['show_option'],'popup').\">\". __('Pop up', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"lightpop\\\"\".$this->_setOptionSelected($this->options['show_option'],'lightpop').\">\".__('LightPop', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"inline\\\"\" .$this->_setOptionSelected($this->options['show_option'],'inline').\">\". __('In line', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"none\\\"\" .$this->_setOptionSelected($this->options['show_option'],'none').\">\". __('The effect none', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"</select>&nbsp;</td>\";\r\n\t\t$out .= \"<td>\".__('Please select it from &quot;Pop up&quot;, &quot;LightPop&quot;, &quot;In line&quot;, and &quot;The effect none&quot;.', $this->textdomain_name);\r\n\t\t$out .= \"</tr>\\n\";\r\n\r\n\t\t// Add Class Name Setting\r\n\t\t$out .= \"<tr style=\\\"border-style:none;\\\">\\n\";\r\n\t\t$out .= \"<td style=\\\"border-style:none;\\\"><strong>\".__('Class name of the link tag', $this->textdomain_name).\"</strong></td>\";\r\n\t\t$out .= \"<td style=\\\"border-style:none;\\\"><input type=\\\"text\\\" name=\\\"vp_classname\\\" value=\\\"\".$this->options['class_name'].\"\\\"/>&nbsp;</td>\";\r\n\t\t$out .= \"<td style=\\\"border-style:none;\\\">\".__('Please set the class name of the link tag.', $this->textdomain_name).\"</td>\\n\";\r\n\t\t$out .= \"</tr>\\n\";\r\n\t\t$out .= \"<tr>\\n\";\r\n\t\t$out .= \"<td></td>\";\r\n\t\t$out .= \"<td colspan=\\\"2\\\"><select name=\\\"vp_classwithtype\\\">\";\r\n\t\t$out .= \"<option value=\\\"0\\\"\".$this->_setOptionSelected($this->options['class_name_with_type'],'0').\">\".__('Without File Type', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"<option value=\\\"1\\\"\".$this->_setOptionSelected($this->options['class_name_with_type'],'1').\">\".__('With File Type', $this->textdomain_name).\"</option>\";\r\n\t\t$out .= \"</select>&nbsp;</td>\";\r\n\t\t$out .= \"</tr>\\n\";\r\n\r\n\t\t// Insert Editor Option (Shortcode or HTML Tag?)\r\n\t\t$out .= \"<tr>\\n\";\r\n\t\t$out .= \"<td><strong>\".__('Insert Editor Option', $this->textdomain_name).\"</strong></td>\";\r\n\t\t$out .= \"<td colspan=\\\"2\\\"><input type=\\\"checkbox\\\" name=\\\"vp_shortcode\\\" value=\\\"1\\\" style=\\\"margin-right:0.5em;\\\" \".($this->options['ins_shortcode']=='1' ? \" checked\" : \"\").\" />\".__('Shortcode is inserted in the editor.', $this->textdomain_name).\"</td>\";\r\n\t\t$out .= \"</tr>\\n\";\r\n\t\t$out .= \"<tr>\\n\";\r\n\r\n\t\t$out .= \"</tbody></table>\\n\";\r\n\r\n\t\t// Add Update Button\r\n\t\t$out .= \"<div style=\\\"text-align:right;margin-top:1em;\\\">\";\r\n\t\t$out .= \"<input type=\\\"submit\\\" name=\\\"options_update\\\" value=\\\"\".__('Update Options', $this->textdomain_name).\"\\\" class=\\\"button\\\" />\";\r\n\t\t$out .= \"</div>\";\r\n\t\t$out .= \"</form></div>\\n\";\r\n\r\n\t\t// Add uninstall\r\n\t\t$out .= \"<div class=\\\"wrap\\\" style=\\\"margin-top:2em;\\\">\\n\";\r\n\t\t$out .= \"<h2>\".__('Uninstall', $this->textdomain_name).\"</h2><br />\\n\";\r\n\t\t$out .= \"<p>\".__('If you want to keep your videos and the popup functionality of your links but want to get rid of the additional menus in the control panel, just deactivate the plugin.<br />For a complete uninstall including all uploaded videos use the uninstall button.', $this->textdomain_name).\"</p>\\n\";\r\n\t\t$out .= \"<div style=\\\"text-align:right;\\\">\";\r\n\t\t$out .= \"<form method=\\\"post\\\" id=\\\"uninstall\\\" action=\\\"\".$this->admin_action.\"\\\">\\n\";\r\n\t\t$out .= \"<input type=\\\"submit\\\" name=\\\"uninst\\\" value=\\\"\".__('Uninstall VideoPop+', $this->textdomain_name).\"\\\" onclick=\\\"javascript:check=confirm('\".__('You are about to delete all your settings and Videos! The links you created with VideoPop will not work after uninstall! Proceed with uninstall?', $this->textdomain_name).\"');if(check==false) return false;\\\" class=\\\"button\\\" />\\n\";\r\n\t\t$out .= \"</form>\\n\";\r\n\t\t$out .= \"</div>\\n\";\r\n\t\t$out .= \"</div>\\n\";\r\n\r\n\t\t// Output\r\n\t\techo (!empty($this->note) ? \"<div id=\\\"message\\\" class=\\\"updated fade\\\"><p>{$this->note}</p></div>\\n\" : '' ).\"\\n\";\r\n\t\techo ($this->error > 0 ? '' : $out).\"\\n\";\r\n\t}", "public function add_options_page() {\n add_options_page(\n __( 'Instagram Settings', 'bii-instagram' ),\n __( 'Instagram', 'bii-instagram' ),\n 'manage_options',\n 'bii-instagram',\n array( &$this, 'create_options_page' )\n );\n }", "function owa_options_page() {\r\n\t\r\n\t$owa = owa_getInstance();\r\n\t\r\n\t$params = array();\r\n\t$params['view'] = 'base.options';\r\n\t$params['subview'] = 'base.optionsGeneral';\r\n\techo $owa->handleRequest($params);\r\n\t\r\n\treturn;\r\n}", "function civ_slider_options_page(){\n add_options_page('Civ Slider Options', 'Civ Slider Options', 8, 'civ_slider', 'civ_slider_options');\n}", "public function view_option_page() {\n\t\tinclude_once plugin_dir_path( __FILE__ ) . 'options.php';\n\t}", "function add_options_page() {\n\t\tadd_options_page(\n\t\t\t'AdControl',\n\t\t\t'AdControl',\n\t\t\t'manage_options',\n\t\t\t'adcontrol',\n\t\t\tarray( $this, 'options_page' )\n\t\t);\n\t}", "public function add_options_pages() {\n if ( function_exists('acf_add_options_page') ) {\n acf_add_options_page(array(\n \"page_title\" => \"Explanatory Text\",\n \"capability\" => \"edit_posts\",\n \"position\" => 50,\n \"icon_url\" => \"dashicons-format-aside\"\n ));\n }\n }", "function optionsframework_options() {\n\t\t$options_pages = array(); \n\t\t$options_pages_obj = get_pages('sort_column=post_parent,menu_order');\n\t\t$options_pages[''] = 'Select a page:';\n\t\tforeach ($options_pages_obj as $page):\n\t\t\t$options_pages[$page->ID] = $page->post_title;\n\t\tendforeach;\n\t\n\t\t// If using image radio buttons, define a directory path\n\t\t$imagepath = get_template_directory_uri() . '/lib/assets/images/icons/';\n\t\n\t\t$options = array();\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('General Settings', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Favicon', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To upload your favicon to the site, simply add the URL to it or upload and select it using the Upload button here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_favicon',\n\t\t\t'type' \t\t=> 'upload');\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('RSS Link', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Add in the URL of your RSS feed here to overwrite the defaut WordPress ones.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_rss',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Custom CSS', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Not 100% happy with our lovely styles? Here you can add some custom CSS if you require minor changes to the ones we\\'ve created. We won\\'t be offended, honest :)', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_css',\n\t\t\t'type' \t\t=> 'textarea');\t\n\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Google Analytics (or custom Javascript)', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If you\\'re hooked up with Google Analytics you can paste the Javascript includes for it here (without the script tags). Or alternatively if you just want some custom Javascript added on top of ours, add that here too.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_js',\n\t\t\t'type' \t\t=> 'textarea');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Breadcrumb Trail?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the breadcrumb trail on all pages in the header.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_breadcrumbs',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Application Form ID', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_application_form_id',\n\t\t\t'desc'\t\t=> 'If you have added an applcation form for the jobs section of your site using the Contact Form & plugin, you can add the ID of the form here for it to be pulled out automatically.',\n\t\t\t'std' \t\t=> '',\n\t\t\t'type' \t\t=> 'text');\t\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Header', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Custom Logo', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To upload a custom logo, simply add the URL to it or upload and select it using the Upload button here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_custom_logo',\n\t\t\t'type' \t\t=> 'upload');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Header Text', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_header_text',\n\t\t\t'des'\t\t=> 'You can add some text to the header if you like. Keep it short and sweet mind; nobody likes a waffler :)',\n\t\t\t'std' \t\t=> '',\n\t\t\t'type' \t\t=> 'text');\t\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Contact Telephone', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your contact telephone number here to go in the header.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_header_phone',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __('Footer', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __('Copyright Text', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the text for your copyright here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_footer_copyright',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Hide FrogsThemes Link?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will hide our link :\\'( <--sad face', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_hide_ft_link',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Blog', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Style', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Select if you prefer the blog to be as a list or in masonry.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_blog_style',\n\t\t\t'options' \t=> array('list' => __('List', 'frogsthemes'), 'masonry' => __('Masonry', 'frogsthemes')),\n\t\t\t'std'\t\t=> 'list',\n\t\t\t'type' \t\t=> 'select');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Share Links?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the share links on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_share_links',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Author Box?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the author box on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_author',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Next/Previous Links?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the next/previous post links on all posts.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_next_prev',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Show Related Posts?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will show the related posts section. These are related by tag.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_show_related_posts',\n\t\t\t'std' \t\t=> '1',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Slider', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Speed of Transition', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the speed you would like the transition to be in milliseconds (1000 = 1 second).', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_speed',\n\t\t\t'std'\t\t=> '600',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Pause Time', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter the time you would like the gallery to pause between transitions in milliseconds (1000 = 1 second).', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_pause',\n\t\t\t'std'\t\t=> '7000',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Auto Start?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will automatically start the gallery.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_auto_start',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Auto Loop?', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('If checked, this will automatically loop through the gallery.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_loop',\n\t\t\t'std' \t\t=> '0',\n\t\t\t'type' \t\t=> 'checkbox');\n\t\t/*\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Animation Type', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Select which effect you would like to use when going between slides.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_slider_transition',\n\t\t\t'options' \t=> array('fade' => __('Fade', 'frogsthemes'), 'slide' => __('Slide', 'frogsthemes')),\n\t\t\t'std'\t\t=> 'fade',\n\t\t\t'type' \t\t=> 'select');\n\t\t*/\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Connections', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Facebook URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Facebook URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_facebook',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Twitter URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Twitter URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_twitter',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Google+ URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Google+ URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_google_plus',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'LinkedIn URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full LinkedIn URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_linkedin',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'Pinterest URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full Pinterest URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_pinterest',\n\t\t\t'type' \t\t=> 'text');\n\t\t\n\t\t$options[] = array( \n\t\t\t'name' \t\t=> __( 'YouTube URL', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('Enter your full YouTube URL here.', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'ft_youtube',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Twitter API Options', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'heading');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Twitter API', 'frogsthemes'),\n\t\t\t'desc' \t\t=> __('To use the Twitter API, you need to sign up for an <a href=\"https://dev.twitter.com/apps\" target=\"_blank\">app with Twitter</a>.', 'frogsthemes'),\n\t\t\t'type' \t\t=> 'info');\n\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Consumer Key', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'consumer_key',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Consumer Secret', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'consumer_secret',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Access Token', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'access_token',\n\t\t\t'type' \t\t=> 'text');\n\t\t\t\t\t\t\t\n\t\t$options[] = array(\n\t\t\t'name' \t\t=> __( 'Access Token Secret', 'frogsthemes'),\n\t\t\t'id' \t\t=> 'access_token_secret',\n\t\t\t'type' \t\t=> 'text');\n\t\n\t\treturn apply_filters('optionsframework_options', $options);\n\t}", "function options_page_html()\n\t\t{\n\t\t\tif (!current_user_can('manage_options')) {\n\t\t\t\twp_die(__('You do not have sufficient permissions to access this page.'));\n\t\t\t}\n\t\t\t\n\t\t\techo '<div class=\"wrap\">';\n\t\t\techo '<h2>';\n\t\t\techo 'Verify Meta Tags Plugin Options';\n\t\t\techo '</h2>';\n\t\t\techo '<form method=\"post\" action=\"options.php\">';\n\t\t\tsettings_fields('vmt-options-page');\n\t\t\tdo_settings_sections('vmt-options-page');\n\t\t\techo '<p class=submit>';\n\t\t\techo '<input type=\"submit\" class=\"button-primary\" value=\"' . __('Save Changes') . '\" />';\n\t\t\techo '</p>';\n\t\t\techo '</form>';\n\t\t\techo '</div>';\n\t\t}", "public function option_page() {\n\t\tif ( ! current_user_can( 'manage_options' ) ) {\n\t\t\twp_die( esc_html__( 'You do not have sufficient permissions to access this page.', 'top-story' ) );\n\t\t}\n\n\t\tinclude_once( \"{$this->plugin->dir_path}/templates/option-page.php\" );\n\t}", "function add_options_page() {\n\t\t\t\tif ( function_exists('add_theme_page') ) {\n\t\t\t\t \tadd_theme_page( 'Cap &amp; Run', 'Cap &amp; Run', 'manage_options', \n\t\t\t\t\t\t\t\t\tbasename(__FILE__), array(&$this, 'options_page') );\n\t\t\t\t}\n\t\t\t}", "public function acf_options_page() { \n\n\t\t\t// Check ACF Admin OK\n\t\t\tif ( ! $this->admin_acf_active() ) { return; }\n\n\t\t\t// Check Options Page OK \n\t\t\tif ( ! function_exists('acf_add_options_page') ) { return; }\n\t\t\t\n\t\t\t// Add Options Page\n\t\t\t$parent = acf_add_options_page( [ \n\t\t\t\t'title' => apply_filters( 'ipress_acf_title', 'iPress' ), \n\t\t\t\t'capability' => 'manage_options', \n\t\t\t] ); \n\n\t\t\t// Set Options Page Subpages\n\t\t\t$subpages = apply_filters( 'ipress_acf_pages', [] );\n\t \n\t\t\t// Add Subpages? \n\t\t\tif ( $subpages ) {\n\t\t\t\tforeach ( $subpages as $k=>$v ) {\n\t\t\t\t\tacf_add_options_sub_page( $v );\n\t\t\t\t} \n\t\t\t}\n\t\t}", "function adminOptions() {\r\n\t\t\tTrackTheBookView::render('admin-options');\r\n\t\t}", "function rkt_options_page() {\n require('tmpl/options.tmpl.php');\n}", "function options_page() {\n\t\t$settings = __( 'AdControl Settings', 'adcontrol' );\n\t\t$notice = sprintf(\n\t\t\t__( 'AdControl requires %sJetpack%s to be installed and connected at this time. %sHelp getting started.%s', 'adcontrol' ),\n\t\t\t'<a href=\"https://jetpack.com/\" target=\"_blank\">', '</a>',\n\t\t\t'<a href=\"https://jetpack.com/support/getting-started-with-jetpack/\" target=\"_blank\">', '</a>'\n\t\t);\n\n\t\techo <<<HTML\n\t\t<div class=\"wrap\">\n\t\t\t<div id=\"icon-options-general\" class=\"icon32\"><br></div>\n\t\t\t<h2>$settings</h2>\n\t\t\t<p>$notice</p>\n\t\t</div>\nHTML;\n\t}", "public function create_page()\n {\n ?>\n <div class=\"wrap\">\n <div id=\"icon-users\">\n <?php\n echo '<h1>' . esc_html__('Available Cron Schedules') . '</h1>'; \n $this->screen = get_current_screen();\n $this->prepare_items();\n $this->display();\n ?>\n </div>\n <?php settings_errors(); ?>\n <form method=\"post\" action=\"options.php\">\n <?php \n //Prints out all hidden fields\n settings_fields('custom-schedules-group');\n do_settings_sections('custom-schedules-admin');\n submit_button();\n ?>\n </form>\n </div>\n <?php \n }", "public static function options_page()\n\t\t\t{\n\t\t\t\tif (!current_user_can('manage_options'))\n\t\t\t\t{\n\t\t\t\t\twp_die( __('You do not have sufficient permissions to access this page.') );\n\t\t\t\t}\n\t\n\t\t\t\t$plugin_id = HE_PLUGINOPTIONS_ID;\n\t\t\t\t// display options page\n\t\t\t\tinclude(self::file_path('options.php'));\n\t\t\t}", "function options_page(){\r\n include($this->plugin_dir.'/include/options-page.php');\r\n }", "function create_options_page($element)\n\t{\n\t\t$output = \"\";\n\t\t\n\t\t$output .= '<div class=\"ace_create_options_container\">';\n\t\t$output .= '\t<span class=\"ace_style_wrap ace_create_options_style_wrap\">';\n\t\t$output .= '\t<input type=\"text\" class=\"ace_create_options_page_new_name ace_dont_activate_save_buttons'.$element['class'].'\" value=\"\" name=\"'.$element['id'].'\" id=\"'.$element['id'].'\" />';\n\t\t$output .= '\t<a href=\"#\" class=\"ace_button ace_create_options ace_button_inactive\" title=\"'.$element['name'].'\" id=\"ace_'.$element['id'].'\">'.$element['label'].'</a>';\n\t\t$output .= '\t<span class=\"ace_loading ace_beside_button_loading\"></span>';\n\t\t$output .= '\t</span>';\n\t\t$output .= '\t<input class=\"ace_create_options_page_temlate_sortable\" type=\"hidden\" value=\"'.$element['template_sortable'].'\" />';\n\t\t$output .= '\t<input class=\"ace_create_options_page_temlate_parent\" type=\"hidden\" value=\"'.$element['temlate_parent'].'\" />';\n\t\t$output .= '\t<input class=\"ace_create_options_page_temlate_icon\" type=\"hidden\" value=\"'.$element['temlate_icon'].'\" />';\n\t\t$output .= '\t<input class=\"ace_create_options_page_temlate_remove_label\" type=\"hidden\" value=\"'.$element['remove_label'].'\" />';\n\t\tif(isset($element['temlate_default_elements']))\n\t\t{\n\t\t\t$elString = base64_encode(serialize($element['temlate_default_elements']));\n\t\t\t$output .= '\t<input class=\"ace_create_options_page_subelements_of\" type=\"hidden\" value=\"'.$elString.'\" />';\n\t\t}\n\t\t$output .= '</div>';\n\t\treturn $output;\n\t}", "function ba_options_page() {\n add_menu_page(\n 'ba Theme Options', // Page title\n 'Theme Options', // Menu title\n 'manage_options', // Capability\n 'ba_options', // Menu slug\n 'ba_options_page_html', // Display\n 'dashicons-format-video', // Icon\n 150\n );\n}", "public function display_options_page() {\n\t\t?>\n\t\t<div class=\"wrap ee-breakouts-admin\">\n\t\t\t<div id=\"icon-options-general\" class=\"icon32\"></div>\n\t\t\t<h2><?php _e('EE Breakouts Settings', 'event_espresso'); ?></h2>\n\t\t\t<div id=\"poststuff\">\n\t\t\t\t<div id=\"post-body-content\">\n\t\t\t\t\t<div class=\"form-wrap\">\n\t\t\t\t\t\t<form action=\"options.php\" method=\"post\">\n\t\t\t\t\t\t\t<?php settings_fields('ee_breakout_options'); ?>\n\t\t\t\t\t\t\t<?php do_settings_sections('ee_breakouts_admin'); ?>\n\t\t\t\t\t\t\t<span class=\"submit\">\n\t\t\t\t\t\t\t\t<input type=\"submit\" class=\"button primary-button\" name=\"update_ee_breakout_options\" value=\"Save Options\" />\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</form>\n\t\t\t\t\t</div> <!-- end .form-wrap -->\n\t\t\t\t</div> <!-- end #post-body-content -->\n\t\t\t</div> <!-- end #poststuff -->\n\t\t</div> <!-- end .wrap -->\n\t\t<?php\n\t}", "function abecaf_register_options_page() {\n add_options_page( 'CAF Donations', 'CAF Donations', 'manage_options', 'abe-caf', 'abecaf_options_page' );\n}", "public function main_options_page(){\n\t\t$page_base = $this->page_url();\n\t\tob_start();\n\t\t?>\n\t\t<div class=\"wp_lms settings\">\n\t\t\t<h1>GrandPubbah</h1>\n\n\t\t</div>\n\t\t<?\n\t\tob_end_flush();\n\t}", "public static function register_page_options() {\n\n\t\t// Register settings\n\t\tregister_setting( 'wpex_under_construction', 'under_construction', array( 'WPEX_Under_Construction', 'sanitize' ) );\n\n\t\t// Add main section to our options page\n\t\tadd_settings_section( 'wpex_under_construction_main', false, array( 'WPEX_Under_Construction', 'section_main_callback' ), 'wpex-under-construction-admin' );\n\n\t\t// Redirect field\n\t\tadd_settings_field(\n\t\t\t'under_construction',\n\t\t\tesc_html__( 'Enable Under Constuction', 'total' ),\n\t\t\tarray( 'WPEX_Under_Construction', 'redirect_field_callback' ),\n\t\t\t'wpex-under-construction-admin',\n\t\t\t'wpex_under_construction_main'\n\t\t);\n\n\t\t// Custom Page ID\n\t\tadd_settings_field(\n\t\t\t'under_construction_page_id',\n\t\t\tesc_html__( 'Under Construction page', 'total' ),\n\t\t\tarray( 'WPEX_Under_Construction', 'content_id_field_callback' ),\n\t\t\t'wpex-under-construction-admin',\n\t\t\t'wpex_under_construction_main'\n\t\t);\n\n\t}", "function inkpro_create_options() {\r\n\treturn array();\r\n}", "function wpec_gd_options_page() {\n\tadd_options_page( __( 'WPEC Group Deal Options', 'wpec-group-deals' ), __( 'Group Deals', 'wpec-group-deals' ), 'administrator', 'wpec_gd_options', 'wpec_gd_options_page_form' );\n}", "public function render_options_page()\n\t{\n\t\treturn include 'src/views/form.php';\n\t}", "public static function init_options_page() {\n\n\t\t$option_page = acf_add_options_page([\n\t\t\t'page_title' => __('Theme Options', 'sage'),\n\t\t\t'menu_title' => 'Theme Options',\n\t\t\t'menu_slug' => 'theme-options',\n\t\t\t'capability' => 'edit_posts',\n\t\t\t'redirect' => true,\n\t\t\t'icon_url' => false,\n\t\t\t'position' => 40,\n\t\t\t'autoload' => true\n\t\t]);\n\n\t\treturn $option_page;\n\t}", "function ctc_add_page() {\n add_options_page('CTC', 'CTC', 8, 'ctcoptions', 'ctc_options_page');\n}", "function initlab_options_page() {\n add_menu_page(\n __('init Lab Options', 'initlab-addons'),\n __('init Lab', 'initlab-addons'),\n 'manage_options',\n 'initlab',\n 'initlab_options_page_html'\n );\n}", "public static function generate_options ()\n\t{\n\t\t// Location options\n\t\tadd_option(\"wustache_base_folder\", 'templates');\n\t}", "public function admin_options() {\n\n\t\t\t?>\n\t\t\t<h3>ATOS</h3>\n\t\t\t<p><?php _e('Acceptez les paiements par carte bleue grâce à Atos.', 'woothemes'); ?></p>\n\t\t\t<p><?php _e('Plugin créé par David Fiaty', 'woothemes'); ?> - <a href=\"http://www.cmsbox.fr\">http://www.cmsbox.fr</a></p>\n\t\t\t<table class=\"form-table\">\n\t\t\t<?php\n\t\t\t\t// Generate the HTML For the settings form.\n\t\t\t\t$this->generate_settings_html();\n\t\t\t?>\n\t\t\t</table><!--/.form-table-->\n\t\t\t<?php\n\t\t}", "function vmt_options_page()\n\t\t{\n\t\t\t// Create the options page\n\t\t\t$options_page = add_options_page(\n\t\t\t\t'Verify Meta Tags Plugin Options', \n\t\t\t\t'Verify Meta Tags',\n\t\t\t\t'manage_options',\n\t\t\t\t'vmt-options-page', \n\t\t\t\tarray(&$this, 'options_page_html')\n\t\t\t);\n\t\t\t\n\t\t\tadd_action( 'admin_print_styles-' . $options_page, array($this, 'enqueue_admin_styles'), 1000 );\n\t\t\t\n\t\t\t// Add settings section\n\t\t\t\n\t\t\tadd_settings_section( \n\t\t\t\t'vmt-options-section', \n\t\t\t\t'Owner Verification Meta Tags', \n\t\t\t\tarray( &$this, 'display_ID_section_html'), \n\t\t\t\t'vmt-options-page'\n\t\t\t);\n\t\t\t\n\t\t\t// Google verification ID\n\t\t\tadd_settings_field(\n\t\t\t\t'verify-meta-tags[google]',\t\n\t\t\t\t'Google Verification ID', \n\t\t\t\tarray( &$this, 'display_verify_id_html' ), \n\t\t\t\t'vmt-options-page', \n\t\t\t\t'vmt-options-section',\n\t\t\t\tarray('code'=>'google') \n\t\t\t);\n\n\t\t\t// Pinterest verification ID\n\t\t\tadd_settings_field(\n\t\t\t\t'verify-meta-tags[pinterest]',\t\n\t\t\t\t'Pinterest Verification ID', \n\t\t\t\tarray( &$this, 'display_verify_id_html' ), \n\t\t\t\t'vmt-options-page', \n\t\t\t\t'vmt-options-section',\n\t\t\t\tarray('code'=>'pinterest') \n\t\t\t);\n\t\t\t\n\t\t\t// Analytics Code block in it's own section\n\t\t\tadd_settings_section( \n\t\t\t\t'vmt-options-analytics-section', \n\t\t\t\t'Site Statistics Tracking', \n\t\t\t\tarray( &$this, 'display_analytics_section_html'), \n\t\t\t\t'vmt-options-page'\n\t\t\t);\n\t\t\tadd_settings_field(\n\t\t\t\t'verify-meta-tags[analytics]',\t\n\t\t\t\t'Analytics code', \n\t\t\t\tarray( &$this, 'display_analytics_html' ), \n\t\t\t\t'vmt-options-page', \n\t\t\t\t'vmt-options-analytics-section',\n\t\t\t\tarray('code'=>'analytics') \n\t\t\t);\n\t\t}", "public function acf_wpi_option_page() {\n\t\t// Prevent init acf wpi options if acf/acf-pro not activated.\n\t\tif ( ! class_exists( 'acf' ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\tacf_add_options_page(\n\t\t\tarray(\n\t\t\t\t'page_title' => __( 'ACF Wpi Options', 'acf_wpi' ),\n\t\t\t\t'menu_slug' => 'acf_wpi_options_page',\n\t\t\t\t'parent_slug' => 'options-general.php',\n\t\t\t)\n\t\t);\n\t\tModuleLoader::get_instance()->register_options_container();\n\t}", "public static function add_options_page() {\n\n if ( is_admin() && function_exists( 'acf_add_options_page' ) ) {\n\n $dustpress_components = array(\n 'page_title' => __( 'DustPress components settings', 'dustpress-components' ),\n 'menu_title' => __( 'Components settings', 'dustpress-components' ),\n 'menu_slug' => __( 'components-settings', 'dustpress-components' ),\n 'capability' => 'manage_options',\n );\n acf_add_options_page( $dustpress_components );\n }\n\n }", "function wpdc_divi_child_options_page(){\r\n\t\t\r\n\t\t$options = get_option('wpdc_options');\r\n\t\t\r\n echo '<div class=\"wrap\">';\r\n\t\techo '<h2>'.WPDC_THEME_NAME.' Options <span style=\"font-size:10px;\">Ver '.WPDC_VER.'</span></h2>';\r\n\t\techo '<form method=\"post\" action=\"options.php\">';\r\n\t\tsettings_fields('wpdc_plugin_options_group');\r\n\t\tsettings_errors();\r\n\t\trequire_once('views.php');\t\t// load table settings\r\n\t\techo '<div style=\"clear:both;\"></div>';\r\n\t\techo '</div>';\r\n\t\techo '<div style=\"clear:both;\"></div>';\r\n echo '</form>';\r\n }", "public function options_page_init(){\n\t\t\tadd_options_page(__('Breaking News options', 'text-domain'), __('Breaking News', 'text-domain'), 'manage_options', 'breakingnews', [ $this, 'options_page_content']);\n\t\t}", "function SetupOtherOptions() {\n\t\tglobal $Language, $Security;\n\t\t$options = &$this->OtherOptions;\n\t\t$option = &$options[\"action\"];\n\n\t\t// Add\n\t\t$item = &$option->Add(\"add\");\n\t\t$addcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageAddLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->AddUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->AddUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\n\t\t$item->Visible = ($this->AddUrl <> \"\" && $Security->CanAdd());\n\n\t\t// Edit\n\t\t$item = &$option->Add(\"edit\");\n\t\t$editcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageEditLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->EditUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->EditUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\n\t\t$item->Visible = ($this->EditUrl <> \"\" && $Security->CanEdit());\n\n\t\t// Copy\n\t\t$item = &$option->Add(\"copy\");\n\t\t$copycaption = ew_HtmlTitle($Language->Phrase(\"ViewPageCopyLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,btn:'AddBtn',url:'\" . ew_HtmlEncode($this->CopyUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->CopyUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\n\t\t$item->Visible = ($this->CopyUrl <> \"\" && $Security->CanAdd());\n\n\t\t// Delete\n\t\t$item = &$option->Add(\"delete\");\n\t\tif ($this->IsModal) // Handle as inline delete\n\t\t\t$item->Body = \"<a onclick=\\\"return ew_ConfirmDelete(this);\\\" class=\\\"ewAction ewDelete\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode(ew_UrlAddQuery($this->DeleteUrl, \"a_delete=1\")) . \"\\\">\" . $Language->Phrase(\"ViewPageDeleteLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewDelete\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->DeleteUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageDeleteLink\") . \"</a>\";\n\t\t$item->Visible = ($this->DeleteUrl <> \"\" && $Security->CanDelete());\n\n\t\t// Set up action default\n\t\t$option = &$options[\"action\"];\n\t\t$option->DropDownButtonPhrase = $Language->Phrase(\"ButtonActions\");\n\t\t$option->UseImageAndText = TRUE;\n\t\t$option->UseDropDownButton = FALSE;\n\t\t$option->UseButtonGroup = TRUE;\n\t\t$item = &$option->Add($option->GroupOptionName);\n\t\t$item->Body = \"\";\n\t\t$item->Visible = FALSE;\n\t}", "function SetupOtherOptions() {\n\t\tglobal $Language, $Security;\n\t\t$options = &$this->OtherOptions;\n\t\t$option = &$options[\"action\"];\n\n\t\t// Add\n\t\t$item = &$option->Add(\"add\");\n\t\t$addcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageAddLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->AddUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->AddUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\n\t\t$item->Visible = ($this->AddUrl <> \"\" && $Security->CanAdd());\n\n\t\t// Edit\n\t\t$item = &$option->Add(\"edit\");\n\t\t$editcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageEditLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->EditUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->EditUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\n\t\t$item->Visible = ($this->EditUrl <> \"\" && $Security->CanEdit());\n\n\t\t// Copy\n\t\t$item = &$option->Add(\"copy\");\n\t\t$copycaption = ew_HtmlTitle($Language->Phrase(\"ViewPageCopyLink\"));\n\t\tif ($this->IsModal) // Modal\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,btn:'AddBtn',url:'\" . ew_HtmlEncode($this->CopyUrl) . \"'});\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->CopyUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\n\t\t$item->Visible = ($this->CopyUrl <> \"\" && $Security->CanAdd());\n\n\t\t// Delete\n\t\t$item = &$option->Add(\"delete\");\n\t\tif ($this->IsModal) // Handle as inline delete\n\t\t\t$item->Body = \"<a onclick=\\\"return ew_ConfirmDelete(this);\\\" class=\\\"ewAction ewDelete\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode(ew_UrlAddQuery($this->DeleteUrl, \"a_delete=1\")) . \"\\\">\" . $Language->Phrase(\"ViewPageDeleteLink\") . \"</a>\";\n\t\telse\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewDelete\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->DeleteUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageDeleteLink\") . \"</a>\";\n\t\t$item->Visible = ($this->DeleteUrl <> \"\" && $Security->CanDelete());\n\n\t\t// Set up action default\n\t\t$option = &$options[\"action\"];\n\t\t$option->DropDownButtonPhrase = $Language->Phrase(\"ButtonActions\");\n\t\t$option->UseImageAndText = TRUE;\n\t\t$option->UseDropDownButton = FALSE;\n\t\t$option->UseButtonGroup = TRUE;\n\t\t$item = &$option->Add($option->GroupOptionName);\n\t\t$item->Body = \"\";\n\t\t$item->Visible = FALSE;\n\t}", "public function plugin_add_options_page() {\r\n\t\t$this->page = add_options_page(__($this->options_page_title), __($this->options_page_name), 'manage_options', $this->slug, array($this, 'plugin_create_options_page'));\r\n\t\tadd_filter( 'plugin_action_links', array(&$this, 'plugin_add_settings_link'), 10, 2 );\r\n\t\t\r\n\t\t// Run stuff when the plugin options page loads\r\n\t\tadd_action('load-'.$this->page, array(&$this, 'plugin_loading_options_page'));\r\n\t}", "public function add_options_page() {\r\n\t\t$slug = $this->key;\r\n\t\t$function = array( $this, 'admin_page_display' );\r\n\t\t$capability = 'delete_others_pages';\r\n\t\t$Menutitle = $this->optionsTitle;\r\n\t\t$pageTitle = $this->optionsTitle;\r\n\t\tif(!$this->subpage) :\r\n\t\t\t$this->options_page = add_menu_page( $pageTitle,$Menutitle, $capability, $slug, $function, $this->icon, $this->index );\r\n\t\telse :\r\n\t\t\t$this->options_page = add_submenu_page( $this->subpage, $pageTitle, $Menutitle, $capability, $slug, $function );\r\n\t\tendif;\r\n\t\t// Include CMB CSS in the head\r\n\t\tadd_action( \"admin_print_styles-{$this->options_page}\", array( 'CMB2_hookup', 'enqueue_cmb_css' ) );\r\n\t}", "function create_theme_options_page() {\n global $lulisaurus_settings_page;\n\n $lulisaurus_settings_page = add_menu_page('Optionen', 'Optionen', 'read', 'lulisaurus_settings', 'build_options_page', 'dashicons-lightbulb');\n\n // Add contextual help\n add_action( 'load-' . $lulisaurus_settings_page, 'add_contextual_theme_help' );\n}", "function addOptionsPage(){\n\t\tadd_options_page( 'Post icon', 'Post icon', 'manage_options', 'post_icon_options', array( $this, 'showPostIconOptions' ) );\n\t}", "public function add_options_page()\n {\n $this->options_page = add_menu_page($this->title, $this->title, 'delete_others_pages', $this->key, array($this, 'admin_page_display'));\n // Include CMB CSS in the head to avoid FOUC\n add_action(\"admin_print_styles-{$this->options_page}\", array('CMB2_hookup', 'enqueue_cmb_css'));\n }", "public function registerOptionsPage()\n {\n add_submenu_page(\n 'tools.php',\n 'PostmanCanFail Settings',\n 'PostmanCanFail',\n 'administrator',\n __FILE__,\n [$this, 'settingsPage']\n );\n }", "public function acf_options_page()\n {\n if( function_exists('acf_add_options_page') ) {\n\n acf_add_options_page(array(\n 'page_title' \t=> 'Import / Export',\n 'menu_title'\t=> 'Import / Export',\n 'menu_slug' \t=> 'import-export-addressbook',\n 'capability'\t=> 'edit_posts',\n 'parent_slug' => 'edit.php?post_type=mv_address_book',\n 'redirect'\t\t=> false\n ));\n\n }\n }", "function SetupOtherOptions() {\r\n\t\tglobal $Language, $Security;\r\n\t\t$options = &$this->OtherOptions;\r\n\t\t$option = &$options[\"action\"];\r\n\r\n\t\t// Add\r\n\t\t$item = &$option->Add(\"add\");\r\n\t\t$addcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageAddLink\"));\r\n\t\tif ($this->IsModal) // Modal\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->AddUrl) . \"',caption:'\" . $addcaption . \"'});\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\r\n\t\telse\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . $addcaption . \"\\\" data-caption=\\\"\" . $addcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->AddUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\r\n\t\t$item->Visible = ($this->AddUrl <> \"\" && $Security->CanAdd());\r\n\r\n\t\t// Edit\r\n\t\t$item = &$option->Add(\"edit\");\r\n\t\t$editcaption = ew_HtmlTitle($Language->Phrase(\"ViewPageEditLink\"));\r\n\t\tif ($this->IsModal) // Modal\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->EditUrl) . \"',caption:'\" . $editcaption . \"'});\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\r\n\t\telse\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . $editcaption . \"\\\" data-caption=\\\"\" . $editcaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->EditUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\r\n\t\t$item->Visible = ($this->EditUrl <> \"\" && $Security->CanEdit());\r\n\r\n\t\t// Copy\r\n\t\t$item = &$option->Add(\"copy\");\r\n\t\t$copycaption = ew_HtmlTitle($Language->Phrase(\"ViewPageCopyLink\"));\r\n\t\tif ($this->IsModal) // Modal\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"javascript:void(0);\\\" onclick=\\\"ew_ModalDialogShow({lnk:this,url:'\" . ew_HtmlEncode($this->CopyUrl) . \"',caption:'\" . $copycaption . \"'});\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\r\n\t\telse\r\n\t\t\t$item->Body = \"<a class=\\\"ewAction ewCopy\\\" title=\\\"\" . $copycaption . \"\\\" data-caption=\\\"\" . $copycaption . \"\\\" href=\\\"\" . ew_HtmlEncode($this->CopyUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageCopyLink\") . \"</a>\";\r\n\t\t$item->Visible = ($this->CopyUrl <> \"\" && $Security->CanAdd());\r\n\r\n\t\t// Delete\r\n\t\t$item = &$option->Add(\"delete\");\r\n\t\t$item->Body = \"<a onclick=\\\"return ew_ConfirmDelete(this);\\\" class=\\\"ewAction ewDelete\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageDeleteLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->DeleteUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageDeleteLink\") . \"</a>\";\r\n\t\t$item->Visible = ($this->DeleteUrl <> \"\" && $Security->CanDelete());\r\n\t\t$option = &$options[\"detail\"];\r\n\t\t$DetailTableLink = \"\";\r\n\t\t$DetailViewTblVar = \"\";\r\n\t\t$DetailCopyTblVar = \"\";\r\n\t\t$DetailEditTblVar = \"\";\r\n\r\n\t\t// \"detail_observacion_tutor\"\r\n\t\t$item = &$option->Add(\"detail_observacion_tutor\");\r\n\t\t$body = $Language->Phrase(\"ViewPageDetailLink\") . $Language->TablePhrase(\"observacion_tutor\", \"TblCaption\");\r\n\t\t$body .= str_replace(\"%c\", $this->observacion_tutor_Count, $Language->Phrase(\"DetailCount\"));\r\n\t\t$body = \"<a class=\\\"btn btn-default btn-sm ewRowLink ewDetail\\\" data-action=\\\"list\\\" href=\\\"\" . ew_HtmlEncode(\"observacion_tutorlist.php?\" . EW_TABLE_SHOW_MASTER . \"=tutores&fk_Dni_Tutor=\" . urlencode(strval($this->Dni_Tutor->CurrentValue)) . \"\") . \"\\\">\" . $body . \"</a>\";\r\n\t\t$links = \"\";\r\n\t\tif ($GLOBALS[\"observacion_tutor_grid\"] && $GLOBALS[\"observacion_tutor_grid\"]->DetailView && $Security->CanView() && $Security->AllowView(CurrentProjectID() . 'observacion_tutor')) {\r\n\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailView\\\" data-action=\\\"view\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailViewLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetViewUrl(EW_TABLE_SHOW_DETAIL . \"=observacion_tutor\")) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailViewLink\")) . \"</a></li>\";\r\n\t\t\tif ($DetailViewTblVar <> \"\") $DetailViewTblVar .= \",\";\r\n\t\t\t$DetailViewTblVar .= \"observacion_tutor\";\r\n\t\t}\r\n\t\tif ($GLOBALS[\"observacion_tutor_grid\"] && $GLOBALS[\"observacion_tutor_grid\"]->DetailEdit && $Security->CanEdit() && $Security->AllowEdit(CurrentProjectID() . 'observacion_tutor')) {\r\n\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailEdit\\\" data-action=\\\"edit\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailEditLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetEditUrl(EW_TABLE_SHOW_DETAIL . \"=observacion_tutor\")) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailEditLink\")) . \"</a></li>\";\r\n\t\t\tif ($DetailEditTblVar <> \"\") $DetailEditTblVar .= \",\";\r\n\t\t\t$DetailEditTblVar .= \"observacion_tutor\";\r\n\t\t}\r\n\t\tif ($GLOBALS[\"observacion_tutor_grid\"] && $GLOBALS[\"observacion_tutor_grid\"]->DetailAdd && $Security->CanAdd() && $Security->AllowAdd(CurrentProjectID() . 'observacion_tutor')) {\r\n\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailCopy\\\" data-action=\\\"add\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailCopyLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetCopyUrl(EW_TABLE_SHOW_DETAIL . \"=observacion_tutor\")) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailCopyLink\")) . \"</a></li>\";\r\n\t\t\tif ($DetailCopyTblVar <> \"\") $DetailCopyTblVar .= \",\";\r\n\t\t\t$DetailCopyTblVar .= \"observacion_tutor\";\r\n\t\t}\r\n\t\tif ($links <> \"\") {\r\n\t\t\t$body .= \"<button class=\\\"dropdown-toggle btn btn-default btn-sm ewDetail\\\" data-toggle=\\\"dropdown\\\"><b class=\\\"caret\\\"></b></button>\";\r\n\t\t\t$body .= \"<ul class=\\\"dropdown-menu\\\">\". $links . \"</ul>\";\r\n\t\t}\r\n\t\t$body = \"<div class=\\\"btn-group\\\">\" . $body . \"</div>\";\r\n\t\t$item->Body = $body;\r\n\t\t$item->Visible = $Security->AllowList(CurrentProjectID() . 'observacion_tutor');\r\n\t\tif ($item->Visible) {\r\n\t\t\tif ($DetailTableLink <> \"\") $DetailTableLink .= \",\";\r\n\t\t\t$DetailTableLink .= \"observacion_tutor\";\r\n\t\t}\r\n\t\tif ($this->ShowMultipleDetails) $item->Visible = FALSE;\r\n\r\n\t\t// Multiple details\r\n\t\tif ($this->ShowMultipleDetails) {\r\n\t\t\t$body = $Language->Phrase(\"MultipleMasterDetails\");\r\n\t\t\t$body = \"<div class=\\\"btn-group\\\">\";\r\n\t\t\t$links = \"\";\r\n\t\t\tif ($DetailViewTblVar <> \"\") {\r\n\t\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailView\\\" data-action=\\\"view\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailViewLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetViewUrl(EW_TABLE_SHOW_DETAIL . \"=\" . $DetailViewTblVar)) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailViewLink\")) . \"</a></li>\";\r\n\t\t\t}\r\n\t\t\tif ($DetailEditTblVar <> \"\") {\r\n\t\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailEdit\\\" data-action=\\\"edit\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailEditLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetEditUrl(EW_TABLE_SHOW_DETAIL . \"=\" . $DetailEditTblVar)) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailEditLink\")) . \"</a></li>\";\r\n\t\t\t}\r\n\t\t\tif ($DetailCopyTblVar <> \"\") {\r\n\t\t\t\t$links .= \"<li><a class=\\\"ewRowLink ewDetailCopy\\\" data-action=\\\"add\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MasterDetailCopyLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->GetCopyUrl(EW_TABLE_SHOW_DETAIL . \"=\" . $DetailCopyTblVar)) . \"\\\">\" . ew_HtmlImageAndText($Language->Phrase(\"MasterDetailCopyLink\")) . \"</a></li>\";\r\n\t\t\t}\r\n\t\t\tif ($links <> \"\") {\r\n\t\t\t\t$body .= \"<button class=\\\"dropdown-toggle btn btn-default btn-sm ewMasterDetail\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"MultipleMasterDetails\")) . \"\\\" data-toggle=\\\"dropdown\\\">\" . $Language->Phrase(\"MultipleMasterDetails\") . \"<b class=\\\"caret\\\"></b></button>\";\r\n\t\t\t\t$body .= \"<ul class=\\\"dropdown-menu ewMenu\\\">\". $links . \"</ul>\";\r\n\t\t\t}\r\n\t\t\t$body .= \"</div>\";\r\n\r\n\t\t\t// Multiple details\r\n\t\t\t$oListOpt = &$option->Add(\"details\");\r\n\t\t\t$oListOpt->Body = $body;\r\n\t\t}\r\n\r\n\t\t// Set up detail default\r\n\t\t$option = &$options[\"detail\"];\r\n\t\t$options[\"detail\"]->DropDownButtonPhrase = $Language->Phrase(\"ButtonDetails\");\r\n\t\t$option->UseImageAndText = TRUE;\r\n\t\t$ar = explode(\",\", $DetailTableLink);\r\n\t\t$cnt = count($ar);\r\n\t\t$option->UseDropDownButton = ($cnt > 1);\r\n\t\t$option->UseButtonGroup = TRUE;\r\n\t\t$item = &$option->Add($option->GroupOptionName);\r\n\t\t$item->Body = \"\";\r\n\t\t$item->Visible = FALSE;\r\n\r\n\t\t// Set up action default\r\n\t\t$option = &$options[\"action\"];\r\n\t\t$option->DropDownButtonPhrase = $Language->Phrase(\"ButtonActions\");\r\n\t\t$option->UseImageAndText = TRUE;\r\n\t\t$option->UseDropDownButton = TRUE;\r\n\t\t$option->UseButtonGroup = TRUE;\r\n\t\t$item = &$option->Add($option->GroupOptionName);\r\n\t\t$item->Body = \"\";\r\n\t\t$item->Visible = FALSE;\r\n\t}", "function EWD_URP_Output_Options_Page() {\n\t\tglobal $URP_Full_Version;\n\t\t\n\t\tif (!isset($_GET['page'])) {$_GET['page'] = \"\";}\n\n\t\tinclude( plugin_dir_path( __FILE__ ) . '../html/AdminHeader.php');\n\t\tif ($_GET['page'] == 'urp-options') {include( plugin_dir_path( __FILE__ ) . '../html/OptionsPage.php');}\n\t\tif ($_GET['page'] == 'urp-woocommerce-import') {include( plugin_dir_path( __FILE__ ) . '../html/WooCommerceImportPage.php');}\n\t\tinclude( plugin_dir_path( __FILE__ ) . '../html/AdminFooter.php');\n}", "public function admin_options() {\r\n echo '<h3>' . __('Mondido', 'mondido') . '</h3>';\r\n echo '<p>' . __('Mondido, Simple payments, smart functions', 'mondido') . '</p>';\r\n echo '<table class=\"form-table\">';\r\n // Generate the HTML For the settings form.\r\n $this->generate_settings_html();\r\n echo '</table>';\r\n }", "public function add_options_page() {\n\t\t$this->options_page = add_menu_page( $this->title, $this->title, 'manage_options', $this->key, array( $this, 'admin_page_display' ) );\n\t\t//$this->options_page = add_theme_page( $this->title, $this->title, 'manage_options', $this->key, array( $this, 'admin_page_display' ) );\n\t\t// Include CMB CSS in the head to avoid FOUC\n\t\tadd_action( \"admin_print_styles-{$this->options_page}\", array( 'CMB2_hookup', 'enqueue_cmb_css' ) );\n\t}", "public function display_options_page() {\n if (! current_user_can('manage_options')) {\n wp_die(__('You do not have sufficient permissions to access this page.'));\n }\n?>\n<div class=\"wrap\">\n <h2><?php esc_attr_e($this->title); ?> Options</h2>\n <form action=\"options.php\" method=\"post\">\n <?php if (function_exists('settings_errors')): settings_errors(); endif; ?>\n <?php settings_fields($this->group); ?>\n <?php foreach ($this->sections as $section): do_settings_sections($section); endforeach; ?>\n <p class=\"submit\">\n <input type=\"submit\" name=\"Submit\" value=\"<?php esc_attr_e('Save Changes'); ?>\" class=\"button-primary\" />\n </p>\n </form>\n</div>\n<?php\n }", "public function mm_options_page() { \n $tmp = $this->plugin_dir . '/inc/views/options-page.php';\n \n ob_start();\n include( $tmp );\n $output = ob_get_contents();\n ob_end_clean();\n echo $output;\n }", "function doOptionsPage()\r\n\t{\r\n\t\t/*\tDeclare the different settings\t*/\r\n\t\tregister_setting('wpklikandpay_store_config_group', 'storeTpe', '' );\r\n\t\t// register_setting('wpklikandpay_store_config_group', 'storeRang', '' );\r\n\t\t// register_setting('wpklikandpay_store_config_group', 'storeIdentifier', '' );\r\n\t\tregister_setting('wpklikandpay_store_config_group', 'environnement', '' );\r\n\t\t// register_setting('wpklikandpay_store_config_group', 'urlSuccess', '' );\r\n\t\t// register_setting('wpklikandpay_store_config_group', 'urlDeclined', '' );\r\n\t\t// register_setting('wpklikandpay_store_config_group', 'urlCanceled', '' );\r\n\t\tsettings_fields( 'wpklikandpay_url_config_group' );\r\n\r\n\t\t/*\tAdd the section about the store main configuration\t*/\r\n\t\tadd_settings_section('wpklikandpay_store_config', __('Informations de la boutique', 'wpklikandpay'), array('wpklikandpay_option', 'storeConfigForm'), 'wpklikandpayStoreConfig');\r\n\r\n\t\t/*\tAdd the section about the back url\t*/\r\n\t\t// add_settings_section('wpklikandpay_url_config', __('Urls de retour apr&eacute;s un paiement', 'wpklikandpay'), array('wpklikandpay_option', 'urlConfigForm'), 'wpklikandpayUrlConfig');\r\n?>\r\n<form action=\"\" method=\"post\" >\r\n<input type=\"hidden\" name=\"saveOption\" id=\"saveOption\" value=\"save\" />\r\n\t<?php \r\n\t\tdo_settings_sections('wpklikandpayStoreConfig'); \r\n \r\n\t\t/*\tSave the configuration in case that the form has been send with \"save\" action\t*/\r\n\t\tif(isset($_POST['saveOption']) && ($_POST['saveOption'] == 'save'))\r\n\t\t{\r\n\t\t\t/*\tSave the store main configuration\t*/\r\n\t\t\tunset($optionList);$optionList = array();\r\n\t\t\t$optionList['storeTpe'] = $_POST['storeTpe'];\r\n\t\t\t$optionList['storeRang'] = $_POST['storeRang'];\r\n\t\t\t$optionList['storeIdentifier'] = $_POST['storeIdentifier'];\r\n\t\t\t$optionList['environnement'] = $_POST['environnement'];\r\n\t\t\twpklikandpay_option::saveStoreConfiguration('wpklikandpay_store_mainoption', $optionList);\r\n\t\t}\r\n\t?>\r\n\t<table summary=\"Store main configuration form\" cellpadding=\"0\" cellspacing=\"0\" class=\"storeMainConfiguration\" >\r\n\t\t<?php do_settings_fields('wpklikandpayStoreConfig', 'mainWKlikAndPayStoreConfig'); ?>\r\n\t</table>\r\n\t<br/><br/><br/>\r\n<!--\r\n\t<?php \r\n\t\t// do_settings_sections('wpklikandpayUrlConfig');\r\n\r\n\t\t/*\tSave the configuration in case that the form has been send with \"save\" action\t*/\r\n\t\tif(isset($_POST['saveOption']) && ($_POST['saveOption'] == 'save'))\r\n\t\t{\r\n\t\t\t/*\tSave the configuration for bakc url after payment\t*/\r\n\t\t\tunset($optionList);$optionList = array();\r\n\t\t\t$optionList['urlSuccess'] = $_POST['urlSuccess'];\r\n\t\t\t$optionList['urlDeclined'] = $_POST['urlDeclined'];\r\n\t\t\t$optionList['urlCanceled'] = $_POST['urlCanceled'];\r\n\t\t\twpklikandpay_option::saveStoreConfiguration('wpklikandpay_store_urloption', $optionList);\r\n\t\t}\r\n\t?>\r\n\t<table summary=\"Back url main configuration form\" cellpadding=\"0\" cellspacing=\"0\" class=\"storeMainConfiguration\" >\r\n\t\t<tr>\r\n\t\t\t<td colspan=\"2\" >\r\n\t\t<?php echo sprintf(__('Ajouter : %s dans les pages que vous allez cr&eacute;er.', 'wpklikandpay'), '<span class=\" bold\" >[wp-klikandpay_payment_return title=\"KlikAndPay return page\" ]</span>'); ?>\r\n\t\t\t</td>\r\n\t\t</tr>\r\n\t\t<tr>\r\n\t\t\t<td colspan=\"2\" >&nbsp;</td>\r\n\t\t</tr>\r\n<?php \r\n\t\tdo_settings_fields('wpklikandpayUrlConfig', 'backUrlConfig'); \r\n?>\r\n\t</table>\r\n-->\r\n\t<br/><br/><br/>\r\n\t<input type=\"submit\" class=\"button-primary\" value=\"<?php _e('Enregistrer les options', 'wpklikandpay'); ?>\" />\r\n</form>\r\n<?php\r\n\t}", "function wwm_2015_optionsframework_options() {\r\n\r\n\t$options = array();\r\n\t//Set the Section Tab Title\r\n\t$options[] = array(\r\n\t\t'name' => __('General Options', 'wwm_2015'),\r\n\t\t'type' => 'heading');\r\n\t\t//Logo\r\n\t\t\t$options[] = array(\r\n\t\t\t\t'name' => __('Main Logo', 'wwm_2015'),\r\n\t\t\t\t'desc' => __('Make sure to use a PNG, with a transparent background (the gray that you see above, is coded in...just for visibility purposes).', 'wwm_2015'),\r\n\t\t\t\t'id' => 'main_logo',\r\n\t\t\t\t'type' => 'upload',\r\n\t\t\t\t'class' => 'large-12 medium-12 small-12 columns');\t\t\r\n\t\t//Primary Color\r\n\t\t\t$options[] = array(\r\n\t\t\t\t\t'name' => __('Primary Color?', 'wwm_2015'),\r\n\t\t\t\t\t'desc' => __('The main color in the scheme', 'wwm_2015'),\r\n\t\t\t\t\t'id' => 'primary_color',\r\n\t\t\t\t\t'std' => '#565b7b',\r\n\t\t\t\t\t'default'=>'#565b7b',\r\n\t\t\t\t\t'type' => 'color',\r\n\t\t\t\t\t'class'=>'large-6 medium-12 small-12 columns'\r\n\t\t\t\t);\t\r\n\t\t//Secondary Color\r\n\t\t\t$options[] = array(\r\n\t\t\t\t\t'name' => __('Secondary Color?', 'wwm_2015'),\r\n\t\t\t\t\t'desc' => __('The secondary color in the scheme', 'wwm_2015'),\r\n\t\t\t\t\t'id' => 'secondary_color',\r\n\t\t\t\t\t'std' => '#d3e2f7',\r\n\t\t\t\t\t'default'=>'#d3e2f7',\r\n\t\t\t\t\t'type' => 'color',\r\n\t\t\t\t\t'class'=>'large-6 medium-12 small-12 columns'\r\n\t\t\t\t);\t\t\r\n\treturn $options;\r\n}", "public function plugin_create_options_page() {\r\n\t\tglobal $screen_layout_columns;\r\n\t\t$data = array();\r\n\t\t?>\r\n\t\t<div class=\"wrap\">\r\n\t\t\t<?php screen_icon('options-general'); ?>\r\n\t\t\t<h2><?php print $this->options_page_title; ?></h2>\r\n\t\t\t<form id=\"settings\" action=\"options.php\" method=\"post\" enctype=\"multipart/form-data\">\r\n\t\t\r\n\t\t\t\t<?php wp_nonce_field('closedpostboxes', 'closedpostboxesnonce', false ); ?>\r\n\t\t\t\t<?php wp_nonce_field('meta-box-order', 'meta-box-order-nonce', false ); ?>\r\n\t\t\t\t<?php settings_fields($this->options_group); ?>\r\n\t\t\t\t<div id=\"poststuff\" class=\"metabox-holder<?php echo 2 == $screen_layout_columns ? ' has-right-sidebar' : ''; ?>\">\r\n\t\t\t\t\t<div id=\"side-info-column\" class=\"inner-sidebar\">\r\n\t\t\t\t\t\t<?php do_meta_boxes($this->page, 'side', $data); ?>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t\t<div id=\"post-body\" class=\"has-sidebar\">\r\n\t\t\t\t\t\t<div id=\"post-body-content\" class=\"has-sidebar-content\">\r\n\t\t\t\t\t\t\t<?php do_meta_boxes($this->page, 'normal', $data); ?>\r\n\t\t\t\t\t\t\t<br/>\r\n\t\t\t\t\t\t\t<p>\r\n\t\t\t\t\t\t\t\t<input type=\"submit\" value=\"Save Changes\" class=\"button-primary\" name=\"Submit\"/>\t\r\n\t\t\t\t\t\t\t</p>\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t\t<br class=\"clear\"/>\t\t\t\t\r\n\t\t\t\t</div>\t\r\n\t\t\t</form>\r\n\t\t</div>\r\n\t\t<script type=\"text/javascript\">\r\n\t\t\t//<![CDATA[\r\n\t\t\tjQuery(document).ready( function($) {\r\n\t\t\t\t$('.if-js-closed').removeClass('if-js-closed').addClass('closed');\r\n\t\t\t\r\n\t\t\t\tpostboxes.add_postbox_toggles('<?php echo $this->page; ?>');\r\n\t\t\t});\r\n\t\t\t//]]>\r\n\t\t</script>\r\n\t\t<?php\r\n\t}", "function options() {\n require( TEMPLATE_PATH . \"/options.php\" );\n}", "public function initializePage()\n\t{\n\t\tadd_menu_page('Thema opties', 'Thema opties', 'manage_options', 'theme-options');\n\t}", "public function adminPluginOptionsPage()\n {\n echo $this->_loadView('admin-settings-page');\n }", "public function add_options_page() {\n\t\t$this->options_page = add_options_page( $this->title, $this->title, 'manage_options', $this->key, array( $this, 'admin_page_display' ) );\n\n\t\t// Include CMB CSS in the head to avoid FOUC\n\t\tadd_action( \"admin_print_styles-{$this->options_page}\", array( 'CMB2_hookup', 'enqueue_cmb_css' ) );\n\t}", "public function add_options_page() {\n\t\t$this->options_page = add_menu_page( $this->metabox_id, $this->title, 'manage_options', $this->key, array( $this, 'admin_page_display' ) , 'dashicons-welcome-widgets-menus', 99);\n\n\t\t// Include CMB CSS in the head to avoid FOUC\n\t\t// wp_register_style( 'style_CMB2', THEME_URI.'/css/style_CMB2.css', false, '3', false );\n\t\tadd_action( \"admin_print_styles-{$this->options_page}\", array( 'CMB2_hookup', 'enqueue_cmb_css' ) );\n\t}", "public function create_plugin_settings_page() {\n \t$page_title = 'My Awesome Settings Page';\n \t$menu_title = 'Awesome Plugin';\n \t$capability = 'manage_options';\n \t$slug = 'smashing_fields';\n \t$callback = array( $this, 'plugin_settings_page_content' );\n \t$icon = 'dashicons-admin-plugins';\n \t$position = 100;\n\n \tadd_menu_page( $page_title, $menu_title, $capability, $slug, $callback, $icon, $position );\n }", "public function define_settings_page() {\n\t\t$this->hook_suffix = add_options_page(\n\t\t\t__( 'Top Story Options', 'top-story' ),\n\t\t\t__( 'Top Story', 'top-story' ),\n\t\t\t'manage_options',\n\t\t\t$this->menu_slug,\n\t\t\tarray( $this, 'option_page' )\n\t\t);\n\t}", "public function add_options_page() {\n\t\tadd_options_page( 'Import Users/Cron', 'Import Users/Cron', 'manage_options', 'import-users-cron-page', array( $this -> submenu_page, 'display' ) );\n\t}", "public function create_plugin_settings_page()\n {\n require_once 'views/settings.phtml';\n }", "function SetupOtherOptions() {\n\t\tglobal $Language, $Security;\n\t\t$options = &$this->OtherOptions;\n\t\t$option = &$options[\"action\"];\n\n\t\t// Add\n\t\t$item = &$option->Add(\"add\");\n\t\t$item->Body = \"<a class=\\\"ewAction ewAdd\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageAddLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageAddLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->AddUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageAddLink\") . \"</a>\";\n\t\t$item->Visible = ($this->AddUrl <> \"\" && $Security->CanAdd());\n\n\t\t// Edit\n\t\t$item = &$option->Add(\"edit\");\n\t\t$item->Body = \"<a class=\\\"ewAction ewEdit\\\" title=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageEditLink\")) . \"\\\" data-caption=\\\"\" . ew_HtmlTitle($Language->Phrase(\"ViewPageEditLink\")) . \"\\\" href=\\\"\" . ew_HtmlEncode($this->EditUrl) . \"\\\">\" . $Language->Phrase(\"ViewPageEditLink\") . \"</a>\";\n\t\t$item->Visible = ($this->EditUrl <> \"\" && $Security->CanEdit());\n\n\t\t// Set up action default\n\t\t$option = &$options[\"action\"];\n\t\t$option->DropDownButtonPhrase = $Language->Phrase(\"ButtonActions\");\n\t\t$option->UseImageAndText = TRUE;\n\t\t$option->UseDropDownButton = FALSE;\n\t\t$option->UseButtonGroup = TRUE;\n\t\t$item = &$option->Add($option->GroupOptionName);\n\t\t$item->Body = \"\";\n\t\t$item->Visible = FALSE;\n\t}", "function options() {\n\t\tif ( ! current_user_can( 'manage_options' ) )\t{\n\t\t\twp_die( __( 'You do not have sufficient permissions to access this page.' ) );\n\t\t}\n\t\tinclude WP_PLUGIN_DIR . '/qoorate/admin_options_page.php';\n\t}", "function gc_create_admin_menu() {\n add_options_page(\n 'Graph Commons',\n 'Graph Commons',\n 'manage_options',\n 'graphcommons',\n array(&$this, 'options_page')\n );\n }", "function owa_options_menu() {\r\n\t\r\n\tif (function_exists('add_options_page')):\r\n\t\tadd_options_page('Options', 'OWA', 8, basename(__FILE__), 'owa_options_page');\r\n\tendif;\r\n \r\n return;\r\n}", "public function add_options_page()\n {\n $parent_slug = null;\n $subpage_slug = $this->welcome_slug;\n\n //echo \">>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> TEST: \" . FREEMIUS_NAVIGATION . '<br>';\n\n if (FREEMIUS_NAVIGATION === 'tabs') {\n // only show submenu page when tabs enabled if welcome tab is active\n if (isset($_GET['page']) && $_GET['page'] === $subpage_slug) {\n $parent_slug = $this->custom_plugin_data->parent_slug;\n }\n } else {\n // always use this if navigation is set to 'menu'\n $parent_slug = $this->custom_plugin_data->parent_slug;\n }\n\n if ($this->custom_plugin_data->menu_type === 'top') {\n $label = 'About';\n } else if ($this->custom_plugin_data->menu_type === 'sub') {\n $label = '<span class=\"fs-submenu-item fs-sub wpgo-plugins\">About</span>';\n }\n\n add_submenu_page($parent_slug, 'Welcome to ' . $this->custom_plugin_data->main_menu_label, $label, 'manage_options', $subpage_slug, array(&$this, 'render_sub_menu_form'));\n }", "function admin_options() {\r\n ?>\r\n <h3><?php _e('Bitcoin Payment','Bitcoin_Payment'); ?></h3>\r\n <table class=\"form-table\">\r\n <?php $this->generate_settings_html(); ?>\r\n </table> <?php\r\n }", "public function add_options_html() {\n\n $has_nav = ( count( $this->pre_tabs ) > 1 ) ? true : false;\n $show_all = ( ! $has_nav ) ? ' csf-show-all' : '';\n $ajax_class = ( $this->args['ajax_save'] ) ? ' csf-save-ajax' : '';\n $sticky_class = ( $this->args['sticky_header'] ) ? ' csf-sticky-header' : '';\n $wrapper_class = ( $this->args['framework_class'] ) ? ' '. $this->args['framework_class'] : '';\n\n echo '<div class=\"csf csf-theme-'. $this->args['theme'] .' csf-options'. $wrapper_class .'\" data-slug=\"'. $this->args['menu_slug'] .'\" data-unique=\"'. $this->unique .'\">';\n\n $notice_class = ( ! empty( $this->notice ) ) ? ' csf-form-show' : '';\n $notice_text = ( ! empty( $this->notice ) ) ? $this->notice : '';\n\n echo '<div class=\"csf-form-result csf-form-success'. $notice_class .'\">'. $notice_text .'</div>';\n\n $error_class = ( ! empty( $this->errors ) ) ? ' csf-form-show' : '';\n\n echo '<div class=\"csf-form-result csf-form-error'. $error_class .'\">';\n if( ! empty( $this->errors ) ) {\n foreach ( $this->errors as $error ) {\n echo '<i class=\"csf-label-error\">!</i> '. $error .'<br />';\n }\n }\n echo '</div>';\n\n echo '<div class=\"csf-container\">';\n\n echo '<form method=\"post\" action=\"\" enctype=\"multipart/form-data\" id=\"csf-form\">';\n\n echo '<input type=\"hidden\" class=\"csf-section-id\" name=\"csf_transient[section]\" value=\"1\">';\n wp_nonce_field( 'csf_options_nonce', 'csf_options_nonce' );\n\n echo '<div class=\"csf-header'. esc_attr( $sticky_class ) .'\">';\n echo '<div class=\"csf-header-inner\">';\n\n echo '<div class=\"csf-header-left\">';\n echo '<h1>'. $this->args['framework_title'] .'</h1>';\n echo '</div>';\n\n echo '<div class=\"csf-header-right\">';\n\n echo ( $has_nav && $this->args['show_all_options'] ) ? '<div class=\"csf-expand-all\" title=\"'. esc_html__( 'show all options', 'csf' ) .'\"><i class=\"fa fa-outdent\"></i></div>' : '';\n\n echo ( $this->args['show_search'] ) ? '<div class=\"csf-search\"><input type=\"text\" placeholder=\"'. esc_html__( 'Search option(s)', 'csf' ) .'\" /></div>' : '';\n\n echo '<div class=\"csf-buttons\">';\n echo '<input type=\"submit\" name=\"'. $this->unique .'[_nonce][save]\" class=\"button button-primary csf-save'. $ajax_class .'\" value=\"'. esc_html__( 'Save', 'csf' ) .'\" data-save=\"'. esc_html__( 'Saving...', 'csf' ) .'\">';\n echo ( $this->args['show_reset_section'] ) ? '<input type=\"submit\" name=\"csf_transient[reset_section]\" class=\"button button-secondary csf-reset-section csf-confirm\" value=\"'. esc_html__( 'Reset Section', 'csf' ) .'\" data-confirm=\"'. esc_html__( 'Are you sure to reset this section options?', 'csf' ) .'\">' : '';\n echo ( $this->args['show_reset_all'] ) ? '<input type=\"submit\" name=\"csf_transient[reset]\" class=\"button button-secondary csf-warning-primary csf-reset-all csf-confirm\" value=\"'. esc_html__( 'Reset All', 'csf' ) .'\" data-confirm=\"'. esc_html__( 'Are you sure to reset all options?', 'csf' ) .'\">' : '';\n echo '</div>';\n\n echo '</div>';\n\n echo '<div class=\"clear\"></div>';\n echo '</div>';\n echo '</div>';\n\n echo '<div class=\"csf-wrapper'. $show_all .'\">';\n\n if( $has_nav ) {\n echo '<div class=\"csf-nav csf-nav-options\">';\n\n echo '<ul>';\n\n $tab_key = 1;\n\n foreach( $this->pre_tabs as $tab ) {\n\n $tab_error = $this->error_check( $tab );\n $tab_icon = ( ! empty( $tab['icon'] ) ) ? '<i class=\"'. $tab['icon'] .'\"></i>' : '';\n\n if( ! empty( $tab['subs'] ) ) {\n\n echo '<li class=\"csf-tab-depth-0\">';\n\n echo '<a href=\"#tab='. $tab_key .'\" class=\"csf-arrow\">'. $tab_icon . $tab['title'] . $tab_error .'</a>';\n\n echo '<ul>';\n\n foreach ( $tab['subs'] as $sub ) {\n\n $sub_error = $this->error_check( $sub );\n $sub_icon = ( ! empty( $sub['icon'] ) ) ? '<i class=\"'. $sub['icon'] .'\"></i>' : '';\n\n echo '<li class=\"csf-tab-depth-1\"><a id=\"csf-tab-link-'. $tab_key .'\" href=\"#tab='. $tab_key .'\">'. $sub_icon . $sub['title'] . $sub_error .'</a></li>';\n\n $tab_key++;\n }\n\n echo '</ul>';\n\n echo '</li>';\n\n } else {\n\n echo '<li class=\"csf-tab-depth-0\"><a id=\"csf-tab-link-'. $tab_key .'\" href=\"#tab='. $tab_key .'\">'. $tab_icon . $tab['title'] . $tab_error .'</a></li>';\n\n $tab_key++;\n }\n\n }\n\n echo '</ul>';\n\n echo '</div>';\n\n }\n\n echo '<div class=\"csf-content\">';\n\n echo '<div class=\"csf-sections\">';\n\n $section_key = 1;\n\n foreach( $this->pre_sections as $section ) {\n\n $onload = ( ! $has_nav ) ? ' csf-onload' : '';\n $section_icon = ( ! empty( $section['icon'] ) ) ? '<i class=\"csf-icon '. $section['icon'] .'\"></i>' : '';\n\n echo '<div id=\"csf-section-'. $section_key .'\" class=\"csf-section'. $onload .'\">';\n echo ( $has_nav ) ? '<div class=\"csf-section-title\"><h3>'. $section_icon . $section['title'] .'</h3></div>' : '';\n echo ( ! empty( $section['description'] ) ) ? '<div class=\"csf-field csf-section-description\">'. $section['description'] .'</div>' : '';\n\n if( ! empty( $section['fields'] ) ) {\n\n foreach( $section['fields'] as $field ) {\n\n $is_field_error = $this->error_check( $field );\n\n if( ! empty( $is_field_error ) ) {\n $field['_error'] = $is_field_error;\n }\n\n $value = ( ! empty( $field['id'] ) && isset( $this->options[$field['id']] ) ) ? $this->options[$field['id']] : '';\n\n CSF::field( $field, $value, $this->unique, 'options' );\n\n }\n\n } else {\n\n echo '<div class=\"csf-no-option csf-text-muted\">'. esc_html__( 'No option provided by developer.', 'csf' ) .'</div>';\n\n }\n\n echo '</div>';\n\n $section_key++;\n }\n\n echo '</div>';\n\n echo '<div class=\"clear\"></div>';\n\n echo '</div>';\n\n echo '<div class=\"csf-nav-background\"></div>';\n\n echo '</div>';\n\n if( ! empty( $this->args['show_footer'] ) ) {\n\n echo '<div class=\"csf-footer\">';\n\n echo '<div class=\"csf-buttons\">';\n echo '<input type=\"submit\" name=\"csf_transient[save]\" class=\"button button-primary csf-save'. $ajax_class .'\" value=\"'. esc_html__( 'Save', 'csf' ) .'\" data-save=\"'. esc_html__( 'Saving...', 'csf' ) .'\">';\n echo ( $this->args['show_reset_section'] ) ? '<input type=\"submit\" name=\"csf_transient[reset_section]\" class=\"button button-secondary csf-reset-section csf-confirm\" value=\"'. esc_html__( 'Reset Section', 'csf' ) .'\" data-confirm=\"'. esc_html__( 'Are you sure to reset this section options?', 'csf' ) .'\">' : '';\n echo ( $this->args['show_reset_all'] ) ? '<input type=\"submit\" name=\"csf_transient[reset]\" class=\"button button-secondary csf-warning-primary csf-reset-all csf-confirm\" value=\"'. esc_html__( 'Reset All', 'csf' ) .'\" data-confirm=\"'. esc_html__( 'Are you sure to reset all options?', 'csf' ) .'\">' : '';\n echo '</div>';\n\n echo ( ! empty( $this->args['footer_text'] ) ) ? '<div class=\"csf-copyright\">'. $this->args['footer_text'] .'</div>' : '';\n\n echo '<div class=\"clear\"></div>';\n echo '</div>';\n\n }\n\n echo '</form>';\n\n echo '</div>';\n\n echo '<div class=\"clear\"></div>';\n\n echo ( ! empty( $this->args['footer_after'] ) ) ? $this->args['footer_after'] : '';\n\n echo '</div>';\n\n }", "function jr_ads_add_pages() {\r\n add_options_page('JR Ads', 'JR Ads', 'administrator', 'jr_ads', 'jr_ads_options_page');\r\n}", "function optionsframework_options() {\n\t\n\t// Test data\n\t$test_array = array(\"one\" => \"One\",\"two\" => \"Two\",\"three\" => \"Three\",\"four\" => \"Four\",\"five\" => \"Five\");\n\t\n\t// Multicheck Array\n\t$multicheck_array = array(\"one\" => \"French Toast\", \"two\" => \"Pancake\", \"three\" => \"Omelette\", \"four\" => \"Crepe\", \"five\" => \"Waffle\");\n\t\n\t// Multicheck Defaults\n\t$multicheck_defaults = array(\"one\" => \"1\",\"five\" => \"1\");\n\t\n\t// Background Defaults\n\t\n\t$background_defaults = array('color' => '', 'image' => '', 'repeat' => 'repeat','position' => 'top center','attachment'=>'scroll');\n\t\n\t\n\t// Pull all the categories into an array\n\t$options_categories = array(); \n\t$options_categories_obj = get_categories();\n\tforeach ($options_categories_obj as $category) {\n \t$options_categories[$category->cat_ID] = $category->cat_name;\n\t}\n\t\n\t// Pull all the pages into an array\n\t$options_pages = array(); \n\t$options_pages_obj = get_pages('sort_column=post_parent,menu_order');\n\t$options_pages[''] = 'Select a page:';\n\tforeach ($options_pages_obj as $page) {\n \t$options_pages[$page->ID] = $page->post_title;\n\t}\n\t\t\n\t// If using image radio buttons, define a directory path\n\t$imagepath = get_bloginfo('stylesheet_directory') . '/images/';\n\t\n// PRICING ARRAY\n\t$test_array = array(\"not_featured\" => \"not featured\",\"featured\" => \"featured\");\n\n\t$options = array();\n\t\n\t$options[] = array( \"name\" => \"Header\",\n\t\t\t\t\t\t\"type\" => \"heading\");\n//HEADER LOGO\n\t$options[] = array( \"name\" => \"Logo\",\n\t\t\t\t\t\t\"desc\" => \"upload your logo\",\n\t\t\t\t\t\t\"id\" => \"logo\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page\",\n\t\t\t\t\t\t\"type\" => \"heading\");\n\n//HOME PAGE SLIDER\n\t$options[] = array( \"name\" => \"Home Page Slider Link 1\",\n\t\t\t\t\t\t\"desc\" => \"Enter a URL for the first slide.\",\n\t\t\t\t\t\t\"id\" => \"home_sliderlink1\",\n\t\t\t\t\t\t\"std\" => \"http://\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"Home Page Slider Image 1\",\n\t\t\t\t\t\t\"desc\" => \"Home Page Slider Image for the first slide.\",\n\t\t\t\t\t\t\"id\" => \"homeslideimg1\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page Slider Link 2\",\n\t\t\t\t\t\t\"desc\" => \"Enter a URL for the second slide.\",\n\t\t\t\t\t\t\"id\" => \"home_sliderlink2\",\n\t\t\t\t\t\t\"std\" => \"http://\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"Home Page Slider Image 2\",\n\t\t\t\t\t\t\"desc\" => \"Home Page Slider Image for the second slide.\",\n\t\t\t\t\t\t\"id\" => \"homeslideimg2\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page Slider Link 3\",\n\t\t\t\t\t\t\"desc\" => \"Enter a URL for the third slide.\",\n\t\t\t\t\t\t\"id\" => \"home_sliderlink3\",\n\t\t\t\t\t\t\"std\" => \"http://\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\t\t\t\t\t\t\n\t$options[] = array( \"name\" => \"Home Page Slider Image 3\",\n\t\t\t\t\t\t\"desc\" => \"Home Page Slider Image for the third slide.\",\n\t\t\t\t\t\t\"id\" => \"homeslideimg3\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t//HOME PAGE FEATURED CONTENT\n\t$options[] = array( \"name\" => \"Home Page Feature Image 1\",\n\t\t\t\t\t\t\"desc\" => \"IMAGE MUST BE 60PX by 60PX. This is the left most home page feature area image.\",\n\t\t\t\t\t\t\"id\" => \"home_featureimage1\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 1 Title\",\n\t\t\t\t\t\t\"desc\" => \"This is the left most home page feature area title.\",\n\t\t\t\t\t\t\"id\" => \"home_featuretitle\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 1 Content\",\n\t\t\t\t\t\t\"desc\" => \"This is the left most home page feature area content.\",\n\t\t\t\t\t\t\"id\" => \"home_featurecontent\",\n\t\t\t\t\t\t\"type\" => \"textarea\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature Image 2\",\n\t\t\t\t\t\t\"desc\" => \"IMAGE MUST BE 60PX by 60PX. This is the middle home page feature area image.\",\n\t\t\t\t\t\t\"id\" => \"home_featureimage2\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 2 Title\",\n\t\t\t\t\t\t\"desc\" => \"This is the middle home page feature area title.\",\n\t\t\t\t\t\t\"id\" => \"home_featuretitle2\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 2 Content\",\n\t\t\t\t\t\t\"desc\" => \"This is the left most home page feature area content.\",\n\t\t\t\t\t\t\"id\" => \"home_featurecontent2\",\n\t\t\t\t\t\t\"type\" => \"textarea\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature Image 3\",\n\t\t\t\t\t\t\"desc\" => \"IMAGE MUST BE 60PX by 60PX. This is the left most home page feature area image.\",\n\t\t\t\t\t\t\"id\" => \"home_featureimage3\",\n\t\t\t\t\t\t\"type\" => \"upload\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 3 Title\",\n\t\t\t\t\t\t\"desc\" => \"This is the right most home page feature area title.\",\n\t\t\t\t\t\t\"id\" => \"home_featuretitle3\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Home Page Feature 3 Content\",\n\t\t\t\t\t\t\"desc\" => \"This is the right most home page feature area content.\",\n\t\t\t\t\t\t\"id\" => \"home_featurecontent3\",\n\t\t\t\t\t\t\"type\" => \"textarea\");\n\t\n//PRICING\n\n\t$options[] = array( \"name\" => \"Pricing\",\n\t\t\t\t\t\t\"type\" => \"heading\");\n//PRICING TABLE 1\n\n\t$options[] = array( \"name\" => \"Featured Pricing Table\",\n\t\t\t\t\t\t\"desc\" => \"Please Select Featured or No \",\n\t\t\t\t\t\t\"id\" => \"featured_pricing\",\n\t\t\t\t\t\t\"std\" => \"two\",\n\t\t\t\t\t\t\"type\" => \"select\",\n\t\t\t\t\t\t\"class\" => \"mini\",\n\t\t\t\t\t\t\"options\" => $test_array);\n\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Name\",\n\t\t\t\t\t\t\"desc\" => \"The name of your 1st pricing table. Example: Basic Hosting\",\n\t\t\t\t\t\t\"id\" => \"pricing1_name\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Payment Structure\",\n\t\t\t\t\t\t\"desc\" => \"The Payment Structure your 1st pricing table. Example: Pay Yearly, Per Month, One Time. \",\n\t\t\t\t\t\t\"id\" => \"pricing1_structure\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\"); \n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Option 1\",\n\t\t\t\t\t\t\"desc\" => \"The 1st for your 1st pricing table. Example: 1TB Bandwith. \",\n\t\t\t\t\t\t\"id\" => \"pricing1_option1\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Option 2\",\n\t\t\t\t\t\t\"desc\" => \"The 2nd option for your 1st pricing table. Example: 1 Gig of Space. \",\n\t\t\t\t\t\t\"id\" => \"pricing1_option2\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Option 3\",\n\t\t\t\t\t\t\"desc\" => \"The 3rd option for your 1st pricing table. Example: Email Support. \",\n\t\t\t\t\t\t\"id\" => \"pricing1_option3\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Price\",\n\t\t\t\t\t\t\"desc\" => \"The price for your 1st pricing table. Example: $19.95. \",\n\t\t\t\t\t\t\"id\" => \"pricing1_price\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 1 Button Link\",\n\t\t\t\t\t\t\"desc\" => \"The link for your 1st pricing table. Example: A sign up page, Paypal Link or Google Checkout. You can redirect them to any URL you want.\",\n\t\t\t\t\t\t\"id\" => \"pricing1_link\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\n\n\n\n\n//PRICING TABLE 2\n\n\t$options[] = array( \"name\" => \"Featured Pricing Table\",\n\t\t\t\t\t\t\"desc\" => \"Please Select Featured or No \",\n\t\t\t\t\t\t\"id\" => \"featured_pricing2\",\n\t\t\t\t\t\t\"std\" => \"two\",\n\t\t\t\t\t\t\"type\" => \"select\",\n\t\t\t\t\t\t\"class\" => \"mini\",\n\t\t\t\t\t\t\"options\" => $test_array);\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Name\",\n\t\t\t\t\t\t\"desc\" => \"The name of your 2nd pricing table. Example: Basic Hosting\",\n\t\t\t\t\t\t\"id\" => \"pricing2_name\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Payment Structure\",\n\t\t\t\t\t\t\"desc\" => \"The Payment Structure your 2nd pricing table. Example: Pay Yearly, Per Month, One Time. \",\n\t\t\t\t\t\t\"id\" => \"pricing2_structure\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\"); \n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Option 1\",\n\t\t\t\t\t\t\"desc\" => \"The 1st option for your 2nd pricing table. Example: 1TB Bandwith. \",\n\t\t\t\t\t\t\"id\" => \"pricing2_option1\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Option 2\",\n\t\t\t\t\t\t\"desc\" => \"The 2nd option for your 2nd pricing table. Example: 1 Gig of Space. \",\n\t\t\t\t\t\t\"id\" => \"pricing2_option2\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Option 3\",\n\t\t\t\t\t\t\"desc\" => \"The 3rd option for your 2nd pricing table. Example: Email Support. \",\n\t\t\t\t\t\t\"id\" => \"pricing2_option3\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Price\",\n\t\t\t\t\t\t\"desc\" => \"The price for your 2nd pricing table. Example: $19.95. \",\n\t\t\t\t\t\t\"id\" => \"pricing2_price\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 2 Button Link\",\n\t\t\t\t\t\t\"desc\" => \"The link for your 2nd pricing table. Example: A sign up page, Paypal Link or Google Checkout. You can redirect them to any URL you want.\",\n\t\t\t\t\t\t\"id\" => \"pricing2_link\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\n\n//PRICING TABLE 3\n\t$options[] = array( \"name\" => \"Featured Pricing Table\",\n\t\t\t\t\t\t\"desc\" => \"Please Select Featured or No \",\n\t\t\t\t\t\t\"id\" => \"featured_pricing3\",\n\t\t\t\t\t\t\"std\" => \"two\",\n\t\t\t\t\t\t\"type\" => \"select\",\n\t\t\t\t\t\t\"class\" => \"mini\",\n\t\t\t\t\t\t\"options\" => $test_array);\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Name\",\n\t\t\t\t\t\t\"desc\" => \"The name of your 3rd pricing table. Example: Basic Hosting\",\n\t\t\t\t\t\t\"id\" => \"pricing3_name\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Payment Structure\",\n\t\t\t\t\t\t\"desc\" => \"The Payment Structure your 3rd pricing table. Example: Pay Yearly, Per Month, One Time. \",\n\t\t\t\t\t\t\"id\" => \"pricing3_structure\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\"); \n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Option 1\",\n\t\t\t\t\t\t\"desc\" => \"The 1st option for your 3rd pricing table. Example: 1TB Bandwith. \",\n\t\t\t\t\t\t\"id\" => \"pricing3_option1\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Option 2\",\n\t\t\t\t\t\t\"desc\" => \"The 2nd option for your 3rd pricing table. Example: 1 Gig of Space. \",\n\t\t\t\t\t\t\"id\" => \"pricing3_option2\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Option 3\",\n\t\t\t\t\t\t\"desc\" => \"The 3rd for your 3rd pricing table. Example: Email Support. \",\n\t\t\t\t\t\t\"id\" => \"pricing3_option3\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Price\",\n\t\t\t\t\t\t\"desc\" => \"The price for your 3rd pricing table. Example: $19.95. \",\n\t\t\t\t\t\t\"id\" => \"pricing3_price\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 3 Button Link\",\n\t\t\t\t\t\t\"desc\" => \"The link for your 3rd pricing table. Example: A sign up page, Paypal Link or Google Checkout. You can redirect them to any URL you want.\",\n\t\t\t\t\t\t\"id\" => \"pricing3_link\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\n\n//PRICING TABLE 4\n\n\t$options[] = array( \"name\" => \"Featured Pricing Table\",\n\t\t\t\t\t\t\"desc\" => \"Please Select Featured or No \",\n\t\t\t\t\t\t\"id\" => \"featured_pricing4\",\n\t\t\t\t\t\t\"std\" => \"two\",\n\t\t\t\t\t\t\"type\" => \"select\",\n\t\t\t\t\t\t\"class\" => \"mini\",\n\t\t\t\t\t\t\"options\" => $test_array);\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Name\",\n\t\t\t\t\t\t\"desc\" => \"The name of your 4th pricing table. Example: Basic Hosting\",\n\t\t\t\t\t\t\"id\" => \"pricing4_name\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Payment Structure\",\n\t\t\t\t\t\t\"desc\" => \"The Payment Structure your 4th pricing table. Example: Pay Yearly, Per Month, One Time. \",\n\t\t\t\t\t\t\"id\" => \"pricing4_structure\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\"); \n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Option 1\",\n\t\t\t\t\t\t\"desc\" => \"The 1st option for your 1st pricing table. Example: 1TB Bandwith. \",\n\t\t\t\t\t\t\"id\" => \"pricing4_option1\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Option 2\",\n\t\t\t\t\t\t\"desc\" => \"The 2nd for your 2nd pricing table. Example: 1 Gig of Space. \",\n\t\t\t\t\t\t\"id\" => \"pricing4_option2\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Option 3\",\n\t\t\t\t\t\t\"desc\" => \"The 3rd option for your 4th pricing table. Example: Email Support. \",\n\t\t\t\t\t\t\"id\" => \"pricing4_option3\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Price\",\n\t\t\t\t\t\t\"desc\" => \"The price for your 4th pricing table. Example: $19.95. \",\n\t\t\t\t\t\t\"id\" => \"pricing4_price\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 4 Button Link\",\n\t\t\t\t\t\t\"desc\" => \"The link for your 4th pricing table. Example: A sign up page, Paypal Link or Google Checkout. You can redirect them to any URL you want.\",\n\t\t\t\t\t\t\"id\" => \"pricing4_link\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n//PRICING TABLE 5\n\t$options[] = array( \"name\" => \"Featured Pricing Table\",\n\t\t\t\t\t\t\"desc\" => \"Please Select Featured or No \",\n\t\t\t\t\t\t\"id\" => \"featured_pricing5\",\n\t\t\t\t\t\t\"std\" => \"two\",\n\t\t\t\t\t\t\"type\" => \"select\",\n\t\t\t\t\t\t\"class\" => \"mini\",\n\t\t\t\t\t\t\"options\" => $test_array);\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Name\",\n\t\t\t\t\t\t\"desc\" => \"The name of your 1st pricing table. Example: Basic Hosting\",\n\t\t\t\t\t\t\"id\" => \"pricing5_name\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Payment Structure\",\n\t\t\t\t\t\t\"desc\" => \"The Payment Structure your 5th pricing table. Example: Pay Yearly, Per Month, One Time. \",\n\t\t\t\t\t\t\"id\" => \"pricing5_structure\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\"); \n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Option 1\",\n\t\t\t\t\t\t\"desc\" => \"The first option for your 5th pricing table. Example: 1TB Bandwith. \",\n\t\t\t\t\t\t\"id\" => \"pricing5_option1\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Option 2\",\n\t\t\t\t\t\t\"desc\" => \"The first option for your 5th pricing table. Example: 1 Gig of Space. \",\n\t\t\t\t\t\t\"id\" => \"pricing5_option2\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Option 3\",\n\t\t\t\t\t\t\"desc\" => \"The first option for your 5th pricing table. Example: Email Support. \",\n\t\t\t\t\t\t\"id\" => \"pricing5_option3\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Price\",\n\t\t\t\t\t\t\"desc\" => \"The price for your 5th pricing table. Example: $19.95. \",\n\t\t\t\t\t\t\"id\" => \"pricing5_price\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\n\t$options[] = array( \"name\" => \"Pricing Table 5 Button Link\",\n\t\t\t\t\t\t\"desc\" => \"The link for your 2nd pricing table. Example: A sign up page, Paypal Link or Google Checkout. You can redirect them to any URL you want.\",\n\t\t\t\t\t\t\"id\" => \"pricing5_link\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"text\");\n\t\n\t//FOOTER\n\n\t$options[] = array( \"name\" => \"Footer\",\n\t\t\t\t\t\t\"type\" => \"heading\");\n\t\n\t$options[] = array( \"name\" => \"Google Analytics Code\",\n\t\t\t\t\t\t\"desc\" => \"Paste your Google Analytics Code into this text box.\",\n\t\t\t\t\t\t\"id\" => \"google_analytics\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"textarea\"); \n\n\t$options[] = array( \"name\" => \"Twitter User Name\",\n\t\t\t\t\t\t\"desc\" => \"Paste your Twitter User Name into this text box.\",\n\t\t\t\t\t\t\"id\" => \"twitter_username\",\n\t\t\t\t\t\t\"std\" => \"Default Text\",\n\t\t\t\t\t\t\"type\" => \"textarea\"); \n\n\treturn $options;\n}", "function optionsframework_options() {\n\n\t$options = array();\n\n\t$options[] = array(\n\t\t'name' => __( 'Basic Settings', 'twentyseventyseven-child-2' ),\n\t\t'type' => 'heading'\n\t);\n\n\t$options[] = array(\n\t\t'name' => __( 'Upload Logo', 'twentyseventyseven-child-2' ),\n\t\t'desc' => __( 'This creates a full size uploader that previews the image.', 'twentyseventyseven-child-2' ),\n\t\t'id' => 'upload-logo',\n\t\t'type' => 'upload'\n\t);\n\n\t$options[] = array(\n\t\t'name' => __( 'Limit Post to show on Front Page', 'twentyseventyseven-child-2' ),\n\t\t'desc' => __( 'Limit Post', 'twentyseventyseven-child-2' ),\n\t\t'id' => 'limit-post-frontpage',\n\t\t'std' => '1',\n\t\t'type' => 'checkbox'\n\t);\n\n\t$options[] = array(\n\t\t'name' => __( 'Posts to limit', 'twentyseventyseven-child-2' ),\n\t\t'desc' => __( 'Posts.', 'twentyseventyseven-child-2' ),\n\t\t'id' => 'limit-post-frontpage-value',\n\t\t'std' => '0',\n\t\t'class' => 'mini',\n\t\t'type' => 'text'\n\t);\n\n\t$options[] = array(\n\t\t'name' => __( 'Show Sidebar on Front Page', 'twentyseventyseven-child-2' ),\n\t\t'desc' => __( 'Show Sidebar', 'twentyseventyseven-child-2' ),\n\t\t'id' => 'show-sidebar-frontpage',\n\t\t'std' => '1',\n\t\t'type' => 'checkbox'\n\t);\n\n\treturn $options;\n}", "function optionsframework_options() {\n\n\n\n\t$options = array();\n\t\n\n\t$imagepath = get_template_directory_uri() . '/images/';\n\n\t$options[] = array(\n\t\t'name' => __('Company Details', 'options_framework_theme'),\n\t\t'type' => 'heading');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Logo', 'options_framework_theme'),\n\t\t'desc' => __('Upload website logo.', 'options_framework_theme'),\n\t\t'id' => 'logo',\n\t\t'type' => 'upload');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Telephone Number', 'options_framework_theme'),\n\t\t'desc' => __('Main Telephone Number', 'options_framework_theme'),\n\t\t'id' => 'telephone_number',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Email Address', 'options_framework_theme'),\n\t\t'desc' => __('Main Email Address', 'options_framework_theme'),\n\t\t'id' => 'email_address',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Address', 'options_framework_theme'),\n\t\t'type' => 'heading');\n\t\t\n\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization Address', 'options_framework_theme'),\n\t\t'desc' => __('First Line', 'options_framework_theme'),\n\t\t'id' => 'organ_address',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization Address line 2', 'options_framework_theme'),\n\t\t'desc' => __('Second Line', 'options_framework_theme'),\n\t\t'id' => 'organ_address_2',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization PO Box', 'options_framework_theme'),\n\t\t'desc' => __('PO Box Number', 'options_framework_theme'),\n\t\t'id' => 'organ_po_box',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization City', 'options_framework_theme'),\n\t\t'desc' => __('Town / City', 'options_framework_theme'),\n\t\t'id' => 'organ_city',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization State / Region', 'options_framework_theme'),\n\t\t'desc' => __('State / Region', 'options_framework_theme'),\n\t\t'id' => 'organ_state',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization Post Code', 'options_framework_theme'),\n\t\t'desc' => __('Post Code', 'options_framework_theme'),\n\t\t'id' => 'organ_post_code',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\t\t\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Organization Country', 'options_framework_theme'),\n\t\t'desc' => __('Country', 'options_framework_theme'),\n\t\t'id' => 'organ_country',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\n\t/* Social Media */\t\n\t\t\n\t$options[] = array(\n\t'name' => __('Social Media', 'options_framework_theme'),\n\t'type' => 'heading');\n\t\t\n\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Facebook URL', 'options_framework_theme'),\n\t\t'desc' => __('Full Facebook address', 'options_framework_theme'),\n\t\t'id' => 'social_facebook',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Youtube URL', 'options_framework_theme'),\n\t\t'desc' => __('Full Youtube address', 'options_framework_theme'),\n\t\t'id' => 'social_youtube',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\t\t\n\t$options[] = array(\n\t\t'name' => __('Twitter URL', 'options_framework_theme'),\n\t\t'desc' => __('Full Twitter address', 'options_framework_theme'),\n\t\t'id' => 'social_twitter',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t$options[] = array(\n\t\t'name' => __('Feed URL', 'options_framework_theme'),\n\t\t'desc' => __('Full RSS URL', 'options_framework_theme'),\n\t\t'id' => 'social_rss',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t'name' => __('Pinterest URL', 'options_framework_theme'),\n\t\t'desc' => __('Full Pinterest URL', 'options_framework_theme'),\n\t\t'id' => 'social_pinterest',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\t\t\n\t\t\t\n\t\t\t$options[] = array(\n\t\t'name' => __('Google Plus URL', 'options_framework_theme'),\n\t\t'desc' => __('Google Plus URL', 'options_framework_theme'),\n\t\t'id' => 'social_google_plus',\n\t\t'std' => '',\n\t\t'type' => 'text');\n\n\treturn $options;\n}", "public function settings_admin_page()\n {\n add_action('wp_cspa_before_closing_header', [$this, 'back_to_optin_overview']);\n add_action('wp_cspa_before_post_body_content', array($this, 'optin_theme_sub_header'), 10, 2);\n add_filter('wp_cspa_main_content_area', [$this, 'optin_form_list']);\n\n $instance = Custom_Settings_Page_Api::instance();\n $instance->page_header(__('Add New Optin', 'mailoptin'));\n $this->register_core_settings($instance, true);\n $instance->build(true);\n }", "public function display_analytics_options_page() {\n\t\t?>\n\t\t<div class=\"wrap\">\n\t\t\t<h2>WSU Analytics Settings</h2>\n\t\t\t<form method=\"post\" action=\"options.php\">\n\t\t<?php\n\t\twp_nonce_field( 'wsuwp-analytics-options' );\n\t\tdo_settings_sections( $this->settings_page );\n\n\t\tsubmit_button();\n\t\t?>\n\t\t\t\t<input type=\"hidden\" name=\"action\" value=\"update\" />\n\t\t\t\t<input type=\"hidden\" name=\"option_page\" value=\"wsuwp-analytics\" />\n\t\t\t</form>\n\t\t</div>\n\t\t<?php\n\t}", "public function options_page()\n\t\t{\n\t\t\tif (!@include 'options-page.php'):\n\t\t\t\tprintf(__('<div id=\"message\" class=\"updated fade\"><p>The options page for the <strong>Mailgun</strong> plugin cannot be displayed. The file <strong>%s</strong> is missing. Please reinstall the plugin.</p></div>',\n\t\t\t\t\t'mailgun'), dirname(__FILE__) . '/options-page.php');\n\t\t\tendif;\n\t\t}", "function optionsframework_options() {\n\n\t$options = array();\n\t\n\t//GENERAL\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('General', 'wpex'),\n\t\t\"type\" \t=> 'heading',\n\t);\n\t\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Custom Logo', 'wpex'),\n\t\t\"desc\" \t=> __('Upload your custom logo.', 'wpex'),\n\t\t\"std\" \t=> '',\n\t\t\"id\" \t=> 'custom_logo',\n\t\t\"type\" \t=> 'upload',\n\t);\n\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Notification Bar', 'att'),\n\t\t\"desc\" \t=> __('Enter your text for the notification bar.', 'att'),\n\t\t\"std\" \t=> 'This is your notification bar...you can <a href=\"#\">add a link here &rarr;</a> if you want.',\n\t\t\"id\" \t=> 'notification',\n\t\t\"type\" \t=> 'textarea',\n\t);\n\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Custom Excerpt Lenght', 'wpex'),\n\t\t\"desc\" \t=> __('Enter your desired custom excerpt length.', 'wpex'),\n\t\t\"id\" \t=> 'excerpt_length',\n\t\t\"std\" \t=> '17',\n\t\t\"type\" \t=> 'text'\n\t);\n\t\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('AJAX Loading Instead of Pagination?', 'wpex'),\n\t\t\"desc\" \t=> __('Check box to enable the load more button rather then generic 1,2,3 pagination.', 'wpex'),\n\t\t\"id\" \t=> 'ajax_loading',\n\t\t\"std\" \t=> '1',\n\t\t\"type\" \t=> 'checkbox',\n\t);\n\t\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Custom WP Gallery?', 'wpex'),\n\t\t\"desc\" \t=> __('This theme outputs a custom gallery style for the WordPress shortcode, if you don\\'t like it or are using a plugin for this you can unselect the custom functionality here.', 'wpex'),\n\t\t\"id\" \t=> 'custom_wp_gallery',\n\t\t\"std\" \t=> '1',\n\t\t\"type\" \t=> 'checkbox'\n\t);\n\t\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Enable Retina Support', 'wpex'),\n\t\t\"desc\"\t=> __('Check this box to enable retina support for featured images. If enabled for every cropped featured image the theme will create a second one that is retina optimized. So keep disabled to save server space.', 'wpex'),\n\t\t\"id\"\t=> 'enable_retina',\n\t\t\"std\"\t=> '0',\n\t\t\"type\"\t=> 'checkbox'\n\t);\n\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Featured Images For Single Posts', 'wpex'),\n\t\t\"desc\"\t=> __('Check this box to enable the display of featured images in single posts.', 'wpex'),\n\t\t\"id\"\t=> 'single_thumb',\n\t\t\"std\"\t=> '1',\n\t\t\"type\"\t=> 'checkbox'\n\t);\n\t\t\n\t\n\t//HOMEPAGE\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Home', 'wpex'),\n\t\t\"type\" \t=> 'heading',\n\t);\t\n\t\t\n\t$options[] = array(\n\t\t\"name\" \t=> __('Homepage Content', 'att'),\n\t\t\"desc\" \t=> __('Use this field to add content to your homepage area right below the main slider (or instead of the slider if you aren\\'t using it) and right above the latest posts.', 'att'),\n\t\t\"std\" \t=> '',\n\t\t\"id\" \t=> 'homepage_content',\n\t\t\"type\" \t=> 'editor',\n\t);\n\t\t\t\n\t\t\n\t//Slider\n\t$options[] = array(\n\t\t\"name\" \t=> __('Slides', 'att'),\n\t\t\"type\" \t=> 'heading',\n\t);\n\t\t\t\n\t\tif ( class_exists( 'Symple_Slides_Post_Type' ) ) {\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t\t=> __('Toggle: Slideshow', 'att'),\n\t\t\t\t\"desc\" \t\t=> __('Check this box to enable automatic slideshow for your slides.', 'att'),\n\t\t\t\t\"id\" \t\t=> \"slides_slideshow\",\n\t\t\t\t\"std\" \t\t=> \"true\",\n\t\t\t\t\"type\" \t\t=> \"select\",\n\t\t\t\t\"options\" \t=> array(\n\t\t\t\t\t'true' \t\t=> 'true',\n\t\t\t\t\t'false' \t=> 'false'\n\t\t\t) );\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t\t=> __('Toggle: Randomize', 'att'),\n\t\t\t\t\"desc\" \t\t=> __('Check this box to enable the randomize feature for your slides.', 'att'),\n\t\t\t\t\"id\" \t\t=> \"slides_randomize\",\n\t\t\t\t\"std\" \t\t=> \"false\",\n\t\t\t\t\"type\" \t\t=> \"select\",\n\t\t\t\t\"options\" \t=> array(\n\t\t\t\t\t'true' \t\t=> 'true',\n\t\t\t\t\t'false' \t=> 'false'\n\t\t\t) );\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t\t=> __('Animation', 'att'),\n\t\t\t\t\"desc\" \t\t=> __('Select your animation of choice.', 'att'),\n\t\t\t\t\"id\" \t\t=> \"slides_animation\",\n\t\t\t\t\"std\" \t\t=> \"slide\",\n\t\t\t\t\"type\" \t\t=> \"select\",\n\t\t\t\t\"options\" \t=> array(\n\t\t\t\t\t'fade' \t\t=> 'fade',\n\t\t\t\t\t'slide' \t=> 'slide'\n\t\t\t) );\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t\t=> __('Direction', 'att'),\n\t\t\t\t\"desc\" \t\t=> __('Select the direction for your slides. Slide animation only & if using the <strong>vertical direction</strong> all slides must have the same height.', 'att'),\n\t\t\t\t\"id\" \t\t=> \"slides_direction\",\n\t\t\t\t\"std\" \t\t=> \"horizontal\",\n\t\t\t\t\"type\" \t\t=> \"select\",\n\t\t\t\t\"options\" \t=> array(\n\t\t\t\t\t'horizontal' \t=> 'horizontal',\n\t\t\t\t\t'vertical' \t\t=> 'vertical'\n\t\t\t) );\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t=> __('SlideShow Speed', 'att'),\n\t\t\t\t\"desc\" \t=> __('Enter your preferred slideshow speed in milliseconds.', 'att'),\n\t\t\t\t\"id\" \t=> \"slideshow_speed\",\n\t\t\t\t\"std\" \t=> \"7000\",\n\t\t\t\t\"type\" \t=> \"text\",\n\t\t\t);\n\t\t\t\t\n\t\t\t$options[] = array(\n\t\t\t\t\"name\" \t=> __('Animation Speed', 'att'),\n\t\t\t\t\"desc\" \t=> __('Enter your preferred animation speed in milliseconds.', 'att'),\n\t\t\t\t\"id\" \t=> \"animation_speed\",\n\t\t\t\t\"std\" \t=> \"600\",\n\t\t\t\t\"type\" \t=> \"text\",\n\t\t\t);\n\t\t}\n\t\t\t\n\t\t$options[] = array(\n\t\t\t\"name\" \t=> __('Slider Alternative', 'att'),\n\t\t\t\"desc\" \t=> __('If you prefer to use another slider you can enter the <strong>shortcode</strong> here.', 'att'),\n\t\t\t\"id\" \t=> \"slides_alt\",\n\t\t\t\"std\" \t=> \"\",\n\t\t\t\"type\" \t=> \"textarea\",\n\t\t);\n\n\treturn $options;\n}", "function bn_project_options_page() {\n // add top level menu page\n if ( empty ( $GLOBALS['admin_page_hooks']['bn_options'] ) ) {\n add_menu_page(\n 'Komunikaty',\n 'Komunikaty',\n '',\n 'bn_options',\n '',\n plugins_url('brodnet-logo.png', __FILE__ )\n );\n }\n\tadd_submenu_page(\n\t\t'bn_options',\n\t\t__('Komunikaty', 'bn-netto'),\n\t\t__('Komunikaty', 'bn-netto'),\n\t\t'manage_options',\n\t\t'bn_project_options',\n\t\t'bn_project_options_page_html'\n\t);\n}", "public function addPages()\r\n {\r\n $settings = add_options_page(\r\n 'OHS Newsletter',\r\n 'OHS Newsletter',\r\n 'manage_options',\r\n 'ohs-newsletter',\r\n array($this, 'optionsPage')\r\n );\r\n }", "public function actionCreateOptions()\n {\n $model = new Options();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['view-options', 'id' => $model->id]);\n } else {\n return $this->render('options/create', [\n 'model' => $model,\n ]);\n }\n }", "public function admin_options() { ?>\n <h3><?php _e( $this->pluginTitle(), 'midtrans-woocommerce' ); ?></h3>\n <p><?php _e($this->getSettingsDescription(), 'midtrans-woocommerce' ); ?></p>\n <table class=\"form-table\">\n <?php\n // Generate the HTML For the settings form.\n $this->generate_settings_html();\n ?>\n </table><!--/.form-table-->\n <?php\n }", "public function optionsdemo_create_settings() {\n\t\t\t$parent_slug = 'edit.php?post_type=optiondemo';\n\t\t\t$page_title = esc_html__( 'Settings', 'optionsdemo' );\n\t\t\t$menu_title = esc_html__( 'Settings', 'optionsdemo' );\n\t\t\t$capability = 'manage_options';\n\t\t\t$slug = 'optionsdemo';\n\t\t\t$callback = array( $this, 'optionsdemo_settings_content' );\n\t\t\t\n\t\t\t//add submenu to custom post\n\t\t\tadd_submenu_page( $parent_slug, $page_title, $menu_title, $capability, $slug, $callback );\n\t\t}", "private function acf_add_options_pages() {\n\t\t\tif (!function_exists('acf_add_options_sub_page')) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t// get all the options pages and add them\n\t\t\t$options_pages = array('top' => array(), 'sub' => array());\n\t\t\t$args = array('post_type' => $this->post_type,\n\t\t\t\t\t\t\t\t\t\t'post_status' => 'publish',\n\t\t\t\t\t\t\t\t\t\t'posts_per_page' => -1,\n\t\t\t\t\t\t\t\t\t\t'order' => 'ASC');\n\t\t\t$page_query = new WP_Query($args);\n\t\t\tif (count($page_query->posts)) {\n\t\t\t\tforeach ($page_query->posts as $post) {\n\t\t\t\t\t$id = $post->ID;\n\t\t\t\t\t$title = get_the_title($id);\n\t\t\t\t\t$menu_text = trim(get_post_meta($id, '_acfop_menu', true));\n\t\t\t\t\tif (!$menu_text) {\n\t\t\t\t\t\t$menu_text = $title;\n\t\t\t\t\t}\n\t\t\t\t\t$slug = trim(get_post_meta($id, '_acfop_slug', true));\n\t\t\t\t\tif (!$slug) {\n\t\t\t\t\t\t$slug = strtolower(trim(preg_replace('/[^a-z0-9]+/i', '-', $title), '-'));\n\t\t\t\t\t}\n\t\t\t\t\t$parent = get_post_meta($id, '_acfop_parent', true);\n\t\t\t\t\t$capability = get_post_meta($id, '_acfop_capability', true);\n\t\t\t\t\t$post_id = 'options';\n\t\t\t\t\t$save_to = get_post_meta($id, '_acfop_save_to', true);\n\t\t\t\t\t$autoload = 0;\n\t\t\t\t\tif ($save_to == 'post') {\n\t\t\t\t\t\t$post_id = intval(get_post_meta($id, '_acfop_post_page', true));\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$autoload = get_post_meta($id, '_acfop_autoload', true);\n\t\t\t\t\t}\n\t\t\t\t\tif ($parent == 'none') {\n\t\t\t\t\t\t$options_page = array('page_title' =>\t$title,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'menu_title' => $menu_text,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'menu_slug' => $slug,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'capability' => $capability,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'post_id' => $post_id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'autoload' => $autoload);\n\t\t\t\t\t\t$redirect = true;\n\t\t\t\t\t\t$value = get_post_meta($id, '_acfop_redirect', true);\n\t\t\t\t\t\tif ($value == '0') {\n\t\t\t\t\t\t\t$redirect = false;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$options_page['redirect'] = $redirect;\n\t\t\t\t\t\tif ($redirect) {\n\t\t\t\t\t\t\t$options_page['slug'] = strtolower(trim(preg_replace('/[^a-z0-9]+/i', '-', $title), '-'));\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t$icon = '';\n\t\t\t\t\t\t$value = get_post_meta($id, '_acfop_icon', true);\n\t\t\t\t\t\tif ($value != '') {\n\t\t\t\t\t\t\t$icon = $value;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($icon) {\n\t\t\t\t\t\t\t$options_page['icon_url'] = $icon;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t$menu_position = '';\n\t\t\t\t\t\t$value = get_post_meta($id, '_acfop_position', true);\n\t\t\t\t\t\tif ($value != '') {\n\t\t\t\t\t\t\t$menu_position = $value;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($menu_position) {\n\t\t\t\t\t\t\t$options_page['position'] = $menu_position;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t\n\t\t\t\t\t\t$options_pages['top'][] = $options_page;\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$order = 0;\n\t\t\t\t\t\t$value = get_post_meta($id, '_acfop_order', true);\n\t\t\t\t\t\tif ($value) {\n\t\t\t\t\t\t\t$order = $value;\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$options_pages['sub'][] = array('title' => $title,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'menu' => $menu_text,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'parent' => $parent,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'slug' => $slug,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'capability' => $capability,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'order' => $order,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'post_id' => $post_id,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'autoload' => $autoload);\n\t\t\t\t\t}\n\t\t\t\t} // end foreach $post;\n\t\t\t} // end if have_posts\n\t\t\twp_reset_query();\n\t\t\tif (count($options_pages['top'])) {\n\t\t\t\tforeach ($options_pages['top'] as $options_page) {\n\t\t\t\t\tacf_add_options_page($options_page);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (count($options_pages['sub'])) {\n\t\t\t\tusort($options_pages['sub'], array($this, 'sort_by_order'));\n\t\t\t\tforeach ($options_pages['sub'] as $options_page) {\n\t\t\t\t\tacf_add_options_sub_page($options_page);\n\t\t\t\t}\n\t\t\t}\n\t\t}" ]
[ "0.82637507", "0.8026201", "0.7942244", "0.78272265", "0.7682874", "0.7561901", "0.748421", "0.7369787", "0.7361973", "0.73372334", "0.7317128", "0.72846085", "0.72743565", "0.7246895", "0.7227218", "0.72189146", "0.7177125", "0.7172117", "0.7164375", "0.7151519", "0.714475", "0.71117365", "0.7103493", "0.71001357", "0.7098525", "0.7089242", "0.70864", "0.70811963", "0.70709974", "0.7043913", "0.70355564", "0.7034889", "0.7030434", "0.70254093", "0.70160055", "0.6995323", "0.69710976", "0.6969137", "0.69667894", "0.6966718", "0.69602907", "0.69575775", "0.6938148", "0.69293797", "0.6921056", "0.68992543", "0.6886354", "0.6885371", "0.6872245", "0.68707377", "0.6867049", "0.68586034", "0.6858203", "0.685102", "0.685102", "0.6837938", "0.6834398", "0.68333936", "0.6832145", "0.68275476", "0.6822658", "0.68178576", "0.6787182", "0.6784845", "0.6775231", "0.6767179", "0.67492384", "0.6745685", "0.67267567", "0.67062515", "0.6704585", "0.6697928", "0.6688337", "0.66837364", "0.6652801", "0.6638913", "0.66143644", "0.65965647", "0.6586969", "0.6586748", "0.65696144", "0.655869", "0.65556574", "0.6537135", "0.65360975", "0.65334547", "0.6532318", "0.6528031", "0.6521723", "0.65136707", "0.65074795", "0.6500461", "0.6496311", "0.64926696", "0.6492466", "0.64918745", "0.64893067", "0.64828837", "0.64828295", "0.6482266", "0.647961" ]
0.0
-1
Sanitize and validate input. Accepts an array, return a sanitized array.
function ajb_options_validate( $input ) { for ( $j=1; $j<=5; $j++) { // home page CSS must be safe text with the allowed tags for posts $input['button_' . $j . '_link'] = wp_filter_post_kses( $input['button_' . $j . '_link'] ); } return $input; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sanitize_array( $array = array(), $sanitize_rule = array() ){\n if ( ! is_array( $array ) || count( $array ) == 0 ) {\n return array();\n }\n\n foreach ( $array as $k => $v ) {\n if ( ! is_array( $v ) ) {\n\n $default_sanitize_rule = (is_numeric( $k )) ? 'html' : 'text';\n $sanitize_type = isset( $sanitize_rule[ $k ] ) ? $sanitize_rule[ $k ] : $default_sanitize_rule;\n $array[ $k ] = $this -> sanitize_value( $v, $sanitize_type );\n }\n if ( is_array( $v ) ) {\n $array[ $k ] = $this -> sanitize_array( $v, $sanitize_rule );\n }\n }\n\n return $array;\n }", "public static function sanitize_array ($data = array()) {\r\n\t\tif (!is_array($data) || !count($data)) {\r\n\t\t\treturn array();\r\n\t\t}\r\n\t\tforeach ($data as $k => $v) {\r\n\t\t\tif (!is_array($v) && !is_object($v)) {\r\n\t\t\t\t$data[$k] = sanitize_text_field($v);//htmlspecialchars(trim($v));\r\n\t\t\t}\r\n\t\t\tif (is_array($v)) {\r\n\t\t\t\t$data[$k] = self::sanitize_array($v);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn $data;\r\n\t}", "function widgetopts_sanitize_array( &$array ) {\n foreach ($array as &$value) {\n if( !is_array($value) ) {\n\t\t\t// sanitize if value is not an array\n $value = sanitize_text_field( $value );\n\t\t}else{\n\t\t\t// go inside this function again\n widgetopts_sanitize_array($value);\n\t\t}\n }\n\n return $array;\n}", "function sanitize_arr_string_xss(array $data): array\n{\n foreach ($data as $k => $v) {\n $data[$k] = filter_var($v, FILTER_SANITIZE_STRING);\n }\n return $data;\n}", "public function array_sanitize($array){\n\n\t\t\treturn htmlentities(mysql_real_escape_string($array));\n\n\t\t}", "function rest_sanitize_array($maybe_array)\n {\n }", "function clean($array){\n\n\t\treturn array_map('mysql_real_escape_string', $array);\n\n\t}", "private function sanitizeArray(array $values): array\n {\n return array_map([\n $this,\n 'sanitizeValue',\n ], $values);\n }", "function sanitize_array($array, $antlers = true)\n{\n $result = array();\n\n foreach ($array as $key => $value) {\n $key = htmlentities($key);\n $result[$key] = sanitize($value, $antlers);\n }\n\n return $result;\n}", "function sanitize($input) {\n if (is_array($input)) {\n foreach($input as $var=>$val) {\n $output[$var] = sanitize($val);\n }\n }\n else {\n $input = trim($input);\n if (get_magic_quotes_gpc()) {\n $input = stripslashes($input);\n }\n $output = strip_tags($input);\n }\n return $output;\n}", "function validate_array($array)\n{\n $arrayLng = count($array);\n for ($i = 0; $i < $arrayLng; ++$i) {\n $array[$i] = validate_input($array[$i]);\n }\n $array = array_filter($array);\n return $array;\n}", "public static function clean(array $array): array\n {\n /* loop overt all the values in the array */\n array_walk_recursive($array, function (&$item) {\n /* Check if the value is a string */\n if (is_string($item)) {\n /* Clean the string */\n $item = StringHelper::clean($item);\n }\n });\n /* Return the cleaned array */\n return $array;\n }", "public static function sanitizeArray(array $arrayToSanitize, string $sanitizationFunction): array\n\t{\n\t\t$sanitized = [];\n\n\t\tforeach ($arrayToSanitize as $key => $value) {\n\t\t\tif (\\is_array($value)) {\n\t\t\t\t$sanitizedValue = self::sanitizeArray($value, $sanitizationFunction);\n\t\t\t\t$sanitized[$key] = $sanitizedValue;\n\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$sanitized[$key] = $sanitizationFunction($value);\n\t\t}\n\n\t\treturn $sanitized;\n\t}", "protected function _sanitizeStrings(&$array)\n {\n foreach ($array as $key => $value) {\n if (is_array($value)) {\n $value = $this->_sanitizeStrings($value);\n }\n elseif (is_string($value) && strpos($value, self::JS_RAW) === false) {\n // sanitize\n $value = str_replace('\"', '', $value);\n }\n\n $array[$key] = $value;\n }\n\n return $array;\n }", "function sanitizeArray($data = array())\r\n{\r\n foreach ($data as $k => $v) {\r\n if (!is_array($v) && !is_object($v)) { // deep enough to only be values? sanitize them now.\r\n $data[$k] = sanitizeValue($v);\r\n }\r\n if (is_array($v)) { // go deeper\r\n $data[$k] = sanitizeArray($v);\r\n }\r\n }\r\n return $data;\r\n}", "function sanitizeAny($input = '')\r\n{\r\n if (!is_array($input) || !count($input)) {\r\n return sanitizeValue($input);\r\n } else {\r\n return sanitizeArray($input);\r\n }\r\n}", "function sanitizeArray(&$array)\n{\n $excludeListForSanitization = array('query');\n// $excludeListForSanitization = array();\n\n foreach ($array as $k => $v) {\n\n // split to key and value\n list($key, $val) = preg_split(\"/=/\", $v, 2);\n if (!isset($val)) {\n continue;\n }\n\n // when magic quotes is on, need to use stripslashes,\n // and then addslashes\n if (PHP_VERSION_ID < 50400 && get_magic_quotes_gpc()) {\n $val = stripslashes($val);\n }\n // note that we must use addslashes here because this function is called before the db connection is made\n // and sql_real_escape_string needs a db connection\n $val = addslashes($val);\n\n // if $key is included in exclude list, skip this param\n if (!in_array($key, $excludeListForSanitization)) {\n\n // check value\n if (strpos($val, '\\\\')) {\n list($val, $tmp) = explode('\\\\', $val);\n }\n\n // remove control code etc.\n $val = strtr($val, \"\\0\\r\\n<>'\\\"\", \" \");\n\n // check key\n if (preg_match('/\\\"/i', $key)) {\n unset($array[$k]);\n continue;\n }\n\n // set sanitized info\n $array[$k] = sprintf(\"%s=%s\", $key, $val);\n }\n }\n}", "function sanitizeArray( $arr ) {\n if (is_array($arr)) {\n foreach($arr as $key => &$data) {\n if (is_array($data)) {\n $data = sanitizeArray($data);\n } else {\n try {\n $json = json_decode( $data , true);\n if (is_array($json)) {\n $data = sanitizeArray( $json );\n continue;\n }\n } catch(Exception $e) {\n $data = sanitize($data);\n }\n }\n }\n }\n return $arr;\n}", "public function scrubArray(array $data) : array;", "public static function sanitiseArray($data)\n {\n $r = $data;\n\n foreach($r as $index => $value) {\n if(is_array($value)){\n $r[$index] = self::sanitiseArray($value);\n }\n\n if($value == null) {\n unset($r[$index]);\n }\n }\n\n return $r;\n }", "function sanitize($input) {\n if (is_array($input)) {\n foreach($input as $var=>$val) {\n $output[$var] = sanitize($val);\n }\n }else{\n if (get_magic_quotes_gpc()) {\n $input = stripslashes($input);\n }\n $input = cleanInput($input);\n $output = mysql_real_escape_string($input);\n }\n return $output;\n}", "private function sanitizeInput(array $inputArray){\n $counter = 0;\n $filteredInput = [];\n foreach ($inputArray as $key => $value) {\n $filteredInput[$key] = mysqli_real_escape_string($this->db, $value);\n }\n return $filteredInput;\n }", "public function sanitarize ($arr) \n {\n foreach( $arr as $key => $value ) {\n $returnArr[$key] = trim(htmlspecialchars($value));\n }\n return $returnArr;\n }", "private function sanitizeInput(array &$input)\n {\n foreach ($input as $key => &$value) {\n if (is_array($value)) {\n $value = $this->sanitizeInput($value);\n } elseif ($value === null) {\n $value = '';\n } else {\n $value = str_replace('<script>', '&lt;script&gt;', $value);\n }\n }\n\n return $input;\n }", "function qwe_clean($array){\r\n\r\n\t\t\t\t\t\t\t\t\t\treturn array_map('mysql_real_escape_string', $array) ;\r\n\t\t\t\t\t\t\t\t\t}", "protected function _purifyArray(array $arrayData,$type='string'){\n foreach($arrayData as $key=> $value){\n if(isset($value) && is_array($value)){\n $arrayData[$key]=$this->_purifyArray($value,$type);\n }elseif(isset($value)){\n $arrayData[$key]=$this->filter->clean(trim($value),$type);\n }\n }\n return $arrayData;\n }", "public static function clean ($arr){\n return is_array($arr) ? array_map('self::clean',$arr) : htmlspecialchars($arr, ENT_HTML5 | ENT_QUOTES);\n }", "public function sanitize()\n {\n $purifier = $this->_purifier;\n $this->_sanitized_data = array_map(\n function ($field) use ($purifier) {\n return $purifier->purify($field);\n },\n $this->_data\n );\n }", "public function sanitize($data) {\n $sanitized = array();\n foreach ( $data as $key => $val ) {\n if ( !is_array($val) ) {\n if ( isset($this->_sanitizers[$key]) ) {\n $sanitized[$key] = Data::sanitize($val, $this->_sanitizers[$key]);\n }\n } else {\n foreach ( $val as $id => $obj ) {\n $sanitized[$key][$id] = $obj->sanitize();\n }\n }\n }\n return $sanitized;\n }", "static function clean($array) {\n\n $cleanedVersion = $array;//TODO\n\n return $cleanedVersion;\n }", "public static function xss_clean(array $data)\n\t{\n\t\tforeach($data as $k => $v)\n\t\t{\n\t\t\t$data[$k] = filter_var($v, FILTER_SANITIZE_STRING);\t\t\n\t\t}\n\t\t\n\t\treturn $data;\n\t}", "public static function sanitizer(&$data, bool $array = true): void\n {\n $data = self::sanitize($data, $array);\n }", "private function sanitize ($query) {\n return array_map(array($this, 'clean'), $query);\n }", "protected function sanitizeData(): array {\n $sanitizedData = [];\n foreach ($this->rawData as $data) {\n $sanitizedData[] = htmlentities($data);\n }\n return $sanitizedData;\n }", "private function cleanInputs($data){\n\t\t$clean_input = array();\n\t\tif(is_array($data)){\n\t\t\tforeach($data as $k => $v){\n\t\t\t\t$clean_input[$k] = $this->cleanInputs($v);\n\t\t\t}\n\t\t}else{\n\t\t\tif(get_magic_quotes_gpc()){ \n\t\t\t// Returns 0 if magic_quotes_gpc is off, \n\t\t\t// 1 otherwise. Always returns FALSE as of PHP 5.4\n\t\t\t\t$data = trim(stripslashes($data));\n\t\t\t}\n\t\t\t$data = strip_tags($data);\n\t\t\t$clean_input = trim($data);\n\t\t}\n\t\treturn $clean_input;\n\t}", "function sanitize($arg) {\n if (is_array($arg)) {\n return array_map('sanitize', $arg);\n }\n\n return htmlentities($arg, ENT_QUOTES, 'UTF-8');\n}", "function sanitize($mixed = null)\n{\n if (!is_array($mixed)) {\n return convertHtmlEntities($mixed);\n }\n function array_map_recursive($callback, $array)\n {\n $func = function ($item) use (&$func, &$callback) {\n return is_array($item) ? array_map($func, $item) : call_user_func($callback, $item);\n };\n return array_map($func, $array);\n }\n return array_map_recursive('convertHtmlEntities', $mixed);\n}", "public static function sanitize($value)\n\t{\n\t\tif (is_array($value) OR is_object($value))\n\t\t{\n\t\t\tforeach ($value as $key => $val)\n\t\t\t{\n\t\t\t\t// Recursively clean each value\n\t\t\t\t$value[$key] = self::sanitize($val);\n\t\t\t}\n\t\t}\n\t\telseif (is_string($value))\n\t\t{\n\t\t\tif (self::$magic_quotes === TRUE)\n\t\t\t{\n\t\t\t\t// Remove slashes added by magic quotes\n\t\t\t\t$value = stripslashes($value);\n\t\t\t}\n\n\t\t\tif (strpos($value, \"\\r\") !== FALSE)\n\t\t\t{\n\t\t\t\t// Standardize newlines\n\t\t\t\t$value = str_replace(array(\"\\r\\n\", \"\\r\"), \"\\n\", $value);\n\t\t\t}\n\t\t}\n\n\t\treturn $value;\n\t}", "function array_sanitize(&$item){\n $item = htmlentities(strip_tags(mysql_real_escape_string($item)));\n }", "function sanitize($input) {\n\t\t$cleaning = $input;\n\t\t\n\t\tswitch ($cleaning) {\n\t\t\tcase trim($cleaning) == \"\":\n\t\t\t\t$clean = false;\n\t\t\t\tbreak;\n\t\t\tcase is_array($cleaning):\n\t\t\t\tforeach($cleaning as $key => $value) {\n\t\t\t\t\t$cleaning[] = sanitize($value);\n\t\t\t\t}\n\t\t\t\t$clean = implode(\",\", $cleaning);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tif(get_magic_quotes_gpc()) {\n\t\t\t\t\t$cleaning = stripslashes($cleaning);\n\t\t\t\t}\n\t\t\t\t$cleaning = strip_tags($cleaning);\n\t\t\t\t$clean = trim($cleaning);\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\treturn $clean;\n\t}", "protected static function clean_array() {\n\t\treturn array( '<', '>', '&', \"'\", '\"' );\n\t}", "public static function sanitize($data, bool $array = true)\n {\n return json_decode(json_encode($data), $array);\n }", "public static function sanitize(&$dirty, int $filter = FILTER_SANITIZE_STRING)\n {\n if (!is_array($dirty)) {\n // If dirty argument isn't an array, change it directly\n $dirty = filter_var(trim($dirty), $filter);\n } else {\n // Walk through each member of the array, inheriting $filter for use inside anonymous function\n array_walk_recursive($dirty, function (&$value) use ($filter) {\n $value = filter_var(trim($value), $filter); // changes original array ($value passed by reference)\n });\n }\n return $dirty;\n }", "protected function clean(Array $data)\n {\n foreach ($data as $key => $value) {\n // If the input data has a value that isn't in the whiteList, remove it from the array\n if (!array_key_exists($key, $this->whiteList)) {\n unset($data[$key]);\n }\n }\n return $data;\n }", "function sanitize_settings( $input ) {\n\t\t\tif( empty( $input ) )\n\t\t\t\treturn false;\n\t\t\t\n\t\t\tif( !is_array( $input ) )\n\t\t\t\t/**\n\t\t\t\t * For some reason, the sanitize callback runs twice, so we don't want to \n\t\t\t\t * \t\texplode something that's already an array \n\t\t\t\t */\n\t\t\t\t$input = explode( ';', $input );\n\t\t\t\n\t\t\t/* Split the list and trim whitespace around each item */\n\t\t\t$input = array_map( 'trim', $input );\n\t\t\t\n\t\t\t/* Turn it into an array if it's not already */\n\t\t\tif( !is_array( $input ) )\n\t\t\t\t$input = array( $input );\n\t\t\t\n\t\t\t/* Make sure all of the addresses are valid emails */\n\t\t\t$input = array_filter( $input, 'is_email' );\n\t\t\t\n\t\t\tif( empty( $input ) )\n\t\t\t\treturn false;\n\t\t\t\n\t\t\treturn $input;\n\t\t}", "function cleanseInput(&$data)\r\n{\r\n if (is_array($data))\r\n {\r\n foreach ($data as &$subItem)\r\n {\r\n $subItem = cleanseInput($subItem);\r\n }\r\n }\r\n \r\n else\r\n { \r\n $data = trim($data, \"';#\");\r\n $data = stripslashes($data);\r\n $data = htmlspecialchars($data);\r\n }\r\n \r\n return $data;\r\n}", "function trim_array($input)\n{\n if (!is_array($input))\n {\n return trim($input);\n }\n\n return array_map('trim_array', $input);\n}", "function sanitizeData($data) {\n if(!is_array($data)){\n // Remove all tags execpt <a> tags\n return strip_tags($data, \"<a>\");\n } else {\n // Call sanitizeData recursively for each array element\n return array_map('sanitizeData', $data);\n }\n}", "public static function arrayScrub($array)\n {\n if (!Arrays::isArray($array, false)) {\n return false;\n }\n\n $narr = array();\n\n while (list($key, $val) = each($array)) {\n if (is_array($val)) {\n $val = Arrays::arrayScrub($val);\n\n // does the result array contain anything?\n if (count($val) != 0) {\n // yes :-)\n $narr[$key] = $val;\n }\n } else {\n if ((false !== $val) && (!is_null($val))) {\n if (trim($val) != '') {\n $narr[$key] = $val;\n }\n }\n }\n }\n unset($array);\n\n return $narr;\n }", "public function normalizeArray(array $config): array;", "public static function mongo_sanitize(&$data) {\n foreach ($data as $key => $item) {\n is_array($item) && !empty($item) && $data[$key] = self::mongo_sanitize($item);\n if (is_array($data) && preg_match('/^\\$/', $key)) {\n unset($data[$key]);\n }\n }\n return $data;\n }", "public static function sanitize($input)\n {\n $new_input = array();\n if (isset($input['id_number']))\n $new_input['id_number'] = absint($input['id_number']);\n\n if (isset($input['title']))\n $new_input['title'] = sanitize_text_field($input['title']);\n\n return $new_input;\n }", "public function sanitize($value)\r\n\t{\r\n\t\tarray_walk(\r\n\t\t\t$value,\r\n\t\t\tfunction(&$value) {\r\n\t\t\t\t$value=trim($value);\r\n\t\t\t\t}\r\n\t\t\t);\r\n\t\treturn $value;\r\n\t}", "public function sanitize_data($data_array) {\n // The sequence of these events is important!\n $data_array = $this->remove_empty_rows($data_array); // run first to get rid of trailing CSV row from Excel save-as\n $data_array = $this->pad_to_rectangle($data_array);\n $data_array = $this->trim_all_elements($data_array);\n $data_array = $this->remove_empty_rows($data_array);\n $data_array = $this->remove_empty_cols($data_array);\n $data_array = $this->slugify_headers($data_array, 0);\n // $data_array = $this->slugify_levels($data_array, 0, array('/#/'=>'num'));\n $data_array = $this->infer_levels($data_array);\n $data_array = $this->remove_subtotals($data_array);\n $data_array = $this->remove_duplicates($data_array);\n $data_array = $this->convert_timepoints_to_numbers($data_array);\n\n return $data_array;\n }", "private function arrayClean($array)\n {\n foreach ($array as $key=>$value) {\n if(is_array($value))\n $this->arrayClean($value);\n else if($value!==null)\n unset($value);\n }\n }", "function array_sanitize (&$item) {\n\t\tif (is_string ($item)) {\n\t\t\t$item = htmlentities (mysqli_real_escape_string ($GLOBALS['con'], $item),ENT_NOQUOTES,\"utf-8\");\n\t\t}\n\t}", "public static function sanitize(array $input, $fields = NULL)\n\t{\n\t\t$magic_quotes = (bool)get_magic_quotes_gpc();\n\t\t\n\t\tif(is_null($fields))\n\t\t{\n\t\t\t$fields = array_keys($input);\n\t\t}\n\n\t\tforeach($fields as $field)\n\t\t{\n\t\t\tif(!isset($input[$field]))\n\t\t\t{\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$value = $input[$field]; \n\t\t\t\t\n\t\t\t\tif(is_string($value))\n\t\t\t\t{\n\t\t\t\t\tif($magic_quotes === TRUE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$value = stripslashes($value);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif(strpos($value, \"\\r\") !== FALSE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$value = trim($value);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tif(function_exists('iconv'))\n\t\t\t\t\t{\n\t\t\t\t\t\t$value = iconv('ISO-8859-1', 'UTF-8', $value);\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$value = filter_var($value, FILTER_SANITIZE_STRING);\t\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$input[$field] = $value;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $input;\t\t\n\t}", "protected function validateInput($input)\n {\n if ($this->expectArray) {\n if (! \\is_array($input)) {\n throw InvalidInputException::filterTypeError($this, $input);\n }\n\n return array_map(function ($value) {\n return TypeCaster::cast($value, $this->type, $this->format);\n }, $input);\n }\n\n if (\\is_array($input)) {\n throw InvalidInputException::filterTypeError($this, $input);\n }\n\n return TypeCaster::cast($input, $this->type, $this->format);\n }", "public function validate(array $input) {\r\n\t\treturn $input;\r\n\t}", "function arrayClean(&$array) {\n\tif (!is_array($array)) return null;\n\treturn array_filter($array, create_function('$o', 'return !empty($o);'));\n}", "public static function sanitize($value)\n {\n if (is_array($value) OR is_object($value))\n {\n foreach ($value as $key => $val)\n {\n // Recursively clean each value\n $value[$key] = Kohana::sanitize($val);\n }\n }\n elseif (is_string($value))\n {\n if (Kohana::$magic_quotes === TRUE)\n {\n // Remove slashes added by magic quotes\n $value = stripslashes($value);\n }\n\n if (strpos($value, \"\\r\") !== FALSE)\n {\n // Standardize newlines\n $value = str_replace(array(\"\\r\\n\", \"\\r\"), \"\\n\", $value);\n }\n\n //Added strip tags\n $value = strip_tags($value);\n }\n\n return $value;\n }", "private function _clean_input_data($str) {\n\t\tif (is_array($str)) {\n\t\t\t$new_array = array();\n\t\t\tforeach ($str as $key => $val) {\n\t\t\t\t$new_array [ $this->_clean_input_keys($key) ] = $this->_clean_input_data($val);\n\t\t\t}\n\n\t\t\treturn $new_array;\n\t\t}\n\n\t\t// We strip slashes if magic quotes is on to keep things consistent\n\t\tif ($this->quotes_gpc) {\n\t\t\t$str = stripslashes($str);\n\t\t}\n\n\t\t// Should we filter the input data?\n\t\tif ($this->use_xss_clean === true) {\n\t\t\t$str = Request::$xss_cleaner->xss_clean($str);\n\t\t}\n\n\t\t// Standardize newlines\n\t\tif (strpos($str, \"\\r\") !== false) {\n\t\t\t$str = str_replace(array(\"\\r\\n\", \"\\r\"), \"\\n\", $str);\n\t\t}\n\n\t\treturn $str;\n\t}", "public function sanitize( $input )\n {\n $new_input = array();\n if( isset( $input['pre_days'] ) )\n $new_input['pre_days'] = sanitize_text_field( $input['pre_days'] );\n\n if( isset( $input['pre_days_file'] ) )\n $new_input['pre_days_file'] = sanitize_text_field( $input['pre_days_file'] );\n\t\n\tif( isset( $input['main_days'] ) )\n $new_input['main_days'] = sanitize_text_field( $input['main_days'] );\n\n if( isset( $input['main_days_file'] ) )\n $new_input['main_days_file'] = sanitize_text_field( $input['main_days_file'] );\n\n\n return $new_input;\n }", "private static function doFixArray(array &$array){\n if( get_magic_quotes_gpc() == 1 ){\n foreach($array as $key => $value){\n if( is_array($value) )\n $array[$key] = self::doFixArray($value);\n else\n $array[$key] = stripslashes($value);\n }\n }\n }", "abstract public function sanitize();", "private function _clean_input_data($str)\n {\n if (is_array($str))\n {\n $new_array = array();\n foreach ($str as $key => $val)\n {\n $new_array[$this->_clean_input_keys($key)] = $this->_clean_input_data($val);\n }\n return $new_array;\n }\n\n /* We strip slashes if magic quotes is on to keep things consistent\n\n NOTE: In PHP 5.4 get_magic_quotes_gpc() will always return 0 and\n it will probably not exist in future versions at all.\n */\n if (get_magic_quotes_gpc())\n {\n $str = stripslashes($str);\n }\n\n // Clean UTF-8 if supported\n $str = $this->clean_string($str);\n // Remove control characters\n $str = $this->remove_invisible_characters($str);\n\n // Should we filter the input data?\n if ($this->_enable_xss === true)\n {\n $str = $this->xss_clean($str);\n }\n\n\n // Standardize newlines if needed\n if ($this->_standardize_newlines == true)\n {\n if (strpos($str, \"\\r\") !== false)\n {\n $str = str_replace(array(\"\\r\\n\", \"\\r\", \"\\r\\n\\n\"), PHP_EOL, $str);\n }\n }\n\n return $str;\n }", "function cleanArray($array)\r\n\t{\r\n\t\tif (is_array($array))\r\n\t\t{\r\n\t\t\tforeach ($array as $key => $sub_array)\r\n\t\t\t{\r\n\t\t\t\t$result = $this->cleanArray($sub_array);\r\n\t\t\t\tif ($result === false)\r\n\t\t\t\t{\r\n\t\t\t\t\tunset($array[$key]);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\t$array[$key] = $result;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t\r\n\t\tif (empty($array))\r\n\t\t{\r\n\t\t\t//return false;\r\n\t\t}\r\n\t\r\n\t\treturn $array;\r\n\t\r\n\t}", "public function cleanInput($input, $opt) {\r\n\r\n switch ($opt) {\r\n case 'string': $filter = FILTER_SANITIZE_STRING;\r\n break;\r\n case 'int': $filter = FILTER_SANITIZE_NUMBER_INT;\r\n break;\r\n case 'special': $filter = FILTER_SANITIZE_SPECIAL_CHARS;\r\n break;\r\n case 'base64':\r\n return $input;\r\n break;\r\n case 'none':\r\n return $input;\r\n break;\r\n default: $filter = FILTER_SANITIZE_STRING;\r\n break;\r\n }\r\n\r\n\r\n if (is_array($input)) {\r\n $clean = array();\r\n foreach ($input as $value) {\r\n $value = filter_var($value, $filter);\r\n $clean[] = $value;\r\n }\r\n return $clean;\r\n } else {\r\n return filter_var($input, $filter);\r\n }\r\n }", "function sanitizeArray( &$data, $whatToKeep )\n{\n $data = array_intersect_key( $data, $whatToKeep ); \n \n foreach ($data as $key => $value) {\n\n $data[$key] = sanitizeOne( $data[$key] , $whatToKeep[$key] );\n\n }\n}", "public function sanitize( $input ) {\n\n $input = preg_split( '/\\s+/', trim( $input ) );\n\n return $input;\n }", "public static function clean($array) {\n\t\t\treturn array_filter($array, function($item) {\n\t\t\t\treturn !empty($item);\n\t\t\t});\n\t\t}", "public function sanitizeRequest(array $template, array $input) : array\n\t{\n\t\t$this->sanitizer = $this->getSanitizer($template)->sanitize($input);\n\n\t\treturn $this->sanitizer;\n\t}", "function mf_sanitize($input){\n\t\tif(get_magic_quotes_gpc() && !empty($input)){\n\t\t\t $input = is_array($input) ?\n\t array_map('mf_stripslashes_deep', $input) :\n\t stripslashes(trim($input));\n\t\t}\n\t\t\n\t\treturn $input;\n\t}", "function process($source) {\n\t\t// clean all elements in this array\n\t\tif (is_array($source)) {\n\t\t\tforeach($source as $key => $value)\n\t\t\t\t// filter element for XSS and other 'bad' code etc.\n\t\t\t\tif (is_string($value)) $source[$key] = $this->remove($this->decode($value));\n\t\t\treturn $source;\n\t\t// clean this string\n\t\t} else if (is_string($source)) {\n\t\t\t// filter source for XSS and other 'bad' code etc.\n\t\t\treturn $this->remove($this->decode($source));\n\t\t// return parameter as given\n\t\t} else return $source;\t\n\t}", "public function sanitize($input)\n {\n $new_input = array();\n\n if (isset($input['product_fields']))\n $new_input['product_fields'] = $input['product_fields'];\n\n if (isset($input['cache_lifetime']))\n $new_input['cache_lifetime'] = absint($input['cache_lifetime']);\n\n if (isset($input['images_size']))\n $new_input['images_size'] = $input['images_size'];\n\n return $new_input;\n }", "function clean_int_array( $array=array() )\n {\n\t\t$return = array();\n\t\t\n\t\tif ( is_array( $array ) and count( $array ) )\n\t\t{\n\t\t\tforeach( $array as $k => $v )\n\t\t\t{\n\t\t\t\t$return[ intval($k) ] = intval($v);\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $return;\n\t}", "function arrayStripslashes(&$array) {\n if (!is_array($array)) {\n return;\n }\n foreach ($array as $k => $v) {\n if (is_array($array[$k])) {\n arrayStripslashes($array[$k]);\n } else {\n $array[$k] = stripslashes($array[$k]);\n }\n }\n return $array;\n}", "function clean_input($input){\n\n\t$clean;\t//clean version of variable\n\n\tif (is_string($input)){\n\t\t$clean = mysql_real_escape_string(stripslashes(ltrim(rtrim($input))));\n\t}\n\telse if (is_numeric($input)){\n\t\t$clean = mysql_real_escape_string(stripslashes(ltrim(rtrim($input))));\n\t}\n\telse if (is_bool($input)){\n\t\t$clean = ($input) ? true : false;\n\t}\n\telse if (is_array($input)){\n\t\tforeach ($input as $k=>$i){\n\t\t\t$clean[$k] = clean_input($i);\n\t\t}\n\t}\n\t\n\treturn $clean;\n\t\n}", "function stripslashes_array( $given ) {\n return is_array( $given ) ? array_map( 'stripslashes', $given ) : stripslashes( $given );\n}", "function array_trim($Input) {\n\tif (!is_array($Input))\n\t\treturn trim($Input);\n\treturn array_map('array_trim', $Input);\n}", "function stripSlashesDeep($value) {\r\n $value = is_array($value) ? array_map('cleanInputs', $value) : stripslashes($value);\r\n return $value;\r\n}", "function clearXss(array &$array, AntiXSS $antiXSS)\n{\n foreach ($array as &$value) {\n if (\\is_array($value)) {\n clearXss($value, $antiXSS);\n } else {\n $value = $antiXSS->xss_clean($value);\n }\n }\n}", "function sanitize($dataArray)\n\t{\n\t\t$this->data[\"username\"] = filter_var($dataArray[\"username\"], FILTER_SANITIZE_STRING);\n\t\t$this->data[\"password\"] = filter_var($dataArray[\"password\"], FILTER_SANITIZE_STRING);\n\t\t$this->data[\"description\"] = filter_var($dataArray[\"description\"], FILTER_SANITIZE_STRING);\n\t\t$this->data[\"quote\"] = filter_var($dataArray[\"quote\"], FILTER_SANITIZE_STRING);\n\t\t\n\t\t/* if(isset($this->data[\"user_level\"]))\n\t\t{\n\t\t\t$this->data[\"user_level\"] = filter_var($dataArray[\"user_level\"], FILTER_SANITIZE_STRING);\n\t\t} */\n\t\treturn $dataArray;\n\t}", "function stripslashes_array( $value ){\n\t$value = is_array( $value ) ? array_map( 'stripslashes_array', $value ) : stripslashes( $value );\n\n\treturn $value;\n}", "private function _from_array($array, $par, $xss_clean = false)\n {\n if(isset($array[$par])) {\n if($xss_clean) {\n return $this->xss_clean($array[$par]);\n }\n else\n return $array[$par];\n }\n else if($par == null) {\n if($xss_clean) {\n return $this->xss_clean($array);\n }\n else\n return $array;\n }\n else\n return false;\n }", "public static function clean(array $array): array\n {\n return array_values(array_filter($array));\n }", "private function format_array( $array ) {\n\n if ( !is_array( $array ) ) {\n\n if ( is_serialized( $array ) ) {\n\n $array = maybe_unserialize( $array );\n\n }\n else {\n\n $array = explode( ',', $array );\n\n }\n\n }\n\n return array_filter( array_map( 'trim', array_map( 'strtolower', $array ) ) );\n\n }", "function revertArrayForSanitizing($array, &$dst)\n{\n foreach ($array as $v) {\n list($key, $val) = preg_split(\"/=/\", $v, 2);\n $dst[$key] = $val;\n }\n}", "protected function sanitizeValue($method, $value, $getArray) {\n\t\t\n\t\t$sanitizer = $this->wire()->sanitizer;\n\t\t$sanitizers = $sanitizer->getAll(true);\n\t\t$methods = array();\n\t\t\n\t\tforeach(explode(',', $method) as $name) {\n\t\t\t$name = trim($name);\n\t\t\tif(empty($name)) continue;\n\t\t\tif(!isset($sanitizers[$name])) throw new WireException(\"Unknown sanitizer '$method'\"); \n\t\t\t$methods[$name] = $sanitizers[$name]; // value is return type(s)\n\t\t}\n\t\n\t\t$lastReturnType = end($methods); \n\t\tif(!$getArray) {\n\t\t\tif($lastReturnType === 'a') {\n\t\t\t\t$getArray = true; // array return value implied\n\t\t\t} else if(strpos($lastReturnType, 'a') !== false) {\n\t\t\t\t$getArray = 1; // array return value possible\n\t\t\t}\n\t\t}\n\t\t\n\t\tforeach($methods as $methodName => $returnType) {\n\t\t\t\n\t\t\t$methodName = trim($methodName);\n\t\t\tif(empty($methodName)) continue;\n\t\t\t\n\t\t\tif(is_array($value)) {\n\t\t\t\t// array value\n\t\t\t\tif(!count($value)) {\n\t\t\t\t\t// nothing to do with value\n\t\t\t\t\t$value = array();\n\t\t\t\t} else if($getArray && strpos($returnType, 'a') === false) {\n\t\t\t\t\t// sanitize array with sanitizer that does not do arrays, 1 item at a time\n\t\t\t\t\t$a = array();\n\t\t\t\t\tforeach($value as $v) {\n\t\t\t\t\t\t$cv = $sanitizer->sanitize($v, $methodName);\n\t\t\t\t\t\tif($cv !== null) $a[] = $cv;\n\t\t\t\t\t}\n\t\t\t\t\t$value = $a;\n\t\t\t\t} else if($getArray) {\n\t\t\t\t\t// sanitizer that can handle arrays\n\t\t\t\t\t$value = $sanitizer->sanitize($value, $methodName);\n\t\t\t\t} else {\n\t\t\t\t\t// sanitizer does not do arrays, reduce to 1st array item\n\t\t\t\t\t$value = reset($value);\n\t\t\t\t\t$value = $sanitizer->sanitize($value, $methodName);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t// non-array value\n\t\t\t\t$value = $sanitizer->sanitize($value, $methodName);\n\t\t\t}\n\t\t}\n\t\t\n\t\tif($getArray === true && !is_array($value)) {\n\t\t\t$value = array($value);\n\t\t}\n\t\t\n\t\treturn $value; \n\t}", "function sanitize(){\r\n\t\t $outar = Array();\r\n \t $arg_list = func_get_args();\r\n\t\t foreach($arg_list[0] as $key => $value){\r\n\t\t\t\t $data = $value;\r\n\t\t\t\t $data = PREG_REPLACE(\"/[^0-9a-zA-Z]/i\", '', $data);\r\n\t\t\t\t array_push($outar,$data);\r\n\t\t }\r\n\t\treturn $outar;\r\n\t }", "public function sanitize() {\n\n\t\t// load the tool that we want to use in the xss filtering process\n\t\t$this->loadTool();\n\n\t\tif (is_array($_GET) AND count($_GET) > 0) {\n\n\t\t\t$_GET = $this->clean_input_data($_GET);\n\t\t}\n\t\tif (is_array($_POST) AND count($_POST) > 0) {\n\n\t\t\t$_POST = $this->clean_input_data($_POST);\n\t\t}\n\t\tif (is_array($_COOKIE) AND count($_COOKIE) > 0) {\n\n\t\t\t$_COOKIE = $this->clean_input_data($_COOKIE);\n\t\t}\n\t\tif (is_array($_FILES) AND count($_FILES) > 0) {\n\n\t\t\t//$_FILES = $this->clean_input_data($_FILES, true);\n\t\t}\n\n\t}", "public function sanitize(){\r\n\t\t$post = array();\r\n\t\tforeach($_POST as $key => $val){\r\n\t\t\tif(!get_magic_quotes_gpc()){\r\n\t\t\t\t$post[$key] = mysql_real_escape_string($val);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn $post;\r\n\t}", "private function sanitize($form_data) {\n $sanitized_data = filter_var_array($form_data, FILTER_SANITIZE_STRING);\n \n // Return the sanitized datas\n return $sanitized_data;\n }", "static function array_clean($array) {\n\t\treturn array_diff($array,array(null,'',\"\\n\",\"\\s\",\"\\r\",\"\\r\\n\",\"\\n\\r\"));\n\t}", "private function sanitizeInput(array $input) {\n\t\t// add verbose level\n\t\tif (!isset($input['--verbose'])) {\n\t\t\t$input['--verbose'] = $this->io->getInput()->getOption('verbose');\n\t\t}\n\n\t\t// check if at least one argument is present and if not add a blank one\n\t\t$hasArgs = false;\n\t\tforeach (array_keys($input) as $key) {\n\t\t\tif (!Text::create($key)->startsWith('--')) {\n\t\t\t\t$hasArgs = true;\n\t\t\t}\n\t\t}\n\t\tif (!$hasArgs) {\n\t\t\t$input[] = '';\n\t\t}\n\t\n\t\treturn $input;\n\t}", "function convArrayForSanitizing($src, &$array)\n{\n $array = array();\n foreach ($src as $key => $val) {\n if (key_exists($key, $_GET)) {\n array_push($array, sprintf(\"%s=%s\", $key, $val));\n }\n }\n}", "public static function clean($request)\n {\n foreach ($request as &$value) {\n if (is_array($value)){\n $value = self::clean($value);\n } else {\n if(!get_magic_quotes_gpc()) {\n $value = addslashes($value);\n }\n $value = strip_tags(htmlspecialchars(stripslashes($value)));\n }\n }\n return $request;\n }", "public function sanitize( $input )\n {\n $new_input = array();\n if( isset( $input['dept_address'] ) )\n $new_input['dept_address'] = $input['dept_address'] ;\n\n if( isset( $input['title'] ) )\n $new_input['title'] = sanitize_text_field( $input['title'] );\n\n if( isset( $input['fb'] ) )\n $new_input['fb'] = sanitize_text_field( $input['fb'] );\n\n if( isset( $input['twitter'] ) )\n $new_input['twitter'] = sanitize_text_field( $input['twitter'] );\n\n if( isset( $input['instagram'] ) )\n $new_input['instagram'] = sanitize_text_field( $input['instagram'] );\n\n if( isset( $input['youtube'] ) )\n $new_input['youtube'] = sanitize_text_field( $input['youtube'] );\n\n if( isset( $input['rss'] ) )\n $new_input['rss'] = sanitize_text_field( $input['rss'] );\n\n return $new_input;\n }", "public function sanitize( $input )\n {\n $new_input = array();\n if( isset( $input['id_number'] ) )\n $new_input['id_number'] = absint( $input['id_number'] );\n\n if( isset( $input['ga_email'] ) )\n $new_input['ga_email'] = sanitize_text_field( $input['ga_email'] );\n\n if( isset( $input['ga_password'] ) )\n $new_input['ga_password'] = sanitize_text_field( $input['ga_password'] );\n\n return $new_input;\n }", "function cleanArrayInput($value)\n\t{\n\t\t$returnValue = 0;\n\t\t\n\t\t$tempValue = strip_tags( trim( $value ) ); \n\t\t\n\t\tif ( is_numeric( $tempValue ) )\n\t\t{\n\t\t\t$returnValue = $tempValue; \n\t\t}\n\t\t\n\t\treturn $returnValue;\n }", "function wpsl_sanitize_multi_array( &$item, $key ) {\n $item = sanitize_text_field( $item );\n}" ]
[ "0.7774483", "0.75636953", "0.7553188", "0.7404712", "0.7176869", "0.70846635", "0.70500994", "0.7005178", "0.6986065", "0.6976998", "0.6875387", "0.68607193", "0.68546754", "0.6803448", "0.6776442", "0.6763725", "0.6757402", "0.6754562", "0.6707987", "0.6698542", "0.664185", "0.6621483", "0.6611022", "0.65770656", "0.65653294", "0.65389407", "0.65217453", "0.65178424", "0.64736927", "0.6469969", "0.6435298", "0.64244777", "0.63746154", "0.63524264", "0.63478553", "0.62980294", "0.62963825", "0.6280039", "0.6263737", "0.6238278", "0.62163526", "0.62142223", "0.61925745", "0.6191959", "0.61858356", "0.6184525", "0.61791664", "0.61654174", "0.6119457", "0.6118498", "0.6109374", "0.61033005", "0.6101178", "0.60962236", "0.6086938", "0.60718596", "0.6067394", "0.6063267", "0.60493124", "0.6035999", "0.60355335", "0.6033635", "0.60140735", "0.6001773", "0.5993968", "0.5992741", "0.5992291", "0.5982315", "0.5972304", "0.5969461", "0.5961848", "0.595459", "0.5952295", "0.59270024", "0.59237677", "0.5919244", "0.590473", "0.5898857", "0.5897814", "0.58924997", "0.58862126", "0.5883951", "0.5883391", "0.5876336", "0.5869801", "0.5861254", "0.5840534", "0.58372056", "0.58361065", "0.5829173", "0.58290523", "0.5825344", "0.5817263", "0.58157945", "0.58148366", "0.5812497", "0.58116263", "0.5807989", "0.5789335", "0.5779052", "0.5766045" ]
0.0
-1
put your code here
public function __construct() { parent::__construct(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n //\n \n }", "public function run()\n\t{\n\t\t//\n\t}", "public function preExecute(){\n\n\t\n\t}", "function script()\n {\n }", "public function run()\n {\n \n }", "public function run()\n {\n \n }", "public function custom()\n\t{\n\t}", "public function run()\n {\n //\n }", "public function run()\n {\n //\n }", "public function run()\r\n {\r\n\r\n }", "public function run(){\n parent::run();\n //Do stuff...\n }", "function run() {\r\n $this->set_demopage();\r\n\r\n $options_def = array(\r\n __class__ => '', // code CSS. ATTENTION [ ] à la place des {}\r\n 'id' => ''\r\n );\r\n\r\n $options = $this->ctrl_options($options_def);\r\n\r\n // il suffit de charger le code dans le head\r\n $this->load_css_head($options[__class__]);\r\n\r\n // -- aucun code en retour\r\n return '';\r\n }", "public function run()\n {\n\n parent::run();\n\n }", "public function run()\n {\n\n }", "public function run()\n {\n\n }", "public function run()\n {\n\n }", "function execute()\r\n\t{\r\n\t\t\r\n\t}", "protected function doExecute()\n\t{\n\t\t// Your application routines go here.\n\t}", "function use_codepress()\n {\n }", "public function run()\n {\n // Put your code here;\n }", "function run()\r\n {\r\n }", "public function run()\n {\n }", "public function run()\n {\n }", "public function run()\n {\n }", "public function run()\n {\n }", "public function run() {\n }", "public static function run() {\n\t}", "public function onRun()\n {\n }", "public function run() {\n\t\t\\Yii::trace(__METHOD__.'()', 'sweelix.yii1.admin.core.widgets');\n\t\t$content = ob_get_contents();\n\t\tob_end_clean();\n\t\tif(\\Yii::app()->user->isGuest === true) {\n\t\t\techo $content;\n\t\t} else {\n\t\t\t$this->render('header');\n\t\t}\n\t}", "public function run() {\n }", "public function render_content() {\n\t}", "public function main()\r\n {\r\n \r\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "public function render_content()\n {\n }", "function render() ;", "function execute()\n {\n }", "public function run(): void\n {\n //\n }", "protected function main()\n /**/\n {\n parent::run();\n }", "public function execute()\n {\n //echo __('Hello Webkul Team.');\n $this->_view->loadLayout();\n $this->_view->renderLayout();\n }", "public function render()\n {\n //\n }", "public function run(){\n echo CHtml::closeTag( \"div\" );\n $this->registerScript();\n }", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "public function run();", "function __desctuct(){\r\n\t\t?>\r\n\r\n\t\t</body>\r\n\t\t</html>\r\n\t\t<?php\r\n\t}", "public function run(){}", "public function demo()\n {\n // xu ly logic\n }", "protected function render_content()\n {\n }", "protected function render_content()\n {\n }", "protected function render_content()\n {\n }", "protected function render_content()\n {\n }", "public function render(){\n\t\t\n\t}", "public static function main(){\n\t\t\t\n\t\t}", "public function render() {\r\n\t\t\r\n\t}", "public function main()\n\t{\n\t}", "function handle() ;", "public function execute() {\n\t}", "function preProcess()\n {\t\n parent::preProcess( );\n\t\t \n\t}", "public function run() {}", "public\n\n\tfunction generate_code()\n\t{\n\t\t$data[\"hitung\"] = $this->Madmin->buat_code();\n\t\t$this->load->view('admin/Generate_code', $data);\n\t}", "public function display_code() {\n\t\techo '<h1>Premise Demo Page</h1>\n\t\t<div class=\"span10\">';\n\n\n\t\t\t// test a form with all possible fields.\n\t\t\t// pass your own arguments if you'd like.\n\t\t\t// new PWP_Demo_Form();\n\n\t\t\t// Premise_test::fields();\n\t\t\t// Premise_test::fields_hooks();\n\t\t\t// Premise_test::fields_demo();\n\t\t\t// Premise_test::videos_embed();\n\t\t\t// Premise_test::fields_duplicate();\n\t\t\t// Premise_test::google_map();\n\t\t\t// Premise_test::grids();\n\n\t\techo '</div>';\n\t}", "function main()\r\n {\r\n $this->setOutput();\r\n }", "public function run()\n\n {\n DB::table('actives')->insert([\n 'script_tag' => 0,\n 'status' =>0\n \n ]);\n //\n }", "protected function _exec()\n {\n }", "public function run() {\n\n\t\t// generate random string md5(uniqid(rand(), true));\n\t\t$this->goneta();\n\t\t$this->pamparam();\n\t\t$this->insideOut();\n\t\t$this->morfoza();\n\t\t$this->basorelief();\n\t\t$this->acajouWasZuSagen();\n\t}", "protected function after_load(){\n\n\n }", "public function work()\n {\n }", "function run();", "function run();", "public function run() {\n\t\t// include other classes\n\t\trequire_once plugin_dir_path ( __FILE__ ) . 'class-top-ratter-render.php';\n\t\trequire_once plugin_dir_path ( __FILE__ ) . 'class-top-ratter-sso.php';\n\t\t\n\t\t// enque styles for this plugin\n\t\tadd_action ( 'wp_enqueue_scripts', array (\n\t\t\t\t$this,\n\t\t\t\t'register_plugin_styles' \n\t\t) );\n\t\t// enque jquery scripts for this plugin\n\t\tadd_action ( 'wp_enqueue_scripts', array (\n\t\t\t\t$this,\n\t\t\t\t'register_plugin_script' \n\t\t) );\n\t\t// add submit action form to redirect and catch from admin.php\n\t\tadd_action ( 'admin_post_tr_action', array (\n\t\t\t\t$this,\n\t\t\t\t'prefix_admin_tr_action' \n\t\t) );\n\t\t\n\t\t// check if plugin tables exist\n\t\t$this->table_check ();\n\t\t\n\t\t// instantiate the render class for shortcodes to work\n\t\t$shortcodes = new Top_Ratter_Render ();\n\t}", "function tap_run_page_handler() \n {\n include(\"/var/www/html/run/tap_run.php\");\n \n $params = cargaArray('Torneo Argentino de Programación', $form, '');\n \n include('body.php'); \n }", "function run() {\r\n $this->view->data=$this->model->run();\r\n }", "function custom_construction() {\r\n\t\r\n\t\r\n\t}", "public function run()\n {\n \\App\\Model\\TemplateLib::create([\n 'name' => 'FNK Test',\n 'stylesheet' => 'body {background:white};',\n 'javascript' => '',\n 'code_header' => $this->codeHeader,\n 'code_footer' => $this->codeFooter,\n 'code_index' => $this->codeIndex,\n 'code_search' => '<h1>saya di search</h1>',\n 'code_category' => '<h1>saya di category</h1>',\n 'code_page' => $this->codePage,\n 'code_post' => $this->codePost,\n 'code_about' => '<h1>saya di about</h1>',\n 'code_404' => '<h1>saya di 404</h1>',\n ]);\n }", "public function helper()\n\t{\n\t\n\t}", "public function drawContent()\n\t\t{\n\t\t}" ]
[ "0.60586566", "0.59289104", "0.5919654", "0.5899511", "0.5838488", "0.5838488", "0.58356965", "0.5814271", "0.5814271", "0.57796824", "0.5701954", "0.5700516", "0.5685669", "0.5684617", "0.5684617", "0.5684617", "0.5639208", "0.563027", "0.56278986", "0.56231225", "0.5620407", "0.56068903", "0.56068903", "0.56068903", "0.56016845", "0.5597219", "0.5595339", "0.5591545", "0.558057", "0.55636305", "0.55034596", "0.5487096", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.5477182", "0.54594034", "0.5446425", "0.5446197", "0.54451364", "0.54319674", "0.5426377", "0.54072845", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.5401934", "0.53981763", "0.5394762", "0.5392594", "0.5392164", "0.5391672", "0.5391672", "0.5391672", "0.5386191", "0.53823715", "0.5374112", "0.5373851", "0.5371084", "0.5369742", "0.53666246", "0.5365522", "0.5358571", "0.53542304", "0.5353158", "0.5345768", "0.5339915", "0.53389114", "0.53339213", "0.5332912", "0.5323722", "0.5323722", "0.5321411", "0.5318719", "0.53184503", "0.5300535", "0.5290181", "0.52723837", "0.52723306" ]
0.0
-1
Call the Model constructor
function __construct() { parent::__construct(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct()\n {\n $this ->model = $this ->makeModel($this ->model());\n }", "function __construct () {\n\t\t$this->_model = new Model();\n\t}", "function __construct()\n {\n // 呼叫模型(Model)的建構函數\n parent::__construct();\n \n }", "function __construc()\r\n\t{\r\n\t\tparent::Model();\r\n\t}", "function __construct()\r\n {\r\n parent::Model();\r\n }", "function __construct() {\r\n parent::Model();\r\n }", "function __construct() {\n // Call the Model constructor \n parent::__construct();\n }", "public function __construct() {\n // Call the Model constructor\n parent::__construct();\n }", "private function __construct($model)\r\n {\r\n\r\n }", "function __construct()\n {\n // Call the Model constructor\n parent::__construct();\n }", "function __construct()\n {\n // Call the Model constructor\n parent::__construct();\n }", "function __construct()\n {\n // Call the Model constructor\n parent::__construct();\n }", "function __construct()\n {\n // Call the Model constructor\n parent::__construct();\n }", "function __construct()\n {\n parent::Model();\n }", "function __construct(){\n\t\tparent::__construct();\n\t\t\t$this->set_model();\n\t}", "public function __construct()\n\t{\n\t\tif (!$this->model_name)\n\t\t{\n\t\t\t$this->model_name = str_replace('Model_', '', get_class($this));\n\t\t}\n\t\t$this->model_name = strtolower($this->model_name);\n\t\t\n\t\t$this->_initialize_db();\n\t}", "public function __construct()\n {\n parent::Model();\n\n }", "function __construct()\n\t\t{\n\t\t\t// Call the Model constructor\n\t\t\tparent::__construct();\n\t\t $this->load->database();\t\n\t\t}", "public function __construct()\n {\n // All of my models are like this\n parent::__construct(get_class($this));\n // Calling methods to get the relevant data\n $this->generateNewsData();\n $this->generateAnalyticsData();\n $this->generatePostsData();\n }", "public function __construct(){\n\t\tparent::__construct();\n\t\t$this->load->model('Model');\n\t}", "public function __construct(){\n\t\tparent::__construct();\n\t\t$this->load->model('Model');\n\t}", "public function __construct () {\n $this->model = 'App\\\\' . $this->model;\n $this->model = new $this->model();\n\n // Get the column listing for a given table\n $this->table_columns = Schema::getColumnListing( $this->table );\n }", "public function __construct()\n\t{\n\t\t// \\ladybug_dump($model);\n\t}", "function __construct () {\n\n\t\techo 'I am in Model';\n\n\t}", "public function __construct() {\n $this->openConnection();\n $this->model();\n }", "public function __construct()\n {\n $this->model = app()->make($this->model());\n }", "function __construct()\n {\n $this->openDatabaseConnection();\n $this->loadModel();\n }", "public function __construct(Model $model) {\n parent::__construct($model);\n \n }", "public function __construct()\n {\n $this->model = new BaseModel;\n }", "public function __construct()\n {\n parent::__construct();\n //自动加载相对应的数据模型\n if ($this->auto_load_model) {\n $model_name = $this->model_name ? $this->model_name . '_model' : $this->router->fetch_class() . '_model';\n $this->load->model($model_name, 'model');\n }\n $this->_set_user();\n $this->_check_resource();\n }", "public function __construct(){\n\t\tinclude_once(\"model/crews_model.php\");\n\t\t$this->model = new crews_model();\n\t}", "public function __construct($model) \n {\n parent::__construct($model);\n }", "public function __construct($initModel = true) {\n if ($initModel)\n $this->model = new Model();\n }", "public function __construct() {\n\t\tparent::__construct();\n\t\t$this->load->model('data');\n\t}", "public function __construct() {\n $this->porcentajesCursoModel = $this->model('PorcentajesCursoModel');\n $this->tipoModuloModel = $this->model('TipoModuloModel');\n $this->cursoModel = $this->model('CursoModel');\n }", "public function __construct() {\n $this->docenteModel = $this->model('DocenteModel');\n }", "function __construct(Model $model)\n {\n $this->model=$model;\n }", "public function __construct() {\n // load our model\n $this->userModel = $this->model('User'); // will check models folder for User.php\n }", "public function __construct($model)\n {\n //\n $this->model = $model;\n }", "public function __construct() {\n\t\t$this->orgModel = new OrgModel(); // TODO: \n\t }", "public function __construct()\n {\n\n $this->SubCategory = new SubCategoriesModel;\n $this->Functions = new ModelFunctions();\n }", "function __construct() {\n parent::__construct();\n $this->load->model('Callcenter_model');\n }", "public function __construct() {\n // und lädt das zugehörige Model\n $this->userModel = $this->model('User');\n }", "function __construct()\n {\n parent::__construct();\n $this->__resTraitConstruct();\n $this->load->model('VSMModel');\n $this->load->model('TextPreprocessingModel');\n\n }", "public function __CONSTRUCT(){\n $this->model = new Estadobien();\n }", "public function __construct()\r\n\t{\r\n\tparent::__construct();\r\n\t\r\n\t//load database libray manually\r\n\t$this->load->database();\r\n\t\r\n\t//load Model\r\n\t$this->load->model('Hello_Model');\r\n\t}", "function __construct() {\n\t\t$this->cotizacionModel = new cotizacionModel();\n\t}", "protected function _construct()\n {\n $this->_init(Model::class, ResourceModel::class);\n }", "public function __construct() {\n parent::__construct('md_rent_car', 'md_order');\n $this->log->log_debug('RentCarAffairModel model be initialized');\n }", "function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct()\n {\n $this->modelName = explode('.', Route::currentRouteName())[0];\n $this->model = new Model($this->modelName);\n }", "public function __construct( Model $model ) {\n\t\t$this->model = $model;\n\t}", "public function __construct () {\n\t\tparent::__construct ();\n\t\t\n\t\tif ($this->models)\n\t\tforeach ($this->models as $model) {\n\t\t\tunset ($this->models[$model]);\n\t\t\t$this->models[$model] = $this->session->getModel ($model,$this);\n\t\t\t$this->$model = $this->models[$model];\n\t\t}\n\t}", "public function __construct()\n {\n \t parent::__construct();\n \t $this->load->model('Modelo');\n }", "function\t__construct()\t{\n\t\t\t\t/* contrutor da classe pai */\n\t\t\t\tparent::__construct();\n\t\t\t\t/* abaixo deverão ser carregados helpers, libraries e models utilizados\n\t\t\t\t\t por este model */\n\t\t}", "function __construct()\n {\n parent::__construct();\n\n\t\t$this->load->model('floatplan_model');\n\t\t$this->load->model('user_model');\n }", "public function __construct() {\r\n $this->model = new CompanyModel();\r\n }", "public function __construct($model){\r\n\t\t$this->model = $model;\r\n\t}", "public function __construct()\n {\n $this->MemberModel = new MemberModel();\n }", "public function __construct()\n\t{\n\t\t$this->modelProducts = new ProductsModel();\n\t\t/* ********** fin initialisation Model ********** */\n\t}", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->load->model('LeBabeModel');\n\t}", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->load->model('LeBabeModel');\n\t}", "public function __construct()\n {\n parent::__construct();\n\n $this->model = new MembersModel();\n }", "public function __construct() {\n $this->load = new Load();\n $this->model = new Model();\n }", "public function __construct()\n {\n echo \"constructeur model\";\n }", "function __construct()\n {\n $this->view = new View();\n $this->model = new si_cf_parametroModel();\n }", "public function __construct()\n\t\t{\n\t\t\t/*goi thang den ham _init trong ResourceModel*/\n\t\t\tparent::_init('lienhe', 'id', new ContactModel);\n\t\t}", "public function __construct()\n {\n parent::__construct();\n\n\t\t$this->load->model(\"options_model\");\n\t\t$this->load->model(\"selections_model\");\n\t\t$this->load->model(\"info_model\");\n\t\t$this->load->model(\"dealer_model\");\n\t\t$this->load->library(\"encrypt\");\n\t\t$this->load->model(\"promocode_model\");\n\t}", "public function __construct()\n {\n parent::__construct();\n $this->load->model(['m_voting', 'm_master', 'm_prospects', 'm_factors']);\n }", "public function __construct() {\n parent::__construct();\n $this->load->model('Thematic_model');\n }", "function __construct() {\n $this->model = new HomeModel();\n }", "public function __construct() {\n\n parent::__construct();\n\n // Load models\n $this->load->model(\"attributesModel\", \"attributes\");\n\n }", "public function __construct()\n\t{\n\t\t//MVC: makes CodeIgniter style $this->load->model() available to my controllers\n\t\t$this->load = new modelLoader($this);\n\t}", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "public function __construct($model)\n {\n $this->model = $model;\n }", "function __construct()\n\t{\n\t\tparent :: __construct();\n\t\t$this -> load -> model('getinfo','m');\n\t}", "function __construct() {\n $this->loteModel = new loteModel();\n }", "public function __construct() {\n parent::__construct();\n $this->load->model(array('dt_diag_klsf_model','dt_obat_model','dt_pasien_model','dt_pemeriksaan_model','dt_proses_model','dt_thpan_model'));\n }", "function __construct()\n\t{\n\t\t// this->model = new Producto();\n\t}", "public function __construct()\n {\n // Call the CI_Model constructor\n parent::__construct();\n }", "public function __construct()\n {\n // Call the CI_Model constructor\n parent::__construct();\n }", "public function __construct() {\n\t\t$this->empleadoModel = $this->model('Empleado');\n\t}", "public function __construct()\r\n\t{\r\n\t\tparent::__construct();\r\n\t\t\r\n\t\t$this->load->model(array('user_model','program_model'));\r\n\t\t\r\n\t}", "public function __construct(Model $model)\n {\n // $this->$key = $model;\n $this->model = $model;\n }", "function __construct()\n {\n // load model\n Load::loadModel(\"helpDesk\");\n }", "public function __construct()\n\t{\n\t\t$this->model = new Layout_Model();\n\t}", "public function __construct(){\n $this->sliderModel = $this->model('Slider');\n $this->siteInfoModel = $this->model('SiteInfo');\n $this->officeModel = $this->model('Office');\n $this->categoryModel = $this->model('Category');\n $this->brandModel = $this->model('Brands');\n $this->productModel = $this->model('Products');\n $this->imgModel = $this->model('Image');\n }", "function __construct()\n {\n parent::__construct();\n // $this->load->model('');\n }", "public function __construct() {\r\n parent::__construct();\r\n $this->load->model(array(\r\n 'app_model'\r\n ));\r\n }", "function __construct(){\n\t\t\t$this->model = new model(); //variabel model merupakan objek baru yang dibuat dari class model\n\t\t\t$this->model->table=\"tb_dosen\";\n\t\t}", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->load->model('TimeTable_model', 'tmtl');\n\t\t$this->load->model('Schools_model', 'schl');\n\t}", "public function __construct() {\n\t\t\t$this->modelName = 'concreeeeeete';\n\t\t}", "public function __construct($model = null)\n {\n $instance = $this->makeModel($model);\n parent::__construct($instance->getConnection()->query());\n $this->setModel($instance);\n }", "function __construct() {\n parent::__construct();\n $this->load->model('Fontend_model');\n $this->load->model('Package_model');\n }" ]
[ "0.8196736", "0.8080118", "0.8054001", "0.7839992", "0.78184336", "0.78158236", "0.7770901", "0.773286", "0.7704549", "0.7701882", "0.7701882", "0.7701882", "0.7701882", "0.76811564", "0.76426494", "0.75779855", "0.75710344", "0.75621206", "0.7518676", "0.75171185", "0.75171185", "0.7511973", "0.7489728", "0.7468261", "0.74572253", "0.7449389", "0.7445181", "0.7444535", "0.7427869", "0.7407304", "0.74014014", "0.73759925", "0.73413444", "0.7335981", "0.73260605", "0.7277932", "0.7272845", "0.72707343", "0.7265125", "0.7254405", "0.7252804", "0.72438663", "0.7242104", "0.7241692", "0.7240256", "0.7231797", "0.7230043", "0.72287345", "0.7228103", "0.722678", "0.72072005", "0.71945196", "0.7175319", "0.716174", "0.71547157", "0.7150238", "0.7140722", "0.71377164", "0.71358", "0.7132933", "0.7132409", "0.7132409", "0.71250975", "0.71239203", "0.71029484", "0.7092826", "0.70837456", "0.7072703", "0.70563996", "0.7049204", "0.70491046", "0.7045107", "0.70382833", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7036996", "0.7033529", "0.7029588", "0.7026682", "0.70233345", "0.70195305", "0.70195305", "0.7018619", "0.7012934", "0.7012402", "0.7007989", "0.70067614", "0.7005785", "0.7004497", "0.6996979", "0.69894654", "0.6989313", "0.6972264", "0.6970196", "0.6969221" ]
0.0
-1
is developer in database?
function isDeveloperInDB($GBID) { $query = $this->db->get_where('developers', array('GBID' => $GBID)); return $query->num_rows() > 0 ? true : false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract function is_developer();", "public function hasdeveloper()\n {\n return $this->hasuser() && $this->user()->isdeveloper();\n }", "public function is_developer() {\n\t\treturn $this->user->exists() && in_array(self::DEVELOPER_ROLE_NAME, $this->user->roles);\n\t}", "public function isDeveloper()\r\n\t{\r\n\t\t\treturn count($this->getDeveloperProfiles()) > 0;\r\n\t}", "public function dbIsInstalled();", "public function isDbSet(): bool\n {\n return (bool)$this->db;\n }", "public function checkDatabaseStructure( );", "private function canUseDatabase()\n {\n return $this->deploymentConfig->get('db');\n }", "public function isInDB() {\n\t\t$db = Loader::db();\n\t\treturn (boolean) $db->getOne('select count(*) from '.$this->btTable.' where bID = ?', array($this->bID));\n\t}", "public function hasDatabase($name);", "public function isDatabase(): bool {\n\t\treturn $this->_database;\n\t}", "public function is_active_record_enabled();", "protected function isDbalEnabled() {}", "protected function isDbalEnabled() {}", "protected function isDbalEnabled() {}", "protected function isDbalEnabled() {}", "public function hasSql(){\n return $this->_has(1);\n }", "public function isDev(): bool;", "public function hasAdministrativeDatabases() {\n return $this->_has(9);\n }", "function checkIntegrityDb()\r\n\t{\r\n\t\treturn true;\r\n\t}", "abstract public function hasDatabase(BaseConnectionInfo $connInfo);", "public function isDatabaseRequired()\n {\n return $this->isSomethingRequired(array(\n 'full_backup', 'database'\n ));\n }", "function isPrimaryKey(): bool;", "private function isExternalDatabase()\n {\n if ($this->isExternalDb) {\n return true;\n }\n\n if (!empty($this->clone->databaseUser)) {\n return true;\n }\n return false;\n }", "function detectdb() {\r\n\t\t\t$names = array();\r\n\t\t\t$this->db->Halt_On_Error = 'no';\r\n\t\t\t$tables = $this->db->table_names();\r\n\t\t\t\r\n\t\t\tforeach ($tables as $tab_info) {\r\n\t\t\t\t$names[] = $tab_info['table_name'];\r\n\t\t\t}\r\n\t\t\tif(is_array($names) && in_array('s3db_account', $names)) {\r\n\t\t\t\treturn True;\r\n\t\t\t} else {\r\n\t\t\t\treturn False;\r\n\t\t\t}\r\n\t\t}", "public function check_db()\n {\n $test = $this->connection->query('SELECT COUNT(*) FROM ' . $this->connection->get_table_prefix() . 'users', null, null, true);\n return !is_null($test);\n }", "public function isFromVendor(): bool;", "private function databaseExists()\n {\n try {\n if (is_numeric(Bookmark::count()) && is_numeric(Tag::count())) {\n return true;\n }\n } catch (Exception $e) {\n return false;\n }\n\n return false;\n }", "public static function isInstalled(){\n\t\treturn !empty(\\GO::config()->db_user);\n\t}", "public function is_main_query()\n {\n }", "public function is_development_environment()\n {\n }", "final protected function is_con()\r\n\t{\r\n\t\tif (isset($this->con)) {\r\n\t\t\tif ($this->is_user($this->con))\r\n\t\t\t\treturn TRUE;\r\n\t\t}\r\n\t\treturn FALSE;\r\n\t}", "function registerToDatabase() {\n\t\t\tif ($this->id != null && $this->id != 0) return false;\n\n\t\t\t$this->conn = connectToDb(\"db_avalanche_store\");\n\n\t\t\t$add_query = \"INSERT INTO tbl_dev_info \n\t\t\t(user_id, \n\t\t\t dev_name,\t\n\t\t\t dev_desc) \n\t\t\tVALUES \n\t\t\t('$this->dev_id', \n\t\t\t '$this->dev_name',\t\n\t\t\t '$this->dev_description');\";\n\n\t\t\t$result = $this->conn->query($add_query);\n\n\t\t\t$this->conn->close();\n\n\t\t\tif (!$result) return false;\n\n\t\t\treturn true;\n\t\t}", "public function existsInDb($dh) {\n $info = $this->getDbInfo($dh);\n return isset($info[\"user\"]);\n }", "public function canManageOwnDevelopments();", "function userCanSetDbPassword(){\r\n\t\treturn $this->getAccessLevel() > 9;\r\n\t}", "public function hasStatement();", "public function isExpert(): bool\n {\n return (bool) $this->_getEntity()->isExpert();\n }", "public function isDev()\n {\n return ($this->_environment === 'development');\n }", "public function canManageDevelopments();", "public function refersToTable(): bool;", "function _isitindb ($sql)\n {\n // Connect to the database\n _dbconnect();\n $result = mysql_query($sql);\n $num_rows = mysql_num_rows($result);\n if ($num_rows > 0) {\n return true; } else {\n return false;\n }\n \n }", "private function check_db() {\n if (ee()->db->table_exists($this->table_name)) {\n return true;\n }\n return $this->make_db();\n }", "function userCanQueryDatabase( $sessionID ) {\r\n\t\treturn FALSE;\r\n\t}", "public function isProduction();", "public function isPersisted() {}", "function _check_product_in_db($product){\n if (in_array($product, $this->db)){\n // echo 'Product already in the database.';\n return True;\n }\n // echo 'Product not in the database.';\n return False;\n }", "public function isPdo();", "public function GetisOwnerThisRecord(){\n return ($this->{$this->nameFieldUserId}==h::userId());\n}", "public function isDeveloperMode()\n {\n $mode = 'default';\n if (isset($this->server[State::PARAM_MODE])) {\n $mode = $this->server[State::PARAM_MODE];\n } else {\n $deploymentConfig = $this->getObjectManager()->get(DeploymentConfig::class);\n $configMode = $deploymentConfig->get(State::PARAM_MODE);\n if ($configMode) {\n $mode = $configMode;\n }\n }\n\n return $mode == State::MODE_DEVELOPER;\n }", "private function connected() {\n $connection = config('database.connections.tenant');\n return\n $connection['database'] == $this->db_name;\n }", "public function isDevelopment() {}", "public function isPersisted();", "public function isPersisted();", "public function isPersisted();", "public function isAdminInitialised()\n { \n $qb = $this->adminRepo->createQueryBuilder('a')\n ->select('a.id')\n ->setMaxResults(1)\n ->getQuery();\n $admin = $qb->getResult();\n\n if(!empty($admin)){\n return true;\n }else{\n return false;\n } \n }", "function user_can_added_to_DB_and_name_check() {\n $user = factory(User::class)->create();\n\n $this->assertEquals( !0, User::all()->count() );\n $this->seeInDatabase('users', ['name' => $user->name]);\n }", "private function isInsertQuery()\n\t{\n\t\treturn $this->insert_table != null;\n\t}", "public function hasDataAccessCommitteeMember() {\n return $this->_has(6);\n }", "public function access() {\n if ( ! isset($GLOBALS['TYPO3_CONF_VARS']['DB']['Connections']['Default']['dbname']) ) {\n return false;\n }\n return true;\n }", "public static function is_development()\n {\n return Kohana::$environment == Kohana::DEVELOPMENT;\n }", "public function isAutoCommit():bool;", "public function testCheckIfEmailIdUsed(){\r\n $db = new database;\r\n $db->connectToDatabase();\r\n $this->assertEquals(true,$db->checkIfEmailIdUsed(\"[email protected]\"));\r\n }", "public function exist(): bool { // 返回是否已经在数据库中存在\n return $this->InformationValid;\n }", "public static function isSystemDbInfoPG(){\n return (\\SYSTEM\\CONFIG\\config::get(\\SYSTEM\\CONFIG\\config_ids::SYS_CONFIG_DB_TYPE) == \\SYSTEM\\CONFIG\\config_ids::SYS_CONFIG_DB_TYPE_PG);}", "function is_dev(){\n return ENVIRONMENT == 'development';\n}", "function isEnrolled($columnId, $userId)\n {\n \t$this->db->where('planningKolomId', $columnId);\n \t$this->db->where('gebruikerId', $userId);\n\n \t$result = $this->db->get('aanwezigheid')->row();\n \n \treturn (isset($result) ? true : false);\n }", "public function isCreate(){\n\t\treturn isset($this->{$this->getPrimaryKey()}) ? false : true;\n\t}", "public function isProduction() {}", "function userCanSetDbName(){\r\n\t\treturn $this->getAccessLevel() > 9;\r\n\t}", "function _is_development_mode() {\n\t\treturn IMFORZA_Utils::is_development_mode();\n\t}", "public function getDatabaseInfo();", "public function does_database_have_data() {\n\t\tglobal $wpdb;\n\n\t\t$tableprefix = $wpdb->prefix;\n\t\t$simple_history_table = self::DBTABLE;\n\n\t\t$sql_data_exists = \"SELECT id AS id_exists FROM {$tableprefix}{$simple_history_table} LIMIT 1\";\n\t\t// phpcs:ignore WordPress.DB.PreparedSQL.NotPrepared\n\t\t$data_exists = (bool) $wpdb->get_var( $sql_data_exists, 0 );\n\n\t\treturn $data_exists;\n\t}", "public function hasSql(): bool\n {\n return isset($this->sql);\n }", "public function filterCheckDb()\n {\n App::$Database->addConnection($this->db, 'install');\n\n try {\n App::$Database->getConnection('install')->getDatabaseName();\n } catch (\\Exception $e) {\n return false;\n }\n\n return true;\n }", "function exist($name, $db) {\n $resultSet = $db -> query(\"SELECT * from Pokedex WHERE name = '$name'\");\n $count = $resultSet->rowCount();\n return (!$count == 0);\n }", "public function isInTransaction(): bool;", "final protected function is_db($user, $db)\r\n\t{\r\n\t\tif (is_dir(\"{$this->dir}$user/$db\"))\r\n\t\t\treturn TRUE;\r\n\t\treturn FALSE;\r\n\t}", "public function test_compare_database()\n {\n $responseProfie = $this->jsonUser('GET', 'api/users/info',[], []);\n $data = json_decode($responseProfie->getContent())->result;\n $arrayUser = [\n 'id' => $data->id,\n 'username' => $data->username,\n 'email' => $data->email\n ];\n $this->assertDatabaseHas('users', $arrayUser);\n }", "protected function isDatabaseReady()\n {\n // Such as during setup of testsession prior to DB connection.\n if (!DB::is_active()) {\n return false;\n }\n\n // If we have a DB of the wrong type then complain\n if (!(DB::get_conn() instanceof MySQLDatabase)) {\n throw new Exception('HybridSessions\\Store\\DatabaseStore currently only works with MySQL databases');\n }\n\n // Prevent freakout during dev/build\n return ClassInfo::hasTable('HybridSessionDataObject');\n }", "public function isMan()\n {\n $res = $this->getEntity()->isMan();\n\t\tif($res === null)\n\t\t{\n\t\t\tSDIS62_Model_DAO_Abstract::getInstance($this::$type_objet)->create($this);\n\t\t\treturn $this->getEntity()->isMan();\n\t\t}\n return $res;\n }", "public function isInscrit(){\r\n $retour = false ;\r\n $pseudo = $this -> getPseudo();\r\n\tif(!empty($pseudo)){\r\n\t$q = \"select User_inscrit as i from UserTab where User_pseudo = '\".$pseudo.\"'\";\r\n\t$res = execute($q) ;\r\n\t\twhile($l = mysql_fetch_assoc($res)){\r\n\t\t if($l['i'] == 1) $retour = true ;\r\n\t\t}\r\n\t}\r\n \r\n return $retour ;\r\n\r\n }", "public function isLogged(){\r\n return isset($_SESSION['dbauth']);\r\n }", "public function isDeveloperMode()\n {\n if (null === $this->_isDeveloperMode) {\n $this->_isDeveloperMode = (bool)$this->scopeConfig->getValue(self::XML_IS_DEVELOPER, \\Magento\\Store\\Model\\ScopeInterface::SCOPE_STORE);\n }\n return $this->_isDeveloperMode;\n }", "function db_check() {\n\t\tif(!is_admin() || !$this->db_option || !$this->db_version || !$this->table_schema) return false;\n\t\tglobal $wpdb;\n\t\t$current_db_version = get_option($this->db_option);\n\t\tif($this->db_version != $current_db_version) {\n\t\t\t$this->db_install_options();\n\t\t\t$this->db_install($sql);\n\t\t}\n\t}", "function isTeamleiter() {\n \n $team = $this -> getTeamObject();\n if(!$team){\n return false;\n }\n \n \n $test_uid = $team -> getLeiter();\n if($test_uid == $this -> getUid()){\n return true;\n }\n else {\n return false; \n }\n }", "private function is_db_available(){\n \t$host = Configuration::DB_HOST;\n\t\t$dbname = Configuration::DB_NAME;\n\t\t$dbuser = Configuration::DB_USER;\n\t\t$dbpass = Configuration::DB_PASS;\n\t\t$con = null;\n\t\ttry{\n\t\t\t$con = new PDO(\"mysql:host=$host;dbname=$dbname\", $dbuser, $dbpass, array(PDO::ATTR_PERSISTENT => true));\n\t\t}\n\t\tcatch(PDOException $e){\n\t\t\treturn false;\n\t\t}\n\t\t$con = null;\n\t\treturn true;\n }", "function isDev(){ return $_ENV['CURRENT_ENVIRONMENT'] == ENVIRONMENT_DEV; }", "function v1_check_db_simple($name, $key, $code, $owners) {\n\t\n\tglobal $warnings;\n\t\n\t// If already in database, send a warning\n\t$id=v1_get_id($key, $code, $owners);\n\t\n\tif (!empty($id)) {\n\t\t// Warning: already in database\n\t\t$warning_msg=$name.\" code=\\\"\".$code.\"\\\"\";\n\t\t// 1st owner\n\t\tif (!empty($owners[0])) {\n\t\t\t$warning_msg.=\" owner1=\\\"\".$owners[0]['code'].\"\\\"\";\n\t\t}\n\t\t// 2nd owner\n\t\tif (!empty($owners[1])) {\n\t\t\t$warning_msg.=\" owner2=\\\"\".$owners[1]['code'].\"\\\"\";\n\t\t}\n\t\t// 3rd owner\n\t\tif (!empty($owners[2])) {\n\t\t\t$warning_msg.=\" owner3=\\\"\".$owners[2]['code'].\"\\\"\";\n\t\t}\n\t\tarray_push($warnings, $warning_msg);\n\t}\n\t\n}", "protected function printSqlCheck() {}", "function isSQL() {\n\t\treturn $this->flagSQL;\n\t}", "function exists() {\r\n\t\t$sql_inicio \t= \" select * from \".$this->table.\" where \";\r\n\t\t$sql_fim \t\t= \" \".($this->get($this->pk) ? \" and \".$this->pk.\" <> \".$this->get($this->pk) : \"\").\" limit 1 \";\r\n\t\t\r\n\t\t$sql \t= \"con_id = \".$this->get(\"con_id\").\" and exa_id = \".$this->get(\"exa_id\").\" \";\r\n\t\tif (mysql_num_rows(Db::sql($sql_inicio.$sql.$sql_fim))){\r\n\t\t\t$this->propertySetError (\"con_id\", \"Já existe no banco de dados.\");\r\n\t\t\t$this->propertySetError (\"exa_id\", \"Já existe no banco de dados.\");\r\n\t\t}\r\n\t}", "public function checkDbVersion()\n {\n if ( GALETTE_MODE === 'DEV' ) {\n Analog::log(\n 'Database version not checked in DEV mode.',\n Analog::INFO\n );\n return true;\n }\n try {\n $select = new \\Zend_Db_Select($this->db);\n $select->from(\n PREFIX_DB . 'database',\n array('version')\n )->limit(1);\n $sql = $select->__toString();\n $res = $select->query()->fetch();\n return $res->version === GALETTE_DB_VERSION;\n } catch ( \\Exception $e ) {\n Analog::log(\n 'Cannot check database version: ' . $e->getMessage(),\n Analog::ERROR\n );\n return false;\n }\n }", "function isOwner($table,$referenceKey,$userReferenceKey,$referenceId){\n\t// var_dump('select * from '.$table.' where '.$referenceKey.' =\"'.$referenceId.'\" and '.$userReferenceKey.'='.Auth::user()->id);\n\n \tif(Auth::check() && $table){\n \t\t$isOwner = \\DB::select('select * from '.$table.' where '.$referenceKey.' =\"'.$referenceId.'\" and '.$userReferenceKey.'='.Auth::user()->id);\n\n \t\t$result = (!empty($isOwner)) ? true :false;\n \t}\n \telse\n \t\t$result = false;\n\n\treturn $result;\n}", "private function checkOpenDB(){\r\n if($this->connected){\r\n return true;\r\n }\r\n \r\n //No database opened yet\r\n return false;\r\n }", "private static function check_db() {\n\t\tif (self::$db_installed) {\n\t\t\treturn true;\n\t\t}\n\n\t\tglobal $databases;\n\n\t\t$sth = Database::get()->prepare('SELECT table_name FROM information_schema.tables WHERE table_schema = :database AND table_name = :table');\n\n\t\t$sth->execute(array(\n\t\t\t':database' => $databases['default']['name'],\n\t\t\t':table' => 'brutal_variables',\n\t\t));\n\n\t\t$table = $sth->fetchObject();\n\n\t\tif ($table == false) {\n\t\t\t$query = '\n\t\t\t\tCREATE TABLE IF NOT EXISTS `brutal_variables` (\n\t\t\t\t\t`name` varchar(255) NOT NULL,\n\t\t\t\t\t`value` TEXT NOT NULL,\n\t\t\t\tPRIMARY KEY (`name`))\n\t\t\t';\n\n\t\t\tDatabase::get()->exec($query);\n\t\t}\n\n\t\tself::$db_installed = true;\n\n\t\treturn true;\n\t}", "public function pClassesInDatabase() {\n return get_option('klarnapclasses') ? true : false;\n }", "function radius_sql_exists($name)\n{\n $exists = false;\n global $environments;\n \n if(!array_key_exists($name, $environments)) return $exists;\n\n $id = $environments[$name]['_id'] . \"@miiicasa.com\";\n\n $dbconn = pg_connect(\"host=localhost port=5432 dbname=radius user=postgres\");\n $result = pg_query_params($dbconn, 'SELECT * FROM radcheck WHERE username = $1', array($id));\n if(pg_num_rows($result) > 0) $exists = true;\n \n pg_close($dbconn);\n\n return $exists;\n}", "function is_site_active()\n{\n\t$this->db->where('id_table',0);\n\t$query = $this->db->get('site');\n\t$row = $query->row();\n $active = $row->active;\n\tif ($active == 1)\n\t{\n\treturn TRUE;\n\t}\n\telse\n\t{\n\treturn FALSE;\n\t}\n}", "public function is_logged_user_in_db() \n {\n $conn = $this->conn;\n $login = $this->login;\n \n $params = array($login);\n $query = 'SELECT * FROM users WHERE login = ?';\n \n $rs = $conn->Execute($query, $params);\n \n if (!$rs) \n {\n Av_exception::write_log(Av_exception::DB_ERROR, $conn->ErrorMsg());\n \n return FALSE;\n }\n \n if (!$rs->EOF) \n {\n return TRUE;\n } \n }" ]
[ "0.69465625", "0.65979105", "0.6455591", "0.62925977", "0.62509894", "0.6183475", "0.6033371", "0.60050935", "0.60036093", "0.597374", "0.5920723", "0.58921164", "0.58865565", "0.5883972", "0.5883972", "0.5883972", "0.5860761", "0.5850598", "0.5814999", "0.5812071", "0.57938284", "0.57765937", "0.576684", "0.5741085", "0.56951535", "0.5664861", "0.56618106", "0.5640793", "0.5623025", "0.56037414", "0.5580054", "0.5576439", "0.55646366", "0.55608296", "0.55586815", "0.5539871", "0.5536874", "0.5533068", "0.5532441", "0.5530635", "0.55266", "0.55241495", "0.55219996", "0.5513142", "0.5504416", "0.5496875", "0.54925936", "0.54821706", "0.5479404", "0.5475289", "0.5473752", "0.54465604", "0.5440844", "0.5440844", "0.5440844", "0.54174036", "0.54106617", "0.5408837", "0.54048955", "0.54036045", "0.53989166", "0.5391798", "0.539083", "0.5386063", "0.5382048", "0.5378496", "0.537094", "0.53643835", "0.53624105", "0.5360014", "0.5350998", "0.5349784", "0.5345079", "0.5327166", "0.53179735", "0.5313915", "0.53065056", "0.5301859", "0.529502", "0.52909374", "0.52896833", "0.52864844", "0.52840686", "0.52839404", "0.5283377", "0.5280656", "0.5272284", "0.5270182", "0.52669644", "0.52637595", "0.5263496", "0.5257585", "0.52562505", "0.52437234", "0.52400947", "0.5238418", "0.5238175", "0.52373356", "0.5236257", "0.52329695" ]
0.61941445
5
get DeveloperID from GBID
function getDeveloperByGBID($GBID) { $query = $this->db->get_where('developers', array('GBID' => $GBID)); if($query->num_rows() == 1) { return $query->first_row(); } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getDeveloper_id()\n {\n return $this->developer_id;\n }", "public function getVendorId() {}", "function getDevId()\n {\n return $this->_props['DevId'];\n }", "public function getOGApplicationID();", "public function getDeveloperKey();", "function GET_APP_ID(){\n return \"7d0df388-f064-48eb-9092-27fbbf0a438e\";\n}", "public function getIosVendorId();", "public function getUserIdentifier(): string\n {\n return ($this->token ?? ($this->appkey ?? ''));\n }", "public function getGid()\n {\n return $this->Gid;\n }", "public function getGplusIdentifier()\n {\n return $this->_getIdentifier('gplus');\n }", "public function obtenerID();", "public function getUserGcmRegId() {\n $stmt = $this->conn->prepare(\"SELECT gcm_registration_id FROM app_users\");\n // $stmt->bind_param(\"s\", $api_key);\n $stmt->execute();\n $user_gcm = $stmt->get_result();\n $stmt->close();\n return $user_gcm;\n }", "public function getVendorId(): ?string;", "public function getDeveloperFromDatabase($GBID, $userID)\n {\n // get developer from db\n $this->db->select('developers.DeveloperID, developers.GBID, developers.GBLink, developers.Name, developers.Image, developers.ImageSmall, developers.Deck');\n $this->db->from('developers');\n\n if ($userID == null) {\n $userID = 0; // prevents joining on UserID causing an error\n }\n\n // $this->db->join('collections', 'collections.DeveloperID = developers.DeveloperID AND collections.UserID = ' . $userID, 'left');\n // $this->db->join('lists', 'collections.ListID = lists.ListID', 'left');\n\n $this->db->where('developers.GBID', $GBID);\n $query = $this->db->get();\n\n // if developer returned\n if ($query->num_rows() == 1) {\n $result = $query->first_row();\n\n $this->developerID = $result->DeveloperID;\n $this->GBID = $result->GBID;\n $this->GBLink = $result->GBLink;\n $this->name = $result->Name;\n $this->image = $result->Image;\n $this->imageSmall = $result->ImageSmall;\n $this->deck = $result->Deck;\n\n return true;\n }\n \n return false;\n }", "public function getPersonGuid();", "public function getUserIdentifier(): string\n {\n return (string)$this->key_hash;\n }", "public function getOGAdminID();", "public function getAuthIdentifier();", "function getVendorId($vendor_name)\n\t{\n\t\t global $log;\n $log->info(\"in getVendorId \".$vendor_name);\n\t\tglobal $adb;\n\t\tif($vendor_name != '')\n\t\t{\n\t\t\t$sql = \"select vendorid from ec_vendor where vendorname='\".$vendor_name.\"'\";\n\t\t\t$result = $adb->query($sql);\n\t\t\t$vendor_id = $adb->query_result($result,0,\"vendorid\");\n\t\t}\n\t\treturn $vendor_id;\n\t}", "public function getBillingProfileId();", "public function getUserIdentifier()\n {\n // that's why I am sending the id here\n return $this->id;\n }", "public function getID(): string {\n\t\treturn $this->appName;\n\t}", "public function get_gsaUid() {\n return $this->gsaUid;\n }", "public function getID()\n {\n return $this->billingId;\n }", "public function getGalleryProfileId(): string {\n\t\treturn ($this->galleryId);\n\t}", "public function getCgId()\n {\n return $this->cg_id;\n }", "public function getGaid();", "public function getOpenId()\n {\n }", "public function getGid()\n {\n $value = $this->get(self::GID);\n return $value === null ? (integer)$value : $value;\n }", "function GID($in_id, $in_db){\n\tglobal $knj_web;\n\t\n\tif ($knj_web[\"dbconn\"]){\n\t\treturn $knj_web[\"dbconn\"]->selectsingle($in_db, array($knj_web[\"col_id_name\"] => $in_id));\n\t}else{\n\t\t$sql = \"SELECT * FROM \" . $in_db . \" WHERE \" . $knj_web[\"col_id_name\"] . \" = '\" . sql($in_id) . \"' LIMIT 1\";\n\t\t$f_gid = mysql_query($sql) or die(\"MySQL-error: \" . mysql_error() . \"\\nSQL: \" . $sql);\n\t\t$d_gid = mysql_fetch_array($f_gid);\n\t}\n\t\n\treturn $d_gid;\n}", "public function getUserAccountPublicId();", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "public function getIdentifier() {}", "function getApplicationId(bool $requestSandboxAppId = TRUE) {\n if ($requestSandboxAppId) {\n return _SQ_SANDBOX_APP_ID;\n } else {\n return _SQ_APP_ID;\n }\n}", "public function getBusinessUnitID(): string;", "public function getUserIdentifier(): string\n\t{\n\t\treturn (string)$this->siret;\n\t}", "public function getGravityCustomerId()\n {\n return $this->getGravityHelper()->getApiUser();\n }", "function getDatabaseId();", "public function obtenerId() {}", "public function getUserid()\n {\n return $this->get(self::_USERID);\n }", "public function getUserid()\n {\n return $this->get(self::_USERID);\n }", "public function getUserid()\n {\n return $this->get(self::_USERID);\n }", "function getIdentifier();", "function getIdentifier();", "public function fetchProjectID(): string;", "public function getIdentifier(): string;", "public function getIdentifier(): string;", "public function getAuthIdentifierName(): string;", "function PKG_getPackageID($client,$package)\n{\n\tCHECK_FW(CC_clientname, $client, CC_package, $package);\n\t$sql = \"SELECT id FROM `clientjobs` WHERE client='$client' AND status='wait4acc' AND package='$package'\";\n\n\t$result = DB_query($sql); //FW ok\n\t$line = mysql_fetch_row($result);\n\treturn($line[0]);\n}", "function getID();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "public function getIdentifier();", "function getPackageKey() ;", "public function getAuthIdentifier()\n {\n \treturn $this->id;\n }", "public function getExtCustomerId();", "function PKG_getClientIDbyPackageID($id)\n{\n\treturn(CLIENT_getId(PKG_getClientbyPackageID($id)));\n}", "function user_id () {\r\n\t$info = user_info();\r\n\treturn (isset($info[0]) ? $info[0] : 0);\r\n}", "public function getIdentifier()\n {\n return $this->uid;\n }", "public function getDriverId($api_key) {\n $stmt = $this->conn->prepare(\"SELECT driver_id FROM driver WHERE api_key = ?\");\n $stmt->bind_param(\"s\", $api_key);\n if ($stmt->execute()) {\n $stmt->bind_result($driver_id);\n $stmt->fetch();\n // TODO\n // $user_id = $stmt->get_result()->fetch_assoc();\n $stmt->close();\n return $driver_id;\n } else {\n return NULL;\n }\n }", "public function getUseAppID() \n \t{\n \t\treturn $this->use_appid;\n \t}", "function get_short_id()\n {\n // E.g. 04622F2089E037A5 => 89E037A5\n return enigma_key::format_id($this->id);\n }", "public function getDeveloper($uuid)\n {\n }", "public function getGamerId()\n {\n $value = $this->get(self::GAMER_ID);\n return $value === null ? (integer)$value : $value;\n }", "abstract public function packageId(): string;", "public static function getHolderID();", "public function getAuthIdentifier()\n {\n return (string) $this->user['id'];\n }", "public function getDocid(): string\n {\n return $this->docid;\n }", "public function getLiveId() {}", "function getDeviceTokenForUser($db, $user) {\n $user = $db->prepare($user);\n $result = $db->query(\"SELECT `devicetoken` FROM `apns_devices` WHERE `username`='{$user}'\");\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if ($row != NULL) {\n return $row['devicetoken'];\n } else {\n return NULL;\n }\n}", "function getRegistrationID()\n { \n return $this->getValueByFieldName('registration_id');\n }", "public function getUserIdentifier(): string\n {\n return (string) $this->login;\n }", "function getIdentifier() ;", "function getIdentifier() ;", "function getIdentifier() ;", "public function getExternalId(): string\n {\n return $this->externalId;\n }", "public function getUsercode()\n {\n return $this->usercode;\n }", "public function getID() : string;", "function tep_get_prid($uprid) {\n $pieces = explode('{', $uprid);\n\n return $pieces[0];\n }", "public function getDataReleaseId(): string\n {\n return $this->dataReleaseId;\n }", "public function getAndroidId();", "function getDeviceToken($device_id){\r\n global $pdo;\r\n\t\t$select = $pdo->prepare(\"SELECT token FROM device_registry\r\n\t\t\tWHERE device_id = ?\");\r\n\t\t$select->execute(array($device_id));\r\n $row = $select->fetch(PDO::FETCH_ASSOC);\r\n\t\treturn $row['token'];\r\n\t}", "public function getID(): string {\n\t\treturn 'user_ldap';\n\t}", "public function getRgstUserId()\n {\n return $this->rgst_user_id;\n }", "private static function getAuthTokenUserId() {\n global $_iform_warehouse_override;\n if ($_iform_warehouse_override || !function_exists('hostsite_get_user_field')) {\n // If linking to a different warehouse, don't do user authentication as\n // it causes an infinite loop.\n return '';\n }\n else {\n $indiciaUserId = hostsite_get_user_field('indicia_user_id');\n // Include user ID if logged in.\n return $indiciaUserId ? \":$indiciaUserId\" : '';\n }\n }", "public function getRegistrantWrapperId() {\n $uuid = $this->registrant->uuid->first()->getValue();\n return $uuid['value'];\n }", "private function getMerchantID()\n\t{\n\t\t$sandbox = $this->params->get('sandbox',0);\n\t\tif($sandbox) {\n\t\t\treturn $this->params->get('sandbox_merchant','');\n\t\t} else {\n\t\t\treturn $this->params->get('merchant','');\n\t\t}\n\t}", "public function getPId();" ]
[ "0.7028161", "0.6661588", "0.6655852", "0.6622608", "0.6590504", "0.639485", "0.6279953", "0.61893755", "0.6178754", "0.6047877", "0.6044135", "0.60317296", "0.59945005", "0.59556115", "0.59418285", "0.59312385", "0.5926804", "0.5908018", "0.58972555", "0.58352613", "0.5821468", "0.58112067", "0.57784474", "0.5771811", "0.5748632", "0.5741648", "0.57324046", "0.5718231", "0.57099456", "0.57053775", "0.57008475", "0.5700292", "0.5700069", "0.5700069", "0.5700069", "0.5700069", "0.5700069", "0.56992805", "0.56992805", "0.5685037", "0.56688887", "0.56533164", "0.565149", "0.5635911", "0.5631698", "0.56313026", "0.56313026", "0.56313026", "0.5623367", "0.5623367", "0.56103176", "0.56049806", "0.56049806", "0.5602745", "0.55874276", "0.5575782", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.5574825", "0.55733925", "0.55695134", "0.5564559", "0.5563221", "0.55625314", "0.55451035", "0.55322075", "0.55314535", "0.5530116", "0.55236375", "0.54911566", "0.5484524", "0.5477931", "0.5469126", "0.5468626", "0.54639107", "0.54633904", "0.5458767", "0.5458409", "0.54549366", "0.54549366", "0.54536855", "0.54496396", "0.5447244", "0.54467875", "0.5445456", "0.54448116", "0.5441665", "0.54370224", "0.543635", "0.5430099", "0.54279584", "0.5423504", "0.54210323", "0.54154116" ]
0.6699714
1
returns developer if in db, or adds and returns it if it isn't
function getOrAddDeveloper($gbDeveloper) { // get developer from db $developer = $this->getDeveloperByGBID($gbDeveloper->id); // if developer isn't in db if($developer == null) { // developer was not found, get from Giant Bomb $this->load->model('GiantBomb'); $result = $this->GiantBomb->getMeta($gbDeveloper->id, "company"); // if developer was returned if ($result != null && $result->error == "OK" && $result->number_of_total_results > 0) { // add developer to database $this->addDeveloper($result->results); } else { // developer was not found return false; } // get developer from db $developer = $this->getDeveloperByGBID($gbDeveloper->id); } return $developer; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function addDeveloper($developer)\n {\n $data = array(\n 'GBID' => $developer->id,\n 'Name' => $developer->name,\n 'API_Detail' => $developer->api_detail_url,\n 'GBLink' => $developer->site_detail_url,\n 'Image' => is_object($developer->image) ? $developer->image->small_url : null,\n 'ImageSmall' => is_object($developer->image) ? $developer->image->icon_url : null,\n 'Deck' => $developer->deck\n );\n\n return $this->db->insert('developers', $data); \n }", "abstract function is_developer();", "public function hasdeveloper()\n {\n return $this->hasuser() && $this->user()->isdeveloper();\n }", "public function getDeveloper_id()\n {\n return $this->developer_id;\n }", "function getDeveloper() \n {\n return $this->_developer;\n }", "public function developer()\n {\n return $this->belongs_to('Developer');\n }", "function registerToDatabase() {\n\t\t\tif ($this->id != null && $this->id != 0) return false;\n\n\t\t\t$this->conn = connectToDb(\"db_avalanche_store\");\n\n\t\t\t$add_query = \"INSERT INTO tbl_dev_info \n\t\t\t(user_id, \n\t\t\t dev_name,\t\n\t\t\t dev_desc) \n\t\t\tVALUES \n\t\t\t('$this->dev_id', \n\t\t\t '$this->dev_name',\t\n\t\t\t '$this->dev_description');\";\n\n\t\t\t$result = $this->conn->query($add_query);\n\n\t\t\t$this->conn->close();\n\n\t\t\tif (!$result) return false;\n\n\t\t\treturn true;\n\t\t}", "function addToDatabase() {\n\t\tif ($this->id != null && $this->id != 0) return false;\n\n\t\t$db = getDb();\n\n\t\t$add_query = \"INSERT INTO user_table \n\t\t(user_name, \n\t\t user_password,\t\n\t\t isAdmin,\t\n\t\t user_first_name,\n\t\t user_last_name) \n\t\tVALUES \n\t\t('$this->username', \n\t\t '$this->password',\t\n\t\t '$this->isAdmin',\t\n\t\t '$this->firstName',\t\n\t\t '$this->lastName');\";\n\n\t\t$result = mysqli_query($db, $add_query);\n\n\t\tmysqli_close($db);\n\n\t\tif (!$result) return false;\n\n\t\treturn true;\n\n\t}", "public function getDeveloperFromDatabase($GBID, $userID)\n {\n // get developer from db\n $this->db->select('developers.DeveloperID, developers.GBID, developers.GBLink, developers.Name, developers.Image, developers.ImageSmall, developers.Deck');\n $this->db->from('developers');\n\n if ($userID == null) {\n $userID = 0; // prevents joining on UserID causing an error\n }\n\n // $this->db->join('collections', 'collections.DeveloperID = developers.DeveloperID AND collections.UserID = ' . $userID, 'left');\n // $this->db->join('lists', 'collections.ListID = lists.ListID', 'left');\n\n $this->db->where('developers.GBID', $GBID);\n $query = $this->db->get();\n\n // if developer returned\n if ($query->num_rows() == 1) {\n $result = $query->first_row();\n\n $this->developerID = $result->DeveloperID;\n $this->GBID = $result->GBID;\n $this->GBLink = $result->GBLink;\n $this->name = $result->Name;\n $this->image = $result->Image;\n $this->imageSmall = $result->ImageSmall;\n $this->deck = $result->Deck;\n\n return true;\n }\n \n return false;\n }", "function addMerchant($vars){\n\tglobal $db;\n\t//should do some kind of security checks to prevent duplicate entries...(not in scope)\n\t$id = $db->insert('merchants', $vars);\n\tif($id){\n\t\t//return id merchantid\n\t\treturn $id;\n\t}else{\n\t\treturn false;\n\t}\n\t\n}", "private function add_record_or_update_record() {\n\t\t\t$this->before_custom_save();\n\t\t\t$this->before_save();\n\t\t\tif($this->new_record) {\n\t\t\t\t$this->before_create();\n\t\t\t\t$result = $this->add_record();\n\t\t\t\t$this->after_create();\n\t\t\t} else {\n\t\t\t\t$this->before_update();\n\t\t\t\t$result = $this->update_record();\n\t\t\t\t$this->after_update();\n\t\t\t}\n\t\t\t$this->after_save();\n\n\t\t\t// init user custom cache\n\t\t\tif (is_array($this->cache)) {\n\t\t\t\t$this->rebuild_cache();\n\t\t\t}\n\n\t\t\tif($this->blob_fields) {\n\t\t\t\t$this->update_blob_fields();\n\t\t\t}\n\t\t\treturn $result;\n\t\t}", "public function is_developer() {\n\t\treturn $this->user->exists() && in_array(self::DEVELOPER_ROLE_NAME, $this->user->roles);\n\t}", "public function isDeveloper()\r\n\t{\r\n\t\t\treturn count($this->getDeveloperProfiles()) > 0;\r\n\t}", "public function hasUseradditem(){\n return $this->_has(24);\n }", "function getDeveloper($bugid, $patch, $revision = false)\n\t{\n\t\tif ($revision) {\n\t\t\treturn $this->_dbh->prepare('\n\t\t\t\tSELECT developer\n\t\t\t\tFROM bugdb_patchtracker\n\t\t\t\tWHERE bugdb_id = ? AND patch = ? AND revision = ?\n\t\t\t')->execute([$bugid, $patch, $revision])->fetchOne();\n\t\t}\n\t\treturn $this->_dbh->prepare('\n\t\t\tSELECT developer, revision\n\t\t\tFROM bugdb_patchtracker\n\t\t\tWHERE bugdb_id = ? AND patch = ? ORDER BY revision DESC\n\t\t')->execute([$bugid, $patch])->fetchAll(PDO::FETCH_ASSOC);\n\t}", "function sql_addCustomer($kunde){\r\n\t\t\r\n\t\tglobal $database;\r\n\t\t$id = $database->insert(\"kunden\", [\r\n\t\t\t\t\"name\" => $kunde\r\n\t\t]);\r\n\t\t\r\n\t\treturn $id;\r\n\t\t\r\n\t}", "function add_customer()\n\t{\n\t\t$table = \"customer\";\n\t\t$where = \"customer_email = '\".$this->input->post('user_email').\"'\";\n\t\t$items = \"customer_id\";\n\t\t$order = \"customer_id\";\n\t\t\n\t\t$result = $this->select_entries_where($table, $where, $items, $order);\n\t\t\n\t\tif(count($result) > 0)\n\t\t{\n\t\t\t$customer_id = $result[0]->customer_id;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$data = array(\n\t\t\t\t'customer_email'=>$this->input->post('user_email'),\n\t\t\t\t'customer_name'=>$this->input->post('seller_name'),\n\t\t\t\t'customer_phone'=>$this->input->post('user_phone')\n\t\t\t);\n\t\t\t\n\t\t\t$table = \"customer\";\n\t\t\t$customer_id = $this->insert($table, $data);\n\t\t}\n\t\t\n\t\treturn $customer_id;\n\t}", "function add_customer($params){\n $this->company_db->insert('tbl_customer', $params);\n return $this->company_db->insert_id();\n }", "function canAdd($user) {\n return $user->isPeopleManager();\n }", "function add_product($product){\n if($this->_check_product_in_db($product)){\n return False; // Product already in database\n }else{\n array_push($this->db, $product);\n return True;\n }\n }", "public function add( $name, $owner = 0 ) {\r\r\n global $wpdb;\r\r\n\r\r\n $this->refresh = true;\r\r\n $data = wd_asp()->options['asp_defaults'];\r\r\n $data['owner'] = intval($owner);\r\r\n\r\r\n if (\r\r\n $wpdb->query(\r\r\n \"INSERT INTO \" . wd_asp()->db->table('main') . \"\r\r\n (name, data) VALUES\r\r\n ('\" . esc_sql($name) . \"', '\" . wd_mysql_escape_mimic(json_encode($data)) . \"')\"\r\r\n ) !== false\r\r\n ) return $wpdb->insert_id;\r\r\n\r\r\n return false;\r\r\n }", "function v1_check_db_simple($name, $key, $code, $owners) {\n\t\n\tglobal $warnings;\n\t\n\t// If already in database, send a warning\n\t$id=v1_get_id($key, $code, $owners);\n\t\n\tif (!empty($id)) {\n\t\t// Warning: already in database\n\t\t$warning_msg=$name.\" code=\\\"\".$code.\"\\\"\";\n\t\t// 1st owner\n\t\tif (!empty($owners[0])) {\n\t\t\t$warning_msg.=\" owner1=\\\"\".$owners[0]['code'].\"\\\"\";\n\t\t}\n\t\t// 2nd owner\n\t\tif (!empty($owners[1])) {\n\t\t\t$warning_msg.=\" owner2=\\\"\".$owners[1]['code'].\"\\\"\";\n\t\t}\n\t\t// 3rd owner\n\t\tif (!empty($owners[2])) {\n\t\t\t$warning_msg.=\" owner3=\\\"\".$owners[2]['code'].\"\\\"\";\n\t\t}\n\t\tarray_push($warnings, $warning_msg);\n\t}\n\t\n}", "function add(){\n\t\t\tif(!is_super_admin_login())\n\t\t\t\treturn $this->vista->acceso_restringido();\n if(!empty($this->params['programa'])){\n TPrograma::add($this->params['programa']);\n }\n }", "function add_voucher_customer($data)\n\t{\n\t\t$this->db->insert('customer_voucher', $data);\n\t\t//return $this->db->insert_id(); // this is only for auto increment\n\t\treturn $this->db->affected_rows();\t\t\n\t}", "function isDeveloperInDB($GBID)\n {\n $query = $this->db->get_where('developers', array('GBID' => $GBID));\n\n return $query->num_rows() > 0 ? true : false;\n }", "function addC(){\n \t$re = new DbManager();\n \t$result = $re -> addColumn();\n \tif ($result == true){\n \t\techo 'colone bien ajouter ';\n \t}\n }", "function addUser($userInfo){\n $this->db->trans_start();\n $this->db->insert('Users', $userInfo);\n\n $insert_id = $this->db->insert_id();\n\n $this->db->trans_complete();\n\n return $insert_id;\n }", "function isAddable(){\n return VM_manager_here;\n }", "function addSignupUser($user) {\n\t$ret = false;\n\t// print_r($user);\n\t$sql = \"INSERT INTO customer (name, phone, position, company, shop) values (\".\n\t\t\"'$user->name', '$user->phone', '$user->position', '$user->company', '$user->shop')\";\n\tmysql_query($sql);\n\tif(mysql_insert_id()) {\n\t\t$ret = true;\n\t}\n\treturn $ret;\n}", "function updateExternalDB($user) {\r\n\t\t// Not doing anything here (yet?)\r\n\t\treturn true;\r\n\t}", "function updateExternalDB($user) {\n return true;\n }", "static function addClub($clubname,$managerName){\n\t\t$db = new DB();\n var_dump($clubname);\n var_dump($managerName);\n\t\t$clubNameAvailable = Club::clubnameExists($clubname);\n\t\t//var_dump($clubNameAvailable);echo \"<br>\";\n $m_id = $db->query(\"SELECT user_id FROM user WHERE username='$managerName' AND type='manager'\")->fetch(PDO::FETCH_ASSOC);\n //var_dump($m_id);echo \"<br>\";\n $manager_id = (int) $m_id[\"user_id\"];\n var_dump($manager_id);\n \tif($clubNameAvailable == FALSE) // if club name is not available then can add as the manager.\n $res = $db->queryIns(\"INSERT INTO club (manager_id,name) VALUES ($manager_id,'$clubname')\");\n var_dump($res); \n\t}", "function addItem2DB($data = null)\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $result = $_POST['itemInfo'];\n echo $this->user_model->add($result);\n }\n }", "public function save($isNewUser = false) {\n $db = new DB();\n\n //if the user is already registered and we're\n //just updating their info.\n if (!$isNewUser) {\n //set the data array\n $data = array(\n \"technology_id\" => \"'$this->technology_id'\",\n \"student_id\" => \"'$this->student_id'\",\n \"count\" => \"'$this->count'\"\n );\n\n //update the row in the database\n $db->update($data, 'endorsements', 'id = ' . $this->id);\n } else {\n //if the user is being registered for the first time.\n $data = array(\n \"technology_id\" => \"'$this->technology_id'\",\n \"student_id\" => \"'$this->student_id'\",\n \"count\" => \"'$this->count'\"\n );\n\n $this->id = $db->insert($data, 'endorsements');\n }\n return true;\n }", "public function GetisOwnerThisRecord(){\n return ($this->{$this->nameFieldUserId}==h::userId());\n}", "public function willGenerateAdd(): bool;", "public function addToDb()\n {\n\n // make sure this is a valid new entry\n if ($this->isValid()) {\n // check for duplicate\n $vals = sprintf(\"('%s',%d)\",$this->email,$this->level);\n $sql = \" insert into Admins values $vals\";\n Dbc::getReader()->Exec($sql);\n }\n else\n print \"<br> Invalid entry. STOP! ($sql)<br>\";\n }", "function add()\n {\n return true;\n }", "public function getDeveloper($uuid)\n {\n }", "public function addProfessional()\n {\n }", "function getDeveloperByGBID($GBID)\n {\n $query = $this->db->get_where('developers', array('GBID' => $GBID));\n\n if($query->num_rows() == 1)\n {\n return $query->first_row();\n }\n\n return null;\n }", "function firstdata_create_saved_profile($db,$customer_id,&$error)\n{\n return $customer_id;\n}", "function checkPlusForUser($user_id)\n{\n\tglobal $db;\n\t$check=0;\n\t$sql = \"SELECT build FROM wg_plus WHERE user_id=\".$user_id;\n\t$db->setQuery($sql);\n\t$check=strtotime($db->loadResult()) - strtotime(date(\"Y-m-d H:i:s\",time()));\n\tif($check>0)\n\t{\n\t\treturn true;\n\t}\n\treturn false;\t\n}", "public function add_payer_record($data){\n\t\t$this->db->insert('tat_finance_payers', $data);\n\t\tif ($this->db->affected_rows() > 0) {\n\t\t\treturn true;\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "public function add_owner() {\n $arrPageData['arrSessionData'] = $this->session->userdata;\n $ownerdata = array('owner_name' => trim($this->input->post('owner_name')),\n 'account_id' => $arrPageData['arrSessionData']['objSystemUser']->accountid,\n 'active' => 1,\n 'archive' => 1,\n 'location_id' => $this->input->post('location_id')\n );\n\n foreach ($ownerdata as $key => $value) {\n if ($value == '') {\n unset($ownerdata[$key]);\n }\n }\n\n\n if ($this->checkowner($ownerdata['owner_name'], $ownerdata['account_id']) == 0) {\n $this->db->insert('owner', $ownerdata);\n $id = $this->db->insert_id();\n }\n if ($id) {\n return $id;\n } else {\n return FALSE;\n }\n }", "function addMaintenance($data){\r\n\r\n $this->app->log->info(__CLASS__ . '::' . __METHOD__);\r\n // $this->app->log->info('software : '.$this->dumpRet($software));\r\n $dao = new \\PNORD\\Model\\SoftwareDAO($this->app); \r\n return $dao->addMaintenance($data); \r\n\r\n }", "public function add($data) {\r\n\t \tglobal $wpdb;\r\n\t \t\r\n\t \tif ($wpdb->insert( $this->table, (array) $data ))\r\n\t \t\t$return = $wpdb->insert_id;\r\n\t \telse\r\n\t \t\t$return = FALSE;\r\n\t \t\r\n\t \treturn $return;\r\n\t }", "function add_membre($data, $database = false) {\n if (!$database) {\n $database = get_database(); \n }\n if (isset($data[\"name\"], $data[\"password\"])) {\n $database[] = $data;\n change_database($database);\n }\n}", "public function createCustomer(): bool {\n $details = $this->createDetails();\n\n //check if the customer is existed\n $result = $this->getCustomer();\n if ($result->num_rows == 0) {\n $db = new Database();\n $result = $db->toTable($db->tableCustomer)->insertRow($details);\n return $result;\n }\n else {\n return false;\n }\n }", "function v1_check_db_species($name, $name_species, $key, $code, $type, $waterfree, $owners) {\n\t\n\tglobal $warnings;\n\t\n\t// If already in database, send a warning\n\t$id=v1_get_id_species($key, $code, $type, $waterfree, $owners);\n\t\n\tif (!empty($id)) {\n\t\t// Warning: already in database\n\t\t$warning_msg=$name.\" code=\\\"\".$code.\"\\\"\";\n\t\t// 1st owner\n\t\tif (!empty($owners[0])) {\n\t\t\t$warning_msg.=\" owner1=\\\"\".$owners[0]['code'].\"\\\"\";\n\t\t}\n\t\t// 2nd owner\n\t\tif (!empty($owners[1])) {\n\t\t\t$warning_msg.=\" owner2=\\\"\".$owners[1]['code'].\"\\\"\";\n\t\t}\n\t\t// 3rd owner\n\t\tif (!empty($owners[2])) {\n\t\t\t$warning_msg.=\" owner3=\\\"\".$owners[2]['code'].\"\\\"\";\n\t\t}\n\t\t$warning_msg.=\" with \".$name_species.\" type=\\\"\".$type.\"\\\"\";\n\t\tif (!empty($waterfree)) {\n\t\t\t$warning_msg.=\" waterfree=\\\"\".$waterfree.\"\\\"\";\n\t\t}\n\t\tarray_push($warnings, $warning_msg);\n\t}\n\t\n}", "public function save() {\r\n\t return isset($this->userid) ? $this->update() : $this->create();\r\n\t}", "public function isFromVendor(): bool;", "public function addUser($data) {\n\t\t$user = $this->findByUnique($data['name'], $data['email'], $data['mobile']);\n\t\tif (!isset($user)) {\n\t\t\t$user = $this->createRow($data);\n\t\t\t$user->save();\n\t\t}\n\t\treturn $user;\n\t}", "public function add($data) {\n if (isset($data['id_user'])) {\n $this->db->where('id_user', $data['id_user']);\n $this->db->update('user', $data);\n } else {\n $this->db->insert('user', $data);\n return $this->db->insert_id();\n }\n }", "function save()\n\t\t{\n\t\t\t// if name is found, return brand id#\n\t\t\t$brand_check = null;\n\t\t\t$brand_check = Brand::findByName($this->getName());\n\t\t\tif($brand_check == null){\n\t\t\t\t$GLOBALS['DB']->exec(\"INSERT INTO brands (name) VALUES ('{$this->getName()}');\");\n\t\t\t\t$this->id = $GLOBALS['DB']->lastInsertId();\n\t\t\t\treturn false;\n\t\t\t}else{\n\t\t\t\treturn $brand_check;\n\t\t\t}\n\t\t}", "function update() {\n\t\t\tif ($this->id == null || $this->id == 0) return false;\n\n\t\t\t$this->conn = connectToDb(\"db_avalanche_store\");\n\n\t\t\t$update_query = \"UPDATE tbl_dev_info SET\n\t\t\t dev_name = '$this->dev_name',\n\t\t\t dev_desc = '$this->dev_description' WHERE user_id = '$this->id';\";\n\n\t\t\t$result = $this->conn->query($update_query);\n\n\t\t\t$this->conn->close();\n\n\t\t\tif (!$result) return false;\n\n\t\t\treturn true;\n\n\t\t}", "function store()\n {\n $this->dbInit();\n query( \"INSERT INTO Grp set Name='$this->Name', Description='$this->Description',\n\tUserAdmin='$this->UserAdmin',\n\tUserGroupAdmin='$this->UserGroupAdmin',\n\tPersonTypeAdmin='$this->PersonTypeAdmin',\n\tCompanyTypeAdmin='$this->CompanyTypeAdmin',\n\tPhoneTypeAdmin='$this->PhoneTypeAdmin',\n\tAddressTypeAdmin='$this->AddressTypeAdmin'\" );\n return mysql_insert_id();\n }", "public function add($data) {\n\t\tif($this->db->insert($this->table, $data)){\n\t\t\tif($id = $this->db->insert_id())\n\t\t\t\treturn $id;\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "private function addCustomerOrVendor(\n bool $isCustomer,\n string $userID,\n string $name,\n string $address) {\n // Query the database to see if the user already has a customer/vendor\n // with the given name.\n $customerOrVendorAlreadyExistsResult =\n $this->runQuery(\n 'SELECT ID FROM BooksDB.' \n . ($isCustomer ? 'Customers' : 'Vendors')\n . ' WHERE (userID = ?) AND (name = ?)',\n 'ss',\n $userID,\n $name);\n\n // If DatabaseConnection::runQuery(string,string,...mixed) returns\n // FALSE, an error occurred, so throw an exception.\n if($customerOrVendorAlreadyExistsResult === FALSE)\n throw new DatabaseException(\n 'DatabaseConnection::runQuery(string,string,...mixed) failed.');\n\n // If the query result does not have exactly 0 contents, the user\n // already has a customer/vendor with the given name, so return FALSE.\n if(count($customerOrVendorAlreadyExistsResult) !== 0) return FALSE;\n\n // Insert the new customer/vendor into the database.\n $this->runQuery(\n 'INSERT INTO BooksDB.'\n . ($isCustomer ? 'Customers' : 'Vendors')\n . ' (userID, name, address) VALUES (?, ?, ?)',\n 'sss',\n $userID,\n $name,\n $address);\n\n // If we made it here, everything must have gone well, so return TRUE.\n // (It is possible the insertion was unsuccessful, but no exceptions\n // were thrown by it; worst case the customer/vendor was not actually\n // added to the database.)\n return TRUE;\n }", "public function addSubAdmindmin($post)\n\t{\n\t\t$this->db->insert('tbl_user', $post);\n\t\t$this->result = $this->db->insert_id() ; \n\t\treturn $this->result ;\n\t}", "function check_software_license_add()\n {\n $q = $this->db->where('license', $this->input->post('license_num'))->where('action_type', 'software add')->where('company_id', $this->session->userdata('company_id'))->limit(1)->get('software');\n\n if ($q->num_rows == 1)\n {\n return true;\n\n } else {\n\n return false;\n }\n }", "function insert_saved($data){\n\t\t\n\t\t$saved_info = $this->get_saved($data);\t\n\t\t$userid = $data['user_id'];\n\t\t$product_id = $data['product_id'];\n\t\tif(empty($saved_info)){\n\t\t$result= $this->db->query(\"INSERT INTO `tbl_saved_product`(`user_id`, `product_id`) VALUES ('$userid','$product_id')\");\n\n\t\t$res = 'added in saved product';\n\n\t\t}else{\n\n\t\t$res = 'already added in saved product';\n\t\t}\n\n\t\treturn $res;\t\t\t\n \n }", "public function getSeniorContributors()\n {\n $query=\"select identifier FROM \".$this->_name.\" WHERE profile_type ='senior' AND status = 'Active'\";\n if(($result = $this->getQuery($query,true)) != NULL)\n return $result;\n else\n return \"NO\";\n }", "function add_customer($params)\n {\n $this->db->insert('customer',$params);\n return $this->db->insert_id();\n }", "function add_customer($customer_info){\n\n\t if(check_token($customer_info['crf_code'],'check')){\n\t\tif(mysqli_result_(mysqli_query_(\"select count('customer_id') from customers where customer_id='\".sanitize($customer_info['customer_id']).\"'\"), 0) != '1'){\n\n \t\t\t\t$cust_id = mysqli_result_(mysqli_query_(\"select customer_id from customers where customer_name='\".sanitize($customer_info['customer_name']).\"' and mobile='\".sanitize($customer_info['mobile']).\"' LIMIT 1 \"), 0);\n\t\t\t\tif($cust_id && sanitize($customer_info['mobile']) !=''){ // if exist return id \n\t\t\t\t\treturn $cust_id;\n\t\t\t\t }else{ // create then return id not dublicate \n\n\t\t\t\t\t\tif(mysqli_result_(mysqli_query_(\"select count(customer_id) from customers where customer_name='\".sanitize($customer_info['customer_name']).\"' and customer_name!='' and mobile='' \"), 0) != '0' && sanitize($customer_info['mobile']) ==''){\n\t\t\t\t\t\t\tdie(\" <strong> write fullname or add mobile because this \".sanitize($customer_info['customer_name']).\" is already exist </strong>\");\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t \tmysqli_query_(\"insert into customers (customer_id,customer_name,mobile,delete_status) values('','\".sanitize($customer_info['customer_name']).\"','\".sanitize($customer_info['mobile']).\"','0')\");\n\t\t\t\t\t\t\treturn mysqli_result_(mysqli_query_(\"SELECT customer_id FROM customers ORDER BY customer_id DESC LIMIT 1\"),0);\n\t\t\t\t\t\t}\n\t\t\t\t }\n\n\t\t\t}else{\n\n\t\t\t\t$cust_name = (sanitize($customer_info['customer_name']) != '')?\"customer_name='\".sanitize($customer_info['customer_name']).\"', \":'';\n\t\t\t\tmysqli_query_(\"update customers set $cust_name mobile='\".sanitize($customer_info['mobile']).\"' where customer_id=\".sanitize($customer_info['customer_id']));\n\t\t\t\treturn sanitize($customer_info['customer_id']);\n\t\t\t}\n\t\t}else{\n \t\t\tdie('login'); \n\t\t}\n}", "public function add(){\r\n\t\t//$this->auth->set_access('add');\r\n\t\t//$this->auth->validate();\r\n\r\n\t\t//call save method\r\n\t\t$this->save();\r\n\t}", "function addHiringMgr($hiring_mgr_details)\n\t {\n\t\t if($this->db->insert('pof_hiring_mgr',$hiring_mgr_details))\n\t\t {\n\t\t return TRUE;\n\t\t }\n\t\t else{\n\t\t return FALSE;\n\t\t }\n\t\t}", "public function getDevelopers($GBID, $userID)\n {\n // check if developer is in database\n if ($this->isDeveloperInDB($GBID)) {\n // get developer from database\n if ($this->getDeveloperFromDatabase($GBID, $userID)) {\n // developer found\n return true;\n }\n }\n\n // developer was not found, get from Giant Bomb\n $this->load->model('GiantBomb');\n $result = $this->GiantBomb->getMeta($GBID, \"developer\");\n\n // if developer was returned\n if ($result != null && $result->error == \"OK\" && $result->number_of_total_results > 0) {\n // add developer to database\n $this->addDeveloper($result->results);\n\n // get developer from database\n return $this->getDeveloperFromDatabase($GBID, $userID);\n } else {\n // developer was not found\n return false;\n }\n }", "function admin_add($cname){\n $vdn = $this->vdn_imp_one($cname);\n if(!$this->user_exists($vdn)) return 9990;\n $this->admins[$vdn] = TRUE;\n return 0;\n }", "public function addUser($data)\n\t{\n\t\t$this->db->insert($this->pro->prifix.$this->pro->user,$data);\n\t\treturn $this->db->insert_id();\n\t\t\n\t}", "public function addOne($product){\n\t\t$this->db->insert('products', $product);\n\t\treturn $this->db->insert_id();\n\t}", "function add_newuser($user) {\n global $DB;\n $DB->insert_record('report_user_statistics', $user, false);\n}", "function add_staff($staff_info){\n \t\tif($this->db->insert('staff', $staff_info)){\n \t\t\treturn true;\n \t\t}\n \t\telse{\n \t\t\treturn false;\n \t\t}\n \t}", "function getDevId()\n {\n return $this->_props['DevId'];\n }", "public function getDeveloperProfile($forceCreation = false)\n\t{\n\t\t// Obtener el perfil del desarrollador\n\t\t$developerProfiles = $this->getDeveloperProfiles();\n\t\t$developerProfile = $developerProfiles ? $developerProfiles[0] : null;\n\t\t\n\t\tif($developerProfile || !$forceCreation)\n\t\t{\n\t\t\treturn $developerProfile;\t\t\t\t\t\t\n\t\t}\n\t\telse // No existe y se ha pedido que sea creado en ese caso\n\t\t{\n\t\t\t// Crear el nuevo perfil de desarrollador\n\t\t\t$developerProfile = new DeveloperProfile();\n\t\t\t$developerProfile->setsfGuardUserProfile($this);\n\t\t\t$developerProfile->save();\n\t\t\t\n\t\t\t// Retornar el nuevo perfil de desarrollador\n\t\t\treturn $developerProfile;\n\t\t}\n\t}", "public function __addBook($userData) \n {\n\t\t$userquery = 0;\n\t\t$userData['publishDate'] = date('Y-m-d');\n\t\t$userquery = DB::table('tblBooks')->insertGetId(array('bookName' => $userData['bookName'] ,'category' => $userData['category'] ,'desc' => $userData['desc'] ,'publishBy' => $userData['publishBy'] ,'publishDate' => $userData['publishDate'] ,'sysStatus' => 'active'));\n\t\treturn $userquery;\n\t }", "public function save()\n\t\t{\n\t\treturn isset($this->userguid) ? $this->update() : $this->create();\n\t\t}", "function saveGeneral($user){\n\t\t$this->db->insert('tbl_complaints_general_examinations', $user);\n\t\treturn $this->db->insert_id();\n\t}", "function getDeveloperInfo()\n\t{\n\t\t$developer_info = array(\"Team\"=>$this->Info['Team'], \"Username\"=>$this->Info['Username'], \"Position\"=>$this->Info['Position']);\n\t\treturn $developer_info;\n\t}", "function dbInsert($edit)\r\n\t{\r\n\r\n\t}", "function AddGroupParticipant($groupid, $userid, $name, $shippinginfo, $admin)\n{\n\t$query = \n\t\"\n\tINSERT INTO \n\t\t`GGParticipants`\n\tSELECT \n\t\t`GroupId`, '$userid', '$name', '$shippinginfo', '$admin', 'Added'\n\tFROM\n\t\t`GGParticipants`\n\tWHERE\n\t\t`GroupId` = '$groupid'\n\t\tAND NOT EXISTS(\n\t\t\tSELECT \n\t\t\t\tnull \n\t\t\tFROM \n\t\t\t\t`GGParticipants` \n\t\t\tWHERE \n\t\t\t\t`UserId` = '$userid' \n\t\t\t\tAND `GroupId` = '$groupid')\n\tLIMIT 1\";\n\n\t$result = mysql_query($query);\n\n\treturn $result;\n}", "public function add($data) {\n if (isset($data['id'])) {\n $this->db->where('id', $data['id']);\n $this->db->update('users', $data);\n } else {\n $this->db->insert('users', $data);\n $insert_id = $this->db->insert_id();\n return $insert_id;\n }\n }", "public function add($data) {\n\t\tif ($this->db->insert($this->table, $data))\n\t\t\treturn $this->db->insert_id();\n\t\telse\n\t\t\treturn false;\n\t}", "public function hasUserId(){\n return $this->_has(2);\n }", "public function hasUserId(){\n return $this->_has(2);\n }", "public function hasUserId(){\n return $this->_has(2);\n }", "public function hasUserId(){\n return $this->_has(2);\n }", "public function hasUserId(){\n return $this->_has(2);\n }", "public function add_or_update()\n {\n $this->on_duplicate_key('foo = foo + 1');\n $this->insert('table', array('foo' => 'bar'));\n }", "function testUserDBInsert() {\n\t\t\t$u = new User(['user_id' => 50, 'username' => 'fjones', 'screen_name' => 'jones, fred', 'DB' => $this->DB]);\n\n\t\t\t$u->updateDb();\n\n\t\t\t$u2 = User::getOneFromDb(['user_id' => 50], $this->DB);\n\n\t\t\t$this->assertTrue($u2->matchesDb);\n\t\t\t$this->assertEqual($u2->username, 'fjones');\n\t\t}", "function IsHotelManager($user_id) {\n global $DB , $Hotel_ID;\n $stmt = $DB->prepare(\"SELECT * FROM hotel WHERE manager_id = ?\");\n $stmt->bindParam(1, $user_id);\n if ($stmt->execute()) {\n if ($row = $stmt->fetch()) {\n $Hotel_ID = $row[\"hotel_id\"];\n return true;\n }\n }\n return false;\n}", "function addSoftware($software){\r\n\r\n $this->app->log->info(__CLASS__ . '::' . __METHOD__);\r\n // $this->app->log->info('software : '.$this->dumpRet($software));\r\n $dao = new \\PNORD\\Model\\SoftwareDAO($this->app); \r\n return $dao->addSoftware($software); \r\n\r\n }", "public function addUser($data)\r\n\t{\r\n\t\t$db = $this->getDbConnection();\r\n\t\t$result = $db->insert($this->_tablename, $data);\r\n\t\t\r\n\t\t$lastid = 0;\r\n\t\tif($result)\r\n\t\t{\r\n\t\t\t$lastid = $db->lastInsertId();\r\n\t\t}\r\n\t\treturn $lastid;\r\n\t}", "public function mainCategoryFindOrSave($name){\n\t\t$table_data=array();\n\t\t$this->db->select('id'); \n\t\t$this->db->where('name',$name);\n\t\t$query = $this->db->get('main_category');\n\t\t$res = $query->row();\n\t\tif(!empty($res))\n\t\t{\n\t\t\treturn $res->id;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$table_data=array(\n\t\t\t'created'=>date('Y-m-d h:i:s'),\n\t\t\t'name'=>$name,\n\t\t\t'is_active'=>1,\n\t\t\t);\n $this->db->insert('main_category', $table_data);\t\t\t\n\t\t return $this->db->insert_id();\n\t\t}\n\t}", "function merchantExists()\n {\n\n $this->getById();\n if ($this->auth_id != null) return true;\n else {\n return false;\n }\n }", "function addNewUser($userInfo)\n {\n $this->db->trans_start();\n $this->db->insert('users', $userInfo);\n \n $insert_id = $this->db->insert_id();\n \n $this->db->trans_complete();\n \n return $insert_id;\n }", "protected function addAnnouncementToDb()\n {\n $db = Db::getConnection();\n $db->query(\"INSERT INTO sale (id, id_user, is_banned, street, total_area, living_area, kitchen_area, balcony, description, price, type_house, floor, count_floor, rooms_count, ownership) VALUES (NULL, '$this->userId', NULL, '$this->street', '$this->totalArea', '$this->livingArea', '$this->kitchenArea', '$this->balcony', '$this->description', '$this->price', '$this->typeHouse', '$this->floor', '$this->countOfFloors', '$this->roomsCount', '$this->ownership');\");\n return $db->lastInsertId();\n }", "function cmst_vendor_add() {\n\t\tglobal $conn;\n\n\t\t// Initialize table object\n\t\t$GLOBALS[\"mst_vendor\"] = new cmst_vendor();\n\n\t\t// Intialize page id (for backward compatibility)\n\t\tif (!defined(\"EW_PAGE_ID\"))\n\t\t\tdefine(\"EW_PAGE_ID\", 'add', TRUE);\n\n\t\t// Initialize table name (for backward compatibility)\n\t\tif (!defined(\"EW_TABLE_NAME\"))\n\t\t\tdefine(\"EW_TABLE_NAME\", 'mst_vendor', TRUE);\n\n\t\t// Open connection to the database\n\t\t$conn = ew_Connect();\n\t}", "function add($itemInfo)\n {\n// if (isset($itemInfo['userid'])) {\n// $item = $this->getItemById($itemInfo['userid']);\n// } else {\n// $item = $this->getItemByNumber($itemInfo['email']);\n// }\n// if (count($item) > 0) {\n// $itemInfo['update_time'] = date(\"Y-m-d\");\n// $insert_id = $this->update($itemInfo, $item->userid);\n// } else {\n// $itemInfo['created_time'] = date(\"Y-m-d\");\n// $this->db->trans_start();\n// $this->db->insert('tbl_userinfo', $itemInfo);\n// $insert_id = $this->db->insert_id();\n// $this->db->trans_complete();\n// }\n\n $this->db->where('id', $itemInfo['id']);\n $insert_id = $this->db->update('tbl_userinfo', $itemInfo);\n\n return $insert_id;\n }", "function add_voucher($data) \n\t{\n\t\t$this->db->insert('vouchers', $data);\n\t\treturn $this->db->insert_id();\n\t}" ]
[ "0.6750118", "0.61055195", "0.60061026", "0.5925797", "0.5872146", "0.5800288", "0.5493585", "0.5472753", "0.5423313", "0.54073495", "0.5304799", "0.53044593", "0.5299693", "0.5227754", "0.51487607", "0.50664824", "0.50611484", "0.5041275", "0.5038148", "0.49967074", "0.49835217", "0.4976966", "0.49590477", "0.49525872", "0.4949477", "0.49469018", "0.49456632", "0.49383593", "0.49271882", "0.4910615", "0.49100026", "0.4907707", "0.49065578", "0.4905326", "0.48970392", "0.48957527", "0.4895376", "0.48947582", "0.48918205", "0.48915616", "0.4878837", "0.48763487", "0.48761135", "0.48704034", "0.4870306", "0.4856878", "0.4851675", "0.4838424", "0.48382753", "0.483169", "0.48313", "0.4826352", "0.48228773", "0.4822846", "0.4812471", "0.48085696", "0.480798", "0.48038816", "0.47993892", "0.4797104", "0.47943106", "0.47926", "0.47875598", "0.4786866", "0.47844917", "0.478117", "0.47798938", "0.47778645", "0.47776982", "0.47772437", "0.47583175", "0.47547895", "0.47546124", "0.47527292", "0.47475874", "0.47470415", "0.47369018", "0.47360113", "0.47328028", "0.47236297", "0.4720298", "0.47134992", "0.47109872", "0.47100917", "0.47100917", "0.47100917", "0.47100917", "0.47100917", "0.47055992", "0.47040746", "0.4693679", "0.46912423", "0.4688908", "0.46789953", "0.46769303", "0.4672539", "0.4672438", "0.46718284", "0.467017", "0.46625856" ]
0.7040459
0
add developer to database
function addDeveloper($developer) { $data = array( 'GBID' => $developer->id, 'Name' => $developer->name, 'API_Detail' => $developer->api_detail_url, 'GBLink' => $developer->site_detail_url, 'Image' => is_object($developer->image) ? $developer->image->small_url : null, 'ImageSmall' => is_object($developer->image) ? $developer->image->icon_url : null, 'Deck' => $developer->deck ); return $this->db->insert('developers', $data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function registerToDatabase() {\n\t\t\tif ($this->id != null && $this->id != 0) return false;\n\n\t\t\t$this->conn = connectToDb(\"db_avalanche_store\");\n\n\t\t\t$add_query = \"INSERT INTO tbl_dev_info \n\t\t\t(user_id, \n\t\t\t dev_name,\t\n\t\t\t dev_desc) \n\t\t\tVALUES \n\t\t\t('$this->dev_id', \n\t\t\t '$this->dev_name',\t\n\t\t\t '$this->dev_description');\";\n\n\t\t\t$result = $this->conn->query($add_query);\n\n\t\t\t$this->conn->close();\n\n\t\t\tif (!$result) return false;\n\n\t\t\treturn true;\n\t\t}", "public function addToDb()\n {\n\n // make sure this is a valid new entry\n if ($this->isValid()) {\n // check for duplicate\n $vals = sprintf(\"('%s',%d)\",$this->email,$this->level);\n $sql = \" insert into Admins values $vals\";\n Dbc::getReader()->Exec($sql);\n }\n else\n print \"<br> Invalid entry. STOP! ($sql)<br>\";\n }", "function augmentDatabase() {\r\n\t}", "function cmst_vendor_add() {\n\t\tglobal $conn;\n\n\t\t// Initialize table object\n\t\t$GLOBALS[\"mst_vendor\"] = new cmst_vendor();\n\n\t\t// Intialize page id (for backward compatibility)\n\t\tif (!defined(\"EW_PAGE_ID\"))\n\t\t\tdefine(\"EW_PAGE_ID\", 'add', TRUE);\n\n\t\t// Initialize table name (for backward compatibility)\n\t\tif (!defined(\"EW_TABLE_NAME\"))\n\t\t\tdefine(\"EW_TABLE_NAME\", 'mst_vendor', TRUE);\n\n\t\t// Open connection to the database\n\t\t$conn = ew_Connect();\n\t}", "private function createMainDatabaseRecords()\n {\n // get the .sql file\n $sql = (string) @file_get_contents( $this->plugin->getPath() . \"/Setup/install.sql\" );\n\n // insert it\n $this->db->exec( $sql );\n }", "public function addOnDB() {\n\t\t\t$db = mysqli_connect($GLOBALS['host'], $GLOBALS['username'], $GLOBALS['password'], $GLOBALS['dbname']);\n\t\t\t\n\t\t\t$format = \"INSERT INTO `user` \n\t\t\t\t(`username`, `password`, `fullname`, `birthplace`, `birthdate`, `email`, `avatar`) VALUES \n\t\t\t\t('%s', '%s', '%s', '%s', '%s', '%s', '%s');\";\n\t\t\t$stmt = sprintf($format, $this->username, $this->password, $this->fullname, $this->birthplace, $this->birthdate,\n\t\t\t\t$this->email, $this->avatar_path);\n\t\t\t$result = mysqli_query($db, $stmt);\n\t\t\t\n\t\t\t$db->close();\n\t\t}", "function addC(){\n \t$re = new DbManager();\n \t$result = $re -> addColumn();\n \tif ($result == true){\n \t\techo 'colone bien ajouter ';\n \t}\n }", "public function addDB()\n {\n $this->model->addDB();\n header('location:index.php?controller=user');\n }", "public function insertDatabase();", "abstract function is_developer();", "function addToDatabase() {\n\t\tif ($this->id != null && $this->id != 0) return false;\n\n\t\t$db = getDb();\n\n\t\t$add_query = \"INSERT INTO user_table \n\t\t(user_name, \n\t\t user_password,\t\n\t\t isAdmin,\t\n\t\t user_first_name,\n\t\t user_last_name) \n\t\tVALUES \n\t\t('$this->username', \n\t\t '$this->password',\t\n\t\t '$this->isAdmin',\t\n\t\t '$this->firstName',\t\n\t\t '$this->lastName');\";\n\n\t\t$result = mysqli_query($db, $add_query);\n\n\t\tmysqli_close($db);\n\n\t\tif (!$result) return false;\n\n\t\treturn true;\n\n\t}", "function addItemToDB()\n {\n $this->database->addItemToDB($this);\n }", "public function add(){\n $tab = DB::table('student');\n $res = $tab -> insert(['name' => '小黑', 'age' => '18']);\n }", "public function addDB()\n {\n $this->model->addDB();\n header('location:index.php?controller=new');\n }", "public function insert($vendor);", "public function addDatabase($database) {\n\t\t$this->databases[$databases->getDatabaseName()] = $databases;\n\t}", "public function insertContributor($data){\r\n $this->insert($data);\r\n }", "public function run()\n {\n sysuser::insert([\n 'uname' => 'dani123',\n 'namalengkap' => 'daniframdhana',\n 'email' => '[email protected]',\n 'upass' => sha1('admin')\n ]);\n }", "function add_data_admin($data_admin)\n\t\t{\n\t\t\t$this->db->insert('admin', $data_admin);\n\t\t}", "public function run()\n {\n DB::table('environments')->insert([ 'name' => 'Environment1', 'description' => 'Description1']);\n }", "private function _install() {\r\n// `id` int(11) NOT NULL,\r\n// `language_id` int(11) NOT NULL,\r\n// `human_name` mediumtext NOT NULL,\r\n// `machine_name` varchar(255) NOT NULL,\r\n// `is_active` enum('0','1') NOT NULL,\r\n// PRIMARY KEY(`id`)\r\n// ) ENGINE=InnoDB DEFAULT CHARSET=utf8;\r\n// CREATE TABLE IF NOT EXISTS `security_attributes_values` (\r\n// `id` int(11) NOT NULL,\r\n// `user_id` int(11) NOT NULL,\r\n// `attribute_id` int(11) NOT NULL,\r\n// `value` mediumtext NOT NULL,\r\n// PRIMARY KEY(`id`)\r\n// ) ENGINE=InnoDB DEFAULT CHARSET=utf8;\r\n }", "function add_membre($data, $database = false) {\n if (!$database) {\n $database = get_database(); \n }\n if (isset($data[\"name\"], $data[\"password\"])) {\n $database[] = $data;\n change_database($database);\n }\n}", "protected function setUpDatabase($app)\n {\n\n }", "public function setUpDatabase()\n\t{\n\t\t$schemes = new Schemes;\n\t\t$schemes->createRequestTable();\n\n\t Customer::create([\n\t 'email' => '[email protected]',\n\t 'first_name' => 'Osuagwu',\n\t 'last_name' => 'Emeka',\n\t 'phone_number' => \"09095685594\",\n\t 'image' => 'https://github.com/rakit/validation',\n\t 'location' => 'Lagos, Nigeria',\n\t 'sex' => 'Male',\n\t ]);\n\n\t Customer::create([\n\t 'email' => '[email protected]',\n\t 'first_name' => 'Mustafa',\n\t 'last_name' => 'Ozyurt',\n\t 'phone_number' => \"09095685594\",\n\t 'image' => 'https://github.com/rakit/validation',\n\t 'location' => 'Berlin, Germany',\n\t 'sex' => 'Male',\n\t ]);\n\t}", "public function add() {\n\n $sql = \"INSERT INTO persona(id,nombre,apellido_paterno,apellido_materno,estado_salud,telefono,ubicacion)\n VALUES(null,'{$this->nombre}','{$this->apellido_paterno}','{$this->apellido_materno}',\n '{$this->estado_salud}','{$this->telefono}','{$this->ubicacion}')\";\n $this->con->consultaSimple($sql);\n }", "public function database() {\n\t\t$this->_check();\n\t\t$d['title_for_layout'] = __(\"Database creation\");\n\t\t$this->set($d);\n\t}", "public function install_module_register()\n {\n $this->EE->db->insert('modules', array(\n 'has_cp_backend' => 'y',\n 'has_publish_fields' => 'n',\n 'module_name' => ucfirst($this->get_package_name()),\n 'module_version' => $this->get_package_version()\n ));\n }", "public function addDB($key, $db){\n $this->db[$key]=$db;\n }", "function dbInstall($data) {\n/*\napp_vkbot - \n*/\n $data = <<<EOD\n app_vkbot: ID int(10) unsigned NOT NULL auto_increment\n app_vkbot: TITLE varchar(100) NOT NULL DEFAULT ''\n app_vkbot: COLOR varchar(255) NOT NULL DEFAULT ''\n app_vkbot: VAL varchar(255) NOT NULL DEFAULT ''\n app_vkbot: CODE varchar(255) NOT NULL DEFAULT ''\nEOD;\n parent::dbInstall($data);\n }", "public function addUserToDb($token) {\n\t\t\trequire_once('classes/canvasWrapper.php');\n\t\t\t$canvas = new CanvasWrapper();\n\t\t\t$user = $canvas->formatUserData();\n\t\t\t$sql = \"INSERT INTO users (osuId,token,name) VALUES (\" . $user->user_id . \",'\" . $token . \"','\" . $user->name . \"')\";\n\t\t\t$result = $this->db->query($sql);\n\t\t}", "function add_product($product){\n if($this->_check_product_in_db($product)){\n return False; // Product already in database\n }else{\n array_push($this->db, $product);\n return True;\n }\n }", "function xmldb_local_vlacsguardiansurvey_install() {\r\n}", "public function run()\n {\n $user = User::find(2); //expert\n $user->expert()->create([\n 'mobile' => '01199493929',\n 'is_active' => true,\n 'status' => 'approved',\n 'slug' => str_slug($user->name, '-'),\n 'profile_picture_url' => 'images/expert.jpg',\n 'cost_per_minute' => 10,\n 'bio' => 'This is a short bio',\n 'current_occupation' => 'Engineer',\n ]);\n\n }", "private function initialiseDatabaseStructure(){\r\n $this->exec($this->userTableSQL);\r\n $query = \"INSERT INTO `user` (`userName`,`userEmail`,`userFirstName`,`userSurname`,`userPassword`,`userIsActive`,`userIsAdmin`) VALUES(?,?,?,?,?,?,?);\";\r\n $statement = $this->prepare($query);\r\n $password = md5('Halipenek3');\r\n $statement->execute(array('admin','[email protected]','Super','Admin',$password,1,1));\r\n\r\n //Create the knowledge Table\r\n $this->exec($this->knowledgeTableSQL);\r\n $this->exec($this->tagTableSQL);\r\n $this->exec($this->tagsTableSQL);\r\n }", "private function insertUserGroup() {\n\t $groupInfo = self::getQueryInfo('base_group', 'group_name', 'id');\n\t $userInfo = self::getQueryInfo('users', 'email', 'id');\n\t\t\n\t\tDB::table('base_user_group')->insert(['user_id'\t=> $userInfo['[email protected]'], 'group_id' => $groupInfo['sales.reporting']]);\n\t\tDB::table('base_user_group')->insert(['user_id'\t=> $userInfo['[email protected]'], 'group_id' => $groupInfo['customer.analytics']]);\n\t}", "function addDepartment($depName) {\n\n /*\n $dept = new Sysinventory_Department();\n $dept->description = $depName;\n $dept->last_update = mktime();\n $result = $dept->save();\n */\n\n //test($depName,1);\n if (!isset($depName)) return;\n $db = &new PHPWS_DB('sysinventory_department');\n $db->addValue('id','NULL');\n $db->addValue('description',$depName);\n $db->addValue('last_update',time());\n $result = $db->insert();\n }", "function install()\n {\n $query = parent::getList( 'user_name = \\'[email protected]\\'' );\n \n if( $query->num_rows() == 0 )\n {\n $data = array(\n 'user_name' => '[email protected]',\n 'password' => sha1('rkauqkf.'),\n 'role' => 'admin',\n 'is_active' => '1',\n 'd_o_c'=>date(\"Y/m/d\"),\n );\n \n parent::add($data);\n }\n }", "public static function setup_db()\r\n {\r\n $installed_ver = get_option( CART_CONVERTER . \"_db_version\" );\r\n\r\n // prevent create table when re-active plugin\r\n if ( $installed_ver != CART_CONVERTER_DB_VERSION ) {\r\n CartModel::setup_db();\r\n EmailModel::setup_db();\r\n //MailTemplateModel::setup_db();\r\n \r\n add_option( CART_CONVERTER . \"_db_version\", CART_CONVERTER_DB_VERSION );\r\n }\r\n }", "private function install() {\n global $DB, $USER;\n $DB->query(\"CREATE TABLE IF NOT EXISTS `\".$this->DBTable.\"` (\n `section` varchar(255) character set utf8 NOT NULL,\n `property` varchar(255) character set utf8 NOT NULL default '',\n `value` text character set utf8 NOT NULL,\n `type` enum('text','CSV','not_editable','select','set','check','password') character set utf8 NOT NULL default 'text',\n `description` text character set utf8 NOT NULL,\n `set` blob NOT NULL,\n KEY `section` (`section`),\n KEY `property` (`property`)\n) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_swedish_ci;\");\n }", "private function addPaymentToDatabase()\n {\n $this->setReceiptKey();\n \n $this->createDonorEntry();\n $this->createDonationEntry();\n $this->createDonationContentEntry();\n $this->createDonorAddressEntry();\n $this->addDonationToFundraisersTotalRaise();\n \n $this->redirect('donations');\n }", "public function run()\n {\n DB::table('MST_COMPANY')->delete();\n DB::table('MST_COMPANY')->insert([\n 'name' => 'SAMSUNG'\n ]);\n }", "public function addProfessional()\n {\n }", "private function addTestUser(): void\n {\n $this->terminus(sprintf('site:team:add %s %s', $this->getSiteName(), $this->getUserEmail()));\n }", "function addAdministrator($data) {\r\n\t\r\n\t\t//Check to see if the type is zero or not\r\n\t\tif($data['type'] == 0) {\r\n\t\t\t$type = 2; //Set the type variable to 2 (technician)\r\n\t\t} else if($data['type'] == 1) {\r\n\t\t\t$type = 1;\r\n\t\t} else if($data['type'] == 2) {\r\n\t\t\t$type = 2;\r\n\t\t} //end if\r\n\r\n\t\t$this->query('INSERT INTO admins (`id`, `created`, `modified`, `username`, `password`, `first_name`, `middle_name`, \r\n\t\t\t\t\t\t\t `last_name`, `email`, `type`, `computer_id`) \r\n\t\t\t\t\t\t\t VALUES (NULL, CURRENT_TIMESTAMP(), CURRENT_TIMESTAMP(), \"'. $data['username'] .'\", md5(\"'. $data['password'] .'\"), \"'. $data['first_name'] .'\",\r\n\t\t\t\t\t\t\t\t\t \"'. $data['middle_name'] .'\", \"'. $data['last_name'] .'\", \"'. $data['email'] .'\", '. $type .', '. $data['computer_id'] .');');\r\n\r\n\t}", "function addNewAgentToDB($data) {\n\t\tprint \"<br/>\\$data: \";\n\t\tprint_r($data);\n\t\treturn insertDatatoBD(\"agents\", $data) ;\n\t}", "public function setupDatabase()\n\t{\n\n\t\t$installSql = $this->sourceDir . '/installation/sql/mysql/joomla.sql';\n\n\t\tif (0) //!file_exists($installSql))\n\t\t\tthrow new Exception(__METHOD__ . ' - Install SQL file not found in ' . $installSql, 1);\n\n\t\t$this->config->set('site_name', 'TEST ' . $this->config->get('target'));\n\t\t$this->config->set('db_name', $this->config->get('target'));\n\n\t\t$dbModel = new JacliModelDatabase($this->config);\n\n\t\t$this->out(sprintf('Creating database %s ...', $this->config->get('db_name')), false);\n\t\t$dbModel->createDB();\n\t\t$this->out('ok');\n\n\t\t$this->out('Populating database...', false);\n\t\t//$dbModel->populateDatabase($installSql);\n\t\t$this->out('ok');\n\n\t\t$this->out('Creating admin user...', false);\n\t\t$this->createAdminUser($dbModel);\n\t\t$this->out('ok');\n\n\t}", "public function addDevice($dev){\n try{\n $this->validateDevice($dev);\n }catch (Exception $e){\n $this->processException($e);\n }\n\n $devDisplayName=$this->getDisplayNameForDevice($dev);\n $devUnits=$this->getUnitsForDevice($dev);\n $devColor=$this->getColorForDevice($dev);\n\n $this->report[\"devices\"][$dev]=array(\n \"displayName\"=>$devDisplayName,\n \"units\"=>$devUnits,\n \"color\"=>$devColor,\n \"data\"=>array()\n );\n }", "function setDeveloper($dev)\n {\n if (strlen($dev) > 64) {\n throw new InvalidArgumentException(\"Input must be 64 characters or less\n in length!\");\n }\n $this->_developer = $dev;\n }", "protected function createDatabaseStructure() {}", "public function insert($raporAdminSetting);", "public function run()\n {\n DB::table('providers')->insert([\n \t'name' => 'Samsung Company LTD',\n \t'cuit' => '034576341234',\n \t'is_active' => 1,\n \t'profile_id' => 3,\n \t'company_id' => 1\n ]);\n\n DB::table('providers')->insert([\n \t'name' => 'LG Company LTD',\n \t'cuit' => '034576341234',\n \t'is_active' => 1,\n \t'profile_id' => 4,\n \t'company_id' => 1\n ]);\n }", "abstract public function installSQL();", "function dbInsert($edit)\r\n\t{\r\n\r\n\t}", "public function addDB() {\n $this->model->addDB();\n //$this->start();\n header('location:index.php?controller=category');\n }", "function installDatabase()\n\t{\n\t\tif (!$this->setup->getClient()->db_exists)\n\t\t{\n\t\t\tif ($_POST[\"chk_db_create\"])\n\t\t\t{\n\t\t\t\tif (!$this->setup->createDatabase($_POST[\"collation\"]))\n\t\t\t\t{\n\t\t\t\t\tilUtil::sendFailure($this->lng->txt($this->setup->getError()), true);\n\t\t\t\t\tilUtil::redirect(\"setup.php?cmd=displayDatabase\");\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tilUtil::sendFailure($this->lng->txt(\"database_not_exists_create_first\"), true);\n\t\t\t\tilUtil::redirect(\"setup.php?cmd=displayDatabase\");\n\t\t\t}\n\t\t}\n\t\tif (!$this->setup->installDatabase())\n\t\t{\n\t\t\tilUtil::sendFailure($this->lng->txt($this->setup->getError()), true);\n\t\t}\n\t\telse\n\t\t{\n\t\t\tilUtil::sendSuccess($this->lng->txt(\"database_installed\"), true);\n\t\t}\n\t\tilUtil::redirect(\"setup.php?cmd=displayDatabase\");\n\t}", "public function run()\n {\n //\n DB::table(\"lecturers\")->insert([\n\n\n [\n \n \"name\"=>\"Lecturer Vitalis\",\n \"username\"=>\"lecturer101\",\n \"email\"=>\"[email protected]\",\n\n ],\n\n\n\n ]);\n }", "function add_newuser($user) {\n global $DB;\n $DB->insert_record('report_user_statistics', $user, false);\n}", "private function make_db() {\n ee()->load->dbforge();\n $fields = array(\n 'id' => array('type' => 'varchar', 'constraint' => '32'),\n 'access' => array('type' => 'integer', 'constraint' => '10', 'unsigned' => true),\n 'data' => array('type' => 'text')\n );\n ee()->dbforge->add_field($fields);\n ee()->dbforge->add_key('id', true);\n ee()->dbforge->create_table($this->table_name);\n\n return true;\n }", "public function acfedu_create_fill_db() {\n\t\t\t\t$this->acfedu_check_table();\n\t\t\t\trequire_once( ABSPATH . 'wp-admin/includes/upgrade.php' );\n\t\t\t\tob_start();\n\t\t\t\tglobal $wpdb;\n //require_once( 'lib/import_nl.php' );\n //require_once( 'lib/import_be.php' );\n //require_once( 'lib/import_lux.php' );\n require_once( 'lib/import_id.php' );\n\t\t\t\t$sql = ob_get_clean();\n\t\t\t\tdbDelta( $sql );\n\t\t\t}", "public function run()\n {\n DB::table('licenses')->insert([\n ['name' => 'MIT'],\n ['name' => 'apache2'],\n ]);\n }", "function addMajor($name, $department, $institution){\n\n\t\t$this->connection->query(\"INSERT INTO majors (majr_name, majr_dept, majr_inst) VALUES ('$name', '$department', '$institution')\",true);\n\t\tif($_SESSION['query']){\n\t\t\treturn \"Major Successfully Added\";\n\t\t}else{\n\t\t\treturn \"Failed to add major!\";\t\t\n\t\t}\n\n\t}", "public function db_install(){\r\n\r\n if ( !class_exists( 'Inf_Member_Upgrade') )\r\n require_once( dirname(dirname(__FILE__)) . '/includes/db/upgrade.php' );\r\n\r\n $upd = new Inf_Member_Upgrade;\r\n $upd->init();\r\n\r\n if(isset($_GET['update_db']) && $_GET['update_db'])\r\n $upd->run_updates();\r\n\r\n }", "public function add($user){\n\n $this->builder->insert($user);\n\n }", "function addStudent($name, $institution, $major, $minor, $identification, $passkey, $google, $yahoo, $live, $facebook, $linkedin, $twitter){\n\n\t\t$this->connection->query(\"INSERT INTO students (stud_name, stud_inst, stud_major, stud_minor, stud_identification, stud_passkey, stud_google, stud_yahoo, stud_live, stud_facebook, stud_linkedin, stud_twitter) VALUES ('$name', '$institution', '$major', '$minor', '$identification', '$passkey', '$google', '$yahoo', '$live', '$facebook', '$linkedin', '$twitter' )\",true);\n\t\tif($_SESSION['query']){\n\t\t\treturn \"Student Successfully Added\";\n\t\t}else{\n\t\t\treturn \"Failed to add Student!\";\t\t\n\t\t}\t\n\n\t}", "function addUser($user)\n {\n $connection = Doctrine_Manager::connection();\n $query = \"INSERT INTO constant_contact (username, access_token, created_at) VALUES ('\".$user['username'].\"', '\".$user['access_token'].\"', '\".date('Y-m-d H:i:s').\"')\";\n $statement = $connection->execute($query);\n }", "public function run()\n {\n DB::table('admins')->insert(array(\n array(\n 'name' => \"liyakat\",\n 'email' => '[email protected]',\n 'password' => bcrypt('guddu_786'),\n ),\n array(\n 'name' => \"dev\",\n 'email' => '[email protected]',\n 'password' => bcrypt('12345678'),\n )\n ));\n }", "public function preCreateDatabase($database_name);", "private final function _createDbStructure()\n {\n if ($conn = $this->_getConnection()) {\n $installer = new lib_Install('install');\n try {\n $installer->install();\n } catch (Exception $e) {\n app::log($e->getMessage(), app::LOG_LEVEL_ERROR);\n }\n }\n }", "function insert() {\n\t \n\t \t$sql = \"INSERT INTO evs_database.evs_group (gru_id, gru_name, gru_head_dept,gru_company_id)\n\t \tVALUES(?, ?, ?,?)\";\n\t\t \n\t \t$this->db->query($sql, array($this->gru_id, $this->gru_name, $this->gru_head_dept ,$this->gru_company_id));\n\t }", "public function creer(){ /*** Cree un utilisateur par insertion d'un tuple dans la table UserTab ***/\r\n \r\n \r\n // $this -> setInscrit(1);\r\n $this -> insertDb();//Insertion en Bd d'un tuple user\r\n\t\t\t\r\n }", "public function add($data){\n \t\t\t$result = $this->db->insert(\"user\",$data);\n \t\t}", "function dbInstall($data='')\n {\n $data = <<<'EOD'\n apiai_actions: ID int(10) unsigned NOT NULL auto_increment\n apiai_actions: TITLE varchar(255) NOT NULL DEFAULT ''\n apiai_actions: LATEST_PARAMS varchar(255) NOT NULL DEFAULT '' \n apiai_actions: LATEST_USAGE datetime\n apiai_actions: CODE text\n\n apiai_entities: ID int(10) unsigned NOT NULL auto_increment\n apiai_entities: NAME varchar(255) NOT NULL DEFAULT ''\n apiai_entities: LAST_EXPORT datetime\n apiai_entities: CODE text\nEOD;\n parent::dbInstall($data);\n\n// --------------------------------------------------------------------\n $code = <<<'EOD'\n$terminals = SQLSelect('select NAME, TITLE from terminals');\n$total = count($terminals);\n$entries = array();\nfor($i=0; $i<$total; $i++) {\n $entries[] = array('value' => $terminals[$i]['NAME'], 'synonyms' => array($terminals[$i]['TITLE']));\n}\n\n$entity = array(\n 'name' => 'terminal',\n 'entries' => $entries\n);\n\nreturn $entity;\nEOD;\n \n $rec = SQLSelect(\"select * from apiai_entities where NAME LIKE 'terminal'\");\n if(!count($rec)) {\n $rec = array('NAME' => 'terminal', 'CODE' => $code);\n SQLInsert('apiai_entities', $rec);\n }\n\n// --------------------------------------------------------------------\n $code = <<<'EOD'\n$users = SQLSelect('select USERNAME, NAME from users');\n$total = count($users);\n$entries = array();\nfor($i=0; $i<$total; $i++) {\n $entries[] = array('value' => $users[$i]['USERNAME'], 'synonyms' => array($users[$i]['NAME']));\n}\n\n$entity = array(\n 'name' => 'user',\n 'entries' => $entries\n);\n\nreturn $entity;\nEOD;\n \n $rec = SQLSelect(\"select * from apiai_entities where NAME LIKE 'user'\");\n if(!count($rec)) {\n $rec = array('NAME' => 'user', 'CODE' => $code);\n SQLInsert('apiai_entities', $rec);\n }\n\n// --------------------------------------------------------------------\n $code = <<<'EOD'\n$rooms = getObjectsByClass('Rooms');\n$total = count($rooms);\n$entries = array();\nfor($i=0; $i<$total; $i++) {\n $name = $rooms[$i]['TITLE'];\n $entry = array('value' => $name);\n $title = gg($rooms[$i]['TITLE'].'.Title');\n if($title)\n $entry['synonyms'] = array($title);\n $entries[] = $entry;\n}\n\n$entity = array(\n 'name' => 'room',\n 'entries' => $entries\n);\n\nreturn $entity;\nEOD;\n \n $rec = SQLSelect(\"select * from apiai_entities where NAME LIKE 'room'\");\n if(!count($rec)) {\n $rec = array('NAME' => 'room', 'CODE' => $code);\n SQLInsert('apiai_entities', $rec);\n }\n }", "public static function addUser()\n {\n // ADD NEW DATA TO A TABLE\n // MAKE SURE TO SEND USERS TO THE /users page when a user is added\n }", "public function insert() {\n\t\t$this->insert_user();\n\t}", "public function installDb()\r\n {\r\n \r\n $sql = Db::getInstance()->execute('\r\n CREATE TABLE IF NOT EXISTS '._DB_PREFIX_.'clubmembre (\r\n id_clubmembre INT UNSIGNED NOT NULL AUTO_INCREMENT,\r\n prenom TEXT NOT NULL,\r\n nom TEXT NOT NULL,\r\n email TEXT NOT NULL,\r\n id_client INT,\r\n PRIMARY KEY (id_clubmembre)\r\n ) ENGINE = '._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;\r\n ');\r\n\r\n return $sql;\r\n }", "function addTeam($name) {\n global $link;\n $query = 'INSERT INTO team (name)\n VALUES (:name)';\n $statement = $link->prepare($query);\n $statement->bindValue(':name', $name);\n $statement->execute();\n $statement->closeCursor();\n }", "public function run(){\n DB::table('users')->insert([\n 'name' => 'Daily News',\n 'email' => '[email protected]',\n 'password' => Hash::make(102030),\n 'level_id' => 3\n ]); \n }", "public function run()\n {\n DB::table('industrys')->insert([\n 'industry' => 'Logistics',\n ]);\n DB::table('industrys')->insert([\n 'industry' => 'FMCG',\n ]);\n }", "public function addUser($data)\n{\n\t$this->insert($data);\n}", "function create_database() \r\n {\r\n \t\t\t$this->tx_cbywebdav_devlog(1,\"create_database\",\"cby_webdav\",\"create_database\");\r\n\r\n // TODO\r\n return false;\r\n }", "private function initDatabase() {\n \n \n \n }", "public function run()\n {\n\t\t\\Illuminate\\Support\\Facades\\DB::table('department_industrial_contact')->insert([\n\t\t\t'industrial_contact_id' => 1,\n\t\t\t'department_id' => 1\n\t\t]);\n }", "public function addToDb ($user_id) {\n\n $_data = array();\n $this->generateAssocData ($_data);\n \n # Associate this show with this user\n $_data['user_id'] = $user_id;\n \n # Unix timestamp of when this show was created / modified\n $_data['created'] = Time::now();\n $_data['modified'] = Time::now(); \n \n return DB::instance(DB_NAME)->insert('shows', $_data);\n }", "public function addDevise($data)\n {\n $data['etat'] = self::$etatImpMetier->getEtatByNum(1);\n\n return static::$deviseImpdao->addDevise($data);\n\n }", "public function run()\n {\n \n Vendor::create([\n\n 'vendor_name' => 'Foodway',\n 'user_id'=> 2,\n\n ]);\n\n }", "function add_profession()\n\t{\n\t\t$data['name']\t\t\t\t\t=\t$this->input->post('name');\n\t\t$data['created_on']\t\t\t\t= \ttime();\n\t\t$data['created_by']\t\t\t\t= \t$this->session->userdata('user_id');\n\t\t$data['timestamp']\t\t\t\t= \ttime();\n\t\t$data['updated_by']\t\t\t\t= \t$this->session->userdata('user_id');\n\n\t\t$this->db->insert('profession', $data);\n\n\t\t$this->session->set_flashdata('success', 'New profession has been added successfully.');\n\n\t\tredirect(base_url() . 'profession_settings', 'refresh');\n\t}", "public function getDeveloper_id()\n {\n return $this->developer_id;\n }", "function add_table( Modyllic_Schema_Table $table ) {\n $this->add['tables'][$table->name] = $table;\n }", "function add()\n\t{\n\t\t$this->_updatedata();\n\t}", "function addItem2DB($data = null)\n {\n if ($this->isAdmin() == TRUE) {\n $this->loadThis();\n } else {\n $result = $_POST['itemInfo'];\n echo $this->user_model->add($result);\n }\n }", "public function addDB()\n {\n $nom = $_POST['nom'];\n $description = $_POST['descrip'];\n\n $requete = $this->connexion->prepare(\"INSERT INTO `category`(`id`, `nom`, `description`)\n VALUES (NULL, :nom, :description)\");\n $requete->bindParam(':nom', $nom);\n $requete->bindParam(':description', $description);\n $resultat = $requete->execute();\n }", "public function run()\n {\n\n \tDB::table('user_types')->insert(['user_type' => 'пользователь']);\n //\n }", "function hookInstall() {\n// $db = get_db()cou;\n//die(\"got to the installer method...\");\n $this->_saveVocabularies();\n }", "public function addEnvironment()\n {\n\n $data['phpVersions'] = $this->getPhpVersions();\n $data['mysqlVersions'] = $this->getMysqlVersions();\n\n $this->load->view('elements/header');\n $this->load->view('environments/create', $data);\n\n }", "function addMaintenance($data){\r\n\r\n $this->app->log->info(__CLASS__ . '::' . __METHOD__);\r\n // $this->app->log->info('software : '.$this->dumpRet($software));\r\n $dao = new \\PNORD\\Model\\SoftwareDAO($this->app); \r\n return $dao->addMaintenance($data); \r\n\r\n }", "public function run()\n {\n $input = [\n \t'nama_app' => 'CDC',\n \t'nama_tab' => 'CDC',\n \t'copyright_text' => 'PT LAPI ITB'\n ];\n\n \\DB::table('pengaturan_aplikasis')->insert($input);\n }", "protected function setUpDatabase($app)\n {\n parent::setUpDatabase($app);\n\n $app[Tenant::class]->create(['tenant_name' => 'testTenant', 'app_code' => 'FOOBAR']);\n $app[Tenant::class]->create(['tenant_name' => 'testTenant2', 'app_code' => 'BARFOO']);\n }", "public function run()\n {\n DB::table('admins')->insert([\n<<<<<<< HEAD\n 'AdId'=>'A001',\n 'Fullname'=>'Lammia',\n 'Email'=>'[email protected]',\n 'Password'=>bcrypt('12345678')\n=======\n 'adid'=>'A001',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('12345678'),\n 'fullname'=>'Dat'\n>>>>>>> aaf2788ab06e36d4b1fbae2f150c9faa2cbe7b50\n ]);\n }", "function uf_create_release_db_libre_V_3_47()\r\n\t{\r\n\t\t$lb_valido=true;\r\n\t\t$ls_sql=\"\";\r\n\t\tswitch($_SESSION[\"ls_gestor\"])\r\n\t\t{\r\n\t\t\tcase \"MYSQL\":\r\n\t\t\t$ls_sql=\" ALTER TABLE tepuy_empresa ADD COLUMN confiva VARCHAR(1) DEFAULT 'P'; \";\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\t\tcase \"POSTGRE\":\r\n\t\t\t$ls_sql=\" ALTER TABLE tepuy_empresa ADD COLUMN confiva varchar(1) DEFAULT 'P'; \";\r\n\t\t\tbreak;\r\n\t\t}\r\n\r\n\t\t$li_row=$this->io_sql->execute($ls_sql);\r\n\t\tif($li_row===false)\r\n\t\t{ \r\n\t\t\t $this->io_msg->message(\"Problemas al ejecutar Release 3.47\");\t\r\n\t\t\t $lb_valido=false;\r\n\t\t}\r\n return $lb_valido;\t\r\n\t}", "function serendipity_installDatabase() {\n global $serendipity;\n\n $queries = serendipity_parse_sql_tables(S9Y_INCLUDE_PATH . 'sql/db.sql');\n $queries = str_replace('{PREFIX}', $serendipity['dbPrefix'], $queries);\n\n foreach ($queries as $query) {\n serendipity_db_schema_import($query);\n }\n\n if (file_exists(S9Y_INCLUDE_PATH . 'sql/preload.sql')) {\n $queries = serendipity_parse_sql_inserts(S9Y_INCLUDE_PATH . 'sql/preload.sql');\n $queries = str_replace('{PREFIX}', $serendipity['dbPrefix'], $queries);\n foreach ($queries as $query) {\n serendipity_db_schema_import($query);\n }\n }\n}" ]
[ "0.60217", "0.5969905", "0.58614874", "0.57840854", "0.5682054", "0.5603042", "0.55695295", "0.5543228", "0.54279214", "0.5363747", "0.53559154", "0.5355493", "0.5354834", "0.5351193", "0.5330794", "0.53240174", "0.5309294", "0.5276008", "0.527083", "0.5256675", "0.52309", "0.52068746", "0.520395", "0.5203395", "0.5203174", "0.5201173", "0.5192892", "0.519275", "0.5182321", "0.5176349", "0.5152177", "0.515205", "0.51455915", "0.5141233", "0.51408523", "0.5130647", "0.51299536", "0.5117775", "0.51112634", "0.5111052", "0.5106916", "0.51066375", "0.51004666", "0.5098949", "0.5089588", "0.5086112", "0.5077972", "0.5074493", "0.5070046", "0.50663525", "0.5061904", "0.5061841", "0.50608927", "0.5058678", "0.50450206", "0.50398874", "0.5027829", "0.5027492", "0.50164396", "0.5013083", "0.50090027", "0.50078756", "0.50078404", "0.50057024", "0.50051886", "0.50038123", "0.5000276", "0.49974012", "0.4997158", "0.49826285", "0.49806917", "0.49785462", "0.49741682", "0.49681392", "0.4966067", "0.49656475", "0.49649265", "0.49614856", "0.49565926", "0.49543536", "0.4952104", "0.49439552", "0.4941716", "0.49408993", "0.4940158", "0.49327463", "0.49301928", "0.49291533", "0.49270663", "0.49266255", "0.4926435", "0.49246964", "0.49227434", "0.49203622", "0.4913004", "0.4911819", "0.49082118", "0.4901579", "0.490009", "0.48984796" ]
0.7022394
0
get developer by GBID
public function getDevelopers($GBID, $userID) { // check if developer is in database if ($this->isDeveloperInDB($GBID)) { // get developer from database if ($this->getDeveloperFromDatabase($GBID, $userID)) { // developer found return true; } } // developer was not found, get from Giant Bomb $this->load->model('GiantBomb'); $result = $this->GiantBomb->getMeta($GBID, "developer"); // if developer was returned if ($result != null && $result->error == "OK" && $result->number_of_total_results > 0) { // add developer to database $this->addDeveloper($result->results); // get developer from database return $this->getDeveloperFromDatabase($GBID, $userID); } else { // developer was not found return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getDeveloperByGBID($GBID)\n {\n $query = $this->db->get_where('developers', array('GBID' => $GBID));\n\n if($query->num_rows() == 1)\n {\n return $query->first_row();\n }\n\n return null;\n }", "public function getDeveloperFromDatabase($GBID, $userID)\n {\n // get developer from db\n $this->db->select('developers.DeveloperID, developers.GBID, developers.GBLink, developers.Name, developers.Image, developers.ImageSmall, developers.Deck');\n $this->db->from('developers');\n\n if ($userID == null) {\n $userID = 0; // prevents joining on UserID causing an error\n }\n\n // $this->db->join('collections', 'collections.DeveloperID = developers.DeveloperID AND collections.UserID = ' . $userID, 'left');\n // $this->db->join('lists', 'collections.ListID = lists.ListID', 'left');\n\n $this->db->where('developers.GBID', $GBID);\n $query = $this->db->get();\n\n // if developer returned\n if ($query->num_rows() == 1) {\n $result = $query->first_row();\n\n $this->developerID = $result->DeveloperID;\n $this->GBID = $result->GBID;\n $this->GBLink = $result->GBLink;\n $this->name = $result->Name;\n $this->image = $result->Image;\n $this->imageSmall = $result->ImageSmall;\n $this->deck = $result->Deck;\n\n return true;\n }\n \n return false;\n }", "public function getDeveloper_id()\n {\n return $this->developer_id;\n }", "public function getDeveloper($uuid)\n {\n }", "function getDevId()\n {\n return $this->_props['DevId'];\n }", "function getDeveloper($bugid, $patch, $revision = false)\n\t{\n\t\tif ($revision) {\n\t\t\treturn $this->_dbh->prepare('\n\t\t\t\tSELECT developer\n\t\t\t\tFROM bugdb_patchtracker\n\t\t\t\tWHERE bugdb_id = ? AND patch = ? AND revision = ?\n\t\t\t')->execute([$bugid, $patch, $revision])->fetchOne();\n\t\t}\n\t\treturn $this->_dbh->prepare('\n\t\t\tSELECT developer, revision\n\t\t\tFROM bugdb_patchtracker\n\t\t\tWHERE bugdb_id = ? AND patch = ? ORDER BY revision DESC\n\t\t')->execute([$bugid, $patch])->fetchAll(PDO::FETCH_ASSOC);\n\t}", "function getOrAddDeveloper($gbDeveloper)\n {\n // get developer from db\n $developer = $this->getDeveloperByGBID($gbDeveloper->id);\n\n // if developer isn't in db\n if($developer == null)\n {\n // developer was not found, get from Giant Bomb\n $this->load->model('GiantBomb');\n $result = $this->GiantBomb->getMeta($gbDeveloper->id, \"company\");\n\n // if developer was returned\n if ($result != null && $result->error == \"OK\" && $result->number_of_total_results > 0) {\n // add developer to database\n $this->addDeveloper($result->results);\n\n } else {\n // developer was not found\n return false;\n }\n\n // get developer from db\n $developer = $this->getDeveloperByGBID($gbDeveloper->id);\n }\n\n return $developer;\n }", "public function fetch_from_tyk() {\n\t\ttry {\n\t\t\t$tyk = new Tyk_API();\n\t\t\t$developer = $tyk->get(sprintf('/portal/developers/%s', $this->get_tyk_id()));\n\t\t\tif (!is_object($developer) || !isset($developer->id)) {\n\t\t\t\tthrow new Exception('Received invalid response');\n\t\t\t}\n\t\t\treturn $developer;\n\t\t}\n\t\tcatch (Exception $e) {\n\t\t\ttrigger_error(sprintf('Could not fetch developer from API: %s', $e->getMessage()), E_USER_WARNING);\n\t\t}\n\t}", "public function getDeveloperKey();", "function getDeveloper() \n {\n return $this->_developer;\n }", "public function getVendorId() {}", "public function getGaid();", "public function getGame($GBID) \n { \n // build API request\n $url = $this->config->item('gb_api_root') . \"/game/\" . $GBID . \"?api_key=\" . $this->config->item('gb_api_key') . \"&format=json\";\n \n // make API request\n $result = $this->Utility->getData($url, \"Game\");\n \n if(is_object($result))\n {\n return $result;\n } else {\n return null;\n }\n }", "function getBuildingInfo() {\n return getOne(\"SELECT * FROM building WHERE id = ?\",[getLogin()['bid']]);\n}", "function isDeveloperInDB($GBID)\n {\n $query = $this->db->get_where('developers', array('GBID' => $GBID));\n\n return $query->num_rows() > 0 ? true : false;\n }", "public function selectDev() {\r\n\t\t$sql = \"Select id, module_name, is_system From #modules Order By module_name\"; \r\n\t\treturn $this->_select($sql);\r\n\t}", "public function getClientById($id, $db){\n $sql = \"SELECT * FROM client_registrations where id = :id\";\n $pst = $db->prepare($sql);\n $pst->bindParam(':id', $id);\n $pst->execute();\n return $pst->fetch(PDO::FETCH_OBJ);\n }", "function getDeveloperInfo()\n\t{\n\t\t$developer_info = array(\"Team\"=>$this->Info['Team'], \"Username\"=>$this->Info['Username'], \"Position\"=>$this->Info['Position']);\n\t\treturn $developer_info;\n\t}", "public function getVendorId(): ?string;", "public function getIosVendorId();", "function getDeviceTokenForUser($db, $user) {\n $user = $db->prepare($user);\n $result = $db->query(\"SELECT `devicetoken` FROM `apns_devices` WHERE `username`='{$user}'\");\n $row = $result->fetch_array(MYSQLI_ASSOC);\n if ($row != NULL) {\n return $row['devicetoken'];\n } else {\n return NULL;\n }\n}", "public function getUserGcmRegId() {\n $stmt = $this->conn->prepare(\"SELECT gcm_registration_id FROM app_users\");\n // $stmt->bind_param(\"s\", $api_key);\n $stmt->execute();\n $user_gcm = $stmt->get_result();\n $stmt->close();\n return $user_gcm;\n }", "function get_by_key() {\t\n\t\t$sql = \"SELECT * \n\t\t\t\tFROM evs_database.evs_group\n\t\t\t\tWHERE gru_id=?\";\n\t\t$query = $this->db->query($sql, array($this->gru_id));\n\t\treturn $query;\n\t}", "public function getGhostProvider(): GhostUser;", "public function getVendorName(): string;", "function getSelectedVendor($userid){\n $datarow = NULL;\n try\n {\n $db = new Database();\n $db->connect();\n \n $sql = \"SELECT userid,firstname,lastname,category,categorycode,phonenumber,email,agebracket,country,countrycode,gender,town,location,stallnumber,userstatus,xikilaaccount,bancoaccount,wantbancoaccount,creationdate FROM registration \".\n \"where userid=:userid\";\n $params = array(\":userid\" => $userid);\n $results = $db->runSelect($sql,$params);\n \n if ($results != null){\n $datarow = $results[0];\n } \n }\n catch(PDOException $ex) {\n echo $ex->getMessage();\n }\n return $datarow;\n }", "function getShipVendorName( $shipvendorid )\n{\nglobal $db;\n\n$query = \"select ShipVendorName from ShippingVendors where\n\t\t\t\tShipVendorID=$shipvendorid\";\n\nif (!$tmpresult = $db->sql_query($query))\n\t{\n\tRestLog(\"Error 16601 in query: $query\\n\".$db->sql_error());\n\tRestUtils::sendResponse(500, \"16601 - There was a problem getting shipping vendor\"); //Internal Server Error\n\treturn false;\n\t}\n\n$shiprow = $db->sql_fetchrow( $tmpresult );\nreturn $shiprow['ShipVendorName'];\n\n}", "function dev_list() {\r\n\tglobal $gResult;\r\n\t$dev_controller = new Developer_Controller(new Developer);\r\n\t$msg = $dev_controller->getAllDevelopers();\r\n\t$gResult = $gResult.$msg;\r\n\treturn cCmdStatus_OK; \r\n}", "public function getOGAdminID();", "public function getVendor()\n {\n return $this->_coreRegistry->registry('current_vendor');\n }", "private function getDeveloperMailById($id)\n {\n static $devs = array();\n if (!isset($devs[$id])) {\n $cached_logger = self::$logger;\n $config = clone $this->config;\n // Suppress (almost) all logging.\n $config->logger = new \\Psr\\Log\\NullLogger();\n $config->subscribers = array();\n $dev = new Developer($config);\n try {\n $dev->load($id);\n $devs[$id] = $dev->getEmail();\n } catch (ResponseException $e) {\n $devs[$id] = null;\n // Log exceptions that are NOT 404s.\n if ($e->getCode() != 404) {\n $cached_logger->warning('Attempting to load dev “' . $id . '” resulted in a response code of ' . $e->getCode() . '.');\n }\n }\n self::$logger = $cached_logger;\n }\n return $devs[$id];\n }", "function getVendorId($vendor_name)\n\t{\n\t\t global $log;\n $log->info(\"in getVendorId \".$vendor_name);\n\t\tglobal $adb;\n\t\tif($vendor_name != '')\n\t\t{\n\t\t\t$sql = \"select vendorid from ec_vendor where vendorname='\".$vendor_name.\"'\";\n\t\t\t$result = $adb->query($sql);\n\t\t\t$vendor_id = $adb->query_result($result,0,\"vendorid\");\n\t\t}\n\t\treturn $vendor_id;\n\t}", "function GetAppId($db, $apiKey)\n{ \n $collection = $db->AppApiKeyPairs;\n\n $key = $collection->findOne(array('apiKey' => $apiKey));\n \n if($key != null && $key[\"enabled\"] == true)\n {\n return $key[\"appId\"];\n }\n \n header('HTTP/1.1 401 Unauthorized');\n exit();\n}", "function addDeveloper($developer)\n {\n $data = array(\n 'GBID' => $developer->id,\n 'Name' => $developer->name,\n 'API_Detail' => $developer->api_detail_url,\n 'GBLink' => $developer->site_detail_url,\n 'Image' => is_object($developer->image) ? $developer->image->small_url : null,\n 'ImageSmall' => is_object($developer->image) ? $developer->image->icon_url : null,\n 'Deck' => $developer->deck\n );\n\n return $this->db->insert('developers', $data); \n }", "public function show($id)\n {\n return Guru::where($id, 'id')->first();\n }", "private function getExistingKinInfo($id) \n {\n $this->db->select('kin_name, kin_relationship, kin_telephone');\n //where $id = GUID \n $this->db->where('GUID', $id);\n //from the users table\n $query = $this->db->get('users');\n return $query;\n \n }", "function getOrganismVersionName($org_vid){\n global $con;if(!$con)$con=getConnection();\n $query=\"select ucsc_db from organism_version where organism_version_id=?\";\n $result = mysql_query($query,$con);$org_version_id=0;\n if($result){\n $numRows =mysql_numrows($result);\n if($numRows>0){\n $row = mysql_fetch_assoc($result);\n $ucsc_db=$row[\"ucsc_db\"];\n }\n }\n return $ucsc_db;\n}", "function PKG_getPackageID($client,$package)\n{\n\tCHECK_FW(CC_clientname, $client, CC_package, $package);\n\t$sql = \"SELECT id FROM `clientjobs` WHERE client='$client' AND status='wait4acc' AND package='$package'\";\n\n\t$result = DB_query($sql); //FW ok\n\t$line = mysql_fetch_row($result);\n\treturn($line[0]);\n}", "public function getOGApplicationID();", "function get_driver_team($idTeam)\n{\n $list_driver = get_driver_team_db($idTeam);\n return $list_driver;\n}", "public function getGid()\n {\n return $this->Gid;\n }", "public static function getDeveloperIndex() {\n return self::$_help_developers;\n }", "public function developer()\n {\n return $this->belongs_to('Developer');\n }", "function get( $id )\n {\n $this->dbInit(); \n if ( $id != \"\" )\n {\n array_query( $user_group_array, \"SELECT * FROM Grp WHERE ID='$id'\" );\n if ( count( $user_group_array ) > 1 )\n {\n die( \"Feil: Flere user_grouper med samme ID funnet i database, dette skal ikke være mulig. \" );\n }\n else if ( count( $user_group_array ) == 1 )\n {\n $this->ID = $user_group_array[ 0 ][ \"ID\" ];\n $this->Name = $user_group_array[ 0 ][ \"Name\" ];\n $this->Description = $user_group_array[ 0 ][ \"Description\" ];\n $this->UserAdmin = $user_group_array[ 0 ][ \"UserAdmin\" ];\n $this->UserGroupAdmin = $user_group_array[ 0 ][ \"UserGroupAdmin\" ];\n $this->PersonTypeAdmin = $user_group_array[ 0 ][ \"PersonTypeAdmin\" ];\n $this->CompanyTypeAdmin = $user_group_array[ 0 ][ \"CompanyTypeAdmin\" ];\n $this->PhoneTypeAdmin = $user_group_array[ 0 ][ \"PhoneTypeAdmin\" ];\n $this->AddressTypeAdmin = $user_group_array[ 0 ][ \"AddressTypeAdmin\" ];\n }\n }\n }", "public static function getDevelopment()\r\n {\r\n return self::get('dev');\r\n }", "function getPackageInfo($db, $packageID){\n\t$sql = \"SELECT * FROM packages WHERE PackageId = '$packageID'\";\n\t$packageResults = mysqli_query($db, $sql);\n\t$packageRow = mysqli_fetch_assoc($packageResults);\n\treturn $packageRow;\n}", "function Build_get($build_id) {\n\t// Create call\n\t$call = new xmlrpcmsg('Build.get', array(new xmlrpcval($build_id, \"int\")));\n\n\t// Do call and return value\n\treturn do_call($call);\n}", "public function testDestiny2GetVendor()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "function getProfile($prj_id, $usr_id)\n {\n $backend =& self::_getBackend($prj_id);\n return $backend->getProfile($usr_id);\n }", "function getGroup() {\n\n\tglobal $db;\n\treturn $db->getGroup ( $GLOBALS [\"targetId\"] );\n\n}", "private function getApikey($id){\n // If yes, then OK. else show only bank account details.\n\n $apiKey = false;\n\n if($id) {\n\n $this->load->model('donations_meta');\n $rec = $this->donations_meta->ci_join('donation_ads.donation_id, donations_meta.dm_value, donations_meta.dm_key', 'donation_ads', 'donations_meta',\n 'donation_ads.donation_id = donations_meta.donation_id', 'donation_ads.donation_id', $id);\n\n if (isset($rec[0])) {\n // $rec has record\n $username = $rec[0]['dm_value'];\n\n $this->load->model('user');\n $rec = $this->user->getRecord($username, 'username');\n\n if (!$rec) {\n // It means user changed his / her username.\n // This is Design Flaw.\n // Best apporach was that we save userid instead of username at time of saving Cause and Cause Meta\n die('Internal Server Error Occured. Err 10001');\n }\n\n $uid = $rec->uid;\n\n\n $rec = $this->user->ci_join('users_meta.um_key, users_meta.um_title, users_meta.um_value',\n 'users', 'users_meta', 'users.uid = users_meta.fk_uid', 'users.uid', $uid);\n\n //echo '<tt><pre>' . var_export($rec, true) . '</pre></tt>'; exit;\n\n if(is_array($rec) && !empty($rec)){\n foreach($rec as $key => $value){\n if(is_array($value) && isset($value['um_key'])){\n\n if($value['um_key'] === 'stripe_secret_live_api_key'){\n $apiKey = $value['um_value'];\n }\n\n }\n }\n }\n }else {\n // DB Record not found\n //print_r(json_encode($rec));\n\n $apiKey = false;\n }\n }\n\n\n\n return $apiKey;\n }", "function particularvendorlist($id)\n\t{\n\t\t$getParvendor=\"SELECT * from vendor where vendor_id = $id\";\n\t\t$vendor_data=$this->get_results( $getParvendor );\n\t\treturn $vendor_data;\n\t}", "private function LoadVendorById($id)\n\t{\n\t\t$query = \"\n\t\t\tSELECT *\n\t\t\tFROM [|PREFIX|]vendors\n\t\t\tWHERE vendorid='\".(int)$id.\"'\n\t\t\";\n\t\t$result = $GLOBALS['ISC_CLASS_DB']->Query($query);\n\t\treturn $GLOBALS['ISC_CLASS_DB']->Fetch($result);\n\t}", "public static function get_developer_keys() {\n\t\t\t// phpcs:ignore WordPress.NamingConventions.ValidHookName\n\t\t\t$developers = array( apply_filters( 'redux/tracking/developer', array() ) );\n\t\t\tif ( empty( $developers ) ) {\n\t\t\t\t$developers = '';\n\t\t\t} else {\n\t\t\t\tif ( 1 === count( $developers ) ) {\n\t\t\t\t\tif ( empty( $developers[0] ) ) {\n\t\t\t\t\t\t$developers = '';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t$instances = Redux_Instances::get_all_instances();\n\t\t\t$data = array();\n\t\t\tforeach ( $instances as $instance ) {\n\t\t\t\tif ( isset( $instance->args['developer'] ) ) {\n\t\t\t\t\t$data[] = $instance->args['developer'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$data = wp_json_encode( $data );\n\n\t\t\treturn $data;\n\t\t}", "function get_by_key() {\t\n\t\t$sql = \"SELECT * \n\t\t\t\tFROM evs_database.evs_identification\n\t\t\t\tWHERE idf_id=?\";\n\t\t$this->db->query($sql, array($this->idf_id));\n\t\treturn $query;\n\t}", "function PKG_getClientbyPackageID($id)\n{\n\treturn(PKG_getInfoFromPackageID($id,\"client\"));\n}", "function GET_APP_ID(){\n return \"7d0df388-f064-48eb-9092-27fbbf0a438e\";\n}", "public function retrieveUserCodeUsingAPIKey($user_code)\n {\n $post_data = array(\n 'user_code' => $user_code\n );\n return $this->startAnonymous()->uri(\"/oauth2/device/user-code\")\n ->bodyHandler(new FormDataBodyHandler($post_data))\n ->get()\n ->go();\n }", "function GID($in_id, $in_db){\n\tglobal $knj_web;\n\t\n\tif ($knj_web[\"dbconn\"]){\n\t\treturn $knj_web[\"dbconn\"]->selectsingle($in_db, array($knj_web[\"col_id_name\"] => $in_id));\n\t}else{\n\t\t$sql = \"SELECT * FROM \" . $in_db . \" WHERE \" . $knj_web[\"col_id_name\"] . \" = '\" . sql($in_id) . \"' LIMIT 1\";\n\t\t$f_gid = mysql_query($sql) or die(\"MySQL-error: \" . mysql_error() . \"\\nSQL: \" . $sql);\n\t\t$d_gid = mysql_fetch_array($f_gid);\n\t}\n\t\n\treturn $d_gid;\n}", "function buildername($id)\n{\n\t$buildername=mysql_fetch_array(mysql_query(\"select company_name from manage_property_builder where p_bid='$id'\"));\n\treturn $buildername['company_name'];\n\t}", "function get_dev_data($host_data, $devid)\n{\n\n $arr = array ('command'=>'gpu','parameter'=>$devid);\n $dev_arr = send_request_to_host($arr, $host_data);\n \n return $dev_arr['GPU']['0'];\n}", "private function getUser($id)\n {\n //$url = TestServiceAsReadOnly::$elasticsearchHost . \"/CIL_RS/index.php/rest/users/\".$id;\n $url = TestServiceAsReadOnly::$elasticsearchHost.$this->context.\"/users/\".$id;\n \n $response = $this->curl_get($url);\n //echo \"\\n-------getProject Response:\".$response;\n //$result = json_decode($response);\n \n return $response;\n }", "function getDeviceToken($device_id){\r\n global $pdo;\r\n\t\t$select = $pdo->prepare(\"SELECT token FROM device_registry\r\n\t\t\tWHERE device_id = ?\");\r\n\t\t$select->execute(array($device_id));\r\n $row = $select->fetch(PDO::FETCH_ASSOC);\r\n\t\treturn $row['token'];\r\n\t}", "public function getVendor($id) {\n try {\n $objVendor = new Base_Model_ObtorLib_App_Core_Catalog_Dao_Vendor();\n $vendor = $objVendor->getVendor($id);\n return $vendor;\n } catch (Exception $e) {\n throw new Base_Model_ObtorLib_App_Core_Catalog_Exception($e);\n }\n }", "function PKG_getClientIDbyPackageID($id)\n{\n\treturn(CLIENT_getId(PKG_getClientbyPackageID($id)));\n}", "public function fetchProjectID(): string;", "function get_driver_info($idPilot)\n{\n $driver_info = get_driver_info_db($idPilot);\n return $driver_info;\n}", "function Build_lookup_name_by_id($build_id) {\n\t// Create call\n\t$call = new xmlrpcmsg('Build.lookup_name_by_id', array(new xmlrpcval($build_id, \"int\")));\n\n\t// Do call and return value\n\treturn do_call($call);\n}", "function oncall_user_settings($ocid) {\n return db_query(\"SELECT * FROM {oncall_team} WHERE ocid = :id\", array(\":id\" => $ocid))->fetchObject();\n}", "public function retrieve($gid) {\n try{\n $response = $this -> httpClient -> get(\"monitoring/monitoring-group/{$gid}.json\", []);\n return json_decode($response -> getBody(), true);\n }catch( \\Exception $e){\n return $this->handleRequestException($e);\n }\n }", "public function get($gid) {\n\t\t$this->setUrlParam(\"QUERY\", $this->makeQuery($gid));\n\t\treturn $this->fetchAndParse();\n\t}", "public function vendor_app_version_get(){\n $data = $this->model->getAllwhere('vendor_app_version','','versioncode,versionname','id','DESC','1');\n\n $resp = array('rccode' => 1, 'version' => !empty($data) ? $data[0]:[]); \n $this->response($resp);\n \n }", "protected function getGigyaAccount() {\n $gigya_uid = json_decode($this->getRequest()->getParam('login_data'))->UID;\n $gigya_account = $this->gigyaHelper->_getAccount($gigya_uid);\n return $gigya_account;\n }", "function getPackageKey() ;", "function get_profile_usrid($usrid){\r\n\t\r\n}", "function getGalley($id) {\n\t\t$galleyDao = \\DAORegistry::getDAO('ArticleGalleyDAO');\n\t\t$galley = $galleyDao->getGalley($id);\n\t\tif (method_exists($galley, 'getArticleId')) {\n\t\t\t$this->registerGalleys($galley, $galley->getArticleId());\n\t\t} else {\n\t\t\t$this->log->log(\"could not get galley nr \" . $id);\n\t\t}\n\t}", "function get_growsumo_customer($cust_id){\n $ch = curl_init('https://api.growsumo.com/v1/customers/'.$cust_id);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n $auth = GROWSUMO_PK.':'.GROWSUMO_SK;\n curl_setopt($ch, CURLOPT_USERPWD, $auth);\n $response = curl_exec($ch);\n curl_close($ch);\n if($response === false || $response['http_code'] != 200) {\n if (curl_error($ch)) {\n $response .= \"\\n \". curl_error($ch);\n @mail('[email protected]','Failed creating growsumo customer',$response.\"<br> Data:\".print_r($grsm_cust_data));\n }\n }\n return json_decode($response);\n }", "private function getUserapp($id){\n\t if($id > 0){\n\t $deviceToken \t = \\sellermodel\\UserInfoModel::where('user_id',$id)->first();\n\t $configTransport = \\UserConfigTransportModel::where('user_id',$id)->where('transport_id',5)->first();\n\n\t if(!empty($configTransport) && $configTransport['active'] == 1){\n\t if($deviceToken['android_device_token'] != '' || $deviceToken['ios_device_token'] != ''){\n\t return $deviceToken;\n\t }else{\n\t return false;\n\t }\n\t }else{\n\t return false;\n\t }\n\t }else{\n\t return false;\n\t }\n\t}", "function return_oneClientByIdModif($mid)\n{\n return getOne($mid, \"bav_client\", \"cli_id_modif\");\n}", "public function getDriverId($api_key) {\n $stmt = $this->conn->prepare(\"SELECT driver_id FROM driver WHERE api_key = ?\");\n $stmt->bind_param(\"s\", $api_key);\n if ($stmt->execute()) {\n $stmt->bind_result($driver_id);\n $stmt->fetch();\n // TODO\n // $user_id = $stmt->get_result()->fetch_assoc();\n $stmt->close();\n return $driver_id;\n } else {\n return NULL;\n }\n }", "function get_by_key() {\t\n\t\t$sql = \"SELECT * \n\t\t\t\tFROM evs_database.evs_key_component\n\t\t\t\tWHERE kcp_id=?\";\n\t\t$this->db->query($sql, array($this->kcp_id));\n\t\treturn $query;\n\t}", "function PKG_getInfoFromPackageID($id,$variable)\n{\n\tCHECK_FW(CC_packageid, $id, \"A\", $variable);\n\t$sql = \"SELECT $variable FROM clientjobs WHERE id='\".$id.\"';\";\n\n\t$result = DB_query($sql); //FW ok\n\t$line = mysql_fetch_row($result);\n\treturn($line[0]);\n}", "public function vendor($vendor_id)\n\t{\n\t\t$this->_vendors_array('all');\n\t\t\n\t\tif (isset($this->vendors_cache[$vendor_id]))\n\t\t{\n\t\t\treturn $this->vendors_cache[$vendor_id];\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn $this->vendors_cache[1];\n\t\t}\n\t}", "public function get_contributor($key = 0)\n {\n }", "public function get_contributor($key = 0)\n {\n }", "public function getBillingProfileId();", "function setDevId($value)\n {\n $this->_props['DevId'] = $value;\n }", "function getCurrentVGIDAdminId($accountId,$DbC)\n{\n\t$query=\"SELECT vehicle_group_id,admin_id FROM account_detail USE INDEX(ad_account_id) WHERE account_id='$accountId'\";\t\n\t$result=mysql_query($query,$DbC);\n\t$row=mysql_fetch_row($result);\n\treturn $row;\t\n}", "function select_family_created_from_user_admin_id($adminID)\n\t{\n\t\t$select_stmt = sprintf(\"SELECT familyID FROM family WHERE familyAdminID = '%s';\"\n\t\t\t\t,$adminID);\n\t\t\n\t\t$results = $this->db->query($select_stmt);\n\t\t$fetch = mysqli_fetch_row($results);\n\t\t\n\t\tif($results!=false)\n\t\t{\n\t\t\t$this->response->setResponse(true, $fetch);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->response->setResponse(false,\"\",\"Failed to retreive family ID from Family\");\n\t\t}\n\t\t\n\t\treturn $this->response;\n\t}", "function get_purchase_request_by_id($db, $id)\n{\n\n\t$sql = 'SELECT * FROM purchase_requests where id='.$id;\n\t$st = $db->prepare($sql);\n\t$st->execute();\n\t$us = $st->fetchAll();\n\treturn $us[0];\n}", "function getVendors(){\n $datarow = NULL;\n try\n {\n $db = new Database();\n $db->connect();\n \n $sql = \"SELECT userid,firstname,lastname,category,categorycode,phonenumber,email,agebracket,country,countrycode,gender,town,userstatus,xikilaaccount,bancoaccount,wantbancoaccount,creationdate FROM registration \".\n \"where userstatus=:userstatus\";\n $params = array(\":userstatus\" => 1);\n $results = $db->runSelect($sql,$params);\n \n if ($results != null){\n $datarow = $results;\n }\t\t\n }\n catch(PDOException $ex) {\n echo $ex->getMessage();\n }\n return $datarow;\n }", "public function getKomokuByID($komoku_id, $kubun)\n {\n $this->db->select(\"*\");\n $this->db->from('m_komoku');\n $this->db->where('del_flg', '0');\n $this->db->where('komoku_id', $komoku_id);\n $this->db->where('kubun', $kubun);\n\n $query = $this->db->get();\n $result = $query->result_array();\n if (sizeof($result) > 0) {\n return $result[0];\n }\n return null;\n }", "function getVendorname(){\r\n return $this->vendorname;\r\n }", "function googleanlytics()\n{\n\t$gname=mysql_query(\"select * from manage_google_webmaster\");\n\t$grow=mysql_fetch_object($gname);\n\treturn $grow;\n}", "function m_get_jawaban($id_sk, $nipg, $id_kuesioner){\n\t\treturn $this->db->query('Select jawaban from tb_respon_kuesioner where id_sk = '.$id_sk.' AND nipg='.$nipg.' AND id_kuesioner = '.$id_kuesioner.'');\n\t}", "function getBOCAccount($accountid = 'a746637b91b19a261a67d8bd') {\n\t//bankid bda8eb884efcef7082792d45\n\t//accountid a746637b91b19a261a67d8bd\n\t//viewid 5710bba5d42604e4072d1e92\n\t//\n\t// Get cURL resource\n\t$curl = curl_init();\n\t// Set some options - we are passing in a useragent too here\n\tcurl_setopt_array($curl, array(\n\t\tCURLOPT_HTTPHEADER => array(\n\t\t\t\t\t\t\t 'Auth-Provider-Name: 01460900080600',\n\t\t\t\t\t\t\t 'Auth-ID: 123456789',\n\t\t\t\t\t\t\t 'Ocp-Apim-Subscription-Key: f1817e51b3fb4d2ca3fc279d0df3a061'\n\t\t\t\t\t\t\t ),\n\t CURLOPT_RETURNTRANSFER => 1,\n\t CURLOPT_URL => \"http://api.bocapi.net/v1/api/banks/bda8eb884efcef7082792d45/accounts/$accountid/5710bba5d42604e4072d1e92/account\",\n\t // CURLOPT_URL => \"192.168.88.202:8080/customer/$custId/goals\",\n\t CURLOPT_USERAGENT => 'BankBase BOC Hackathon Request'\n\t));\n\t// Send the request & save response to $resp\n\t$resp = curl_exec($curl);\n\t// Close request to clear up some resources\n\tcurl_close($curl);\n\n\t$resp_decode = json_decode($resp);\n\treturn $resp_decode;\n}", "public function getDetail($id_user){\n\t\t$db = new Database();\n\t\t$dbConnect = $db->connect();\n\t\t$sql = \"SELECT * FROM user where id_user = '{$id_user}'\";\n\t\t$data = $dbConnect->query($sql);\n\t\t$dbConnect = $db->close();\n\t\treturn $data->fetch_array();\n\t}", "abstract function is_developer();", "function get_team_info($idTeam)\n{\n $team_info = get_team_info_db($idTeam);\n return $team_info;\n}", "protected function getBelongingRaidDev($dev)\n\t{\n\t\tfor ($vDisk = 0; $vDisk < $this->getDiskAmount(); $vDisk++)\n\t\t{\n\t\t\tforeach ($this->getRaidDevsBuildingDisk($vDisk) as $raidDev)\n\t\t\t\tif ($dev == $raidDev)\n\t\t\t\t\treturn($this->getDiskDev($vDisk));\n\t\t}\n\t\n\t\treturn(false);\n\t}" ]
[ "0.745457", "0.6790662", "0.6525077", "0.62479895", "0.6175166", "0.60971165", "0.6051891", "0.6002118", "0.59929645", "0.58735746", "0.5712", "0.560319", "0.55546635", "0.5546957", "0.54967", "0.53585315", "0.5330587", "0.53078085", "0.5264711", "0.5253704", "0.5240388", "0.5225924", "0.5225857", "0.52233446", "0.52020484", "0.5193185", "0.5190428", "0.518525", "0.5124208", "0.5122894", "0.5120814", "0.51167786", "0.5112803", "0.51115", "0.510038", "0.5094957", "0.50902945", "0.5068732", "0.50566506", "0.5051196", "0.50492334", "0.50378084", "0.5002789", "0.50001824", "0.49970654", "0.49867108", "0.49839228", "0.4972345", "0.4957925", "0.4954737", "0.4951676", "0.49313045", "0.49274084", "0.492229", "0.49181247", "0.49164954", "0.49104658", "0.49098954", "0.4901357", "0.48971355", "0.4880339", "0.48793352", "0.48775077", "0.4876457", "0.48741487", "0.4865875", "0.48623824", "0.48574126", "0.4853267", "0.48492035", "0.48491633", "0.48457065", "0.48449364", "0.48403585", "0.4839666", "0.48394528", "0.48353118", "0.48257178", "0.48244488", "0.48225394", "0.48190555", "0.48175207", "0.48098978", "0.48092717", "0.48072213", "0.48050877", "0.48041904", "0.48000792", "0.4799969", "0.47975534", "0.47968957", "0.47968918", "0.47871763", "0.4777312", "0.4773916", "0.47735256", "0.47728962", "0.4768557", "0.47677606", "0.4764904" ]
0.6084658
6
get developer from database
public function getDeveloperFromDatabase($GBID, $userID) { // get developer from db $this->db->select('developers.DeveloperID, developers.GBID, developers.GBLink, developers.Name, developers.Image, developers.ImageSmall, developers.Deck'); $this->db->from('developers'); if ($userID == null) { $userID = 0; // prevents joining on UserID causing an error } // $this->db->join('collections', 'collections.DeveloperID = developers.DeveloperID AND collections.UserID = ' . $userID, 'left'); // $this->db->join('lists', 'collections.ListID = lists.ListID', 'left'); $this->db->where('developers.GBID', $GBID); $query = $this->db->get(); // if developer returned if ($query->num_rows() == 1) { $result = $query->first_row(); $this->developerID = $result->DeveloperID; $this->GBID = $result->GBID; $this->GBLink = $result->GBLink; $this->name = $result->Name; $this->image = $result->Image; $this->imageSmall = $result->ImageSmall; $this->deck = $result->Deck; return true; } return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getDeveloper() \n {\n return $this->_developer;\n }", "public function developer()\n {\n return $this->belongs_to('Developer');\n }", "public function getDeveloper_id()\n {\n return $this->developer_id;\n }", "public function getDeveloper($uuid)\n {\n }", "function getDeveloper($bugid, $patch, $revision = false)\n\t{\n\t\tif ($revision) {\n\t\t\treturn $this->_dbh->prepare('\n\t\t\t\tSELECT developer\n\t\t\t\tFROM bugdb_patchtracker\n\t\t\t\tWHERE bugdb_id = ? AND patch = ? AND revision = ?\n\t\t\t')->execute([$bugid, $patch, $revision])->fetchOne();\n\t\t}\n\t\treturn $this->_dbh->prepare('\n\t\t\tSELECT developer, revision\n\t\t\tFROM bugdb_patchtracker\n\t\t\tWHERE bugdb_id = ? AND patch = ? ORDER BY revision DESC\n\t\t')->execute([$bugid, $patch])->fetchAll(PDO::FETCH_ASSOC);\n\t}", "public function fetch_from_tyk() {\n\t\ttry {\n\t\t\t$tyk = new Tyk_API();\n\t\t\t$developer = $tyk->get(sprintf('/portal/developers/%s', $this->get_tyk_id()));\n\t\t\tif (!is_object($developer) || !isset($developer->id)) {\n\t\t\t\tthrow new Exception('Received invalid response');\n\t\t\t}\n\t\t\treturn $developer;\n\t\t}\n\t\tcatch (Exception $e) {\n\t\t\ttrigger_error(sprintf('Could not fetch developer from API: %s', $e->getMessage()), E_USER_WARNING);\n\t\t}\n\t}", "public function selectDev() {\r\n\t\t$sql = \"Select id, module_name, is_system From #modules Order By module_name\"; \r\n\t\treturn $this->_select($sql);\r\n\t}", "function getOrAddDeveloper($gbDeveloper)\n {\n // get developer from db\n $developer = $this->getDeveloperByGBID($gbDeveloper->id);\n\n // if developer isn't in db\n if($developer == null)\n {\n // developer was not found, get from Giant Bomb\n $this->load->model('GiantBomb');\n $result = $this->GiantBomb->getMeta($gbDeveloper->id, \"company\");\n\n // if developer was returned\n if ($result != null && $result->error == \"OK\" && $result->number_of_total_results > 0) {\n // add developer to database\n $this->addDeveloper($result->results);\n\n } else {\n // developer was not found\n return false;\n }\n\n // get developer from db\n $developer = $this->getDeveloperByGBID($gbDeveloper->id);\n }\n\n return $developer;\n }", "function getDevId()\n {\n return $this->_props['DevId'];\n }", "private function get_consultant_info() {\n try {\n /** @noinspection PhpUndefinedMethodInspection */\n $stm=$this->uFunc->pdo(\"uAuth\")->prepare(\"SELECT\n firstname,\n secondname,\n email\n FROM\n u235_users\n JOIN \n u235_usersinfo\n ON\n u235_users.user_id=u235_usersinfo.user_id AND\n u235_usersinfo.status=u235_users.status\n WHERE\n u235_users.user_id=:user_id AND\n u235_users.status='active' AND\n u235_usersinfo.site_id=:site_id\n \");\n $site_id=site_id;\n /** @noinspection PhpUndefinedMethodInspection */$stm->bindParam(':site_id', $site_id,PDO::PARAM_INT);\n /** @noinspection PhpUndefinedMethodInspection */$stm->bindParam(':user_id', $this->cons_id,PDO::PARAM_INT);\n /** @noinspection PhpUndefinedMethodInspection */$stm->execute();\n }\n catch(PDOException $e) {$this->uFunc->error('90'/*.$e->getMessage()*/);}\n\n return $stm;\n }", "function getDeveloperInfo()\n\t{\n\t\t$developer_info = array(\"Team\"=>$this->Info['Team'], \"Username\"=>$this->Info['Username'], \"Position\"=>$this->Info['Position']);\n\t\treturn $developer_info;\n\t}", "function getDeveloperByGBID($GBID)\n {\n $query = $this->db->get_where('developers', array('GBID' => $GBID));\n\n if($query->num_rows() == 1)\n {\n return $query->first_row();\n }\n\n return null;\n }", "public function index()\n {\n return Developer::all();\n }", "public function tampil_data()\n {\n return $this->db->get('developer')->result_array();\n }", "function getUser(){\n $db=new connect();\n $select=\"select * from users\";\n return $db->getList($select);\n }", "public static function getvendorData()\n {\n\n $value=DB::table('users')->where('user_type','=','vendor')->where('drop_status','=','no')->orderBy('id', 'desc')->get(); \n return $value;\n\t\n }", "function getSelectedVendor($userid){\n $datarow = NULL;\n try\n {\n $db = new Database();\n $db->connect();\n \n $sql = \"SELECT userid,firstname,lastname,category,categorycode,phonenumber,email,agebracket,country,countrycode,gender,town,location,stallnumber,userstatus,xikilaaccount,bancoaccount,wantbancoaccount,creationdate FROM registration \".\n \"where userid=:userid\";\n $params = array(\":userid\" => $userid);\n $results = $db->runSelect($sql,$params);\n \n if ($results != null){\n $datarow = $results[0];\n } \n }\n catch(PDOException $ex) {\n echo $ex->getMessage();\n }\n return $datarow;\n }", "abstract function is_developer();", "function getProfileInfo($user){\n\t\tglobal $db;\n\t\t$sql = \"SELECT * from personalinfo WHERE user_email ='$user'\";\n\t\t$result =$db->query($sql);\n\t\t$infotable = $result->fetch_assoc();\n\t\treturn $infotable;\n\t}", "function getVendors(){\n $datarow = NULL;\n try\n {\n $db = new Database();\n $db->connect();\n \n $sql = \"SELECT userid,firstname,lastname,category,categorycode,phonenumber,email,agebracket,country,countrycode,gender,town,userstatus,xikilaaccount,bancoaccount,wantbancoaccount,creationdate FROM registration \".\n \"where userstatus=:userstatus\";\n $params = array(\":userstatus\" => 1);\n $results = $db->runSelect($sql,$params);\n \n if ($results != null){\n $datarow = $results;\n }\t\t\n }\n catch(PDOException $ex) {\n echo $ex->getMessage();\n }\n return $datarow;\n }", "public function getToolOwnerAttribute() {\n\t\t//\n\t\t$user = User::getIndex(Session::get('user_uid'));\n\t\tif ($user) {\n\n\t\t\t// fetch owner information\n\t\t\t//\n\t\t\t$owner = Owner::getIndex($this->tool_owner_uuid);\n\t\t\tif ($owner) {\n\t\t\t\treturn $owner->toArray();\n\t\t\t}\n\t\t}\n\t}", "public function hasdeveloper()\n {\n return $this->hasuser() && $this->user()->isdeveloper();\n }", "public function getVendorId() {}", "public function getOwner()\n\t{\n\t\tglobal $mysql;\n\t\t$result = $mysql->query(\"SELECT `sid` FROM `students` WHERE `laptop` = \".$this->getID());\n\t\tif ( !$result || mysqli_num_rows($result) == 0 )\n\t\t\treturn false;\n\t\treturn new Student(mysqli_result($result, 0, \"sid\"));\n\t}", "public static function getProjectSmallDetail($owner){\n\t\t$db = DemoDB::getConnection();\n\t\t$sql = \"SELECT id, name, description, created_at\n\t\t\t\tFROM project\n\t\t\t\tWHERE administrator_id = :id\";\n\t\t$stmt = $db->prepare($sql);\n $stmt->bindValue(\":id\", $owner);\n\t\t$ok = $stmt->execute();\n\t\tif ($ok) {\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n }\n\t}", "function addDeveloper($developer)\n {\n $data = array(\n 'GBID' => $developer->id,\n 'Name' => $developer->name,\n 'API_Detail' => $developer->api_detail_url,\n 'GBLink' => $developer->site_detail_url,\n 'Image' => is_object($developer->image) ? $developer->image->small_url : null,\n 'ImageSmall' => is_object($developer->image) ? $developer->image->icon_url : null,\n 'Deck' => $developer->deck\n );\n\n return $this->db->insert('developers', $data); \n }", "public function getVendorName(): string;", "public function getT_Major(){\n\t\t\t \t$sql=\"select distinct(major_name) from major\";\n\t\t\t \t$this->openDB();\n\t\t\t \t$this->prepareQuery($sql);\n\t\t\t \t$result=$this->executeQuery();\n\t\t\t \t\n\t\t\t \treturn $result;\t \n\t\t\t\t}", "public function getDeveloper()\n {\n return 'Absolute Web Solutions';\n }", "public function getVendor()\n {\n return $this->_coreRegistry->registry('current_vendor');\n }", "function getOrganismVersionName($org_vid){\n global $con;if(!$con)$con=getConnection();\n $query=\"select ucsc_db from organism_version where organism_version_id=?\";\n $result = mysql_query($query,$con);$org_version_id=0;\n if($result){\n $numRows =mysql_numrows($result);\n if($numRows>0){\n $row = mysql_fetch_assoc($result);\n $ucsc_db=$row[\"ucsc_db\"];\n }\n }\n return $ucsc_db;\n}", "function getPartner() {\n $table = $this->get_table();\n $query = $this->db->get($table);\n return $query;\n }", "public function getAdministrator() {\n\n return database::getInstance()->select('staff',\"*\");\n\n\n }", "function getBuildingInfo() {\n return getOne(\"SELECT * FROM building WHERE id = ?\",[getLogin()['bid']]);\n}", "public function currentUsrDept()\n { \n $curr_usr = $this->username;\n\n $this->db->select(\"sm_dept_code\");\n $this->db->from(\"ims_hris.staff_main\");\n $this->db->where(\"upper(sm_apps_username)\", $curr_usr);\n $q = $this->db->get();\n \n return $q->row_case('UPPER');\n }", "public function get_developers()\n {\n $this->data['developer'] = $this->CreateTeamModel->get_developers();\n $this->load->view('add_member_view',$this->data);\n }", "public function select(){\n\t\t$sql=\"SELECT PROGRA_ID,PROGRA_CODIGO, PROGRA_NOMBRE, PROGRA_EMAIL, PROGRA_USUADIGI, PROGRA_FECHDIGI, PROGRA_HORADIGI\n\t\t FROM programa\";\n\t\treturn ejecutarConsulta($sql);\n\t}", "function dev_list() {\r\n\tglobal $gResult;\r\n\t$dev_controller = new Developer_Controller(new Developer);\r\n\t$msg = $dev_controller->getAllDevelopers();\r\n\t$gResult = $gResult.$msg;\r\n\treturn cCmdStatus_OK; \r\n}", "public function getProfile()\n {\n $res = $this->getEntity()->getProfile();\n\t\tif($res === null)\n\t\t{\n\t\t\t$this->setProfile(SDIS62_Model_DAO_Abstract::getInstance($this::$type_objet)->findByCriteria('Profile', array('primary' => $this::getPrimary())));\n\t\t\treturn $this->getEntity()->getProfile();\n\t\t}\n return $res;\n }", "public function getSeniorContributors()\n {\n $query=\"select identifier FROM \".$this->_name.\" WHERE profile_type ='senior' AND status = 'Active'\";\n if(($result = $this->getQuery($query,true)) != NULL)\n return $result;\n else\n return \"NO\";\n }", "public function getDevelopers(): array\n {\n }", "public static function getClientWithManagerPrivileges()\r\n {\r\n $db = Zend_Registry::get(\"db\");\r\n\r\n $profile = new MemberProfile();\r\n\r\n $select = $profile->getSelectStatement();\r\n\r\n// $select->where('MP_IsDetaillant = ?', 1);\r\n $select->order('company');\r\n $select->order('lastName');\r\n $select->order('firstName');\r\n\r\n return $db->fetchAll($select);\r\n }", "function get_driver_team($idTeam)\n{\n $list_driver = get_driver_team_db($idTeam);\n return $list_driver;\n}", "public function getVendorId(): ?string;", "public static function getDevelopment()\r\n {\r\n return self::get('dev');\r\n }", "public function getPersonal();", "public function fetchProgramById(){\n $query = $this->connection->query(\"select * from programs where id='$this->id'\");\n return $query;\n }", "public function get_user() {\r\n return $this->util_model->get_data(\r\n 'schools', \r\n array('unitname') \r\n );\r\n }", "function getdriverdetails()\n{\n\t//returns the details of the driver\n\t$sql=\"select * from driver_detail where status=0 order by rand() limit 1\";\n\tforeach($GLOBALS['db']->query($sql) as $row);\n\tif(isset($row))\n\t\treturn $row;\n}", "public function getRecord()\n {\n return $this->options['peoplefinder']->getByNUID($this->nu_id);\n }", "function get_database_user()\n\t{\n\t\treturn ($this -> database_user);\n\t}", "function get_ua($id_des){\n $sql=\"select uni_acad from designacion where id_designacion=\".$id_des;\n $res= toba::db('designa')->consultar($sql); \n return $res[0]['uni_acad'];\n }", "public function Info()\n\t{\n\t\t$sql = \"SELECT \n\t\t\t\t\t\t*, \n\t\t\t\t\t\tmajor.name AS majorName, \n\t\t\t\t\t\tsubject.name AS name,\n\t\t\t\t\t\tcourse.tipo as tipoCuatri,\n\t\t\t\t\t\tsubject.totalPeriods,\n\t\t\t\t\t\t(SELECT IF((course.modality = 'Online'), subject.crm_id_online, subject.crm_id_local)) AS crm_id,\n\t\t\t\t\t\t(SELECT IF((course.modality = 'Online'), subject.crm_name_online, subject.crm_name_local)) AS crm_name\n\t\t\t\t\tFROM\n\t\t\t\t\t\tcourse\n\t\t\t\t\tLEFT JOIN subject ON subject.subjectId = course.subjectId\n\t\t\t\t\tLEFT JOIN major ON major.majorId = subject.tipo\n\t\t\t\t\tWHERE\n\t\t\t\t\t\tcourseId='\" . $this->courseId . \"'\";\n\t\t//configuramos la consulta con la cadena de actualizacion\n\n\t\t//$sql=\"select \";\n\n\t\t$this->Util()->DB()->setQuery($sql);\n\t\t//ejecutamos la consulta y obtenemos el resultado\n\t\t$result = $this->Util()->DB()->GetRow();\n\t\tif ($result) {\n\t\t\t//\t\t\t\t$result = $this->Util->EncodeRow($result);\n\t\t}\n\n\t\t$result[\"access\"] = explode(\"|\", $result[\"access\"]);\n\n\t\t$user = new User;\n\t\t$user->setUserId($result[\"access\"][0]);\n\t\t$info = $user->Info();\n\t\t$result[\"encargado\"] = $info;\n\t\treturn $result;\n\t}", "public function getDeveloperProfile($forceCreation = false)\n\t{\n\t\t// Obtener el perfil del desarrollador\n\t\t$developerProfiles = $this->getDeveloperProfiles();\n\t\t$developerProfile = $developerProfiles ? $developerProfiles[0] : null;\n\t\t\n\t\tif($developerProfile || !$forceCreation)\n\t\t{\n\t\t\treturn $developerProfile;\t\t\t\t\t\t\n\t\t}\n\t\telse // No existe y se ha pedido que sea creado en ese caso\n\t\t{\n\t\t\t// Crear el nuevo perfil de desarrollador\n\t\t\t$developerProfile = new DeveloperProfile();\n\t\t\t$developerProfile->setsfGuardUserProfile($this);\n\t\t\t$developerProfile->save();\n\t\t\t\n\t\t\t// Retornar el nuevo perfil de desarrollador\n\t\t\treturn $developerProfile;\n\t\t}\n\t}", "public function getDeveloperKey();", "public static function getDeveloperIndex() {\n return self::$_help_developers;\n }", "function getApplicantYet(){\n try {\n $user = 'root';\n $pass = '1q2w3e';\n $dbh = new PDO('mysql:host=localhost;dbname=animal;charset=utf8',$user,$pass);\n $dbh -> exec(\"SET CHARACTER SET utf-8\");\n $sql = $dbh->prepare(\"SELECT * FROM applicant where licensenumber IS NULL\");\n $sql->execute();\n #echo 'Count row : '.$sql->rowCount().'<br/>';\n $result = $sql->fetchAll();\n\n $dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_WARNING);\n $dbh = null;\n\n return $result;\n\n } catch (PDOException $e) {\n print \"Error!: \" . $e->getMessage() . \"<br/>\";\n die();\n }\n }", "public function getActSchoolAdminPerson() {\n return $this->dataBase->getEntry('person',\"role like '%admin%' and classID=\".$this->getStafClassBySchoolId(getActSchoolId())[\"id\"]);\n }", "public function getAdmin() {\n $sql = \"SELECT *\n FROM {$this->tablename} p\n WHERE p.status='admin'\";\n return $this->db->query($sql)->single($this->entity);\n }", "function getVendorname(){\r\n return $this->vendorname;\r\n }", "function getUser()\n {\n $stmt = self::$_db->prepare(\"SELECT u.id_user AS id_user, u.username AS username, u.mail AS mail, u.description AS description, u.image AS image FROM user AS u\n WHERE u.id_user=:uid\");\n $uid = self::getUserID();\n $stmt->bindParam(\":uid\", $uid);\n $stmt->execute();\n return $stmt->fetchAll(PDO::FETCH_ASSOC)[0];\n }", "public function data_user(){\n\t\treturn $this->db->get('registrasi');\n\t}", "function afficherclient()\r\n\t{\r\n\t\t$sql=\"SElECT * From user\";\r\n\t\t$db = config::getConnexion();\r\n\t\ttry\r\n\t\t{\r\n\t\t$liste=$db->query($sql);\r\n\t\treturn $liste;\r\n\t\t}\r\n catch (Exception $e)\r\n {\r\n die('Erreur: '.$e->getMessage());\r\n }\r\n\t}", "public function getClient(){ return UserData::getById($this->client_id); }", "private function getOneUserApp() {\n $this->user_panel->checkAuthAdmin();\n $this->user_app->findOne();\n }", "function getOwnerById($id)\n\t{\n\t\t$sql = \"Select * from tblowner where pkowner_id =\" .$id; // sql statement \n\t\t$result = getConn($sql);\t\t\t// execute sql statement \n\t\treturn $result;\t\t\t\t\t\t// return result from sql \n\t}", "public function GetVendor()\n\t{\n\t\treturn $this->vendor;\n\t}", "public function index()\n {\n return Developer::latest()->paginate(10);\n }", "private function getUser()\n {\n $userObj = new Core_Model_Users;\n return $userObj->profile();\n }", "function hotproject()\n{\t\n\t\t$sql=\"select property_name from manage_property where hot_property='Y'\";\n\t\t$res=mysql_query($sql);\n\t\t$row=mysql_fetch_object($res);\n\t\treturn $row;\n\n\t}", "function getUser($email, $password) {\n\ttry {\n\t\t$DBH = DBC('postgres'); //enter db name\n\t\t$SQL = \"SELECT password,dev_id FROM developer WHERE email = ?;\";\n\t\t$STH = $DBH->prepare($SQL);\n\t\t$STH->execute(array($email));\n\t\t$return = false;\n\t\t$json_dev = \"\";\n\t\tforeach ($STH->fetchAll(PDO::FETCH_ASSOC) as $row) {\n\t\t\t//All passwords are hashed using password_hash, so to we must use password_verify to compare them\n\t\t\tif (password_verify($password, $row['password'])) {\n\t\t\t\t\t$json_dev = json_encode(array('response' => 1,'dev_id' => $row['dev_id']));\n\t\t\t $return = true;\n\t\t\t}\n\t\t}\n\t\tif($return) {\n\t\t\techo $json_dev;\n\t\t} else {\n\t\t\techo json_encode($json_dev = array('response' => 0));\n\t\t}\n\t} catch(PDOException $e) {\n\t\techo $e->getMessage();\n\t}\n}", "private function getOneAppVersion() {\n $this->app_version->findOne();\n }", "function getAllDept(){\r\n echo\r\n $query = \"SELECT dept_name,dept_id FROM department\";\r\n $result = $this->executeQuery($query); \r\n return $result;\r\n }", "function findCompany($das,$name) {\n\t$dbh = new PDO(PDO_DSN,DATABASE_USER,DATABASE_PASSWORD);\n\ttry {\n\t\t$pdo_stmt = $dbh->prepare('select name, id from company where name=?');\n\t\t$root = $das->executePreparedQuery($dbh, $pdo_stmt ,array($name), array('company.name', 'company.id'));\n\t} catch (SDO_DAS_Relational_Exception $e) {\n\t\techo \"SDO_DAS_Relational_Exception raised when trying to retrieve data from the database.\";\n\t\techo \"Probably something wrong with the SQL query.\";\n\t\techo \"\\n\".$e->getMessage();\n\t\texit();\n\t}\n\treturn $root['company'][0];\n}", "function getUserInfo($db, $credentialID){\n\t$sql = \"SELECT * FROM customers WHERE credentialID = '$credentialID'\";\n\t$customerResult = mysqli_query($db, $sql);\n\t$customerRow = mysqli_fetch_assoc($customerResult);\n\treturn $customerRow;\n}", "public function getUserData()\n\t{\n\t\t$fbuid = $this->getFBUID();\n\t\t$rs = $this->db->query(\"SELECT * from selective_status_users where fbuid = \" . $this->db->quote($fbuid) . \" limit 1\");\n\t\tif ($rs && $row = $rs->fetch()) {\n\t\t\treturn $row;\n\t\t}\n\t}", "public function get_persona(){\n\t$exe = $this->db->get('persona');\n\treturn $exe->result();\n}", "function GetProfileDetails(){\n\t\t$this->load->model('User_model');\n\t\t\n\t\t$this->user_id = $this->User_model->Get_User_ID_By_Token($this->user_auth_id); //Just Like a call to require ID of USER\n\t\t//Did this because the user_id might be set but above function just represents auth ID and sends to model to deliver real ID\n\t\t\n\t\t$this->db->select('firstname,lastname,auth_token,program_name,level,grad_year');\n\t\t$this->db->from('users');\n\t\t$this->db->join('programs', 'programs.program_id = users.program_id');\n\t\t$this->db->join('students', 'students.user_id = users.user_id');\n\t\t$this->db->where('users.user_id', $this->user_id);\n\t\t$query = $this->db->get();\n\t\t\n\t\t$results = $query->result_array();\n\t\t\n\t\treturn $results[0];\n\t}", "public function getOrm()\n {\n $user= User::first();\n dd($user->NombresCompletos,$user->profile->edad,$user->profile->Biografia);\n }", "function getUser() {\n $DBA = new DatabaseInterface();\n $fields = array(0 => 'username', 1 => 'title', 2 => 'first_name', 3 => 'last_name', 4 => 'password', 5 => 'contactemail', 6 => 'contacttelephone', 7 => 'newsletter', 8 =>'pcode', 9 => 'store_owner', 10 => 'house', 11 => 'street', 12 => 'town', 13 => 'county', 14 => 'geolong', 15 => 'geolat', 16 => 'avatar', 17 => 'mobile', 18 => 'optout');\n $idfields = array(0 => 'id');\n $idvals = array(0 => $this->ID);\n $rs = $DBA->selectQuery(DBUSERTABLE, $fields, $idfields, $idvals);\n\n if (!isset($rs[2]))\n {\n while ($res = mysql_fetch_array($rs[0]))\n {\n $this->setUserVar('Username', $res['username']);\n $this->setUserVar('Title', $res['title']);\n $this->setUserVar('FirstName', $res['first_name']);\n $this->setUserVar('LastName', $res['last_name']);\n $this->setUserVar('ContactEmail', $res['contactemail']);\n $this->setUserVar('ContactTelephone', $res['contacttelephone']);\n $this->setUserVar('NewsletterSubscriber', $res['newsletter']);\n $this->setUserVar('Area', $res['pcode']);\n $this->setUserVar('StoreOwner', $res['store_owner']);\n $this->setUserVar('House', $res['house']);\n $this->setUserVar('Street', $res['street']);\n $this->setUserVar('Town', $res['town']);\n $this->setUserVar('County', $res['county']);\n $this->setUserVar('PCode', $res['pcode']);\n $this->setUserVar('Long', $res['geolong']);\n $this->setUserVar('Lat', $res['geolat']);\n $this->setUserVar('Avatar', $res['avatar']);\n $this->setUserVar('Mobile', $res['mobile']);\n $this->setUserVar('DMOptOut', $res['optout']);\n $this->formatAddress();\n $this->formatEmail();\n if ($this->Lat == '')\n {\n $this->GeoLocate();\n }\n }\n }\n }", "function ambil_data(){\n\t\treturn $this->db->get('user');\n\t}", "function getDeviceDetailsfunction($userId){\r\n global $pdo;\t\r\n\t\t$select = $pdo->prepare(\"SELECT device_registry.* \r\n FROM users \r\n LEFT JOIN device_registry ON users.device=device_registry.id \r\n\t\t\t\t WHERE users.id = ?\");\r\n\t\t$select->execute(array($userId));\r\n\t\t$result_array = $select->fetch(PDO::FETCH_ASSOC);\r\n\t\treturn $result_array;\r\n\t}", "public function adminInfo($id){\n $info = DB::table('admins')->where('uid', $id)->first();\n return $info;\n }", "public function getVendor()\n {\n return $this->hasOne(VendorServiceExt::className(), ['vendor_id' => 'vendor_id']);\n }", "public function getJoueur()\n\t{\n\t\t$cnx=new database();\n\t\t\n\t\t$req = $cnx->_db->query('SELECT * FROM joueurs');\t\n\t\t// $req_q=$req->fetch();\t\t\n\t\treturn $req;\n\t}", "public function read_single_user() {\n //Create query\n $query = 'SELECT vendor_id, latitude, longitude, time, type FROM ' . $this->table_name . ' WHERE vendor_id = ?';\n\n //Prepare statement\n $stmt = $this->conn->prepare($query);\n //Clean lowercase.\n //Bind UID\n $stmt->bindParam(1, $this->vendor_id);\n\n //Execute query\n $stmt->execute();\n\n return $stmt;\n }", "public function selectuser(){\r\n\t\t$query = \"SELECT * FROM users\";\r\n\t\t$add_query = parent::get_results($query);\r\n\t\t\r\n\t\treturn $add_query;\r\n\t\t// echo '<pre>';\r\n\t\t// print_r( $add_query );\r\n\t\t// echo '</pre>';\r\n\t\t// exit;\r\n\t}", "function _getFromGebruikersDb($user)\n {\n $conn = getConn();\n $sql = \"SELECT Gebruikersnaam, Wachtwoord, Rol FROM Gebruiker WHERE \nGebruikersnaam = ?;\";\n $stmt = sqlsrv_prepare($conn, $sql, array($user));\n if (!$stmt) {\n die(print_r(sqlsrv_errors(), true));\n }\n sqlsrv_execute($stmt);\n if (sqlsrv_execute($stmt)) {\n while ($row = sqlsrv_fetch_array($stmt, SQLSRV_FETCH_ASSOC)) {\n $this->name_db = $row['Gebruikersnaam'];\n $this->pass_db = $row['Wachtwoord'];\n $this->role_db = $row['Rol'];\n }\n }\n }", "public function getDr(){\n $data = $this->db->get_where('user', array('Level' => 'Dokter'));\n\n return $data;\n }", "public function seniorContributors()\n {\n $query = \"SELECT identifier FROM \".$this->_name.\" WHERE status='Active' AND profile_type='senior'\";\n if(($result = $this->getQuery($query,true)) != NULL)\n {\n for($i=0; $i<count($result); $i++)\n {\n $result[$i]= $result[$i]['identifier'];\n }\n return $result;\n }\n else\n return \"NO\";\n }", "private function _get_info() {\n\n\t\t/* Grab the basic information from the catalog and return it */\n\t\t$sql = \"SELECT * FROM `access_list` WHERE `id`='\" . Dba::escape($this->id) . \"'\";\n\t\t$db_results = Dba::query($sql);\n\n\t\t$results = Dba::fetch_assoc($db_results);\n\n\t\treturn $results;\n\n\t}", "function get_pengguna(){\n return $this->db->get('tb_user');\n}", "function getUserDetails(){\n if(empty($this->userid)){\n return null;\n } \n $userDetailsQuery = \"SELECT * FROM da_userMaster WHERE da_userMaster.username = '$this->userid'\"; \n $dbqry = new dbquery($userDetailsQuery, $this->connid);\n $user = $dbqry->getrowassocarray();\n return $user;\n }", "public function get_select() {\n return $this->db->get('ws_users'); \n }", "function user_details() {\r\n\t\t\t$query = $this->pdo->prepare(\"select * from user_account\");\r\n\t\t\t$query->execute();\r\n\t\t\treturn $query->fetchAll();\r\n\t\t}", "public function getPerson() {\n return $this->getPersoner()->getSingle();\n }", "public function getAdminProfile() {\n $this->db->select('*');\n $this->db->where('status', 1);\n $query = $this->db->get('tbl_admin');\n if ($query->num_rows() > 0) {\n return $query->row_array();\n }\n }", "protected function getTrainer()\n {\n return $this->selectOneByParameter();\n }", "function get_designers() {\n return $this->mysqli->query(\"SELECT `product_variations`.*, `products`.*, `designers`.`name` AS 'des_name' FROM `product_variations` JOIN `products` ON `products`.`product_id` = `product_variations`.`product_id` JOIN `designers` ON `designers`.`designer_id` = `products`.`designer_id` ORDER BY `designers`.`name` ASC, `product_variations`.`price` ASC\");\n }", "private function get_admins_info() {\n $stm=$this->uSup->get_com_admins_to_notify_about_requests(\"user_id\",$this->company_id);\n\n $q_user_id=\"(1=0 \";\n /** @noinspection PhpUndefinedMethodInspection */\n while($admin=$stm->fetch(PDO::FETCH_OBJ)) {\n $q_user_id.=\" OR u235_users.user_id='\".$admin->user_id.\"' \";\n }\n $q_user_id.=\")\";\n try {\n /** @noinspection PhpUndefinedMethodInspection */\n $stm=$this->uFunc->pdo(\"uAuth\")->prepare(\"SELECT DISTINCT\n firstname,\n secondname,\n email\n FROM\n u235_users\n JOIN \n u235_usersinfo\n ON\n u235_users.user_id=u235_usersinfo.user_id AND\n u235_usersinfo.status=u235_users.status\n WHERE\n \" .$q_user_id. \" AND \n u235_users.status='active' AND\n u235_usersinfo.site_id=:site_id\n \");\n $site_id=site_id;\n /** @noinspection PhpUndefinedMethodInspection */$stm->bindParam(':site_id', $site_id,PDO::PARAM_INT);\n /** @noinspection PhpUndefinedMethodInspection */$stm->execute();\n }\n catch(PDOException $e) {$this->uFunc->error('120'/*.$e->getMessage()*/);}\n\n return $stm;\n }" ]
[ "0.6846746", "0.6811631", "0.6795779", "0.6535069", "0.6485643", "0.6257134", "0.62479734", "0.6166037", "0.60660034", "0.5952285", "0.59144306", "0.5890355", "0.5744496", "0.5699739", "0.5657502", "0.56133944", "0.5611225", "0.56018335", "0.55920464", "0.55579525", "0.5526165", "0.54973084", "0.54799694", "0.5452507", "0.54364246", "0.5415453", "0.5412754", "0.5410884", "0.53982276", "0.53882885", "0.53785694", "0.537623", "0.53728145", "0.5369252", "0.5364944", "0.5355817", "0.53519607", "0.5351414", "0.5326678", "0.53250384", "0.5317242", "0.5299912", "0.52910846", "0.52810115", "0.5279542", "0.52630144", "0.5261309", "0.52604383", "0.52555233", "0.5240372", "0.52395076", "0.5238584", "0.52333635", "0.5228936", "0.52271277", "0.52236044", "0.5223343", "0.52233416", "0.521935", "0.5204865", "0.51987153", "0.51904684", "0.518943", "0.5187055", "0.51869553", "0.5181885", "0.517463", "0.51736045", "0.5172571", "0.51711607", "0.51703286", "0.51698864", "0.51694864", "0.51648754", "0.5164189", "0.51632833", "0.5162571", "0.5159442", "0.5158615", "0.51543397", "0.5150358", "0.5148982", "0.5139118", "0.5133671", "0.5128824", "0.51240546", "0.51163685", "0.5115309", "0.51128894", "0.5111021", "0.51087147", "0.51086086", "0.510748", "0.51049143", "0.5099405", "0.5092179", "0.5089386", "0.50882465", "0.50865173", "0.508558" ]
0.6016552
9
Run the database seeds.
public function run() { DB::table('transactions')->insert([ [ 'bill_id' => 1, 'income' => true, 'amount' => 10000, 'from' => 'Alapítvány', 'description' => 'Ennyi támogatást kaptunk a képzés kezdetére. Mindenről kell számla!!!' ], [ 'bill_id' => 1, 'income' => false, 'amount' => 800, 'from' => 'AnnaKrisz ABC', 'description' => 'Nasi a 2. képzés alkalomra' ], [ 'bill_id' => 1, 'income' => false, 'amount' => 3500, 'from' => 'Gipsz Jakab', 'description' => 'Ennyit basztunk el pólókra' ], [ 'bill_id' => 2, 'income' => false, 'amount' => 500, 'from' => 'Adó', 'description' => 'Lenyúlta a NAV' ], ]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n // $this->call(UserTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(TagTableSeeder::class);\n // $this->call(PostTagTableSeeder::class);\n\n /*AB - use faker to populate table see file ModelFactory.php */\n factory(App\\Editeur::class, 40) ->create();\n factory(App\\Auteur::class, 40) ->create();\n factory(App\\Livre::class, 80) ->create();\n\n for ($i = 1; $i < 41; $i++) {\n $number = rand(2, 8);\n for ($j = 1; $j <= $number; $j++) {\n DB::table('auteur_livre')->insert([\n 'livre_id' => rand(1, 40),\n 'auteur_id' => $i\n ]);\n }\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('post')->insert(\n [\n 'title' => 'Test Post1',\n 'desc' => str_random(100).\" post1\",\n 'alias' => 'test1',\n 'keywords' => 'test1',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post2',\n 'desc' => str_random(100).\" post2\",\n 'alias' => 'test2',\n 'keywords' => 'test2',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post3',\n 'desc' => str_random(100).\" post3\",\n 'alias' => 'test3',\n 'keywords' => 'test3',\n ]\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n\n factory('App\\User', 10 )->create();\n\n $users= \\App\\User::all();\n $users->each(function($user){ factory('App\\Category', 1)->create(['user_id'=>$user->id]); });\n $users->each(function($user){ factory('App\\Tag', 3)->create(['user_id'=>$user->id]); });\n\n\n $users->each(function($user){\n factory('App\\Post', 10)->create([\n 'user_id'=>$user->id,\n 'category_id'=>rand(1,20)\n ]\n );\n });\n\n $posts= \\App\\Post::all();\n $posts->each(function ($post){\n\n $post->tags()->attach(array_unique([rand(1,20),rand(1,20),rand(1,20)]));\n });\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => '[email protected]', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n UsersLevel::create([\n 'name' => 'Administrator'\n ]);\n\n UsersLevel::create([\n 'name' => 'User'\n ]);\n\n User::create([\n 'username' => 'admin',\n 'password' => bcrypt('admin123'),\n 'level_id' => 1,\n 'fullname' => \"Super Admin\",\n 'email'=> \"[email protected]\"\n ]);\n\n\n \\App\\CategoryPosts::create([\n 'name' =>'Paket Trip'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' =>'Destinasi Kuliner'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Event'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Profil'\n ]);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n $faker = Faker::create('id_ID');\n /**\n * Generate fake author data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('author')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Generate fake publisher data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('publisher')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Seeding payment method\n */\n DB::table('payment')->insert([\n ['name' => 'Mandiri'],\n ['name' => 'BCA'],\n ['name' => 'BRI'],\n ['name' => 'BNI'],\n ['name' => 'Pos Indonesia'],\n ['name' => 'BTN'],\n ['name' => 'Indomaret'],\n ['name' => 'Alfamart'],\n ['name' => 'OVO'],\n ['name' => 'Cash On Delivery']\n ]);\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n // MyList::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 3; $i++) {\n MyList::create([\n 'title' => 'List-'.($i+1),\n 'color' => $faker->sentence,\n 'icon' => $faker->randomDigitNotNull,\n 'index' => $faker->randomDigitNotNull,\n 'user_id' => 1,\n ]);\n }\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Products::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few products in our database:\n for ($i = 0; $i < 50; $i++) {\n Products::create([\n 'name' => $faker->word,\n 'sku' => $faker->randomNumber(7, false),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Pablo Rosales',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'status' => 1,\n 'role_id' => 1,\n 'movil' => 0\n ]);\n\n User::create([\n 'name' => 'Usuario Movil',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'status' => 1,\n 'role_id' => 3,\n 'movil' => 1\n ]);\n\n Roles::create([\n 'name' => 'Administrador'\n ]);\n Roles::create([\n 'name' => 'Operaciones'\n ]);\n Roles::create([\n 'name' => 'Comercial'\n ]);\n Roles::create([\n 'name' => 'Aseguramiento'\n ]);\n Roles::create([\n 'name' => 'Facturación'\n ]);\n Roles::create([\n 'name' => 'Creditos y Cobros'\n ]);\n\n factory(App\\Customers::class, 100)->create();\n }", "public function run()\n {\n // php artisan db:seed --class=StoreTableSeeder\n\n foreach(range(1,20) as $i){\n $faker = Faker::create();\n Store::create([\n 'name' => $faker->name,\n 'desc' => $faker->text,\n 'tags' => $faker->word,\n 'address' => $faker->address,\n 'longitude' => $faker->longitude($min = -180, $max = 180),\n 'latitude' => $faker->latitude($min = -90, $max = 90),\n 'created_by' => '1'\n ]);\n }\n\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => '[email protected]',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create([\n 'name' => 'Qwerty',\n 'email' => '[email protected]',\n 'password' => bcrypt('secretpassw'),\n ]);\n\n factory(User::class, 59)->create([\n 'password' => bcrypt('secretpassw'),\n ]);\n\n for ($i = 1; $i < 11; $i++) {\n factory(Category::class)->create([\n 'name' => 'Category ' . $i,\n ]);\n }\n\n for ($i = 1; $i < 101; $i++) {\n factory(Product::class)->create([\n 'name' => 'Product ' . $i,\n ]);\n }\n }", "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> '[email protected]',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1,5) as $index) {\n Lista::create([\n 'name' => $faker->sentence(2),\n 'description' => $faker->sentence(10), \n ]);\n } \n\n foreach (range(1,20) as $index) {\n $n = $faker->sentence(2);\n \tTarea::create([\n \t\t'name' => $n,\n \t\t'description' => $faker->sentence(10),\n 'lista_id' => $faker->numberBetween(1,5),\n 'slug' => Str::slug($n),\n \t\t]);\n } \n }", "public function run()\n {\n $faker = Faker::create('lt_LT');\n\n DB::table('users')->insert([\n 'name' => 'user',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n DB::table('users')->insert([\n 'name' => 'user2',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n\n foreach (range(1,100) as $val)\n DB::table('authors')->insert([\n 'name' => $faker->firstName(),\n 'surname' => $faker->lastName(),\n \n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n Flight::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 100; $i++) {\n\n\n Flight::create([\n 'flightNumber' => $faker->randomNumber(5),\n 'depAirport' => $faker->city,\n 'destAirport' => $faker->city,\n 'reservedWeight' => $faker->numberBetween(1000 - 10000),\n 'deptTime' => $faker->dateTime('now'),\n 'arrivalTime' => $faker->dateTime('now'),\n 'reservedVolume' => $faker->numberBetween(1000 - 10000),\n 'airlineName' => $faker->colorName,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(UserSeeder::class);\n\n Medicamento::factory(50)->create();\n Reporte::factory(5)->create();\n Cliente::factory(200)->create();\n Asigna_valor::factory(200)->create();\n Carga::factory(200)->create();\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n TicketSeeder::class\n ]);\n\n DB::table('departments')->insert([\n 'abbr' => 'IT',\n 'name' => 'Information Technologies',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'email_verified_at' => Carbon::now(),\n 'password' => Hash::make('admin'),\n 'department_id' => 1,\n 'avatar' => 'default.png',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => 1,\n 'user_id' => 1\n ]);\n }", "public function run()\n {\n \\App\\Models\\Article::factory(20)->create();\n \\App\\Models\\Category::factory(5)->create();\n \\App\\Models\\Comment::factory(40)->create();\n\n \\App\\Models\\User::create([\n \"name\"=>\"Alice\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n \\App\\Models\\User::create([\n \"name\"=>\"Bob\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class,3)->create()->each(\n \tfunction($user)\n \t{\n \t\t$user->questions()\n \t\t->saveMany(\n \t\t\tfactory(App\\Question::class, rand(2,6))->make()\n \t\t)\n ->each(function ($q) {\n $q->answers()->saveMany(factory(App\\Answer::class, rand(1,5))->make());\n })\n \t}\n );\n }\n}", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "public function run()\n\t{\n\t\tDB::table('libros')->truncate();\n\n\t\t$faker = Faker\\Factory::create();\n\n\t\tfor ($i=0; $i < 10; $i++) { \n\t\t\tLibro::create([\n\n\t\t\t\t'titulo'\t\t=> $faker->text(40),\n\t\t\t\t'isbn'\t\t\t=> $faker->numberBetween(100,999),\n\t\t\t\t'precio'\t\t=> $faker->randomFloat(2,3,150),\n\t\t\t\t'publicado'\t\t=> $faker->numberBetween(0,1),\n\t\t\t\t'descripcion'\t=> $faker->text(400),\n\t\t\t\t'autor_id'\t\t=> $faker->numberBetween(1,3),\n\t\t\t\t'categoria_id'\t=> $faker->numberBetween(1,3)\n\n\t\t\t]);\n\t\t}\n\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('libros')->insert($libros);\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 10)->create()->each(function ($user) {\n // Seed the relation with 5 purchases\n // $videos = factory(App\\Video::class, 5)->make();\n // $user->videos()->saveMany($videos);\n // $user->videos()->each(function ($video){\n // \t$video->videometa()->save(factory(App\\VideoMeta::class)->make());\n // \t// :( \n // });\n factory(App\\User::class, 10)->create()->each(function ($user) {\n\t\t\t factory(App\\Video::class, 5)->create(['user_id' => $user->id])->each(function ($video) {\n\t\t\t \tfactory(App\\VideoMeta::class, 1)->create(['video_id' => $video->id]);\n\t\t\t // $video->videometa()->save(factory(App\\VideoMeta::class)->create(['video_id' => $video->id]));\n\t\t\t });\n\t\t\t});\n\n });\n }", "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "public function run()\n {\n $this->call([\n CountryTableSeeder::class,\n ProvinceTableSeeder::class,\n TagTableSeeder::class\n ]);\n\n User::factory()->count(10)->create();\n Category::factory()->count(5)->create();\n Product::factory()->count(20)->create();\n Section::factory()->count(5)->create();\n Bundle::factory()->count(20)->create();\n\n $bundles = Bundle::all();\n // populate bundle-product table (morph many-to-many)\n Product::all()->each(function ($product) use ($bundles) {\n $product->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray(),\n ['default_quantity' => rand(1, 10)]\n );\n });\n // populate bundle-tags table (morph many-to-many)\n Tag::all()->each(function ($tag) use ($bundles) {\n $tag->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray()\n );\n });\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker=Faker\\Factory::create();\n\n for($i=0;$i<100;$i++){\n \tApp\\Blog::create([\n \t\t'title' => $faker->catchPhrase,\n 'description' => $faker->text,\n 'showns' =>true\n \t\t]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(PermissionsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n $this->call(BusinessTableSeeder::class);\n $this->call(PrinterTableSeeder::class);\n factory(App\\Tag::class,10)->create();\n factory(App\\Category::class,10)->create();\n factory(App\\Subcategory::class,50)->create();\n factory(App\\Provider::class,10)->create();\n factory(App\\Product::class,24)->create()->each(function($product){\n\n $product->images()->saveMany(factory(App\\Image::class, 4)->make());\n\n });\n\n\n factory(App\\Client::class,10)->create();\n }", "public function run()\n {\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'name' => $faker->sentence,\n 'sku' => $faker->paragraph,\n 'price' => $faker->number,\n ]);\n }\n }", "public function run()\n {\n Storage::deleteDirectory('public/products');\n Storage::makeDirectory('public/products');\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n $this->call(ProductSeeder::class);\n Order::factory(4)->create();\n Order_Detail::factory(4)->create();\n Size::factory(100)->create();\n }", "public function run()\n {\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Doctor::factory(25)->create();\n Patient::factory(50)->create();\n Status::factory(3)->create();\n Appointment::factory(100)->create();\n }", "public function run()\n\t{\n\t\t\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$faker = \\Faker\\Factory::create();\n\n\t\tTodolist::truncate();\n\n\t\tforeach(range(1, 50) as $index)\n\t\t{\n\n\t\t\t$user = User::create([\n\t\t\t\t'name' => $faker->name,\n\t\t\t\t'email' => $faker->email,\n\t\t\t\t'password' => 'password',\n\t\t\t\t'confirmation_code' => mt_rand(0, 9),\n\t\t\t\t'confirmation' => rand(0,1) == 1\n\t\t\t]);\n\n\t\t\t$list = Todolist::create([\n\t\t\t\t'name' => $faker->sentence(2),\n\t\t\t\t'description' => $faker->sentence(4),\n\t\t\t]);\n\n\t\t\t// BUILD SOME TASKS FOR EACH LIST ITEM\n\t\t\tforeach(range(1, 10) as $index) \n\t\t\t{\n\t\t\t\t$task = new Task;\n\t\t\t\t$task->name = $faker->sentence(2);\n\t\t\t\t$task->description = $faker->sentence(4);\n\t\t\t\t$list->tasks()->save($task);\n\t\t\t}\n\n\t\t}\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1'); \n\n\t}", "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n \\App\\User::create([\n 'name'=>'PAPE SAMBA NDOUR',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('Admin1122'),\n ]);\n\n $faker = Faker::create();\n\n for ($i = 0; $i < 100 ; $i++)\n {\n $firstName = $faker->firstName;\n $lastName = $faker->lastName;\n $niveau = \\App\\Niveau::inRandomOrder()->first();\n \\App\\Etudiant::create([\n 'prenom'=>$firstName,\n 'nom'=>$lastName,\n 'niveau_id'=>$niveau->id\n ]);\n }\n\n\n }", "public function run()\n {\n //\n DB::table('foods')->delete();\n\n Foods::create(array(\n 'name' => 'Chicken Wing',\n 'author' => 'Bambang',\n 'overview' => 'a deep-fried chicken wing, not in spicy sauce'\n ));\n\n Foods::create(array(\n 'name' => 'Beef ribs',\n 'author' => 'Frank',\n 'overview' => 'Slow baked beef ribs rubbed in spices'\n ));\n\n Foods::create(array(\n 'name' => 'Ice cream',\n 'author' => 'Lou',\n 'overview' => ' A sweetened frozen food typically eaten as a snack or dessert.'\n ));\n\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 3)->create();\n factory(App\\Models\\Category::class, 3)\n ->create()\n ->each(function ($u) {\n $u->courses()->saveMany(factory(App\\Models\\Course::class,3)->make())->each(function ($c){\n $c->exams()->saveMany(factory(\\App\\Models\\Exam::class,3)->make())->each(function ($e){\n $e->questions()->saveMany(factory(\\App\\Models\\Question::class,4)->make())->each(function ($q){\n $q->answers()->saveMany(factory(\\App\\Models\\Answer::class,4)->make())->each(function ($a){\n $a->correctAnswer()->save(factory(\\App\\Models\\Correct_answer::class)->make());\n });\n });\n });\n });\n\n });\n\n }", "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n UserSeeder::class,\n ]);\n\n \\App\\Models\\Category::factory(4)->create();\n \\App\\Models\\View::factory(6)->create();\n \\App\\Models\\Room::factory(8)->create();\n \n $rooms = \\App\\Models\\Room::all();\n // \\App\\Models\\User::all()->each(function ($user) use ($rooms) { \n // $user->rooms()->attach(\n // $rooms->random(rand(1, \\App\\Models\\Room::max('id')))->pluck('id')->toArray()\n // ); \n // });\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => '[email protected]']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'[email protected]',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','[email protected]')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => '[email protected]']);\n\n factory(Category::class, 5)->create();\n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n \n User::factory(1)->create([\n 'rol'=>'EPS'\n ]);\n Person::factory(10)->create();\n $this->call(EPSSeeder::class);\n $this->call(OfficialSeeder::class);\n $this->call(VVCSeeder::class);\n $this->call(VaccineSeeder::class);\n }", "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "public function run()\n {\n $this->call([\n LanguagesTableSeeder::class,\n ListingAvailabilitiesTableSeeder::class,\n ListingTypesTableSeeder::class,\n RoomTypesTableSeeder::class,\n AmenitiesTableSeeder::class,\n UsersTableSeeder::class,\n UserLanguagesTableSeeder::class,\n ListingsTableSeeder::class,\n WishlistsTableSeeder::class,\n StaysTableSeeder::class,\n GuestsTableSeeder::class,\n TripsTableSeeder::class,\n ReviewsTableSeeder::class,\n RatingsTableSeeder::class,\n PopularDestinationsTableSeeder::class,\n ImagesTableSeeder::class,\n ]);\n\n // factory(App\\User::class, 5)->states('host')->create();\n // factory(App\\User::class, 10)->states('hostee')->create();\n\n // factory(App\\User::class, 10)->create();\n // factory(App\\Models\\Listing::class, 30)->create();\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "public function run()\n {\n\n $this->call(UserSeeder::class);\n factory(Empresa::class,10)->create();\n factory(Empleado::class,50)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => '[email protected]',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Russell'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Bitfumes'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Paul'\n ]);\n }", "public function run()\n {\n $user_ids = [1,2,3];\n $faker = app(\\Faker\\Generator::class);\n $posts = factory(\\App\\Post::class)->times(50)->make()->each(function($post) use ($user_ids,$faker){\n $post->user_id = $faker->randomElement($user_ids);\n });\n \\App\\Post::insert($posts->toArray());\n }", "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "public function run()\n\t{\n\t\t$this->call(ProductsTableSeeder::class);\n\t\t$this->call(CategoriesTableSeeder::class);\n\t\t$this->call(BrandsTableSeeder::class);\n\t\t$this->call(ColorsTableSeeder::class);\n\n\t\t$products = \\App\\Product::all();\n \t$categories = \\App\\Category::all();\n \t$brands = \\App\\Brand::all();\n \t$colors = \\App\\Color::all();\n\n\t\tforeach ($products as $product) {\n\t\t\t$product->colors()->sync($colors->random(3));\n\n\t\t\t$product->category()->associate($categories->random(1)->first());\n\t\t\t$product->brand()->associate($brands->random(1)->first());\n\n\t\t\t$product->save();\n\t\t}\n\n\t\t// for ($i = 0; $i < count($products); $i++) {\n\t\t// \t$cat = $categories[rand(0,5)];\n\t\t// \t$bra = $brands[rand(0,7)];\n\t\t// \t$cat->products()->save($products[$i]);\n\t\t// \t$bra->products()->save($products[$i]);\n\t\t// }\n\n\t\t// $products = factory(App\\Product::class)->times(20)->create();\n\t\t// $categories = factory(App\\Category::class)->times(6)->create();\n\t\t// $brands = factory(App\\Brand::class)->times(8)->create();\n\t\t// $colors = factory(App\\Color::class)->times(15)->create();\n\t}", "public function run()\n {\n /*$this->call(UsersTableSeeder::class);\n $this->call(GroupsTableSeeder::class);\n $this->call(TopicsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);*/\n DB::table('users')->insert([\n 'name' => 'pkw',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'type' => '1'\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = Faker::create();\n foreach (range(1,200) as $index) {\n DB::table('users')->insert([\n 'name' => $faker->name,\n 'email' => $faker->email,\n 'phone' => $faker->randomDigitNotNull,\n 'address'=> $faker->streetAddress,\n 'password' => bcrypt('secret'),\n ]);\n }\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n echo PHP_EOL , 'seeding roles...';\n\n Role::create(\n [\n 'name' => 'Admin',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Principal',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Teacher',\n 'deletable' => false,\n ]\n );\n\n Role::create(\n [\n 'name' => 'Student',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Parents',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Accountant',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Librarian',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Receptionist',\n 'deletable' => false,\n ]\n );\n\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 5; $i++) {\n Runner::create([\n 'external_id' => $faker->uuid,\n 'name' => $faker->name,\n 'race_id' =>rand(1,5),\n 'age' => rand(30, 45),\n 'sex' => $faker->randomElement(['male', 'female']),\n 'color' => $faker->randomElement(['#ecbcb4', '#d1a3a4']),\n ]);\n }\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "public function run()\n {\n Eloquent::unguard();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // $this->call([\n // CountriesTableSeeder::class,\n // ]);\n\n factory(App\\User::class, 100)->create();\n factory(App\\Type::class, 10)->create();\n factory(App\\Item::class, 100)->create();\n factory(App\\Order::class, 1000)->create();\n\n $items = App\\Item::all();\n\n App\\Order::all()->each(function($order) use ($items) {\n\n $n = rand(1, 10);\n\n $order->items()->attach(\n $items->random($n)->pluck('id')->toArray()\n , ['quantity' => $n]);\n\n $order->total = $order->items->sum(function($item) {\n return $item->price * $item->pivot->quantity;\n });\n\n $order->save();\n\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'izzanni',\n \n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'aina',\n\n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'sab',\n\n ]\n );\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n //Acá se define lo que el seeder va a hacer.\n //insert() para insertar datos.\n //Array asociativo. La llave es el nombre de la columna.\n// DB::table('users')->insert([\n// //Para un solo usuario.\n// 'name' => 'Pedrito Perez',\n// 'email' => '[email protected]',\n// 'password' => bcrypt('123456')\n// ]);//Se indica el nombre de la tabla.\n\n //Crea 50 usuarios (sin probar)\n// factory(App\\User::class, 50)->create()->each(function($u) {\n// $u->posts()->save(factory(App\\Post::class)->make());\n// });\n\n factory(App\\User::class, 10)->create(); //Así se ejecuta el model factory creado en ModelFactory.php\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n //nhập liệu mẫu cho bảng users\n DB::table('users')->insert([\n \t['id'=>'1001', 'name'=>'Phan Thị Hiền', 'email'=>'[email protected]', 'password'=>'123456', 'isadmin'=>1],\n \t['id'=>'1002', 'name'=>'Phan Thị Hà', 'email'=>'[email protected]', 'password'=>'111111', 'isadmin'=>0]\n ]);\n\n\n //nhập liệu mẫu cho bảng suppliers\n DB::table('suppliers')->insert([\n \t['name'=>'FPT', 'address'=>'151 Hùng Vương, TP. Đà Nẵng', 'phonenum'=>'0971455395'],\n \t['name'=>'Điện Máy Xanh', 'address'=>'169 Phan Châu Trinh, TP. Đà Nẵng', 'phonenum'=>'0379456011']\n ]);\n\n\n //Bảng phiếu bảo hành\n }", "public function run()\n {\n \t// DB::table('categories')->truncate();\n // factory(App\\Models\\Category::class, 10)->create();\n Schema::disableForeignKeyConstraints();\n Category::truncate();\n $faker = Faker\\Factory::create();\n\n $categories = ['SAMSUNG','NOKIA','APPLE','BLACK BERRY'];\n foreach ($categories as $key => $value) {\n Category::create([\n 'name'=>$value,\n 'description'=> 'This is '.$value,\n 'markup'=> rand(10,100),\n 'category_id'=> null,\n 'UUID' => $faker->uuid,\n ]);\n }\n }" ]
[ "0.8013876", "0.79804534", "0.7976992", "0.79542726", "0.79511505", "0.7949612", "0.794459", "0.7942486", "0.7938189", "0.79368967", "0.79337025", "0.78924936", "0.78811055", "0.78790957", "0.78787595", "0.787547", "0.7871811", "0.78701615", "0.7851422", "0.7850352", "0.7841468", "0.7834583", "0.7827792", "0.7819104", "0.78088796", "0.7802872", "0.7802348", "0.78006834", "0.77989215", "0.7795819", "0.77903426", "0.77884805", "0.77862066", "0.7778816", "0.7777486", "0.7765202", "0.7762492", "0.77623445", "0.77621746", "0.7761383", "0.77606887", "0.77596676", "0.7757001", "0.7753607", "0.7749522", "0.7749292", "0.77466977", "0.7729947", "0.77289546", "0.772796", "0.77167094", "0.7714503", "0.77140456", "0.77132195", "0.771243", "0.77122366", "0.7711113", "0.77109736", "0.7710777", "0.7710086", "0.7705484", "0.770464", "0.7704354", "0.7704061", "0.77027386", "0.77020216", "0.77008796", "0.7698617", "0.76985973", "0.76973504", "0.7696405", "0.7694293", "0.7692694", "0.7691264", "0.7690576", "0.76882726", "0.7687433", "0.7686844", "0.7686498", "0.7685065", "0.7683827", "0.7679184", "0.7678287", "0.76776296", "0.76767945", "0.76726556", "0.76708084", "0.76690495", "0.766872", "0.76686716", "0.7666299", "0.76625943", "0.7662227", "0.76613766", "0.7659881", "0.7656644", "0.76539344", "0.76535016", "0.7652375", "0.7652313", "0.7652022" ]
0.0
-1
This method will convert a meeting to an array that can be used for an APIrequest
public function toArrayForApi() { $return = array(); if ($this->getMeeting()) { $return['meeting_id'] = $this->getMeeting(); } if ($this->getContact()) { $return['contact_id'] = $this->getContact(); } return $return; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function GetMeetingIDArray()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n return $this->_meeting_id_array;\n }", "function defineMeetingTime(){\r\n\r\n\t$SQL=\"select * from agenda where event<>'' order by meetingTime\";\r\n\t$agendaArray=get_obj_info($SQL , array(\"meetingTime\",\"event\"));\r\n\tfor($i=0;$i<count($agendaArray);$i++){\r\n\t\t$meetingTime = $agendaArray[$i]->meetingTime;\r\n\t\t$meetingTime_array[$i] = strftime(\"%H:%M\", mkdate($meetingTime));\r\n\t}\r\n\t\r\n\treturn $meetingTime_array;\r\n}", "public function toArray($request)\n {\n $type = ArrHelper::searchByKey(ArrHelper::getTransList('types', 'meeting'), 'uuid', $this->type);\n\n return [\n 'uuid' => $this->uuid,\n 'title' => $this->title,\n 'agenda' => $this->agenda,\n 'type' => $type,\n 'category' => new Option($this->whenLoaded('category')),\n 'description' => $this->description,\n 'created_at' => CalHelper::toDateTime($this->created_at),\n 'updated_at' => CalHelper::toDateTime($this->updated_at)\n ];\n }", "public function getMeetingInfo($meeting)\n {\n if (! $meeting instanceof GetMeetingInfoParameters) {\n $meeting = $this->initGetMeetingInfo($meeting);\n }\n\n $this->response = $this->bbb->getMeetingInfo($meeting);\n if ($this->response->success()) {\n return collect(XmlToArray($this->response->getRawXml()));\n }\n\n return collect([]);\n }", "public function all()\n {\n $this->response = $this->bbb->getMeetings();\n if ($this->response->success()) {\n if (! is_null($this->response->getRawXml()->meetings->meeting) && count($this->response->getRawXml()->meetings->meeting) > 0) {\n $meetings = [];\n foreach ($this->response->getRawXml()->meetings->meeting as $meeting) {\n $meetings[] = XmlToArray($meeting);\n }\n\n return collect(XmlToArray($meetings));\n }\n }\n\n return collect([]);\n }", "function getParticipantsForMeetings($array)\n {\n $result = array();\n for ($i=0; $i < count($array); $i++) {\n $bookingID = $array[$i][\"id\"];\n\n $obj = $array[$i];\n\n $query = $this->db->query(\"SELECT bookingID, users.* from booking_invitations join users on users.id = booking_invitations.userID where bookingID = $bookingID\");\n if($query->num_rows()>0)\n {\n $obj[\"users\"] = $query->result_array();\n\n }\n else\n {\n $obj[\"users\"] = array();\n\n }\n\n array_push($result, $obj);\n }\n\n return $result;\n }", "function bbbAtendanceLog(){\n $method = 'getMeetings';\n $result = fetchFromServer($method, $data);\n if(!empty($result->meetings->meeting)){\n $meetings = $result->meetings->meeting;\n $check = is_array($meetings);\n if ($check){\n foreach ($meetings as $meeting){\n echo \"mnoho meetingu\";\n bbbWriteMeetings($meeting);\n }\n }else{\n $meeting = $meetings;\n echo \"jeden meeting\";\n bbbWriteMeetings($meeting);\n\n }\n }\n}", "public function getActiveMeetings() {\n $requestaction = 'getMeetings';\n $meetings = [];\n\n $requeststring = \"\";\n $checksum = sha1($requestaction . $requeststring . $this->bbbserversecret);\n\n if(get_config('local_intelliboard', 'bbb_debug')) {\n ob_start();\n $curl = new \\curl(['debug'=>true]);\n $out = fopen('php://output', 'w');\n $options['CURLOPT_VERBOSE'] = true;\n $options['CURLOPT_STDERR'] = $out;\n } else {\n $curl = new \\curl();\n }\n\n $res = $curl->get($this->apiendpoint . \"/{$requestaction}\", [\n 'checksum' => $checksum\n ]);\n\n if(get_config('local_intelliboard', 'bbb_debug')) {\n fclose($out);\n echo '<pre>';\n var_dump(ob_get_clean());\n }\n\n $xml = simplexml_load_string($res);\n\n if(isset($xml->meetings->meeting)) {\n $meetings = $xml->meetings->meeting;\n }\n\n return $meetings;\n }", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'user' => $this->user->toArray(),\n 'meeting_room' => $this->meetingRoom->toArray(),\n 'occupy_at' => $this->occupy_at->format('Ymd'),\n 'start_at' => $this->start_at->format('H:i'),\n 'end_at' => $this->end_at->format('H:i')\n ];\n }", "function to_array($person = false){\r\n\t\t$booking = array();\r\n\t\t//Core Event Data\r\n\t\t$booking = parent::to_array();\r\n\t\t//Location Data\r\n\t\tif($person && is_object($this->person)){\r\n\t\t\t$person = $this->person->to_array();\r\n\t\t\t$booking = array_merge($booking, $person);\r\n\t\t}\r\n\t\treturn $booking;\r\n\t}", "public function reservationsArray(){\n\t\t$reponse = new Reponse();\n\t\t$date=new Zend_Date();\n\t\t$dateres=$date->get('dd-MM-YYYY');\n\t\t$datestart=new Zend_Date( $dateres.' 00:00:00', 'dd-MM-YYYY HH:mm:ss');\n\t\t$dateend=new Zend_Date( $dateres.' 23:59:59', 'dd-MM-YYYY HH:mm:ss');\n\t\t$start=$datestart->getTimestamp();\n\t\t$end=$dateend->getTimestamp();\n\n\t\t$mylocation = $this->selectedLocation;\n\t\tif( $mylocation instanceof Object_Location ){\n\t\t\t$this->view->reservations= $mylocation->getResource()->getReservationsByDate($start,$end);\n\t\t}\n\t}", "public function returnTaskAsArray() {\n\t\t$task = array();\n\t\t$task['id'] = $this->getID();\n\t\t$task['title'] = $this->getTitle();\n\t\t$task['description'] = $this->getDescription();\n\t\t$task['deadline'] = $this->getDeadline();\n\t\t$task['completed'] = $this->getCompleted();\n\t\treturn $task;\n\t}", "function bmlt_convert_one_meeting ( $in_original_data, ///< The original file data for the meeting.\n $in_one_meeting, ///< The meeting, in the source format. An associative array.\n $in_count ///< The index of this meeting.\n )\n {\n global $region_bias, $gOutput_level;\n $ret = null;\n\n\n if ( $gOutput_level != 'MINIMAL' )\n {\n echo ( \"<tr><td style=\\\"color:white;background-color:black;font-weight:bold;padding-left:1em\\\" colspan=\\\"3\\\">Starting Conversion of Meeting #$in_count</td></tr>\" );\n }\n else\n {\n echo ( \"<tr><td style=\\\"border-top:2px solid black\\\" colspan=\\\"3\\\"></td></tr>\" );\n }\n \n // We cycle through all the meeting data, and extract that which can be mapped to BMLT context.\n \n if ( isset ( $in_one_meeting ) && is_array ( $in_one_meeting ) && count ( $in_one_meeting ) )\n {\n $in_one_meeting = bmlt_clean_one_meeting ( $in_one_meeting );\n \n if ( $in_one_meeting )\n {\n if ( !$in_one_meeting['published'] )\n {\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"font-style:italic;font-size:medium;color:blue;background-color:orange\\\">This meeting is institutional, so it will be unpublished.</td></tr>\\n\" );\n }\n \n $ret = $in_one_meeting;\n // See if we need to geocode.\n if ( !isset ( $ret['longitude'] ) || !isset ( $ret['latitude'] ) || !floatval ( $ret['longitude'] ) || !floatval ( $ret['latitude'] ) )\n {\n $address_string = bmlt_build_address ( $ret );\n \n if ( $address_string )\n {\n if ( $gOutput_level != 'MINIMAL' )\n {\n echo ( \"<tr><td colspan=\\\"3\\\"\" );\n if ( !$in_one_meeting['published'] )\n {\n echo ( \"style=\\\"font-style:italic;font-size:medium;color:blue;background-color:orange\\\"\" );\n }\n echo ( \">This meeting does not have a long/lat, so we are geocoding '$address_string'.</td></tr>\\n\" );\n }\n \n $region_bias = function_exists ( 'bmlt_get_region_bias' ) ? bmlt_get_region_bias() : NULL;\n \n $geocoded_result = bmlt_geocode ( $address_string, ($in_one_meeting['published'] != 0) );\n \n if ( $geocoded_result )\n {\n $ret['longitude'] = floatval ( $geocoded_result['result']['longitude'] );\n $ret['latitude'] = floatval ( $geocoded_result['result']['latitude'] );\n \n if ( isset ( $geocoded_result['result']['partial_geocode'] ) )\n {\n $ret['published'] = 0;\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"color:blue;font-size:large;font-weight:bold;background-color:orange\\\">GEOCODE AMBIGUOUS FOR MEETING $in_count!</td></tr>\\n\" );\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"font-style:italic;font-size:medium;color:blue;background-color:orange\\\">Meeting $in_count will be unpublished. You should edit this meeting, verify that the address information is correct, and possibly correct the longitude and latitude.</td></tr>\\n\" );\n }\n elseif ( $gOutput_level == 'PROLIX' )\n {\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"font-style:italic;font-size:medium\\\">New Long/Lat: \".$ret['longitude'].\", \".$ret['latitude'].\"</td></tr>\\n\" );\n }\n \n if ( array_key_exists ( 'location_postal_code_1', $geocoded_result['result']) )\n {\n $ret['location_postal_code_1'] = $geocoded_result['result']['location_postal_code_1'];\n }\n \n if ( array_key_exists ( 'location_neighborhood', $geocoded_result['result'] ) )\n {\n $ret['location_neighborhood'] = $geocoded_result['result']['location_neighborhood'];\n }\n \n if ( array_key_exists ( 'location_sub_province', $geocoded_result['result'] ) )\n {\n $ret['location_sub_province'] = $geocoded_result['result']['location_sub_province'];\n }\n \n if ( array_key_exists ( 'location_province', $geocoded_result['result'] ) )\n {\n $ret['location_province'] = $geocoded_result['result']['location_province'];\n }\n \n if ( array_key_exists ( 'location_nation', $geocoded_result['result'] ) )\n {\n $ret['location_nation'] = $geocoded_result['result']['location_nation'];\n }\n \n usleep ( 500000 ); // This prevents Google from summarily ejecting us as abusers.\n }\n else\n {\n $ret['published'] = 0;\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"color:blue;font-size:large;font-weight:bold;background-color:orange\\\">GEOCODE FAILURE FOR MEETING $in_count! BAD ADDRESS: '$address_string'</td></tr>\\n\" );\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"font-style:italic;font-size:medium;color:blue;background-color:orange\\\">Meeting $in_count will be unpublished. You should edit this meeting, correct the address information, and set the longitude and latitude.</td></tr>\\n\" );\n }\n }\n else\n {\n $ret['published'] = 0;\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"color:blue;font-size:large;font-weight:bold;background-color:orange\\\">GEOCODE FAILURE FOR MEETING $in_count! CAN'T CREATE ADDRESS!</td></tr>\\n\" );\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"font-style:italic;font-size:medium;color:blue;background-color:orange\\\">Meeting $in_count will be unpublished. You should edit this meeting, add the address information, and set the longitude and latitude.</td></tr>\\n\" );\n }\n }\n elseif ( ($gOutput_level == 'PROLIX') || ($gOutput_level == 'VERBOSE') )\n {\n echo ( \"<tr><td colspan=\\\"3\\\">This already has a long/lat. No need to geocode</td></tr>\\n\" );\n }\n \n $background = '';\n \n if ( !$ret['published'] )\n {\n $background = \";background-color:orange\";\n }\n \n if ( $gOutput_level != 'MINIMAL' )\n {\n echo ( '<tr>' );\n echo ( \"<td style=\\\"width:34%;border-bottom:2px solid black;font-weight:bold;font-size:large$background\\\">\" );\n echo ( 'Read From File' );\n echo ( '</td>' );\n echo ( \"<td style=\\\"width:33%;border-bottom:2px solid black;font-weight:bold;font-size:large$background\\\">\" );\n if ( ($gOutput_level == 'PROLIX') || ($gOutput_level == 'VERBOSE') )\n {\n echo ( 'Converted' );\n }\n echo ( '</td>' );\n echo ( \"<td style=\\\"width:34%;border-bottom:2px solid black;font-weight:bold;font-size:large$background\\\">\" );\n echo ( 'Stored in Database' );\n echo ( '</td>' );\n echo ( \"</tr>\\n\" );\n echo ( '<tr>' );\n echo ( \"<td style=\\\"vertical-align:top$background\\\">\" );\n echo ( '<pre>'.htmlspecialchars ( print_r ( $in_original_data, true ) ).'</pre>' );\n echo ( '</td>' );\n echo ( \"<td style=\\\"vertical-align:top$background\\\">\" );\n if ( ($gOutput_level == 'PROLIX') || ($gOutput_level == 'VERBOSE') )\n {\n echo ( '<pre>'.htmlspecialchars ( print_r ( $in_one_meeting, true ) ).'</pre>' );\n }\n echo ( '</td>' );\n echo ( \"<td style=\\\"vertical-align:top$background\\\">\" );\n echo ( '<pre>'.htmlspecialchars ( print_r ( $ret, true ) ).'</pre>' );\n echo ( '</td>' );\n echo ( \"</tr>\\n\" );\n }\n }\n elseif ( $gOutput_level != 'MINIMAL' )\n {\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"background-color:red;color:white;padding-left:1em\\\">This meeting is deleted or too corrupted to convert.</td></tr>\\n\" );\n }\n }\n \n return $ret;\n }", "public function GetSearchResultsAsArray()\n {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $ret = null;\n \n if ($this->GetSearchResults_Obj() instanceof c_comdef_meetings) {\n $s_array = $this->GetSearchResults_Obj()->GetMeetingObjects();\n \n if (is_array($s_array) && count($s_array)) {\n $ret = $s_array;\n }\n }\n \n return $ret;\n }", "public function show()\n {\n\n\n\n\n $myMeetings = MeetingAttendee::where('phonebook','=',0)\n ->where('attendee','=',\\Auth::user()->id)\n ->select('meeting')\n ->get();\n\n $myMeetingIds = array();\n\n foreach ($myMeetings as $myMeeting) {\n\n $myMeetingIds[] = $myMeeting->meeting;\n\n }\n\n $calendarMeetingsEvents = \\DB::table('calendar_events')\n ->join('calendar_events_type', 'calendar_events.event_type_id', '=', 'calendar_events_type.id')\n ->select(\n \\DB::raw(\"\n calendar_events.id,\n calendar_events.name,\n calendar_events.start_date,\n calendar_events.start_time,\n calendar_events.end_date,\n calendar_events.end_time,\n calendar_events_type.name as event_type\n \"\n\n )\n )\n ->where('calendar_events.event_type_id','=',1)\n ->whereIn('meeting_id',$myMeetingIds)\n ->groupBy('calendar_events.id')\n ->get();\n\n\n\n $calendarEventArray = array();\n $response = array();\n\n foreach ($calendarMeetingsEvents as $calendarMeetingEvent) {\n\n $calendarEventArray['title'] = $calendarMeetingEvent->start_time.'-'.$calendarMeetingEvent->name;\n $calendarEventArray['start'] = $calendarMeetingEvent->start_date.' '.$calendarMeetingEvent->start_time;\n $calendarEventArray['end'] = $calendarMeetingEvent->end_date.' '.$calendarMeetingEvent->end_time;\n $response[] = $calendarEventArray;\n\n\n }\n\n return \\Response::json($response);\n\n }", "public function to_array()\r\n {\r\n $d = array();\r\n if($this->start) {\r\n $d['start'] = PiplApi_Utils::piplapi_date_to_str($this->start);\r\n }\r\n if($this->end){\r\n $d['end'] = PiplApi_Utils::piplapi_date_to_str($this->end);\r\n }\r\n return $d;\r\n }", "function bmlt_clean_one_meeting ( $in_one_meeting ///< The meeting, in the source format. An associative array.\n )\n {\n global $service_body_array, $gOutput_level;\n \n if ( (isset ( $in_one_meeting['Delete'] ) && $in_one_meeting['Delete']) )\n {\n return NULL;\n }\n \n $in_one_meeting['Delete'] = NULL;\n unset ( $in_one_meeting['Delete'] );\n \n if ( isset ( $in_one_meeting['Institutional'] ) && (strtolower($in_one_meeting['Institutional']) == 'true') )\n {\n $in_one_meeting['published'] = 0;\n }\n \n $in_one_meeting['Institutional'] = NULL;\n unset ( $in_one_meeting['Institutional'] );\n \n if ( isset ( $in_one_meeting['AreaRegion'] ) )\n {\n $value = $in_one_meeting['AreaRegion'];\n $in_one_meeting['service_body_bigint'] = intval($service_body_array[$in_one_meeting['AreaRegion']]['id_bigint']);\n $name = $service_body_array[$value]['name_string'];\n \n if ( !$name )\n {\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"background-color:red;color:white;font-weight:bold\\\">This meeting \" );\n \n $group_name = trim ( $in_one_meeting['meeting_name'] );\n \n if ( $group_name )\n {\n echo ( \"('$group_name') \" );\n }\n \n echo ( \"is part of a Service body ($value) that is not known to this server, and will be skipped.</td></tr>\" );\n return NULL;\n }\n elseif ( $gOutput_level != 'MINIMAL' )\n {\n echo ( \"<tr><td colspan=\\\"3\\\">This meeting is part of the '$name' ($value) Service Body.</td></tr>\" );\n }\n \n $in_one_meeting['AreaRegion'] = NULL;\n unset ( $in_one_meeting['AreaRegion'] );\n }\n \n $in_one_meeting['longitude'] = floatval ( str_replace ( ',', '.', $in_one_meeting['longitude'] ) );\n $in_one_meeting['latitude'] = floatval ( str_replace ( ',', '.', $in_one_meeting['latitude'] ) );\n \n if ( isset ( $in_one_meeting['WeekdayString'] ) )\n {\n $in_one_meeting['weekday_tinyint'] = func_convert_from_english_full_weekday ( $in_one_meeting['WeekdayString'] );\n\n $in_one_meeting['WeekdayString'] = NULL;\n unset ( $in_one_meeting['WeekdayString'] );\n }\n \n if ( isset ( $in_one_meeting['SimpleMilitaryTime'] ) )\n {\n $in_one_meeting['start_time'] = func_start_time_from_simple_military ( $in_one_meeting['SimpleMilitaryTime'] );\n \n $in_one_meeting['SimpleMilitaryTime'] = NULL;\n unset ( $in_one_meeting['SimpleMilitaryTime'] );\n }\n \n if ( isset ( $in_one_meeting['RoomInfo'] ) )\n {\n $val = intval ( $in_one_meeting['RoomInfo'] );\n $openParen = FALSE;\n \n if ( isset ( $in_one_meeting['location_info'] ) && $in_one_meeting['location_info'] )\n {\n $in_one_meeting['location_info'] .= ' (';\n $openParen = TRUE;\n }\n else\n {\n $in_one_meeting['location_info'] = '';\n }\n \n $in_one_meeting['location_info'] .= \"$val\";\n \n if ( $openParen )\n {\n $in_one_meeting['location_info'] .= \")\";\n }\n \n $in_one_meeting['RoomInfo'] = NULL;\n unset ( $in_one_meeting['RoomInfo'] );\n }\n \n if ( isset ( $in_one_meeting['FormatsAsString'] ) )\n {\n $in_one_meeting['formats'] = bmlt_convert_formats ( $in_one_meeting['FormatsAsString'] );\n }\n else\n {\n $in_one_meeting['formats'] = bmlt_determine_formats_from_world ( $in_one_meeting );\n }\n \n $in_one_meeting['FormatsAsString'] = NULL;\n unset ( $in_one_meeting['FormatsAsString'] );\n $in_one_meeting['FormatClosedOpen'] = NULL;\n unset ( $in_one_meeting['FormatClosedOpen'] );\n $in_one_meeting['FormatWheelchair'] = NULL;\n unset ( $in_one_meeting['FormatWheelchair'] );\n $in_one_meeting['FormatLanguage1'] = NULL;\n unset ( $in_one_meeting['FormatLanguage1'] );\n $in_one_meeting['FormatLanguage2'] = NULL;\n unset ( $in_one_meeting['FormatLanguage2'] );\n $in_one_meeting['FormatLanguage3'] = NULL;\n unset ( $in_one_meeting['FormatLanguage3'] );\n $in_one_meeting['Format1'] = NULL;\n unset ( $in_one_meeting['Format1'] );\n $in_one_meeting['Format2'] = NULL;\n unset ( $in_one_meeting['Format2'] );\n $in_one_meeting['Format3'] = NULL;\n unset ( $in_one_meeting['Format3'] );\n $in_one_meeting['Format4'] = NULL;\n unset ( $in_one_meeting['Format4'] );\n $in_one_meeting['Format5'] = NULL;\n unset ( $in_one_meeting['Format5'] );\n \n if ( ((intval ( $in_one_meeting['weekday_tinyint'] ) ) < 0) || (intval ( $in_one_meeting['weekday_tinyint'] ) > 6) || !isset ( $in_one_meeting['start_time'] ) || !trim ( $in_one_meeting['start_time'] ) )\n {\n if ( $gOutput_level != 'MINIMAL' )\n {\n $name = isset ( $in_one_meeting['meeting_name'] ) ? trim ( $in_one_meeting['meeting_name'] ) : '';\n \n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"background-color:red;color:white;font-weight:bold\\\">The meeting \" );\n \n if ( $name )\n {\n echo ( \"'$name' \" );\n }\n \n echo ( \"does not have enough information to convert, and will be skipped.</td></tr>\" );\n }\n \n $in_one_meeting = null;\n }\n else\n {\n $sb = isset ( $in_one_meeting['service_body_bigint'] ) ? intval ( $in_one_meeting['service_body_bigint'] ) : 0;\n $in_one_meeting['service_body_bigint'] = 0;\n \n foreach ( $service_body_array as $service_body )\n {\n if ( intval ( $service_body['id_bigint'] ) == $sb )\n {\n $in_one_meeting['service_body_bigint'] = $sb;\n break;\n }\n }\n \n if ( !intval ( $in_one_meeting['service_body_bigint'] ) )\n {\n if ( $gOutput_level != 'MINIMAL' )\n {\n echo ( \"<tr><td colspan=\\\"3\\\" style=\\\"background-color:red;color:white;font-weight:bold\\\">This meeting does not belong to a valid Service Body, and will be skipped.</td></tr>\" );\n }\n \n $in_one_meeting = null;\n }\n }\n \n return $in_one_meeting;\n }", "public function toSlackObjectArray(): array;", "function getReservationTimeArrayAsInteger(){\n //setting variables;\n //$dateformat = 'H:i:s';\n $int_start_time;\n $int_duration = strtotime($this->end_time) - strtotime($this->start_time);\n $int_duration = (int)date('h', $int_duration);\n //$reservationTimeArray = array($this->start_time, $this->end_time);\n\n //first switch case function will convert all possible bookings to integer value\n switch($this->start_time){\n case '9:00:00':\n $int_start_time = 0;\n break;\n case '10:00:00':\n $int_start_time = 1;\n break;\n case '11:00:00':\n $int_start_time = 2;\n break;\n case '12:00:00':\n $int_start_time = 3;\n break;\n case '13:00:00':\n $int_start_time = 4;\n break;\n case '14:00:00':\n $int_start_time = 5;\n break;\n case '15:00:00':\n $int_start_time = 6;\n break;\n case '16:00:00':\n $int_start_time = 7;\n break;\n case '17:00:00':\n $int_start_time = 8;\n break;\n }\n\n //by the end of this switch case we have array which will have exactly 2 values inside\n //the problem is if smbd booked for more than 1 hour the array will be missing these intermediate value\n // EXAMPLE: Booking from 15:00 to 18:00 will result in array value of [6,9];\n //the next step is we need to fill up missing values;\n\n for($i = $int_start_time; $i < ($int_start_time + $int_duration); $i++){\n $int_reservationTimeArray[] = $i;\n }\n \n\n //after this we have array which can look as [6,9,7,8];\n //the array is not sorted, so we better sort it before we pass it back\n\n\n sort($int_reservationTimeArray);\n\n return $int_reservationTimeArray;\n\n\n }", "public function getAllIBCMeetings() {\n\t\t$dao = $this->getDao(new IBCMeeting());\n return $dao->getAll();\n\t}", "public function getMeetings() {\n\t\t$meetings = Meeting::get()->Sort('StartDate', 'DESC');\n\t\treturn $meetings;\n\t}", "public function getMeetings() {\n\t\t$meetings = Meeting::get()->Sort('StartDate', 'DESC');\n\t\treturn $meetings;\n\t}", "public function getAllMeetingRooms() {\n $sql = 'SELECT * FROM ces_meeting_rooms WHERE status = \"L\"';\n \n $stmt = $this->conn->prepare($sql);\n $stmt->execute();\n \n return $stmt->fetchAll();\n }", "public function SetMeetingIDArray(\n $in_meeting_id_array ///< An array of positive integers. These are the IDs of individual meetings to find.\n ) {\n // phpcs:enable PSR1.Methods.CamelCapsMethodName.NotCamelCaps\n $this->_meeting_id_array = $in_meeting_id_array;\n }", "public function get_agenda() {\n\t\t$items = $this->agenda_items->get_items();\n\t\t$participants = $this->participants->get_participants();\n\n\t\t// Create agenda\n\t\tforeach ($items as $item) {\n\t\t\tif ($item->is_all_participants) {\n\t\t\t\tforeach ($participants as $participant) {\n\t\t\t\t\t$json_return['items'][] = $this->create_agenda_row($item, $participant);\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$json_return['items'][] = $this->create_agenda_row($item, NULL);\n\t\t\t}\n\t\t}\n\n\t\t// Get participants\n\t\tforeach ($participants as $participant) {\n\t\t\t$json_return['participants'][$participant->id] = $participant;\n\t\t}\n\n\t\t$json_return['success'] = TRUE;\n\t\techo json_encode($json_return);\n\t}", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'people_id' => $this->people_id,\n 'notes' => $this->notes,\n 'date_appointment' => Carbon::parse($this->date_appointment)->format('d/m/Y'),\n ];\n }", "public function toArrayForApi()\n {\n $return = array();\n\n if ($this->getDueDate()) {\n $return['due_date'] = $this->getDueDate();\n }\n if ($this->getTeamId()) {\n $return['team_id'] = $this->getTeamId();\n }\n if ($this->getUserId()) {\n $return['user_id'] = $this->getUserId();\n }\n if ($this->getTaskTypeId()) {\n $return['task_type_id'] = $this->getTaskTypeId();\n }\n if ($this->getDescription()) {\n $return['description'] = $this->getDescription();\n }\n if ($this->getDuration()) {\n $return['duration'] = $this->getDuration();\n }else{\n $return['duration'] = 0;\n }\n if ($this->getPriority()) {\n $return['priority'] = $this->getPriority();\n }\n if ($this->getFor()){\n $return['for'] = $this->getFor();\n }\n if ($this->getForId()) {\n $return['for_id'] = $this->getForId();\n }\n if ($this->getCreatorUserId()) {\n $return['creator_user_id'] = $this->getCreatorUserId();\n }\n\n return $return;\n }", "public function toArray($request)\n {\n Resource::withoutWrapping();\n $id = $this->id;\n return [\n 'id' => $id,\n 'barber' => $this->barber,\n 'date' => $this->date,\n 'time' => $this->time,\n '_links' => [\n 'self' => [\n \"href\" => \"http://gbhavelaar.nl/api/appointments/\".$id\n ],\n 'collection' => [\n \"href\" => \"http://gbhavelaar.nl/api/appointments\"\n ]\n\n ]\n\n ];\n }", "public function toSlackObjectArray(): array\n {\n }", "public function toArray($request)\n {\n return [\n 'data' => $this->collection->transform(function($officeTime){\n return[\n 'id' => $officeTime->id,\n 'title' => $officeTime->title,\n 'daily_rutine' => $officeTime->daily_rutine,\n 'optional_day' => $officeTime->optional_day,\n 'off_day' => $officeTime->off_day,\n 'status' => $officeTime->status,\n ];\n })\n ];\n }", "public function meetings()\n {\n return $this->belongsToMany('Modules\\Meeting\\Entities\\Meeting')->withTimestamps();\n }", "protected function getMesesArray(){\n\n $dt = new \\DateTime();\n $dt->modify('-13 months');\n for ($i = 0 ; $i < 12 ; $i ++){\n \t\t$dt->modify('+1 month');\n $meses[$i] = strftime(\"%b %Y\" , $dt->getTimeStamp());\n }\n return json_encode($meses);\n }", "public function toArray($request)\n {\n /* return parent::toArray($request);*/\n\n $teachers_string = $this->teachers;\n $teachers_array = explode(',', $teachers_string);\n\n $teachersid_string = $this->teachers_id;\n $teachersid_array = explode(',', $teachersid_string);\n\n return [\n 'id' => $this->id,\n 'codeno' => $this->codeno,\n 'title' => $this->title,\n 'startdate' => $this->startdate,\n 'enddate' => $this->enddate,\n 'duration_id' => $this->duration_id,\n 'user_id' => $this->user_id,\n\n 'duration' => new DurationResource(Duration::find($this->duration_id)),\n 'user' => new UserResource(User::find($this->user_id)),\n \"teachers\" => TeacherResource::collection(Section::find($this->id)->teachers),\n ];\n }", "public function getMeetings($room_id)\n {\n $this->validate(request(), [\n 'before'=>'date_format:Y-m-d H:i',\n 'after'=>'date_format:Y-m-d H:i',\n ]);\n $room = Room::where('id', $room_id)->get();\n if(is_null($room)){\n return response()->json([\"message\"=>\"Room does not exist.\"], 404);\n }\n $meetings = Meeting::where('room_id', $room_id);\n if(request()->has('before'))\n {\n $meetings->where('end_time', '<', request()->get('before'));\n }\n\n if(request()->has('after'))\n {\n $meetings->where('start_time', '>', request()->get('after'));\n }\n\n return response()->json(array(\"meetings\"=>$meetings->get()));\n }", "public function getAllMeetings() {\n $meetings = $this->meetingRepository->findAll();\n return $meetings;\n }", "public function getMeetings(): CacheableJsonResponse {\n\n // Initialize the response.\n $response = [];\n\n // Wrap Query in render context.\n $context = new RenderContext();\n $meeting_nids = \\Drupal::service('renderer')->executeInRenderContext($context, function () {\n $meeting_query = \\Drupal::entityQuery('node')\n ->condition('type', 'cfo_meeting')\n ->condition('status', 1)\n ->sort('created');\n return $meeting_query->execute();\n });\n\n if (!empty($meeting_nids)) {\n\n // Loop through all meetings.\n foreach ($meeting_nids as $meeting_nid) {\n\n // Load the meeting node.\n if ($meeting_node = $this->nodeStorage->load($meeting_nid)) {\n\n // Prepare the meeting date for the url \"slug\".\n $meeting_date = $meeting_node->get('field_meeting_date')->getValue()[0]['value'];\n $meeting_slug = date('F-j-Y', strtotime($meeting_date));\n\n // Contents of this meeting.\n $meeting = [\n 'meeting_nid' => $meeting_nid,\n 'meeting_title' => $meeting_node->label(),\n 'meeting_updated' => $meeting_node->changed->value,\n 'meeting_slug' => $meeting_slug,\n ];\n\n // Add this meeting into the response.\n $response[] = $meeting;\n\n }\n\n }\n\n }\n\n // Set up the Cache Meta.\n $cacheMeta = (new CacheableMetadata())\n ->setCacheTags(['node_list:cfo_meeting'])\n ->setCacheMaxAge(Cache::PERMANENT);\n\n // Set the JSON response to the response of meetings.\n $json_response = new CacheableJsonResponse($response);\n\n // Add in the cache dependencies.\n $json_response->addCacheableDependency($cacheMeta);\n\n // Handle any bubbled cacheability metadata.\n if (!$context->isEmpty()) {\n $bubbleable_metadata = $context->pop();\n BubbleableMetadata::createFromObject($meeting_nids)\n ->merge($bubbleable_metadata);\n }\n\n // Return JSON Response.\n return $json_response;\n\n }", "public function getAllParticipants($event_id) {\r\n$query = $this->db->query(\"SELECT * FROM participated_in where event_id= \" . $event_id . \" AND deleted =0 ORDER BY is_instructor DESC\");\r\n$participants_array = array();\r\n$i = 0;\r\nforeach ($query->result() as $row) {\r\n$person_detail = $this->personModel->getPersonDetail($row->person_id);\r\n$participants_array[$i][0] = $row->person_id;\r\n$participants_array[$i][1] = $person_detail[2]; //$this->personModel->getPersonName($row->person_id);\r\n$participants_array[$i][2] = $row->is_instructor;\r\n$participants_array[$i][3] = $person_detail[7];\r\n$participants_array[$i][4] = $person_detail[12];\r\n$participants_array[$i][5] = $person_detail[11];\r\n\r\n\r\n$i++;\r\n}\r\n\r\nreturn $participants_array;\r\n}", "public function toArray()\n\t{\n\t\t$response = $this->data;\n\n\t\t// Convert more data\n\t\tif (isset($response['player1'])) $response['player1'] = $response['player1']->toArray();\n\t\tif (isset($response['player2'])) $response['player2'] = $response['player2']->toArray();\n\t\tif (isset($response['winner'])) $response['winner'] = $response['winner']->toArray();\n\t\tif (isset($response['event'])) $response['event'] = $response['event']->toArray();\n\n\t\treturn $response;\n\t}", "public function toApi(): array\n {\n return [\n 'id' => $this->id,\n 'task_id' => $this->task_id,\n 'text' => $this->text,\n 'is_complete' => (bool) $this->is_complete\n ];\n }", "public function toArray($request)\n {\n $rtn = [\n 'id' => (string)$this->id,\n 'start_time' => (string)$this->start_time,\n 'end_time' => (string)$this->end_time,\n 'reason' => $this->reason ? (string)$this->reason : null,\n 'user_id' => (string)$this->user_id\n ];\n\n $rtn = array_merge($rtn, [\n 'created_at' => (string)$this->created_at,\n 'updated_at' => (string)$this->updated_at,\n ]);\n\n return $rtn;\n }", "public function meetings() {\n return $this->belongsToMany('App\\Meeting');\n }", "function meetingDetails()\n\t{\n\t\t$sql = \"SELECT * FROM meetingdetails\";\n\t\t$result = $this->connection->query($sql);\n\n\t\twhile($row = mysqli_fetch_array($result))\n\t\t{\n\t\t\treturn $row['day'] . \" \" . $row['date'] . \" \" . $row['month'] . \"<br />\" . $row['venue'] . \"<br />at \" . $row['time'].\" Sharp\";\n\t\t}\n\t\treturn \"\";\n\t}", "public function getAppointmentsListJSON() {\nglobal $_LW;\n$output=[];\nforeach($_LW->dbo->query('select', 'id, title', 'livewhale_appointments', false, 'title ASC')->run() as $res2) { // loop through and add appointments\n\t$output[]=['id'=>$res2['id'], 'title'=>$res2['title']];\n};\nreturn json_encode($output);\n}", "public function getParticipants()\r\n {\r\n return $this->hasMany(MeetingParticipant::className(), ['meeting_id' => 'id']);\r\n }", "function _makeAgenda($agenda){\n return [\n 'text' => $agenda->title,\n 'description' => $agenda->description,\n 'video' => $agenda->video == 1 ? true : false,\n 'videoURL' => $agenda->videoURL,\n 'videoBackgroundImage' => $agenda->videoBackgroundImage,\n 'redirectTo' => url('/agenda/'.$agenda->slug),\n 'videoBackgroundImageURL' => $agenda->videoBackgroundImageURL,\n ];\n }", "public function _getGroupMeetings()\n {\n $meetings = [];\n foreach ($this->meetings as $meeting)\n if ($meeting->IsGroupMeeting)\n $meetings[] = $meeting;\n\n return $meetings;\n }", "public function toArray()\n {\n $event = array();\n\n if ($this->id !== null) {\n $event['id'] = \"$this->id\";\n }\n\n $event['title'] = $this->activite->getDesignation();\n $event['start'] = $this->heureDebut->format(\"H:i:s\");\n if ($this->heureFin !== null) {\n $event['end'] = $this->heureFin->format(\"H:i:s\");\n }\n $event['resourceId'] = $this->enfant->getId() . \"-\" . $this->jour->getId();\n\n return $event;\n }", "public function _getPrivateMeetings()\n {\n $meetings = [];\n foreach ($this->meetings as $meeting)\n if ($meeting->IsPrivateMeeting)\n $meetings[] = $meeting;\n\n return $meetings;\n }", "public function update($meeting)\n {\n\n }", "public function getEventsByDay( $day ) {\n\n\t\t$rangestart = strtotime($day) * 1000; // zimbra always works with milliseconds in timestamps\n\t\t$rangeend = $rangestart + (24 * 60 * 60 * 1000);\n\n\t\t/**\n\t\t* build full call url\n\t\t*/\n\t\t$calendar = $this->getFromZimbra(\"/calendar?start=\" . $rangestart . \"&end=\" . $rangeend);\n\n\t\t$events = array();\n\t\tif( !property_exists($calendar, \"appt\") ) return $events;\n\n\t\tforeach ($calendar->appt as $meetingSeries) {\n\n\t\t\t/**\n\t\t\t* collect values for the current appointment\n\t\t\t*/\n\t\t\t$finalstartdate = null;\n\t\t\t$finalenddate = null;\n\t\t\t$finalname = null;\n\t\t\t$finallocation = null;\n\n\t\t\t/**\n\t\t\t* iterate over all sub events in order to find the right one\n\t\t\t* single events just have one item = easy, we just take this one\n\t\t\t* series of events contain the original item plus all execptions, more difficult to handle\n\t\t\t*/\n\t\t\tforeach ($meetingSeries->inv as $meeting) {\n\n\t\t\t\t$startdate = isset($meeting->comp[0]->s[0]->u) ? $meeting->comp[0]->s[0]->u : \"\";\n\t\t\t\t$enddate = isset($meeting->comp[0]->e[0]->u) ? $meeting->comp[0]->e[0]->u: \"\";\n\t\t\t\t$name = $meeting->comp[0]->name;\n\t\t\t\t$location = $meeting->comp[0]->loc;\n\n\t\t\t\t/**\n\t\t\t\t* we take the original, if nothing is set yet\n\t\t\t\t* the original events hold the time from the original day only, so we need to recalculate\n\t\t\t\t* since we are only getting the data from one day, we can kill the day information on extract the hours only\n\t\t\t\t*/\n\t\t\t\tif( $finalstartdate == null && !property_exists($meeting->comp[0], \"recurId\")) {\n\t\t\t\t\t$finalstartdate = date(\"Y-m-d\", $rangestart/1000) . \" \" . date(\"H:i\", $startdate / 1000);\n\t\t\t\t\t$finalenddate = date(\"Y-m-d\", $rangestart/1000) . \" \" . date(\"H:i\", $enddate / 1000);\n\t\t\t\t\t$finalname = $name;\n\t\t\t\t\t$finallocation = $location;\n\t\t\t\t}\n\n\t\t\t\t/**\n\t\t\t\t* overwrite if got an exception of the series taking place on the current day\n\t\t\t\t*/\n\t\t\t\tif( property_exists($meeting, \"recurId\") &&\n\t\t\t\t\t($startdate <= $rangeend && $enddate >= $rangestart)) {\n\t\t\t\t\t$finalstartdate = date(\"Y-m-d H:i\", $startdate / 1000);\n\t\t\t\t\t$finalenddate = date(\"Y-m-d H:i\", $enddate / 1000);\n\t\t\t\t\t$finalname = $name;\n\t\t\t\t\t$finallocation = $location; \n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$events[]= array(\n\t\t\t\t\"name\" => $finalname,\n\t\t\t\t\"location\" => $finallocation,\n\t\t\t\t\"startdate\" => $finalstartdate, // timestamp has milli seconds as well\n\t\t\t\t\"enddate\" => $finalenddate\n\t\t\t);\n\t\t}\n\n\t\tusort($events, array(\"self\", \"cmp\"));\n\t\treturn $events;\n\t}", "protected function getEmpryarray() {\n return array(\n 'lngGameid' => 0,\n 'lngUseridfrom' => 0,\n 'lngUseridto' => 0,\n 'strMessage' => '',\n 'blnRead' => false\n );\n }", "public function toArray($request)\n {\n\n return [\n 'list' => $this->collection->map(function ($chat) {\n return [\n 'id' => $chat->id,\n 'name' => $chat->name,\n 'lastMessageText' => $chat->last_message_body,\n 'lastMessageDT' => $chat->last_message_time ? $chat->last_message_time->timestamp : null,\n 'isRead' => (bool)$chat->last_is_read,\n 'isLastFromMe' => ($this->user_id == $chat->last_user_id),\n 'attendees' => new AttendeesCollection($chat->attendees, $chat->user_id)\n ];\n })->toArray()\n ];\n }", "protected function asArray()\n\t{\n\t\treturn \\json_decode($this->response, true);\n\t}", "function procMeetArray($lineSplit) {\n\t// Turn the start/end times from 03:45 PM to 154500\n\t// Hours must be mod'd by 12 so 12:00 PM does not become\n\t// 24:00 and 12 AM does not become 12:00\n\tif(!preg_match(\"/(\\d\\d):(\\d\\d) ([A-Z]{2})/\", $lineSplit[10], $start)) {\n\t\t// Odds are the class is TBD (which means we can't represent it)\n\t\treturn false;\n\t}\n\t$lineSplit[10] = (($start[3] == 'PM') ? ($start[1] % 12) + 12 : $start[1] % 12) . $start[2] . \"00\";\n\tpreg_match(\"/(\\d\\d):(\\d\\d) ([A-Z]{2})/\", $lineSplit[11], $end);\n\t$lineSplit[11] = (($end[3] == 'PM') ? ($end[1] % 12) + 12 : $end[1] % 12) . $end[2] . \"00\";\n\treturn $lineSplit;\n}", "function submitted_events_calendar($submission) {\n\tif (submitted_events_starts_with ( $submission->brunelgroup, 'Joint' )) {\n\t\treturn array (\n\t\t\t\t23,\n\t\t\t\t24 \n\t\t);\n\t} elseif (submitted_events_starts_with ( $submission->brunelgroup, '20' )) {\n\t\treturn array (\n\t\t\t\t23 \n\t\t);\n\t} elseif (submitted_events_starts_with ( $submission->brunelgroup, '40' )) {\n\t\treturn array (\n\t\t\t\t24 \n\t\t);\n\t} else {\n\t\treturn array ();\n\t}\n}", "public function formatToArray(){\n return [\n 'nombre' => $this->name,\n 'ciudad' => $this->cityId,\n 'email' => $this->email,\n 'telefono' => $this->tel,\n 'tipo_documento' => $this->typeDoc,\n 'documento' => $this->doc,\n 'direccion' => $this->addr,\n 'direccion_referencia' => $this->addRef,\n 'coordenadas' => $this->addrCoo,\n 'ruc' => $this->ruc,\n 'razon_social' => $this->socialReason,\n ];\n }", "public function getArray()\n{\n\t$ts=$this->getTimestamp();return array('year'=>date('Y',$ts),'month'=>date('m',$ts),'day'=>date('d',$ts),'hour'=>date('H',$ts),'minute'=>date('i',$ts),'second'=>date('s',$ts));\n}", "public function index()\n {\n $meeting = Meeting::all();\n $response = [\n 'message' => 'data retrived successfully',\n 'data' => $meeting\n ];\n return response()->json($response, 200);\n }", "public function toArray()\n {\n $objectArray = get_object_vars($this);\n\n //Specific data\n if (null !== $objectArray['dateSended']) {\n $objectArray['dateSended'] = $objectArray['dateSended']->format('Y-m-d');\n }\n if (null !== $objectArray['timeSended']) {\n $objectArray['timeSended'] = $objectArray['timeSended']->format('H:i:s');\n }\n\n return $objectArray;\n }", "public function getMeetingInfo()\n {\n if (array_key_exists(\"meetingInfo\", $this->_propDict)) {\n if (is_a($this->_propDict[\"meetingInfo\"], \"\\Beta\\Microsoft\\Graph\\Model\\MeetingInfo\") || is_null($this->_propDict[\"meetingInfo\"])) {\n return $this->_propDict[\"meetingInfo\"];\n } else {\n $this->_propDict[\"meetingInfo\"] = new MeetingInfo($this->_propDict[\"meetingInfo\"]);\n return $this->_propDict[\"meetingInfo\"];\n }\n }\n return null;\n }", "public static function setMeetingReminders($meeting_id,$chosen_time=false) {\n $mtg = Meeting::findOne($meeting_id);\n if ($chosen_time ===false) {\n $chosen_time = Meeting::getChosenTime($meeting_id);\n }\n // create attendees list for organizer and participants\n $attendees = array();\n $attendees[0]=$mtg->owner_id;\n $cnt =1;\n foreach ($mtg->participants as $p) {\n if ($p->status ==Participant::STATUS_DEFAULT) {\n $attendees[$cnt]=$p->participant_id;\n $cnt+=1;\n }\n }\n // for each attendee\n foreach ($attendees as $a) {\n // for their reminders\n $rems = Reminder::find()->where(['user_id'=>$a])->all();\n foreach ($rems as $rem) {\n // create a meeting reminder for that reminder at that time\n MeetingReminder::create($meeting_id,$a,$rem->id,$rem->duration);\n }\n }\n }", "public function send_meeting()\n {\n // save meeting\n if($this->user['is_matched'] > 0) {\n $update['data']['from'] = $this->session->userdata('user_id');\n $update['data']['to'] = $this->user['is_matched'];\n $update['data']['meeting_subject'] = $this->input->post('meeting_subject');\n $update['data']['meeting_desc'] = $this->input->post('meeting_desc');\n $update['data']['month'] = $this->input->post('month');\n $update['data']['day'] = $this->input->post('day');\n $update['data']['year'] = $this->input->post('year');\n $update['data']['start_ampm'] = $this->input->post('start_ampm');\n $update['data']['end_ampm'] = $this->input->post('end_ampm');\n $update['data']['stamp'] = date(\"Y-m-d H:i:s\");\n $update['data']['start_time'] = $this->input->post('start_time');\n $update['data']['end_time'] = $this->input->post('end_time');\n\n $update['table'] = 'meetings';\n $update['data']['ical'] = encrypt_url($this->Application_model->insert($update));\n\n // send emails to each party\n\n $match = $this->Application_model->get(array('table'=>'users','id'=>$this->user['is_matched']));\n $update['data']['who'][] = $match['first_name'] . \" \" . $match['last_name'];\n $update['data']['who'][] = $this->user['first_name'] . \" \" . $this->user['last_name'];\n\n //convert date and time to nice format\n $nice_date = date('D M d, Y',strtotime($this->input->post('day').\"-\".$this->input->post('month').\"-\".$this->input->post('year')));\n $update['data']['nice_date'] = $nice_date;\n\n // to requesting user\n $data = array();\n $data['user'] = $this->user['first_name'] . \" \" . $this->user['last_name'];\n $data['message'] = $update['data'];\n $message = $this->load->view('/dash/email/meeting', $data, true);\n $this->email->clear();\n $this->email->from($this->config->item('admin_email', 'ion_auth'), $this->config->item('site_title', 'ion_auth'));\n $this->email->to($this->user['email']);\n\n $full_subject = \"Invitation: \" . $nice_date . \" \" . $this->input->post('start_time') . \"\" . $this->input->post('start_ampm') . \" - \" . $this->input->post('end_time') . \"\" . $this->input->post('end_ampm') . \" (\" . $this->user['first_name'] . \" \" . $this->user['last_name'] . \")\";\n\n $this->email->subject($full_subject);\n $this->email->message($message);\n\n $result = $this->email->send(); // @todo handle false send result\n\n\n // to invitee\n $data = array();\n $data['user'] = $match['first_name'] . \" \" . $match['last_name'];\n $data['message'] = $update['data'];\n $message = $this->load->view('/dash/email/meeting', $data, true);\n $this->email->clear();\n $this->email->from($this->config->item('admin_email', 'ion_auth'), $this->config->item('site_title', 'ion_auth'));\n $this->email->to($match['email']);\n\n $full_subject = \"Invitation: \" . $nice_date . \" \" . $this->input->post('start_time') . \"\" . $this->input->post('start_ampm') . \" - \" . $this->input->post('end_time') . \"\" . $this->input->post('end_ampm') . \" (\" . $match['first_name'] . \" \" . $match['last_name'] . \")\";\n\n $this->email->subject($full_subject);\n $this->email->message($message);\n\n $result = $this->email->send(); // @todo handle false send result\n\n\n $this->session->set_flashdata(\n 'message',\n '<div class=\"alert alert-success\">Meeting Request Sent.</div>'\n );\n\n redirect('/dashboard/match','refresh');\n }else{\n\n redirect('/dashboard','refresh');\n\n }\n\n }", "public function actionBookedhours(): array\n {\n $request = Yii::$app->request;\n\n if ($request->isPost) {\n return Appointments::getBookedHoursByDate($request->post('service_id'), $request->post('date'));\n }\n \n return [];\n }", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'start_date' => optional($this->start_date)->format('Y-m-d H:i'),\n 'end_date' => optional($this->end_date)->format('Y-m-d H:i'),\n 'patient' => PersonResource::make(optional($this->patient->person)),\n 'doctor' => DoctorResource::make(optional($this->doctor)),\n 'type' => AppointmentsTypeResource::make(optional($this->type))\n ];\n }", "public function toArray($request)\n {\n // get order of cities on the tip line to check the available seats\n $dispatch_city_order = $this->line->getCityOrder($request->dispatch_city_id);\n $destination_city_order = $this->line->getCityOrder($request->destination_city_id);\n\n $bookedTickets = $this->reservations()->bookedTickets($this->line,$dispatch_city_order,$destination_city_order);\n return [\n 'id'=>$this->id,\n 'bus'=>new BusResource($this->bus),\n 'date'=>$this->date,\n 'available_seats' =>getAvailableTickets($bookedTickets)\n ];\n }", "public function toArray($request)\n {\n $timing = Timing::find($this->timing_id);\n return [\n 'id'=>$this->id,\n 'name'=>$this->name,\n 'profession'=>$this->profession,\n 'timing'=> new TimingResource($timing),\n 'fields_merge'=> new FieldCollection($this->fields()->get()),\n 'fields'=> array_map('strval', $this->fields()->pluck('id')->toArray()),\n 'mobile'=>$this->mobile,\n 'phone'=>$this->phone,\n 'social_media'=>$this->social_media,\n 'fax'=>$this->fax,\n 'state'=>$this->state,\n 'city'=>$this->city,\n 'description'=>$this->description,\n 'activity'=>new ActivityCollection($this->activities),\n 'public_show'=>$this->public_show,\n\n 'type'=>strval($timing->type),\n 'period'=>strval($timing->period),\n 'number'=>strval($timing->number),\n\n ];\n }", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'day' => $this->day,\n 'from' => $this->from,\n 'to' => $this->to,\n 'payment_method' => $this->payment_method,\n 'payment_id' => $this->payment_id,\n $this->mergeWhen($request->route()->getName() == 'appointments.index', [\n 'bookings' => BookingResource::collection($this->bookings),\n ]),\n $this->mergeWhen($request->route()->getName() == 'appointments.show', [\n 'doctor' => new DoctorResource($this->doctor),\n 'clinic' => new ClinicResource($this->doctor->clinic),\n 'bookings' => BookingResource::collection($this->bookings),\n ]),\n $this->mergeWhen($request->doctors, [\n 'doctor' => new DoctorResource($this->doctor)\n ]),\n $this->mergeWhen($request->clinics, [\n 'clinic' => new ClinicResource($this->doctor->clinic)\n ])\n ];\n }", "public function toArray()\r\n {\r\n \treturn array(\r\n \t\t'guid'\t=> $this->guid,\r\n \t\t'pollGuid'\t=> $this->pollGuid,\r\n \t\t'text' => $this->text,\r\n \t\t'hits' => $this->hits\r\n \t);\r\n }", "public function load_participant_talks()\n {\n $participant_id = (string)Auth::user()->id;\n $talks = Talks::with(['event'])->whereJsonContains('participants',$participant_id)->get();\n\n return response()->json($talks, 200);\n }", "function get_appointment_times($db, $appointments) {\n $unavailable_times = array();\n $available_times = array();\n foreach ($appointments as $appointment) {\n array_push($unavailable_times, date(\"Y-m-d H:i:s\", strtotime($appointment['appt_time'])));\n }\n foreach ($unavailable_times as $unavailable_time) {\n $possible_time = date(\"Y-m-d H:i:s\", strtotime($unavailable_time . \"+1 hour\"));\n if (!in_array($possible_time, $unavailable_times)) {\n array_push($available_times, $possible_time);\n }\n }\n return $available_times;\n}", "protected function getPendingAppointments($args) {\n\n if ($args['ent_date_time'] == '')\n return $this->_getStatusMessage(1, 1);\n\n $this->curr_date_time = urldecode($args['ent_date_time']);\n\n $returned = $this->_validate_token($args['ent_sess_token'], $args['ent_dev_id'], '1');\n\n if (is_array($returned))\n return $returned;\n\n// $curr_date = date('Y-m-d H:i:s', time());\n// $curr_date_bfr_30min = date('Y-m-d H:i:s', time() - 1800);\n// $curr_date_bfr_1hr = date('Y-m-d H:i:s', time() - 3600);\n\n\n $selectAppntsQry = \"select p.profile_pic,p.first_name,p.phone,p.email,a.appt_lat,a.appt_long,a.appointment_dt,a.extra_notes,a.address_line1,a.address_line2,a.status,a.booking_type from appointment a, slave p \";\n $selectAppntsQry .= \" where p.slave_id = a.slave_id and a.status = 1 and a.mas_id = '\" . $this->User['entityId'] . \"' order by a.appointment_dt DESC\"; // and a.appointment_dt >= '\" . $curr_date_bfr_1hr . \"'\n\n $selectAppntsRes = mysql_query($selectAppntsQry, $this->db->conn);\n\n if (mysql_num_rows($selectAppntsRes) <= 0)\n return $this->_getStatusMessage(30, $selectAppntsQry);\n\n $pending_appt = array();\n\n while ($appnt = mysql_fetch_assoc($selectAppntsRes)) {\n\n if ($appnt['profile_pic'] == '')\n $appnt['profile_pic'] = $this->default_profile_pic;\n\n $pending_appt[] = array('apntDt' => $appnt['appointment_dt'], 'pPic' => $appnt['profile_pic'], 'email' => $appnt['email'],\n 'fname' => $appnt['first_name'], 'phone' => $appnt['phone'], 'apntTime' => date('H:i', strtotime($appnt['appointment_dt'])),\n 'apntDate' => date('Y-m-d', strtotime($appnt['appointment_dt'])), 'apptLat' => (double) $appnt['appt_lat'], 'apptLong' => (double) $appnt['appt_long'],\n 'addrLine1' => urldecode($appnt['address_line1']), 'addrLine2' => urldecode($appnt['address_line2']), 'notes' => $appnt['extra_notes'], 'bookType' => $appnt['booking_type']);\n }\n\n\n $errMsgArr = $this->_getStatusMessage(31, 2);\n\n return array('errNum' => $errMsgArr['errNum'], 'errFlag' => $errMsgArr['errFlag'], 'errMsg' => $errMsgArr['errMsg'], 'appointments' => $pending_appt); //,'test'=>$selectAppntsQry,'test1'=>$appointments);\n }", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'queueNo' => $this->queue_no,\n 'dateIn' => $this->timestamp_in,\n 'patientName' => $this->patient_name,\n 'fromRoom' => $this->from,\n 'toRoom' => $this->to,\n 'note' => $this->note,\n ];\n }", "function create_schedule(){\n\t\tfor ($i=0 ; $i< 6; $i++){\n\t\t\tfor ($j = $this->times[$i] ; $j < $this->times[$i+1] ; $j++){\n\t \t\t\t$this->bedroom[$j] = $this->temps[$this->bedroom_setting[$i]];\n\t\t\t\t$this->bathroom[$j] = $this->temps[$this->bathroom_setting[$i]];\n\t\t\t\t$this->kitchen[$j] = $this->temps[$this->kitchen_setting[$i]];\n\t\t\t\t$this->livingroom[$j] = $this->temps[$this->livingroom_setting[$i]];\n\t\t\t}\n\t\t}\n\t\t$result = [$this->bedroom,$this->bathroom,$this->kitchen, $this->livingroom];\n\t\treturn $result;\n\t}", "private function getActivities()\n {\n // Fetch the activity endpoint of the API\n $apiUrl = $this->eagleApi . '/activity';\n $activitiesString = file_get_contents($apiUrl);\n\n // Decode the response and return\n return json_decode($activitiesString);\n }", "public function getAgenda(ServiceBase $api, array $args)\n {\n $end_time = new SugarDateTime(\"+14 days\");\n $start_time = new SugarDateTime(\"-1 hour\");\n\n\n $meeting = BeanFactory::newBean('Meetings');\n $meetingList = $meeting->get_list('date_start', \"date_start > \" . $GLOBALS['db']->convert($GLOBALS['db']->quoted($start_time->asDb()), 'datetime') . \" AND date_start < \" . $GLOBALS['db']->convert($GLOBALS['db']->quoted($end_time->asDb()), 'datetime'));\n\n // Setup the breaks for the various time periods\n $datetime = new SugarDateTime();\n $today_stamp = $datetime->get_day_end()->getTimestamp();\n $tomorrow_stamp = $datetime->setDate($datetime->year,$datetime->month,$datetime->day+1)->get_day_end()->getTimestamp();\n\n\n $timeDate = TimeDate::getInstance();\n\n $returnedMeetings = array('today'=>array(),'tomorrow'=>array(),'upcoming'=>array());\n foreach ( $meetingList['list'] as $meetingBean ) {\n $meetingStamp = $timeDate->fromDb($meetingBean->date_start)->getTimestamp();\n $meetingData = $this->formatBean($api,$args,$meetingBean);\n\n if ( $meetingStamp < $today_stamp ) {\n $returnedMeetings['today'][] = $meetingData;\n } else if ( $meetingStamp < $tomorrow_stamp ) {\n $returnedMeetings['tomorrow'][] = $meetingData;\n } else {\n $returnedMeetings['upcoming'][] = $meetingData;\n }\n }\n\n return $returnedMeetings;\n }", "public function it_splits_the_elements_by_date_timerange_service()\n {\n $hours = $this->vacancyParser->hours('830-1130,14-20,2215-2330,2330-2345');\n\n $array = [\n ['startAt' => '8:30', 'finishAt' => '11:30'],\n ['startAt' => '14:00', 'finishAt' => '20:00'],\n ['startAt' => '22:15', 'finishAt' => '23:30'],\n ['startAt' => '23:30', 'finishAt' => '23:45'],\n ];\n\n $this->assertEquals($hours, $array);\n }", "public function testToArray()\n {\n $datetime = DateTime::createFromFormat('Y-m-d H:i:s.u', '2022-02-03 23:59:59.555666', DateTimeZone::TokyoAsia());\n $this->assertSame([\n 'year' => 2022,\n 'month' => 2,\n 'day' => 3,\n 'hour' => 23,\n 'minute' => 59,\n 'second' => 59,\n 'microsecond' => 555666,\n 'timestamp' => 1643900399,\n 'timezone' => 'Asia/Tokyo',\n ], $datetime->toArray());\n }", "private function getUpcomingMeetingList($id) {\n $currentDate = new \\DateTime();\n\n $em = $this->getDoctrine()->getManager();\n\n $q = $em->createQuery(\"SELECT e \"\n . \"FROM \\Acme\\bsceneBundle\\Entity\\Meeting e \"\n . \"WHERE e.account = :id AND e.date >= :date \"\n . \"ORDER BY e.date ASC\")->setParameters(array('date' => $currentDate, 'id' => $id));\n $eventList = $q->getArrayResult();\n\n return $eventList;\n }", "public function toArray($request)\n {\n $rooms = $this->rooms;\n $apiArr = array();\n \n /*\n Generation an API-link like PokeAPI or SWAPI.\n Not sure if this is recommended... prob not.\n Commented in return is a nested Json that contains the rooms.\n */\n foreach($rooms as $room){\n array_push($apiArr, request()->getHttpHost() . Config('enum.apiRooms') . $room->id);\n }\n\n return [\n 'id' => $this->id,\n 'description' => $this->description,\n 'type' => $this->type,\n 'price' => number_format($this->price / 100, 2),\n 'rooms_url' => $apiArr,\n //'rooms_data' => $this->rooms\n ];\n }", "public function toArray()\n {\n return [\n 'location' => $this->location(),\n 'from' => $this->from(),\n 'to' => $this->to(),\n 'pencil' => $this->pencil\n ];\n }", "function bmlt_add_meeting_to_database (&$in_out_meeting_array, ///< The meeting data, as an associative array. It must have the exact keys for the database table columns. No prompts, data type, etc. That will be supplied by the routine. Only a value. The 'id_bigint' field will be set to the new meeting ID.\n $in_templates_array ///< This contains the key/value templates for the meeting data.\n )\n {\n $ret = 0;\n \n global $g_server, $g_main_keys;\n \n // We break the input array into elements destined for the main table, and elements destined for the data table(s).\n $in_meeting_array_main = array_intersect_key ( $in_out_meeting_array, $g_main_keys );\n $in_meeting_array_other = array_diff_key ( $in_out_meeting_array, $g_main_keys );\n \n // OK, we'll be creating a PDO prepared query, so we break our main table data into keys, placeholders and values.\n $keys = array();\n $values = array();\n $values_placeholders = array();\n foreach ( $in_meeting_array_main as $key => $value )\n {\n if ( ($gOutput_level == 'PROLIX') && ($key == 'published') && !intval ( $value ) )\n {\n echo ( '<tr><td colspan=\"3\">Meeting '.$in_meeting_array_main['id_bigint'].' is not published</td></tr>' );\n }\n \n array_push ( $keys, $key );\n array_push ( $values, $value );\n array_push ( $values_placeholders, '?' );\n }\n \n // Now that we have the main table keys, placeholders and arrays, we create the INSERT query and add the meeting's main data.\n $keys = \"(`\".implode ( \"`,`\", $keys ).\"`)\";\n $values_placeholders = \"(\".implode ( \",\", $values_placeholders ).\")\";\n $sql = \"INSERT INTO `\".$g_server->GetMeetingTableName_obj().\"_main` $keys VALUES $values_placeholders\";\n \n try // Catch any thrown exceptions.\n { \n $result = c_comdef_dbsingleton::preparedExec ( $sql, $values );\n \n // If that was successful, we extract the ID for the meeting.\n if ( $result )\n {\n $sql = \"SELECT LAST_INSERT_ID()\";\n $row2 = c_comdef_dbsingleton::preparedQuery ( $sql, array() );\n if ( is_array ( $row2 ) && count ( $row2 ) == 1 )\n {\n $meeting_id = intval ( $row2[0]['last_insert_id()'] );\n }\n else\n {\n die ( \"Can't get the meeting ID!\" );\n }\n \n $ret = $meeting_id;\n $in_out_meeting_array['id_bigint'] = $meeting_id;\n \n // OK. We have now created the basic meeting info, and we have the ID necessary to create the key/value pairs for the data tables.\n // In 99% of the cases, we will only fill the _data table. However, we should check for long data, in case we need to use the _longdata table.\n $data_values = null;\n $longdata_values = null;\n \n // Here, we simply extract the parts of the array that correspond to the data and longdata tables.\n if ( isset ( $in_templates_array['data'] ) && is_array ( $in_templates_array['data'] ) && count ( $in_templates_array['data'] ) )\n {\n $data_values = array_intersect_key ( $in_meeting_array_other, $in_templates_array['data'] );\n }\n \n if ( isset ( $in_templates_array['longdata'] ) && is_array ( $in_templates_array['longdata'] ) && count ( $in_templates_array['longdata'] ) )\n {\n $longdata_values = array_intersect_key ( $in_meeting_array_other, $in_templates_array['longdata'] );\n }\n // What we do here, is expand each of the input key/value pairs to have the characteristics assigned by the template for that key.\n foreach ( $data_values as $key => &$data_value )\n {\n $val = $data_value; // We replace a single value with an associative array, so save the value.\n if ( isset ( $val ) )\n {\n $data_value = array();\n $data_value['meetingid_bigint'] = $meeting_id;\n $data_value['key'] = $key;\n $data_value['field_prompt'] = $in_templates_array['data'][$key]['field_prompt'];\n $data_value['lang_enum'] = $in_templates_array['data'][$key]['lang_enum'];\n $data_value['visibility'] = $in_templates_array['data'][$key]['visibility'];\n $data_value['data_string'] = $val;\n $data_value['data_bigint'] = intval ( $val );\n $data_value['data_double'] = floatval ( $val );\n }\n else\n {\n $data_value = null;\n unset ( $data_value );\n }\n }\n \n if ( is_array ( $longdata_values ) && count ( $longdata_values ) )\n {\n foreach ( $longdata_values as $key => &$londata_value )\n {\n $val = $data_value; // We replace a single value with an associative array, so save the value.\n if ( isset ( $val ) )\n {\n $londata_value['meetingid_bigint'] = $meeting_id;\n $londata_value['key'] = $key;\n $londata_value['field_prompt'] = $in_templates_array['data'][$key]['field_prompt'];\n $londata_value['lang_enum'] = $in_templates_array['data'][$key]['lang_enum'];\n $londata_value['visibility'] = $in_templates_array['data'][$key]['visibility'];\n if ( (isset ( $in_templates_array['longdata'][$key]['data_longtext'] ) && $in_templates_array['longdata'][$key]['data_longtext']) )\n {\n $londata_value['data_longtext'] = $val;\n $londata_value['data_blob'] = null;\n }\n elseif ( (isset ( $in_templates_array['longdata'][$key]['data_blob'] ) && $in_templates_array['longdata'][$key]['data_blob']) )\n {\n $londata_value['data_blob'] = $val;\n $londata_value['data_longtext'] = null;\n }\n else\n {\n $londata_value = null;\n }\n }\n else\n {\n $londata_value = null;\n unset ( $londata_value );\n }\n }\n }\n \n // OK. At this point, we have 2 arrays, one that corresponds to entries into the _data table, and the other into the _longdata table. Time to insert the data.\n \n // First, we do the data array.\n if ( isset ( $data_values ) && is_array ( $data_values ) && count ( $data_values ) )\n {\n foreach ( $data_values as $value )\n {\n if ( isset ( $value ) && is_array ( $value ) && count ( $value ) )\n {\n $keys = array();\n $values = array();\n $values_placeholders = array();\n \n foreach ( $value as $key => $val )\n {\n array_push ( $keys, $key );\n array_push ( $values, $val );\n array_push ( $values_placeholders, '?' );\n }\n \n if ( is_array ( $values ) && count ( $values ) )\n {\n // Now that we have the main table keys, placeholders and arrays, we create the INSERT query and add the meeting's main data.\n $keys = \"(`\".implode ( \"`,`\", $keys ).\"`)\";\n $values_placeholders = \"(\".implode ( \",\", $values_placeholders ).\")\";\n $sql = \"INSERT INTO `\".$g_server->GetMeetingTableName_obj().\"_data` $keys VALUES $values_placeholders\";\n $result = c_comdef_dbsingleton::preparedExec ( $sql, $values );\n }\n }\n }\n }\n \n // Next, we do the longdata array.\n if ( isset ( $longdata_values ) && is_array ( $longdata_values ) && count ( $longdata_values ) )\n {\n foreach ( $longdata_values as $value )\n {\n if ( isset ( $value ) && is_array ( $value ) && count ( $value ) )\n {\n $keys = array();\n $values = array();\n $values_placeholders = array();\n \n foreach ( $value as $key => $val )\n {\n array_push ( $keys, $key );\n array_push ( $values, $val );\n array_push ( $values_placeholders, '?' );\n }\n \n if ( is_array ( $values ) && count ( $values ) )\n {\n // Now that we have the longdata table keys, placeholders and arrays, we create the INSERT query and add the meeting's main data.\n $keys = \"(`\".implode ( \"`,`\", $keys ).\"`)\";\n $values_placeholders = \"(\".implode ( \",\", $values_placeholders ).\")\";\n $sql = \"INSERT INTO `\".$g_server->GetMeetingTableName_obj().\"_longdata` $keys VALUES $values_placeholders\";\n $result = c_comdef_dbsingleton::preparedExec ( $sql, $values );\n }\n }\n }\n }\n }\n else\n {\n die ( \"Can't create a new meeting!\" );\n }\n }\n catch ( Exception $e )\n {\n die ( '<pre>'.htmlspecialchars ( print_r ( $e, true ) ).'</pre>' );\n }\n \n return $ret;\n }", "public function jsonSerialize() {\r\r\n $array = [\r\r\n 'idLunch' => $this->getIdLunch(),\r\r\n 'oneEnterprise' => $this->getOneEnterprise()->getIdEnterprise(), \r\r\n 'onePurchasingFair' => $this->getOnePurchasingFair()->getIdPurchasingFair(), \r\r\n 'lunchesPlanned' => $this->getLunchesPlanned(), \r\r\n 'lunchesCanceled' => $this->getLunchesCanceled(), \r\r\n 'lunchesDetails' => $this->getLunchesDetails(),\r\r\n 'idParticipant' => $this->getIdParticipant()\r\r\n ];\r\r\n return $array;\r\r\n }", "public function participants()\n { \n // $date = explode(\" \", $this->created_at)[0];\n $date = $this->created_at;\n $matches = Match::whereDate('created_at', $date )\n ->where('location_id', $this->location_id)->get();\n $participants = collect([]);\n foreach ($matches as $m) {\n $participants->push($m->user);\n }\n return $participants;\n }", "function civicrm_api3_zoomevent_synczoomdata($params) {\n\t$allAttendees = [];\n\t$days = $params['days'];\n\t$pastDateTimeFull = new DateTime();\n\t$pastDateTimeFull = $pastDateTimeFull->modify(\"-\".$days.\" days\");\n\t$pastDate = $pastDateTimeFull->format('Y-m-d');\n\t$currentDate = date('Y-m-d');\n\n $apiResult = civicrm_api3('Event', 'get', [\n 'sequential' => 1,\n 'end_date' => ['BETWEEN' => [$pastDate, $currentDate]],\n ]);\n\t$allEvents = $apiResult['values'];\n\t$eventIds = [];\n\tforeach ($allEvents as $key => $value) {\n\t\t$eventIds[] = $value['id'];\n\t}\n\t$allUpdatedParticpants = [];\n\tforeach ($eventIds as $eventId) {\n\t\t$updatedParticpants = [];\n\t\t$list = CRM_CivirulesActions_Participant_AddToZoom::getZoomParticipantsData($eventId);\n\t\tif(empty($list)){\n\t\t\tcontinue;\n\t\t}\n\n\t\t$consolidatedList = [];\n\t\tforeach ($list as $email => $participant) {\n\t\t\t$participantDetails = $participant[0];\n\t\t\t// Picking the first entry time\n\t\t\t$firstEntry = key(array_slice($participant, 0, 1, true));\n\t\t\t// Picking the last last leaving time\n\t\t\t$lastEntry = key(array_slice($participant, -1, 1, true));\n\t\t\t$participantDetails['join_time'] = $participant[$firstEntry]['join_time'];\n\t\t\t$participantDetails['leave_time'] = $participant[$lastEntry]['leave_time'];\n\t\t\t$totalDuration = 0;\n\t\t\tforeach ($participant as $key => $eachJoin) {\n\t\t\t\t$totalDuration += $eachJoin['duration'];\n\t\t\t\t$participantDetails['duration_'.($key+1)] = $eachJoin['duration'];\n\t\t\t}\n\t\t\t$participantDetails['duration'] = $totalDuration;\n\t\t\t$consolidatedList[$email] = $participantDetails;\n\t\t\t$consolidatedList[$email]['has_civi_record'] = FALSE;\n\t\t}\n\n\t\t$emails = [];\n\t\tforeach ($consolidatedList as $key => $value) {\n\t\t\t$emails[] = $key;\n\t\t}\n\t\t$webinarId = getWebinarID($eventId);\n\t\t$meetingId = getMeetingID($eventId);\n\t\tif(!empty($webinarId)){\n\t\t\t$attendees = selectZoomParticipants($emails, $eventId);\n\t\t}elseif(!empty($meetingId)){\n\t\t\t$attendees = selectZoomParticipants($emails, $eventId);\n\t\t}\n\t\tforeach ($attendees as $attendee) {\n\t\t\t$updatedParticpants[$attendee['participant_id']] = CRM_NcnCiviZoom_Utils::updateZoomParticipantData($attendee['participant_id'], $consolidatedList[$attendee['email']]);\n\t\t\t$consolidatedList[$attendee['email']]['has_civi_record'] = TRUE;\n\t\t}\n\t\t$allUpdatedParticpants[$eventId] = $updatedParticpants;\n\t\t// Collecting the unmatched participants as exceptions\n\t\t$exceptionsArray = array();\n\t\tforeach ($consolidatedList as $value) {\n\t\t\tif(!$value['has_civi_record']){\n\t\t\t\t$exceptionsArray[] = $value;\n\t\t\t}\n\t\t}\n\t\tif(!empty($exceptionsArray)){\n\t\t\t$return['exception_notes'][$eventId] = CRM_NcnCiviZoom_Utils::updateUnmatchedZoomParticipantsToNotes($eventId, $exceptionsArray);\n\t\t}\n\t}\n\n\t$return['all_updated_participants'] = $allUpdatedParticpants;\n\n\treturn civicrm_api3_create_success($return, $params, 'Event');\n}", "public function toArray($request)\n {\n\n $date = date('d-M-Y', strtotime($this->created_at));\n $lateHours = $this->created_at->diff(new DateTime($date . ' 09:00:00'))->h;\n $lateMinutes = $this->created_at->diff(new DateTime($date . ' 09:00:00'))->i;\n\n $totalHours = (($lateHours * 60 ) + $lateMinutes) / 60;\n\n return [\n 'id' => $this->id,\n 'courier' => $this->courier->name,\n 'status' => $this->courier->status,\n 'supervisor' => $this->supervisor->name,\n 'time' => date('h:i A', strtotime($this->created_at)),\n 'date' => $date,\n 'lateTime' => $lateHours . ':' . $lateMinutes,\n 'lateTimeNumber' => number_format((float)$totalHours, 2, '.', '')\n ];\n }", "public function agency_meeting()\n {\n //获取该拍卖会信息\n $meeting = M('AuctionMeeting')->field('id, name, thumb, address, pre_starttime,pre_endtime, pre_address,starttime,endtime, agencyid, introduce')->find(I('get.id', '', 'int'));\n $this->meeting_res = $meeting;\n //dump($this->meeting_res);\n //p($this->meeting_res);\n\n $data['hits'] = array('exp', 'hits+1'); // 拍品点击量+1\n M('AuctionMeeting')->where(array('id' => I('get.id', 0, 'int')))->save($data); // 根据条件保存修改的数据\n\n#无数据\n //查询该拍卖会的最新预展信息\n $time = time();\n $this->meeting_yz = M('AuctionExhibit')->field('id, pre_starttime, pre_endtime')->where(\"UNIX_TIMESTAMP(starttime) > $time && meetingid >= '\" . mysql_real_escape_string(I('get.id', '', 'int')) . \"' && isshow = 1\")->order('starttime desc')->limit(1)->select();\n // p( $this->meeting_yz);//无数据\n#无数据\n //查询该拍卖会的最新拍卖信息\n $this->meeting_jg = M('AuctionExhibit')->field('id, starttime, endtime')->where(\"UNIX_TIMESTAMP(endtime) <= $time && meetingid >= '\" . mysql_real_escape_string(I('get.id', '', 'int')) . \"' && isshow = 1\")->order('starttime desc')->limit(1)->select();\n //p($this->meeting_jg);//无数据\n\n //获取该拍卖会所属机构信息\n $this->agency_res = $this->Model->field('id, name, address, thumb, tel, email, website, post')->where(array('id' => $meeting['agencyid']))->find();\n // p($this->agency_res);\n\n //获取该拍卖会下专场信息\n $this->list_num = M('AuctionMeeting')->where(array('pid' => I('get.id', '', 'int'), 'status' => 0))->count();\n// /p($this->list_num);\n// / $this->list = M('AuctionMeeting')->field('id, name, pid, money,pre_starttime, thumb, pre_endtime, starttime, address, endtime')->where(array('pid' => I('get.id', '', 'int'), 'status' => 0))->order('starttime desc')->select();\n\n $p = isset($_GET['p']) ? $_GET['p'] : 1;\n //每页显示的数量\n $prePage = 8;\n $list = M('AuctionMeeting')->field('id, name, pid, money,pre_starttime, thumb, pre_endtime, starttime, address, endtime')->where(array('pid' => I('get.id', '', 'int'), 'status' => 0))->order('starttime desc')->page($p . ',' . $prePage)->select();\n //p($list);\n $this->assign(\"list\", $list);\n $count = M('AuctionMeeting')->where(array('pid' => I('get.id', '', 'int'), 'status' => 0))->count(); // 查询满足要求的总记录数\n $Page = new \\Think\\Page($count, $prePage); // 实例化分页类 传入总记录数和每页显示的记录数\n $Page->setConfig('header', '共%TOTAL_ROW%条记录');\n $Page->setConfig('prev', '上一页');\n $Page->setConfig('next', '下一页');\n $Page->setConfig('first', '首页');\n $Page->setConfig('last', '尾页');\n\n $Page->setConfig('theme', '%HEADER% %FIRST% %UP_PAGE% %LINK_PAGE% %DOWN_PAGE% %END%');\n $show = $Page->show(); // 分页显示输出\n //p($show);\n $this->assign('page', $show); // 赋值分页输出\n\n //p($this->list);\n\n //拍品推荐\n $this->pptj_res = M('AuctionExhibit')->field('id, name, thumb, price, endprice, areaid, starttime')->where('isshow = 1')->limit(10)->order('hits desc')->select();\n //p( $this->pptj_res);\n //分配body css\n $this->assign(\"css\", 'selling-panel selling-preview-detail');\n $this->display('Front:agency_meeting');\n }", "public function index()\n {\n /*\n if (isset($_SESSION['access_token']) && $_SESSION['access_token']) {\n $this->client->setAccessToken($_SESSION['access_token']);\n $service = new Google_Service_Calendar($this->client);\n\n $calendarId = 'primary';\n\n\n $results = $service->events->listEvents($calendarId);\n return $results->getItems();\n\n } else {\n return redirect()->route('oauthCallback');\n }\n */\n\n if (Session::has('access_token')) {\n $this->client->setAccessToken(Session::get('access_token'));\n $service = new Google_Service_Calendar($this->client);\n\n $calendarId = 'primary';\n\n\n $results = $service->events->listEvents($calendarId);\n\n foreach ($results as $key => $value) {\n\n //$res = Meeting::where('title', $meetings[0]['title'][2])->where('name', $meetings[0]['name'][2])->where('start_time', $meetings[0]['start_time'][2])->where('end_time', $meetings[0]['end_time'][2])->first();\n\n \n $m = new Meeting;\n //$m->title = $results->getItems()[0]->description;\n $m->description = $results->getItems()[0]->description;\n $m->name = $results->getItems()[0]->organizer->displayName;\n $m->start_time = trim(preg_replace('/[a-zA-Z]/',' ',$results->getItems()[0]->start->dateTime));\n $m->end_time = trim(preg_replace('/[a-zA-Z]/',' ',$results->getItems()[0]->end->dateTime));\n //$m->end_time = $results->getItems()[0]->end->dateTime;\n $m->save();\n \n \n }\n\n return dd($results->getItems());\n\n //return dd($results->getItems()[0]->description);\n //return $results->getItems();\n\n } else {\n return redirect()->route('oauth2Callback');\n }\n\n }", "function getAttendees(){\n $this->attendees = array();\n $i = 0;\n $schoolTable = 'school_'.$this->schoolId;\n $query = \"SELECT id, name AS attendeeName, logintype, email, phone, hotel, room, \n committee AS committeeId, country AS countryId \n FROM $schoolTable\";\n $result = mysql_query($query) or die(mysql_error());\n while($row = mysql_fetch_array($result)){\n $this->attendees[$i] = array();\n $this->attendees[$i]['id'] = $row['id'];\n $this->attendees[$i]['name'] = $row['attendeeName'];\n $this->attendees[$i]['logintype'] = $row['logintype'];\n $this->attendees[$i]['committeeId'] = $row['committeeId'];\n $this->attendees[$i]['countryId'] = $row['countryId'];\n $this->attendees[$i]['email'] = $row['email'];\n $this->attendees[$i]['phone'] = $row['phone'];\n $this->attendees[$i]['hotel'] = $row['hotel'];\n $this->attendees[$i]['room'] = $row['room'];\n $i++;\n }\n // Populate empty rows if attendees table isn't filled\n for($i; $i<$this->totalAttendees; $i++){\n $this->attendees[$i] = array();\n $this->attendees[$i]['id'] = 0;\n $this->attendees[$i]['name'] = 0;\n $this->attendees[$i]['logintype'] = 0;\n $this->attendees[$i]['committeeId'] = 0;\n $this->attendees[$i]['countryId'] = 0;\n $this->attendees[$i]['email'] = 0;\n $this->attendees[$i]['phone'] = 0;\n $this->attendees[$i]['hotel'] = 0;\n $this->attendees[$i]['room'] = 0;\n }\n }", "public function toArray($request)\n {\n return [\n 'id' => $this->id,\n 'title' => $this->name,\n 'startDate' => $this->start_time,\n 'endDate' => $this->end_time,\n 'section' => $this->section->id,\n 'course' => $this->section->course->id\n ];\n }", "public static function getMeeting($meetingId, $useCache = true, $isWebinar = false)\n {\n $cache = StudipCacheFactory::getCache();\n\n if ($useCache && $meeting = $cache->read('zoom-meeting-' . $meetingId)) {\n $meeting = json_decode($meeting);\n\n // Convert start time to DateTime object for convenience.\n $time = is_array($meeting->occurrences) ? $meeting->occurrences[0]->start_time : $meeting->start_time;\n $start_time = new DateTime($time, new DateTimeZone(self::ZOOM_TIMEZONE));\n $start_time->setTimezone(new DateTimeZone(self::LOCAL_TIMEZONE));\n $meeting->start_time = $start_time;\n\n return $meeting;\n } else {\n $result = self::_call(($isWebinar ? 'webinars/' : 'meetings/') . $meetingId);\n\n // Meeting found, all is well.\n if ($result['statuscode'] == 200) {\n $meeting = $result['response'];\n\n $cache->write('zoom-meeting-' . $meetingId, json_encode($meeting), self::CACHE_LIFETIME);\n // Convert start time to DateTime object for convenience.\n $time = is_array($meeting->occurrences) ? $meeting->occurrences[0]->start_time : $meeting->start_time;\n $start_time = new DateTime($time, new DateTimeZone(self::ZOOM_TIMEZONE));\n $start_time->setTimezone(new DateTimeZone(self::LOCAL_TIMEZONE));\n $meeting->start_time = $start_time;\n $meeting->duration = is_array($meeting->occurrences) ?\n $meeting->occurrences[0]->duration :\n $meeting->duration;\n\n // Meeting not found in Zoom\n } else if ($result['statuscode'] == 404) {\n $cache->expire('zoom-meeting-' . $meetingId);\n $meeting = 404;\n // Some other problem.\n } else {\n $meeting = null;\n }\n\n return $meeting;\n }\n }", "public function legacySave(){\n $retval = array();\n foreach($this->attendees as $id => $attendee){\n $retval[] = $this->realLegacySave($attendee);\n }\n\n return $retval;\n }", "public function toArray():array {\n return [\n 'name' => $this->name,\n 'description' => $this->description,\n 'points' => $this->points,\n 'deadline' => $this->deadline,\n 'for_newcomer' => $this->for_newcomer === \"1\" ?true:false\n ];\n }", "public function toArray()\n {\n return array(\n 'id' => $this->id,\n 'description' => $this->description,\n 'involvementKindID' => $this->involvementKindID,\n 'reportKindID' => $this->reportKindID,\n 'locationID' => $this->locationID,\n 'personID' => $this->personID,\n 'departmentID' => $this->departmentID,\n 'dateTime' => $this->dateTime,\n 'statusID' => $this->statusID,\n 'actionTaken' => $this->actionTaken,\n 'photoPath' => $this->photoPath\n );\n }", "public function toArray(): array\n {\n return array(\n 'id' => $this->ID,\n 'public_id' => $this->PublicID,\n 'request_time' => $this->RequestTime\n );\n }", "function get_apnt_times($starttime,$endtime){\r\n $vd[] = get_times($starttime, $endtime);\r\n return $flat = array_unique(call_user_func_array('array_merge', $vd));\r\n }", "public function getItemsPopulated()\r\n {\r\n $start = new DateTime($this->begin);\r\n $items = $this->items;\r\n\r\n foreach ($items as $item) {\r\n if($item->begin) {break;} // legacy meeting\r\n $start = $this->populateTime($item, $start);\r\n }\r\n return $items;\r\n }", "private function getStoredReservationsJsonStructure(): array\n {\n return [\n 'data' => [\n '*' => [\n 'first_name',\n 'last_name',\n 'middle_name',\n 'phone',\n 'birth_date',\n 'sex',\n 'appointment_time',\n 'webOrderId'\n ]\n ]\n ];\n }", "public function toArray($request)\n {\n\n if ($this->resource->relationLoaded('schedules')) {\n [\n 'available_day' => $available_day,\n 'available_from' => $available_from,\n 'available_to' => $available_to\n ] = static::formatAvailableTime($this->available_time);\n }\n return [\n 'id' => $this->id,\n 'name' => $this->name,\n \"first_name_ar\" => $this->first_name_ar,\n \"last_name_ar\" => $this->last_name_ar,\n \"first_name_en\" => $this->first_name_en,\n \"last_name_en\" => $this->last_name_en,\n\n \"description_ar\" => $this->description_ar,\n \"description_en\" => $this->description_en,\n \"title_ar\" => $this->title_ar,\n \"title_en\" => $this->title_en,\n 'description' => $this->description,\n 'title' => $this->title,\n 'email' => $this->email,\n 'phone' => $this->phone,\n 'price' => $this->price,\n 'period' => $this->period,\n 'civil_id' => $this->civil_id,\n 'license_number' => $this->license_number,\n 'gender' => $this->gender == Doctor::GENDER_MALE ? __(\"Male\") : __(\"Female\"),\n 'phone_verified_at' => $this->phone_verified_at,\n 'img' => fileUrl($this->img),\n 'logo' => fileUrl($this->logo),\n 'token' => null,\n 'verfication_code' => $this->verification_code,\n\n //relashions\n 'category' => new CategoryResource($this->whenLoaded('category')),\n 'sub_categories' => CategoryResource::collection($this->whenLoaded('sub_categories')),\n 'schedules' => $this->when($this->resource->relationLoaded('schedules'), $this->weakly_schedules),\n 'available_day' => $this->when($this->resource->relationLoaded('schedules'), $available_day ?? null),\n 'available_from' => $this->when($this->resource->relationLoaded('schedules'), $available_from ?? null),\n 'available_to' => $this->when($this->resource->relationLoaded('schedules'), $available_to ?? null),\n 'is_online' => $this->isOnline(),\n 'is_favourite' => $this->isFavourite(),\n 'reviews' => RatingResource::collection($this->whenLoaded('ratings')),\n 'rating' => round($this->ratings->avg('rate') ?? 0, 0),\n 'papers' => AttachmentResource::collection($this->whenLoaded('papers')),\n\n\n ];\n }", "public function toArray($request)\n {\n //现在还不知道怎么把完成的 tasks, 按完成日期分组输出\n $task = Tasks::query()\n\n ->whereDate(\"finished_date\", $this->date)\n ->get();\n\n\n return [\n// 'date' => $this->date,\n// 'task' => $task\n 'id' => $this->id,\n 'title' => $this->title,\n 'task' => $this->task,\n 'user_id' => $this->author_id,\n 'private' => $this->private,\n 'finished' => $this->finished,\n 'finished_date' => $this->finished_date ? Carbon::parse($this->finished_date)->format('Y-m-d') : null,\n 'finished_time' => $this->finished_date ? Carbon::parse($this->finished_date)->format('H:m:s') : null,\n ];\n }", "public function getParticipants(): Collection;" ]
[ "0.6517258", "0.61099863", "0.5971747", "0.5840125", "0.57448786", "0.5728306", "0.5682719", "0.5643105", "0.56227374", "0.5603327", "0.55897194", "0.55660146", "0.55634385", "0.55582196", "0.5527764", "0.55059314", "0.54887706", "0.5424365", "0.5383251", "0.53515047", "0.53466636", "0.53466636", "0.53245276", "0.53064746", "0.53008175", "0.5291749", "0.52826136", "0.52640355", "0.5236848", "0.52314", "0.5227695", "0.5225052", "0.52227974", "0.52191526", "0.521428", "0.52092886", "0.5199565", "0.5186643", "0.5162849", "0.5154096", "0.51521015", "0.51308537", "0.5129511", "0.51123774", "0.51093364", "0.5106956", "0.51038396", "0.5102952", "0.5102946", "0.5093936", "0.5082662", "0.5071708", "0.50695825", "0.5057788", "0.50518394", "0.5034443", "0.5022025", "0.50156194", "0.50152695", "0.50110584", "0.50009763", "0.49872413", "0.49754477", "0.4972845", "0.49715197", "0.49699172", "0.49657008", "0.49610543", "0.49593514", "0.49565884", "0.49560115", "0.49500525", "0.494506", "0.49363506", "0.4931525", "0.49312705", "0.4929862", "0.49266115", "0.4926016", "0.49249458", "0.49244654", "0.49196398", "0.491896", "0.4913195", "0.49056938", "0.4897758", "0.48920855", "0.4887093", "0.48759302", "0.48738635", "0.48728728", "0.48707655", "0.48687238", "0.4858154", "0.48535198", "0.48482412", "0.48481327", "0.4847323", "0.4846341", "0.48352745" ]
0.6015301
2
Url call for each Exception status
public function indexAction() { $e = $this->getException(); if ($e instanceof \FMUP\Exception\Status) { $this->errorStatus($e->getStatus()); } $this->render(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getFailureUrl();", "private function callStatus() {\n try {\n $this->status = $this->client->request('GET', $this->url->full_url, [\n 'allow_redirects' => false\n ]);\n } catch (\\Exception $ex) {\n $this->status = $ex->getResponse();\n }\n }", "abstract protected function echoExceptionWeb($exception);", "public function uriError()\n {\n header(\"HTTP/1.0 404\");\n exit();\n }", "public function validateFailedURL() {\r\n return $this->validateResultURL(self::FAILED_STATUS);\r\n }", "public function test_IndexError(){\n\t\t$this->validateTestException(\n\t\t\t$this->fullURL,\n\t\t\t'GET',\n\t\t\t$this->data,\n\t\t\t'NotImplementedException',\n\t\t\t'index'\n\t\t);\n\t}", "public function testErrorIsThrownIfURLNotFound()\n {\n $this->mockHttpResponses([new Response(404, [], view('tests.google-404')->render())]);\n\n self::$importer->get('google-not-found-url', now()->subYear(), now()->addYear());\n }", "public function getExceptions();", "public function http(HttpResponseException $ex);", "function error_handler($exception) {\n\tglobal $config;\n\theader('HTTP/1.0 404 Not Found');\n\textract(array('error'=>$exception->getMessage()));\n\trequire($config['VIEW_PATH'].'404.php');\n\tdie();\n}", "function internalServerError($error)\n{\n header('HTTP/1.1 500 Internal Server Error');\n $emailIds = array(\"[email protected]\", \"[email protected]\", \"[email protected]\", \"[email protected]\");\n foreach ($emailIds as $to)\n sendMail($to, \"Alert! error occurred in apis\", $error);\n}", "private static function pageNotFound()\n {\n if (self::$notFound && is_callable(self::$notFound)) {\n call_user_func(self::$notFound);\n } else {\n header($_SERVER['SERVER_PROTOCOL'] . ' 404 Not Found');\n throw new ExceptionHandler(\"Hata\", \"Controller bulunamadı\");\n }\n }", "public function getErrorResponses();", "public function Access_error ()\n\t\t{\n\t\t\t$errMsg[0]['error'] = \"Invalid URL!\";\n\t\t\treturn json_encode ($errMsg);\n\t\t}", "public function error404()\n {\n }", "function goodrds_image_exceptions($id) {\n\t\t\n\t\t$key = false;\n\t\t$id = str_replace(array('#','id_'), '', $id);\n\t\tforeach ($this->goodrds_options['exceptions']['ids'] as $k => $exID) {\n\t\t\t$exID = str_replace(array('#','id_'), '', $exID);\n\t\t\tif ($exID == $id)\n\t\t\t\t$key = $k;\n\t\t}\n\t\tif ($key)\n\t\t\treturn $this->goodrds_options['exceptions']['urls'][$key];\n\t\t\t\n\t\treturn $key; //false\n\t}", "public static function error($status,$message){\r\n throw new \\Luracast\\Restler\\RestException($status, $message);\r\n }", "function getStatusCode();", "public function actionError() {\n if ($error = Yii::app()->errorHandler->error) {\n\t\t\t$this->sendRestResponse(500,array(\n\t\t\t\t'status' => false,\n\t\t\t\t'message' => $error['message'],\n\t\t\t\t'data' => $error,\n\t\t\t));\t\t\t\n }\n\t}", "public function errorHttp() {\n return $this->view->load(\"errors/404\");\n }", "private function getErrorPage($url){\r\n header(\"HTTP/1.0 404 Not Found\");\r\n die(strtoupper(\"error 404 $url not found\"));\r\n }", "function getHttpStatus();", "function exceptionHandler($e) {\n $msg = array(\"status\" => \"500\", \"message\" => $e->getMessage(), \"file\" => $e->getFile(), \"line\" => $e->getLine());\n $usr_msg = array(\"status\" => \"500\", \"message\" => \"Sorry! Internal server error!\");\n header(\"Access-Control-Allow-Origin: *\"); \n header(\"Content-Type: application/json; charset=UTF-8\"); \n header(\"Access-Control-Allow-Methods: GET, POST\");\n echo json_encode($usr_msg);\n logError($msg);\n\n }", "public function crawlFailed(UriInterface $url, RequestException $requestException, ?UriInterface $foundOnUrl = null)\n {\n echo 'failed';\n }", "public function crawlFailed(UriInterface $url, RequestException $requestException, ?UriInterface $foundOnUrl = null)\n {\n echo 'Failed';\n }", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function getStatusCode();", "public function actionError()\n {\n if($error=Yii::app()->errorHandler->error)\n {\n if($error['code'] != 404 || !isset($aErrorMsg[$error['errorCode']])){\n Yii::log(' error : ' . $error['file'] .\":\". $error['line'] .\":\". $error['message'], 'error', 'system');\n }\n $ret = new ReturnInfo(FAIL_RET, Yii::t('exceptions', $error['message']), intval($error['errorCode']));\n if(Yii::app()->request->getIsAjaxRequest()){\n echo json_encode($ret);\n \n }else{\n if( empty($error['errorCode']) ){\n if(isset($this->aErrorMsg[$error['code']])){\n if(empty($this->aErrorMsg[$error['code']]['message'])) {\n $this->aErrorMsg[$error['code']]['message'] = $error['message'];\n }\n $this->render('error', $this->aErrorMsg[$error['code']]);\n }else{\n $this->render('error', $this->aErrorMsg['1000']);\n }\n }else{\n $this->render('error', $this->aErrorMsg[ $error['errorCode'] ]);\n \n }\n }\n \n } \n }", "public function getStatusUrl()\n {\n return Mage::helper('oro_ajax')->getAjaxStatusUrl($this->_urlParams);\n }", "function statusCode()\n {\n }", "public static function exception_handler($exception) { \n ResponseFactory::send($exception->getMessage()); //Send exception message as response.\n }", "public function testUrlGenerationWithUrlFilterFailureMethod(): void\n {\n $this->expectException(CakeException::class);\n $this->expectExceptionMessageMatches(\n '/URL filter defined in .*RouterTest\\.php on line \\d+ could not be applied\\.' .\n ' The filter failed with: /'\n );\n $routes = Router::createRouteBuilder('/');\n $routes->connect('/{lang}/{controller}/{action}/*');\n $request = new ServerRequest([\n 'params' => [\n 'plugin' => null,\n 'lang' => 'en',\n 'controller' => 'Posts',\n 'action' => 'index',\n ],\n ]);\n Router::setRequest($request);\n\n Router::addUrlFilter(function () {\n throw new Exception();\n });\n Router::url(['controller' => 'Posts', 'action' => 'index', 'lang' => 'en']);\n }", "public function generateFailed();", "function http_throw($code = 404)\n{\n ob_start();\n\n include(__DIR__ . '/../Exceptions/404/404.html');\n $contents = ob_get_clean();\n\n http_response_code($code);\n\n echo $contents;\n}", "public function testErrorIsThrownIfURLIsInvalid()\n {\n self::$importer->get('invalid-google-url', now()->subYear(), now()->addYear());\n }", "public function getStatusCode() {}", "public function index() {\r\n header(\"Content-Type: application/json\");\r\n header(\"HTTP/1.1 404\", true, 404);\r\n\r\n $response = $this->apiv1_core->errorResponse(404001, '');\r\n echo json_encode($response);\r\n return;\r\n }", "public function logError(){\n AbstractLoggedException::$dbMessage .= \"Invalid URI requestd; \";\n parent::log();\n }", "public function render($request, Exception $e)\n\t{\n if ($e instanceof \\App\\Exceptions\\CouponException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\CardDeclined)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\OrderCreationException)\n return \\Redirect::to('checkout/confirm')->with(array('status' => 'danger' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\RegisterException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => 'Vous êtes déjà inscrit à ce colloque'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création de campagne sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\ContentCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création du contenu pour la campagne'));\n\n if ($e instanceof \\App\\Exceptions\\FileUploadException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec le téléchargement du fichier '.$e->getMessage() ));\n\n if ($e instanceof \\App\\Exceptions\\SubscribeUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur synchronisation email vers mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneSendException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec l\\'envoi de la newsletter, mailjet à renvoyé une erreur'));\n\n if ($e instanceof \\App\\Exceptions\\DeleteUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec la suppression de l\\'abonnés sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\UserNotExistException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Cet utilisateur n\\'existe pas'));\n\n\t\tif ($e instanceof \\App\\Exceptions\\StockCartException)\n\t\t\treturn redirect()->back()->with(array('status' => 'warning' , 'message' => 'Il n\\'y a plus assez de stock pour cet article'));\n\n\t\tif ($e instanceof \\App\\Exceptions\\AdresseNotExistException)\n\t\t\treturn redirect()\n\t\t\t\t->back()\n\t\t\t\t->with(['status' => 'warning' , 'message' => 'Il n\\'existe aucune adresse de livraison, veuillez indiquer une adresse valide dans ', 'link' => 'profil']);\n\n if ($e instanceof \\Symfony\\Component\\HttpKernel\\Exception\\MethodNotAllowedHttpException)\n return redirect()->to('admin');\n\n\t\tif($e instanceof \\Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException)\n\t\t\treturn response()->view('404', [], 404);\n\n\t\tif ($e instanceof \\Illuminate\\Session\\TokenMismatchException)\n\t\t\treturn redirect('auth/login');\n\n\t\treturn parent::render($request, $e);\n\t}", "public function render($request, Exception $e)\n\t{\n if ($e instanceof \\App\\Exceptions\\CouponException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\CardDeclined)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\OrderCreationException)\n return \\Redirect::to('checkout/confirm')->with(array('status' => 'danger' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\RegisterException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => 'Vous êtes déjà inscrit à ce colloque'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création de campagne sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\ContentCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création du contenu pour la campagne'));\n\n if ($e instanceof \\App\\Exceptions\\FileUploadException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec l\\'upload '.$e->getMessage() ));\n\n if ($e instanceof \\App\\Exceptions\\SubscribeUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur synchronisation email vers mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneSendException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec l\\'envoi de la newsletter, mailjet à renvoyé une erreur'));\n\n if ($e instanceof \\App\\Exceptions\\DeleteUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec la suppression de l\\'abonnés sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\UserNotExistException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Cet email n\\'existe pas'));\n\n if ($e instanceof \\Symfony\\Component\\HttpKernel\\Exception\\MethodNotAllowedHttpException)\n return redirect()->to('admin');\n\n\t\treturn parent::render($request, $e);\n\t}", "public function crawlFailed(\n UriInterface $url,\n RequestException $requestException,\n ?UriInterface $foundOnUrl = null\n ) {\n parent::crawlFailed($url, $requestException, $foundOnUrl);\n\n $statusCode = $requestException->getCode();\n\n if ($this->isExcludedStatusCode($statusCode)) {\n return;\n }\n\n $this->log->warning(\n $this->formatLogMessage($url, $requestException, $foundOnUrl)\n );\n }", "public function is_404();", "public function show404() {\n header(\"HTTP/1.0 404 Not Found\");\n throw new Exception('404 Not Found');\n }", "public function getHttpStatusCode();", "public function indexAction()\n {\n Extra_ErrorREST::setInvalidHTTPMethod($this->getResponse());\n }", "function getHTTPCode() {\n\n return 500;\n\n }", "function getErrPage(){\n}", "public static function http404() {\n\t\tself::$global['CONTEXT']=$_SERVER['REQUEST_URI'];\n\t\tself::error(\n\t\t\tself::resolve(self::TEXT_NotFound),404,debug_backtrace(FALSE)\n\t\t);\n\t}", "public function index_get()\n {\n $this->response([\n 'Operation' => \"error\",\n 'Message' => 'Please Post Data'\n ], REST_Controller::HTTP_NOT_FOUND); // NOT_FOUND (404) being the HTTP response code\n }", "public function failAction()\n {\n //====================================================================//\n // Return Dummy Response\n return new JsonResponse(array('result' => 'Ko'), 500);\n }", "public function show404();", "public function errorOccured();", "private function urlExist() {\n if (!$this->webhook->url) {\n // throw an exception\n $this->missingEx('url');\n }\n }", "public function getPageAccessFailureReasons() {}", "public function errorAction()\r\n {\r\n $errors = $this->_getParam('error_handler');\r\n $messages = array();\r\n\r\n switch ((string)$errors->type) {\r\n case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_NO_CONTROLLER:\r\n case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_NO_ACTION:\r\n // 404 error -- controller or action not found\r\n $this->getResponse()->setRawHeader('HTTP/1.1 404 Not Found');\r\n\r\n $messages[] = Zoo::_(\"The page you requested was not found.\");\r\n if (ZfApplication::getEnvironment() == \"development\" || ZfApplication::getEnvironment() == \"staging\") {\r\n $messages[] = $errors->exception->getMessage();\r\n }\r\n break;\r\n\r\n case Zend_Controller_Plugin_ErrorHandler::EXCEPTION_OTHER:\r\n case 0:\r\n // application error\r\n //$messages[] = Zoo::_(\"An unexpected error occurred with your request. Please try again later.\");\r\n $messages[] = $errors->exception->getMessage();\r\n if (ZfApplication::getEnvironment() == \"development\" || ZfApplication::getEnvironment() == \"staging\") {\r\n $trace = $errors->exception->getTrace();\r\n foreach (array_keys($trace) as $i) {\r\n if ($trace[$i]['args']) {\r\n foreach ($trace[$i]['args'] as $index => $arg) {\r\n if (is_object($arg)) {\r\n $trace[$i]['args'][$index] = get_class($arg);\r\n }\r\n elseif (is_array($arg)) {\r\n $trace[$i]['args'][$index] = \"array\";\r\n }\r\n }\r\n }\r\n $trace[$i]['file_short'] = \"..\".substr($trace[$i]['file'], strrpos(str_replace(\"\\\\\", DIRECTORY_SEPARATOR, $trace[$i]['file']), DIRECTORY_SEPARATOR));\r\n }\r\n $this->view->assign('trace', $trace);\r\n }\r\n break;\r\n\r\n default:\r\n // application error\r\n $this->getResponse()->setRawHeader('HTTP/1.1 '.$errors->type);\r\n $messages[] = $errors->exception->getMessage();\r\n break;\r\n }\r\n\r\n // Clear previous content\r\n $this->getResponse()->clearBody();\r\n\r\n $this->view->assign('errormessages', $messages);\r\n }", "public function badUrlProvider() {\n\n $badRedirects[\"ip: 127.0.0.1\"] = array(\"http://127.0.0.1\", false);\n\n // Anything that resolves to zero needs to be tested carefully due to falsiness\n $badRedirects[\"ip: 0\"] = array(\"http://0/data.json\", false);\n\n // Hex is bad\n $badRedirects[\"ip: hex\"] = array(\"http://0x7f000001/data.json\", false);\n\n // So is octal\n $badRedirects[\"ip: octal\"] = array(\"http://0123/data.json\", false);\n\n // We don't like mixed hex and octal either\n $badRedirects[\"ip: mixed hex/octal/decimal\"] = array(\"http://0x7f.0x0.0.0/data.json\", false);\n\n // We don't even like dotted-quads\n $badRedirects[\"ip: dotted-quad\"] = array(\"http://111.22.34.56/data.json\", false);\n\n // Don't you come around here with any of that IPv6 crap\n $badRedirects[\"ipv6: localhost\"] = array(\"http://[::1]\", false);\n\n // Domains that resolve to IPv4 localhost? NFW.\n $badRedirects[\"localhost.ip4\"] = array(\"https://localhost.ip4/\", [['type' => 'A', 'ip' => '127.0.0.1']]);\n\n // Domains that resolve to IPv6 localhost? Get out!\n $badRedirects[\"localhost.ip6\"] = array(\"https://localhost.ip6:443\", [['type' => 'AAAA', 'ipv6' => '::1']]);\n\n // Domains that resolve to IPv6 addresses that represent IPv4 private ranges? Not on our watch!\n $badRedirects[\"localhost2.ip6\"] = array(\"http://localhost2.ip6:80\", [['type' => 'AAAA', 'ipv6' => '::ffff:127.0.0.1']]);\n $badRedirects[\"private1.ip6\"] = array(\"https://private1.ip6:80\", [['type' => 'AAAA', 'ipv6' => '::ffff:192.168.1.18']]);\n $badRedirects[\"private2.ip6\"] = array(\"https://private2.ip6:80\", [['type' => 'AAAA', 'ipv6' => '::ffff:10.0.0.1']]);\n $badRedirects[\"private3.ip6\"] = array(\"http://private3.ip6:80\", [['type' => 'AAAA', 'ipv6' => '::ffff:127.0.0.2']]);\n\n // Domains that resolve to IPv6 link-local adddresses? Hell no!\n $badRedirects[\"linklocal.ip6\"] = array(\"https://linklocal.ip6/\", [['type' => 'AAAA', 'ipv6' => 'fe80::']]);\n\n return $badRedirects;\n }", "function print_exception(Exception $e) {\n $debug = ini_get('display_errors');\n\n ob_end_clean();\n\n if ($e instanceof HttpException) {\n if (!headers_sent()) header('HTTP/1.0 '.$e->getStatusCode().' '.$e->getTitle());\n echo '<h1>'.$e->getTitle().'</h1>';\n } else {\n if (!headers_sent()) header('HTTP/1.0 500 Internal Server Error');\n echo '<h1>Internal Server Error</h1>';\n }\n if ($debug) {\n echo '<h2>'.get_class($e).': '.$e->getMessage().'</h2>';\n echo '<pre>'.$e->getTraceAsString().'</pre>';\n }\n}", "public function runFailed();", "public function force404();", "public function force404();", "public function actionError()\n {\n if (($exception = Yii::$app->getErrorHandler()->exception) === null) {\n // action has been invoked not from error handler, but by direct route, so we display '404 Not Found'\n $exception = new HttpException(404, Yii::t('yii', 'Page not found.'));\n }\n\n if ($exception instanceof HttpException) {\n $code = $exception->statusCode;\n } else {\n $code = $exception->getCode();\n }\n if ($exception instanceof Exception) {\n $name = $exception->getName();\n } else {\n $name = Yii::t('yii', 'Error');\n }\n if ($code) {\n $name .= \" (#$code)\";\n }\n\n if ($exception instanceof UserException) {\n $message = $exception->getMessage();\n } else {\n $message = Yii::t('yii', 'An internal server error occurred.');\n }\n $statusCode = $exception->statusCode ? $exception->statusCode : 500;\n if (Yii::$app->getRequest()->getIsAjax()) {\n return \"$name: $message\";\n } else {\n return $this->render('error', [\n 'code' => $statusCode,\n 'name' => $name,\n 'message' => $message\n ]);\n }\n }", "public function index() {\n\n\t\treturn $this->httpError(404);\n\t}", "public static function notFound(){\n\n throw new \\yii\\web\\HttpException(404, 'Not Found', 405);\n }", "protected function errorAction() {}", "public function getStatusCode()\n {\n }", "public function getException();", "public function indexAction()\n {\n $this->view->errorCode = static::ERROR_CODE_500;\n $this->view->errorMessage = 'Server Internal Error';\n $errors = $this->_getParam('error_handler');\n\n if (!$errors || !$errors instanceof \\ArrayObject) {\n $this->view->errorMessage = 'You have reached the error page';\n return;\n }\n\n // the request\n $this->view->request = $errors->request;\n\n // conditionally display exceptions\n $this->view->displayExceptions = $this->getInvokeArg('displayExceptions');\n $this->view->exception = $errors->exception;\n\n $errorCode = static::ERROR_CODE_500;\n if ($errors->exception instanceof Exception) {\n $this->_handleException($errors->exception);\n $exceptionType = get_class($errors->exception);\n switch ($exceptionType) {\n case 'Zend_Controller_Router_Exception':\n case 'Zend_Controller_Action_Exception':\n if (static::ERROR_CODE_404 == $errors->exception->getCode()) {\n $errorCode = static::ERROR_CODE_404;\n }\n break;\n case 'Zend_Controller_Dispatcher_Exception':\n $errorCode = static::ERROR_CODE_404;\n }\n $this->view->errorCode = $errorCode;\n $this->getResponse()->setHttpResponseCode($errorCode);\n }\n\n if (defined('APPLICATION_ENV') && (in_array(APPLICATION_ENV, array('development', 'staging', 'test')))) {\n $this->view->displayExceptions = true;\n }\n\n $this->view->metaTitle = $this->view->_('System is in maintenance mode');\n\n if (static::ERROR_CODE_404 == $this->view->errorCode) {\n $this->view->errorMessage = 'We are sorry but the page you requested cannot be found.';\n }\n\n $this->render('index');\n }", "function failed($reason) {\n // Status for ELB, will cause ELB to remove instance.\n header(\"HTTP/1.0 503 Service unavailable: failed $reason check\");\n // Status for the humans.\n print \"Server is DOWN<br>\\n\";\n echo \"Failed: $reason\";\n exit;\n}", "public function testItThrowsException()\n {\n $location = \"00000,us\";\n $response = $this->api->send_request($location); \n }", "public function index($type = '')\n {\n\t\tif(!Auth::user()->can(['exception-show'])) die('Permission denied -- exception-show');\n $fromService = '';\n $currentUserId = '';\n $linkIndex = '';\n $data['date_from'] = isset($_GET['date_from']) ? $_GET['date_from'] : '';\n\t\t$data['date_to'] = isset($_GET['date_to']) ? $_GET['date_to'] : '';\n\t\t$data['sap_seller_id'] = isset($_GET['sap_seller_id']) ? $_GET['sap_seller_id'] : '';\n\t\t$data['status'] = isset($_GET['status']) ? $_GET['status'] : '';\n\n return view('exception/index',['users'=>$this->getUsers(),'groups'=>$this->getGroups(),'mygroups'=>$this->getUserGroup(),'sellerids'=>$this->getAccounts(),'teams'=> getUsers('sap_bgbu'),'sap_sellers'=>getUsers('sap_seller'), 'fromService'=>$fromService, 'currentUserId'=>$currentUserId, 'linkIndex'=>$linkIndex,'data'=>$data]);\n }", "public static function error_response() {\r\n header(\"HTTP/1.1 404 Recurso no encontrado\");\r\n exit();\r\n }", "protected abstract function send_error($ex=null) ;", "public function error(BaseResponse $response);", "function ReturnServerError()\n{\n header('HTTP/1.1 500 Internal Server Error');\n die(\"A server error occured while saving your request.\\r\\nPlease check our API status page at http://status.prybar.io and try again later\");\n}", "public function displayException($i) {\n if (!headers_sent())\n header('X-Error: By Brid Api');\n $error = array('name' => $i->getMessage(), 'message' => $i->getFile(), 'error' => $i->getMessage(), 'class' => get_class($i));\n if ($i->getCode() != 0) {\n $error['code'] = $i->getCode();\n }\n\n echo json_encode($error);\n }", "function get_reason($status) {\n $reason = array(\n 100 => 'Continue', 'Switching Protocols',\n 200 => 'OK', 'Created', 'Accepted', 'Non-Authoritative Information',\n 'No Content', 'Reset Content', 'Partial Content',\n 300 => 'Multiple Choices', 'Moved Permanently', 'Found', 'See Other',\n 'Not Modified', 'Use Proxy', '(Unused)', 'Temporary Redirect',\n 400 => 'Bad Request', 'Unauthorized', 'Payment Required','Forbidden',\n 'Not Found', 'Method Not Allowed', 'Not Acceptable',\n 'Proxy Authentication Required', 'Request Timeout', 'Conflict',\n 'Gone', 'Length Required', 'Precondition Failed',\n 'Request Entity Too Large', 'Request-URI Too Long',\n 'Unsupported Media Type', 'Requested Range Not Satisfiable',\n 'Expectation Failed',\n 500 => 'Internal Server Error', 'Not Implemented', 'Bad Gateway',\n 'Service Unavailable', 'Gateway Timeout',\n 'HTTP Version Not Supported');\n\n return isset($reason[$status]) ? $reason[$status] : '';\n }", "function internalError() {\n\t\t$this->status = $this->STATUS_INTERNAL_ERROR;\n\t\t$this->noCache();\n\t}", "public function isValidUrlInvalidRessourceDataProvider() {}", "public function status_code()\n {\n }", "function status() { return $this->err->status;}", "public static function manyRequests(){\n\n throw new \\yii\\web\\HttpException(414, 'Too Many Requests', 405);\n }", "function globalExceptionHandler ($ex) {\n try {\n ob_end_clean();\n $msg = '<b>' . get_class($ex) . ' (' . $ex->getCode() . ')</b> thrown in <b>' . $ex->getFile() . '</b> on line <b>'\n . $ex->getLine() . '</b><br>' . $ex->getMessage()\n . str_replace('#', '<br>#', $ex->getTraceAsString()) . '<br>';\n\n //don't log errors caused by routing to a non-existant page (since bots do that constantly)\n if($ex->getCode() != 404 && $ex->getCode() != 403 && $ex->getMessage() != \"Call to a member function getRewriteRoute() on null\") {\n $ds = DataService::getInstance();\n $ds->logException($msg);\n }\n\n if (DEBUG) {\n echo $msg;\n } else {\n if(Session::getUser() != null)\n header(\"Location: /error\");\n else\n header(\"Location: /login/error\");\n }\n }\n catch (Exception $e) {\n if(Session::getUser() != null)\n header(\"Location: /error\");\n else\n header(\"Location: /login/error\");\n }\n}", "function getHttpCode();", "function http_send_status($status) {}", "public function onException(GetResponseForExceptionEvent $event)\n {\n $this->stats->increment('exception');\n }", "abstract protected function _getErrorMessageForUrlKey($urlKey);", "function setFailedValidationStatusCode();", "public static function validRoutes(){\n $routes = self::$urled;\n $urlroute = $_GET['url'];\n $response1 = 0;\n\n\n foreach ($routes as $route) {\n if($urlroute == $route){\n $response1 += 1;\n }\n }\n if($response1 == 0){\n $response = ['error'=>'404 - not valid url'];\n echo json_encode($response);\n\n }\n }", "public function actionException()\n {\n $this->render('exception');\n }", "public function httpStatusDataProvider()\n {\n return [\n [\"badGateway\", 502, \"Bad gateway\"],\n [\"badRequest\", 400, \"Bad request\"],\n [\"conflict\", 409, \"Conflict\"],\n [\"expectationFailed\", 417, \"Expectation failed\"],\n [\"forbidden\", 403, \"Forbidden\"],\n [\"gatewayTimeout\", 504, \"Gateway timeout\"],\n [\"gone\", 410, \"Gone\"],\n [\"httpVersionNotSupported\", 505, \"Http version not supported\"],\n [\"internalServerError\", 500, \"Internal server error\"],\n [\"lengthRequired\", 411, \"Length required\"],\n [\"methodNotAllowed\", 405, \"Method not allowed\"],\n [\"notAcceptable\", 406, \"Not acceptable\"],\n [\"notFound\", 404, \"Not found\"]\n // TODO: Add the remaining status codes.\n ];\n }", "function throw_exception($message,$statusCode = 1004)\n {\n throw new \\think\\exception\\HttpException($statusCode,$message);\n }", "public static function handler(Exception $e)\n\t{\n\t\ttry\n\t\t{\t\t\t\n\t\t\t// Get the exception information\n\t\t\t$code = $e->getCode();\n\t\t\t\n\t\t\tif ($e instanceof ErrorException)\n\t\t\t{\n\t\t\t\t//some exceptions not have http code\n\t\t\t\tself::$http_code = Rest_Response::HTTP_SERVER_ERROR;\n\t\t\t\tself::$error['error'] = $e->getMessage();\n\t\t\t}\n\n\t\t\t//从其他异常抛出\n\t\t\tif(empty(self::$error['error'])) {\n\t\t\t\tself::$http_code = Rest_Response::HTTP_SERVER_ERROR;\n\t\t\t\tself::$error['error'] = $e->getMessage();\n\t\t\t}\n\n\t\t\tself::log($e);\n\n\t\t\tself::output($e);\n\n\t\t} catch (Exception $e)\n\t\t{\n\t\t\tself::output($e);\n\t\t}\n\t}" ]
[ "0.6324633", "0.60766774", "0.5993369", "0.598967", "0.5825878", "0.57615757", "0.55993545", "0.5597495", "0.55422497", "0.5528005", "0.5483638", "0.5468769", "0.54636186", "0.545094", "0.54378974", "0.54038054", "0.5400422", "0.53801095", "0.5364332", "0.536274", "0.53522563", "0.5329935", "0.5329452", "0.5325364", "0.5318291", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.5294426", "0.52931786", "0.5290387", "0.5285741", "0.5272235", "0.5272185", "0.5267353", "0.52599305", "0.52590555", "0.52559024", "0.5249197", "0.5248861", "0.52456075", "0.52397996", "0.52316034", "0.52137697", "0.5210721", "0.5202573", "0.51875", "0.5172278", "0.515437", "0.5141543", "0.5131545", "0.51091796", "0.51087487", "0.5095218", "0.5089904", "0.5079231", "0.5078978", "0.5074007", "0.506843", "0.5068323", "0.50623024", "0.50623024", "0.50560313", "0.5047244", "0.5043828", "0.5043096", "0.5039272", "0.5036379", "0.50353754", "0.502637", "0.50166124", "0.50150037", "0.5010448", "0.5009627", "0.50092", "0.50027925", "0.50013596", "0.49967602", "0.49964407", "0.49952406", "0.49951202", "0.49935558", "0.4991695", "0.49899814", "0.49833512", "0.49821702", "0.4975593", "0.49684387", "0.49664122", "0.49585006", "0.4951002", "0.49507058", "0.49502066", "0.49468645" ]
0.5752623
6
Constructor. Initializes a new instance of the Control class.
function Control($name = "") { $this->Name = $name; $this->_state = WEB_CONTROL_CONSTRUCTED; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->setAdapter(new TJuiControlAdapter($this));\n\t}", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->setAdapter(new TActiveControlAdapter($this));\n\t}", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->setAdapter(new TActiveControlAdapter($this));\n\t}", "public function customize_controls_init()\n {\n }", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->setAdapter(new TActiveControlAdapter($this));\n\t\t$this->getActiveControl()->setClientSide(new TActiveCustomValidatorClientSide);\n\t}", "function customize_controls_init()\n {\n }", "public function controls()\n {\n }", "public function __construct( $oMainControl ) {\n\t\tparent::__construct( $oMainControl );\n\t}", "public function setupControl()\n\t{\n\t\t$this->addText('referenceNumber', 'Reference number:');\n\t\t$this->addSelect('priority', 'Priority:', PriorityEnum::getOptions());\n\t\t$this->addTextArea('symptoms', 'Symptoms:', 40, 8)\n\t\t\t->addRule(Form::FILLED, 'Symptoms are required.');\n\t\t$this->addText('problemOwner', 'Problem owner:');\n\t\t$this->addSelect('status', 'State:', array(\n\t\t\tOperationProblem::STATUS_NEW => 'new',\n\t\t\tOperationProblem::STATUS_INVESTIGATED => 'investigated',\n\t\t\tOperationProblem::STATUS_RESOLVED => 'resolved',\n\t\t\tOperationProblem::STATUS_CLOSED => 'closed'\n\t\t));\n\n\t\t$this->addSelect('category', 'Category:', array('' => $this->noCategoryText) + $this->getCategoriesOptions());\n\n\t\t$this->addTextArea('onEventRaw', 'onEvent:');\n\n\t\t$this->addSubmit('save', 'Save problem');\n\n\t\t$this->onValidate[] = $this->onValidateForm;\n\t}", "protected function _construct()\n {\n $this->_controller = 'adminhtml_slider';\n $this->_blockGroup = 'Baniwal_OwlCarouselSlider';\n $this->_headerText = __('Sliders');\n $this->_addButtonLabel = __('Add New Slider');\n \n parent::_construct();\n }", "public function build_controls()\n\t{\n\t\t$this->add_control( 'title', [\n\t\t\t'label' => __( 'Title' )\n\t\t] );\n\t\t$this->add_control( 'content', [\n\t\t\t'label' => __( 'Content' ),\n\t\t\t'type' => 'textarea'\n\t\t] );\n\t\t$this->add_control( 'link_url', [\n\t\t\t'label' => __( 'URL' )\n\t\t] );\n\t\t$this->add_control( 'link_text', [\n\t\t\t'label' => __( 'Link Text' )\n\t\t] );\n\t\t$this->add_control( 'link_target', [\n\t\t\t'label' => __( 'Open link in a new window/tab' ),\n\t\t\t'type' => 'checkbox',\n\t\t\t'value' => '1'\n\t\t] );\n\t}", "function __construct() {\n\n\t\t// Widget Handle\n\t\t$this->ID = 'example-widget';\n\n\t\t// Widget Config\n\t\t$this->options = array(\n\t\t\t'name' => 'Example Widget', // Widget name\n\t\t\t'description' => 'Widget description.', // Widget description\n\t\t\t'classname' => 'projects-cycle-widget' // CSS class\n\t\t);\n\n\t\t// Default values for widget fields\n\t\t$this->defaults = array(\n\t\t\t'widget_title' => 'My Example Widget',\n\t\t\t'sample_field' => 'Some value'\n\t\t);\n\n\t\tparent::__construct();\n\n\t}", "protected function _construct()\n {\n parent::_construct();\n $this->setTemplate(self::TEMPLATE);\n }", "function getControl()\n\t{\n\t\treturn $this->control;\n\t}", "public function setControl($var)\n {\n GPBUtil::checkString($var, True);\n $this->control = $var;\n\n return $this;\n }", "public function setControl($var)\n {\n GPBUtil::checkString($var, True);\n $this->control = $var;\n\n return $this;\n }", "public function setControl($var)\n {\n GPBUtil::checkString($var, True);\n $this->control = $var;\n\n return $this;\n }", "public function __construct ($objParent, $strControlId = null) {\n\t\tparent::__construct($objParent, $strControlId);\n\n\t\tBootstrap::LoadJS($this);\n\t\t/*\n\n\t\tif ($this instanceof \\QTextBoxBase ||\n\t\t\t$this instanceof \\QListBox) {\n\t\t\t$this->AddCssClass (Bootstrap::FormControl);\n\t\t}\n\t\t*/\n\t}", "function ControlOnInit() {\n }", "protected function _construct()\n {\n parent::_construct();\n $this->_addButtonLabel = __('Add');\n }", "public function getControl()\n {\n return $this->control;\n }", "public function getControl()\n {\n return $this->control;\n }", "public function getControl()\n {\n return $this->control;\n }", "function controls()\n\t{\n\t}", "public function __construct(){\n // 表示部分で使うオブジェクトを作成\n $this->initDisplayObj();\n }", "public function __construct() {\n // 表示部分で使うオブジェクトを作成\n $this->initDisplayObj();\n }", "public function __construct($control, $onlyinternal = false) {\n\t\t$this->_control = $control;\n\t\t$this->_internalonly = $onlyinternal;\n\t}", "public function __construct($objParent, $strControlId = null)\n {\n parent::__construct($objParent, $strControlId);\n\n Bootstrap::loadJS($this);\n /*\n\n if ($this instanceof \\QCubed\\Control\\TextBoxBase ||\n $this instanceof \\QCubed\\Project\\Control\\ListBox) {\n $this->addCssClass(Bootstrap::FormControl);\n }\n */\n }", "public function __construct()\n {\n if (!$this->_addButtonLabel) {\n $this->_addButtonLabel = Mage::helper('adminhtml')->__('Add');\n }\n parent::__construct();\n if (!$this->getTemplate()) {\n $this->setTemplate('hipay/system/config/form/field/rules.phtml');\n }\n }", "public function BuildControls() {\n\n $this->EncType= $this->GetOption('EncType');\n\n // convert array of arrays into array of objects\n foreach($this->Controls as $Name=>&$Control) {\n // skip already builded controls\n if (is_object($Control)) {\n continue;\n }\n // find classname\n if (!isset($Control['Type'])) {\n $Control += array('Type'=>'text', 'Attributes'=>array('UNKNOWNTYPE'=>'YES'));\n }\n if (strpos($Control['Type'], '\\\\') === false) { // short name, ex.: \"select\"\n $Type= ucfirst($Control['Type']);\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\'.$Type.'Control';\n } else { // it is fully qualified class name\n $Class= $Control['Type'];\n }\n if (!class_exists($Class)) {\n $this->Error('Class \"'.$Class.'\" not found.');\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\TextControl'; // fallback to any primitive control\n }\n // copy this array into $Options and append few more items\n // and append common options to allow usage of services\n $Options= $Control + array(\n 'Name'=> $Name,\n 'Form'=> $this,\n 'Book'=> $this->GetOption('Book')\n ) + $this->GetCommonOptions();\n $Control= new $Class($Options);\n // switch to multipart encoding if any control require that\n if ($Control->GetMultipartEncoding()) {\n $this->EncType= 'multipart/form-data';\n }\n }\n $this->Builded= true;\n }", "protected function _register_controls() {\n\t}", "function __construct() {\n\t\t$this->label = __( 'HTML 1', 'customify' );\n\t}", "function __construct() {\n\t\tparent::__construct();\n\t\t$this->init();\n\t}", "function __construct($control, $reason)\n\t{\n\t\t$this->control = $control;\n\t\t$this->reason = $reason;\n\t\tparent::__construct($this->control->getName()\n\t\t\t. \": \" . self::$REASON_DESCRIPTION[$this->reason]);\n\t}", "function __construct() {\n parent::__construct( false, 'GE Custom Slider Widget' );\n }", "public function register_controls()\n {\n }", "public function __construct()\n\t{\n\t\tself::init();\n\t}", "public function __construct()\n {\n $widget_ops = array(\n 'classname' => 'cs_widget',\n 'description' => 'CSWidget is awesome',\n );\n parent::__construct('cs_widget', 'CS Widget', $widget_ops);\n }", "public function __construct()\n {\n $this->defaultStyle = \"rotatingPlane\";\n $this->defaultColor = \"black\";\n $this->container = null;\n }", "public function init()\n {\n // Initialize widget.\n }", "function __construct()\n\t{\n\t\tparent::__construct(\n\t\t\t'jetty_widget_button_text',\n\t\t\t__('Jetty Widget - Andeavor Button Text Box', 'jetty'),\n\t\t\tarray( 'description' => __( 'This widget for display text and button', 'jetty' ), )\n\t\t);\n\t}", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'Compound_Calculator_Widget', // Base ID\n\t\t\t__( 'compound Calculator Widget', 'cc_domain' ), // Name\n\t\t\tarray( 'description' => __( 'Widget lets users Calculate Compound Interest', 'text_domain' ), ) // Args\n\t\t);\n\t}", "public function __construct() {\n\t\t\t$this->init();\n\t\t}", "function __construct($aowner=null)\r\n {\r\n //Calls inherited constructor\r\n parent::__construct($aowner);\r\n\r\n $this->_pen=new Pen();\r\n $this->_pen->_control=$this;\r\n }", "public function __construct(MissionControl $missionControl) {\n\t\t$this->missionControl = $missionControl;\n\t}", "public function __construct(MissionControl $missionControl) {\n\t\t$this->missionControl = $missionControl;\n\t}", "protected function _register_controls()\n {\n\n /**\n * Style tab\n */\n\n $this->start_controls_section(\n 'general',\n [\n 'label' => __('Content', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n\t\t\t'menu_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Style', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'inline',\n\t\t\t\t'options' => [\n\t\t\t\t\t'inline' => __( 'Inline', 'akash-hp' ),\n\t\t\t\t\t'flyout' => __( 'Flyout', 'akash-hp' ),\n\t\t\t\t],\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_label',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Label', 'akash-hp' ),\n 'type' => Controls_Manager::TEXT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_open_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'fa fa-align-justify',\n\t\t\t\t\t'library' => 'solid',\n ],\n \n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_close_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Close Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'far fa-window-close',\n\t\t\t\t\t'library' => 'solid',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'menu_align',\n [\n 'label' => __('Align', 'akash-hp'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'start' => [\n 'title' => __('Left', 'akash-hp'),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __('top', 'akash-hp'),\n 'icon' => 'fa fa-align-center',\n ],\n 'flex-end' => [\n 'title' => __('Right', 'akash-hp'),\n 'icon' => 'fa fa-align-right',\n ],\n ],\n 'default' => 'left',\n\t\t\t\t'toggle' => true,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .akash-main-menu-wrap.navbar' => 'justify-content: {{VALUE}}'\n\t\t\t\t\t] \n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n\t\t\t'header_infos_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Header Info', 'akash-hp' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'show_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'akash-hp' ),\n\t\t\t\t'label_off' => __( 'Hide', 'akash-hp' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'no',\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'info_title', [\n\t\t\t\t'label' => __( 'Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'info Title' , 'akash-hp' ),\n\t\t\t\t'label_block' => true,\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'info_content', [\n\t\t\t\t'label' => __( 'Content', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t'default' => __( 'info Content' , 'akash-hp' ),\n\t\t\t\t'show_label' => false,\n\t\t\t]\n );\n \n $repeater->add_control(\n\t\t\t'info_url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'akash-hp' ),\n\t\t\t\t'show_external' => true,\n\t\t\t]\n );\n \n\t\t$this->add_control(\n\t\t\t'header_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Repeater info', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'info_title' => __( 'Call us:', 'akash-hp' ),\n\t\t\t\t\t\t'info_content' => __( '(234) 567 8901', 'akash-hp' ),\n\t\t\t\t\t],\n\t\t\t\t],\n 'title_field' => '{{{ info_title }}}',\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_menu_style',\n [\n 'label' => __('Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'menu_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'menu_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n \n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n \n $this->add_responsive_control(\n 'item_gap',\n [\n 'label' => __('Menu Gap', 'akash-hp'),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'devices' => ['desktop', 'tablet', 'mobile'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-left: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-right: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_readius',\n [\n 'label' => __('Item Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li:hover>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'dropdown_style',\n [\n 'label' => __('Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'dripdown_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n \n $this->add_control(\n 'dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'ddown_menu_border_color',\n [\n 'label' => __('Menu Border Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_radius',\n [\n 'label' => __('Menu radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_flyout_style',\n [\n 'label' => __('Flyout/Mobile Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_menu_typography',\n 'label' => __('Item Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'flyout_menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n $this->add_responsive_control(\n 'flyout_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_menu_padding',\n [\n 'label' => __('Menu Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n \n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n\n\t\t$this->end_controls_tab();\n\n $this->end_controls_tabs();\n \n $this->end_controls_section();\n\n $this->start_controls_section(\n 'flyout_dropdown_style',\n [\n 'label' => __('Flyout/Mobile Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_dripdown_typography',\n 'label' => __('Dropdown Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n\n $this->start_controls_section(\n 'trigger_style',\n [\n 'label' => __('Trigger Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n $this->start_controls_tabs(\n 'trigger_style_tabs'\n );\n \n $this->start_controls_tab(\n 'trigger_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'trigger_typography',\n 'label' => __('Trigger Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n 'trigger_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'trigger_icon_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'trigger_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_padding',\n [\n 'label' => __('Button Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'trigger_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n\n $this->add_control(\n 'trigger_hover_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_hover_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_hover_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu:hover',\n ]\n );\n\n $this->add_control(\n 'trigger_hover_animation',\n [\n 'label' => __('Hover Animation', 'akash-hp'),\n 'type' => Controls_Manager::HOVER_ANIMATION,\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_hover_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n \n $this->start_controls_section(\n 'infos_style_section',\n [\n 'label' => __('Info Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n ]\n );\n\n $this->start_controls_tabs(\n 'info_style_tabs'\n );\n \n $this->start_controls_tab(\n 'info_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_title_typography',\n 'label' => __('Title Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info span',\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_typography',\n 'label' => __('Info Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info h3 ',\n ]\n );\n\n $this->add_control(\n 'info_title_color',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'info_box_border',\n 'label' => __('Box Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .akash-header-infos',\n ]\n );\n\n $this->add_control(\n\t\t\t'info_title_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Info Title Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .header-info span' => 'margin-bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'ifno_item_padding',\n [\n 'label' => __('Info item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'info_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n $this->add_control(\n 'info_title_color_hover',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color_hover',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n \n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n $this->start_controls_section(\n 'panel_style',\n [\n 'label' => __('Panel Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'panel_label_typography',\n 'label' => __('Label Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler',\n ]\n );\n\n \n $this->add_control(\n 'panel_label_color',\n [\n 'label' => __('Label Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_color',\n [\n 'label' => __('Close Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler i' => 'color: {{VALUE}}',\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'stroke: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_fill_color',\n [\n 'label' => __('Close Trigger Fill Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'fill: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_label_background',\n [\n 'label' => __('Label Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.close-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n \n $this->add_control(\n 'panel_background',\n [\n 'label' => __('Panel Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_cloxe_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Close Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'panel_shadow',\n 'label' => __('Panel Shadow', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-inner',\n ]\n );\n\n $this->add_responsive_control(\n 'close_label_padding',\n [\n 'label' => __('Label Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n \n $this->add_responsive_control(\n 'panel_padding',\n [\n 'label' => __('Panel Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n\n $this->end_controls_section();\n }", "public function __construct( ) {\n $this->name = 'WPBXSlider';\n $this->version = '0.1.0';\n }", "public function __construct()\n {\n parent::__construct();\n \n $this->m_define();\n }", "protected function buildControl()\n\t\t{\n\t\t\tswitch($this->getDisplayMode())\n\t\t\t{\n\t\t\t\tcase self::DISPLAYMODE_ICONS :\n\t\t\t\t\t$this->buildIconView();\n\t\t\t\t\tbreak;\n\t\t\t\tcase self::DISPLAYMODE_LIST :\n\t\t\t\t\t$this->buildListView();\n\t\t\t\t\tbreak;\n\t\t\t\tcase self::DISPLAYMODE_DETAILS :\n\t\t\t\t\t$this->buildDetailView();\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tstatic::fail(\"Unknown DisplayMode '%s'\", $this->getDisplayMode());\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}", "public function getControl()\n\t{\n\t\t$control = parent::getControl();\n\t\t$control->addAttributes(array(\n\t\t\t'id' => $this->getHtmlId(),\n\t\t));\n\t\treturn $control;\n\t}", "public function __construct() {\n\n\t\t// Load plugin text domain\n\t\tadd_action( 'init', array( $this, 'load_plugin_textdomain' ) );\n\n\t\t// Activate plugin when new blog is added\n\t\tadd_action( 'wpmu_new_blog', array( $this, 'activate_new_site' ) );\n\n\t\tadd_shortcode('grams', array( &$this, 'shortcode') );\n\t\tadd_action('wp_enqueue_scripts', array( &$this, 'enqueue_scripts') );\n\n\t\t// widget\n\t\t$this->widget = new Simple_Grams_Widget();\n\t\tadd_action( 'widgets_init', array( &$this, 'simple_grams' ) );\n\n\t}", "function __construct () {\n\n $this -> ruedas = 8;\n $this -> color = \"gris\";\n $this -> motor = 1600;\n\n }", "public function __construct()\n {\n Kirki::add_config(\n self::$config,\n array(\n 'capability' => 'edit_theme_options',\n 'option_type' => 'theme_mod',\n 'disable_output' => false,\n )\n );\n\n /**\n * Set up the panel\n */\n new Panel(\n self::$panel,\n array(\n 'priority' => 30,\n 'title' => esc_attr__('Footer', 'stage'),\n 'description' => esc_attr__('Customize the footer.', 'stage'),\n )\n );\n\n /**\n * Init sections with fields\n */\n $this->colors();\n $this->settings();\n }", "function TreeControl($id, $title = \"\", $style=\"tree\", $scroll=true,$width=500,$height=400)\n\t{\n\t\t$this->id = $id;\n\t\t$this->title = $title;\n\t\t$this->style = $style;\n\t\t$this->scroll = $scroll;\n\t\t$this->width = $width;\n\t\t$this->height = $height;\n\t}", "function avControl( &$table, $name, $description, $default, $required, $quered, $list, $header, $order)\n\t{\n\t\t$this->constructor(&$table, $name, $description, $default, $required, $quered, $list, $header, $order);\n\t}", "public function __construct() {\n\n\t\t// Register widget scripts\n\t\tadd_action( 'elementor/frontend/after_register_scripts', [ $this, 'widget_scripts' ] );\n\n\t\t// Register widgets\n\t\tadd_action( 'elementor/widgets/widgets_registered', [ $this, 'register_widgets' ] );\n\n\t\t// Register editor scripts\n\t\tadd_action( 'elementor/editor/after_enqueue_scripts', [ $this, 'editor_scripts' ] );\n\n\t\t$this->add_page_settings_controls();\n\t}", "public function __construct() {\n\t\t$this->init();\n\t}", "function &getInstance($control_name, $name=null) {\r\n\t\trequire_once ZAR_CONTROLS_PATH . '/'.strtolower($control_name).'.php';\r\n\t\t$class = 'ZariliaControl_'.$control_name.'.php';\r\n\t\t$obj = new $class($name);\r\n\t\tunset($class);\r\n\t\treturn $obj;\r\n\t}", "function __construct(){\n\t\t$this->initials_data = array(\n\t\t\t\"button_class\"=>\"btn-primary\"\n\t\t\t);\n\t\treturn $this;\n\t}", "public function __construct() {\n\t\tparent::__construct();\n\t\t// Other code to run when object is instantiated\n\t}", "function __construct() {\n $widget_ops = array( 'classname' => 'wplms_notes_discussion', 'description' => __('Notes & Discussion Widget for Dashboard', 'wplms-dashboard') );\n $control_ops = array( 'width' => 300, 'height' => 350, 'id_base' => 'wplms_notes_discussion' );\n parent::__construct( 'wplms_notes_discussion', __(' DASHBOARD : Notes & Discussion', 'wplms-dashboard'), $widget_ops, $control_ops );\n }", "public function __construct(ControlPositionHelper $controlPositionHelper)\n {\n $this->controlPositionHelper = $controlPositionHelper;\n }", "function __construct()\n {\n $this\n ->setOpacity(1.0)\n ->setUpdatedAt(new \\DateTime('now'))\n ->setActive(false)\n ;\n }", "public function __construct()\n\t{\n\t\t$widget_ops = array( \n\t\t\t'classname' => 'Widget_Testimonial',\n\t\t\t'description' => 'Testimonial widget',\n\t\t\t);\n\t\tparent::__construct( 'Widget_Testimonial', 'Widget Testimonial', $widget_ops );\n\t}", "public static function get_instance() {\n\n if( null == self::$instance ) {\n self::$instance = new MSDLAB_SettingControls();\n }\n\n return self::$instance;\n\n }", "public function __construct()\n\t{\n\t\t$this->html = new HtmlBuilder;\n\t}", "public function __construct() {\n\t\tparent::__construct();\n\n\t\t$this->disableRendering();\n\t}", "private function __construct()\n {\n // Let it as a singleton class\n $this->_mux = new Mux;\n }", "public function __construct()\n\t{\n\t\t$this->app = $this->getApp();\n\n\t\tif (!$this->app->config->captcha_enable) {\n\t\t\treturn;\n\t\t}\n\n\t\t$this->driver = $this->app->config->captcha_engine;\n\t\t$this->handle = $this->getHandle();\n\t\t$this->enabled = true;\n\t}", "public function __construct()\n {\n $sPluginClass = preg_replace(\"/Widget$/\", 'Plugin', get_class($this));\n $this->oPlugin = new $sPluginClass;\n\t\tparent::__construct\n (\n\t\t\t$this->oPlugin->pluginId() . '_widget',\n\t\t\t__($this->oPlugin->pluginName() . ' Widget', $this->oPlugin->textDomain()),\n\t\t\t['description' => __($this->oPlugin->pluginDescription(), $this->oPlugin->textDomain())]\n\t\t);\n\t}", "public function __construct()\n\t{\n\t\tself::$instance =& $this;\n\t}", "function __construct() {\r\n\t\t$this->Class = 'form-control';\r\n\t\t$this->SelectedClass = 'active';\r\n\t\t$this->HTML = '';\r\n\t\t$this->ListType = 0;\r\n\t\t$this->ListBoxHeight = 10;\r\n\t\t$this->MultipleSeparator = ', ';\r\n\t\t$this->RadiosPerLine = 1;\r\n\t\t$this->AllowNull = true;\r\n\t\t$this->ApplySelect2 = true;\r\n\t}", "function AddControls($controls)\r\n {\r\n $this->Controls = $controls;\r\n }", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t\n\t\t//var_dump($this->window);\n\t\t$action = CC_Actions::instance();\n\t\t$quit = $action->get_action('help', 'website');\n\t\t$new = $quit->create_menu_item();\n\t\t$image = $new->get_children();\n\t\t$image = $image[1];\n\t\techo $image;\n\t\t$image->reparent($this->vbox);\n\t\t$icon = $quit->create_icon(CC::$DND);\n\t\t$this->vbox->add($icon);\n\t\t$quit = $action->get_action('file', 'quit');\n\t\t$icon = $quit->create_icon(CC::$DND);\n\t\t$this->vbox->add($icon);\n\t\t$this->show_all();\n\t}", "protected function __construct()\n\t\t{\n\t\t\t$this->init();\n\t\t}", "protected function __construct()\n\t\t{\n\t\t\t$this->init();\n\t\t}", "function __construct()\n {\n parent::__construct();\n $this->init();\n }", "protected function __construct()\n\t{\n\t\t$this->_init();\n\t}", "public function __construct() {\n\t\t$fields = [ 'title', 'link', 'classes' ];\n\n\t\t$this->setFields( $fields );\n\n\t\t$widget_ops = [\n\t\t\t'classname' => 'CLW_Widget',\n\t\t\t'description' => 'Custom link widget',\n\t\t];\n\t\tparent::__construct( 'clw_widget', 'CLW Widget', $widget_ops );\n\t}", "function _construct() {\n\t\tparent::_construct();\n\t}", "public function staticControl($options = [])\n {\n $this->adjustLabelFor($options);\n $this->parts['{input}'] = Html::activeStaticControl($this->model, $this->attribute, $options);\n return $this;\n }", "public function construct()\r\n\t{\r\n\t\t\r\n\t\t\r\n\t\t$class = ($this->classClr) ? 'w50 clr' : 'w50';\r\n\t\t$class = ($this->classLong) ? 'long clr' : $class;\r\n\t\t$class .= ($this->picker) ? ' wizard' : '';\r\n\t\t\r\n\t\t$wizard = ($this->picker == 'page') ? array(array('tl_content', 'pagePicker')) : false;\r\n\t\t\r\n\t\t// input unit\r\n\t\tif (($this->picker == 'unit'))\r\n\t\t{\r\n\t\t\t$options = array();\r\n\t\t\tforeach (deserialize($this->units) as $arrOption)\r\n\t\t\t{\r\n\t\t\t\t$options[$arrOption['value']] = $arrOption['label'];\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// the text field\r\n\t\t$this->generateDCA(($this->picker != 'unit') ? ($this->multiple) ? 'multiField' : 'textField' : 'inputUnit', array\r\n\t\t(\r\n\t\t\t'inputType' =>\t($this->picker == 'unit') ? 'inputUnit' : 'text',\r\n\t\t\t'label'\t\t=>\tarray($this->label, $this->description),\r\n\t\t\t'default'\t=>\t$this->defaultValue,\r\n\t\t\t'wizard'\t=>\t$wizard,\r\n\t\t\t'options'\t=>\t$options,\r\n\t\t\t'eval'\t\t=>\tarray\r\n\t\t\t(\r\n\t\t\t\t'mandatory'\t\t=>\t($this->mandatory) ? true : false, \r\n\t\t\t\t'minlength'\t\t=>\t$this->minlength, \r\n\t\t\t\t'maxlength'\t\t=>\t$this->maxLength, \r\n\t\t\t\t'tl_class'\t\t=>\t$class,\r\n\t\t\t\t'rgxp'\t\t\t=>\t$this->rgxp,\r\n\t\t\t\t'multiple'\t\t=>\t($this->multiple) ? true : false,\r\n\t\t\t\t'size'\t\t\t=>\t$this->multiple,\r\n\t\t\t\t'datepicker' \t=> \t($this->picker == 'datetime') ? true : false,\r\n\t\t\t\t'colorpicker' \t=> \t($this->picker == 'color') ? true : false,\r\n\t\t\t\t'isHexColor' \t=> \t($this->picker == 'color') ? true : false,\r\n\t\t\t),\r\n\t\t));\r\n\t\t\r\n\t}", "public function __construct() {\n\n\t\t// Register widget styles\n\t\tadd_action( 'elementor/frontend/after_register_styles', [ $this, 'widget_styles' ] );\n\n\t\t// Register widget scripts\n\t\tadd_action( 'elementor/frontend/after_register_scripts', [ $this, 'widget_scripts' ] );\n\n\t\t// Register widgets\n\t\tadd_action( 'elementor/widgets/widgets_registered', [ $this, 'register_widgets' ] );\n\n\t\t// Register editor scripts\n\t\tadd_action( 'elementor/editor/after_enqueue_scripts', [ $this, 'editor_scripts' ] );\n\n\t\t// Register category\n\t\tadd_action( 'elementor/elements/categories_registered', [ $this, 'add_category' ] );\n\n\t\t$this->add_page_settings_controls();\n\t}", "public function __construct() {\n $this->init();\n }", "protected function _register_controls() {\r\n\r\n\t\t$this->start_controls_section(\r\n\t\t\t'settings_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => esc_html__( 'General Settings', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'title', [\r\n\t\t\t'label' => esc_html__( 'Title', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( 'Primary Plan', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter title', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'featured', [\r\n\t\t\t'label' => esc_html__( 'Featured', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::SWITCHER,\r\n\t\t\t'default' => 'no',\r\n\t\t\t'description' => esc_html__( 'enable featured', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'price', [\r\n\t\t\t'label' => esc_html__( 'Price', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '250', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter price', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'sign', [\r\n\t\t\t'label' => esc_html__( 'Sign', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '$', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter sign', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'month', [\r\n\t\t\t'label' => esc_html__( 'Month', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '/Mo', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter month', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'btn_text', [\r\n\t\t\t'label' => esc_html__( 'Button Text', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( 'Get Started', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter button text', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'btn_link', [\r\n\t\t\t'label' => esc_html__( 'Button Link', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::URL,\r\n\t\t\t'default' => array(\r\n\t\t\t\t'url' => '#'\r\n\t\t\t),\r\n\t\t\t'description' => esc_html__( 'enter button link', 'aapside-master' )\r\n\t\t] );\r\n\r\n\t\t$this->add_control( 'feature_items', [\r\n\t\t\t'label' => esc_html__( 'Feature Item', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::REPEATER,\r\n\t\t\t'default' => [\r\n\t\t\t\t[\r\n\t\t\t\t\t'feature' => esc_html__( '5 Analyzer', 'aapside-master' )\r\n\t\t\t\t],\r\n\t\t\t],\r\n\t\t\t'fields' => [\r\n\t\t\t\t[\r\n\t\t\t\t\t'name' => 'feature',\r\n\t\t\t\t\t'label' => esc_html__( 'Feature', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t\t\t'description' => esc_html__( 'enter feature item.', 'aapside-master' ),\r\n\t\t\t\t\t'default' => esc_html__( '5 Analyzer', 'aapside-master' )\r\n\t\t\t\t]\r\n\t\t\t],\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\r\n\t\t$this->start_controls_section( 'styling_section', [\r\n\t\t\t'label' => esc_html__( 'Styling Settings', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->add_control( 'title_color', [\r\n\t\t\t'label' => esc_html__( 'Title Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .name\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'price_color', [\r\n\t\t\t'label' => esc_html__( 'Price Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap .price\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'month_color', [\r\n\t\t\t'label' => esc_html__( 'Month Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap .month\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'features_color', [\r\n\t\t\t'label' => esc_html__( 'Features Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-body ul\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\r\n\t\t/* button styling start */\r\n\t\t$this->start_controls_section( 'button_styling_section', [\r\n\t\t\t'label' => esc_html__( 'Button Styling', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->start_controls_tabs(\r\n\t\t\t'button_style_tabs'\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'button_style_normal_tab',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Normal', 'aapside-master' ),\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'button_normal_color', [\r\n\t\t\t'label' => esc_html__( 'Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Button Background', 'aapside-master' ),\r\n\t\t\t'name' => 'button_normal_bg_color',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Border::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Border', 'aapside-master' ),\r\n\t\t\t'name' => 'button_normal_border',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_tab();\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'button_style_hover_tab',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Hover', 'aapside-master' ),\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'button_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Button Background', 'aapside-master' ),\r\n\t\t\t'name' => 'button_hover_bg_color',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Border::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Border', 'aapside-master' ),\r\n\t\t\t'name' => 'button_hover_border',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_tab();\r\n\r\n\t\t$this->end_controls_tabs();\r\n\t\t$this->add_control( 'button_divider', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_responsive_control( 'button_border_radius', [\r\n\t\t\t'label' => esc_html__( 'Border Radius', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::DIMENSIONS,\r\n\t\t\t'units' => [ 'px', '%', 'em' ],\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\" => \"border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\t\t/* button styling end */\r\n\r\n\t\t/* border color start */\r\n\t\t$this->start_controls_section( 'hover_border_section', [\r\n\t\t\t'label' => esc_html__( 'Hover Border Style', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'hover_background',\r\n\t\t\t'label' => esc_html__( 'Active Border Color', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02:after\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_section();\r\n\t\t/* border color end */\r\n\r\n\r\n\t\t/* button styling start */\r\n\t\t$this->start_controls_section( 'typography_section', [\r\n\t\t\t'label' => esc_html__( 'Typography Settings', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'title_typography',\r\n\t\t\t'label' => esc_html__( 'Title Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-header .name\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'price_typography',\r\n\t\t\t'label' => esc_html__( 'Price Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'features_typography',\r\n\t\t\t'label' => esc_html__( 'Features Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-body ul\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'button_typography',\r\n\t\t\t'label' => esc_html__( 'Button Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\t\t/* button styling end */\r\n\t}", "public function __construct() {\n\t\tparent::__construct(\n\t \t\t'property_map_widget', // Base ID\n\t\t\t'Porperty Map', // Name\n\t\t\tarray( 'description' => __( 'Property Map Widget', DOMAIN ), ) // Args\n\t\t);\n\t}", "public function __construct()\n {\n parent::__construct();\n $this->FormGenerator = new FormGenerator();\n }", "public function __construct( )\r\n\t{\r\n\t\t// TODO Auto-generated constructor\r\n\t}", "public function __construct() {\n\t\t// widget actual processes\n\t\t\n\t\tparent::__construct(\n\t\t\t'xtreme_example_widget', // Base ID\n\t\t\t__( 'Xtreme Example Widget Title', XF_TEXTDOMAIN ), // Name\n\t\t\tarray( 'description' => __( 'A Foo Widget', XF_TEXTDOMAIN ), ) // Args\n\t\t);\n\t}", "function __construct() {\n\t\tparent::__construct();\n $this->vista->setTitle('Cursos');\n\t\t$this->TSubgrupo = new TSubgrupo();\n\t\t$this->TPrograma = new TPrograma();\n\t }", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'truman_sign_clock_widget',\n\t\t\t__( 'Clock Widget', 'truman-digital-sign-theme' ),\n\t\t\tarray( 'description' => __( 'Shows a clock with time and date', 'truman-digital-sign-theme' ), )\n\t\t);\n\t}", "public function __construct() {\n\t\t\trequire_once('classes/canvasWrapper.php');\n\t\t\t$this->canvas = new CanvasWrapper();\n\t\t\t\n\t\t\t$this->db = Db::getInstance();\n\t\t\t\n\t\t}", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "public function __construct()\r\n {\r\n parent::init();\r\n }", "final private function __construct()\n {\n \t$this->init();\n }", "public function __construct()\n {\n self::init(); // Ou $this->init();\n }", "abstract public function openControl($label, $class = '', $attr = '');", "public function construct()\n\t\t{\n\t\t}", "function __construct () { // Metodo Constructor: __construct nueva forma de hacer un constructor.\n\n // Caracteristicas iniciales de la clase. Definiendo el valor de las variables definidas fuera del constructor.\n $this -> ruedas = 4; // this: es como decir \"coche\". Estamos diciendo que la clase partira con 4 ruedas inicialmente.\n $this -> color = \"\";\n $this -> motor = 1600;\n }" ]
[ "0.73567444", "0.6724498", "0.6724498", "0.66757464", "0.65305096", "0.65044117", "0.64593035", "0.6362783", "0.6345811", "0.6306116", "0.61643845", "0.61347216", "0.6054457", "0.60443056", "0.6039964", "0.6039964", "0.6039964", "0.6031953", "0.59967244", "0.59701306", "0.59339714", "0.59339714", "0.59339714", "0.5909594", "0.5904438", "0.5896532", "0.58834034", "0.58831763", "0.5867779", "0.5852569", "0.5809576", "0.5798923", "0.5797112", "0.5787457", "0.57862264", "0.5780928", "0.57751805", "0.57711065", "0.5765165", "0.5761837", "0.574578", "0.57392657", "0.57301104", "0.5723726", "0.57225704", "0.57225704", "0.57158", "0.56923455", "0.5689577", "0.5686564", "0.5681027", "0.5679641", "0.56693774", "0.5668365", "0.56680906", "0.5667144", "0.5656098", "0.5655847", "0.5655467", "0.5644729", "0.564117", "0.5640876", "0.5630123", "0.5628963", "0.5628228", "0.5612682", "0.5610969", "0.5610634", "0.561003", "0.5607438", "0.5599218", "0.55944204", "0.5592436", "0.5588931", "0.5585321", "0.5582411", "0.5582411", "0.55813503", "0.55793345", "0.5578986", "0.55743206", "0.55729383", "0.5568854", "0.55667704", "0.5555134", "0.5550451", "0.5547008", "0.5541094", "0.55407184", "0.5538561", "0.55371916", "0.55355704", "0.55320007", "0.55303586", "0.55299824", "0.5528717", "0.55215955", "0.55201304", "0.5503374", "0.54988056" ]
0.71430963
1
Method Adds the specified Control object to the controls collection.
function AddControl(&$object) { if (!is_object($object)) { return; } //if (is_object($object->Parent)) //$object->Parent->RemoveControl($object); $object->Parent = &$this; $object->Page = &$this->Page; @$this->Controls[$object->Name] = &$object; if ($this->_state >= WEB_CONTROL_INITIALIZED) { $object->initRecursive(); if ($this->_state >= WEB_CONTROL_LOADED) $object->loadRecursive(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function addControl(IControl $control): IControl;", "function AddControls($controls)\r\n {\r\n $this->Controls = $controls;\r\n }", "public function addControl(Entities\\Devices\\Controls\\Control $control): void\n\t{\n\t\tif (!$this->controls->contains($control)) {\n\t\t\t// ...and assign it to collection\n\t\t\t$this->controls->add($control);\n\t\t}\n\t}", "public function addControl(sys_admin_Control $control, $name);", "public function add_control($name, $ctl)\n\t{\n\t\tif (array_key_exists($name, $this->controls)) {\n\t\t\tif (DEBUG) dwrite(\"Control '$name' already added\");\n\t\t\treturn;\n\t\t}\n\n\t\t$ctl->page =& $this;\n\t\t$this->controls[$name] =& $ctl;\n\t}", "public function register_controls()\n {\n }", "protected function _register_controls() {\n\t}", "protected function _register_controls() {\n\n\t\t//link\n\t\t//image\n\t\t//featured\n\t\t//term\n\t\t//style alternative-imagebox\n\t\t//\n\t\t//\n\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-listeo' ),\n\t\t\t)\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link','elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'elementor-listeo' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Choose Background Image', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\n\n\t\t// $this->add_control(\n\t\t// \t'featured',\n\t\t// \t[\n\t\t// \t\t'label' => __( 'Featured badge', 'elementor-listeo' ),\n\t\t// \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t// \t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t// \t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t// \t\t'return_value' => 'yes',\n\t\t// \t\t'default' => 'yes',\n\t\t// \t]\n\t\t// );\n\n\t\t$this->add_control(\n\t\t\t'taxonomy',\n\t\t\t[\n\t\t\t\t'label' => __( 'Taxonomy', 'elementor-listeo' ),\n\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [],\n\t\t\t\t'options' => $this->get_taxonomies(),\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$taxonomy_names = get_object_taxonomies( 'listing','object' );\n\t\tforeach ($taxonomy_names as $key => $value) {\n\t\n\t\t\t$this->add_control(\n\t\t\t\t$value->name.'term',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Show term from '.$value->label, 'elementor-listeo' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'default' => [],\n\t\t\t\t\t'options' => $this->get_terms($value->name),\n\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t'taxonomy' => $value->name,\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\n\n\t\t$this->add_control(\n\t\t\t'show_counter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show listings counter', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t\t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style ', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' => 'alternative-imagebox',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'elementor-listeo' ),\n\t\t\t\t\t'alternative-imagebox' => __( 'Alternative', 'elementor-listeo' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "public function attach(Control $ctrl)\n {\n $this->controls[$ctrl->attr('id')] = $ctrl;\n if ($ctrl instanceof Panel) foreach($ctrl as $child) $this->attach($child);\n return $this;\n }", "protected function _register_controls()\n {\n $this->start_controls_section(\n 'section_content',\n [\n 'label' => __('Content', 'uap-uganda'),\n ]\n );\n\n $this->add_control(\n 'posts',\n [\n 'label' => __('Number of Posts', 'uap-uganda'),\n 'type' => Controls_Manager::NUMBER,\n 'default' => 2\n ]\n );\n\n $this->add_control(\n 'posts_per_page',\n [\n 'label' => __('Posts Per Page', 'uap-uganda'),\n 'type' => Controls_Manager::NUMBER,\n 'default' => 2\n ]\n );\n\n $this->end_controls_section();\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "protected function _register_controls()\n {\n global $post;\n $page = get_post($post->ID);\n $pageTitle = $page->post_title;\n\n // Top post's part starts\n $this->start_controls_section(\n 'section_top',\n [\n 'label' => __('Top part of article', 'elementor'),\n ]\n );\n\n $this->add_control(\n 'page_title',\n [\n 'label' => 'Type page title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => $pageTitle,\n// 'default' => 'TEXT TITLE',\n ]\n );\n\n $this->add_control(\n 'page_subtitle',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'blog_content_top',\n [\n 'label' => __('Top article part', 'elementor'),\n 'default' => __('Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_middle',\n [\n 'label' => __('Middle article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_bottom',\n [\n 'label' => __('Bottom article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->end_controls_section();\n // Top post's part ends\n\n // Middle post's part starts\n $this->start_controls_section(\n 'section_middle',\n [\n 'label' => __('Middle part of article', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'the_quote',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n 'default' => __('“We’re seeing some really bullish bitcoin price action today along with other ...',\n 'plugin-domain'),\n ]\n );\n\n $this->end_controls_section();\n // Midddle post's part ends\n }", "protected function _register_controls()\n\t{\n\n\t\t$this->start_controls_section(\n\t\t\t'section_settings',\n\t\t\t[\n\t\t\t\t'label' => __('Settings', 'algolia-wp-plugin'),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'index_name',\n\t\t\t[\n\t\t\t\t'label' => __('Search Index', 'algolia-wp-plugin'),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'show_label' => true,\n\t\t\t\t'default' => 'wp_searchable_posts',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'facet_filters',\n\t\t\t[\n\t\t\t\t'label' => __('Facet Filters', 'algolia-wp-plugin'),\n\t\t\t\t'type' => Controls_Manager::CODE,\n\t\t\t\t'show_label' => true,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hits_per_page',\n\t\t\t[\n\t\t\t\t'label' => __('Hits Per Page', 'algolia-wp-plugin'),\n\t\t\t\t'show_label' => true,\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'default' => 5,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'localize',\n\t\t\t[\n\t\t\t\t'label' => __('Localize', 'algolia-wp-plugin'),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => true,\n\t\t\t\t'frontend_available' => true,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n\n\t\t\t\t$this->start_controls_section(\n\t\t\t\t\t'section_sc_booked',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'ThemeREX Booked Calendar', 'trx_addons' ),\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'style',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Layout', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => [\n\t\t\t\t\t\t\t\t\t'calendar' => esc_html__('Calendar', 'trx_addons'),\n\t\t\t\t\t\t\t\t\t'list' => esc_html__('List', 'trx_addons')\n\t\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t'default' => 'calendar'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'calendar',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Calendar', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Select calendar -', 'trx_addons')), trx_addons_get_list_terms(false, 'booked_custom_calendars')),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'month',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Month', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current month -', 'trx_addons')), trx_addons_get_list_months()),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'year',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Year', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current year -', 'trx_addons')), trx_addons_get_list_range(date('Y'), date('Y')+25)),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\t$this->end_controls_section();\n\t\t\t}", "public function addControl($name)\n {\n return $this->qform->addControl($name);\n }", "function addOptionControl($params, $section = null) {\n // otherwise add it to the element root\n if ($section) {\n $l = $section;\n } else {\n $l = $this->El;\n }\n\n $control_type = $params['type'];\n\n if (isset($params['name'])) {\n $control_label = $params['name'];\n } else {\n throw new Exception(\"addOptionControl params['name'] must be set\");\n }\n\n // generate a unique slug for the control based on the name\n if (isset($params['slug'])) {\n $control_slug = $params['slug'];\n } else {\n $control_slug = str_replace(\" \", \"-\", $params['name']);\n $control_slug = 'slug_'.preg_replace(\"/[^A-Za-z0-9 ]/\", \"\", $control_slug);\n }\n\n $Control = $l->addControl($control_type, $control_slug, __($control_label));\n\n // option controls is not a style controls, make those auto rebuild element to avoid \"Apply param\" button\n /*$rebuild_element = isset($params['rebuild_element']) ? $params['rebuild_element'] : true; \n if ($rebuild_element) {\n $Control->rebuildElementOnChange();\n }*/\n\n if (isset($params['condition'])) {\n $Control->setCondition($params['condition']);\n }\n\n if (isset($params['value'])) {\n $Control->setValue($params['value']);\n }\n\n if (isset($params['default'])) {\n $Control->setDefaultValue($params['default']);\n }\n\n if (isset($params['base64']) && $params['base64'] == true) {\n $Control->base64();\n }\n\n return $Control;\n\n }", "public function appendControl($name, $template);", "protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'Subtitle',\n\t\t\t[\n\t\t\t\t'label' => __( 'SubTitle', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'gallery',\n\t\t\t[\n\t\t\t\t'label' => __( 'Add Images', 'plugin-domain' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::GALLERY,\n\t\t\t\t'default' => [],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style', 'elementor-hello-world' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'content_typography',\n\t\t\t\t'label' => __( 'Typography', 'elementor-hello-world' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .title',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t$this->add_control(\n\t\t\t'width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Width', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 5,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t\t'size' => 50,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .box' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'show_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'elementor-hello-world' ),\n\t\t\t\t'label_off' => __( 'Hide', 'elementor-hello-world' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\t\n\t\t\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t$this->start_controls_section(\n\t\t\t'section_advanced',\n\t\t\t[\n\t\t\t\t'label' => __( 'Opacity Change', 'elementor-hello-world' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'title_color1', \n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'transparent',\n\t\t\t[\n\t\t\t\t'label' => __( 'Enable', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'On', 'elementor-hello-world' ),\n\t\t\t\t'label_off' => __( 'Off', 'elementor-hello-world' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t\t'frontend_available' => true,\n\t\t\t\t'prefix_class' => 'opacity-siva-border-',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title2' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t$this->end_controls_section();\n\t}", "public function add_control( $wp_customize ) {}", "public function addElement(Control $element, $order = 0): Div\n {\n if ($order == 0) {\n $this->elements[] = $element;\n } else {\n $this->elements[$order] = $element;\n }\n return $this;\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'plugin-name' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Nothing to do with this', 'elhelper' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'input_type' => 'url',\n\t\t\t\t'placeholder' => __( 'https://your-link.com ', 'elhelper' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t}", "protected function _register_controls()\n\t{\n\t\t// Heading\n\t\t$this->start_controls_section(\n\t\t\t'heading_style',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__('Heading', 'elementor'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'heading_typography',\n\t\t\t\t'label' => esc_html__('Typography', 'elementor'),\n\t\t\t\t'selector' => '{{WRAPPER}} .woocommerce-additional-fields > h3',\n\t\t\t)\n\t\t);\n\t\t$this->add_control(\n\t\t\t'heading_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Color', 'elementor'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields > h3' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'heading_align',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Alignment', 'elementor'),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => esc_html__('Left', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => esc_html__('Center', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => esc_html__('Right', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'prefix_class' => '',\n\t\t\t\t'default' => '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields > h3' => 'text-align: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\n\t\t// label\n\t\t$this->start_controls_section(\n\t\t\t'label_style',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__('Label', 'webt'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'label_typography',\n\t\t\t\t'label' => esc_html__('Typography', 'elementor'),\n\t\t\t\t'selector' => '{{WRAPPER}} .woocommerce-additional-fields .form-row label',\n\t\t\t)\n\t\t);\n\t\t$this->add_control(\n\t\t\t'label_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Label Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields .form-row label' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'label_align',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Alignment', 'elementor'),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => esc_html__('Left', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => esc_html__('Center', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => esc_html__('Right', 'elementor'),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'prefix_class' => '',\n\t\t\t\t'default' => '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields .form-row label' => 'text-align: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\n\t\t// Input Fields\n\t\t$this->start_controls_section(\n\t\t\t'input_style',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__('Input Fields', 'webt'),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'input_typography',\n\t\t\t\t'label' => esc_html__('Typography', 'elementor'),\n\t\t\t\t'selector' => '{{WRAPPER}} .woocommerce-additional-fields input , {{WRAPPER}} .woocommerce-additional-fields textarea',\n\t\t\t)\n\t\t);\n\t\t$this->add_control(\n\t\t\t'input_placeholder_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Field Placeholder Input Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input::placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input::-webkit-input-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input::-moz-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input:-ms-input-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields textarea::placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields textarea::-webkit-input-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields textarea::-moz-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields textarea:-ms-input-placeholder' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'input_padding',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Padding', 'elementor'),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => ['px', 'em'],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->start_controls_tabs('tabs_input_style');\n\t\t$this->start_controls_tab(\n\t\t\t'tab_input_normal',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Normal', 'webt'),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'input_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Text Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'input_border',\n\t\t\t\t'selector' => '{{WRAPPER}} .woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'input_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Background Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'input_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Radius', 'webt'),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => ['px', '%'],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'input_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} woocommerce-additional-fields input, {{WRAPPER}} .woocommerce-additional-fields textarea',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'tab_input_focus',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Focus', 'webt'),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'input_focus_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Text Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input:focus, {{WRAPPER}} .woocommerce-additional-fields textarea:focus' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'input_focus_border',\n\t\t\t\t'selector' => '{{WRAPPER}} .woocommerce-additional-fields input:focus, {{WRAPPER}} .woocommerce-additional-fields textarea:focus',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'input_focus_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Background Color', 'webt'),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .woocommerce-additional-fields input:focus, {{WRAPPER}} .woocommerce-additional-fields textarea:focus' => 'background-color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'input_focus_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Radius', 'webt'),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => ['px', '%'],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} woocommerce-additional-fields input:focus, {{WRAPPER}} .woocommerce-additional-fields textarea:focus' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'input_focus_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} woocommerce-additional-fields input:focus, {{WRAPPER}} .woocommerce-additional-fields textarea:focus',\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_tab();\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t}", "public function build_controls()\n\t{\n\t\t$this->add_control( 'title', [\n\t\t\t'label' => __( 'Title' )\n\t\t] );\n\t\t$this->add_control( 'content', [\n\t\t\t'label' => __( 'Content' ),\n\t\t\t'type' => 'textarea'\n\t\t] );\n\t\t$this->add_control( 'link_url', [\n\t\t\t'label' => __( 'URL' )\n\t\t] );\n\t\t$this->add_control( 'link_text', [\n\t\t\t'label' => __( 'Link Text' )\n\t\t] );\n\t\t$this->add_control( 'link_target', [\n\t\t\t'label' => __( 'Open link in a new window/tab' ),\n\t\t\t'type' => 'checkbox',\n\t\t\t'value' => '1'\n\t\t] );\n\t}", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'description',\n\t\t\t[\n\t\t\t\t'label' => __( 'Description', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n /*-----------------------------------------------------------------------------------*/\n /* Content TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_section',\n array(\n 'label' => __('APR Heading', 'apr-core' ),\n )\n );\n /* Heading 1*/\n $this->add_control(\n 'title',\n array(\n 'label' => __( 'Title', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' => true\n ),\n 'placeholder' => __( 'Enter your title', 'apr-core' ),\n 'default' => __( 'Enter your title', 'apr-core' ),\n 'label_block' => true,\n )\n );\n $this->add_control(\n 'heading_size',\n array(\n 'label' => __( 'HTML Tag', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => array(\n 'h1' => __( 'H1', 'apr-core' ),\n 'h2' => __( 'H2', 'apr-core' ),\n 'h3' => __( 'H3', 'apr-core' ),\n 'h4' => __( 'H4', 'apr-core' ),\n 'h5' => __( 'H5', 'apr-core' ),\n 'p' => __( 'p', 'apr-core' ),\n ),\n 'default' => 'h3',\n )\n );\n $this->add_control(\n 'link',\n [\n 'label' => __( 'Link', 'elementor' ),\n 'type' => Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => '',\n ],\n 'separator' => 'before',\n ]\n );\n $this->add_responsive_control(\n 'alignment',\n array(\n 'label' => __('Alignment', 'apr-core'),\n 'type' => Controls_Manager::CHOOSE,\n 'default' => 'left',\n 'options' => array(\n 'left' => array(\n 'title' => __( 'Left', 'apr-core' ),\n 'icon' => 'fa fa-align-left',\n ),\n 'center' => array(\n 'title' => __( 'Center', 'apr-core' ),\n 'icon' => 'fa fa-align-center',\n ),\n 'right' => array(\n 'title' => __( 'Right', 'apr-core' ),\n 'icon' => 'fa fa-align-right',\n )\n ),\n )\n );\n $this->add_control(\n 'description',\n array(\n 'label' => __( 'Description', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' \t=> true\n ),\n )\n );\n $this->add_control(\n 'description_position',\n [\n 'label' => __( 'Description Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'bottom',\n 'options' => [\n 'aside' => __( 'Aside', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' ),\n ],\n ]\n );\n $this->add_control(\n 'list_divider',\n [\n 'label' => __( 'Divider', 'apr-core' ),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'no',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'divider_position',\n [\n 'label' => __( 'Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n 'top' => __( 'Top', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' )\n ],\n 'default' => 'bottom',\n 'condition' => [\n 'list_divider' => 'yes',\n ]\n ]\n );\n\n $this->add_control(\n 'divider_color',\n [\n 'label' => __( 'Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'divider_color_hover',\n [\n 'label' => __( 'Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:hover:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_responsive_control(\n 'divider_top',\n [\n 'label' => __( 'Top Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'top: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_left',\n [\n 'label' => __( 'Left Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'left: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_weight',\n [\n 'label' => __( 'Height', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 1,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'height: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_width',\n [\n 'label' => __( 'Width', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'default' => [\n 'size' => 100,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'width: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n \n $this->end_controls_section();\n /*-----------------------------------------------------------------------------------*/\n /* Style TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_style_section',\n array(\n 'label' => __( 'Color', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n $this->add_control(\n 'title_color',\n [\n 'label' => __( 'Title Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title,\n {{WRAPPER}} .heading-modern .heading-title a' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color',\n [\n 'label' \t=> __( 'Description color', 'apr-core' ),\n 'type' \t\t=> Controls_Manager::COLOR,\n 'scheme' \t=> [\n 'type' \t\t=> Scheme_Color::get_type(),\n 'value' \t=> Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n 'desc_style',\n array(\n 'label' => __( 'Typography', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'title_typo',\n 'label' \t=> __( 'Title', 'apr-core' ),\n 'selector' => '{{WRAPPER}} .heading-modern .heading-title',\n ]\n );\n $this->add_responsive_control(\n 'title_width',\n array(\n 'label' => __('Max width Title','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .heading-title' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'desc_typo',\n 'label' \t=> __( 'Description', 'apr-core' ),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' \t=> '{{WRAPPER}} .heading-modern .description',\n ]\n );\n $this->add_responsive_control(\n 'desc_width',\n array(\n 'label' => __('Max width Description','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .description' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_responsive_control(\n 'title_margin',\n array(\n 'label' => __( 'Margin Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n\n $this->add_responsive_control(\n 'title_padding',\n [\n 'label' => __( 'Padding Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_responsive_control(\n 'desc_margin',\n array(\n 'label' => __( 'Margin Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n $this->add_responsive_control(\n 'description_padding',\n [\n 'label' => __( 'Padding Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_control(\n 'title_color_hover',\n [\n 'label' => __( 'Title Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title:hover,\n {{WRAPPER}} .heading-modern .heading-title a:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color_hover',\n [\n 'label' => __( 'Description Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .description:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore \n\n\t\t$this->register_general_content_controls();\n\n\t\t$this->register_count_content_controls();\n\n\t\t$this->register_helpful_information();\n\t}", "public function btnAddRule_Click($strFormId, $strControlId, $strParameter) {\n\t $this->pnlAddRule->Visible = true;\n\t $this->pnlAddRule->RemoveChildControls(true);\n\t $pnlAddRuleView = new AddRule($this->pnlAddRule,'UpdateRuleList',$this); \t\t\n\t\t}", "public function BuildControls() {\n\n $this->EncType= $this->GetOption('EncType');\n\n // convert array of arrays into array of objects\n foreach($this->Controls as $Name=>&$Control) {\n // skip already builded controls\n if (is_object($Control)) {\n continue;\n }\n // find classname\n if (!isset($Control['Type'])) {\n $Control += array('Type'=>'text', 'Attributes'=>array('UNKNOWNTYPE'=>'YES'));\n }\n if (strpos($Control['Type'], '\\\\') === false) { // short name, ex.: \"select\"\n $Type= ucfirst($Control['Type']);\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\'.$Type.'Control';\n } else { // it is fully qualified class name\n $Class= $Control['Type'];\n }\n if (!class_exists($Class)) {\n $this->Error('Class \"'.$Class.'\" not found.');\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\TextControl'; // fallback to any primitive control\n }\n // copy this array into $Options and append few more items\n // and append common options to allow usage of services\n $Options= $Control + array(\n 'Name'=> $Name,\n 'Form'=> $this,\n 'Book'=> $this->GetOption('Book')\n ) + $this->GetCommonOptions();\n $Control= new $Class($Options);\n // switch to multipart encoding if any control require that\n if ($Control->GetMultipartEncoding()) {\n $this->EncType= 'multipart/form-data';\n }\n }\n $this->Builded= true;\n }", "protected function _register_controls() {\n parent::_register_controls();\n\n $this->start_controls_section(\n 'section_title',\n [\n 'label' => __( 'Single Product MultiVendor List', 'dokan' ),\n ]\n );\n\n $this->add_control(\n 'text',\n [\n 'label' => __( 'Title', 'dokan' ),\n 'default' => __( 'Other Available Vendor', 'dokan' ),\n 'placeholder' => __( 'Other Available Vendor', 'dokan' ),\n ]\n );\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n $this->start_controls_section(\n 'section_video',\n [\n 'label' => __( 'Video', 'elementor' ),\n ]\n );\n\n\n $this->add_control(\n 'insert_url',\n [\n 'label' => __( 'External URL', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n ]\n );\n\n $this->add_control(\n 'hosted_url',\n [\n 'label' => __( 'Choose File', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n 'dynamic' => [\n 'active' => true,\n 'categories' => [\n TagsModule::MEDIA_CATEGORY,\n ],\n ],\n 'media_type' => 'video',\n 'condition' => [\n 'insert_url' => '',\n ],\n ]\n );\n\n $this->add_control(\n 'external_url',\n [\n 'label' => __( 'URL', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::URL,\n 'autocomplete' => false,\n 'show_external' => false,\n 'label_block' => true,\n 'show_label' => false,\n 'dynamic' => [\n 'active' => true,\n 'categories' => [\n TagsModule::POST_META_CATEGORY,\n TagsModule::URL_CATEGORY,\n ],\n ],\n 'media_type' => 'video',\n 'placeholder' => __( 'Enter your URL', 'elementor' ),\n 'condition' => [\n 'video_type' => 'hosted',\n 'insert_url' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'start',\n [\n 'label' => __( 'Start Time', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::NUMBER,\n 'description' => __( 'Specify a start time (in seconds)', 'elementor' ),\n 'condition' => [\n 'loop' => '',\n ],\n ]\n );\n\n $this->add_control(\n 'end',\n [\n 'label' => __( 'End Time', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::NUMBER,\n 'description' => __( 'Specify an end time (in seconds)', 'elementor' ),\n 'condition' => [\n 'loop' => '',\n ],\n ]\n );\n\n $this->add_control(\n 'overlay_block',\n [\n 'label' => __( 'Overlay', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __( 'If ON the video will be blocked by an overlay with a Text and a Button at end time.', 'elementor' ),\n ]\n );\n\n $this->add_control(\n 'auto_open',\n [\n 'label' => __( 'Auto-open link', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __( 'Set if a link should be opened after video stops. It can be an Elementor Popup.', 'elementor' ),\n ]\n );\n\n $this->add_control(\n 'auto_link',\n [\n 'label' => __( 'Link', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'placeholder' => __( 'https://your-link.com', 'elementor' ),\n 'default' => [\n 'url' => '#',\n ],\n 'condition' => [\n 'auto_open' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'video_options',\n [\n 'label' => __( 'Video Options', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'autoplay',\n [\n 'label' => __( 'Autoplay', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n ]\n );\n\n $this->add_control(\n 'mute',\n [\n 'label' => __( 'Mute', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n ]\n );\n\n $this->add_control(\n 'loop',\n [\n 'label' => __( 'Loop', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n ]\n );\n\n $this->add_control(\n 'controls',\n [\n 'label' => __( 'Player Controls', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'label_off' => __( 'Hide', 'elementor' ),\n 'label_on' => __( 'Show', 'elementor' ),\n 'default' => 'yes',\n ]\n );\n\n $this->add_control(\n 'showinfo',\n [\n 'label' => __( 'Video Info', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'label_off' => __( 'Hide', 'elementor' ),\n 'label_on' => __( 'Show', 'elementor' ),\n 'default' => 'yes',\n ]\n );\n\n\n\n $this->add_control(\n 'download_button',\n [\n 'label' => __( 'Download Button', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'label_off' => __( 'Hide', 'elementor' ),\n 'label_on' => __( 'Show', 'elementor' ),\n ]\n );\n\n $this->add_control(\n 'poster',\n [\n 'label' => __( 'Poster', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n ]\n );\n\n $this->add_control(\n 'view',\n [\n 'label' => __( 'View', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::HIDDEN,\n 'default' => 'hosted',\n ]\n );\n\n $this->end_controls_section();\n\n // Heading Content\n\n $this->start_controls_section(\n 'section_heading',\n [\n 'label' => __( 'Title', 'elementor' ),\n 'condition' => [\n 'overlay_block' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'title_text',\n [\n 'label' => __( 'Text', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n 'dynamic' => [\n 'active' => true,\n ],\n 'placeholder' => __( 'Enter your title', 'elementor' ),\n 'default' => __( 'Add Your Heading Text Here', 'elementor' ),\n ]\n );\n\n $this->end_controls_section();\n\n\n // Button Content\n\n $this->start_controls_section(\n 'section_button',\n [\n 'label' => __( 'Button', 'elementor' ),\n 'condition' => [\n 'overlay_block' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'button_type',\n [\n 'label' => __( 'Type', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => '',\n 'options' => [\n '' => __( 'Default', 'elementor' ),\n 'info' => __( 'Info', 'elementor' ),\n 'success' => __( 'Success', 'elementor' ),\n 'warning' => __( 'Warning', 'elementor' ),\n 'danger' => __( 'Danger', 'elementor' ),\n ],\n 'prefix_class' => 'elementor-button-',\n ]\n );\n\n $this->add_control(\n 'text',\n [\n 'label' => __( 'Text', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => __( 'Click here', 'elementor' ),\n 'placeholder' => __( 'Click here', 'elementor' ),\n ]\n );\n\n // $this->add_control(\n // 'link',\n // [\n // 'label' => __( 'Link', 'elementor' ),\n // 'type' => \\Elementor\\Controls_Manager::TEXT,\n // 'dynamic' => [\n // 'active' => true,\n // ],\n // 'placeholder' => __( 'https://your-link.com', 'elementor' ),\n // 'default' => __( '#', 'elementor' ),\n //\n // ]\n // );\n $this->add_control(\n 'link',\n [\n 'label' => __( 'Link', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'placeholder' => __( 'https://your-link.com', 'elementor' ),\n 'default' => [\n 'url' => '#',\n ],\n ]\n );\n\n $this->add_control(\n 'new_tab',\n [\n 'label' => __( 'Open link in new tab', 'your-plugin' ),\n 'label_on' => __( 'new', 'your-plugin' ),\n 'label_off' => __( 'same', 'your-plugin' ),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'return_value' => 'yes',\n 'default' => 'no'\n ]\n );\n\n $this->add_responsive_control(\n 'align',\n [\n 'label' => __( 'Alignment', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::CHOOSE,\n 'options' => [\n 'left' => [\n 'title' => __( 'Left', 'elementor' ),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __( 'Center', 'elementor' ),\n 'icon' => 'fa fa-align-center',\n ],\n 'right' => [\n 'title' => __( 'Right', 'elementor' ),\n 'icon' => 'fa fa-align-right',\n ],\n 'justify' => [\n 'title' => __( 'Justified', 'elementor' ),\n 'icon' => 'fa fa-align-justify',\n ],\n ],\n 'prefix_class' => 'elementor%s-align-',\n 'default' => '',\n ]\n );\n\n $this->add_control(\n 'size',\n [\n 'label' => __( 'Size', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'sm',\n 'options' => self::get_button_sizes(),\n 'style_transfer' => true,\n ]\n );\n\n $this->add_control(\n 'icon',\n [\n 'label' => __( 'Icon', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::ICON,\n 'label_block' => true,\n 'default' => '',\n ]\n );\n\n $this->add_control(\n 'icon_align',\n [\n 'label' => __( 'Icon Position', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'left',\n 'options' => [\n 'left' => __( 'Before', 'elementor' ),\n 'right' => __( 'After', 'elementor' ),\n ],\n 'condition' => [\n 'icon!' => '',\n ],\n ]\n );\n\n $this->add_control(\n 'icon_indent',\n [\n 'label' => __( 'Icon Spacing', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'max' => 50,\n ],\n ],\n 'condition' => [\n 'icon!' => '',\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-button .elementor-align-icon-right' => 'margin-left: {{SIZE}}{{UNIT}};',\n '{{WRAPPER}} .elementor-button .elementor-align-icon-left' => 'margin-right: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_control(\n 'view',\n [\n 'label' => __( 'View', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::HIDDEN,\n 'default' => 'traditional',\n ]\n );\n\n $this->add_control(\n 'button_css_id',\n [\n 'label' => __( 'Button ID', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => '',\n 'title' => __( 'Add your custom id WITHOUT the Pound key. e.g: my-id', 'yx-super-cat' ),\n 'label_block' => false,\n 'description' => __( 'Please make sure the ID is unique and not used elsewhere on the page this form is displayed. This field allows <code>A-z 0-9</code> & underscore chars without spaces.', 'yx-super-cat' ),\n 'separator' => 'before',\n\n ]\n );\n\n $this->end_controls_section();\n\n // $this->start_controls_section(\n // \t'section_image_overlay',\n // \t[\n // \t\t'label' => __( 'Image Overlay', 'yx-super-cat' ),\n // \t]\n // );\n //\n // $this->add_control(\n // \t'show_image_overlay',\n // \t[\n // \t\t'label' => __( 'Image Overlay', 'yx-super-cat' ),\n // \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n // \t\t'label_off' => __( 'Hide', 'yx-super-cat' ),\n // \t\t'label_on' => __( 'Show', 'yx-super-cat' ),\n // \t]\n // );\n //\n // $this->add_control(\n // \t'image_overlay',\n // \t[\n // \t\t'label' => __( 'Choose Image', 'yx-super-cat' ),\n // \t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n // \t\t'default' => [\n // \t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n // \t\t],\n // \t\t'dynamic' => [\n // \t\t\t'active' => true,\n // \t\t],\n // \t\t'condition' => [\n // \t\t\t'show_image_overlay' => 'yes',\n // \t\t],\n // \t]\n // );\n //\n // $this->add_group_control(\n // \t\\Elementor\\Group_Control_Image_Size::get_type(),\n // \t[\n // \t\t'name' => 'image_overlay', // Usage: `{name}_size` and `{name}_custom_dimension`, in this case `image_overlay_size` and `image_overlay_custom_dimension`.\n // \t\t'default' => 'full',\n // \t\t'separator' => 'none',\n // \t\t'condition' => [\n // \t\t\t'show_image_overlay' => 'yes',\n // \t\t],\n // \t]\n // );\n //\n // $this->add_control(\n // \t'show_play_icon',\n // \t[\n // \t\t'label' => __( 'Play Icon', 'yx-super-cat' ),\n // \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n // \t\t'default' => 'yes',\n // \t\t'condition' => [\n // \t\t\t'show_image_overlay' => 'yes',\n // \t\t\t'image_overlay[url]!' => '',\n // \t\t],\n // \t]\n // );\n //\n // $this->add_control(\n // \t'lightbox',\n // \t[\n // \t\t'label' => __( 'Lightbox', 'yx-super-cat' ),\n // \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n // \t\t'frontend_available' => true,\n // \t\t'label_off' => __( 'Off', 'yx-super-cat' ),\n // \t\t'label_on' => __( 'On', 'yx-super-cat' ),\n // \t\t'condition' => [\n // \t\t\t'show_image_overlay' => 'yes',\n // \t\t\t'image_overlay[url]!' => '',\n // \t\t],\n // \t\t'separator' => 'before',\n // \t]\n // );\n //\n // $this->end_controls_section();\n\n // Video Style\n\n $this->start_controls_section(\n 'section_video_style',\n [\n 'label' => __( 'Video', 'yx-super-cat' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'aspect_ratio',\n [\n 'label' => __( 'Aspect Ratio', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'options' => [\n '169' => '16:9',\n '219' => '21:9',\n '43' => '4:3',\n '32' => '3:2',\n '11' => '1:1',\n ],\n 'default' => '169',\n 'prefix_class' => 'elementor-widget-video elementor-aspect-ratio-',\n 'frontend_available' => true,\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Css_Filter::get_type(),\n [\n 'name' => 'css_filters',\n 'selector' => '{{WRAPPER}} .elementor-wrapper',\n ]\n );\n\n $this->add_control(\n 'play_icon_title',\n [\n 'label' => __( 'Play Icon', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::HEADING,\n 'condition' => [\n 'show_image_overlay' => 'yes',\n 'show_play_icon' => 'yes',\n ],\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'play_icon_color',\n [\n 'label' => __( 'Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-custom-embed-play i' => 'color: {{VALUE}}',\n ],\n 'condition' => [\n 'show_image_overlay' => 'yes',\n 'show_play_icon' => 'yes',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'play_icon_size',\n [\n 'label' => __( 'Size', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 10,\n 'max' => 300,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-custom-embed-play i' => 'font-size: {{SIZE}}{{UNIT}}',\n ],\n 'condition' => [\n 'show_image_overlay' => 'yes',\n 'show_play_icon' => 'yes',\n ],\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Text_Shadow::get_type(),\n [\n 'name' => 'play_icon_text_shadow',\n 'selector' => '{{WRAPPER}} .elementor-custom-embed-play i',\n 'fields_options' => [\n 'text_shadow_type' => [\n 'label' => _x( 'Shadow', 'Text Shadow Control', 'yx-super-cat' ),\n ],\n ],\n 'condition' => [\n 'show_image_overlay' => 'yes',\n 'show_play_icon' => 'yes',\n ],\n ]\n );\n\n $this->end_controls_section();\n\n\n // Overlay Style\n\n $this->start_controls_section(\n 'section_overlay_style',\n [\n 'label' => __( 'Overlay', 'elementor' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'overlay_block' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'overlay_color',\n [\n 'label' => __( 'Overlay Color', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .super-video-stopper' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->end_controls_section();\n\n\n\n // Heading Style\n\n $this->start_controls_section(\n 'section_title_style',\n [\n 'label' => __( 'Title', 'elementor' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'overlay_block' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'margin_bottom_tit',\n [\n 'label' => __( 'Bottom Margin', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-heading-title' => 'padding-bottom: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_control(\n 'title_color',\n [\n 'label' => __( 'Text Color', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .elementor-heading-title' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Typography::get_type(),\n [\n 'name' => 'typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .elementor-heading-title',\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Text_Shadow::get_type(),\n [\n 'name' => 'text_shadow',\n 'selector' => '{{WRAPPER}} .elementor-heading-title',\n ]\n );\n\n $this->add_control(\n 'blend_mode',\n [\n 'label' => __( 'Blend Mode', 'elementor' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'options' => [\n '' => __( 'Normal', 'elementor' ),\n 'multiply' => 'Multiply',\n 'screen' => 'Screen',\n 'overlay' => 'Overlay',\n 'darken' => 'Darken',\n 'lighten' => 'Lighten',\n 'color-dodge' => 'Color Dodge',\n 'saturation' => 'Saturation',\n 'color' => 'Color',\n 'difference' => 'Difference',\n 'exclusion' => 'Exclusion',\n 'hue' => 'Hue',\n 'luminosity' => 'Luminosity',\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-heading-title' => 'mix-blend-mode: {{VALUE}}',\n ],\n 'separator' => 'none',\n ]\n );\n\n $this->end_controls_section();\n\n // Lightbox\n\n $this->start_controls_section(\n 'section_lightbox_style',\n [\n 'label' => __( 'Lightbox', 'yx-super-cat' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'show_image_overlay' => 'yes',\n 'image_overlay[url]!' => '',\n 'lightbox' => 'yes',\n ],\n ]\n );\n\n $this->add_control(\n 'lightbox_color',\n [\n 'label' => __( 'Background Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '#elementor-lightbox-{{ID}}' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'lightbox_ui_color',\n [\n 'label' => __( 'UI Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '#elementor-lightbox-{{ID}} .dialog-lightbox-close-button' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'lightbox_ui_color_hover',\n [\n 'label' => __( 'UI Hover Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '#elementor-lightbox-{{ID}} .dialog-lightbox-close-button:hover' => 'color: {{VALUE}}',\n ],\n 'separator' => 'after',\n ]\n );\n\n $this->add_control(\n 'lightbox_video_width',\n [\n 'label' => __( 'Content Width', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'unit' => '%',\n ],\n 'range' => [\n '%' => [\n 'min' => 50,\n ],\n ],\n 'selectors' => [\n '(desktop+)#elementor-lightbox-{{ID}} .elementor-video-container' => 'width: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_control(\n 'lightbox_content_position',\n [\n 'label' => __( 'Content Position', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'frontend_available' => true,\n 'options' => [\n '' => __( 'Center', 'yx-super-cat' ),\n 'top' => __( 'Top', 'yx-super-cat' ),\n ],\n 'selectors' => [\n '#elementor-lightbox-{{ID}} .elementor-video-container' => '{{VALUE}}; transform: translateX(-50%);',\n ],\n 'selectors_dictionary' => [\n 'top' => 'top: 60px',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'lightbox_content_animation',\n [\n 'label' => __( 'Entrance Animation', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::ANIMATION,\n 'frontend_available' => true,\n ]\n );\n\n $this->end_controls_section();\n\n\n // Button Style\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __( 'Button', 'yx-super-cat' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'overlay_block' => 'yes',\n ],\n ]\n );\n\n\n $this->start_controls_tabs( 'tabs_button_style' );\n\n $this->start_controls_tab(\n 'tab_button_normal',\n [\n 'label' => __( 'Normal', 'yx-super-cat' ),\n ]\n );\n\n $this->add_control(\n 'button_text_color',\n [\n 'label' => __( 'Text Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'default' => '',\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button, {{WRAPPER}} .elementor-button' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Typography::get_type(),\n [\n 'name' => 'typography_btn',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} a.elementor-button, {{WRAPPER}} .elementor-button',\n ]\n );\n\n $this->add_control(\n 'background_color',\n [\n 'label' => __( 'Background Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_4,\n ],\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button, {{WRAPPER}} .elementor-button' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'tab_button_hover',\n [\n 'label' => __( 'Hover', 'yx-super-cat' ),\n ]\n );\n\n $this->add_control(\n 'hover_color',\n [\n 'label' => __( 'Text Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button:hover, {{WRAPPER}} .elementor-button:hover, {{WRAPPER}} a.elementor-button:focus, {{WRAPPER}} .elementor-button:focus' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Typography::get_type(),\n [\n 'name' => 'typography_btn_hover',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} a.elementor-button:hover, {{WRAPPER}} .elementor-button:hover, {{WRAPPER}} a.elementor-button:focus, {{WRAPPER}} .elementor-button:focus',\n ]\n );\n\n $this->add_control(\n 'button_background_hover_color',\n [\n 'label' => __( 'Background Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button:hover, {{WRAPPER}} .elementor-button:hover, {{WRAPPER}} a.elementor-button:focus, {{WRAPPER}} .elementor-button:focus' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'button_hover_border_color',\n [\n 'label' => __( 'Border Color', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'condition' => [\n 'border_border!' => '',\n ],\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button:hover, {{WRAPPER}} .elementor-button:hover, {{WRAPPER}} a.elementor-button:focus, {{WRAPPER}} .elementor-button:focus' => 'border-color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_control(\n 'hover_animation',\n [\n 'label' => __( 'Hover Animation', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::HOVER_ANIMATION,\n ]\n );\n\n $this->end_controls_tab();\n\n $this->end_controls_tabs();\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Border::get_type(),\n [\n 'name' => 'border',\n 'selector' => '{{WRAPPER}} .elementor-button',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'border_radius',\n [\n 'label' => __( 'Border Radius', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button, {{WRAPPER}} .elementor-button' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_group_control(\n \\Elementor\\Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'button_box_shadow',\n 'selector' => '{{WRAPPER}} .elementor-button',\n ]\n );\n\n $this->add_responsive_control(\n 'text_padding',\n [\n 'label' => __( 'Padding', 'yx-super-cat' ),\n 'type' => \\Elementor\\Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} a.elementor-button, {{WRAPPER}} .elementor-button' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ],\n 'separator' => 'before',\n ]\n );\n\n $this->end_controls_section();\n\n }", "protected function _register_controls() {\n // `Testimonial Carousel` Section\n $this->start_controls_section( 'testimonial_carousel', array(\n 'label' => 'Testimonial Carousel',\n 'tab' => Controls_Manager::TAB_CONTENT,\n ) );\n\n $repeater = new \\Elementor\\Repeater();\n\n $repeater->add_control( 'testimonial_image', array(\n 'label' => 'Choose Image',\n 'type' => Controls_Manager::MEDIA,\n 'default' => array(\n 'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n ),\n ) );\n\n $repeater->add_group_control( \\Elementor\\Group_Control_Image_Size::get_type(), array(\n 'name' => 'testimonial_img_size',\n 'exclude' => array(),\n 'include' => array(),\n 'default' => 'thumbnail',\n ) );\n\n $repeater->add_control( 'testimonial_content', array(\n 'label' => 'Content',\n 'type' => Controls_Manager::TEXTAREA,\n 'default' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut elit tellus, luctus nec ullamcorper mattis, pulvinar dapibus leo.',\n ) );\n\n $repeater->add_control( 'testimonial_name', array(\n 'label' => 'Name',\n 'type' => Controls_Manager::TEXT,\n 'default' => 'John Doe',\n ) );\n\n $repeater->add_control( 'testimonial_title', array(\n 'label' => 'Title',\n 'type' => Controls_Manager::TEXT,\n 'default' => 'Web Developer',\n ) );\n\n $this->add_control( 'testimonial_list', array(\n 'label' => 'Testimonials',\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'default' => array(\n array(\n 'testimonial_content' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec pharetra magna eu nisi porttitor, ut auctor felis commodo. Fusce nunc nisl, volutpat vel dolor eget, dapibus congue mauris. Nullam vestibulum eros vitae augue sagittis aliquet. Nulla tempor imperdiet enim eu pulvinar.',\n ),\n array(\n 'testimonial_content' => 'Suspendisse nec imperdiet nisi, eu pulvinar turpis. Maecenas consequat pharetra mi eget volutpat. Vivamus quis pulvinar ante. Mauris vitae bibendum orci. Quisque porta dui mauris, eget facilisis nunc cursus et. Pellentesque condimentum mollis dignissim. Cras vehicula lacinia nulla, blandit luctus lectus ornare quis.',\n ),\n array(\n 'testimonial_content' => 'Etiam ac ligula magna. Nam tempus lorem a leo fermentum, eget iaculis eros vulputate. Fusce sollicitudin nulla ac aliquam scelerisque. Fusce nec dictum magna. Ut maximus ultrices pulvinar. Integer sit amet felis tellus. Phasellus turpis ex, luctus vulputate egestas eget, laoreet et nunc.',\n ),\n ),\n 'title_field' => '{{{ testimonial_name }}}'\n ) );\n\n $this->end_controls_section();\n\n // `Image` Section\n $this->start_controls_section( 'testimonial_image_style', array(\n 'label' => 'Image',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_image_size', array(\n 'label' => 'Image Size',\n 'type' => Controls_Manager::SLIDER,\n 'range' => array(\n 'px' => array(\n 'min' => 50,\n 'max' => 500,\n 'step' => 5,\n ),\n ),\n 'selectors' => array(\n '{{WRAPPER}} .img-box' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Border::get_type(), array(\n 'name' => 'testimonial_image_border',\n 'label' => 'Border Type',\n 'selector' => '{{WRAPPER}} .img-box',\n ) );\n\n $this->add_control( 'testimonial_image_border_radius', array(\n 'label' => 'Border Radius',\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units'=> array( 'px', '%' ),\n 'selectors' => array(\n '{{WRAPPER}} .img-box' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n '{{WRAPPER}} .img-box img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ), \n ) );\n\n $this->end_controls_section();\n\n // `Content` Section\n $this->start_controls_section( 'testimonial_content_style', array(\n 'label' => 'Content',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_content_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_3,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial-content' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_content_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_3,\n 'selector' => '{{WRAPPER}} .testimonial-content',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_content_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial-content',\n ) );\n\n $this->end_controls_section();\n\n // `Name` Section\n $this->start_controls_section( 'testimonial_name_style', array(\n 'label' => 'Name',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_name_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_1,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial_name' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_name_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .testimonial_name',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_name_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial_name',\n ) );\n\n $this->end_controls_section();\n\n // `Title` Section\n $this->start_controls_section( 'testimonial_title_style', array(\n 'label' => 'Title',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_title_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_3,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial_title' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_title_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_3,\n 'selector' => '{{WRAPPER}} .testimonial_title',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_title_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial_title',\n ) );\n\n $this->end_controls_section();\n }", "public function register_control_type($control)\n {\n }", "protected function register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'_section_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Advanced', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t// Element Name for the Navigator\n\t\t$this->add_control(\n\t\t\t'_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::HIDDEN,\n\t\t\t\t'render_type' => 'none',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_margin',\n\t\t\t[\n\t\t\t\t'label' => __( 'Margin', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%', 'rem' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} > .elementor-widget-container' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_padding',\n\t\t\t[\n\t\t\t\t'label' => __( 'Padding', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%', 'rem' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} > .elementor-widget-container' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_z_index',\n\t\t\t[\n\t\t\t\t'label' => __( 'Z-Index', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'min' => 0,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'z-index: {{VALUE}};',\n\t\t\t\t],\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_element_id',\n\t\t\t[\n\t\t\t\t'label' => __( 'CSS ID', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'dynamic' => [\n\t\t\t\t\t'active' => true,\n\t\t\t\t],\n\t\t\t\t'default' => '',\n\t\t\t\t'title' => __( 'Add your custom id WITHOUT the Pound key. e.g: my-id', 'elementor' ),\n\t\t\t\t'style_transfer' => false,\n\t\t\t\t'classes' => 'elementor-control-direction-ltr',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_css_classes',\n\t\t\t[\n\t\t\t\t'label' => __( 'CSS Classes', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'dynamic' => [\n\t\t\t\t\t'active' => true,\n\t\t\t\t],\n\t\t\t\t'prefix_class' => '',\n\t\t\t\t'title' => __( 'Add your custom class WITHOUT the dot. e.g: my-class', 'elementor' ),\n\t\t\t\t'classes' => 'elementor-control-direction-ltr',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_effects',\n\t\t\t[\n\t\t\t\t'label' => __( 'Motion Effects', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_animation',\n\t\t\t[\n\t\t\t\t'label' => __( 'Entrance Animation', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::ANIMATION,\n\t\t\t\t'frontend_available' => true,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'animation_duration',\n\t\t\t[\n\t\t\t\t'label' => __( 'Animation Duration', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '',\n\t\t\t\t'options' => [\n\t\t\t\t\t'slow' => __( 'Slow', 'elementor' ),\n\t\t\t\t\t'' => __( 'Normal', 'elementor' ),\n\t\t\t\t\t'fast' => __( 'Fast', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'prefix_class' => 'animated-',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_animation!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_animation_delay',\n\t\t\t[\n\t\t\t\t'label' => __( 'Animation Delay', 'elementor' ) . ' (ms)',\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'default' => '',\n\t\t\t\t'min' => 0,\n\t\t\t\t'step' => 100,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_animation!' => '',\n\t\t\t\t],\n\t\t\t\t'render_type' => 'none',\n\t\t\t\t'frontend_available' => true,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'_section_background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Background', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tabs( '_tabs_background' );\n\n\t\t$this->start_controls_tab(\n\t\t\t'_tab_background_normal',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_background',\n\t\t\t\t'selector' => '{{WRAPPER}} > .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'_tab_background_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_background_hover',\n\t\t\t\t'selector' => '{{WRAPPER}}:hover .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_background_hover_transition',\n\t\t\t[\n\t\t\t\t'label' => __( 'Transition Duration', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 3,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'render_type' => 'ui',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} > .elementor-widget-container' => 'transition: background {{SIZE}}s',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'_section_border',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->start_controls_tabs( '_tabs_border' );\n\n\t\t$this->start_controls_tab(\n\t\t\t'_tab_border_normal',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_border',\n\t\t\t\t'selector' => '{{WRAPPER}} > .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_border_radius',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} > .elementor-widget-container' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} > .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'_tab_border_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_border_hover',\n\t\t\t\t'selector' => '{{WRAPPER}}:hover .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_border_radius_hover',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Radius', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}:hover > .elementor-widget-container' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => '_box_shadow_hover',\n\t\t\t\t'selector' => '{{WRAPPER}}:hover .elementor-widget-container',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_border_hover_transition',\n\t\t\t[\n\t\t\t\t'label' => __( 'Transition Duration', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 3,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .elementor-widget-container' => 'transition: background {{_background_hover_transition.SIZE}}s, border {{SIZE}}s, border-radius {{SIZE}}s, box-shadow {{SIZE}}s',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'_section_masking',\n\t\t\t[\n\t\t\t\t'label' => __( 'Mask', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_mask_switch',\n\t\t\t[\n\t\t\t\t'label' => __( 'Mask', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'On', 'elementor' ),\n\t\t\t\t'label_off' => __( 'Off', 'elementor' ),\n\t\t\t\t'default' => '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control( '_mask_shape', [\n\t\t\t'label' => __( 'Shape', 'elementor' ),\n\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t'options' => $this->get_shapes(),\n\t\t\t'default' => 'circle',\n\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-image: url( ' . ELEMENTOR_ASSETS_URL . '/mask-shapes/{{VALUE}}.svg );' ),\n\t\t\t'condition' => [\n\t\t\t\t'_mask_switch!' => '',\n\t\t\t],\n\t\t] );\n\n\t\t$this->add_control(\n\t\t\t'_mask_image',\n\t\t\t[\n\t\t\t\t'label' => __( 'Image', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t'media_type' => 'image',\n\t\t\t\t'should_include_svg_inline_option' => true,\n\t\t\t\t'library_type' => 'image/svg+xml',\n\t\t\t\t'dynamic' => [\n\t\t\t\t\t'active' => true,\n\t\t\t\t],\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-image: url( {{URL}} );' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t\t'_mask_shape' => 'custom',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_mask_notice',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::HIDDEN,\n\t\t\t\t'raw' => __( 'Need More Shapes?', 'elementor' ) . '<br>' . sprintf( __( 'Explore additional Premium Shape packs and use them in your site. <a target=\"_blank\" href=\"%s\">Learn More</a>', 'elementor' ), 'https://go.elementor.com/mask-control' ),\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Size', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'contain' => __( 'Fit', 'elementor' ),\n\t\t\t\t\t'cover' => __( 'Fill', 'elementor' ),\n\t\t\t\t\t'custom' => __( 'Custom', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'contain',\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-size: {{VALUE}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_size_scale',\n\t\t\t[\n\t\t\t\t'label' => __( 'Scale', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', 'em', '%', 'vw' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 500,\n\t\t\t\t\t],\n\t\t\t\t\t'em' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t\t'size' => 100,\n\t\t\t\t],\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-size: {{SIZE}}{{UNIT}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t\t'_mask_size' => 'custom',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_position',\n\t\t\t[\n\t\t\t\t'label' => __( 'Position', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'center center' => __( 'Center Center', 'elementor' ),\n\t\t\t\t\t'center left' => __( 'Center Left', 'elementor' ),\n\t\t\t\t\t'center right' => __( 'Center Right', 'elementor' ),\n\t\t\t\t\t'top center' => __( 'Top Center', 'elementor' ),\n\t\t\t\t\t'top left' => __( 'Top Left', 'elementor' ),\n\t\t\t\t\t'top right' => __( 'Top Right', 'elementor' ),\n\t\t\t\t\t'bottom center' => __( 'Bottom Center', 'elementor' ),\n\t\t\t\t\t'bottom left' => __( 'Bottom Left', 'elementor' ),\n\t\t\t\t\t'bottom right' => __( 'Bottom Right', 'elementor' ),\n\t\t\t\t\t'custom' => __( 'Custom', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'center center',\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-position: {{VALUE}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_position_x',\n\t\t\t[\n\t\t\t\t'label' => __( 'X Position', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', 'em', '%', 'vw' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -500,\n\t\t\t\t\t\t'max' => 500,\n\t\t\t\t\t],\n\t\t\t\t\t'em' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t\t'size' => 0,\n\t\t\t\t],\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-position-x: {{SIZE}}{{UNIT}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t\t'_mask_position' => 'custom',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_position_y',\n\t\t\t[\n\t\t\t\t'label' => __( 'Y Position', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', 'em', '%', 'vw' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -500,\n\t\t\t\t\t\t'max' => 500,\n\t\t\t\t\t],\n\t\t\t\t\t'em' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t\t'size' => 0,\n\t\t\t\t],\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-position-y: {{SIZE}}{{UNIT}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t\t'_mask_position' => 'custom',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_mask_repeat',\n\t\t\t[\n\t\t\t\t'label' => __( 'Repeat', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'options' => [\n\t\t\t\t\t'no-repeat' => __( 'No-Repeat', 'elementor' ),\n\t\t\t\t\t'repeat' => __( 'Repeat', 'elementor' ),\n\t\t\t\t\t'repeat-x' => __( 'Repeat-X', 'elementor' ),\n\t\t\t\t\t'repeat-Y' => __( 'Repeat-Y', 'elementor' ),\n\t\t\t\t\t'round' => __( 'Round', 'elementor' ),\n\t\t\t\t\t'space' => __( 'Space', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'default' => 'no-repeat',\n\t\t\t\t'selectors' => $this->get_mask_selectors( '-webkit-mask-repeat: {{VALUE}};' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_mask_switch!' => '',\n\t\t\t\t\t'_mask_size!' => 'cover',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'_section_position',\n\t\t\t[\n\t\t\t\t'label' => __( 'Positioning', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_element_width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Width', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '',\n\t\t\t\t'options' => [\n\t\t\t\t\t'' => __( 'Default', 'elementor' ),\n\t\t\t\t\t'inherit' => __( 'Full Width', 'elementor' ) . ' (100%)',\n\t\t\t\t\t'auto' => __( 'Inline', 'elementor' ) . ' (auto)',\n\t\t\t\t\t'initial' => __( 'Custom', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'selectors_dictionary' => [\n\t\t\t\t\t'inherit' => '100%',\n\t\t\t\t],\n\t\t\t\t'prefix_class' => 'elementor-widget%s__width-',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'width: {{VALUE}}; max-width: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_element_custom_width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Custom Width', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_element_width' => 'initial',\n\t\t\t\t],\n\t\t\t\t'device_args' => [\n\t\t\t\t\tControls_Stack::RESPONSIVE_TABLET => [\n\t\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t\t'_element_width_tablet' => [ 'initial' ],\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t\tControls_Stack::RESPONSIVE_MOBILE => [\n\t\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t\t'_element_width_mobile' => [ 'initial' ],\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', '%', 'vw' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'width: {{SIZE}}{{UNIT}}; max-width: {{SIZE}}{{UNIT}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_element_vertical_align',\n\t\t\t[\n\t\t\t\t'label' => __( 'Vertical Align', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'flex-start' => [\n\t\t\t\t\t\t'title' => __( 'Start', 'elementor' ),\n\t\t\t\t\t\t'icon' => 'eicon-v-align-top',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'elementor' ),\n\t\t\t\t\t\t'icon' => 'eicon-v-align-middle',\n\t\t\t\t\t],\n\t\t\t\t\t'flex-end' => [\n\t\t\t\t\t\t'title' => __( 'End', 'elementor' ),\n\t\t\t\t\t\t'icon' => 'eicon-v-align-bottom',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_element_width!' => '',\n\t\t\t\t\t'_position' => '',\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'align-self: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_position_description',\n\t\t\t[\n\t\t\t\t'raw' => '<strong>' . __( 'Please note!', 'elementor' ) . '</strong> ' . __( 'Custom positioning is not considered best practice for responsive web design and should not be used too frequently.', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::RAW_HTML,\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-warning',\n\t\t\t\t'render_type' => 'ui',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_position',\n\t\t\t[\n\t\t\t\t'label' => __( 'Position', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '',\n\t\t\t\t'options' => [\n\t\t\t\t\t'' => __( 'Default', 'elementor' ),\n\t\t\t\t\t'absolute' => __( 'Absolute', 'elementor' ),\n\t\t\t\t\t'fixed' => __( 'Fixed', 'elementor' ),\n\t\t\t\t],\n\t\t\t\t'prefix_class' => 'elementor-',\n\t\t\t\t'frontend_available' => true,\n\t\t\t]\n\t\t);\n\n\t\t$start = is_rtl() ? __( 'Right', 'elementor' ) : __( 'Left', 'elementor' );\n\t\t$end = ! is_rtl() ? __( 'Right', 'elementor' ) : __( 'Left', 'elementor' );\n\n\t\t$this->add_control(\n\t\t\t'_offset_orientation_h',\n\t\t\t[\n\t\t\t\t'label' => __( 'Horizontal Orientation', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'toggle' => false,\n\t\t\t\t'default' => 'start',\n\t\t\t\t'options' => [\n\t\t\t\t\t'start' => [\n\t\t\t\t\t\t'title' => $start,\n\t\t\t\t\t\t'icon' => 'eicon-h-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'end' => [\n\t\t\t\t\t\t'title' => $end,\n\t\t\t\t\t\t'icon' => 'eicon-h-align-right',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'classes' => 'elementor-control-start-end',\n\t\t\t\t'render_type' => 'ui',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_offset_x',\n\t\t\t[\n\t\t\t\t'label' => __( 'Offset', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -1000,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vh' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => '0',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', '%', 'vw', 'vh' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'body:not(.rtl) {{WRAPPER}}' => 'left: {{SIZE}}{{UNIT}}',\n\t\t\t\t\t'body.rtl {{WRAPPER}}' => 'right: {{SIZE}}{{UNIT}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_offset_orientation_h!' => 'end',\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_offset_x_end',\n\t\t\t[\n\t\t\t\t'label' => __( 'Offset', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -1000,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vh' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => '0',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', '%', 'vw', 'vh' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'body:not(.rtl) {{WRAPPER}}' => 'right: {{SIZE}}{{UNIT}}',\n\t\t\t\t\t'body.rtl {{WRAPPER}}' => 'left: {{SIZE}}{{UNIT}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_offset_orientation_h' => 'end',\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'_offset_orientation_v',\n\t\t\t[\n\t\t\t\t'label' => __( 'Vertical Orientation', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'toggle' => false,\n\t\t\t\t'default' => 'start',\n\t\t\t\t'options' => [\n\t\t\t\t\t'start' => [\n\t\t\t\t\t\t'title' => __( 'Top', 'elementor' ),\n\t\t\t\t\t\t'icon' => 'eicon-v-align-top',\n\t\t\t\t\t],\n\t\t\t\t\t'end' => [\n\t\t\t\t\t\t'title' => __( 'Bottom', 'elementor' ),\n\t\t\t\t\t\t'icon' => 'eicon-v-align-bottom',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'render_type' => 'ui',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_offset_y',\n\t\t\t[\n\t\t\t\t'label' => __( 'Offset', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -1000,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vh' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', '%', 'vh', 'vw' ],\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => '0',\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'top: {{SIZE}}{{UNIT}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_offset_orientation_v!' => 'end',\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'_offset_y_end',\n\t\t\t[\n\t\t\t\t'label' => __( 'Offset', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => -1000,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vh' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => -200,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', '%', 'vh', 'vw' ],\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => '0',\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}}' => 'bottom: {{SIZE}}{{UNIT}}',\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'_offset_orientation_v' => 'end',\n\t\t\t\t\t'_position!' => '',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'_section_responsive',\n\t\t\t[\n\t\t\t\t'label' => __( 'Responsive', 'elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'responsive_description',\n\t\t\t[\n\t\t\t\t'raw' => __( 'Responsive visibility will take effect only on preview or live page, and not while editing in Elementor.', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::RAW_HTML,\n\t\t\t\t'content_classes' => 'elementor-descriptor',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_desktop',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hide On Desktop', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => '',\n\t\t\t\t'prefix_class' => 'elementor-',\n\t\t\t\t'label_on' => 'Hide',\n\t\t\t\t'label_off' => 'Show',\n\t\t\t\t'return_value' => 'hidden-desktop',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_tablet',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hide On Tablet', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => '',\n\t\t\t\t'prefix_class' => 'elementor-',\n\t\t\t\t'label_on' => 'Hide',\n\t\t\t\t'label_off' => 'Show',\n\t\t\t\t'return_value' => 'hidden-tablet',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_mobile',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hide On Mobile', 'elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => '',\n\t\t\t\t'prefix_class' => 'elementor-',\n\t\t\t\t'label_on' => 'Hide',\n\t\t\t\t'label_off' => 'Show',\n\t\t\t\t'return_value' => 'hidden-phone',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\tPlugin::$instance->controls_manager->add_custom_attributes_controls( $this );\n\n\t\tPlugin::$instance->controls_manager->add_custom_css_controls( $this );\n\t}", "protected function _register_controls() {\n\t\t$this->query_controls();\n\t\t$this->layout_controls();\n\n $this->start_controls_section(\n 'eael_section_post_block_style',\n [\n 'label' => __( 'Post Block Style', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\n $this->add_control(\n\t\t\t'eael_post_block_bg_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post Background Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\n $this->add_control(\n\t\t\t'eael_thumbnail_overlay_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Thumbnail Overlay Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => 'rgba(0,0,0, .5)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-overlay, {{WRAPPER}} .eael-post-block.post-block-style-overlay .eael-entry-wrapper' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_spacing',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Spacing Between Items', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', '%', 'em' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_border',\n\t\t\t\t'label' => esc_html__( 'Border', 'essential-addons-elementor' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border Radius', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'border-radius: {{TOP}}px {{RIGHT}}px {{BOTTOM}}px {{LEFT}}px;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n $this->start_controls_section(\n 'eael_section_typography',\n [\n 'label' => __( 'Color & Typography', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_title_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#303133',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title, {{WRAPPER}} .eael-entry-title a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_hover_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Hover Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#23527c',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title:hover, {{WRAPPER}} .eael-entry-title a:hover' => 'color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_title_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title' => 'text-align: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_title_typography',\n\t\t\t\t'label' => __( 'Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-title',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_excerpt_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_excerpt_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_excerpt_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_excerpt_typography',\n\t\t\t\t'label' => __( 'Excerpt Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-grid-post-excerpt p',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_meta_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_meta_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta, .eael-entry-meta a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_footer',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'flex-start' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'flex-end' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'stretch' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-footer' => 'justify-content: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-footer',\n ]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_header',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-header',\n ]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_meta_typography',\n\t\t\t\t'label' => __( 'Meta Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-meta > div, {{WRAPPER}} .eael-entry-meta > span',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Load More Button Style Controls!\n\t\t */\n\t\t$this->load_more_button_style();\n\n\t}", "protected function _register_controls() {\n \n \t$this->start_controls_section(\n \t\t'section_listing_posts',\n \t\t[\n \t\t\t'label' => __( 'Listing Posts', 'listslides' ),\n \t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n \t\t]\n \t); \n\n \t$this->add_control(\n \t\t'item_per_page',\n \t\t[\n \t\t\t'label' => __( 'Number of Listings', 'listslides' ),\n \t\t\t'type' => Controls_Manager::SELECT,\n \t\t\t'default' => 5,\n \t\t\t'options' => [\n \t\t\t\t2 => __( 'Two', 'listslides' ),\n \t\t\t\t3 => __( 'Three', 'listslides' ),\n \t\t\t\t4 => __( 'Four', 'listslides' ),\n \t\t\t\t5 => __( 'Five', 'listslides')\n \t\t\t]\n \t\t]\n \t);\n\n \t$this->end_controls_section();\n\n \t$this->start_controls_section(\n\t\t\t'slide_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Slides Settings', 'listslides' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'nav',\n\t\t\t[\n\t\t\t\t'label' => __( 'Navigation Arrow', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'dots',\n\t\t\t[\n\t\t\t\t'label' => __( 'Dots', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplay',\n\t\t\t[\n\t\t\t\t'label' => __( 'Auto Play', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\t[\n\t\t\t\t'label' => __( 'Loop', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'mouseDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Mouse Drag', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'touchDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Touch Motion', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplayTimeout',\n\t\t\t[\n\t\t\t\t'label' => __( 'Autoplay Timeout', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '3000',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'autoplay' => 'true',\n\t\t\t\t],\n\t\t\t\t'options' => [\n\t\t\t\t\t'2000' => __( '2 Seconds', 'listslides' ),\n\t\t\t\t\t'3000' => __( '3 Seconds', 'listslides' ),\n\t\t\t\t\t'5000' => __( '5 Seconds', 'listslides' ),\n\t\t\t\t\t'10000' => __( '10 Seconds', 'listslides' ),\n\t\t\t\t\t'15000' => __( '15 Seconds', 'listslides' ),\n\t\t\t\t\t'20000' => __( '20 Seconds', 'listslides' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n }", "function addStyleControl($params, $section = null) {\n // otherwise add it to the element root\n if ($section) {\n $l = $section;\n } else {\n $l = $this->El;\n }\n\n $control_type = isset($params['control_type']) ? $params['control_type'] : $this->get_control_type_by_css_property($params['property']);\n\n // use the provided name as the control label if it is set\n // otherwise auto generate a name based on the CSS property it sets\n if (isset($params['name'])) {\n $control_label = $params['name'];\n } else {\n $control_label = ucwords(str_replace('-', ' ', $params['property']));\n }\n\n // generate a unique slug for the control\n // based on the selector and the css property\n if (isset($params['selectors'])) {\n // take the first selector from array to generate the slug. Is there a better way?\n $property = str_replace('-', '_', $params['selectors'][0]['property']);\n\n $selector = $params['selectors'][0]['selector'];\n $selector = str_replace(\" \", \"-\", $selector);\n $selector = preg_replace(\"/[^A-Za-z0-9 ]/\", \"\", $selector);\n\n $control_slug = 'slug_'.$selector.'_'.$property;\n\n }\n else if (isset($params['selector'])) {\n \n $property = str_replace('-', '_', $params['property']);\n \n $selector = $params['selector'];\n $selector = str_replace(\" \", \"-\", $selector);\n $selector = preg_replace(\"/[^A-Za-z0-9 ]/\", \"\", $selector);\n\n $control_slug = 'slug_'.$selector.'_'.$property;\n }\n else {\n $control_slug = $params['property'];\n }\n if (isset($params['slug'])) {\n $control_slug = $params['slug'];\n }\n\n $control = $l->addControl($control_type, $control_slug, __($control_label));\n\n // now map the control to the appropriate css selector, based on the control slug\n if (isset($params['selector'])){\n // single\n $this->mapPropertyHelper($params['selector'], $params['property'], $control_slug);\n }\n elseif (isset($params['selectors']) && is_array($params['selectors'])) {\n // multiple\n foreach ($params['selectors'] as $selector) {\n $this->mapPropertyHelper($selector['selector'], $selector['property'], $control_slug);\n $this->fixUnitsAndValues($control, $selector['property']);\n }\n }\n // if no selector defined assume this is a CSSOption\n else {\n $control->CSSOption();\n }\n\n // utility function to set the units and values properply\n // depending on the CSS property the control is affecting\n // for example, it will add the px unit to a control that is applied to font-size\n // and 100 - 900 values to a control setting font-weight \n if (isset($params['property'])){\n $this->fixUnitsAndValues($control, $params['property']);\n }\n\n if (isset($params['unit'])){\n $control->setUnits($params['unit']);\n }\n if (isset($params['value'])){\n $control->setValue($params['value']);\n }\n\n if (isset($params['default'])) {\n $control->setDefaultValue($params['default']);\n }\n\n if (isset($params['condition'])) {\n $control->setCondition($params['condition']);\n }\n\n if (isset($params['description'])) {\n $control->setDescription($params['description']);\n }\n\n if (isset($params['hidden'])) {\n $control->hidden();\n }\n\n // call whiteList to make the control settable in classes, states, and media queries\n $control->whiteList();\n\n\n return $control;\n\n }", "protected function _register_controls() {\n\n $nav_menus = wp_get_nav_menus();\n\n $nav_menus_option = array(\n esc_html__( 'Select a menu', 'Alita-extensions' ) => '',\n );\n\n foreach ( $nav_menus as $key => $nav_menu ) {\n $nav_menus_option[$nav_menu->name] = $nav_menu->name;\n }\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'description' => esc_html__( 'Enter the title of menu.', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => 'Alita Best Selling:',\n ]\n );\n\n $this->add_control(\n 'menu',\n [\n\n 'label' => esc_html__( 'Menu', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'vertical-menu',\n 'options' => $nav_menus_option,\n ]\n );\n \n\n $this->end_controls_section();\n\n }", "public function addMemberUnderControl(Member $memberToAdd)\n {\n $this->peopleUnderControl->addMember($memberToAdd, $this);\n }", "public function addsButtons() {}", "public function setControls(LdapControl ...$controls)\n {\n $this->controls = $controls;\n }", "protected function _setAddButton()\n {\n $this->setChild('add_button',\n $this->getLayout()->createBlock('adminhtml/widget_button')\n ->setData(array('id' => \"add_tax_\" . $this->getElement()->getHtmlId(),\n 'label' => Mage::helper('catalog')->__('Add Tax'),\n 'onclick' => \"weeeTaxControl.addItem('\" . $this->getElement()->getHtmlId() . \"')\",\n 'class' => 'add'\n )));\n }", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'Alita-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'Alita-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'Alita-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'Alita-extensions' ),\n 'return_value' => true,\n 'default' => false,\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'Alita-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'Alita-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'Alita-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'Alita-extensions' ),\n 'random' =>esc_html__( 'Random', 'Alita-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'Alita-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'Alita-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'section_content',\n [\n 'label' => __('Content', 'elementor-super-cat'),\n ]\n );\n\n\n $this->add_control(\n 'taxonomy',\n [\n 'label' => __('Name of taxonomy to filter', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT2,\n 'label_block' => true,\n 'options' => $this->get_taxonomies(),\n 'default' => isset($this->get_taxonomies()[0]) ? $this->get_taxonomies()[0] : []\n ]\n );\n\n $this->add_control(\n 'post_id',\n [\n 'label' => __('CSS ID of the post widget', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'order_by',\n [\n 'label' => __('Order By', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'name',\n 'options' => [\n 'name' => __('Name', 'elementor-super-cat'),\n 'slug' => __('Slug', 'elementor-super-cat'),\n ],\n ]\n );\n\n $this->add_control(\n 'all_text',\n [\n 'label' => __('Text to show for <b>Show All</b>', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => \"all\"\n ]\n );\n\n $this->add_control(\n 'hide_empty',\n [\n 'label' => __('Hide empty', 'elementor'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('If ON empty filters will be hidden.', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'invisible_filter',\n [\n 'label' => __('Remove Filter and display only currenct taxonomy', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('Removes the filter bar and only display related single related taxonomy', 'elementor'),\n ]\n );\n\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Style', 'elementor-super-cat'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'color_filter',\n [\n 'label' => __('Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'color_filter_active',\n [\n 'label' => __('Active Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter.elementor-active' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n 'typography',\n [\n 'name' => 'typography_filter',\n 'selector' => '{{WRAPPER}} .elementor-portfolio__filter',\n ]\n );\n\n $this->add_control(\n 'filter_item_spacing',\n [\n 'label' => __('Space Between', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter:not(:last-child)' => 'margin-right: calc({{SIZE}}{{UNIT}}/2)',\n '{{WRAPPER}} .elementor-portfolio__filter:not(:first-child)' => 'margin-left: calc({{SIZE}}{{UNIT}}/2)',\n ],\n ]\n );\n\n $this->add_control(\n 'filter_spacing',\n [\n 'label' => __('Spacing', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filters' => 'margin-bottom: {{SIZE}}{{UNIT}}',\n ],\n ]\n );\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n \t\t$this->start_controls_section(\n \t\t\t'eael_section_google_map_settings',\n \t\t\t[\n \t\t\t\t'label' => esc_html__( 'General Settings', 'essential-addons-elementor' )\n \t\t\t]\n \t\t);\n \t\t$this->add_control(\n\t\t 'eael_google_map_type',\n\t\t \t[\n\t\t \t\t'label' \t=> esc_html__( 'Google Map Type', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> 'basic',\n\t\t \t'label_block' \t=> false,\n\t\t \t'options' \t\t=> [\n\t\t \t\t'basic' \t=> esc_html__( 'Basic', 'essential-addons-elementor' ),\n\t\t \t\t'marker' \t=> esc_html__( 'Multiple Marker', 'essential-addons-elementor' ),\n\t\t \t\t'static' \t=> esc_html__( 'Static', 'essential-addons-elementor' ),\n\t\t \t\t'polyline' => esc_html__( 'Polyline', 'essential-addons-elementor' ),\n\t\t \t\t'polygon' \t=> esc_html__( 'Polygon', 'essential-addons-elementor' ),\n\t\t \t\t'overlay' \t=> esc_html__( 'Overlay', 'essential-addons-elementor' ),\n\t\t \t\t'routes' \t=> esc_html__( 'With Routes', 'essential-addons-elementor' ),\n\t\t \t\t'panorama' => esc_html__( 'Panorama', 'essential-addons-elementor' ),\n\t\t \t]\n\t\t \t]\n\t\t);\n\t\t$this->add_control(\n 'eael_google_map_address_type',\n [\n 'label' => __( 'Address Type', 'essential-addons-elementor' ),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n\t\t\t\t\t'address' => [\n\t\t\t\t\t\t'title' => __( 'Address', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-map',\n\t\t\t\t\t],\n\t\t\t\t\t'coordinates' => [\n\t\t\t\t\t\t'title' => __( 'Coordinates', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-map-marker',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => 'address',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['basic']\n\t\t\t\t]\n ]\n );\n $this->add_control(\n\t\t\t'eael_google_map_addr',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Geo Address', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Marina Bay, Singapore', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_address_type' => ['address'],\n\t\t\t\t\t'eael_google_map_type' => ['basic']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type!' => ['routes'],\n\t\t\t\t\t'eael_google_map_address_type' => ['coordinates']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type!' => ['routes'],\n\t\t\t\t\t'eael_google_map_address_type' => ['coordinates']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t// Only for static\n\t\t$this->add_control(\n\t\t\t'eael_google_map_static_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['static'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_static_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['static'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_resolution_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Map Image Resolution', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => 'static'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_static_width',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Static Image Width', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 610\n\t\t\t\t],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 1400,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => 'static'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_static_height',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Static Image Height', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 300\n\t\t\t\t],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 700,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => 'static'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t// Only for Overlay\n\t\t$this->add_control(\n\t\t\t'eael_google_map_overlay_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['overlay'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_overlay_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['overlay'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t// Only for panorama\n\t\t$this->add_control(\n\t\t\t'eael_google_map_panorama_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['panorama'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_panorama_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['panorama'],\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_overlay_content',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Overlay Content', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'label_block' => True,\n\t\t\t\t'default' => esc_html__( 'Add your content here', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => 'overlay'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n \t\t$this->end_controls_section();\n \t\t/**\n \t\t * Map Settings (With Marker only for Basic)\n \t\t */\n \t\t$this->start_controls_section(\n \t\t\t'eael_section_google_map_basic_marker_settings',\n \t\t\t[\n \t\t\t\t'label' => esc_html__( 'Map Marker Settings', 'essential-addons-elementor' ),\n \t\t\t\t'condition' => [\n \t\t\t\t\t'eael_google_map_type' => ['basic']\n \t\t\t\t]\n \t\t\t]\n \t\t);\n \t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_title',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Google Map Title', 'essential-addons-elementor' )\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_content',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Google map content', 'essential-addons-elementor' )\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_icon_enable',\n\t\t\t[\n\t\t\t\t'label' => __( 'Custom Marker Icon', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'default' => 'no',\n\t\t\t\t'label_on' => __( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t'label_off' => __( 'No', 'essential-addons-elementor' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t]\n\t\t);\n \t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_icon',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Marker Icon', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t// 'url' => Utils::get_placeholder_image_src(),\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_basic_marker_icon_enable' => 'yes'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_icon_width',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Marker Width', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 32\n\t\t\t\t],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 150,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_basic_marker_icon_enable' => 'yes'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_basic_marker_icon_height',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Marker Height', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 32\n\t\t\t\t],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'max' => 150,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_basic_marker_icon_enable' => 'yes'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n \t\t/**\n \t\t * Map Settings (With Marker)\n \t\t */\n \t\t$this->start_controls_section(\n \t\t\t'eael_section_google_map_marker_settings',\n \t\t\t[\n \t\t\t\t'label' => esc_html__( 'Map Marker Settings', 'essential-addons-elementor' ),\n \t\t\t\t'condition' => [\n \t\t\t\t\t'eael_google_map_type' => ['marker', 'polyline', 'routes', 'static']\n \t\t\t\t]\n \t\t\t]\n \t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_markers',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'eael_google_map_marker_title' => esc_html__( 'Map Marker 1', 'essential-addons-elementor' ) ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_lat',\n\t\t\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_lng',\n\t\t\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( 'Marker Title', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_content',\n\t\t\t\t\t\t'label' => esc_html__( 'Content', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( 'Marker Content. You can put html here.', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_icon_color',\n\t\t\t\t\t\t'label' => esc_html__( 'Default Icon Color', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'description' => esc_html__( '(Works only on Static mode)', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t\t\t'default' => '#e23a47',\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_icon_enable',\n\t\t\t\t\t\t'label' => __( 'Use Custom Icon', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'default' => 'no',\n\t\t\t\t\t\t'label_on' => __( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'label_off' => __( 'No', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'return_value' => 'yes',\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_icon',\n\t\t\t\t\t\t'label' => esc_html__( 'Custom Icon', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t// 'url' => Utils::get_placeholder_image_src(),\n\t\t\t\t\t\t],\n\t\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t\t'eael_google_map_marker_icon_enable' => 'yes'\n\t\t\t\t\t\t]\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_icon_width',\n\t\t\t\t\t\t'label' => esc_html__( 'Icon Width', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t\t\t'default' => esc_html__( '32', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t\t'eael_google_map_marker_icon_enable' => 'yes'\n\t\t\t\t\t\t]\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_marker_icon_height',\n\t\t\t\t\t\t'label' => esc_html__( 'Icon Height', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t\t\t'default' => esc_html__( '32', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t\t'eael_google_map_marker_icon_enable' => 'yes'\n\t\t\t\t\t\t]\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{eael_google_map_marker_title}}',\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\n\n \t\t/**\n \t\t * Polyline Coordinates Settings (Polyline)\n \t\t */\n \t\t$this->start_controls_section(\n \t\t\t'eael_section_google_map_polyline_settings',\n \t\t\t[\n \t\t\t\t'label' => esc_html__( 'Coordinate Settings', 'essential-addons-elementor' ),\n \t\t\t\t'condition' => [\n \t\t\t\t\t'eael_google_map_type' => ['polyline', 'polygon']\n \t\t\t\t]\n \t\t\t]\n \t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_polylines',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'eael_google_map_polyline_title' => esc_html__( '#1', 'essential-addons-elementor' ) ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_polyline_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '#', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_polyline_lat',\n\t\t\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'eael_google_map_polyline_lng',\n\t\t\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{eael_google_map_polyline_title}}',\n\t\t\t]\n\t\t);\n \t\t$this->end_controls_section();\n\n \t\t/**\n \t\t * Routes Coordinates Settings (Routes)\n \t\t */\n \t\t$this->start_controls_section(\n \t\t\t'eael_section_google_map_routes_settings',\n \t\t\t[\n \t\t\t\t'label' => esc_html__( 'Routes Coordinate Settings', 'essential-addons-elementor' ),\n \t\t\t\t'condition' => [\n \t\t\t\t\t'eael_google_map_type' => ['routes']\n \t\t\t\t]\n \t\t\t]\n \t\t);\n \t\t$this->add_control(\n\t\t\t'eael_google_map_routes_origin',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Origin', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'after',\n\t\t\t]\n\t\t);\n \t\t$this->add_control(\n\t\t\t'eael_google_map_routes_origin_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2925005', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_routes_origin_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8665551', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_routes_dest',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Destination', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'after',\n\t\t\t]\n\t\t);\n \t\t$this->add_control(\n\t\t\t'eael_google_map_routes_dest_lat',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Latitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '1.2833808', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_routes_dest_lng',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Longitude', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '103.8585377', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t \t'eael_google_map_routes_travel_mode',\n\t\t \t[\n\t\t \t\t'label' \t=> esc_html__( 'Travel Mode', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> 'walking',\n\t\t \t'label_block' \t=> false,\n\t\t \t'options' \t\t=> [\n\t\t \t\t'walking' \t=> esc_html__( 'Walking', 'essential-addons-elementor' ),\n\t\t \t\t'bicycling' => esc_html__( 'Bicycling', 'essential-addons-elementor' ),\n\t\t \t\t'driving' \t=> esc_html__( 'Driving', 'essential-addons-elementor' ),\n\t\t \t]\n\t\t \t]\n\t\t);\n \t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_map_controls',\n\t\t\t[\n\t\t\t\t'label'\t=> esc_html__( 'Map Controls', 'essential-addons-elementor' )\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_zoom',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Zoom Level', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::NUMBER,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => esc_html__( '14', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_map_streeview_control',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Street View Controls', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n 'default' => 'true',\n 'label_on' => __( 'On', 'essential-addons-elementor' ),\n 'label_off' => __( 'Off', 'essential-addons-elementor' ),\n 'return_value' => 'true',\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_map_type_control',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Map Type Control', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __( 'On', 'essential-addons-elementor' ),\n 'label_off' => __( 'Off', 'essential-addons-elementor' ),\n 'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_map_zoom_control',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Zoom Control', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __( 'On', 'essential-addons-elementor' ),\n 'label_off' => __( 'Off', 'essential-addons-elementor' ),\n 'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_map_fullscreen_control',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Fullscreen Control', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __( 'On', 'essential-addons-elementor' ),\n 'label_off' => __( 'Off', 'essential-addons-elementor' ),\n 'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_map_scroll_zoom',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Scroll Wheel Zoom', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n 'label_on' => __( 'On', 'essential-addons-elementor' ),\n 'label_off' => __( 'Off', 'essential-addons-elementor' ),\n 'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\t\t \n\t\t/**\n \t\t * Map Theme Settings\n \t\t */\n \t\t$this->start_controls_section(\n\t\t\t'eael_section_google_map_theme_settings',\n\t\t\t[\n\t\t\t\t'label'\t\t=> esc_html__( 'Map Theme', 'essential-addons-elementor' ),\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type!'\t=> ['static', 'panorama']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n 'eael_google_map_theme_source',\n [\n 'label'\t\t=> __( 'Theme Source', 'essential-addons-elementor' ),\n\t\t\t\t'type'\t\t=> Controls_Manager::CHOOSE,\n 'options' => [\n\t\t\t\t\t'gstandard' => [\n\t\t\t\t\t\t'title' => __( 'Google Standard', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-map',\n\t\t\t\t\t],\n\t\t\t\t\t'snazzymaps' => [\n\t\t\t\t\t\t'title' => __( 'Snazzy Maps', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-map-marker',\n\t\t\t\t\t],\n\t\t\t\t\t'custom' => [\n\t\t\t\t\t\t'title' => __( 'Custom', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-edit',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default'\t=> 'gstandard'\n ]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_gstandards',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Google Themes', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'standard',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'essential-addons-elementor' ),\n\t\t\t\t\t'silver' => __( 'Silver', 'essential-addons-elementor' ),\n\t\t\t\t\t'retro' => __( 'Retro', 'essential-addons-elementor' ),\n\t\t\t\t\t'dark' => __( 'Dark', 'essential-addons-elementor' ),\n\t\t\t\t\t'night' => __( 'Night', 'essential-addons-elementor' ),\n\t\t\t\t\t'aubergine' => __( 'Aubergine', 'essential-addons-elementor' )\n\t\t\t\t],\n\t\t\t\t'description' => sprintf( '<a href=\"https://mapstyle.withgoogle.com/\" target=\"_blank\">%1$s</a> %2$s',__( 'Click here', 'essential-addons-elementor' ), __( 'to generate your own theme and use JSON within Custom style field.', 'essential-addons-elementor' ) ),\n\t\t\t\t'condition'\t=> [\n\t\t\t\t\t'eael_google_map_theme_source'\t=> 'gstandard'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_snazzymaps',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'SnazzyMaps Themes', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'label_block'\t\t\t=> true,\n\t\t\t\t'default' => 'colorful',\n\t\t\t\t'options' => [\n\t\t\t\t\t'default'\t\t=> __( 'Default', 'essential-addons-elementor' ),\n\t\t\t\t\t'simple'\t\t=> __( 'Simple', 'essential-addons-elementor' ),\n\t\t\t\t\t'colorful'\t\t=> __( 'Colorful', 'essential-addons-elementor' ),\n\t\t\t\t\t'complex'\t\t=> __( 'Complex', 'essential-addons-elementor' ),\n\t\t\t\t\t'dark'\t\t\t=> __( 'Dark', 'essential-addons-elementor' ),\n\t\t\t\t\t'greyscale'\t\t=> __( 'Greyscale', 'essential-addons-elementor' ),\n\t\t\t\t\t'light'\t\t\t=> __( 'Light', 'essential-addons-elementor' ),\n\t\t\t\t\t'monochrome'\t=> __( 'Monochrome', 'essential-addons-elementor' ),\n\t\t\t\t\t'nolabels'\t\t=> __( 'No Labels', 'essential-addons-elementor' ),\n\t\t\t\t\t'twotone'\t\t=> __( 'Two Tone', 'essential-addons-elementor' )\n\t\t\t\t],\n\t\t\t\t'description' => sprintf( '<a href=\"https://snazzymaps.com/explore\" target=\"_blank\">%1$s</a> %2$s',__( 'Click here', 'essential-addons-elementor' ), __( 'to explore more themes and use JSON within custom style field.', 'essential-addons-elementor' ) ),\n\t\t\t\t'condition'\t=> [\n\t\t\t\t\t'eael_google_map_theme_source'\t=> 'snazzymaps'\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_custom_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Custom Style', 'essential-addons-elementor' ),\n\t\t\t\t'description' => sprintf( '<a href=\"https://mapstyle.withgoogle.com/\" target=\"_blank\">%1$s</a> %2$s',__( 'Click here', 'essential-addons-elementor' ), __( 'to get JSON style code to style your map', 'essential-addons-elementor' ) ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n 'condition' => [\n 'eael_google_map_theme_source' => 'custom',\n ],\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section(); \n \t\t/**\n\t\t * -------------------------------------------\n\t\t * Tab Style Google Map Style\n\t\t * -------------------------------------------\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'eael_section_google_map_style_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'General Style', 'essential-addons-elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_max_width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Max Width', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 1140,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1400,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-google-map' => 'max-width: {{SIZE}}{{UNIT}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_max_height',\n\t\t\t[\n\t\t\t\t'label' => __( 'Max Height', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 400,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1400,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-google-map' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_margin',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Margin', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%' ],\n\t\t\t\t'selectors' => [\n\t \t\t\t\t\t'{{WRAPPER}} .eael-google-map' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t \t\t\t],\n\t\t\t]\n\t\t);\n\n \t\t$this->end_controls_section();\n\n \t\t/**\n\t\t * -------------------------------------------\n\t\t * Tab Style Google Map Style\n\t\t * -------------------------------------------\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'eael_section_google_map_overlay_style_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Overlay Style', 'essential-addons-elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['overlay']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_overlay_width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Width', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 200,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1100,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_overlay_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'background-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_mapoverlay_padding',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Padding', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%' ],\n\t\t\t\t'selectors' => [\n\t \t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t \t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_overlay_margin',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Margin', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%' ],\n\t\t\t\t'selectors' => [\n\t \t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t \t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_google_map_overlay_border',\n\t\t\t\t'label' => esc_html__( 'Border', 'essential-addons-elementor' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-gmap-overlay',\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_overlay_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border Radius', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', 'em', '%' ],\n\t\t\t\t'selectors' => [\n\t \t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t \t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_google_map_overlay_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-gmap-overlay',\n\t\t\t]\n\t\t);\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n \t'name' => 'eael_google_map_overlay_typography',\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-gmap-overlay',\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_overlay_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#222',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-gmap-overlay' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * -------------------------------------------\n\t\t * Tab Style Google Map Stroke Style\n\t\t * -------------------------------------------\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'eael_section_google_map_stroke_style_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Stroke Style', 'essential-addons-elementor' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['polyline', 'polygon', 'routes']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_stroke_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#e23a47',\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_stroke_opacity',\n\t\t\t[\n\t\t\t\t'label' => __( 'Opacity', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 0.8,\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0.2,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_stroke_weight',\n\t\t\t[\n\t\t\t\t'label' => __( 'Weight', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 4,\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 10,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'eael_google_map_stroke_fill_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Fill Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#e23a47',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['polygon']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'eael_google_map_stroke_fill_opacity',\n\t\t\t[\n\t\t\t\t'label' => __( 'Fill Opacity', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'size' => 0.4,\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0.2,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'condition' => [\n\t\t\t\t\t'eael_google_map_type' => ['polygon']\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-gastenboek' ),\n\t\t\t)\n\t\t);\n\n $this->end_controls_section();\n\t}", "public function AddControl($Name, array $Struct) {\n\n $this->Controls[$Name]= $Struct;\n $this->Builded= false;\n }", "public function addControl($c) {\n $this->addColumn($c);\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Clients Settings', 'elementor-main-clients' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t 'clients-columns',\n\t\t \t[\n\t\t \t'label' \t=> esc_html__( 'Column', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> '2',\n\t\t \t'options' \t\t=> [\t\t\t\t\n\t\t\t\t\t'1' => esc_html__('1 Column', 'baldiyaat'),\n\t\t\t\t\t'2' => esc_html__('2 Column', 'baldiyaat'),\n\t\t\t\t\t'3' => esc_html__('3 Column', 'baldiyaat'),\n\t\t\t\t\t'4' => esc_html__('4 Column', 'baldiyaat'),\n\t\t\t\t\t'6' => esc_html__('6 Column', 'baldiyaat')\n\t\t \t],\n\t\t \t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'thumbnail-size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Thumbnail Size', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'label_block' \t=> false,\n\t\t\t\t'default' => esc_html__( 'hide', 'essential-addons-elementor' ),\n\t\t \t'options' => wpha_get_thumbnail_list(),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'num-fetch',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Num Fetch', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => 10,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_config_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Clients Images', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'slider',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide',\n\t\t\t\t\t\t'label' => esc_html__( 'Image', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'url' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png',\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_caption',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Caption', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_enable_slide_link',\n\t\t\t\t\t\t'label' => __( 'Enable Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'default' => 'false',\n\t\t\t\t\t\t'label_on' => esc_html__( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'label_off' => esc_html__( 'No', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'return_value' => 'true',\n\t\t\t\t\t\t\n\t\t\t\t \t],\n\t\t\t\t \t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_link',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => [\n\t\t \t\t\t'url' => '#',\n\t\t \t\t\t'is_external' => '',\n\t\t \t\t\t],\n\t\t \t\t\t'show_external' => true,\n\t\t \t\t\t'condition' => [\n\t\t \t\t\t\t'main_clients_settings_enable_slide_link' => 'true'\n\t\t \t\t\t]\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{main_clients_settings_slide_title}}',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_color_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color & Design', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Sub Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .kode-sub-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_caption_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Caption Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-des' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button BG Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'background-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t\n\t}", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Number' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Counter Title\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Title' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Box', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_background',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background-Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#f7f7f7',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'background: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Border\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_border',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#eee',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'border: 8px solid {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Number Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h3' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_number_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h3',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h6' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h6',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "protected function _register_controls()\n {\n\n /**\n * Style tab\n */\n\n $this->start_controls_section(\n 'general',\n [\n 'label' => __('Content', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n\t\t\t'menu_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Style', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'inline',\n\t\t\t\t'options' => [\n\t\t\t\t\t'inline' => __( 'Inline', 'akash-hp' ),\n\t\t\t\t\t'flyout' => __( 'Flyout', 'akash-hp' ),\n\t\t\t\t],\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_label',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Label', 'akash-hp' ),\n 'type' => Controls_Manager::TEXT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_open_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'fa fa-align-justify',\n\t\t\t\t\t'library' => 'solid',\n ],\n \n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_close_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Close Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'far fa-window-close',\n\t\t\t\t\t'library' => 'solid',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'menu_align',\n [\n 'label' => __('Align', 'akash-hp'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'start' => [\n 'title' => __('Left', 'akash-hp'),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __('top', 'akash-hp'),\n 'icon' => 'fa fa-align-center',\n ],\n 'flex-end' => [\n 'title' => __('Right', 'akash-hp'),\n 'icon' => 'fa fa-align-right',\n ],\n ],\n 'default' => 'left',\n\t\t\t\t'toggle' => true,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .akash-main-menu-wrap.navbar' => 'justify-content: {{VALUE}}'\n\t\t\t\t\t] \n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n\t\t\t'header_infos_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Header Info', 'akash-hp' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'show_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'akash-hp' ),\n\t\t\t\t'label_off' => __( 'Hide', 'akash-hp' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'no',\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'info_title', [\n\t\t\t\t'label' => __( 'Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'info Title' , 'akash-hp' ),\n\t\t\t\t'label_block' => true,\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'info_content', [\n\t\t\t\t'label' => __( 'Content', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t'default' => __( 'info Content' , 'akash-hp' ),\n\t\t\t\t'show_label' => false,\n\t\t\t]\n );\n \n $repeater->add_control(\n\t\t\t'info_url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'akash-hp' ),\n\t\t\t\t'show_external' => true,\n\t\t\t]\n );\n \n\t\t$this->add_control(\n\t\t\t'header_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Repeater info', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'info_title' => __( 'Call us:', 'akash-hp' ),\n\t\t\t\t\t\t'info_content' => __( '(234) 567 8901', 'akash-hp' ),\n\t\t\t\t\t],\n\t\t\t\t],\n 'title_field' => '{{{ info_title }}}',\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_menu_style',\n [\n 'label' => __('Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'menu_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'menu_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n \n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n \n $this->add_responsive_control(\n 'item_gap',\n [\n 'label' => __('Menu Gap', 'akash-hp'),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'devices' => ['desktop', 'tablet', 'mobile'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-left: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-right: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_readius',\n [\n 'label' => __('Item Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li:hover>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'dropdown_style',\n [\n 'label' => __('Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'dripdown_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n \n $this->add_control(\n 'dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'ddown_menu_border_color',\n [\n 'label' => __('Menu Border Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_radius',\n [\n 'label' => __('Menu radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_flyout_style',\n [\n 'label' => __('Flyout/Mobile Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_menu_typography',\n 'label' => __('Item Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'flyout_menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n $this->add_responsive_control(\n 'flyout_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_menu_padding',\n [\n 'label' => __('Menu Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n \n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n\n\t\t$this->end_controls_tab();\n\n $this->end_controls_tabs();\n \n $this->end_controls_section();\n\n $this->start_controls_section(\n 'flyout_dropdown_style',\n [\n 'label' => __('Flyout/Mobile Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_dripdown_typography',\n 'label' => __('Dropdown Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n\n $this->start_controls_section(\n 'trigger_style',\n [\n 'label' => __('Trigger Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n $this->start_controls_tabs(\n 'trigger_style_tabs'\n );\n \n $this->start_controls_tab(\n 'trigger_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'trigger_typography',\n 'label' => __('Trigger Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n 'trigger_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'trigger_icon_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'trigger_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_padding',\n [\n 'label' => __('Button Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'trigger_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n\n $this->add_control(\n 'trigger_hover_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_hover_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_hover_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu:hover',\n ]\n );\n\n $this->add_control(\n 'trigger_hover_animation',\n [\n 'label' => __('Hover Animation', 'akash-hp'),\n 'type' => Controls_Manager::HOVER_ANIMATION,\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_hover_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n \n $this->start_controls_section(\n 'infos_style_section',\n [\n 'label' => __('Info Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n ]\n );\n\n $this->start_controls_tabs(\n 'info_style_tabs'\n );\n \n $this->start_controls_tab(\n 'info_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_title_typography',\n 'label' => __('Title Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info span',\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_typography',\n 'label' => __('Info Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info h3 ',\n ]\n );\n\n $this->add_control(\n 'info_title_color',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'info_box_border',\n 'label' => __('Box Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .akash-header-infos',\n ]\n );\n\n $this->add_control(\n\t\t\t'info_title_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Info Title Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .header-info span' => 'margin-bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'ifno_item_padding',\n [\n 'label' => __('Info item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'info_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n $this->add_control(\n 'info_title_color_hover',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color_hover',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n \n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n $this->start_controls_section(\n 'panel_style',\n [\n 'label' => __('Panel Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'panel_label_typography',\n 'label' => __('Label Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler',\n ]\n );\n\n \n $this->add_control(\n 'panel_label_color',\n [\n 'label' => __('Label Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_color',\n [\n 'label' => __('Close Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler i' => 'color: {{VALUE}}',\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'stroke: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_fill_color',\n [\n 'label' => __('Close Trigger Fill Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'fill: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_label_background',\n [\n 'label' => __('Label Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.close-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n \n $this->add_control(\n 'panel_background',\n [\n 'label' => __('Panel Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_cloxe_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Close Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'panel_shadow',\n 'label' => __('Panel Shadow', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-inner',\n ]\n );\n\n $this->add_responsive_control(\n 'close_label_padding',\n [\n 'label' => __('Label Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n \n $this->add_responsive_control(\n 'panel_padding',\n [\n 'label' => __('Panel Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n\n $this->end_controls_section();\n }", "private function insertControl($control, $lpcid) {\r\n $control['landingpage_collectionid'] = $lpcid;\r\n $control['name'] = $lpcid . '_control';\r\n $control['pagetype'] = 1;\r\n\r\n $this->db->insert('landing_page', $control);\r\n $lpd = $this->db->insert_id();\r\n\r\n if (!is_int($lpd) || $lpd <= 0) {\r\n $this->project = $lpcid;\r\n self::deleteProject();\r\n throw new Exception('The control variant could not be created', 500);\r\n }\r\n $this->syncCollectionGoals();\r\n return $this->successResponse(200, $lpcid);\r\n }", "protected function _register_controls()\n {\n \n // start_controls_section -----\n $this->start_controls_section(\n 'general_settings_section',\n [\n 'label' => __('General Settings', 'elementor-hello-world'),\n ]\n );\n $this->add_control(\n 'title',\n [\n 'label' => __('Title', 'elementor-hello-world'),\n 'type' => Controls_Manager::TEXTAREA,\n 'default' => ''\n ]\n );\n $this->add_control(\n 'description',\n [\n 'label' => 'Description',\n 'type' => Controls_Manager::WYSIWYG,\n 'default' => ''\n ]\n );\n \n $this->add_control(\n 'extra_classes',\n [\n 'label' => __('Extra Classes', 'elementor-hello-world'),\n 'type' => Controls_Manager::TEXT,\n 'default' => ''\n ]\n );\n $this->end_controls_section();\n \n $oRepeater = new \\Elementor\\Repeater();\n $this->start_controls_section(\n 'tab_name',\n [\n 'label' => __('Tab Name', 'elementor-hello-world'),\n ]\n );\n $oRepeater->add_control(\n 'tab_name',\n [\n 'label' => __('Tab Name', 'hslanding-elementor'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'label_block' => true,\n ]\n );\n \n $oRepeater->add_control(\n 'tab_description',\n [\n 'label' => __('Tab Description', 'hslanding-elementor'),\n 'type' => \\Elementor\\Controls_Manager::WYSIWYG,\n 'label_block' => true,\n ]\n );\n \n $oRepeater->add_control(\n 'right_image',\n [\n 'label' => __('Right Image', 'hslanding-elementor'),\n 'type' => \\Elementor\\Controls_Manager::MEDIA,\n 'label_block' => true,\n ]\n );\n $oRepeater->add_control(\n 'right_content',\n [\n 'label' => __('Right Content', 'hslanding-elementor'),\n 'type' => \\Elementor\\Controls_Manager::WYSIWYG,\n 'label_block' => true,\n ]\n );\n $this->add_control(\n 'tabs',\n [\n 'label' => __('Tab Settings', 'plugin-domain'),\n 'type' => \\Elementor\\Controls_Manager::REPEATER,\n 'fields' => $oRepeater->get_controls()\n ]\n );\n \n // end_controls_section -----\n $this->end_controls_section();\n }", "function customize_controls_init()\n {\n }", "public function build_controls()\n {\n $this->add_control( 'id', [\n 'label' => __( 'Post', 'customize-static-layout' ),\n 'type' => 'object_selector',\n 'post_query_vars' => static::get_post_query_vars(),\n 'select2_options' => [\n 'allowClear' => true,\n 'placeholder' => __( '&mdash; Select &mdash;', 'customize-static-layout' ),\n ],\n ], 'CustomizeObjectSelector\\Control' );\n }", "protected function _register_controls() { \n /*Testimonials Content Section */\n $this->start_controls_section('premium_testimonial_person_settings',\n [\n 'label' => __('Author', 'premium-addons-for-elementor'),\n ]\n );\n \n /*Person Image*/\n $this->add_control('premium_testimonial_person_image',\n [\n 'label' => __('Image','premium-addons-for-elementor'),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [ 'active' => true ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src()\n ],\n 'description' => __( 'Choose an image for the author', 'premium-addons-for-elementor' ),\n 'show_label' => true,\n ]\n ); \n\n /*Person Image Shape*/\n $this->add_control('premium_testimonial_person_image_shape',\n [\n 'label' => __('Image Style', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Choose image style', 'premium-addons-for-elementor' ),\n 'options' => [\n 'square' => __('Square','premium-addons-for-elementor'),\n 'circle' => __('Circle','premium-addons-for-elementor'),\n 'rounded' => __('Rounded','premium-addons-for-elementor'),\n ],\n 'default' => 'circle',\n ]\n );\n \n /*Person Name*/ \n $this->add_control('premium_testimonial_person_name',\n [\n 'label' => __('Name', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Person Name', 'premium-addons-for-elementor'),\n 'description' => __( 'Enter author name', 'premium-addons-for-elementor' ),\n 'label_block' => true\n ]\n );\n \n /*Name Title Tag*/\n $this->add_control('premium_testimonial_person_name_size',\n [\n 'label' => __('HTML Tag', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select a heading tag for author name', 'premium-addons-for-elementor' ),\n 'options' => [\n 'h1' => 'H1',\n 'h2' => 'H2',\n 'h3' => 'H3',\n 'h4' => 'H4',\n 'h5' => 'H5',\n 'h6' => 'H6',\n ],\n 'default' => 'h3',\n 'label_block' => true,\n ]\n );\n \n /*End Person Content Section*/\n $this->end_controls_section();\n\n /*Start Company Content Section*/ \n $this->start_controls_section('premium_testimonial_company_settings',\n [\n 'label' => __('Company', 'premium-addons-for-elementor')\n ]\n );\n \n /*Company Name*/\n $this->add_control('premium_testimonial_company_name',\n [\n 'label' => __('Name', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Company Name','premium-addons-for-elementor'),\n 'description' => __( 'Enter company name', 'premium-addons-for-elementor' ),\n 'label_block' => true,\n ]\n );\n \n /*Company Name Tag*/\n $this->add_control('premium_testimonial_company_name_size',\n [\n 'label' => __('HTML Tag', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select a heading tag for company name', 'premium-addons-for-elementor' ),\n 'options' => [\n 'h1' => 'H1',\n 'h2' => 'H2',\n 'h3' => 'H3',\n 'h4' => 'H4',\n 'h5' => 'H5',\n 'h6' => 'H6', \n ],\n 'default' => 'h4',\n 'label_block' => true,\n ]\n );\n \n $this->add_control('premium_testimonial_company_link_switcher',\n [\n 'label' => __('Link', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n ]\n );\n \n /*Company Link */\n $this->add_control('premium_testimonial_company_link',\n [\n 'label' => __('Link', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [\n 'active' => true,\n 'categories' => [\n TagsModule::POST_META_CATEGORY,\n TagsModule::URL_CATEGORY\n ]\n ],\n 'description' => __( 'Add company URL', 'premium-addons-for-elementor' ),\n 'label_block' => true,\n 'condition' => [\n 'premium_testimonial_company_link_switcher' => 'yes'\n ]\n ]\n );\n \n /*Link Target*/ \n $this->add_control('premium_testimonial_link_target',\n [\n 'label' => __('Link Target', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select link target', 'premium-addons-for-elementor' ),\n 'options' => [\n 'blank' => __('Blank'),\n 'parent' => __('Parent'),\n 'self' => __('Self'),\n 'top' => __('Top'),\n ],\n 'default' => __('blank','premium-addons-for-elementor'),\n 'condition' => [\n 'premium_testimonial_company_link_switcher' => 'yes'\n ]\n ]\n );\n \n /*End Company Content Section*/\n $this->end_controls_section();\n\n /*Start Testimonial Content Section*/\n $this->start_controls_section('premium_testimonial_settings',\n [\n 'label' => __('Content', 'premium-addons-for-elementor'),\n ]\n );\n\n /*Testimonial Content*/\n $this->add_control('premium_testimonial_content',\n [ \n 'label' => __('Testimonial Content', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Donec id elit non mi porta gravida at eget metus. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Cras mattis consectetur purus sit amet fermentum. Nullam id dolor id nibh ultricies vehicula ut id elit. Donec id elit non mi porta gravida at eget metus.','premium-addons-for-elementor'),\n 'label_block' => true,\n ]\n );\n \n /*End Testimonial Content Section*/\n $this->end_controls_section();\n \n /*Image Styling*/\n $this->start_controls_section('premium_testimonial_image_style',\n [\n 'label' => __('Image', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n \n /*Image Size*/\n $this->add_control('premium_testimonial_img_size',\n [\n 'label' => __('Size', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', 'em'],\n 'default' => [\n 'unit' => 'px',\n 'size' => 110,\n ],\n 'range' => [\n 'px'=> [\n 'min' => 10,\n 'max' => 150,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-img-wrapper'=> 'width: {{SIZE}}{{UNIT}}; height:{{SIZE}}{{UNIT}};',\n ]\n ]\n );\n\n /*Image Border Width*/\n $this->add_control('premium_testimonial_img_border_width',\n [\n 'label' => __('Border Width (PX)', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'unit' => 'px',\n 'size' => 2,\n ],\n 'range' => [\n 'px'=> [\n 'min' => 0,\n 'max' => 15,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-person-image' => 'border-width: {{SIZE}}{{UNIT}};',\n ]\n ]\n );\n \n /*Image Border Color*/\n $this->add_control('premium_testimonial_image_border_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-img-wrapper' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n $this->end_controls_section();\n \n /*Start Person Settings Section*/\n $this->start_controls_section('premium_testimonials_person_style', \n [\n 'label' => __('Author', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n \n /*Person Name Color*/\n $this->add_control('premium_testimonial_person_name_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-person-name' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Authohr Name Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'author_name_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-person-name',\n ]\n );\n \n /*Separator Color*/\n $this->add_control('premium_testimonial_separator_color',\n [\n 'label' => __('Divider Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-separator' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n $this->end_controls_section();\n \n /*Start Company Settings Section*/\n $this->start_controls_section('premium_testimonial_company_style',\n [\n 'label' => __('Company', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n\n /*Company Name Color*/\n $this->add_control('premium_testimonial_company_name_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_2,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-company-link' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Company Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'company_name_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-company-link',\n ]\n ); \n\n /*End Color Section*/\n $this->end_controls_section();\n \n /*Start Content Settings Section*/\n $this->start_controls_section('premium_testimonial_content_style',\n [\n 'label' => __('Content', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n\n /*Content Color*/\n $this->add_control('premium_testimonial_content_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-text-wrapper' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Content Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'content_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-text-wrapper',\n ]\n ); \n \n \n /*Testimonial Text Margin*/\n $this->add_responsive_control('premium_testimonial_margin',\n [\n 'label' => __('Margin', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'top' => 15,\n 'bottom'=> 15,\n 'left' => 0 ,\n 'right' => 0 ,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-text-wrapper' => 'margin: {{top}}{{UNIT}} {{right}}{{UNIT}} {{bottom}}{{UNIT}} {{left}}{{UNIT}};',\n ]\n ]\n );\n\n /*End Content Settings Section*/\n $this->end_controls_section();\n \n /*Start Quotes Style Section*/\n $this->start_controls_section('premium_testimonial_quotes',\n [\n 'label' => __('Quotation Icon', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n \n /*Quotes Color*/ \n $this->add_control('premium_testimonial_quote_icon_color',\n [\n 'label' => __('Color','premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'default' => 'rgba(110,193,228,0.2)',\n 'selectors' => [\n '{{WRAPPER}} .fa' => 'color: {{VALUE}};',\n ]\n ]\n );\n\n /*Quotes Size*/\n $this->add_control('premium_testimonial_quotes_size',\n [\n 'label' => __('Size', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', '%', 'em'],\n 'default' => [\n 'unit' => 'px',\n 'size' => 120,\n ],\n 'range' => [\n 'px' => [\n 'min' => 5,\n 'max' => 250,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-upper-quote, {{WRAPPER}} .premium-testimonial-lower-quote' => 'font-size: {{SIZE}}{{UNIT}};',\n ]\n ]\n );\n \n /*Upper Quote Position*/\n $this->add_responsive_control('premium_testimonial_upper_quote_position',\n [\n 'label' => __('Top Icon Position', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'top' => 70,\n 'left' => 12 ,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-upper-quote' => 'top: {{TOP}}{{UNIT}}; left:{{LEFT}}{{UNIT}};',\n ]\n ]\n );\n \n /*Lower Quote Position*/\n $this->add_responsive_control('premium_testimonial_lower_quote_position',\n [\n 'label' => __('Bottom Icon Position', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'bottom' => 3,\n 'right' => 12,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-lower-quote' => 'right: {{RIGHT}}{{UNIT}}; bottom: {{BOTTOM}}{{UNIT}};',\n ]\n ]\n );\n\n /*End Typography Section*/\n $this->end_controls_section();\n \n $this->start_controls_section('premium_testimonial_container_style',\n [\n 'label' => __('Container','premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n \n $this->add_group_control(\n Group_Control_Background::get_type(),\n [\n 'name' => 'premium_testimonial_background',\n 'types' => [ 'classic' , 'gradient' ],\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper'\n ]\n );\n \n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'premium_testimonial_container_border',\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper',\n ]\n );\n\n $this->add_control('premium_testimonial_container_border_radius',\n [\n 'label' => __('Border Radius', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', '%', 'em'],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-content-wrapper' => 'border-radius: {{SIZE}}{{UNIT}}'\n ]\n ]\n );\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'premium_testimonial_container_box_shadow',\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper',\n ]\n );\n \n $this->add_responsive_control('premium_testimonial_box_padding',\n [\n 'label' => __('Padding', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-content-wrapper' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}}',\n ]\n ]\n );\n\n $this->end_controls_section();\n \n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\tarray(\n\t\t\t\t'label' => 'Slider Revolution 6',\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'revslidertitle',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Selected Module:', 'revslider' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'render_type' => 'none',\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'shortcode',\n\t\t\tarray(\n\t\t\t\t//'type' => \\Elementor\\Controls_Manager::HIDDEN,\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label' => __( 'Shortcode', 'revslider' ),\n\t\t\t\t'dynamic' => ['active' => true],\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t// Advanced \t\t\n\t\t$this->add_control(\n\t\t\t'select_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">cached</i> Select Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'edit_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">edit</i> Edit Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.editslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'settings_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">tune</i> Block Settings', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.settingsslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'optimize_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">flash_on</i> Optimize File Sizes', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.optimizeslider',\n\t\t\t)\n\t\t);\n\t\t$this->end_controls_section();\t\n\t}", "protected function _register_controls()\n\t{\n\t\t$this->start_controls_section(\n\t\t\t'section_custom_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice', 'elementor'),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice', 'webt'),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'placeholder' => esc_html('A custom notice to any page on your site'),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'custom_type_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice Type', 'webt'),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'solid',\n\t\t\t\t'options' => [\n\t\t\t\t\t'success' => __('Success', 'webt'),\n\t\t\t\t\t'error' => __('Error', 'webt'),\n\t\t\t\t\t'notice' => __('Notice', 'webt'),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'wc_custom_notice_warning',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::RAW_HTML,\n\t\t\t\t'raw' => esc_html__('Add a custom notice to any page on your site', 'webt'),\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\t}", "public function afterLoadRegisterControlsUI(){\n\t\t\n\t}", "protected function _register_controls() {\r\n\r\n\t\t$this->start_controls_section(\r\n\t\t\t'settings_section',\r\n\t\t\t[\r\n\t\t\t\t'label' => esc_html__( 'General Settings', 'aapside-master' ),\r\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'title', [\r\n\t\t\t'label' => esc_html__( 'Title', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( 'Primary Plan', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter title', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'featured', [\r\n\t\t\t'label' => esc_html__( 'Featured', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::SWITCHER,\r\n\t\t\t'default' => 'no',\r\n\t\t\t'description' => esc_html__( 'enable featured', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'price', [\r\n\t\t\t'label' => esc_html__( 'Price', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '250', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter price', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'sign', [\r\n\t\t\t'label' => esc_html__( 'Sign', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '$', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter sign', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'month', [\r\n\t\t\t'label' => esc_html__( 'Month', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( '/Mo', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter month', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'btn_text', [\r\n\t\t\t'label' => esc_html__( 'Button Text', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t'default' => esc_html__( 'Get Started', 'aapside-master' ),\r\n\t\t\t'description' => esc_html__( 'enter button text', 'aapside-master' )\r\n\t\t] );\r\n\t\t$this->add_control( 'btn_link', [\r\n\t\t\t'label' => esc_html__( 'Button Link', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::URL,\r\n\t\t\t'default' => array(\r\n\t\t\t\t'url' => '#'\r\n\t\t\t),\r\n\t\t\t'description' => esc_html__( 'enter button link', 'aapside-master' )\r\n\t\t] );\r\n\r\n\t\t$this->add_control( 'feature_items', [\r\n\t\t\t'label' => esc_html__( 'Feature Item', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::REPEATER,\r\n\t\t\t'default' => [\r\n\t\t\t\t[\r\n\t\t\t\t\t'feature' => esc_html__( '5 Analyzer', 'aapside-master' )\r\n\t\t\t\t],\r\n\t\t\t],\r\n\t\t\t'fields' => [\r\n\t\t\t\t[\r\n\t\t\t\t\t'name' => 'feature',\r\n\t\t\t\t\t'label' => esc_html__( 'Feature', 'aapside-master' ),\r\n\t\t\t\t\t'type' => Controls_Manager::TEXT,\r\n\t\t\t\t\t'description' => esc_html__( 'enter feature item.', 'aapside-master' ),\r\n\t\t\t\t\t'default' => esc_html__( '5 Analyzer', 'aapside-master' )\r\n\t\t\t\t]\r\n\t\t\t],\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\r\n\t\t$this->start_controls_section( 'styling_section', [\r\n\t\t\t'label' => esc_html__( 'Styling Settings', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->add_control( 'title_color', [\r\n\t\t\t'label' => esc_html__( 'Title Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .name\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'price_color', [\r\n\t\t\t'label' => esc_html__( 'Price Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap .price\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'month_color', [\r\n\t\t\t'label' => esc_html__( 'Month Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap .month\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_control( 'features_color', [\r\n\t\t\t'label' => esc_html__( 'Features Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-body ul\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\r\n\t\t/* button styling start */\r\n\t\t$this->start_controls_section( 'button_styling_section', [\r\n\t\t\t'label' => esc_html__( 'Button Styling', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->start_controls_tabs(\r\n\t\t\t'button_style_tabs'\r\n\t\t);\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'button_style_normal_tab',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Normal', 'aapside-master' ),\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'button_normal_color', [\r\n\t\t\t'label' => esc_html__( 'Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Button Background', 'aapside-master' ),\r\n\t\t\t'name' => 'button_normal_bg_color',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Border::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Border', 'aapside-master' ),\r\n\t\t\t'name' => 'button_normal_border',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_tab();\r\n\r\n\t\t$this->start_controls_tab(\r\n\t\t\t'button_style_hover_tab',\r\n\t\t\t[\r\n\t\t\t\t'label' => __( 'Hover', 'aapside-master' ),\r\n\t\t\t]\r\n\t\t);\r\n\t\t$this->add_control( 'button_hover_color', [\r\n\t\t\t'label' => esc_html__( 'Color', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::COLOR,\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\" => \"color: {{VALUE}}\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Button Background', 'aapside-master' ),\r\n\t\t\t'name' => 'button_hover_bg_color',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Border::get_type(), [\r\n\t\t\t'label' => esc_html__( 'Border', 'aapside-master' ),\r\n\t\t\t'name' => 'button_hover_border',\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn:hover\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_tab();\r\n\r\n\t\t$this->end_controls_tabs();\r\n\t\t$this->add_control( 'button_divider', [\r\n\t\t\t'type' => Controls_Manager::DIVIDER\r\n\t\t] );\r\n\t\t$this->add_responsive_control( 'button_border_radius', [\r\n\t\t\t'label' => esc_html__( 'Border Radius', 'aapside-master' ),\r\n\t\t\t'type' => Controls_Manager::DIMENSIONS,\r\n\t\t\t'units' => [ 'px', '%', 'em' ],\r\n\t\t\t'selectors' => [\r\n\t\t\t\t\"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\" => \"border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n\t\t\t]\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\t\t/* button styling end */\r\n\r\n\t\t/* border color start */\r\n\t\t$this->start_controls_section( 'hover_border_section', [\r\n\t\t\t'label' => esc_html__( 'Hover Border Style', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\r\n\t\t$this->add_group_control( Group_Control_Background::get_type(), [\r\n\t\t\t'name' => 'hover_background',\r\n\t\t\t'label' => esc_html__( 'Active Border Color', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02:after\"\r\n\t\t] );\r\n\r\n\t\t$this->end_controls_section();\r\n\t\t/* border color end */\r\n\r\n\r\n\t\t/* button styling start */\r\n\t\t$this->start_controls_section( 'typography_section', [\r\n\t\t\t'label' => esc_html__( 'Typography Settings', 'aapside-master' ),\r\n\t\t\t'tab' => Controls_Manager::TAB_STYLE\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'title_typography',\r\n\t\t\t'label' => esc_html__( 'Title Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-header .name\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'price_typography',\r\n\t\t\t'label' => esc_html__( 'Price Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-header .price-wrap\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'features_typography',\r\n\t\t\t'label' => esc_html__( 'Features Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-body ul\"\r\n\t\t] );\r\n\t\t$this->add_group_control( Group_Control_Typography::get_type(), [\r\n\t\t\t'name' => 'button_typography',\r\n\t\t\t'label' => esc_html__( 'Button Typography', 'aapside-master' ),\r\n\t\t\t'selector' => \"{{WRAPPER}} .single-price-plan-02 .price-footer .boxed-btn\"\r\n\t\t] );\r\n\t\t$this->end_controls_section();\r\n\t\t/* button styling end */\r\n\t}", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'client_logo',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Choose Image', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => Utils::get_placeholder_image_src(),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_name',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Title', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Client Name', 'elementive' ),\n\t\t\t\t'placeholder' => __( 'Type your client name here', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_link',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Link', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-client.com', 'elementive' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'clients',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Clients List', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => array(),\n\t\t\t\t'title_field' => '{{{ client_name }}}',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'max_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Logo max width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 600,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo img' => 'max-width : {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 0.5,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo:hover' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_carousel',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_SETTINGS,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'vertical_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Vertical align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-flex-top',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-flex-top' => __( 'Top', 'elementive' ),\n\t\t\t\t\t'uk-flex-middle' => __( 'Middle', 'elementive' ),\n\t\t\t\t\t'uk-flex-bottom' => __( 'Bottom', 'elementive' ),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'auto_play',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Enable auto play', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t\t'separator' => 'after',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'columns',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Columns', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 6,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 2,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'margins',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Column margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'overflow',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Overflow', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Loop', 'elementive' ),\n\t\t\t\t'description' => __( 'Set to yes to enable continuous loop mode', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'centered',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Centered slider', 'elementive' ),\n\t\t\t\t'description' => __( 'If yes, then active slide will be centered, not always on the left side.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'speed',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Speed', 'elementive' ),\n\t\t\t\t'description' => __( 'Speed of the enter/exit transition.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 10,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 500,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Navigation', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_diameter_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Diameter', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 30,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 40,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation ' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}}; line-height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_icon_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Icon width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 10,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'navigation_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background_hover',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation .navigation-background-hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->add_control(\n\t\t\t'pagination',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Pagination', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_bullet_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-text-center',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-text-center' => __( 'Center', 'elementive' ),\n\t\t\t\t\t'uk-text-left' => __( 'Left', 'elementive' ),\n\t\t\t\t\t'uk-text-right' => __( 'Right', 'elementive' ),\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bottom',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bottom size', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-pagination ' => 'bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_margin',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'margin: 0 {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 3,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_height',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet height', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 10,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'pagination_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Active', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_diameter_width_active',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 40,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 8,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t// End carousel navigation section.\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title\n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title \n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_sub_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Sub Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Sub Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#dee3e4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h2' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title h2',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Sub Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Sub Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Sub Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#343a40',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title p' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_sub_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title p',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "public function customize_controls_init()\n {\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'main_gallery_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Gallery Settings', 'elementor-main-gallery' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t 'style',\n\t\t \t[\n\t\t \t'label' \t=> esc_html__( 'Slider Type', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> 'bxslider',\n\t\t \t'label_block' \t=> false,\n\t\t \t'options' \t\t=> [\t\t\t\t\n\t\t\t\t\t'instagram'=> esc_html__('Instagram', 'baldiyaat'),\n\t\t\t\t\t'gallery-slider'=> esc_html__('Gallery Slider Carousel', 'baldiyaat'),\n\t\t\t\t\t'simple-gallery'=> esc_html__('Simple Gallery', 'baldiyaat'),\n\t\t\t\t\t'video-slider'=> esc_html__('Video Gallery', 'baldiyaat')\n\t\t \t],\n\t\t \t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t 'gallery-columns',\n\t\t \t[\n\t\t \t'label' \t=> esc_html__( 'Column', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> '2',\n\t\t \t'options' \t\t=> [\t\t\t\t\n\t\t\t\t\t'1' => esc_html__('1 Column', 'baldiyaat'),\n\t\t\t\t\t'2' => esc_html__('2 Column', 'baldiyaat'),\n\t\t\t\t\t'3' => esc_html__('3 Column', 'baldiyaat'),\n\t\t\t\t\t'4' => esc_html__('4 Column', 'baldiyaat'),\n\t\t\t\t\t'6' => esc_html__('6 Column', 'baldiyaat')\n\t\t \t],\n\t\t \t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'thumbnail-size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Thumbnail Size', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'label_block' \t=> false,\n\t\t\t\t'default' => esc_html__( 'hide', 'essential-addons-elementor' ),\n\t\t \t'options' => wpha_get_thumbnail_list(),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'num-fetch',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Num Fetch', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => 10,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'pagination',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Pagination', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'yes', 'essential-addons-elementor' ),\n\t\t\t\t'label_off' => __( 'no', 'essential-addons-elementor' ),\n\t\t\t\t'return_value' => 'enable',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Gallery Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_gallery_config_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Gallery Images', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'slider',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t\t[ 'main_gallery_settings_slide' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png' ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_gallery_settings_slide',\n\t\t\t\t\t\t'label' => esc_html__( 'Image', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'url' => KODEFOREST_MAIN_URL . 'assets/gallery/simple-gallery.png',\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_gallery_settings_slide_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_gallery_settings_slide_caption',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Caption', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_gallery_settings_enable_slide_link',\n\t\t\t\t\t\t'label' => __( 'Enable Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'default' => 'false',\n\t\t\t\t\t\t'label_on' => esc_html__( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'label_off' => esc_html__( 'No', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'return_value' => 'true',\n\t\t\t\t\t\t\n\t\t\t\t \t],\n\t\t\t\t \t[\n\t\t\t\t\t\t'name' => 'main_gallery_settings_slide_link',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => [\n\t\t \t\t\t'url' => '#',\n\t\t \t\t\t'is_external' => '',\n\t\t \t\t\t],\n\t\t \t\t\t'show_external' => true,\n\t\t \t\t\t'condition' => [\n\t\t \t\t\t\t'main_gallery_settings_enable_slide_link' => 'true'\n\t\t \t\t\t]\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{main_gallery_settings_slide_title}}',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Gallery Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_gallery_color_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color & Design', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_galleryt_bghover_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background Hover Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#d2973b',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .kode_gallery_fig:hover img' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\t\t\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_gallery_caption_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Caption Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-des' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_gallery_button_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button BG Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .kode_gallery_fig:hover a' => 'background-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t\n\t}", "public function controls()\n {\n }", "function add() {\n foreach ($this->_meta_box['pages'] as $page) {\n add_meta_box($this->_meta_box['id'], $this->_meta_box['title'], array(&$this, 'show'), $page, $this->_meta_box['context'], $this->_meta_box['priority']);\n }\n }", "function add() {\n foreach ($this->_meta_box['pages'] as $page) {\n add_meta_box($this->_meta_box['id'], $this->_meta_box['title'], array(&$this, 'show'), $page, $this->_meta_box['context'], $this->_meta_box['priority']);\n }\n }", "public function addButton(&$button)\n {\n $this->getChildren()->addControl($button);\n }", "protected function register_controls() {\n\n\t\t$this->render_team_member_content_control();\n\t\t$this->register_content_separator();\n\t\t$this->register_content_social_icons_controls();\n\t\t$this->register_helpful_information();\n\n\t\t/* Style */\n\t\t$this->register_style_team_member_image();\n\t\t$this->register_style_team_member_name();\n\t\t$this->register_style_team_member_designation();\n\t\t$this->register_style_team_member_desc();\n\t\t$this->register_style_team_member_icon();\n\t\t$this->register_content_spacing_control();\n\t}", "public function createChildControls ()\n\t{\n\t\tif ($this->_container===null)\n\t\t{\n\t\t\t$this->_container=Prado::CreateComponent('System.Web.UI.ActiveControls.TActivePanel');\n\t\t\t$this->_container->setId($this->getId(false).'_content');\n\t\t\tparent::getControls()->add($this->_container);\n\t\t}\n\t}", "function add() {\n\t\tforeach ($this->_meta_box['pages'] as $page) {\n\t\t\tadd_meta_box($this->_meta_box['id'], $this->_meta_box['title'], array(&$this, 'show'), $page, $this->_meta_box['context'], $this->_meta_box['priority']);\n\t\t}\n\t}", "protected function _register_controls()\r\n {\r\n\r\n\r\n $this->start_controls_section(\r\n 'slider_settings_section',\r\n [\r\n 'label' => esc_html__('Query Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_CONTENT,\r\n ]\r\n );\r\n $this->add_control(\r\n 'column',\r\n [\r\n 'label' => esc_html__('Column', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n '3' => esc_html__('04 Column', 'aapside-master'),\r\n '4' => esc_html__('03 Column', 'aapside-master'),\r\n '2' => esc_html__('06 Column', 'aapside-master')\r\n ),\r\n 'label_block' => true,\r\n 'description' => esc_html__('select grid column', 'aapside-master'),\r\n 'default' => '4'\r\n ]\r\n );\r\n $this->add_control(\r\n 'total',\r\n [\r\n 'label' => esc_html__('Total Post', 'aapside-master'),\r\n 'type' => Controls_Manager::TEXT,\r\n 'description' => esc_html__('enter how many post you want to show, enter -1 for unlimited', 'aapside-master'),\r\n 'default' => '-1'\r\n ]\r\n );\r\n $this->add_control(\r\n 'category',\r\n [\r\n 'label' => esc_html__('Category', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT2,\r\n 'multiple' => true,\r\n 'label_block' => true,\r\n 'description' => esc_html__('select category, for all category leave it blank', 'aapside-master'),\r\n 'options' => appside_master()->get_terms_names('portfolio-cat', 'id', true)\r\n ]\r\n );\r\n $this->add_control(\r\n 'orderby',\r\n [\r\n 'label' => esc_html__('Order By', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ID' => esc_html__('ID', 'aapside-master'),\r\n 'title' => esc_html__('Title', 'aapside-master'),\r\n 'date' => esc_html__('Date', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order by', 'aapside-master'),\r\n 'default' => 'ID'\r\n ]\r\n );\r\n $this->add_control(\r\n 'order',\r\n [\r\n 'label' => esc_html__('Order', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ASC' => esc_html__('Ascending', 'aapside-master'),\r\n 'DESC' => esc_html__('Descending', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order.', 'aapside-master'),\r\n 'default' => 'ASC'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination',\r\n [\r\n 'label' => esc_html__('Pagination', 'aapside-master'),\r\n 'type' => Controls_Manager::SWITCHER,\r\n 'description' => esc_html__('you can set yes to show pagination.', 'aapside-master'),\r\n 'default' => 'yes'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination_alignment',\r\n [\r\n 'label' => esc_html__('Pagination Alignment', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'left' => esc_html__('Left Align', 'aapside-master'),\r\n 'center' => esc_html__('Center Align', 'aapside-master'),\r\n 'right' => esc_html__('Right Align', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('you can set pagination alignment.', 'aapside-master'),\r\n 'default' => 'left',\r\n 'condition' => array('pagination' => 'yes')\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n $this->start_controls_section(\r\n 'thumbnail_settings_section',\r\n [\r\n 'label' => esc_html__('Thumbnail Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_control('thumb_border_radius', [\r\n 'label' => esc_html__('Border Radius', 'aapside-master'),\r\n 'type' => Controls_Manager::DIMENSIONS,\r\n 'size_units' => ['px', '%', 'em'],\r\n 'selectors' => [\r\n \"{{WRAPPER}} .hard-single-item-02 .thumb img\" => \"border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n ]\r\n ]);\r\n $this->add_control(\r\n 'thumbnail_bottom_gap',\r\n [\r\n 'label' => esc_html__('Thumbnail Bottom Gap', 'aapside-master'),\r\n 'type' => Controls_Manager::SLIDER,\r\n 'size_units' => ['px', '%'],\r\n 'range' => [\r\n 'px' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n 'step' => 1,\r\n ],\r\n '%' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n ],\r\n ],\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .thumb' => 'margin-bottom: {{SIZE}}{{UNIT}};',\r\n ],\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n\r\n /* title styling tabs start */\r\n $this->start_controls_section(\r\n 'title_settings_section',\r\n [\r\n 'label' => esc_html__('Title Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->start_controls_tabs(\r\n 'style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('title_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('title_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n\r\n /* title styling tabs end */\r\n\r\n /* readmore styling tabs start */\r\n $this->start_controls_section(\r\n 'readmore_settings_section',\r\n [\r\n 'label' => esc_html__('Category Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'readmore_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* readmore styling tabs end */\r\n\r\n /* pagination styling tabs start */\r\n $this->start_controls_section(\r\n 'pagination_settings_section',\r\n [\r\n 'label' => esc_html__('Pagination Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'pagination_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('pagination_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination` ul li a\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a, {{WRAPPER}} .portfolio-pagination ul li span\"\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('pagination_hover_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_hover_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a:hover, {{WRAPPER}} .Portfolio-pagination ul li span.current\"\r\n ]);\r\n\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* pagination styling tabs end */\r\n\r\n /* Typography tabs start */\r\n $this->start_controls_section(\r\n 'typography_settings_section',\r\n [\r\n 'label' => esc_html__('Typography Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'title_typography',\r\n 'label' => esc_html__('Title Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .title\"\r\n ]);\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'post_meta_typography',\r\n 'label' => esc_html__('Category Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .cats\"\r\n ]);\r\n $this->end_controls_section();\r\n\r\n /* Typography tabs end */\r\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__( 'Style', 'woocommerce-builder-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'wc_style_warning',\n\t\t\t[\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n\t\t\t\t'raw' => esc_html__( 'This is the preview mode of the builder, this widget may not show properly you should view the result in the Product Page and The style of this widget is often affected by your theme and plugins. If you experience any such issue, try to switch to a basic theme and deactivate related plugins.', 'woocommerce-builder-elementor' ),\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',\n\t\t\t]\n\t\t);\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Video Testimonials Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'vid_testimonial_view',\n [\n 'label' => __('Style', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'view1',\n 'options' => [\n 'view1' => __('Style 1', 'careerfy-frame'),\n 'view2' => __('Style 2', 'careerfy-frame'),\n 'view3' => __('Style 3', 'careerfy-frame'),\n ],\n ]\n );\n\n $repeater = new \\Elementor\\Repeater();\n $repeater->add_control(\n 'vid_testimonial_img', [\n 'label' => __('Image', 'careerfy-frame'),\n 'type' => Controls_Manager::MEDIA,\n 'label_block' => true,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ]\n );\n\n $repeater->add_control(\n 'vid_url', [\n 'label' => __('Video URL', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n \"description\" => __(\"Put Video URL of Vimeo, Youtube.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_title', [\n 'label' => __('Client Name', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('client Title will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n\n $repeater->add_control(\n 'rank_title', [\n 'label' => __('Client Rank', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('Client Rank will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'company_title', [\n 'label' => __('Client Company', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Company will be applied to style 1 and style 2.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'testimonial_desc', [\n 'label' => __('Description', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXTAREA,\n 'label_block' => true,\n \"description\" => __(\"Testimonial Description will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_location', [\n 'label' => __('Client Location', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Location will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n $this->add_control(\n 'careerfy_video_testimonial_item',\n [\n 'label' => __('Add video testimonial item', 'careerfy-frame'),\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'title_field' => '{{{ company_title }}}',\n ]\n );\n $this->end_controls_section();\n }", "public function add($label);", "public function add() {\n\t\t$this->display ( 'admin/tag/add.html' );\n\t}", "public function add(Validators $validator);", "public function btnAddCannedStrategy_Click($strFormId, $strControlId, $strParameter) {\n\t $this->pnlAddCannedStrategy->Visible = true;\n\t $this->pnlAddCannedStrategy->RemoveChildControls(true);\n\t $pnlAddCannedStrategyView = new AddCannedStrategy($this->pnlAddCannedStrategy,'UpdateStrategyList',$this); \t\t\n\t\t}", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'electro-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'electro-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'electro-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'electro-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'electro-extensions' ),\n 'return_value' => 'true',\n 'default' => 'false',\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'electro-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'electro-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'electro-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'electro-extensions' ),\n 'random' =>esc_html__( 'Random', 'electro-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'electro-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'electro-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "public function add($obj) {\n\t}", "protected function _register_controls() {\n\t\t$template_type = learndash_elementor_get_template_type();\n\t\t$preview_step_id = $this->learndash_get_preview_post_id( $template_type );\n\n\t\t$this->start_controls_section(\n\t\t\t'preview',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Preview Setting', 'learndash-elementor' ),\n\t\t\t)\n\t\t);\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'course' ) ), true ) ) {\n\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Course.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Course', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'course' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'course' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ) ), true ) ) {\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Lesson.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Lesson', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'lesson' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'lesson' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( in_array( $template_type, array( learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Topic.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Topic', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'topic' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'topic' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'preview_user_id',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__( 'User ID', 'learndash-elementor' ),\n\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t'options' => array(),\n\t\t\t\t'default' => get_current_user_id(),\n\t\t\t\t'label_block' => true,\n\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_USER,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Start of Style tab.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'section_course_content_header',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Header', 'learndash-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-section-heading h2',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'lesson' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-lesson-topic-list .ld-table-list .ld-table-list-header .ld-table-list-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'topic' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-table-list .ld-table-list-header .ld-table-list-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_header_text_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading > h2' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list .ld-table-list-header' => 'color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ), learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list.ld-topic-list .ld-table-list-header' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list.ld-topic-list .ld-table-list-header.ld-primary-background' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_expand_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading .ld-expand-button' => 'color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_expand_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading .ld-item-list-actions .ld-expand-button' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_course_content_row_item',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Row Item', 'learndash-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'header_section_course_content_row_item_title',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'TITLE', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'lesson' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-topic-list.ld-table-list .ld-table-list-items',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'topic' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-topic-list.ld-table-list .ld-table-list-items',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_row_item_title_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Title Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '#495255',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-title' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list-items .ld-table-list-item a' => 'color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_row_item_background_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '#ffffff',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item' => 'background-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list-items' => 'background-color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_control(\n\t\t\t\t'header_section_course_content_row_item_expand',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'EXPAND', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_expand_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-icon-arrow-down' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-text' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_expand_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-icon-arrow-down' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_row_item_lesson_progress',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'LESSON PROGRESS HEADER', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_lesson_progress_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_lesson_progress_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header.ld-primary-background' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_lesson_progress_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header.ld-primary-background' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t}\n\n\t\t$this->end_controls_section();\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ), learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\n\t\t\t$this->start_controls_section(\n\t\t\t\t'section_course_content_footer',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Footer', 'learndash-elementor' ),\n\t\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_links',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'LINKS (Back to...)', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_links_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-actions a.ld-primary-color',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_links_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-actions a.ld-primary-color' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_navigation',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'NAVIGATION', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_navigation_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_navigation_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_navigation_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button' => 'background-color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_mark_complete',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'MARK COMPLETE', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_mark_complete_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_mark_complete_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_mark_complete_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'secondary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button' => 'background-color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->end_controls_section();\n\t\t}\n\t}", "protected function register_controls() {\n $this->start_controls_section(\n 'developer_tools',\n [\n 'label' => esc_html__( 'Developer Tools', 'bridge-core' ),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'shortcode_snippet',\n [\n 'label' => esc_html__( 'Show Shortcode Snippet', 'bridge-core' ),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'no',\n 'options' => array(\n 'no' => esc_html__( 'No', 'bridge-core' ),\n 'yes' => esc_html__( 'Yes', 'bridge-core' ),\n ),\n ]\n );\n\n $this->end_controls_section();\n }", "function CreateChildControls() {\n }", "public function addWidget()\r\n {\r\n }", "protected function _register_controls(){\n //Name of the content section\n $this->start_controls_section(\n 'header_slider',\n array(\n 'label' => __('Slider', 'reveal'),\n 'tab' => Controls_Manager::TAB_CONTENT\n )\n );\n\n //input fields for the content\n $this->add_control(\n 'title',\n array(\n 'label' => __( 'Title', 'reveal' ),\n 'type' => Controls_Manager::WYSIWYG\n )\n ); // end add_control\n\n //button for the slider\n $this->add_control(\n 'button1_text',\n array(\n 'label' => __( 'Button 1 Text', 'reveal' ),\n 'type' => Controls_Manager::TEXT\n )\n );\n $this->add_control(\n 'button1_url',\n array(\n 'label' => __( 'Button 1 Url', 'reveal' ),\n 'type' => Controls_Manager::URL\n )\n );\n\n $this->add_control(\n 'button2_text',\n array(\n 'label' => __( 'Button 2', 'reveal' ),\n 'type' => Controls_Manager::TEXT\n )\n );\n $this->add_control(\n 'button2_url',\n array(\n 'label' => __( 'Button 2 Url', 'reveal' ),\n 'type' => Controls_Manager::URL\n )\n );\n\n //slider image\n $this->add_control(\n 'gallery',\n array(\n 'label' => __( 'Add Slider Images', 'reveal' ),\n 'type' => Controls_Manager::GALLERY,\n 'default' => [],\n )\n );\n\n $this->add_control(\n 'img_height',\n array(\n 'label' => __( 'Slider Images Height', 'reveal' ),\n 'type' => Controls_Manager::NUMBER,\n 'default' => 350,\n )\n );\n $this->end_controls_section(); //end of field creation\n\n //Section for style sheet\n $this->start_controls_section( //input field label\n 'content_style', //unique id\n [\n 'label' => __( 'Style', 'reveal' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n $this->end_controls_section();\n\n\n\n }", "function CreateChildControls(){\n parent::CreateChildControls();\n $this->AddControl(new SitemapControl(\"cms_sitemap\", \"cms_sitemap\"));\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Brand list Settings', 'xstore-core' ),\n\t\t\t\t'tab' \t=> \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'ids',\n\t\t\t[\n\t\t\t\t'label' \t=>\t__( 'Select Brand', 'xstore-core' ),\n\t\t\t\t'type' \t\t=>\t\\Elementor\\Controls_Manager::SELECT2,\n\t\t\t\t'multiple' \t=>\ttrue,\n\t\t\t\t'options' \t=>\tElementor::get_terms('brand'),\n\t\t\t\t'label_block'\t=> 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_a_z',\n\t\t\t[\n\t\t\t\t'label' => __( 'Display A-Z filter', 'xstore-core' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'description' => __( 'Do not forget switch on Customize -> Speed Optimization -> Masonry Scripts', 'xstore-core' ),\n\t\t\t\t'label_on' => __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' => __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'columns',\n\t\t\t[\n\t\t\t\t'label' \t=> __( 'Columns', 'xstore-core' ),\n\t\t\t\t'type' \t\t=> \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' \t=> '',\n\t\t\t\t'options' \t=> [\n\t\t\t\t\t'1' => esc_attr__( '1', 'xstore' ),\n\t\t\t\t\t'2' => esc_attr__( '2', 'xstore' ),\n\t\t\t\t\t'3' => esc_attr__( '3', 'xstore' ),\n\t\t\t\t\t'4' => esc_attr__( '4', 'xstore' ),\n\t\t\t\t\t'5' => esc_attr__( '5', 'xstore' ),\n\t\t\t\t\t'6' => esc_attr__( '6', 'xstore' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'alignment',\n\t\t\t[\n\t\t\t\t'label' \t => __( 'Alignment', 'xstore-core' ),\n\t\t\t\t'type' \t\t => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'options' \t => [\n\t\t\t\t\t'left' \t => esc_html__('Left', 'xstore-core') , \n\t\t\t\t\t'center' => esc_html__('Center', 'xstore-core') , \n\t\t\t\t\t'right'\t => esc_html__('Right', 'xstore-core') \n\t\t\t\t],\n\t\t\t\t'default'\t => 'left'\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'capital_letter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Display brands capital letter', 'xstore-core' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' => __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'brand_image',\n\t\t\t[\n\t\t\t\t'label' => __( 'Brand image', 'xstore-core' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' => __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'size',\n\t\t\t[\n\t\t\t\t'label' \t=>\t__( 'Images size', 'xstore-core' ),\n\t\t\t\t'type' \t\t=>\t\\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'condition' => ['brand_image' => 'yes'],\n\t\t\t\t'default' \t=>\t'',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'brand_title',\n\t\t\t[\n\t\t\t\t'label' \t\t=> __( 'Brand title', 'xstore-core' ),\n\t\t\t\t'type'\t\t\t=> \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' \t\t=> __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' \t=> __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' \t=> 'yes',\n\t\t\t\t'default' \t\t=> 'yes',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'tooltip',\n\t\t\t[\n\t\t\t\t'label' \t\t=> __( 'Title with tooltip', 'xstore-core' ),\n\t\t\t\t'type'\t\t\t=> \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' \t\t=> __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' \t=> __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' \t=> 'yes',\n\t\t\t\t'default' \t\t=> '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'brand_desc',\n\t\t\t[\n\t\t\t\t'label' \t\t=> __( 'Brand description', 'xstore-core' ),\n\t\t\t\t'type'\t\t\t=> \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' \t\t=> __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' \t=> __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' \t=> 'yes',\n\t\t\t\t'default' \t\t=> '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'hide_empty',\n\t\t\t[\n\t\t\t\t'label' \t\t=> __( 'Hide empty', 'xstore-core' ),\n\t\t\t\t'type'\t\t\t=> \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' \t\t=> __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' \t=> __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' \t=> 'yes',\n\t\t\t\t'default' \t\t=> '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'show_product_counts',\n\t\t\t[\n\t\t\t\t'label' \t\t=> __( 'Show Product Counts', 'xstore-core' ),\n\t\t\t\t'type'\t\t\t=> \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' \t\t=> __( 'Yes', 'xstore-cores' ),\n\t\t\t\t'label_off' \t=> __( 'No', 'xstore-cores' ),\n\t\t\t\t'return_value' \t=> 'yes',\n\t\t\t\t'default' \t\t=> '',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'class',\n\t\t\t[\n\t\t\t\t'label' \t=>\t__( 'Extra Class', 'xstore-core' ),\n\t\t\t\t'type' \t\t=>\t\\Elementor\\Controls_Manager::TEXT,\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t}", "public function add($element) {\n $type = strtolower(current(array_reverse(explode(\"\\\\\", get_class($element)))));\n parent::add($element);\n if ($type == \"hidden\")\n $this->_hiddenElements[] = $element;\n else\n $this->_inputElements[] = [$element, $this->_currentFieldset];\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'section_image',\n\t\t\t[\n\t\t\t\t'label' => __( 'Image', 'happyden' ),\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Width', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'tablet_default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'mobile_default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ '%', 'px', 'vw' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-feature-image img' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'space',\n\t\t\t[\n\t\t\t\t'label' => __( 'Max Width', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'tablet_default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'mobile_default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ '%', 'px', 'vw' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'vw' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-feature-image img' => 'max-width: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'height',\n\t\t\t[\n\t\t\t\t'label' => __( 'Height', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'tablet_default' => [\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'mobile_default' => [\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t],\n\t\t\t\t'size_units' => [ 'px', 'vh' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 500,\n\t\t\t\t\t],\n\t\t\t\t\t'vh' => [\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-feature-image img' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_responsive_control(\n\t\t\t'object-fit',\n\t\t\t[\n\t\t\t\t'label' => __( 'Object Fit', 'happyden' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'condition' => [\n\t\t\t\t\t'height[size]!' => '',\n\t\t\t\t],\n\t\t\t\t'options' => [\n\t\t\t\t\t'' => __( 'Default', 'happyden' ),\n\t\t\t\t\t'fill' => __( 'Fill', 'happyden' ),\n\t\t\t\t\t'cover' => __( 'Cover', 'happyden' ),\n\t\t\t\t\t'contain' => __( 'Contain', 'happyden' ),\n\t\t\t\t],\n\t\t\t\t'default' => '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .happyden-feature-image img' => 'object-fit: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\t}", "public function btnAddScorecard_Click($strFormId, $strControlId, $strParameter) {\n\t $this->pnlAddScorecard->Visible = true;\n\t $this->pnlAddScorecard->RemoveChildControls(true);\n\t $pnlAddScorecardView = new AddScorecard($this->pnlAddScorecard,'UpdateScorecardList',$this); \t\t\n\t\t}", "public function addAction()\n {\n $row = new Admin_Model_DbRow_Controller(array(\n 'moduleName' => $this->getRequest()->getParam('modul', ''),\n 'controllerName' => $this->getRequest()->getParam('control', ''),\n 'enabled' => 0,\n 'virtual' => $this->getRequest()->getParam('virtual', 0),\n 'description' => $this->getRequest()->getParam('description', '')\n ));\n $form = new Admin_Form_Controller_Add($row);\n $form->setAction('/noc/admin/controller/add');\n\n IF($this->getRequest()->isPost()) {\n IF($form->isValid($this->getRequest()->getParams())) {\n $this->dbCtrl->insert($row->toDbArray(array('moduleName', 'controllerName', 'enabled', 'virtual', 'description')));\n $this->_redirect('admin/controller/scan');\n }\n }\n\n $this->view->form = $form;\n }", "public function addGroup( $name, array $controls )\n\t{\n\t\t$obj = new Miao_Form_Control_Group( $name );\n\t\tforeach ( $controls as $control )\n\t\t{\n\t\t\t$obj->addControl( $control );\n\t\t}\n\t\t$this->addControl( $obj );\n\t\treturn $obj;\n\t}", "function addCustomControl($html, $property=\"\", $section=null) {\n if (is_object($property)) {\n $section = $property;\n $property = \"\";\n }\n \n // if section parameter is passed, add the control to the section\n // otherwise add it to the element root\n if ($section) {\n $l = $section;\n } else {\n $l = $this->El;\n }\n\n $control = $l->addControl(\"custom_control\", $property);\n $control->setHTML($html);\n $control->unprefix();\n\n return $control;\n }", "public function add() {\n if ($this->GdataAuth->isAuthorized()) {\n if (!empty($this->data)) {\n $this->YouTubeVideo->set($this->data);\n if ($this->YouTubeVideo->validates() && $this->YouTubeVideo->save($this->data)) {\n $this->Session->setFlash('It worked!');\n $this->redirect(array());\n }\n }\n // Set official you tube categories and access control options to populate\n // form fields\n $this->set('categories', $this->YouTubeVideo->categories());\n foreach ($this->YouTubeVideo->accessControls as $accessControl => $options) {\n $this->set(Inflector::pluralize($accessControl), array_combine($options, $options));\n }\n }\n }", "function RemoveControl(&$object) {\n\n \t//echo 'here';\n\n if (!is_object($object) || !is_object($this->FindControl($object->Name)))\n return;\n unset($object->Parent);\n unset($this->Controls[$object->Name]);\n }", "public function add($object): void;", "public function btnAddUser_Click($strFormId, $strControlId, $strParameter) {\n\t $this->pnlAddUser->Visible = true;\n\t $this->pnlAddUser->RemoveChildControls(true);\n\t $this->pnlRemoveUser->RemoveChildControls(true);\n\t $pnlAddUserView = new AddScorecardUser($this->pnlAddUser,'UpdateScorecardList',$this); \t\t\n\t\t}", "public function add(){\n\t\t\t\n\t\t\trequire_once('views/category/add.php');\n\t\t}", "function controls()\n\t{\n\t}", "public function add() {\n\t\t\n\t\t$this->template->content = View::instance(\"v_posts_add\");\n\t\t\n\t\t$client_files_body = Array(\n\t\t\t'/js/jquery.form.js',\n\t\t\t'/js/posts_add.js'\n\t\t);\n\t\t\n\t\t$this->template->client_files_body = Utils::load_client_files($client_files_body);\n\n\t\techo $this->template;\n\t\t\n\t}" ]
[ "0.741929", "0.73306775", "0.7229181", "0.6804962", "0.6348779", "0.60424525", "0.59369045", "0.59005946", "0.58931774", "0.58457613", "0.58347094", "0.578179", "0.56269336", "0.5623284", "0.5597254", "0.5595026", "0.5575268", "0.5546615", "0.55403733", "0.55120975", "0.5511349", "0.55089325", "0.55088586", "0.55017614", "0.5488697", "0.5480997", "0.5461876", "0.5454777", "0.5450054", "0.54379", "0.5364756", "0.5363819", "0.5358648", "0.5352695", "0.5334135", "0.5328473", "0.5328353", "0.5313052", "0.5310286", "0.53026855", "0.5295574", "0.52953273", "0.5279152", "0.52650017", "0.526497", "0.52552044", "0.52543706", "0.5251225", "0.52219355", "0.5213903", "0.51990235", "0.51960224", "0.51864403", "0.5183277", "0.5177164", "0.51719195", "0.51694566", "0.5162963", "0.51591617", "0.51502293", "0.51440454", "0.51416755", "0.5135922", "0.5132205", "0.5116472", "0.50969183", "0.50969183", "0.5093737", "0.5092046", "0.50919724", "0.50831884", "0.50824004", "0.50778747", "0.50672156", "0.50298685", "0.5016593", "0.5012249", "0.50121003", "0.5004685", "0.49890116", "0.49727753", "0.4951658", "0.49385774", "0.49288568", "0.48956874", "0.48737955", "0.48721945", "0.48699975", "0.4853992", "0.48488975", "0.48385516", "0.48375365", "0.48299104", "0.48188794", "0.48143145", "0.48117808", "0.4805927", "0.48034957", "0.47994485", "0.47927266" ]
0.71817094
3
Method Removes the specified Control object from the controls collection.
function RemoveControl(&$object) { //echo 'here'; if (!is_object($object) || !is_object($this->FindControl($object->Name))) return; unset($object->Parent); unset($this->Controls[$object->Name]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function remove_control($id)\n {\n }", "public function deleteControl($name);", "public function destroy(backupcontrols $backupcontrols)\n {\n //\n }", "public function remove(LabelTemplate $labelTemplate);", "public function remove()\n {\n $arg = func_get_args();\n\n foreach ($this->group as $form) {\n if (! is_object($form)) {\n $form = new $form();\n }\n\n if (method_exists($form, 'delete')) {\n $form->delete(...$arg);\n }\n }\n }", "public function addControl(Entities\\Devices\\Controls\\Control $control): void\n\t{\n\t\tif (!$this->controls->contains($control)) {\n\t\t\t// ...and assign it to collection\n\t\t\t$this->controls->add($control);\n\t\t}\n\t}", "public function erase()\n {\n if (is_object($this->addpointButton)) {\n $this->addpointButton->destroy();\n }\n if (is_object($this->removepointButton)) {\n $this->removepointButton->destroy();\n }\n\n $this->frame->clearComponents();\n $this->frame->destroy();\n $this->destroyComponents();\n parent::destroy();\n }", "protected function removeFormObjectFromViewHelperVariableContainer() {}", "public function remove () {\r\n\t\t\r\n\t\tforeach ($this as $node) \r\n\t\t $node->parentNode->removeChild($node);\r\n\t}", "function unloadRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n for ($i = 0; $i < count($this->Controls); $i++) {\n @$control = &$this->Controls[$keys[$i]];\n if(method_exists($control, \"unloadRecursive\")){\n $control->unloadRecursive();\n }\n $control=null;\n }\n }\n $this->ControlOnUnload();\n $this->Controls=array();\n }", "public function remove($handles)\n {\n }", "public function remove() {\n\t\t$this->setRemoved(TRUE);\n\t}", "public function remove()\n {\n $this->_getBackend()->remove($this->_id);\n }", "public function remove();", "public function remove();", "public function remove();", "public function remove();", "public function dialog_Close($strFormId, $strControlId, $strParameter)\n {\n $this->Form->removeControl($this->ControlId);\n }", "public function remove($label) {\n\t\tif ($this->_has($label)) {\n\t\t\tunset($this->_register[$label]);\n\t\t}\n\t}", "public function btnRemoveUser_Click($strFormId, $strControlId, $strParameter) {\n\t $this->pnlRemoveUser->Visible = true;\n\t $this->pnlRemoveUser->RemoveChildControls(true);\n\t $this->pnlAddUser->RemoveChildControls(true);\n\t $pnlRemoveUserView = new RemoveScorecardUser($this->pnlRemoveUser,'UpdateScorecardList',$this); \t\t\n\t\t}", "function removeButton($index) {\r\n\t\tif(!$index>(count($this->buttons)-1)) {\r\n\t\t\tif($index == \"last\") { $index = $this->buttons[count($this->buttons)-1]; }\r\n\t\t\telseif($index == \"first\") { $index = 0; }\r\n\r\n\t\t\t$i=$index;\r\n\t\t\twhile($i>$index) {\r\n\t\t\t\t$this->buttons[$i]=$this->buttons[$i+1];\r\n\t\t\t\t$i++;\r\n\t\t\t}\r\n\t\t\tunset($this->buttons[count($this->buttons)-1]);\r\n\t\t\treturn true;\r\n\t\t} else {\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "public function remove($item)\n {\n $this->gridField->setRecord(null);\n $config = $this->gridField->getConfig();\n $config->addComponent(new GridFieldAddNewButton('buttons-before-right'));\n $config->addComponent(new GridFieldAddExistingAutocompleter('buttons-before-left'));\n }", "function wp_unregister_widget_control($id)\n {\n }", "public function __unset($label) {\n\t\t$this->remove($label);\n\t}", "function removeButton($a_button_name)\n\t{\n\t\t$key = array_search($a_button_name, $this->buttons);\n\t\tif ($key !== FALSE)\n\t\t{\n\t\t\tunset($this->buttons[$key]);\n\t\t}\n\t}", "public function remove() {}", "public function remove() {}", "public function removeLabel(): void\n {\n $this->labelName = null;\n $this->label = false;\n }", "function do_delete(){\n\t\t// remove from fieldset:\n\t\t$fieldset = jcf_fieldsets_get( $this->fieldset_id );\n\t\tif( isset($fieldset['fields'][$this->id]) )\n\t\t\tunset($fieldset['fields'][$this->id]);\n\t\tjcf_fieldsets_update( $this->fieldset_id, $fieldset );\n\t\t\n\t\t// remove from fields array\n\t\tjcf_field_settings_update($this->id, NULL);\n\t}", "public function remove ($obj) {}", "abstract public function closeControl();", "public function removeAllButtons()\n {\n $this->mixButtons = array();\n $this->blnValidationArray = array();\n $this->blnModified = true;\n }", "public function remove_meta_box() {\n\t\tremove_meta_box( $this->tax_name . 'div', 'ctrs-projects', 'side' );\n\t}", "public function removeButton($blockName);", "public function remove() {\n }", "public function addControl(IControl $control): IControl;", "public function remove()\n {\n }", "public function remove_meta_boxes(){\r\n remove_meta_box('slugdiv', 'cycloneslider', 'normal');\r\n }", "protected function removeInstance() {}", "public function removeButton($strButtonId)\n {\n if (!empty($this->mixButtons)) {\n $this->mixButtons = array_filter($this->mixButtons, function ($a) use ($strButtonId) {\n return $a['id'] == $strButtonId;\n });\n }\n\n unset ($this->blnValidationArray[$strButtonId]);\n\n $this->blnModified = true;\n }", "function AddControls($controls)\r\n {\r\n $this->Controls = $controls;\r\n }", "public function remove($object);", "public function remove($object);", "public function removeFieldSet($index) {\n\t\t$this->fieldsets[$index] = null;\n\t}", "public static function remove() : void\n {\n static::clear();\n \n }", "public function remove($object): void;", "public function remove_meta_box() {\r\n\r\n\t\tif( ! is_wp_error( $this->tax_obj ) && isset($this->tax_obj->object_type) ) foreach ( $this->tax_obj->object_type as $post_type ):\r\n\t\t\t$id = ! is_taxonomy_hierarchical( $this->taxonomy ) ? 'tagsdiv-'.$this->taxonomy : $this->taxonomy .'div' ;\r\n\t \t\tremove_meta_box( $id, $post_type, 'side' );\r\n\t \tendforeach;\r\n\t}", "public function remove($name, $removeObjects = true) {}", "public function clear()\n {\n $this->inputFieldsGroup->clear();\n $this->inputFilesGroup->clear();\n $this->inputImagesGroup->clear();\n $this->inputConditionsGroup->clear();\n }", "public function remove($value);", "public function remove()\n {\n\n }", "public function unset()\n {\n unset($this->value);\n }", "public function removeWidgets()\n {\n $this->disabledWidgets->each(function ($widget) {\n unregister_widget($this->widgetIds[$widget]);\n });\n }", "abstract public function remove();", "abstract public function remove();", "abstract public function remove();", "public function destroy(CaretakerForm $caretakerForm)\n {\n //\n }", "public function deleteIpControl($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->deleteIpControlWithOptions($request, $runtime);\n }", "public function adminRemove()\r\n\t{\r\n\t\treturn;\r\n\t}", "function AddControl(&$object) {\n if (!is_object($object)) {\n return;\n }\n //if (is_object($object->Parent))\n //$object->Parent->RemoveControl($object);\n $object->Parent = &$this;\n $object->Page = &$this->Page;\n @$this->Controls[$object->Name] = &$object;\n if ($this->_state >= WEB_CONTROL_INITIALIZED) {\n $object->initRecursive();\n if ($this->_state >= WEB_CONTROL_LOADED)\n $object->loadRecursive();\n }\n }", "public function erase()\n {\n ActionHandler::getInstance()->deleteAction($this->deleteAction);\n ActionHandler::getInstance()->deleteAction($this->deleteActionf);\n $this->saveButton->destroy();\n $this->loadButton->destroy();\n $this->frame->clearComponents();\n $this->frame->destroy();\n $this->destroyComponents();\n\n parent::destroy();\n }", "public function clearSelection() {\n wb_set_selected($this->controlID, self::NO_SELECTION);\n\n return $this;\n }", "public function remove($id);", "public function remove($id);", "public function destroy(Add_image $add_image)\n {\n //\n }", "function removeObjectByID($inTermsID) {\n\t\tif ( $this->getCount() > 0 ) {\n\t\t\tforeach ( $this as $oObject ) {\n\t\t\t\tif ( $oObject->getTermsID() == $inTermsID ) {\n\t\t\t\t\t$oObject->setMarkForDeletion(true);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $this;\n\t}", "public function RemoveRecord()\n {\n $rec = $this->GetActiveRecord();\n global $g_BizSystem;\n $ok = $this->GetDataObj()->RemoveRecord($rec,$bPrtObjUpdated);\n if (!$ok)\n return $this->ProcessDataObjError($ok);\n\n $html = \"\";\n // rerender parent form's driving form (its field is updated in M-1 case)\n if ($bPrtObjUpdated) {\n $prtForm = $g_BizSystem->GetObjectFactory()->GetObject($this->m_ParentFormName);\n $html = $prtForm->ReRender();\n }\n //$this->UpdateActiveRecord($this->GetDataObj()->GetRecord(0));\n return $html . $this->ReRender();\n }", "function remove($id)\n {\n unset($this->collection[$id]);\n }", "function remove($aws_data_object) {\n\t\t}", "public function clearPrevious()\n {\n $this->previous = NULL;\n }", "public function admin_remove(){\n \n $this->set(\"title_for_layout\",\"Remove a Group\");\n \n // Load the group in question\n $group = $this->Group->find('first', array('conditions' => array('Group.id' => $this->params->id)));\n if($group){\n $this->set('group', $group);\n } else {\n $this->Session->setFlash('That group could not be found.', 'default', array('class' => 'alert alert-error'));\n $this->redirect(array('controller' => 'group', 'action' => 'index', 'admin' => true));\n }\n }", "public function action_remove(){\n $abuse = ORM::factory('BoardAbuse', $this->request->param('id'));\n if($abuse->loaded()){\n if($abuse->ad->loaded())\n $abuse->ad->delete();\n $abuse->delete();\n }\n $this->redirect('admin/boardAbuses' . URL::query());\n }", "public function removePost(PostInterface $post);", "public function Remove($data) {\r\n if($this->root != null)\r\n return null;\r\n return $this->removeHelper($data, $this->root);\r\n }", "public function remove_form_field()\n\t{\n\t\t//Get logged in session admin id\n\t\t$user_id \t\t\t\t\t\t= ($this->session->userdata('user_id_hotcargo')) ? $this->session->userdata('user_id_hotcargo') : 1;\n\t\t$setting_data \t\t\t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t$data['data']['setting_data'] \t= $setting_data;\n\t\t$data['data']['settings'] \t\t= $this->sitesetting_model->get_settings();\n\t\t$data['data']['dealer_id'] \t\t= $user_id;\n\t\t\n\t\t//getting all admin data \n\t\t$data['myaccount_data'] \t\t\t= $this->myaccount_model->get_account_data($user_id);\n\t\t\n\t\t\n\t\t//Get requested id to remove\n\t\t$field_id \t\t\t\t\t= $this->input->get('form_id');\n\t\t\n\t\t//deleting query\n\t\t$this->mongo_db->where(array('field_name' => $field_id));\n\t\tif($this->mongo_db->delete('form_fields'))\n\t\t\techo 1;\n\t\telse\n\t\t\techo 0;\n\t}", "abstract public function remove($collection, $criteria = null);", "public function onRemove();", "public function remove($element);", "public function clear() \r\n {\r\n unset($this->elements);\r\n $this->elements = array();\r\n }", "public function remove() {\r\n\t\t// Check for request forgeries\r\n\t\tJRequest::checkToken() or die( 'Invalid Token' );\r\n\r\n\t\t$post\t= JRequest::get('post');\r\n\t\t$cid \t= JRequest::getVar( 'checkboxid', array(), 'post', 'array' );\r\n\t\tJArrayHelper::toInteger($cid);\r\n\t\t\r\n\t\t$model = $this->getModel('languages');\r\n\t\t\r\n\t\tif ($model->remove($cid, $post)) {\r\n\t\t\t$msg = JText::_( 'LANGUAGES_REMOVED' );\r\n\t\t} else {\r\n\t\t\t$msg = JText::_( 'ERROR_DELETING_LANGUAGES' );\r\n\t\t}\r\n\r\n\t\t// Check the table in so it can be edited.... we are done with it anyway\r\n\t\t$link = 'index.php?option=com_joomfish&task=languages.show';\r\n\t\t$this->setRedirect($link, $msg);\r\n\t}", "protected function removeFormObjectNameFromViewHelperVariableContainer() {}", "public function control_close()\n\t{\n\t\t$this->controls_opened = $this->line_opened = false;\n\t\treturn \"</div>\\n</div>\"; // close .controls div\n\t}", "public function destroy(ClassChoice $classChoice)\n {\n //\n }", "public function destroy($id)\n {\n $control = Control::find($id)->delete();\n\n return back()->with('info', 'Eliminado correctamente');\n }", "public function remove($selector = null)\n\t{\n\t\treturn $this->cmd('remove', array(), $selector);\n\t}", "function action_remove() {\n\t\t\t$data = UTIL::get_post('data');\n\t\t\t$id = (int)$data['rem_id'];\n\t\t\t$table = $data['rem_table'];\n\t\t\t\n\t\t\t$choosen = $this->SESS->get('objbrowser', 'choosen');\n\t\t\tunset($choosen[$table][$id]);\n\t\t\tif (count($choosen[$table]) == 0) unset($choosen[$table]);\n\t\t\t\n\t\t\t$this->SESS->set('objbrowser', 'choosen', $choosen);\n\t\t}", "public function unregister_meta_boxes()\n {\n }", "function remove_postcustom() {\n\tremove_meta_box( 'postcustom', null, 'normal' );\n}", "private function removeObjectFromObjects(){\n\t\t$object_id = $this->object->id;\n\t\t//remove object from total objects\n\t\tif($this->objects->contains( 'id', $object_id)){\n\t\t\t$this->objects = $this->objects->reject( function($item, $key) use($object_id) {\n\t\t\t\treturn $item->id == $object_id;\n\t\t\t});\n\t\t}\n\t}", "public function remove($item);", "public function removeObserver() {\n //$this->__observers = array();\n foreach($this->__observers as $obj) {\n unset($obj);\n }\n }", "public function destroy($id)\n {\n $add = Add::find($id);\n $add->delete();\n }", "public function remove($object)\n {\n parent::delete($object); // TODO: Change the autogenerated stub\n }", "public function no_button() { $this->button = NULL; }", "private function destroy() {\n wb_destroy_window($this->controlID);\n\n return $this;\n }", "protected function RemovalObject()\n {\n $id = Request::PostData('delete');\n return $id ? new Container($id) : null;\n }", "public function remove($tag) { //+\n\t\tunset($this->arShortcodes[$tag]);\n\t}", "function bsg_remove_genesis_customizer_controls( $wp_customize ) {\n // remove Site Title/Logo: Dynamic Text or Image Logo option from Customizer\n $wp_customize->remove_control( 'blog_title' );\n return $wp_customize;\n}", "public static function remove() {\n if ($u = static::check_record_existence()) {\n if ($u->remove())\n flash('Usuário deletado com sucesso.');\n else\n flash('Algo ocorreu errado. Tente novamente mais tarde.', 'error');\n }\n\n go_paginate();\n }", "public function removeIpControlPolicyItem($request)\n {\n $runtime = new RuntimeOptions([]);\n\n return $this->removeIpControlPolicyItemWithOptions($request, $runtime);\n }" ]
[ "0.6533316", "0.62502456", "0.55944717", "0.5424647", "0.5274031", "0.52098316", "0.51489204", "0.50818485", "0.5077212", "0.50703186", "0.50672567", "0.505403", "0.505188", "0.5017671", "0.5017671", "0.5017671", "0.5017671", "0.49994475", "0.49988776", "0.4950321", "0.49154985", "0.49140978", "0.49133074", "0.4891943", "0.4849103", "0.48021126", "0.48006454", "0.47871906", "0.47683376", "0.47645885", "0.47346908", "0.47068182", "0.46533558", "0.46433216", "0.4617308", "0.4616968", "0.45967895", "0.4584793", "0.45808077", "0.4564151", "0.45572242", "0.45506328", "0.45506328", "0.45423675", "0.45402512", "0.4502544", "0.44954565", "0.44849512", "0.44779578", "0.4477241", "0.44754207", "0.44682238", "0.44565022", "0.44457915", "0.44457915", "0.44457915", "0.44423997", "0.44275892", "0.44195357", "0.43986815", "0.43725783", "0.43713623", "0.43684527", "0.43684527", "0.4359599", "0.4348801", "0.43456063", "0.43447757", "0.43363923", "0.43198457", "0.43149802", "0.43099225", "0.4309259", "0.4292898", "0.42908522", "0.42904466", "0.42807224", "0.42801288", "0.42657292", "0.42475158", "0.42457122", "0.42382985", "0.42278787", "0.4226263", "0.4224867", "0.42223397", "0.42221427", "0.421956", "0.42014334", "0.41904306", "0.41896042", "0.41855493", "0.4185162", "0.4184828", "0.41827378", "0.41755515", "0.41661474", "0.41661206", "0.4159318", "0.41575143" ]
0.75417274
0
Method finds control by its name
function &FindControl($controlName) { if (isset($this->Controls[$controlName])) return $this->Controls[$controlName]; if ($this->HasControls()) { $keys = array_keys($this->Controls); for ($i = 0; $i < count($this->Controls); $i++) { @$control = &$this->Controls[$keys[$i]]; if ($control->HasControls()) { @$result = &$control->FindControl($controlName); if (is_object($result)) return $result; } } } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getControl($name);", "public function get_control($name)\n\t{\n\t\tif (!array_key_exists($name, $this->controls)) throw new Exception(\"Control '$name' not found\");\n\t\treturn $this->controls[$name];\n\t}", "public function checkControlExists($name);", "public function testFindSimpleControl()\n {\n $names = ['hello', 10, 0, '0', '0.0'];\n\n foreach ($names as $name)\n {\n $form = $this->setupFormFind('', 'post', $name);\n\n $control = $form->findFormControlByName($name);\n $this->assertNotEmpty($control);\n $this->assertEquals($name, $control->getLocalName());\n }\n }", "public function testFindComplexControl()\n {\n $names = ['hello', 10, 0, '0', '0.0'];\n\n foreach ($names as $name)\n {\n $form = $this->setupFormFind('', $name);\n\n $control = $form->findFormControlByName($name);\n $this->assertNotEmpty($control);\n $this->assertEquals($name, $control->getLocalName());\n }\n }", "public function GetControl($Name) {\n\n return $this->Controls[$Name];\n }", "public function getControl($id)\n\t{\n\t\t$control=null;\n\t\t$service=prado::getApplication()->getService();\n\t\tif ($service instanceof TPageService)\n\t\t{\n\t\t\t// Find the control\n\t\t\t// Warning, this will not work if you have a '_' in your control Id !\n\t\t\t$controlId=str_replace(TControl::CLIENT_ID_SEPARATOR,TControl::ID_SEPARATOR,$id);\n\t\t\t$control=$service->getRequestedPage()->findControl($controlId);\n\t\t}\n\t\treturn $control;\n\t}", "public function __get($name)\n\t{\n\t\t$pos=strpos($name, 'Control',1);\n\t\t$name=strtolower(substr($name, 0, $pos));\n\n\t\t$cp=$this->getCallbackParameter();\n\t\tif(!isset($cp->$name) || $cp->$name=='')\n\t\t\treturn null;\n\n\t\treturn $this->getControl($cp->$name);\n\t}", "public function getControls();", "public function validateControlName($name);", "public function grabControl($strControlId)\n {\n\t\tif (!isset($_FORM) || !$_FORM) {\n\t\t\treturn null;\n\t\t}\n\t\treturn $_FORM->GetControl($strControlId);\n }", "public function getAllControls();", "function getControl()\n\t{\n\t\treturn $this->control;\n\t}", "public function get_control($id)\n {\n }", "public static function find($name);", "public static function find($name);", "public function testFindFieldSet()\n {\n $names = ['hello', 10, 0, '0', '0.0'];\n\n foreach ($names as $name)\n {\n $form = $this->setupFormFind($name);\n\n $control = $form->findFormControlByName($name);\n $this->assertNotEmpty($control);\n $this->assertEquals($name, $control->getLocalName());\n }\n }", "public function getControl()\n {\n return $this->control;\n }", "public function getControl()\n {\n return $this->control;\n }", "public function getControl()\n {\n return $this->control;\n }", "private function searchControl(array $cid, array $controls, $deep = -1)\n {\n foreach ($controls as $obj)\n {\n $vs = $this->getActualVS($obj);\n if ($vs && $vs['properties']['id'] == $cid[0])\n {\n $m = 1; $n = count($cid);\n for ($k = 1; $k < $n; $k++)\n {\n if (!isset($vs['controls'])) break;\n $controls = $vs['controls']; $flag = false;\n foreach ($controls as $obj)\n {\n $vs = $this->getActualVS($obj);\n if ($vs && $vs['properties']['id'] == $cid[$k])\n {\n $m++;\n $flag = true;\n break;\n }\n }\n if (!$flag) break;\n }\n if ($m == $n) break;\n return false;\n }\n else if (isset($vs['controls']) && $deep != 0) \n {\n $ctrl = $this->searchControl($cid, $vs['controls'], $deep > 0 ? $deep - 1 : -1);\n if ($ctrl !== false) return $ctrl;\n }\n }\n return empty($n) ? false : ($obj instanceof Control ? $obj : $this->get($vs['attributes']['id']));\n }", "public function find($name) {\r\n if (isset($this->views[$name])) {\r\n return $this->views[$name];\r\n }\r\n\r\n if ($this->hasHintInformation($name = trim($name))) {\r\n return $this->views[$name] = $this->findNamespacedView($name);\r\n }\r\n\r\n return $this->views[$name] = $this->findInPaths($name, $this->paths);\r\n }", "public function getDroppedControl ()\n\t {\n\t\t $control=null;\n\t\t $service=Prado::getApplication()->getService();\n\t\t if ($service instanceof TPageService)\n\t\t {\n\t\t\t// Find the control\n\t\t\t// Warning, this will not work if you have a '_' in your control Id !\n\t\t\t$dropControlId=str_replace(TControl::CLIENT_ID_SEPARATOR,TControl::ID_SEPARATOR,$this->_dragElementId);\n\t\t\t$control=$service->getRequestedPage()->findControl($dropControlId);\n\t\t }\n\t\t return $control;\n\t }", "public function getDroppedControl ()\n\t {\n\t\t $control=null;\n\t\t $service=prado::getApplication()->getService();\n\t\t if ($service instanceof TPageService)\n\t\t {\n\t\t\t// Find the control\n\t\t\t// Warning, this will not work if you have a '_' in your control Id !\n\t\t\t$dropControlId=str_replace(TControl::CLIENT_ID_SEPARATOR,TControl::ID_SEPARATOR,$this->_dragElementId);\n\t\t\t$control=$service->getRequestedPage()->findControl($dropControlId);\n\t\t }\n\t\t return $control;\n\t }", "public function getControlNames();", "public function getElementName($name);", "public function deleteControl($name);", "function &GetSelector()\r\n\t{\r\n\t\treturn $this->FindControl(\"selectorGroup\");\r\n\t}", "public function getWidget($name){\n\t\t\t$class = null;\n\t\t\tif(is_file($this->config['widgetFolder'].$name.'.widget.php')){\n\t\t\t\trequire_once($this->config['widgetFolder'].$name.'.widget.php');\n\t\t\t\t$name = 'UIW_'.$name;\n\t\t\t\t$class = new $name();\n\t\t\t} \n\t\t\treturn $class;\n\t\t}", "public function getControl()\n\t{\n\t\t$control = parent::getControl();\n\t\tif (count($this->suggest) !== 0) {\n\t\t\t$control->attrs['data-tag-suggest'] = Environment::getApplication()->getPresenter()->link(self::$renderName, array($this->paramName => '%__filter%'));\n\t\t}\n\t\n\t\treturn $control;\n\t}", "abstract public function openControl($label, $class = '', $attr = '');", "function get_form_index($type, $name)\n {\n $retval = FALSE;\n if ($this->object->get_form_count($type) > 0) {\n $retval = array_search($name, $this->object->_forms[$type]);\n }\n return $retval;\n }", "public function getControl($caption = NULL)\n\t{\n\t\t$control = $this->getControlDiv();\n\t\t$input = $this->getInput($caption);\n\n\t\tif ($this->src) {\n\t\t\t$control->add($this->getExisted());\n\t\t}\n\t\t$control->add($this->getPreview())\n\t\t\t\t->add($this->getButtons($input, 'div'));\n\n\t\treturn $control;\n\t}", "public function getWidget();", "public function findLabel($name)\n {\n $model = $this->hooq->where('martbox_display_id', $name)->first();\n return $model;\n }", "function &getInstance($control_name, $name=null) {\r\n\t\trequire_once ZAR_CONTROLS_PATH . '/'.strtolower($control_name).'.php';\r\n\t\t$class = 'ZariliaControl_'.$control_name.'.php';\r\n\t\t$obj = new $class($name);\r\n\t\tunset($class);\r\n\t\treturn $obj;\r\n\t}", "public function getControlField($tagName)\n {\n $query = '//response/record/marcRecord/controlfield[@tag=\"' . $tagName . '\"]';\n $controlField = $this->domCrawler->filterXPath($query)->first();\n\n $controlFields = $this->domCrawler->filterXPath($query)->each(function(Crawler $node) {\n return new ControlField($node);\n });\n\n if(count($controlFields) > 0 ){\n return $controlFields;\n }\n\n return null;\n }", "public function testGetName() {\r\n\t\t$this->testObject->setName ( self::TEST_CONTROL_ID );\r\n\t\t$this->assertTrue ( self::TEST_CONTROL_ID == $this->testObject->getName (), 'incorrect control name returned' );\r\n\t}", "abstract public function getPanelName();", "public function getControl()\n\t{\n\t\t$control = parent::getControl();\n\t\t$control->addAttributes(array(\n\t\t\t'id' => $this->getHtmlId(),\n\t\t));\n\t\treturn $control;\n\t}", "public function addControl($name)\n {\n return $this->qform->addControl($name);\n }", "public function getWidget($widgetName)\r\n {\r\n foreach($this->_widgets as $widget)\r\n {\r\n if(key($widget) === $widgetName)\r\n return current($widget);\r\n }\r\n\r\n return false;\r\n }", "public function getByControllerName($name)\n {\n $result = $this->_module->get(array('modulo'=>$name));\n\n if(!$result)\n return false;\n return $result[0];\n }", "public function getComponentByName($name);", "function getParentSelectorName() ;", "public function getNamedWidgetArgument($name);", "public function __get($name){\n if($this->locator->hasLocation($name)){\n return $this->findElement($name);\n }\n }", "public function add_control($name, $ctl)\n\t{\n\t\tif (array_key_exists($name, $this->controls)) {\n\t\t\tif (DEBUG) dwrite(\"Control '$name' already added\");\n\t\t\treturn;\n\t\t}\n\n\t\t$ctl->page =& $this;\n\t\t$this->controls[$name] =& $ctl;\n\t}", "protected function getWidget()\n {\n $widgets = $this->getPage()->findAll('css', 'body div.filter-container ul.ui-multiselect-checkboxes');\n\n /** @var NodeElement $widget */\n foreach ($widgets as $widget) {\n if ($widget->isVisible()) {\n return $widget;\n }\n }\n\n self::fail('Could not find widget on page or it\\'s not visible');\n }", "public function find($name)\n {\n\t\t$this->load($name);\n }", "public function get($id, $searchRecursively = true, Control $context = null)\n {\n if (isset($this->controls[$id])) \n {\n $ctrl = $this->controls[$id];\n if ($context && !isset($context->getControls()[$id])) return false;\n if ($ctrl->isRemoved()) return false;\n return $ctrl;\n }\n else if (isset($this->vs[$id]))\n {\n $vs = $this->vs[$id];\n $ctrl = new $vs['class']($vs['properties']['id']);\n $ctrl->setVS($vs);\n if ($context && !isset($context->getControls()[$id])) return false;\n $this->controls[$ctrl->attr('id')] = $ctrl;\n return $ctrl;\n }\n if ($context) $controls = $context->getControls();\n else if (isset($this->controls[$this->UID])) \n {\n if ($id == $this->controls[$this->UID]->prop('id')) return $this->controls[$this->UID];\n $controls = $this->controls[$this->UID]->getControls();\n }\n else if (isset($this->vs[$this->UID])) \n {\n if ($id == $this->vs[$this->UID]['properties']['id']) return $this->get($this->UID, false);\n $controls = $this->vs[$this->UID]['controls'];\n }\n else return false;\n $ctrl = $this->searchControl(explode('.', $id), $controls, $searchRecursively ? -1 : 0);\n if ($ctrl) $this->controls[$ctrl->attr('id')] = $ctrl;\n return $ctrl;\n }", "public function getButton($buttonName)\n {\n return $this->getChildren()->getControl($buttonName, true, 'ButtonModelBase');\n }", "function findByName($name)\r\n\t{\r\n\t\tglobal $debug;\r\n\t\t$dbh = getOpenedConnection();\r\n\t\t\r\n\t\tif ($dbh == null)\r\n\t\t\treturn;\r\n\t\t\t\r\n\t\t$sql = \"\r\n\t\t\tselect Id\r\n\t\t\tfrom tbl_Pistol_CompetitionDay\r\n\t\t\twhere Name like '$this->Name'\r\n\t\t\";\r\n\t\t\r\n\t\t$result = mysqli_query($dbh,$sql);\r\n\t\tif ($obj = mysqli_fetch_object($result))\r\n\t\t{\r\n\t\t\t$found = $obj->Id;\r\n\t\t}\r\n\r\n\t\tmysqli_free_result($result);\r\n\t\tif ($found != 0) {\r\n\t\t\t$this->load($found);\r\n\t\t}\r\n\t\t\r\n\t\treturn $found;\r\n\t}", "public static function get_button_by_name($name) {\n\t\tif ( $button = \\PodloveSubscribeButton\\Model\\Button::find_one_by_property('name', $name) ) {\n\t\t\treturn $button;\n\t\t}\n\n\t\tif ( $network_button = \\PodloveSubscribeButton\\Model\\NetworkButton::find_one_by_property('name', $name) ) {\n\t\t\t$network_button->id = $network_button->id . 'N';\n\t\t\treturn $network_button;\n\t\t}\n\n\t\treturn false;\n\t}", "public function getIndex($name, $id) {\n foreach ($this->view->result as $item) {\n if ($item->$name == $id) {\n return $item->index;\n }\n }\n return FALSE;\n }", "static function getIdOf ($name)\n {\n return array_search ($name, self::$NAMES);\n }", "public function getControl()\r\n\t{\r\n\t\t$control=parent::getControl();\r\n\t\t$control->class[]='tag-control';\r\n\r\n\t\tif ($this->delimiter!==NULL && Strings::trim($this->delimiter)!=='') {\r\n\t\t\t$control->attrs['data-tag-delimiter']=$this->delimiter;\r\n\t\t\t}\r\n\r\n\t\tif ($this->joiner!==NULL && Strings::trim($this->joiner)!=='') {\r\n\t\t\t$control->attrs['data-tag-joiner']=$this->joiner;\r\n\t\t\t}\r\n\t\r\n\t\tif ($this->suggestCallback!==NULL) {\r\n\t\t\t$form=$this->getForm();\r\n\t\t\tif (!$form || !$form instanceof Form) {\r\n\t\t\t\tthrow new \\Nette\\InvalidStateException('TagInput supports only Nette\\Application\\UI\\Form.');\r\n\t\t\t\t}\r\n\t\t\t$control->attrs['data-tag-suggest']=$form->presenter->link($this->renderName, array('word_filter' => '%__filter%'));\r\n\t\t\t}\r\n\r\n\t\treturn $control;\r\n\t}", "public function getControls()\n\t{\n\t\t$this->ensureChildControls();\n\t\treturn $this->_container->getControls();\n\t}", "public function getControl()\n\t{\n\t\t$container = clone $this->container;\n\t\t$separator = (string) $this->separator;\n\t\t$control = parent::getControl();\n\t\t$id = $control->id;\n\t\t$counter = 0;\n\t\t$value = $this->value === NULL ? NULL : (string) $this->getValue();\n\t\t$label = /*Nette\\Web\\*/Html::el('label');\n\n\t\tforeach ($this->items as $key => $val) {\n\t\t\t$control->id = $label->for = $id . '-' . $key;\n\t\t\t$control->checked = (string) $key == $value;\n\t\t\t$control->value = $key;\n\n\t\t\t/* Novak - vse bude HTML */\n\t\t\t/*if ($val instanceof Html) {\n\t\t\t\t$label->setHtml($val);\n\t\t\t} else {\n\t\t\t\t$label->setText($val);\n\t\t\t}*/\n\t\t\t$label->setHtml($val);\n\n\t\t\t// za posledni polozkou nebude oddelovac\n\t\t\tif($counter == count($this->items)-1) $separator = \"\";\n\n\t\t\t$container->add((string) $control . (string) $label . $separator);\n\t\t\t$counter++;\n\n\t\t}\n\n\t\treturn $container;\n\t}", "function getSelectorName() ;", "function getSelectorName() ;", "public function find(string $view);", "public function getControls()\n\t{\t\t\t \n\t\treturn $this->getComponents(TRUE, 'Nette\\Forms\\IFormControl');\n\t}", "public function getButton() {}", "final public function offsetGet($name)\n\t{\n\t\treturn $this->getComponent($name, TRUE);\n\t}", "public function findCommand($name) {\n $query = $this->pdo->prepare('SELECT * FROM yubnub.commands WHERE lowercase_name = :lowercaseName');\n $query->bindValue(':lowercaseName', mb_strtolower($name), PDO::PARAM_STR);\n $query->execute();\n if ($query->rowCount() > 0) {\n $row = $query->fetch(PDO::FETCH_ASSOC);\n return $this->createCommand($row);\n }\n return null;\n }", "function get( $name )\n\t{\n\t foreach( $this->inputs as $input ){\n\t // loop over each and see if match\n\t if( $input['name'] == $name ){\n\t // return a reference\n\t return $input;\n\t }\n\t }\n\t}", "public function byLabel($name);", "protected function _register_controls() {\n\t}", "public function find($selector);", "function getSelector1Name() ;", "public function getParentSelectorName();", "public function register_controls()\n {\n }", "abstract public function getPanelKey();", "public function get_widget_control($args)\n {\n }", "public function offsetGet(mixed $name): FormInterface\n {\n return $this->get($name);\n }", "public function getInput($name);", "function getChildSelectorName() ;", "public function getControllerName()\n {\n $current = static::class;\n $ancestry = ClassInfo::ancestry($current);\n $controller = null;\n while ($class = array_pop($ancestry)) {\n if ($class === self::class) {\n break;\n }\n if (class_exists($candidate = sprintf('%sController', $class))) {\n $controller = $candidate;\n break;\n }\n $candidate = sprintf('%sController', str_replace('\\\\Model\\\\', '\\\\Control\\\\', $class));\n if (class_exists($candidate)) {\n $controller = $candidate;\n break;\n }\n }\n if ($controller) {\n return $controller;\n }\n return PageController::class;\n }", "public function appendControl($name, $template);", "public function locate();", "public function getChildSelectorName();", "public function findName($name)\n {\n return $this->model->where('name', $name)->first();\n }", "function ID($id)\n {\n if (false !== $ctrl = \\ClickBlocks\\MVC\\Page::$current->view->get($id)) return $ctrl->attr('id');\n }", "public function getComponent($name);", "function get_button($id, $index) {\n\t\tif(isset($this->buttons[$id][$index])) {\n\t\t\treturn $this->buttons[$id][$index];\n\t\t}\n\n\t\treturn false;\n\t}", "public function find($tag);", "public function getComponent($name) {\n return $this->components[$name];\n }", "public function getParentSelectorName() {}", "public function getElementName();", "private function findForm(){\n\n\t\t$results = $this->wpdb->get_results($this->wpdb->prepare(\"\n\t\t\tSELECT\n\t\t\t\t`form`.`id` \t\t\tas 'id',\n\t\t\t\t`form`.`label` \t\t\tas 'label',\n\t\t\t\t`form`.`confirm_submit` as 'confirm_submit',\n\t\t\t\t`form`.`date_available` as 'date_available',\n\t\t\t\t`form`.`date_expire` \tas 'date_expire'\n\t\t\tFROM `mark_reg_forms` as `form`\n\t\t\tWHERE\n\t\t\t\t`form`.`id` = %d\n\t\t\t\tAND `form`.`enabled` = 1\n\t\t\", $this->form_id));\n\n\t\tif(count($results)):\n\t\t\t$this->form_confirm_submit\t= $results[0]->confirm_submit;\n\t\t\t$this->form_label \t\t\t= $results[0]->label;\n\t\t\t$this->form_date_available\t= $results[0]->date_available;\n\t\t\t$this->form_date_expire\t\t= $results[0]->date_expire;\n\t\t\t$this->form_name\t\t\t= 'mark_reg_form_'.$this->form_id;\n\t\telse:\n\t\t\t$this->log(\"FORM NOT FOUND FOR ID: $this->form_id\");\n\t\tendif;\n\t}", "function fetchElement($name, $value, &$node, $control_name)\r\n {\r\n return JText::_($value);\r\n }", "public function findByName($name);", "public function findByName($name);", "public function findByName($name);", "public function getControl()\r\n {\r\n return $this->_checkBoxTreeRender($this->_getTree());\r\n }", "function &locate($name, $findpath=false) {\n if ($this->name == $name) {\n if ($findpath) {\n $this->visiblepath = array($this->visiblename);\n $this->path = array($this->name);\n }\n return $this;\n } else {\n $return = NULL;\n return $return;\n }\n }", "public function getWidgetByPath(array $names);", "public function getControl()\n {\n return \\Nette\\Forms\\Controls\\BaseControl::getControl()->checked($this->value);\n }", "public function getControl()\n {\n $name = $this->getHtmlName();\n return Html::el()\n ->add(Html::el('input')->name($name . '[day]')->id($this->getHtmlId())->value($this->day))\n ->add(\\Nette\\Forms\\Helpers::createSelectBox(\n array(\"zimní měsíce\" => array(1 => \"leden\", 2), \"jarní měsíce\" => array(3 => 3, 4, 5, 6, 7, 8, 9, 10, 11, 12)), array('selected?' => $this->month)\n )->name($name . '[month]'))\n ->add(Html::el('input')->name($name . '[year]')->value($this->year));\n }" ]
[ "0.7661887", "0.70866567", "0.67597723", "0.6366229", "0.6070919", "0.6061565", "0.5963723", "0.56296945", "0.5626426", "0.56045246", "0.55911255", "0.5561188", "0.54828167", "0.5472097", "0.54472244", "0.54472244", "0.5339303", "0.53190047", "0.53190047", "0.53190047", "0.5291752", "0.5266385", "0.52607244", "0.5244665", "0.52295375", "0.5100096", "0.5040016", "0.4993951", "0.49739096", "0.49370578", "0.49301356", "0.48930448", "0.48785385", "0.4848604", "0.48401424", "0.48376378", "0.48271772", "0.48188546", "0.48016492", "0.48011434", "0.47998613", "0.47995704", "0.478928", "0.4787882", "0.47853503", "0.4774367", "0.47557163", "0.47555226", "0.475119", "0.47418034", "0.473764", "0.47371337", "0.4735569", "0.47346887", "0.47101122", "0.47021767", "0.46980286", "0.4697096", "0.4693055", "0.4692253", "0.4692253", "0.46882394", "0.46657747", "0.46558407", "0.4644921", "0.46414477", "0.4633735", "0.463152", "0.46145043", "0.46128413", "0.46086708", "0.4605002", "0.46016237", "0.4600026", "0.45915613", "0.45737278", "0.45640734", "0.45467833", "0.45461866", "0.45453554", "0.4545182", "0.45439938", "0.45432678", "0.4539082", "0.45367417", "0.45358363", "0.45355675", "0.45217997", "0.4521798", "0.45209002", "0.45179006", "0.45176336", "0.45120183", "0.45120183", "0.45120183", "0.45098567", "0.45063958", "0.45017287", "0.44953203", "0.4494998" ]
0.7391364
1
Method checks if Instance has controls
function HasControls() { return (count($this->Controls) > 0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function checkControlExists($name);", "static function hasCurrent() {\n\t\treturn is_object(self::$_ctrl);\n\t}", "public function controls()\n {\n }", "public static function checkPreconditions() {\n /**\n * @var $ilCtrl ilCtrl\n * @var $ilPluginAdmin ilPluginAdmin\n */\n global $ilCtrl, $ilPluginAdmin;\n $existCtrlMainMenu = $ilPluginAdmin->exists(IL_COMP_SERVICE, 'UIComponent', 'uihk', 'CtrlMainMenu');\n $isActiveCtrlMainMenu = $ilPluginAdmin->isActive(IL_COMP_SERVICE, 'UIComponent', 'uihk', 'CtrlMainMenu');\n //The ilRouterGUI is used in ILIAS <= 4.4\n $existRouterGUI = self::getBaseClass() != false;\n return ($existCtrlMainMenu && $isActiveCtrlMainMenu && $existRouterGUI);\n }", "public function shouldShow()\n {\n return $this->_checkClass();\n }", "public function validateControlAndChildren()\n {\n if ($this->blnIsOpen) { // don't validate a closed dialog\n if (!empty($this->mixButtons)) { // using built-in dialog buttons\n if (!empty ($this->blnValidationArray[$this->strClickedButtonId])) {\n return parent::validateControlAndChildren();\n }\n } else { // using QButtons placed in the control\n return parent::validateControlAndChildren();\n }\n }\n return true;\n }", "public function register_controls()\n {\n }", "public function prepare_controls()\n {\n }", "public function getControls();", "public function is_group(){\n return is_array($this->controls) && count($this->controls) > 1;\n }", "public function hasPanControl()\n {\n return $this->panControl !== null;\n }", "public function isAttached($ctrl)\n {\n $id = $ctrl instanceof Control ? $ctrl->attr('id') : $ctrl;\n return isset($this->controls[$id]) || isset($this->vs[$id]);\n }", "function controls()\n\t{\n\t}", "public static function hasInstance(){\n\t\tif(self::$instance !== null){\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "protected function _register_controls() {\n\t}", "public function getAllControls();", "private function hasInstance()\n {\n return !self::$_instance ? false : true;\n }", "public function hasScaleControl()\n {\n return $this->scaleControl !== null;\n }", "public function hasStreetViewControl()\n {\n return $this->streetViewControl !== null;\n }", "public function hasMapTypeControl()\n {\n return $this->mapTypeControl !== null;\n }", "public static function hasInstance() {\n return (self::$instance != null);\n }", "function captchaExists()\n\t{\n\t\tif ( $this->mode == ADD_ONTHEFLY || $this->mode == ADD_INLINE || $this->mode == EDIT_INLINE )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn $this->pSet->isCaptchaEnabledOnEdit();\n\t}", "static public function hasInstances()\n {\n return (bool) self::$instances;\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "public function hasInputs()\n {\n return (count($this->inputs) > 0);\n }", "public function hasRotateControl()\n {\n return $this->rotateControl !== null;\n }", "function ts_check_if_control_panel()\r\n{\r\n\t$control_panel = ot_get_option('control_panel');\r\n\t\r\n\tif ($control_panel == 'enabled_admin' && current_user_can('manage_options') || $control_panel == 'enabled_all')\r\n\t{\r\n\t\treturn true;\r\n\t}\r\n\treturn false;\r\n}", "public function hasSubForms()\n {\n return count($this->getSubForms()) > 0;\n }", "public function hasPresenter()\n {\n return ! empty($this->presenter);\n }", "public function hasOverviewMapControl()\n {\n return $this->overviewMapControl !== null;\n }", "public function access()\n {\n return $this->hasInstanceOldPlugins();\n }", "public function hasZoomControl()\n {\n return $this->zoomControl !== null;\n }", "public function preventsElementDisplay(): bool;", "public function hasInputsCount()\n {\n return $this->inputs_count !== null;\n }", "public function getControls()\n {\n return $this->controls;\n }", "protected function _isNeedToShow()\n {\n if (!$this->_isModuleEnabled()) {\n return false;\n }\n\n if (!$this->_isParallaxBlockEnabled()) {\n return false;\n }\n\n return true;\n }", "public function afterLoadRegisterControlsUI(){\n\t\t\n\t}", "function hasInstanceGroups() {\n\t\treturn $this->_grouping->hasInstanceGroups();\n\t}", "protected function get_controls()\n\t{\n\t\treturn array\n\t\t(\n\t\t\tself::CONTROL_PERMISSION => Module::PERMISSION_CREATE,\n\t\t\tself::CONTROL_RECORD => true,\n\t\t\tself::CONTROL_OWNERSHIP => true,\n\t\t\tself::CONTROL_FORM => true\n\t\t)\n\n\t\t+ parent::get_controls();\n\t}", "public function valid()\n {\n\n if ($this->container['template'] === null) {\n return false;\n }\n return true;\n }", "function audioman_is_ect_featured_content_inactive( $control ) {\n return ! ( class_exists( 'Essential_Content_Featured_Content' ) || class_exists( 'Essential_Content_Pro_Featured_Content' ) );\n }", "protected function isCreateButtonRequired()\n {\n $parentBlock = $this->getParentBlock();\n\n return $parentBlock instanceof Template\n && $parentBlock->getOrderId()\n && $this->canShowButton($parentBlock->getOrderId());\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore \n\n\t\t$this->register_general_content_controls();\n\n\t\t$this->register_count_content_controls();\n\n\t\t$this->register_helpful_information();\n\t}", "public function checkAccess()\n {\n $list = $this->getPages();\n\n /**\n * Settings controller is available directly if the $page request variable is provided\n * if the $page is omitted, the controller must be the subclass of Settings main one.\n *\n * The inner $page variable must be in the getPages() array\n */\n return parent::checkAccess()\n && isset($list[$this->page])\n && (\n ($this instanceof \\XLite\\Controller\\Admin\\Settings && isset(\\XLite\\Core\\Request::getInstance()->page))\n || is_subclass_of($this, '\\XLite\\Controller\\Admin\\Settings')\n );\n }", "public function customize_controls_init()\n {\n }", "public function isEditFormShown() {}", "function have_interface() {\n\t\treturn count($this->watches) > 0;\n\t}", "public static function Elementor_active_check() {\n\n if ( ! self::$active_plugins ) {\n self::init();\n }\n\n return in_array( 'elementor/elementor.php', self::$active_plugins ) || array_key_exists( 'elementor/elementor.php', self::$active_plugins );\n }", "function customize_controls_init()\n {\n }", "static public function hasInstance($name = 'main')\n {\n return isset(self::$instances[$name]);\n }", "protected function hasLabels()\n {\n $showLabels = $this->getConfigParam('showLabels'); // plus abfrage $this-showLabels kombinieren.\n if ($this->autoPlaceholder && $showLabels !== ActiveForm::SCREEN_READER) {\n $showLabels = false;\n }\n\n return $showLabels;\n }", "public static function initialized()\n\t{\n\t\treturn !is_null(self::$instance);\n\t}", "function hasDropDown() ;", "protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }", "function canCreate() {\r\n\t\treturn !DataObject::get_one($this->class);\r\n\t}", "function checkPanelMode()\n\t{\n\t\tswitch ($this->display_mode)\n\t\t{\n\t\t\tcase \"view\":\n\t\t\t\t$this->displayStatusPanel();\n\t\t\t\tbreak;\n\n\t\t\tcase \"setup\":\n\t\t\t\t$this->displayProcessPanel();\n\t\t\t\tbreak;\n\t\t}\n\t}", "public function canShowAnything()\n {\n if ($this->getCanShowDataFields() or $this->getCanShowAdditionalBooks()\n ) {\n $books = $this->getAdditionalBooksToShow();\n $fields = $this->getDataFieldsToShow();\n if (!empty($books) or !empty($fields)) {\n return true;\n }\n }\n\n return false;\n }", "protected function register_controls() {\n\n\t\t$this->render_team_member_content_control();\n\t\t$this->register_content_separator();\n\t\t$this->register_content_social_icons_controls();\n\t\t$this->register_helpful_information();\n\n\t\t/* Style */\n\t\t$this->register_style_team_member_image();\n\t\t$this->register_style_team_member_name();\n\t\t$this->register_style_team_member_designation();\n\t\t$this->register_style_team_member_desc();\n\t\t$this->register_style_team_member_icon();\n\t\t$this->register_content_spacing_control();\n\t}", "function hasForm() {\n\t\t\t$form = $this->getForm( );\n\n\t\t\tif (!empty( $$form )) {\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\treturn false;\n\t\t}", "public function valid() {\n return false !== current($this->components);\n }", "public function canShowAnything()\n {\n if ($this->getCanShowDataFields() or $this->getCanShowAdditionalBooks()\n ) {\n $books = $this->getAdditionalBooksToShow();\n $fields = $this->getDataFieldsToShow();\n if (!empty($books) or !empty($fields)) {\n return true;\n }\n }\n\n return false;\n }", "static function checkInit(\n \\AmidaMVC\\Framework\\Controller $ctrl,\n \\AmidaMVC\\Component\\SiteObj &$_siteObj )\n {\n if( $_siteObj->get( 'siteObj' ) ) {\n return TRUE;\n }\n return FALSE;\n }", "public function isUsed()\n\t{\n\t\treturn $this->data && $this->data['forms_attempts'] > 0;\n\t}", "public function getControls()\n\t{\t\t\t \n\t\treturn $this->getComponents(TRUE, 'Nette\\Forms\\IFormControl');\n\t}", "public static function isGfActive()\n {\n return class_exists('RGForms');\n }", "public function getControls()\n\t{\n\t\t$this->ensureChildControls();\n\t\treturn $this->_container->getControls();\n\t}", "public function instance_can_be_docked() {\n return false;\n }", "protected function is_types_active() {\n\t\treturn class_exists( 'Types_Main' );\n\t}", "public function useControlbin() {\n\t\treturn $this->use_controlbin == self::VALUE_TRUE;\n\t}", "public function hasShowDisplay()\n {\n return $this->show_display !== null;\n }", "public function hasView() {\n\t\treturn is_object($this->view);\n\t}", "public function showInMenu()\n {\n $ctrs = PageCom::ctrs();\n return $ctrs && (count($ctrs) > 1);\n }", "private function _validate_user() {\n\t\treturn (current_user_can(\"edit_posts\") && current_user_can(\"edit_pages\") && !empty($this->buttons));\n\t}", "public static function validateFilled(IControl $control)\r\n\t{\r\n\t\treturn count($control->getValue())!==0;\r\n\t}", "public function canShowTab()\n {\n return $this->_getCurrentTheme()->isVirtual() && $this->_getCurrentTheme()->getId();\n }", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasDropDown() {}", "public function hasVclock()\n {\n return isset($this->vclock);\n }", "public function hasDropDown() {}", "public function hasDropDown() {}", "public static function hasInstance($instance_name = 'default')\n {\n return isset(self::$instances[$instance_name]);\n }", "public function isFormField()\n\t{\n\t\treturn $this->handler_class != 'Application\\DeskPRO\\CustomFields\\Handler\\Display';\n\t}", "private function checkMenu()\n {\n\n }", "public function hasInitBu()\n {\n return $this->get(self::INIT_BU) !== null;\n }", "function audioman_is_ect_featured_content_active( $control ) {\n return ( class_exists( 'Essential_Content_Featured_Content' ) || class_exists( 'Essential_Content_Pro_Featured_Content' ) );\n }", "protected function CheckTemplateEngineStatus()\n {\n $this->data['show_template_engine'] = TdbCmsConfig::GetInstance()->fieldShowTemplateEngine;\n }", "public function hasBound()\n {\n return $this->bound !== null;\n }", "public function valid()\n {\n\n if ($this->container['is_empty'] === null) {\n return false;\n }\n if ($this->container['use_autocomplete'] === null) {\n return false;\n }\n return true;\n }", "public function has_menu()\r\n {\r\n return false;\r\n }", "public function isShowInput() {\n\t\t$this->getShowInput();\n\t}", "public function checkAddToCardButton()\n {\n return $this->_rootElement->find($this->addToCard, Locator::SELECTOR_CSS)->isVisible();\n }", "protected function _register_controls() {\n\n\t\t//link\n\t\t//image\n\t\t//featured\n\t\t//term\n\t\t//style alternative-imagebox\n\t\t//\n\t\t//\n\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-listeo' ),\n\t\t\t)\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link','elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'elementor-listeo' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Choose Background Image', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\n\n\t\t// $this->add_control(\n\t\t// \t'featured',\n\t\t// \t[\n\t\t// \t\t'label' => __( 'Featured badge', 'elementor-listeo' ),\n\t\t// \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t// \t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t// \t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t// \t\t'return_value' => 'yes',\n\t\t// \t\t'default' => 'yes',\n\t\t// \t]\n\t\t// );\n\n\t\t$this->add_control(\n\t\t\t'taxonomy',\n\t\t\t[\n\t\t\t\t'label' => __( 'Taxonomy', 'elementor-listeo' ),\n\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [],\n\t\t\t\t'options' => $this->get_taxonomies(),\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$taxonomy_names = get_object_taxonomies( 'listing','object' );\n\t\tforeach ($taxonomy_names as $key => $value) {\n\t\n\t\t\t$this->add_control(\n\t\t\t\t$value->name.'term',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Show term from '.$value->label, 'elementor-listeo' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'default' => [],\n\t\t\t\t\t'options' => $this->get_terms($value->name),\n\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t'taxonomy' => $value->name,\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\n\n\t\t$this->add_control(\n\t\t\t'show_counter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show listings counter', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t\t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style ', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' => 'alternative-imagebox',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'elementor-listeo' ),\n\t\t\t\t\t'alternative-imagebox' => __( 'Alternative', 'elementor-listeo' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "public function valid()\n {\n\n if ($this->container['class_name'] === null) {\n return false;\n }\n return true;\n }", "public function hasScreen(){\n return $this->_has(12);\n }", "public function canShowTab()\r\n\t{\r\n\t\treturn true;\r\n\t}" ]
[ "0.66844016", "0.6625151", "0.623702", "0.61716133", "0.61647433", "0.6073021", "0.6056189", "0.60411435", "0.60091525", "0.59959954", "0.598452", "0.5909895", "0.5878007", "0.58705086", "0.584485", "0.58116984", "0.5809447", "0.5786876", "0.57811844", "0.5714378", "0.57133543", "0.5712865", "0.56432444", "0.56296074", "0.56280637", "0.5618305", "0.56036896", "0.559167", "0.55822885", "0.55341977", "0.55180854", "0.55116343", "0.5494451", "0.5487207", "0.546978", "0.5468154", "0.5464935", "0.5460782", "0.54507357", "0.54415923", "0.54336447", "0.5424549", "0.54233885", "0.54129755", "0.5411465", "0.5385963", "0.5375167", "0.5369856", "0.5363617", "0.53622735", "0.5356433", "0.53499687", "0.53498995", "0.53466856", "0.53446645", "0.53282064", "0.531441", "0.53100127", "0.53092647", "0.5306045", "0.53043246", "0.53036773", "0.5302798", "0.5292245", "0.52897394", "0.52870077", "0.52812487", "0.52797717", "0.5274879", "0.5267748", "0.5256382", "0.52542067", "0.52518904", "0.52375394", "0.5235215", "0.5229639", "0.5229639", "0.5229639", "0.5229639", "0.5228586", "0.5228586", "0.5228586", "0.5227659", "0.5226858", "0.5226858", "0.52204", "0.5219481", "0.5216837", "0.52115744", "0.52086663", "0.52034897", "0.5192797", "0.5190251", "0.51723766", "0.5171703", "0.51714975", "0.51704246", "0.51671535", "0.51657355", "0.5165528" ]
0.7874779
0
Method Processes recursive load of control and all of it's children.
function createChildrenRecursive() { $this->CreateChildControls(); if ($this->HasControls()) { $keys = array_keys($this->Controls); $count = count($this->Controls); for ($i = 0; $i < $count; $i++) { @$control = &$this->Controls[$keys[$i]]; $control->createChildrenRecursive(); } } $this->initChildrenRecursive(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "function loadedChildren()\r\n {\r\n //Calls childrens loaded recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->loaded();\r\n }\r\n }", "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "protected function childLoad() {}", "function initRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n @$control->Page = &$this->Page;\n $control->initRecursive();\n }\n }\n $this->_state = WEB_CONTROL_INITIALIZED;\n $this->ControlOnInit();\n }", "final public function load() {\n $this->childLoad();\n \\add_action('admin_menu', [$this, 'addAdminMenuEntries']);\n }", "protected function _load()\r\n {\r\n $page = new Model_Page();\r\n $children = $page->getChildren($this->_parentId);\r\n if ($children != null && $children->count() > 0) {\r\n foreach ($children as $child) {\r\n if ($child->show_on_menu == 1) {\r\n $this->items[] = new Digitalus_Menu_Item($child);\r\n }\r\n }\r\n }\r\n }", "private function load_children() {\n\t\tif (isset($this->_children)) return;\n\t\t$this->_children = array();\n\t\t$this->_testcases = array();\n\t\tif (!$this->exists()) return; // entity doesn't actually exist\n\t\tforeach (new DirectoryIterator($this->data_path()) as $child) {\n\t\t\t$filename = $child->getFilename();\n\t\t\tif ($child->isDot() || $filename[0] == '.') {\n\t\t\t\t// skip hidden files and ..\n\t\t\t} else if ($child->isDir()) {\n\t\t\t\t// subdirectory = child entity\n\t\t\t\t$this->_children[$filename] = new Entity($this, $filename);\n\t\t\t} else if (substr($filename,-3) == '.in') {\n\t\t\t\t// \".in\" file = testcase\n\t\t\t\t$this->_testcases []= substr($filename,0,-3);\n\t\t\t}\n\t\t}\n\t\tsort($this->_testcases);\n\t\t//ksort($this->_children);\n\t\tuasort($this->_children, 'compare_order');\n\t}", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "protected function loadTreeData() {}", "public function load() {\n\t\tforeach ($this->childWidgets as $widget) {\n\t\t\tif ($widget->getElement() == null) {\n\t\t\t\tConsole::error($widget);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tDOM::appendChild($this->getElement(), $widget->getElement());\n\t\t\t$widget->load();\n\t\t}\n\t\tparent::load();\n\t}", "public function loadProcess() {\n\t\t// register page view\n\t\t$this->pixelPageView();\n\t\t\n\t\t// load next URL string\n\t\t$nextPosition = $this->position + 1;\n\t\t$lastPosition = array_pop(array_keys($this->pathOrderArr));\n\t\t\n\t\tfor ($i = $nextPosition; $i <= $lastPosition + 1; $i++) {\n\t\t\tif (array_key_exists($i, $this->pathOrderArr)) {\n\t\t\t\t$nextPosition = $i;\n\t\t\t\tbreak;\n\t\t\t}\t\n\t\t}\n\t\t\n\t\t// generate next page's URL\n\t\tif ($nextPosition > $lastPosition)\n\t\t\t$this->nextUrl = 'javascript: parent.location.href=\\''. $this->redirectURL .'\\''; // end of path, redirect to affiliate's URL\n\t\telse \n\t\t\t$this->nextUrl = $this->getNextUrl($nextPosition);\n\t\t\n\t\t$this->loadView();\n\t}", "function unloadRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n for ($i = 0; $i < count($this->Controls); $i++) {\n @$control = &$this->Controls[$keys[$i]];\n if(method_exists($control, \"unloadRecursive\")){\n $control->unloadRecursive();\n }\n $control=null;\n }\n }\n $this->ControlOnUnload();\n $this->Controls=array();\n }", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "abstract protected function loadPagetree(DataContainerInterface $objDc);", "private function setAllLoaded()\n {\n $class_reflection = new ReflectionClass(get_class($this));\n do {\n if ($class_reflection->isInstantiable())\n $this->setLoadedFromDb($class_reflection->getName());\n\n } while (($class_reflection = $class_reflection->getParentClass()) && # get the parent\n $class_reflection->getName() != __CLASS__); # check that we're not hitting the top\n }", "function preinit()\r\n {\r\n //Calls children's init recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->preinit();\r\n }\r\n }", "function LoadChildrenIntoTree($id, &$tree, $loadprops = false, $all = false)\n\t{\t\n\t\tglobal $gCms;\n\t\t$db = &$gCms->GetDb();\n\n\t\t// get the content rows\n\t\t$query = \"SELECT * FROM \".cms_db_prefix().\"content WHERE parent_id = ? AND active = 1 ORDER BY hierarchy\";\n\t\tif( $all )\n\t\t $query = \"SELECT * FROM \".cms_db_prefix().\"content WHERE parent_id = ? ORDER BY hierarchy\";\n\t\t$contentrows =& $db->GetArray($query, array($id));\n\t\t$contentprops = '';\n\n\t\t// get the content ids from the returned data\n\t\tif( $loadprops )\n\t\t {\n\t\t $child_ids = array();\n\t\t for( $i = 0; $i < count($contentrows); $i++ )\n\t\t {\n\t\t\t$child_ids[] = $contentrows[$i]['content_id'];\n\t\t }\n\t\t \n\t\t // get all the properties for the child_ids\n\t\t $query = 'SELECT * FROM '.cms_db_prefix().'content_props WHERE content_id IN ('.implode(',',$child_ids).') ORDER BY content_id';\n\t\t $tmp =& $db->GetArray($query);\n\n\t\t // re-organize the tmp data into a hash of arrays of properties for each content id.\n\t\t if( $tmp )\n\t\t {\n\t\t\t$contentprops = array();\n\t\t\tfor( $i = 0; $i < count($contentrows); $i++ )\n\t\t\t {\n\t\t\t $content_id = $contentrows[$i]['content_id'];\n\t\t\t $t2 = array();\n\t\t\t for( $j = 0; $j < count($tmp); $j++ )\n\t\t\t {\n\t\t\t\tif( $tmp[$j]['content_id'] == $content_id )\n\t\t\t\t {\n\t\t\t\t $t2[] = $tmp[$j];\n\t\t\t\t }\n\t\t\t }\n\t\t\t $contentprops[$content_id] = $t2;\n\t\t\t }\n\t\t }\n\t\t }\n\t\t\n\t\t// build the content objects\n\t\tfor( $i = 0; $i < count($contentrows); $i++ )\n\t\t {\n\t\t $row =& $contentrows[$i];\n\t\t $id = $row['content_id'];\n\n\t\t if (!in_array($row['type'], array_keys(ContentOperations::ListContentTypes()))) continue;\n\t\t $contentobj =& ContentOperations::CreateNewContent($row['type']);\n\t\t if ($contentobj)\n\t\t {\n\t\t\t$contentobj->LoadFromData($row, false);\n\t\t\tif( $loadprops && $contentprops && isset($contentprops[$id]) )\n\t\t\t {\n\t\t\t // load the properties from local cache.\n\t\t\t $props =& $contentprops[$id];\n\t\t\t $obj =& $contentobj->mProperties;\n\t\t\t $obj->mPropertyNames = array();\n\t\t\t $obj->mPropertyTypes = array();\n\t\t\t $obj->mPropertyValues = array();\n\t\t\t foreach( $props as $oneprop )\n\t\t\t {\n\t\t\t\t$obj->mPropertyNames[] = $oneprop['prop_name'];\n\t\t\t\t$obj->mPropertyTypes[$oneprop['prop_name']] = $oneprop['type'];\n\t\t\t\t$obj->mPropertyValues[$oneprop['prop_name']] = $oneprop['content'];\n\t\t\t }\n\t\t\t $contentobj->mPropertiesLoaded = true;\n\t\t\t }\n\n\t\t\t// cache the content objects\n\t\t\t$contentcache =& $tree->content;\n\t\t\t$contentcache[$id] =& $contentobj;\n\t\t }\n\t\t }\n\t}", "protected function processFileTree () {\n\t\t$files = $this->populateFileTree();\n\t\tforeach ($files as $file) {\n\t\t\t$this->processFile($file);\n\t\t}\n\t}", "public function loadAll()\n {\n $this->setAll(array());\n $d = dir($this->getPath());\n $this->load($d);\n $d->close();\n }", "abstract protected function loadFiletree(DataContainerInterface $objDc);", "public function __invoke() {\n\t\t// Register hooks for the group if part of group\n\t\tif ( null !== $this->group ) {\n\t\t\t$this->group->load( $this->group, $this->page );\n\t\t}\n\n\t\t$this->page->load( $this->page );\n\t}", "function InitChildControls() {\n }", "function InitControl($data=array()){\n $_page_id=$this->Page->Request->globalValue(\"_page_id\");\n $menuFile=&ConfigFile::GetInstance(\"menuIni\",$this->Page->Kernel->Settings->GetItem(\"module\",\"ResourcePath\").$data[\"file\"]);\n $this->parent_field_name=\"parentid\";\n $this->caption_field_name=\"caption\";\n $this->image_field_name=\"image\";\n $this->key_field_name=\"id\";\n\t\t\t$this->url_name=\"url\";\n $this->root=$data[\"root\"];\n $this->onelevel=$data[\"onelevel\"];\n //create menu structure\n $i=1;\n $currentid=0;\n foreach ($menuFile->Sections as $name => $section) {\n $section[\"id\"] = $i;\n $section[\"parentid\"] = 0;\n $section[\"caption\"] = $section[sprintf(\"name_%s\",$this->Page->Kernel->Language)];\n $section[\"image\"] = $section[\"image\"];\n $i++;\n if ($menuFile->HasItem($name,\"parent\")) {\n $parentname=strtolower($menuFile->GetItem($name,\"parent\"));\n $section[\"parentid\"]=$sections[$parentname][\"id\"];\n }\n //search in array current url\n if (!is_array($section[\"url\"]))\n $section[\"url\"]=array($section[\"url\"]);\n if (in_array($this->Page->PageURI,$section[\"url\"]) || $section[\"page_id\"]==$_page_id) $currentid=$section[\"id\"];\n $section[\"url\"]=$section[\"url\"][0];\n $sections[$name]=$section;\n }\n $this->data[\"selected_value\"]=$currentid;\n foreach($sections as $name => $section) $this->_list[]=$section;\n }", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "public function traverse(): void\n {\n // Register data hooks on the table\n $this->registerHandlerDefinitions($this->definition->tableName, $this->definition->tca);\n \n // Register data hooks on the types and fields\n $this->traverseTypes();\n $this->traverseFields();\n \n // Allow externals\n $this->eventBus->dispatch(new CustomDataHookTraverserEvent($this->definition, function () {\n $this->registerHandlerDefinitions(...func_get_args());\n }));\n }", "public function loadChildNodes()\n {\n $ids = $this->_cache->getBackend()->getChildNodeIds($this);\n return $this->setChildNodeIds($ids);\n }", "public function calc_tree()\n\t{\n\t\t$this->readTree(TRUE);\t\t\t// Make sure we have accurate data\n\t\tforeach ($this->class_parents as $cp)\n\t\t{\n\t\t\t$rights = array();\n\t\t\t$this->rebuild_tree($cp,$rights);\t\t// increasing rights going down the tree\n\t\t}\n\t}", "public function iterateChildren();", "abstract public function loadAll();", "protected function postLoad(){\n\t\t\t\n\t\t}", "function showHierarchy()\n\t{\n\t\tglobal $lng, $ilCtrl;\n\t\t\n\t\t$this->setTabs();\n\t\t\n\t\t$ilCtrl->setParameter($this, \"backcmd\", \"showHierarchy\");\n\t\t\n\t\tinclude_once(\"./Modules/LearningModule/classes/class.ilChapterHierarchyFormGUI.php\");\n\t\t$form_gui = new ilChapterHierarchyFormGUI($this->content_object->getType(), $_GET[\"transl\"]);\n\t\t$form_gui->setFormAction($ilCtrl->getFormAction($this));\n\t\t$form_gui->setTitle($this->obj->getTitle());\n\t\t$form_gui->setIcon(ilUtil::getImagePath(\"icon_st.svg\"));\n\t\t$form_gui->setTree($this->tree);\n\t\t$form_gui->setCurrentTopNodeId($this->obj->getId());\n\t\t$form_gui->addMultiCommand($lng->txt(\"delete\"), \"delete\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"cut\"), \"cutItems\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"copy\"), \"copyItems\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"cont_de_activate\"), \"activatePages\");\n\t\tif ($this->content_object->getLayoutPerPage())\n\t\t{\t\n\t\t\t$form_gui->addMultiCommand($lng->txt(\"cont_set_layout\"), \"setPageLayout\");\n\t\t}\n\t\t$form_gui->setDragIcon(ilUtil::getImagePath(\"icon_pg.svg\"));\n\t\t$form_gui->addCommand($lng->txt(\"cont_save_all_titles\"), \"saveAllTitles\");\n\t\t$form_gui->addHelpItem($lng->txt(\"cont_chapters_after_pages\"));\n\t\t$up_gui = ($this->content_object->getType() == \"dbk\")\n\t\t\t? \"ilobjdlbookgui\"\n\t\t\t: \"ilobjlearningmodulegui\";\n\t\t$ilCtrl->setParameterByClass($up_gui, \"active_node\", $this->obj->getId());\n\t\t$ilCtrl->setParameterByClass($up_gui, \"active_node\", \"\");\n\n\t\t$ctpl = new ilTemplate(\"tpl.chap_and_pages.html\", true, true, \"Modules/LearningModule\");\n\t\t$ctpl->setVariable(\"HIERARCHY_FORM\", $form_gui->getHTML());\n\t\t$ilCtrl->setParameter($this, \"obj_id\", $_GET[\"obj_id\"]);\n\t\t\n\t\tinclude_once(\"./Modules/LearningModule/classes/class.ilObjContentObjectGUI.php\");\n\t\t$ml_head = ilObjContentObjectGUI::getMultiLangHeader($this->content_object->getId(), $this);\n\t\t\n\t\t$this->tpl->setContent($ml_head.$ctpl->get());\n\t}", "protected function _preloadContainerData()\r\n\t{\r\n\t\t$this->preloadTemplate('page_nav');\r\n\t}", "function load ()\n {\n $this->relationships = parent::_load ( $this->basepath ) ;\n }", "protected function buildRenderChildrenClosure() {}", "public function loadTree($par = 1){\r\n\t\t$user = new Table_Users();\r\n\t\t// load the user data\r\n\t\t$userData = $user->getDataById($_SESSION['userId']);\r\n\t\t//get the role id\r\n\t\t$role_id = $userData->role_id;\r\n\t\t// load the tree\r\n\t\techo $this->getChildrens($par, $role_id);\r\n\t}", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "function ProcessMultilevel()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::ProcessMultilevel();\" . \"<HR>\";\n if ($this->listSettings->HasItem(\"MAIN\", \"PARENT_FIELD\")) {\n $this->parent_field = $this->listSettings->GetItem(\"MAIN\", \"PARENT_FIELD\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_PARENTFIELD_SETTINGS\", array(), true);\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"USE_SUB_CATEGORIES\")) {\n $this->use_sub_categories = $this->listSettings->GetItem(\"MAIN\", \"USE_SUB_CATEGORIES\");\n }\n else {\n $this->use_sub_categories = 0;\n }\n if ($this->use_sub_categories) {\n $this->ProcessMultilevelSubCategories();\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_MEGA_DELETE\")) {\n $this->mega_delete = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_MEGA_DELETE\");\n }\n else {\n $this->mega_delete = 0;\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_NODE_MOVE\")) {\n $this->node_move = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_NODE_MOVE\");\n }\n else {\n $this->node_move = 0;\n }\n\n }", "private function loadSubWidgets()\n {\n $subWidgets = [];\n // get widgets for the fields\n foreach ($this->fields as $index => $field) :\n $subWidgets[$index] = $field->widget;\n endforeach;\n\n $this->widget->setSubWidgets($subWidgets);\n }", "abstract protected function getCurrentChildren(): array ;", "protected function loadParentId(){return 0;}", "public function load() {\r\n\t\t$this->includes();\r\n\t\t$this->inits();\r\n\t}", "protected function loadObjects() {\n if (!isset($this->objects)) {\n $this->obj_builder->toggleAutoload('on');\n $this->objects = $this->obj_builder->buildObjects();\n $this->obj_builder->toggleAutoload('off');\n }\n }", "function &GetAllContentAsHierarchy($loadprops, $onlyexpanded=null, $loadcontent = false)\n\t{\n\t\tdebug_buffer('', 'starting tree');\n\n\t\trequire_once(dirname(dirname(__FILE__)).'/Tree/Tree.php');\n\n\t\t$nodes = array();\n\t\tglobal $gCms;\n\t\t$db = &$gCms->GetDb();\n\n\t\t$cachefilename = TMP_CACHE_LOCATION . '/contentcache.php';\n\t\t$usecache = true;\n\t\tif (isset($onlyexpanded) || isset($CMS_ADMIN_PAGE))\n\t\t{\n\t\t\t#$usecache = false;\n\t\t}\n\n\t\t$loadedcache = false;\n\n\t\tif ($usecache)\n\t\t{\n\t\t\tif (isset($gCms->variables['pageinfo']) && file_exists($cachefilename))\n\t\t\t{\n\t\t\t\t$pageinfo =& $gCms->variables['pageinfo'];\n\t\t\t\t//debug_buffer('content cache file exists... file: ' . filemtime($cachefilename) . ' content:' . $pageinfo->content_last_modified_date);\n\t\t\t\tif (isset($pageinfo->content_last_modified_date) && $pageinfo->content_last_modified_date < filemtime($cachefilename))\n\t\t\t\t{\n\t\t\t\t\tdebug_buffer('file needs loading');\n\n\t\t\t\t\t$handle = fopen($cachefilename, \"r\");\n\t\t\t\t\t$data = fread($handle, filesize($cachefilename));\n\t\t\t\t\tfclose($handle);\n\n\t\t\t\t\t$tree = unserialize(substr($data, 16));\n\n\t\t\t\t\t#$variables =& $gCms->variables;\n\t\t\t\t\t#$variables['contentcache'] =& $tree;\n\t\t\t\t\tif (strtolower(get_class($tree)) == 'tree')\n\t\t\t\t\t{\n\t\t\t\t\t\t$loadedcache = true;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$loadedcache = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!$loadedcache)\n\t\t{\n\t\t\t$query = \"SELECT id_hierarchy FROM \".cms_db_prefix().\"content ORDER BY hierarchy\";\n\t\t\t$dbresult =& $db->Execute($query);\n\n\t\t\tif ($dbresult && $dbresult->RecordCount() > 0)\n\t\t\t{\n\t\t\t\twhile ($row = $dbresult->FetchRow())\n\t\t\t\t{\n\t\t\t\t\t$nodes[] = $row['id_hierarchy'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$tree = new Tree();\n\t\t\tdebug_buffer('', 'Start Loading Children into Tree');\n\t\t\t$tree = Tree::createFromList($nodes, '.');\n\t\t\tdebug_buffer('', 'End Loading Children into Tree');\n\t\t}\n\n\t\tif (!$loadedcache && $usecache)\n\t\t{\n\t\t\tdebug_buffer(\"Serializing...\");\n\t\t\t$handle = fopen($cachefilename, \"w\");\n\t\t\tfwrite($handle, '<?php return; ?>'.serialize($tree));\n\t\t\tfclose($handle);\n\t\t}\n\n\t\tif( $loadcontent )\n\t\t {\n\t\t ContentOperations::LoadChildrenIntoTree(-1, $tree, false, true);\n\t\t }\n\n\t\tdebug_buffer('', 'ending tree');\n\n\t\treturn $tree;\n\t}", "protected function resolveChildren()\n {\n foreach ($this->unresolvedChildren as $name => $info) {\n $this->children[$name] = $this->create($name, $info['type'], $info['init_options'], $info['exec_options']);\n }\n\n $this->unresolvedChildren = array();\n }", "public function all_deps($handles, $recursion = \\false, $group = \\false)\n {\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "public function get_children();", "function populate() {\n $this->populateInputElements($this->children);\n }", "protected function loadFiles() {\n if ($this->loaded === true) {\n return;\n }\n $iter = new RecursiveDirectoryIterator($this->directory);\n $this->iterateFiles($iter);\n $this->loaded = true;\n }", "public function doLoad()\n {\n $this->DataSourceInstance->doLoad();\n }", "public function load() {\n $this->loadModules($this->dir['modules_core'], 'core');\n $this->loadModules($this->dir['modules_custom'], 'custom');\n $this->runModules();\n }", "protected function collectChildren(): void\n {\n $this->collection = new Collection();\n foreach ($this->rawResults as $blockChildContent) {\n $this->collection->add(Block::fromResponse($blockChildContent));\n }\n }", "private function inherit()\n\t{\n\t\t$this->log(1, '...Computing inheritance(s?)');\n\t\tforeach($this->_classes as $class_name => $class_def)\n\t\t{\n\t\t\t$this->log(2,\"For Class $class_name\");\n\t\t\t$parent_name = $class_def->get_parent_class_name();\n\t\t\tif(!empty($parent_name))\n\t\t\t{\n\t\t\t\t$this->log(2, \" parent = \".$parent_name);\n\t\t\t\t$parent_def = &$this->_classes[$parent_name];\n\t\t\t\t$parent_def->_children[] = $class_def;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->log(2, \" no parent\");\n\t\t\t\t$_top_classes[] = $class_def;\n\t\t\t}\n\t\t}\n\t\t\n\t\tforeach($_top_classes as $top_class)\n\t\t{\n\t\t\t$this->traverse_class_hierarchy($top_class);\n\t\t}\t\t\n\t}", "function ControlOnLoad(){\n parent::ControlOnLoad();\n }", "private function parse()\n {\n $this->parseChildrenNodes($this->_dom, $this->_rootNode);\n }", "public function getChildren() {}", "public function getChildren() {}", "public function getChildren() {}", "function init()\r\n {\r\n //Copy components to comps, so you can alter components properties\r\n //on init() methods\r\n $comps=$this->components->items;\r\n //Calls children's init recursively\r\n reset($comps);\r\n while (list($k,$v)=each($comps))\r\n {\r\n $v->init();\r\n }\r\n }", "public function load(): void\n {\n if ($this->paths->isEmpty()) {\n return;\n }\n\n foreach ((new Finder)->in($this->paths->toArray())->files() as $file) {\n $this->loadAction(\n $this->getClassnameFromPathname($file->getPathname())\n );\n }\n }", "public function load()\n {\n if( $this->autoload ) {\n $loader = new BasePathClassLoader( $this->paths );\n $loader->useEnvPhpLib();\n $loader->register();\n }\n\n foreach( $this->paths as $path ) {\n $di = new RecursiveDirectoryIterator($path);\n $ita = new RecursiveIteratorIterator($di);\n $regex = new RegexIterator($ita, '/^.+\\.php$/i', \n RecursiveRegexIterator::GET_MATCH);\n\n foreach( $regex as $matches ) foreach( $matches as $match ) {\n try {\n require_once $match;\n } \n catch ( Exception $e ) {\n echo \"$match class load failed.\\n\";\n }\n }\n }\n }", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "public function initializeChildren() {\n\t\tif ($this->initialized === TRUE) {\n\t\t\treturn;\n\t\t}\n\t\t/** @var \\TYPO3\\CMS\\Core\\Resource\\Folder $folder */\n\t\t$subFolders = $this->folder->getSubfolders();\n\t\tforeach ($subFolders as $folder) {\n\t\t\t$f = new Storage($this->mapFolderIdToEntityName($folder->getName()), array());\n\t\t\t$f->setStorage($this->storage);\n\t\t\t$f->setFolder($folder);\n\t\t\t$this->addChild($f);\n\t\t}\n\n\t\t$files = $this->folder->getFiles();\n\t\tforeach ($files as $file) {\n\t\t\t$f = new File();\n\t\t\t$f->setFalFileObject($file);\n\t\t\t$this->addChild($f);\n\t\t}\n\t\t$this->initialized = TRUE;\n\t}", "function get_child_nodes_row_control($categoryID, $category_structure, $level, $current_category_id, $user_id, $control = false, $data_structure, $params = array())\n {\n $rs = '';\n if (!isset($category_structure['childs'][$categoryID]) || !is_array($category_structure['childs'][$categoryID])) {\n return '';\n }\n\n\n if (count($params) > 0) {\n $add_url = '&' . implode('&', $params);\n }\n\n foreach ($category_structure['childs'][$categoryID] as $child_id) {\n\n\n if ((0 != $this->getConfigValue('hide_empty_catalog')) and (0 == $data_structure['data'][$user_id][$child_id])) {\n $rs .= '';\n } else {\n\n if ($current_category_id == $child_id) {\n $selected = \" selected \";\n } else {\n $selected = \"\";\n }\n $this->j++;\n if (ceil($this->j / 2) > floor($this->j / 2)) {\n $row_class = \"row1\";\n } else {\n $this->j = 0;\n $row_class = \"row2\";\n }\n\n //print_r($category_structure['catalog'][$child_id]);\n //print_r($data_structure['data'][$user_id]);\n //echo \"category_id = $child_id, count = \".$data_structure['data'][$user_id][$child_id].'<br>';\n $rs .= '<tr>';\n\n if ($child_id == $current_category_id) {\n $row_class = 'active';\n }\n $rs .= '<td class=\"' . $row_class . '\"><a href=\"?topic_id=' . $child_id . '' . $add_url . '\">' . str_repeat('&nbsp;.&nbsp;', $level) . $category_structure['catalog'][$child_id]['name'] . '</a> (' . (int)$data_structure['data'][$user_id][$child_id] . ')' . ' <small>id:' . $child_id . '</small></td>';\n if ($control) {\n $edit_icon = '<a href=\"?action=structure&do=edit&id=' . $child_id . '\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/edit.png\" border=\"0\" alt=\"редактировать\" title=\"редактировать\"></a>';\n $delete_icon = '<a href=\"?action=structure&do=delete&id=' . $child_id . '\" onclick=\"if ( confirm(\\'' . Multilanguage::_('L_MESSAGE_REALLY_WANT_DELETE') . '\\') ) {return true;} else {return false;}\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/delete.png\" border=\"0\" width=\"16\" height=\"16\" alt=\"удалить\" title=\"удалить\"></a>';\n }\n\n //$rs .= '<td class=\"'.$row_class.'\">'.$this->get_operation_type_name_by_id($category_structure['catalog'][$child_id]['operation_type_id']).'</td>';\n if ($control) {\n $rs .= '<td class=\"' . $row_class . '\">' . $edit_icon . $delete_icon . '</td>';\n }\n\n $rs .= '</tr>';\n //$rs .= '<option value=\"'.$child_id.'\" '.$selected.'>'.str_repeat(' . ', $level).$category_structure['catalog'][$child_id]['name'].'</option>';\n //print_r($category_structure['childs'][$child_id]);\n if (isset($category_structure['childs'][$child_id]) && count($category_structure['childs'][$child_id]) > 0) {\n $rs .= $this->get_child_nodes_row_control($child_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n }\n }\n return $rs;\n }", "function AddControl(&$object) {\n if (!is_object($object)) {\n return;\n }\n //if (is_object($object->Parent))\n //$object->Parent->RemoveControl($object);\n $object->Parent = &$this;\n $object->Page = &$this->Page;\n @$this->Controls[$object->Name] = &$object;\n if ($this->_state >= WEB_CONTROL_INITIALIZED) {\n $object->initRecursive();\n if ($this->_state >= WEB_CONTROL_LOADED)\n $object->loadRecursive();\n }\n }", "protected function loadSubQueries()\n {\n foreach ($this->subQueries as $subQuery) {\n $subQuery($this->tableQuery);\n }\n }", "public function process()\n\t{\t\n\t\tif ($iDeleteId = $this->request()->getInt('delete'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->delete($iDeleteId))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', null, Phpfox::getPhrase('admincp.menu_successfully_deleted'));\t\n\t\t\t}\n\t\t}\n\t\t\n\t\tif ($aVals = $this->request()->getArray('val'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->updateOrder($aVals))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', array('parent' => $this->request()->getInt('parent')), Phpfox::getPhrase('admincp.menu_order_successfully_updated'));\t\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t$iParentId = $this->request()->getInt('parent');\t\t\n\t\tif ($iParentId > 0)\n\t\t{\n\t\t\t$aMenu = Phpfox::getService('admincp.menu')->getForEdit($iParentId);\n\t\t\tif (isset($aMenu['menu_id']))\n\t\t\t{\n\t\t\t\t$this->template()->assign('aParentMenu', $aMenu);\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$iParentId = 0;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$aTypes = Phpfox::getService('admincp.menu')->getTypes();\n\t\t$aRows = Phpfox::getService('admincp.menu')->get(($iParentId > 0 ? array('menu.parent_id = ' . (int) $iParentId) : array('menu.parent_id = 0')));\n\t\t$aMenus = array();\n\t\t$aModules = array();\n\t\t\n\t\tforeach ($aRows as $iKey => $aRow)\n\t\t{\n\t\t\tif(Phpfox::isModule($aRow['module_id']))\n\t\t\t{\n\t\t\t\tif (!$iParentId && in_array($aRow['m_connection'], $aTypes))\n\t\t\t\t{\n\t\t\t\t\t$aMenus[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tif ($aRow['m_connection'] == 'mobile' || $aRow['m_connection'] == 'main_right') {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$aModules[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\t\t\t\n\t\t\t}\n\t\t}\n\t\tunset($aRows);\t\t\n\t\n\t\t$this->template()\n\t\t\t->setBreadCrumb('CMS', '#cms')\n\t\t\t->setBreadcrumb('Menus', $this->url()->makeUrl('admincp.menu'), true)\n\t\t\t->setTitle('Menus')\n\t\t\t->assign(array(\n\t\t\t\t'aMenus' => $aMenus,\n\t\t\t\t'aModules' => $aModules,\n\t\t\t\t'iParentId' => $iParentId\n\t\t\t)\n\t\t);\n\t}", "protected function _Load_Pages() {\r\n $dir = untrailingslashit( plugin_dir_path(__FILE__ ) );\r\n // Recurssively load the directory\r\n $this->_Recusive_Load_Dir($dir.'/pages');\r\n // Fire the shortcode init action\r\n do_action('vcff_supports_pages_init',$this);\r\n }", "public function postLoad() { }", "protected function handleLoad()\n\t{\n\n\t\t/*\n\t\t*\tif safe mode or open_basedir is set, skip to using file_get_contents\n\t\t*\t(fixes \"CURLOPT_FOLLOWLOCATION cannot be activated\" curl_setopt error)\n\t\t*/\n\t\tif(ini_get('safe_mode') || ini_get('open_basedir'))\n\t\t{\n\t\t\t// do nothing (will pass on to getPafeFile/get_file_contents as isset($curlHtml) will fail)\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// load the page\n\t\t\t$this->getPageCurl();\n\n\t\t\t// parse the returned html for the data we want\n\t\t\t$curlHtml = $this->parseHtml();\n\t\t}\n\n\t\t// see if curl managed to get data\n\t\t// if not, try with get_file_contents\n\t\tif (isset($curlHtml) && !empty($curlHtml['name']) && !empty($curlHtml['count']) && !empty($curlHtml['img']))\n\t\t{\n\t\t\treturn $curlHtml;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// try loading with file_get_contents instead\n\t\t\t$this->getPageFile();\n\n\t\t\t// parse\n\t\t\t$data = $this->parseHtml();\n\n\t\t\t// return\n\t\t\treturn $data;\n\t\t}\n\n\t}", "protected function process_load($data)\n\t{\n\t\t$parsed_data = array();\n\t\tforeach ($data as $key => $value)\n\t\t{\n\t\t\tif (strpos($key, ':'))\n\t\t\t{\n\t\t\t\tlist($table, $field) = explode(':', $key);\n\t\t\t\tif ($table == $this->_table_name)\n\t\t\t\t{\n\t\t\t\t\t$parsed_data[$field] = $value;\n\t\t\t\t}\n\t\t\t\telseif ($field)\n\t\t\t\t{\n\t\t\t\t\t$this->_lazy[inflector::singular($table)][$field] = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$parsed_data[$key] = $value;\n\t\t\t}\n\t\t}\n\t\t$this->_data = $parsed_data;\n\t}", "function CreateChildControls() {\n }", "public function reorderChildren()\n {\n $sql = \"select ID_PAGE from \" . $this->mode . \"PAGE where PAG_IDPERE=\" . $this->getID() . \" order by PAG_POIDS\";\n $stmt = $this->dbh->prepare(\"update \" . $this->mode . \"PAGE set PAG_POIDS=:PAG_POIDS where ID_PAGE=:ID_PAGE\");\n $PAG_POIDS = 1;\n $stmt->bindParam(':PAG_POIDS', $PAG_POIDS, PDO::PARAM_INT);\n foreach ($this->dbh->query($sql)->fetchAll(PDO::FETCH_COLUMN) as $ID_PAGE) {\n $stmt->bindValue(':ID_PAGE', $ID_PAGE, PDO::PARAM_INT);\n $stmt->execute();\n $PAG_POIDS ++;\n }\n }", "public function postLoad() {}", "function children() {\n\t\t$this->load_children();\n\t\treturn $this->_children;\n\t}", "public function loadAllClassesIncrementally()\n {\n }", "public function _load()\n {\n $query = new Query(\n \"SELECT *\n FROM `\" . Leder::TABLE . \"`\n WHERE `arrangement_fra` = '#fra'\n AND `arrangement_til` = '#til'\",\n [\n 'fra' => $this->getArrangementFraId(),\n 'til' => $this->getArrangementTilId()\n ]\n );\n\n $res = $query->getResults();\n while( $row = Query::fetch($res) ) {\n $this->add(\n Leder::loadFromDatabaseRow( $row )\n );\n }\n }", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public static function loadAll();", "function display_node($parent, $level) {\n global $tam1;\n $tam2=array();\n global $leafnodes; \n global $responce;\n if($parent >0) {\n foreach ($tam1 as $row){\n\t if($row['ID_Parent']==$parent){\n\t\t $tam2[]=$row;\n\t }\n }\n } else {\n \n\t foreach ($tam1 as $row){\n\t if($row['ID_Parent']==''){\n\t\t $tam2[]=$row;\n\t }\n }\n }\n\n foreach ($tam2 as $row) {\n\tif(!$row['ID_Parent']) $valp = 'NULL'; else $valp = $row['ID_Parent'];\t\n\t//kiem tra node co phai lead\n\tif(array_key_exists($row['ID_Control'], $leafnodes)) $leaf='true'; else $leaf = 'false';\t\n\t$responce[] = array('ID_Control' => $row[\"ID_Control\"], 'ID_Parent' => $row[\"ID_Parent\"], 'Caption' => $row[\"Caption\"],'KieuControl' => $row[\"KieuControl\"],'IsBarButton' => $row[\"IsBarButton\"] ,'Icon' =>$row[\"Icon\"],'Active' =>$row[\"Active\"],'STT' =>$row[\"STT\"],'PageOpen' =>$row[\"PageOpen\"],'OpenType' =>$row[\"OpenType\"],'TenControl' =>$row[\"TenControl\"] , 'level' => $level, 'parent' => $valp, 'isLeaf' => $leaf, 'expanded' => \"true\", 'loaded' => \"true\");\n\t\n\t display_node($row['ID_Control'],$level+1);\n\t \n\t} \n \n return $responce;\n \n}", "function dumpChildrenJavascript()\r\n {\r\n //Iterates through components, dumping all javascript\r\n $this->dumpJavascript();\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n if ($v->inheritsFrom('Control'))\r\n {\r\n if ($v->canShow())\r\n {\r\n $v->dumpJavascript();\r\n }\r\n }\r\n else $v->dumpJavascript();\r\n }\r\n }", "protected function loadStructure(DataContainerInterface $objDc)\n\t{\n\t\t// Method ajaxTreeView is in TreeView.php - watch out!\n\t\techo $objDc->ajaxTreeView($this->getAjaxId(), intval(self::getPost('level')));\n\t\texit;\n\t}", "public function afterLoad(){\n $this->getType()->afterLoadProcess($this);\n return parent::afterLoad();\n }", "public function run() {\n $this->load_dependencies();\n $this->load_localization();\n $this->load_admin();\n $this->load_public();\n }", "abstract protected function reloadPagetree(DataContainerInterface $objDc);", "function SetTreeData($data){\n $this->InitControl($data);\n\n }", "function renderChildrenOf($pa, $root = null, $output = '', $level = 0) {\n if(!$root) $root = wire(\"pages\")->get(1);\n $output = '';\n $level++;\n foreach($pa as $child) {\n $class = '';\n $has_children = ($child->id == \"1018\" || $child->id == \"1263\" || count($child->children('include=all'))) ? true : false;\n\n if($has_children && $child !== $root) {\n if($level == 1){\n $class .= 'parent'; // first level boostrap dropdown li class\n //$atoggle .= ' class=\"dropdown-toggle\" data-toggle=\"dropdown\"'; // first level anchor attributes\n }\n }\n\n // make the current page and only its first level parent have an active class\n if($child === wire(\"page\") && $child !== $root){\n $class .= ' active';\n } else if($level == 1 && $child !== $root){\n if($child === wire(\"page\")->rootParent || wire(\"page\")->parents->has($child)){\n $class .= ' active';\n }\n }\n\n $class = strlen($class) ? \" class='\".trim($class).\"'\" : '';\n if($child->menu_item_url) {$childlink = $child->menu_item_url; } else { $childlink = $child->url; }\n $output .= \"<li$class><a href='$childlink'>$child->title</a>\";\n\n // If this child is itself a parent and not the root page, then render its children in their own menu too...\n \n if($has_children && $child !== $root) {\n \n // check for special menu items\n if ($child->id == \"1263\") { //services main item\n\n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n \n // promo\n $output .= '<div class=\"col3\">';\n $output .= '<h4 class=\"megamenu-col-title\">Promotional Offer:</h4>';\n $output .= '<a href=\"#\"><img src=\"http://placehold.it/270x244\" alt=\"\"></a>';\n $output .= '</div>';\n // end promo\n \n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('General');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Cosmetic Dentistry');\n $output .= megaMenuServicesList('Dental Restorations');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Specialty');\n $output .= '</div>';\n // end third column\n\n $output .= '</div></div>';\n }elseif ($child->id == \"1018\") {// blog main menu item\n \n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n\n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('general-dentistry');\n $output .= megaMenuBlogCatList('sleep-apnea-snoring');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('cosmetic-dentistry');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('childrens-dentistry');\n $output .= '</div>';\n // end third column\n\n // dourth column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('sedation-dentistry'); \n $output .= megaMenuBlogCatList('restorations');\n $output .= '</div>';\n // end dourth column\n\n $output .= '</div></div>';\n \n }else {// default case for all other menu items\n\n $output .= renderChildrenOf($child->children('include=all'), $root, $output, $level);\n\n }\n }\n $output .= '</li>';\n\n\n }\n $outerclass = ($level == 1) ? \"menuzord-menu\" : 'dropdown';\n return \"<ul class='$outerclass'>$output</ul>\";\n}", "function admin_preload ()\n\t{\n\t\t$this->CI->admin_navigation->child_link('configuration',65,'phpBB3',site_url('admincp/phpbb'));\n\t}", "function loadSubModules()\n{\n $debug_prefix = debug_indent(\"Module->loadSubModules() {$this->ModuleID}:\");\n $submodule_elements = $this->_map->selectChildrenOfFirst('SubModules', null, null, true, true);\n if(count($submodule_elements) > 0){\n foreach($submodule_elements as $submodule_element){\n $submodule = $submodule_element->createObject($this->ModuleID);\n $subModuleID = $submodule_element->getAttr('moduleID', true);\n $this->SubModules[$subModuleID] = $submodule;\n print \"$debug_prefix Submodule $subModuleID parsed.\\n\";\n unset($submodule);\n }\n\n //special for best practices: add the IsBestPractice SummaryField\n if(isset($this->SubModules['bpc'])){\n $this->useBestPractices = true;\n $recordIDField = end($this->PKFields);\n\n $field_object = MakeObject(\n $this->ModuleID,\n 'IsBestPractice',\n 'SummaryField',\n array(\n 'name' => 'IsBestPractice',\n 'type' => 'tinyint',\n 'summaryFunction' => 'count',\n 'summaryField' => 'BestPracticeID',\n 'summaryKey' => 'RelatedRecordID',\n 'summaryModuleID' => 'bpc',\n 'localKey' => $recordIDField,\n 'phrase' => 'Is Best Practice|Whether the associated record is a best practice'\n )\n );\n//print \"best practice auto field\";\n//print_r($field_object);\n//die();\n $this->ModuleFields['IsBestPractice'] = $field_object;\n }\n\n //copies submodule conditions to summary fields\n foreach($this->ModuleFields as $fieldName => $field){\n if('summaryfield' == strtolower(get_class($field))){\n if(!$field->isGlobal){\n\n if(isset($this->SubModules[$field->summaryModuleID])){\n $subModule =& $this->SubModules[$field->summaryModuleID];\n if(count($subModule->conditions) > 0){\n //$field->conditions = $subModule->conditions;\n $field->conditions = array_merge($subModule->conditions, (array)$field->conditions);\n $this->ModuleFields[$fieldName] = $field;\n }\n unset($subModule);\n } else {\n trigger_error(\"The summaryfield '{$field->name}' requires a '{$field->summaryModuleID}' submodule.\", E_USER_ERROR);\n }\n }\n }\n }\n }\n debug_unindent();\n}", "private function parse_directory_tree()\r\n {\r\n foreach ($this->tc_step_data_list as $tc_index => $testcase_node)\r\n {\r\n $first_level = $testcase_node->get_first_level();\r\n $first_id = null;\r\n $second_level = $testcase_node->get_second_level();\r\n $second_id = null;\r\n $third_level = $testcase_node->get_third_level();\r\n $third_id = null;\r\n $fourth_level = $testcase_node->get_fourth_level();\r\n $fourth_id = null;\r\n $fifth_level = $testcase_node->get_fifth_level();\r\n $fifth_id = null;\r\n \r\n if ($first_level != null && $first_level != \"\" && trim($first_level) != \"\")\r\n {\r\n $first_id = $this->parse_directory_level(1, $first_level, \r\n $tc_index, $testcase_node, null);\r\n }\r\n \r\n if ($second_level != null && $second_level != \"\" && trim($second_level) != \"\")\r\n {\r\n $second_id = $this->parse_directory_level(2, $second_level,\r\n $tc_index, $testcase_node, $first_id);\r\n }\r\n else \r\n {\r\n // no second level dic, means testcase in first dic\r\n $tc_parent = $this->directory_array[1][$first_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($third_level != null && $third_level != \"\" && trim($third_level) != \"\")\r\n {\r\n $third_id = $this->parse_directory_level(3, $third_level,\r\n $tc_index, $testcase_node, $second_id);\r\n }\r\n else\r\n {\r\n // no third level dic, means testcase in second dic\r\n $tc_parent = $this->directory_array[2][$second_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fourth_level != null && $fourth_level != \"\" && trim($fourth_level) != \"\")\r\n {\r\n $fourth_id = $this->parse_directory_level(4, $fourth_level,\r\n $tc_index, $testcase_node, $third_id);\r\n }\r\n else\r\n {\r\n // no fourth level dic, means testcase in third dic\r\n $tc_parent = $this->directory_array[3][$third_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fifth_level != null && $fifth_level != \"\" || trim($fifth_level) != \"\")\r\n {\r\n // the last level dic\r\n $fifth_id = $this->parse_directory_level(5, $fifth_level,\r\n $tc_index, $testcase_node, $fourth_id);\r\n $tc_parent = $this->directory_array[5][$fifth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n else\r\n {\r\n // no fifth level dic, means testcase in fourth dic\r\n $tc_parent = $this->directory_array[4][$fourth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n }\r\n }" ]
[ "0.7851746", "0.69309044", "0.65314066", "0.6447771", "0.61732817", "0.6093573", "0.6043107", "0.5980434", "0.590623", "0.57993656", "0.5759078", "0.5733826", "0.57306117", "0.5597951", "0.5541654", "0.55382365", "0.54745454", "0.5456345", "0.5449586", "0.538659", "0.5330207", "0.5323464", "0.5294042", "0.5278952", "0.524806", "0.52335185", "0.52265596", "0.522467", "0.52160645", "0.5199014", "0.5193998", "0.5190819", "0.51894665", "0.5184002", "0.51329017", "0.5129324", "0.5125764", "0.51203763", "0.5112283", "0.5109959", "0.5107036", "0.51024604", "0.50630015", "0.50591743", "0.5044124", "0.50427604", "0.50416416", "0.50362104", "0.5035509", "0.50141644", "0.5014005", "0.50119144", "0.5003512", "0.49936488", "0.498111", "0.4971034", "0.4964498", "0.4964498", "0.4964498", "0.49602622", "0.4959221", "0.49320233", "0.4924377", "0.4924377", "0.49025905", "0.48991603", "0.48940164", "0.48725587", "0.48671618", "0.48668572", "0.4856787", "0.4851587", "0.4850273", "0.48465765", "0.48406684", "0.48395208", "0.4838932", "0.48301625", "0.48272896", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48222473", "0.48205078", "0.48108944", "0.48055503", "0.4793632", "0.47889924", "0.47853068", "0.47852445", "0.47843048", "0.4783861", "0.47808808", "0.47798234", "0.47673398" ]
0.60770184
6
Method Processes recursive set of control data and all of it's children.
function initChildrenRecursive() { $this->initChildControls(); if ($this->HasControls()) { $keys = array_keys($this->Controls); $count = count($this->Controls); for ($i = 0; $i < $count; $i++) { @$control = &$this->Controls[$keys[$i]]; $control->initChildrenRecursive(); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "function ProcessMultilevel()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::ProcessMultilevel();\" . \"<HR>\";\n if ($this->listSettings->HasItem(\"MAIN\", \"PARENT_FIELD\")) {\n $this->parent_field = $this->listSettings->GetItem(\"MAIN\", \"PARENT_FIELD\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_PARENTFIELD_SETTINGS\", array(), true);\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"USE_SUB_CATEGORIES\")) {\n $this->use_sub_categories = $this->listSettings->GetItem(\"MAIN\", \"USE_SUB_CATEGORIES\");\n }\n else {\n $this->use_sub_categories = 0;\n }\n if ($this->use_sub_categories) {\n $this->ProcessMultilevelSubCategories();\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_MEGA_DELETE\")) {\n $this->mega_delete = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_MEGA_DELETE\");\n }\n else {\n $this->mega_delete = 0;\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_NODE_MOVE\")) {\n $this->node_move = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_NODE_MOVE\");\n }\n else {\n $this->node_move = 0;\n }\n\n }", "protected function processFileTree () {\n\t\t$files = $this->populateFileTree();\n\t\tforeach ($files as $file) {\n\t\t\t$this->processFile($file);\n\t\t}\n\t}", "public function calc_tree()\n\t{\n\t\t$this->readTree(TRUE);\t\t\t// Make sure we have accurate data\n\t\tforeach ($this->class_parents as $cp)\n\t\t{\n\t\t\t$rights = array();\n\t\t\t$this->rebuild_tree($cp,$rights);\t\t// increasing rights going down the tree\n\t\t}\n\t}", "function SetTreeData($data){\n $this->InitControl($data);\n\n }", "function process_data($data) {\n // Implement in children classes\n }", "public function iterateChildren();", "public function traverse(): void\n {\n // Register data hooks on the table\n $this->registerHandlerDefinitions($this->definition->tableName, $this->definition->tca);\n \n // Register data hooks on the types and fields\n $this->traverseTypes();\n $this->traverseFields();\n \n // Allow externals\n $this->eventBus->dispatch(new CustomDataHookTraverserEvent($this->definition, function () {\n $this->registerHandlerDefinitions(...func_get_args());\n }));\n }", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "private function parse_directory_tree()\r\n {\r\n foreach ($this->tc_step_data_list as $tc_index => $testcase_node)\r\n {\r\n $first_level = $testcase_node->get_first_level();\r\n $first_id = null;\r\n $second_level = $testcase_node->get_second_level();\r\n $second_id = null;\r\n $third_level = $testcase_node->get_third_level();\r\n $third_id = null;\r\n $fourth_level = $testcase_node->get_fourth_level();\r\n $fourth_id = null;\r\n $fifth_level = $testcase_node->get_fifth_level();\r\n $fifth_id = null;\r\n \r\n if ($first_level != null && $first_level != \"\" && trim($first_level) != \"\")\r\n {\r\n $first_id = $this->parse_directory_level(1, $first_level, \r\n $tc_index, $testcase_node, null);\r\n }\r\n \r\n if ($second_level != null && $second_level != \"\" && trim($second_level) != \"\")\r\n {\r\n $second_id = $this->parse_directory_level(2, $second_level,\r\n $tc_index, $testcase_node, $first_id);\r\n }\r\n else \r\n {\r\n // no second level dic, means testcase in first dic\r\n $tc_parent = $this->directory_array[1][$first_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($third_level != null && $third_level != \"\" && trim($third_level) != \"\")\r\n {\r\n $third_id = $this->parse_directory_level(3, $third_level,\r\n $tc_index, $testcase_node, $second_id);\r\n }\r\n else\r\n {\r\n // no third level dic, means testcase in second dic\r\n $tc_parent = $this->directory_array[2][$second_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fourth_level != null && $fourth_level != \"\" && trim($fourth_level) != \"\")\r\n {\r\n $fourth_id = $this->parse_directory_level(4, $fourth_level,\r\n $tc_index, $testcase_node, $third_id);\r\n }\r\n else\r\n {\r\n // no fourth level dic, means testcase in third dic\r\n $tc_parent = $this->directory_array[3][$third_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fifth_level != null && $fifth_level != \"\" || trim($fifth_level) != \"\")\r\n {\r\n // the last level dic\r\n $fifth_id = $this->parse_directory_level(5, $fifth_level,\r\n $tc_index, $testcase_node, $fourth_id);\r\n $tc_parent = $this->directory_array[5][$fifth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n else\r\n {\r\n // no fifth level dic, means testcase in fourth dic\r\n $tc_parent = $this->directory_array[4][$fourth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n }\r\n }", "function initRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n @$control->Page = &$this->Page;\n $control->initRecursive();\n }\n }\n $this->_state = WEB_CONTROL_INITIALIZED;\n $this->ControlOnInit();\n }", "function _data_recurse($id, &$children,$list=array(), $maxlevel=9999, $level=0,$indent='',$data=array())\n {\n // pr($children);\n $id_parent=$id;\n if (@$children[$id] && $level <= $maxlevel)\n {\n $field_parent_id =$this->field_parent_id ; $fieldtitle=$this->field_parent_name; $fieldkey = $this->key;\n foreach ($children[$id] as $t)\n {\n //echo \"<br>Ifieldkey=\".$fieldkey;\n $id = $t->$fieldkey;\n $tmp = $t;\n //$tmp['children'] = count(@$children[$id]);\n\n //== Su ly parent\n /* $tmp->{'_parent'} =array();\n if($data && $id_parent > 0) {\n foreach($data as $p)\n if($p->$fieldkey == $id_parent)\n $tmp->{'_parent'} = $p;\n }*/\n //== Su ly sub\n $tmp->{'_subs'} = @$children[$id]?(@$children[$id]):array();\n $tmp->{'_sub_ids'} = array();\n if($tmp->{'_subs'}){\n //$sub_ids=array();\n foreach($tmp->{'_subs'} as $it)\n {\n $tmp->{'_sub_ids'}[]= $it->$fieldkey;\n }\n }\n $pre \t= '|-- '; $spacer = '&nbsp;&nbsp;&nbsp;&nbsp;';\n //$pre \t= ''; $spacer = '';\n //== Su ly hien thi moi lien he cha con\n if ($t->$field_parent_id == 0) {\n $txt \t= $t->$fieldtitle;\n } else {\n /*foreach($children as $key => $vs){\n foreach($vs as $v){\n if($t->$field_parent_id == $v->$fieldkey){\n $pre = $v->$fieldtitle.' >> ';\n break;\n }\n }\n if($pre) break;\n\n }*/\n $txt \t= $pre . $t->$fieldtitle;\n }\n $tmp->{'_'.$this->field_name} = \"$indent$txt\";// add more field service for display tree\n $list[$id] = $tmp ;\n $list = $this->_data_recurse($id, $children,$list, $maxlevel, $level+1, $indent . $spacer,$data);\n\n }\n }\n return $list;\n }", "public function rebuildtree(){\n\t\t//Rebuild categories ads trigger count.\n\n\t\t//Rebuild nested set - get cat\n\t\tBLog::addToLog('[Items] rebuilding nested sets...');\n\t\t//\n\t\t$bcache=\\Brilliant\\BFactory::getCache();\n\t\tif($bcache){\n\t\t\t$bcache->invalidate();\n\t\t\t}\n\t\t//\n\t\t$catslist=$this->itemsFilter(array());\n\t\tBLog::addToLog('[Items] Total categories count:'.count($catslist).'...');\n\n\t\t$rootcats=array();\n\t\t//\n\t\tforeach($catslist as $cat){\n\t\t\t$cat->level=0;\n\t\t\t$cat->lft=0;\n\t\t\t$cat->rgt=0;\n\t\t\tif(empty($cat->{$this->parentKeyName})){\n\t\t\t\t$rootcats[]=$cat;\n\t\t\t\t}\n\t\t\t}\n\t\t//Sort root categories.\n\t\t$n=count($rootcats);\n\t\tBLog::addToLog('[Items] Root categories count:'.$n.'...');\n\t\tfor($i=0; $i<$n; $i++){\n\t\t\t$m=$i;\n\t\t\tfor($j=$i+1; $j<$n; $j++){\n\t\t\t\tif($rootcats[$j]->ordering < $rootcats[$m]->ordering){\n\t\t\t\t\t$m=$j;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\tif($m!=$i){\n\t\t\t\t$t=$rootcats[$i];\n\t\t\t\t$rootcats[$i]=$rootcats[$m];\n\t\t\t\t$rootcats[$m]=$t;\n\t\t\t\t}\n\t\t\t}\n\n\t\t//Foreach by root categories...\n\t\tforeach($rootcats as $rcat){\n\t\t\tBLog::addToLog('[Items] Processing root category ['.$rcat->id.']');\n\n\t\t\t$rcat->level=1;\n\t\t\t$lft=1; $rgt=2;\n\t\t\t$this->rebuildtree_recursive($rcat,$lft,$rgt);\n\t\t\t$rcat->lft=1;\n\t\t\t$rcat->rgt=$rgt;\n\t\t\t}\n\t\t$db=\\Brilliant\\BFactory::getDBO();\n\t\tif(empty($db)){\n\t\t\treturn false;\n\t\t\t}\n\t\tBLog::addToLog('[Items] Updating nested set...');\n\t\tforeach($catslist as $ct){\n\t\t\t$qr='UPDATE `'.$this->tableName.'` set `'.$this->leftKeyName.'`='.$ct->lft.', `'.$this->rightKeyName.'`='.$ct->rgt.', `'.$this->levelKeyName.'`='.$ct->level.' WHERE `'.$this->primaryKeyName.'`='.$ct->id;\n\t\t\t$q=$db->query($qr);\n\t\t\tif(empty($q)){\n\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t}\n\t\t//Invalidate all cache.\n\t\t$bcache=\\Brilliant\\BFactory::getCache();\n\t\tif($bcache){\n\t\t\t$bcache->invalidate();\n\t\t\t}\n\t\treturn true;\n\t\t}", "protected function emitPostProcessTreeDataSignal() {}", "public function process_root_element($data) {\n }", "abstract protected function getCurrentChildren(): array ;", "function loadedChildren()\r\n {\r\n //Calls childrens loaded recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->loaded();\r\n }\r\n }", "public function build($data)\n\t{\n\t\t$this->checkData($data);\n\n\t\t$hierarchyMember = $this->hierarchyMember;\n\t\t$charsPerLevel = $this->charsPerLevel;\n\t\t$usePositionAsIndex = TRUE;\n\n\t\t$root = $this->createNode();\n\t\t$nodes = [];\n\t\tforeach ($data as $item) {\n\t\t\t$rawPosition = $this->getMember($item, $hierarchyMember) ?? '';\n\t\t\t$cutoff = substr($rawPosition, 0, strlen($this->hierarchyCutoff));\n\t\t\tif (!empty($this->hierarchyCutoff) && $cutoff !== $this->hierarchyCutoff) {\n\t\t\t\tthrow new RuntimeException(sprintf('Item hierarchy member \"%s\" does not start with the set hierarchy cut-off string \"%s\".', $rawPosition, $this->hierarchyCutoff), 3);\n\t\t\t}\n\t\t\t$itemPosition = substr($rawPosition, strlen($this->hierarchyCutoff));\n\n\t\t\tif ($itemPosition === NULL || strlen($itemPosition) < $this->charsPerLevel) {\n\t\t\t\t// root node found\n\t\t\t\t$newRoot = $this->createNode($item);\n\t\t\t\t$this->copyNodesRelationsAndReplace($root, $newRoot);\n\t\t\t\t$root = $newRoot;\n\t\t\t\tcontinue;\n\t\t\t} elseif (!isset($nodes[$itemPosition])) {\n\t\t\t\t// insert the node into the check table\n\t\t\t\t$nodes[$itemPosition] = $node = $this->createNode($item);\n\t\t\t} else {\n\t\t\t\t// the node has been inserted before - due to data failure or gap bridging\n\t\t\t\t// replace the node, copy node relations and continue\n\t\t\t\t$oldNode = $nodes[$itemPosition];\n\t\t\t\t$nodes[$itemPosition] = $this->createNode($item);\n\t\t\t\t$this->copyNodesRelationsAndReplace($oldNode, $nodes[$itemPosition]);\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$parentPos = substr($itemPosition, 0, -$charsPerLevel);\n\t\t\tif (isset($nodes[$parentPos])) {\n\t\t\t\t// parent has already been processed, link the child\n\t\t\t\t$nodes[$parentPos]->addChild($node, $usePositionAsIndex ? $cutoff . $itemPosition : NULL);\n\t\t\t} else {\n\t\t\t\t// bridge the gap between the current node and the nearest parent\n\t\t\t\t$pos = $parentPos;\n\t\t\t\t$childPosition = $itemPosition;\n\t\t\t\t$childNode = $node;\n\t\t\t\twhile (strlen($pos) >= $charsPerLevel && strlen($pos) >= strlen($cutoff) && !isset($nodes[$pos])) {\n\t\t\t\t\t$nodes[$pos] = $newNode = $this->createNode();\n\t\t\t\t\t$newNode->addChild($childNode, $usePositionAsIndex ? $cutoff . $childPosition : NULL);\n\t\t\t\t\t$childNode = $newNode;\n\t\t\t\t\t$childPosition = $pos;\n\t\t\t\t\t$pos = substr($pos, 0, -$charsPerLevel);\n\t\t\t\t}\n\t\t\t\tif (!isset($nodes[$pos])) {\n\t\t\t\t\t$root->addChild($childNode, $usePositionAsIndex ? $cutoff . $childPosition : NULL);\n\t\t\t\t} else {\n\t\t\t\t\t$nodes[$pos]->addChild($childNode, $usePositionAsIndex ? $cutoff . $childPosition : NULL);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$this->autoSort && $this->sortChildren($root);\n\t\treturn $root;\n\t}", "function get_child_nodes_row_control($categoryID, $category_structure, $level, $current_category_id, $user_id, $control = false, $data_structure, $params = array())\n {\n $rs = '';\n if (!isset($category_structure['childs'][$categoryID]) || !is_array($category_structure['childs'][$categoryID])) {\n return '';\n }\n\n\n if (count($params) > 0) {\n $add_url = '&' . implode('&', $params);\n }\n\n foreach ($category_structure['childs'][$categoryID] as $child_id) {\n\n\n if ((0 != $this->getConfigValue('hide_empty_catalog')) and (0 == $data_structure['data'][$user_id][$child_id])) {\n $rs .= '';\n } else {\n\n if ($current_category_id == $child_id) {\n $selected = \" selected \";\n } else {\n $selected = \"\";\n }\n $this->j++;\n if (ceil($this->j / 2) > floor($this->j / 2)) {\n $row_class = \"row1\";\n } else {\n $this->j = 0;\n $row_class = \"row2\";\n }\n\n //print_r($category_structure['catalog'][$child_id]);\n //print_r($data_structure['data'][$user_id]);\n //echo \"category_id = $child_id, count = \".$data_structure['data'][$user_id][$child_id].'<br>';\n $rs .= '<tr>';\n\n if ($child_id == $current_category_id) {\n $row_class = 'active';\n }\n $rs .= '<td class=\"' . $row_class . '\"><a href=\"?topic_id=' . $child_id . '' . $add_url . '\">' . str_repeat('&nbsp;.&nbsp;', $level) . $category_structure['catalog'][$child_id]['name'] . '</a> (' . (int)$data_structure['data'][$user_id][$child_id] . ')' . ' <small>id:' . $child_id . '</small></td>';\n if ($control) {\n $edit_icon = '<a href=\"?action=structure&do=edit&id=' . $child_id . '\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/edit.png\" border=\"0\" alt=\"редактировать\" title=\"редактировать\"></a>';\n $delete_icon = '<a href=\"?action=structure&do=delete&id=' . $child_id . '\" onclick=\"if ( confirm(\\'' . Multilanguage::_('L_MESSAGE_REALLY_WANT_DELETE') . '\\') ) {return true;} else {return false;}\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/delete.png\" border=\"0\" width=\"16\" height=\"16\" alt=\"удалить\" title=\"удалить\"></a>';\n }\n\n //$rs .= '<td class=\"'.$row_class.'\">'.$this->get_operation_type_name_by_id($category_structure['catalog'][$child_id]['operation_type_id']).'</td>';\n if ($control) {\n $rs .= '<td class=\"' . $row_class . '\">' . $edit_icon . $delete_icon . '</td>';\n }\n\n $rs .= '</tr>';\n //$rs .= '<option value=\"'.$child_id.'\" '.$selected.'>'.str_repeat(' . ', $level).$category_structure['catalog'][$child_id]['name'].'</option>';\n //print_r($category_structure['childs'][$child_id]);\n if (isset($category_structure['childs'][$child_id]) && count($category_structure['childs'][$child_id]) > 0) {\n $rs .= $this->get_child_nodes_row_control($child_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n }\n }\n return $rs;\n }", "private function setParentChildrenClass() {\n $tmp_schemedata = $this->schemedata;\n \n // replace parents with primary key.\n foreach($this->schemedata as $index => $class) {\n $parents = array();\n $see = array();\n foreach ($class['parents'] as $parent=>$cols) {\n foreach($tmp_schemedata as $tmp_class) {\n if ($tmp_class['table'] == $parent) {\n $tmp = $tmp_class['pkFields'];\n $tmp_cols = $cols;\n $tmp2 = array();\n foreach ($tmp as $key=>$val) {\n $key = array_shift($tmp_cols);\n $tmp2[$key] = $val;\n }\n $parents[$tmp_class['name']] = $tmp2;\n $see[] = $tmp_class['name'];\n }\n }\n }\n $this->schemedata[$index]['parents'] = $parents;\n $this->schemedata[$index]['see'] = $see;\n }\n\n // children\n foreach($this->schemedata as $index => $class) {\n foreach ($class['parents'] as $parent=>$cols) {\n foreach($tmp_schemedata as $tmp_class) {\n if ($tmp_class['table'] == $this->schemedata[$parent]['table']) {\n if ($class['type'] != 'TO' AND $class['type'] != 'TS' AND $class['type'] != 'TB') {\n $tmp = $class['parents']; // children's parent def\n $tmp2 = array();\n foreach ($tmp as $key=>$val) {\n if($key == $tmp_class['name']) {\n $tmp2 = $val;\n }\n }\n if($class['name']) {\n $this->schemedata[$tmp_class['name']]['children'][$class['name']] = $tmp2;\n $this->schemedata[$tmp_class['name']]['see'][] = $class['name'];\n } else {\n $this->schemedata[$tmp_class['name']]['children'][$index] = $tmp2;\n }\n }\n }\n }\n }\n }\n\n // relationships\n foreach($this->schemedata as $class) {\n if ($class['type'] == 'TO' OR $class['type'] == 'TS' OR $class['type'] == 'TB') {\n foreach ($class['parents'] as $parent=>$pkFields) {\n if(!isset($this->schemedata[$parent]['relationships'])) {\n $this->schemedata[$parent]['relationships'] = array();\n }\n // add parent to another parent list getter\n foreach ($class['parents'] as $p=>$fs) {\n if ($parent != $p) {\n $type = 'List';\n $mname = '';\n foreach($fs as $k => $v) {\n $name = $k;\n }\n foreach($class['params'] as $param) {\n if($name == $param['name']) {\n $type = ($param['pair']=='N')?'List':'Class';\n break;\n }\n }\n\n $this->schemedata[$parent]['relationships'][$p]= array(\n 'table' => $class['table'],\n 'myFields' => $pkFields,\n 'fields' => $fs,\n 'type' => $type\n );\n }\n }\n }\n }\n }\n\n // rewrite relation key for parents, children and relations\n foreach($this->schemedata as $key => $class) {\n // parent\n foreach($class['parents'] as $k1 => $values) {\n foreach($values as $k2 => $value) {\n foreach($class['params'] as $param) {\n if($param['name']==$k2) {\n unset($this->schemedata[$key]['parents'][$k1][$k2]);\n $this->schemedata[$key]['parents'][$k1][$param['mname']] = $value;\n break;\n }\n }\n }\n }\n // children\n foreach($class['children'] as $k1 => $values) {\n foreach($values as $k2 => $value) {\n foreach($class['params'] as $param) {\n if($param['name']==$value) {\n $this->schemedata[$key]['children'][$k1][$k2] = $param['mname'];\n break;\n }\n }\n }\n }\n // relations\n if(isset($class['relationships'])) {\n foreach($class['relationships'] as $k1 => $values) {\n foreach($values['myFields'] as $k2 => $value) {\n foreach($class['params'] as $param) {\n if($param['name']==$value) {\n $this->schemedata[$key]['relationships'][$k1]['myFields'][$k2] = $param['mname'];\n break;\n }\n }\n }\n foreach($values['fields'] as $k2 => $value) {\n foreach($class['params'] as $param) {\n if($param['name']==$value) {\n $this->schemedata[$key]['relationships'][$k1]['fields'][$k2] = $param['mname'];\n break;\n }\n }\n }\n }\n }\n }\n }", "function populate() {\n $this->populateInputElements($this->children);\n }", "public function process($data) {\n\t\tforeach($data as $title => $item) {\n\t\t\tif (is_string($item)&&trim($item)==''&&$m = Core_Regexps::match_with_results('{^\\%(.+)$}',trim($title))) {\n\t\t\t\t$_component = trim($m[1]);\n\t\t\t\t$_parms = false;\n\t\t\t\tif ($m = Core_Regexps::match_with_results('{^([^\\s]+)\\s+(.+)$}',$_component)) {\n\t\t\t\t\t$_component = $m[1];\n\t\t\t\t\t$_parms = trim($m[2]);\n\t\t\t\t}\n\t\t\t\tif (CMS::component_exists($_component)) {\n\t\t\t\t\t$_class = CMS::$component_names[$_component];\n\t\t\t\t\t$_classref = Core_Types::reflection_for($_class);\n\t\t\t\t\t$links = $_classref->hasMethod('navigation_tree')? $_classref->getMethod('navigation_tree')->invokeArgs(NULL,array($_parms)) : array();\n\t\t\t\t\tforeach($links as $k => $v) {\n\t\t\t\t\t\tif (is_string($v)) $v = array('url' => $v);\n\t\t\t\t\t\t$v[\"from-$_component\"] = 1;\n\t\t\t\t\t\t$links[$k] = $v;\n\t\t\t\t\t}\n\t\t\t\t\t$this->process($links);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\telse $this->add($title,$item);\n\t\t}\n\t}", "protected function buildRenderChildrenClosure() {}", "abstract public function get__do_process ( $data );", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "function dumpChildrenFormItems($return_contents=false)\r\n {\r\n //Iterates through components, dumping all form items\r\n reset($this->components->items);\r\n\r\n if ($return_contents) ob_start();\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n if ($v->inheritsFrom('Control'))\r\n {\r\n if ($v->canShow())\r\n {\r\n $v->dumpFormItems();\r\n }\r\n }\r\n else $v->dumpFormItems();\r\n }\r\n if ($return_contents)\r\n {\r\n $contents=ob_get_contents();\r\n ob_end_clean();\r\n return($contents);\r\n }\r\n }", "function get_category_tree_control_shop($current_category_id, $user_id, $control = false, $params = array())\n {\n //print_r($params);\n //echo '$current_category_id = '.$current_category_id;\n $category_structure = $this->loadCategoryStructure();\n $data_structure = $this->load_data_structure_shop($user_id, $params);\n //echo '<pre>';\n //print_r($data_structure);\n //print_r($category_structure);\n\n foreach ($category_structure['catalog'] as $cat_point) {\n $ch = 0;\n $this->getChildsItemsCount($cat_point['id'], $category_structure['childs'], $data_structure['data'][$user_id], $ch);\n\n $data_structure['data'][$user_id][$cat_point['id']] += $ch;\n }\n\n\n $level = 0;\n $rs = '';\n $rs .= '<table border=\"0\">';\n $rs .= '<tr>';\n $rs .= '<td class=\"row_title\">' . Multilanguage::_('L_TEXT_TITLE') . '</td>';\n $rs .= '<td class=\"row_title\"></td>';\n $rs .= '</tr>';\n foreach ($category_structure['childs'][0] as $item_id => $catalog_id) {\n //echo $catalog_id.'<br>';\n $rs .= $this->get_row_control($catalog_id, $category_structure, $level, 'row1', $user_id, $control, $data_structure, $current_category_id, $params);\n $rs .= $this->get_child_nodes_row_control($catalog_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n $rs .= '</table>';\n return $rs;\n }", "protected function traverseFields(): void\n {\n $columns = $this->definition->tca['columns'] ?? [];\n foreach ($this->definition->data as $fieldName => $value) {\n if (! is_array($columns[$fieldName])) {\n continue;\n }\n \n $this->registerHandlerDefinitions($fieldName, $columns[$fieldName], [$fieldName]);\n \n // Handle flex form fields\n if (isset($columns[$fieldName]['config']['type']) && $columns[$fieldName]['config']['type'] === 'flex') {\n $this->flexFormTraverser->initialize($this->definition, [$fieldName])->traverse();\n }\n }\n }", "function _postProcess() {\r\n $item = current($this->_struct);\r\n \r\n $ret = array('_name'=>$item['tag'], '_attributes'=>array(), '_value'=>null);\r\n\r\n if (isset($item['attributes']) && count($item['attributes'])>0) {\r\n foreach ($item['attributes'] as $key => $data) {\r\n if (!is_null($data)) {\r\n $item['attributes'][$key] = str_replace($this->_replaceWith, $this->_replace, $item['attributes'][$key]);\r\n }\r\n }\r\n $ret['_attributes'] = $item['attributes'];\r\n if ($this->attributesDirectlyUnderParent)\r\n $ret = array_merge($ret, $item['attributes']);\r\n }\r\n\r\n if (isset($item['value']) && $item['value'] != null)\r\n $item['value'] = str_replace($this->_replaceWith, $this->_replace, $item['value']);\r\n \r\n switch ($item['type']) {\r\n case 'open':\r\n $children = array();\r\n while (($child = next($this->_struct)) !== FALSE ) {\r\n if ($child['level'] <= $item['level'])\r\n break;\r\n \r\n $subItem = $this->_postProcess();\r\n \r\n if (isset($subItem['_name'])) {\r\n if (!isset($children[$subItem['_name']]))\r\n $children[$subItem['_name']] = array();\r\n \r\n $children[$subItem['_name']][] = $subItem;\r\n }\r\n else {\r\n foreach ($subItem as $key=>$value) {\r\n if (isset($children[$key])) {\r\n if (is_array($children[$key]))\r\n $children[$key][] = $value;\r\n else\r\n $children[$key] = array($children[$key], $value);\r\n }\r\n else {\r\n $children[$key] = $value;\r\n }\r\n }\r\n }\r\n }\r\n \r\n if ($this->childTagsDirectlyUnderParent)\r\n $ret = array_merge($ret, $this->_condenseArray($children));\r\n else\r\n $ret['_value'] = $this->_condenseArray($children);\r\n \r\n break;\r\n case 'close':\r\n break;\r\n case 'complete':\r\n if (count($ret['_attributes']) > 0) {\r\n if (isset($item['value']))\r\n $ret['_value'] = $item['value'];\r\n }\r\n else {\r\n\t\t\tif (isset($item['value'])) {\r\n\t\t\t\t$ret = array($item['tag']=> $item['value']);\r\n\t\t\t} else {\r\n\t\t\t\t$ret = array($item['tag']=> \"\");\r\n\t\t\t}\r\n }\r\n break;\r\n }\r\n\r\n //added by Dan Coulter\r\n\r\n \r\n /*\r\n foreach ($ret as $key => $data) {\r\n if (!is_null($data) && !is_array($data)) {\r\n $ret[$key] = str_replace($this->_replaceWith, $this->_replace, $ret[$key]);\r\n }\r\n }\r\n */\r\n return $ret;\r\n }", "public function traverseFlexFormXMLData_recurse($dataStruct, $editData, &$PA, $path = '')\n {\n if (is_array($dataStruct)) {\n foreach ($dataStruct as $key => $value) {\n // The value of each entry must be an array.\n if (is_array($value)) {\n if ($value['type'] === 'array') {\n // Array (Section) traversal\n if ($value['section']) {\n $cc = 0;\n if (is_array($editData[$key]['el'])) {\n if ($this->reNumberIndexesOfSectionData) {\n $temp = [];\n $c3 = 0;\n foreach ($editData[$key]['el'] as $v3) {\n $temp[++$c3] = $v3;\n }\n $editData[$key]['el'] = $temp;\n }\n foreach ($editData[$key]['el'] as $k3 => $v3) {\n if (is_array($v3)) {\n $cc = $k3;\n $theType = key($v3);\n $theDat = $v3[$theType];\n $newSectionEl = $value['el'][$theType];\n if (is_array($newSectionEl)) {\n $this->traverseFlexFormXMLData_recurse([$theType => $newSectionEl], [$theType => $theDat], $PA, $path . '/' . $key . '/el/' . $cc);\n }\n }\n }\n }\n } else {\n // Array traversal\n if (is_array($editData) && is_array($editData[$key])) {\n $this->traverseFlexFormXMLData_recurse($value['el'], $editData[$key]['el'], $PA, $path . '/' . $key . '/el');\n }\n }\n } elseif (is_array($value['TCEforms']['config'])) {\n // Processing a field value:\n foreach ($PA['vKeys'] as $vKey) {\n $vKey = 'v' . $vKey;\n // Call back\n if ($PA['callBackMethod_value'] && is_array($editData) && is_array($editData[$key])) {\n $this->executeCallBackMethod($PA['callBackMethod_value'], [$value, $editData[$key][$vKey], $PA, $path . '/' . $key . '/' . $vKey, $this]);\n }\n }\n }\n }\n }\n }\n }", "protected function constructRecursively($data)\n {\n if ($this->isAok($data)) {\n $this->items = $data->items;\n } else {\n foreach($data as $key => $item) {\n $this->append($item, $key);\n }\n }\n }", "public function all_deps($handles, $recursion = \\false, $group = \\false)\n {\n }", "protected function loadTreeData() {}", "private function _createTree($data)\n {\n $results = $idMap = array();\n $ids = Set::extract(\"/{$this->name}/id\", $data);\n\n foreach($data as $item) {\n $item['children'] = array();\n $id = $item[$this->name]['id'];\n $parentId = $item[$this->name]['parent_id'];\n\n $idMap[$id] = array_merge($item[$this->name], array('children' => array()));\n\n if(!$parentId || !in_array($parentId, $ids)) {\n $idMap[$id]['level'] = 0;\n $results[] =& $idMap[$id];\n } else {\n $idMap[$id]['level'] = $idMap[$parentId]['level'] + 1;\n $idMap[$parentId]['children'][] =& $idMap[$id];\n }\n }\n\n return $results;\n }", "public function evaluateChildNodes();", "function get_category_tree_control($current_category_id, $user_id, $control = false, $params = array(), $search_params = array())\n {\n // @todo: $user_id нужно добавить проверку на массив в этом значении и генерировать контрол в соответствии с массивом\n // user_id\n\n $category_structure = $this->loadCategoryStructure();\n $data_structure = $this->load_data_structure($user_id, $params, $search_params);\n //print_r($data_structure);\n if (is_array($category_structure['catalog']) && count($category_structure['catalog']) > 0) {\n foreach ($category_structure['catalog'] as $cat_point) {\n $ch = 0;\n $this->getChildsItemsCount($cat_point['id'], $category_structure['childs'], $data_structure['data'][$user_id], $ch);\n if (!isset($data_structure['data'][$user_id][$cat_point['id']])) {\n $data_structure['data'][$user_id][$cat_point['id']] = 0;\n }\n $data_structure['data'][$user_id][$cat_point['id']] += $ch;\n }\n }\n unset($params['active']);\n unset($params['hot']);\n\n $level = 0;\n $rs = '';\n $rs .= '<table border=\"0\" width=\"100%\" class=\"table table-hover\">';\n if (is_array($category_structure['childs'][0]) && count($category_structure['childs'][0]) > 0) {\n foreach ($category_structure['childs'][0] as $item_id => $catalog_id) {\n //echo $catalog_id.'<br>';\n $rs .= $this->get_row_control($catalog_id, $category_structure, $level, 'row1', $user_id, $control, $data_structure, $current_category_id, $params);\n $rs .= $this->get_child_nodes_row_control($catalog_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n }\n $rs .= '</table>';\n return $rs;\n }", "protected function _parseFolders($data)\n {\n foreach ($data as $child) {\n if ($child->type == 'text/x-moz-place-container') {\n if (empty($child->root)) {\n $this->_tagMap[$child->id] = $child->title;\n $this->_parentMap[$child->id] = $child->parent;\n }\n if (!empty($child->children)) {\n $this->_parseFolders($child->children);\n }\n }\n }\n }", "public function get_children();", "function process($data)\n {\n \t$this->referees = $referees = $this->getReferees();\n \n // Calc total points for each referee\n foreach($this->referees as $referee) \n {\n \t$points = $this->getMadisonRefereePoints($referee->id);\n \t\n \t$referee->pending = $points['pending'];\n \t$referee->processed = $points['processed'];\n \t\n \t$referee->pending_rt = $points['pending_rt'];;\n \t$referee->processed_rt = $points['processed_rt'];\n }\n $this->buildPickLists($referees,$data);\n \n /* And render it */ \n return $this->renderx();\n }", "protected function deleteChildren() {}", "function CreateTree($data,$p_id=0,$level=0){\n if(!$data){\n return;\n }\n static $newarray=[];\n foreach($data as $k=>$v){\n if($v->p_id==$p_id){\n $v->level=$level;\n $newarray[]=$v;\n //调用自身\n $this->CreateTree($data,$v->cate_id,$level+1);\n }\n }\n return $newarray;\n}", "private function build_tree()\n\t\t{\n\t\t\t$this->html_result .= '<ul class=\"'.$this->style.'_ul_first\" onkeydown=\"return input_main_key(event,\\''.$this->internal_id.'\\')\">';\n\n\t\t\t//==================================================================\n\t\t\t// Always first this row in tree ( edit mode only )\n\t\t\t//==================================================================\n\t\t\tif ($this->edit_mode)\n\t\t\t{\n\t\t\t\t$this->html_result .= '<div class=\"'.$this->style.'_interow\" id=\"'.$this->internal_id.'INT_0\" OnClick=\"add_new_node(\\''.$this->internal_id.'\\',0)\"></div>';\n\t\t\t}\n\t\t\t//==================================================================\n\t\t\t\n\t\t\t$this->scan_level(0,$this->get_any_child(1));\n\n\t\t\t$this->html_result .= '<ul class=\"'.$this->style.'_ul\">';\n\t\t}", "public function build($data)\n\t{\n\t\t$this->checkData($data);\n\n\t\t$parentMember = $this->getParentMember();\n\t\t$idMember = $this->getIdMember();\n\t\t$nodes = []; // node cache, processed nodes\n\t\t$rootId = NULL;\n\t\t$rootFound = FALSE;\n\t\tforeach ($data as $item) {\n\t\t\t$id = $this->getCallbackMember($item, $idMember);\n\t\t\t$parent = $this->getCallbackMember($item, $parentMember);\n\n\t\t\tif ($parent === NULL || $id === $parent) {\n\t\t\t\tif ($this->throwOnMultipleRoots && $rootFound) {\n\t\t\t\t\tthrow new RuntimeException('Multiple roots occurring in the data.', 200);\n\t\t\t\t}\n\t\t\t\t// the root has been found\n\t\t\t\t$rootId = $id;\n\t\t\t\t$parent = NULL;\n\t\t\t\t$rootFound = TRUE;\n\t\t\t}\n\n\t\t\t$node = $this->createNode($item);\n\t\t\tif (isset($nodes[$id])) {\n\t\t\t\t// a stub node has been inserted into node cache before - need to replace it\n\t\t\t\t/* @var $stub INode */\n\t\t\t\t$stub = $nodes[$id];\n\t\t\t\tforeach ($stub->getChildren() as $index => $child) {\n\t\t\t\t\t$node->addChild($child, $index);\n\t\t\t\t}\n\t\t\t\t$node->setParent($stub->getParent());\n\t\t\t}\n\t\t\t// insert the node into the node cache table\n\t\t\t$nodes[$id] = $node;\n\n\t\t\tif ($parent !== NULL) {\n\t\t\t\tif (!isset($nodes[$parent])) {\n\t\t\t\t\t// insert a stub of the parent node into the node cache\n\t\t\t\t\t$nodes[$parent] = $parentNode = $this->createNode();\n\t\t\t\t} else {\n\t\t\t\t\t// the parent node has been processed before\n\t\t\t\t\t$parentNode = $nodes[$parent];\n\t\t\t\t}\n\t\t\t\t$parentNode->addChild($node, $this->getChildIndex($id, $node));\n\t\t\t}\n\t\t}\n\n\t\t// all nodes processed, root found?\n\t\tif ($rootFound) {\n\t\t\t$root = $nodes[$rootId];\n\t\t} else {\n\t\t\t$root = NULL;\n\t\t\tforeach ($this->implicitRoots as $irid) {\n\t\t\t\tif (isset($nodes[$irid])) {\n\t\t\t\t\t$root = $nodes[$irid];\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\tif ($root !== NULL) {\n\t\t\treturn $root;\n\t\t}\n\t\tthrow new RuntimeException('No root node present.', 100);\n\t}", "public function showData(){\n echo \"<li>Data: \";\n if(gettype($this->data) == \"array\"){\n print_r(implode(', ', $this->data));\n }\n else{\n print_r($this->data);\n }\n echo \"</li>\";\n\n echo \"<ul><li>is a \".$this->type.\"</li>\"; // Print the type of the node\n\n if($this->parentNode != NULL){\n echo \"<li>Parent: \";\n if(gettype($this->parentNode->getData()) == \"array\"){\n print_r(implode(', ', $this->parentNode->getData()));\n }\n else{\n print_r($this->parentNode->getData());\n }\n\n echo \"</li>\";\n }\n else{\n echo \"<li>has no parent node.</li>\";\n }\n\n // echo \"<li>Children: </li>\";\n // // Show left child\n // if($this->childNodes[\"left\"] != NULL){\n // $d = $this->childNodes[\"left\"]->getData();\n //\n // if(gettype($d) == \"array\"){\n // echo \"L: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"L: \".$d.\"\\t\";\n // }\n //\n // }\n // // Show left-right child if we have it\n // if($this->childNodes[\"LR\"] != NULL){\n // $d = $this->childNodes[\"LR\"]->getData();\n //\n // if(gettype($d) == \"array\"){\n // echo \"LR: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"LR: \".$d.\"\\t\";\n // }\n // }\n //\n // // ... middle child\n // if($this->childNodes[\"mid\"] != NULL){\n // $d = $this->childNodes[\"mid\"]->getData();\n //\n // if(gettype($d) == \"array\"){\n // echo \"M: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"M: \".$d.\"\\t\";\n // }\n // }\n // // ... middle-right child\n // if($this->childNodes[\"MR\"] != NULL){\n // $d = $this->childNodes[\"MR\"]->getData();\n //\n // if(gettype($d) == \"array\"){\n // echo \"MR: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"MR: \".$d.\"\\t\";\n // }\n // }\n //\n // // ... right child\n // if($this->childNodes[\"right\"] != NULL){\n // $d = $this->childNodes[\"right\"]->getData();\n // if(gettype($d) == \"array\"){\n // echo \"R: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"R: \".$d.\"\\t\";\n // }\n // }\n // // ... right-right child\n // if($this->childNodes[\"RR\"] != NULL){\n // $d = $this->childNodes[\"RR\"]->getData();\n //\n // if(gettype($d) == \"array\"){\n // echo \"RR: \".implode(', ', $d).\"\\t\";\n // }\n // else{\n // echo \"RR: \".$d.\"\\t\";\n // }\n // }\n\n echo \"</ul>\";\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "private function load_children() {\n\t\tif (isset($this->_children)) return;\n\t\t$this->_children = array();\n\t\t$this->_testcases = array();\n\t\tif (!$this->exists()) return; // entity doesn't actually exist\n\t\tforeach (new DirectoryIterator($this->data_path()) as $child) {\n\t\t\t$filename = $child->getFilename();\n\t\t\tif ($child->isDot() || $filename[0] == '.') {\n\t\t\t\t// skip hidden files and ..\n\t\t\t} else if ($child->isDir()) {\n\t\t\t\t// subdirectory = child entity\n\t\t\t\t$this->_children[$filename] = new Entity($this, $filename);\n\t\t\t} else if (substr($filename,-3) == '.in') {\n\t\t\t\t// \".in\" file = testcase\n\t\t\t\t$this->_testcases []= substr($filename,0,-3);\n\t\t\t}\n\t\t}\n\t\tsort($this->_testcases);\n\t\t//ksort($this->_children);\n\t\tuasort($this->_children, 'compare_order');\n\t}", "public function doProcessData() {}", "function unloadRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n for ($i = 0; $i < count($this->Controls); $i++) {\n @$control = &$this->Controls[$keys[$i]];\n if(method_exists($control, \"unloadRecursive\")){\n $control->unloadRecursive();\n }\n $control=null;\n }\n }\n $this->ControlOnUnload();\n $this->Controls=array();\n }", "function unserializeChildren()\r\n {\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->unserialize();\r\n }\r\n }", "public function process()\n {\n $this->addCategory(self::ROOT_CATEGORY_ID, $this->_categories);\n }", "private function parse()\n {\n $this->parseChildrenNodes($this->_dom, $this->_rootNode);\n }", "protected function collectChildren(): void\n {\n $this->collection = new Collection();\n foreach ($this->rawResults as $blockChildContent) {\n $this->collection->add(Block::fromResponse($blockChildContent));\n }\n }", "public function process_handler() {\n\t\tif (get_option( 'chips_data_option_name' )) {\n\t\t\t$opts = get_option( 'chips_data_option_name' );\n\t\t\tif (isset($opts['data_root']) === TRUE) {\n\t\t\t\t$data_root = $opts['data_root'];\t\n\t\t\t}\n\t\t\tif (isset($opts['data_root']) === TRUE) {\n\t\t\t\t$data_html = $opts['data_html'];\n\t\t\t}\n\t\t}\n\t\t$upload_dir = wp_upload_dir();\n\t\tchipsBGProcess::splitBuildProcess($_POST,$this);\n\t}", "function display_node($parent, $level) {\n global $tam1;\n $tam2=array();\n global $leafnodes; \n global $responce;\n if($parent >0) {\n foreach ($tam1 as $row){\n\t if($row['ID_Parent']==$parent){\n\t\t $tam2[]=$row;\n\t }\n }\n } else {\n \n\t foreach ($tam1 as $row){\n\t if($row['ID_Parent']==''){\n\t\t $tam2[]=$row;\n\t }\n }\n }\n\n foreach ($tam2 as $row) {\n\tif(!$row['ID_Parent']) $valp = 'NULL'; else $valp = $row['ID_Parent'];\t\n\t//kiem tra node co phai lead\n\tif(array_key_exists($row['ID_Control'], $leafnodes)) $leaf='true'; else $leaf = 'false';\t\n\t$responce[] = array('ID_Control' => $row[\"ID_Control\"], 'ID_Parent' => $row[\"ID_Parent\"], 'Caption' => $row[\"Caption\"],'KieuControl' => $row[\"KieuControl\"],'IsBarButton' => $row[\"IsBarButton\"] ,'Icon' =>$row[\"Icon\"],'Active' =>$row[\"Active\"],'STT' =>$row[\"STT\"],'PageOpen' =>$row[\"PageOpen\"],'OpenType' =>$row[\"OpenType\"],'TenControl' =>$row[\"TenControl\"] , 'level' => $level, 'parent' => $valp, 'isLeaf' => $leaf, 'expanded' => \"true\", 'loaded' => \"true\");\n\t\n\t display_node($row['ID_Control'],$level+1);\n\t \n\t} \n \n return $responce;\n \n}", "function run() {\n $paragraph_fields = getParagraphsFields();\n\n foreach ($paragraph_fields as $paragraph_field) {\n $parent_type = $paragraph_field->parent_type;\n $parent_field_name = $paragraph_field->parent_field_name;\n\n // We only care about cloned nodes right now, because nested paragraphs\n // should clone cleanly by default.\n if ($parent_type !== 'node') {\n logMessage(\"Not processing parent_type $parent_type, field $parent_field_name...\");\n continue;\n }\n\n $rows = getMultiplyParentedParagraphFieldRows($parent_type, $parent_field_name);\n foreach ($rows as $target_id => $row) {\n $parent_ids = $row->parent_ids;\n $parent_count = count($parent_ids);\n\n if ($parent_count > 0) {\n $parent_list = implode(', ', $parent_ids);\n logMessage(\"Paragraph #{$target_id} has {$parent_count} parents: {$parent_list}\");\n // We can leave this paragraph with its original parent,\n // but we wanna give clones to its other parents.\n $cloned_parent_ids = array_slice($parent_ids, 0, 1);\n if (!empty($cloned_parent_ids)) {\n repairParagraph($parent_type, $parent_field_name, (int) $cloned_parent_ids[0], (int) $target_id);\n }\n }\n }\n\n }\n}", "function serializeChildren()\r\n {\r\n //Calls children's serialize recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->serialize();\r\n }\r\n }", "public function addTransactionChildren($data)\n\t{\n\t\t$oTransactionStatus = new Transactions_Status();\n\t\t$oTransactionStatus->setTransactionStatus($data['tr_id'], Transaction_Statuses::STATUS_SUBMITTED);\n\n\t\t$oProperties = new Transaction_Properties();\n\t\tforeach($data['properties'] as $value)\n\t\t{\n\t\t\t$oProperties->addProperty($data['tr_id'], $value['id'], $value['value']);\n\t\t}\n\t\t$oProperties->addProperty($data['tr_id'], 'transaction_password', $this->generatePassword());\n\n\t\t$oRelationship = new Transaction_Relationships();\n\t\t$relationship_id = $oRelationship->addRelationship($data);\n\t\t$oRelationship->handleRelationshipUploadedFiles(\n\t\t\t$relationship_id,\n\t\t\t$data['case_id'],\n\t\t\t$data['relationship_documents'],\n\t\t\t$this->getUploadedFiles('relationship_documents')\n\t\t);\n\n\t\t$oParty = new Transaction_Relationship_Parties();\n\t\t$data['rel_id'] = $relationship_id;\n\n\n\t\tforeach($data['parties'] as $party_data)\n\t\t{\n\t\t\t$party_data['rel_id'] = $relationship_id;\n\t\t\t$party_id = $oParty->addParty($party_data);\n\n\t\t\t$oSubjects = new Transaction_Relationship_Party_Subjects();\n\t\t\tforeach($party_data['data'] as $item)\n\t\t\t{\n\t\t\t\t$item['party_id'] = $party_id;\n\t\t\t\t$subject_id = $oSubjects->addSubject($item);\n\n\t\t\t\t$oSubjects->handleSubjectUploadedFiles(\n\t\t\t\t\t$subject_id,\n\t\t\t\t\t$data['case_id'],\n\t\t\t\t\t$item['fileData']['existing_files'],\n\t\t\t\t\t$this->getUploadedFiles($item['hash'])\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\n\t\t// objects part\n\t\t$oObject = new Transaction_Relationship_Objects();\n\t\tforeach($data['objects'] as $item)\n\t\t{\n\t\t\t$data['rel_id'] = $relationship_id;\n\t\t\t$data['object_type'] = $item['objectType'];\n\t\t\t$object_id = $oObject->addObject($data, $item['objectData']);\n\n\t\t\t$oObject->handleObjectUploadedFiles(\n\t\t\t\t$object_id,\n\t\t\t\t$data['case_id'],\n\t\t\t\t$item['fileData']['existing_files'],\n\t\t\t\t$this->getUploadedFiles($item['hash'])\n\t\t\t);\n\t\t}\n\t}", "private function constructHierarchy() {\n\t\t//////////////////////////////////////////////////\n\t\t// Construct child-parent linkage for MonadObjects\n\t\t//////////////////////////////////////////////////\n \n $dummyidd = 10000000;\n\n $number_sets = count($this->sentenceSets);\n\n\t\tfor ($msetIndex=0; $msetIndex<$number_sets; ++$msetIndex) {\n $moarr = &$this->monadObjects[$msetIndex]; // Cached here;\n\t\t\tfor ($i=1; $i<$this->maxLevels; ++$i) {\n\t\t\t\t// Find constituent MonadObjects\n \n\t\t\t\tforeach ($moarr[$i] as $parentMo) { // Loop through monads at level i\n\t\t\t\t\tforeach ($moarr[$i-1] as $childMo) { // Loop through mondads at child level\n\t\t\t\t\t\tif ($childMo->contained_in($parentMo))\n\t\t\t\t\t\t\t$parentMo->add_child($childMo);\n\t\t\t\t\t}\n\t\t\t\t}\n \n\t\t\t\t// Find MonadObjects without parents\n\t\t\t\tforeach ($moarr[$i-1] as $childMo) {\n\t\t\t\t\tif ($childMo->get_parent()===null) {\n\t\t\t\t\t\t$matobj = new OlMatchedObject($dummyidd++, 'dummy');\n\t\t\t\t\t\t$matobj->monadset = $childMo->mo->monadset;\n \n\t\t\t\t\t\t$mmo = new MultipleMonadObject($matobj);\n\t\t\t\t\t\t$moarr[$i][] = $mmo;\n\t\t\t\t\t\t$mmo->add_child($childMo);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n// // Print hierarchy\n// for ($i=1; $i<$this->maxLevels; ++$i) {\n// foreach ($moarr[$i] as $parentMo) {\n// echo \"<pre>parent = \",$parentMo->get_id_d(),\" : \";\n// foreach ($parentMo->children_idds as $cid)\n// echo $cid,\" \";\n// echo \"</pre>\";\n// }\n// }\n }\n }", "function SetAllHierarchyPositions()\n\t{\n\t\tglobal $gCms;\n\t\t$db = $gCms->GetDb();\n\n\t\t$query = \"SELECT content_id FROM \".cms_db_prefix().\"content\";\n\t\t$dbresult = &$db->Execute($query);\n\n\t\twhile ($dbresult && !$dbresult->EOF)\n\t\t{\n\t\t\tContentOperations::SetHierarchyPosition($dbresult->fields['content_id']);\n\t\t\t$dbresult->MoveNext();\n\t\t}\n\t\t\n\t\tif ($dbresult) $dbresult->Close();\n\t}", "private function eval_treeview()\n {\n static $bool_drsFirstPrompt = true;\n\n // LOOP each filter\n foreach ( ( array ) $this->conf_view[ 'filter.' ] as $table => $fields )\n {\n // CONTINUE : table hasn't any dot\n if ( rtrim( $table, '.' ) == $table )\n {\n continue;\n }\n // CONTINUE : table hasn't any dot\n\n foreach ( array_keys( ( array ) $fields ) as $field )\n {\n // CONTINUE : field has an dot\n if ( rtrim( $field, '.' ) != $field )\n {\n continue;\n }\n // CONTINUE : field has an dot\n // Class var table.field\n $tableField = $table . $field;\n\n $conf_view = $this->conf_view;\n $cObj_name = $conf_view[ 'filter.' ][ $table ][ $field . '.' ][ 'treeview.' ][ 'enabled' ];\n $cObj_conf = $conf_view[ 'filter.' ][ $table ][ $field . '.' ][ 'treeview.' ][ 'enabled.' ];\n $treeviewEnabled = $this->pObj->cObj->cObjGetSingle( $cObj_name, $cObj_conf );\n\n // CONTINUE : field has an dot\n if ( !$treeviewEnabled )\n {\n continue;\n }\n // CONTINUE : field has an dot\n // DRS\n if ( $this->pObj->b_drs_warn )\n {\n if ( $bool_drsFirstPrompt )\n {\n $prompt = 'DON\\'T USE AJAX: The treeview of ' . $tableField . ' is enabled. ' .\n 'You will get unexpected effects!';\n t3lib_div :: devLog( '[WARN/FILTER] ' . $prompt, $this->pObj->extKey, 2 );\n $bool_drsFirstPrompt = false;\n }\n }\n // DRS\n // #i0117, 141223, dwildt, 1+\n $this->treeviewTableFields[] = $tableField;\n\n switch ( $this->conf_view[ 'filter.' ][ $table ][ $field ] )\n {\n case( 'CATEGORY_MENU' ):\n $this->eval_treeviewCategoryMenu( $tableField );\n break;\n case( 'TREEVIEW' ):\n $this->eval_treeviewCheckbox( $tableField );\n // #43692, 121206, dwildt, 13+\n // Adding jQuery\n $bool_success_jQuery = $this->pObj->objJss->load_jQuery();\n if ( $bool_success_jQuery )\n {\n if ( $this->pObj->b_drs_javascript )\n {\n $prompt = 'Current filter is a treeview.';\n t3lib_div::devlog( '[INFO/JSS] ' . $prompt, $this->pObj->extKey, 0 );\n $prompt = 'jQuery will be loaded.';\n t3lib_div::devlog( '[INFO/JSS] ' . $prompt, $this->pObj->extKey, 0 );\n }\n }\n // Adding jQuery\n // #43692, 121206, dwildt, 13+\n break;\n default:\n $header = 'Evaluation of treeview filter failed!';\n $text = '' . $tableField . ' is configured as ' . $this->conf_view[ 'filter.' ][ $table ][ $field ] . '\n <br />\n But ' . $tableField . '.treeview.enabled is true. This isn\\'t proper.\n <br />\n Please take care of a proper TypoScript configuration.<br />\n Remove ' . $tableField . '.treeview.enabled or set it to false.';\n $this->pObj->drs_die( $header, $text );\n break;\n }\n }\n }\n // LOOP each filter\n\n return;\n }", "function dumpChildrenJavascript()\r\n {\r\n //Iterates through components, dumping all javascript\r\n $this->dumpJavascript();\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n if ($v->inheritsFrom('Control'))\r\n {\r\n if ($v->canShow())\r\n {\r\n $v->dumpJavascript();\r\n }\r\n }\r\n else $v->dumpJavascript();\r\n }\r\n }", "protected function resolveChildren()\n {\n foreach ($this->unresolvedChildren as $name => $info) {\n $this->children[$name] = $this->create($name, $info['type'], $info['init_options'], $info['exec_options']);\n }\n\n $this->unresolvedChildren = array();\n }", "function InitControl($data=array()){\n $_page_id=$this->Page->Request->globalValue(\"_page_id\");\n $menuFile=&ConfigFile::GetInstance(\"menuIni\",$this->Page->Kernel->Settings->GetItem(\"module\",\"ResourcePath\").$data[\"file\"]);\n $this->parent_field_name=\"parentid\";\n $this->caption_field_name=\"caption\";\n $this->image_field_name=\"image\";\n $this->key_field_name=\"id\";\n\t\t\t$this->url_name=\"url\";\n $this->root=$data[\"root\"];\n $this->onelevel=$data[\"onelevel\"];\n //create menu structure\n $i=1;\n $currentid=0;\n foreach ($menuFile->Sections as $name => $section) {\n $section[\"id\"] = $i;\n $section[\"parentid\"] = 0;\n $section[\"caption\"] = $section[sprintf(\"name_%s\",$this->Page->Kernel->Language)];\n $section[\"image\"] = $section[\"image\"];\n $i++;\n if ($menuFile->HasItem($name,\"parent\")) {\n $parentname=strtolower($menuFile->GetItem($name,\"parent\"));\n $section[\"parentid\"]=$sections[$parentname][\"id\"];\n }\n //search in array current url\n if (!is_array($section[\"url\"]))\n $section[\"url\"]=array($section[\"url\"]);\n if (in_array($this->Page->PageURI,$section[\"url\"]) || $section[\"page_id\"]==$_page_id) $currentid=$section[\"id\"];\n $section[\"url\"]=$section[\"url\"][0];\n $sections[$name]=$section;\n }\n $this->data[\"selected_value\"]=$currentid;\n foreach($sections as $name => $section) $this->_list[]=$section;\n }", "static function to_tree($data)\n {\n //Cap 1\n for ($i = 3; $i >= 1; $i--)\n {\n //echo $i . \"============<br/>\";\n foreach ($data as $key=>$value)\n {\n //if ($key == 1485 || $key == 192 || $key == 193 || $key == 29)\n //echo \"$key = \" . $data[$key][\"ten\"] . \"<br/>\";\n \n //if (!isset($data[$key][\"tree\"])) $data[$key][\"tree\"] = false;\n //if ($value[\"parent\"] > 0 && !$data[$key][\"tree\"])\n if ($value[\"cap\"] == $i)\n {\n //if (!isset($data[$value[\"parent\"]][\"child\"])){\n //\t$data[$value[\"parent\"]][\"child\"] = array();\n //}\n $data[$value[\"parent\"]][\"child\"][$key] = $value;\n //if ($key == 1485 || $key == 192 || $key == 193 || $key == 29)\n //echo \"&nbsp;&nbsp;&nbsp;&nbsp;Dua \" . $value[\"ten\"] . \" vao \" . $value[\"parent\"] . \" \" . $data[$value[\"parent\"]][\"ten\"] . \" <br/>\";\n //$data[$key][\"tree\"] = true;\n //$data[$value[\"parent\"]][\"tree\"] = false;\n }\n }\n }\n //Khu bo\n foreach ($data as $key=>$value)\n {\n if ($value[\"parent\"] > 0)\n {\n unset($data[$key]);\n }\n }\n \n return $data;\n }", "private function build()\n {\n foreach ($this->getChildVariables() as $element) {\n if ($element instanceof BuildableInterface) {\n $element->build($this, $this->_rootNode);\n } elseif ($element instanceof MultipleElementsStore) {\n $this->buildStore($element);\n }\n }\n }", "function CreateChildControls() {\n }", "function ProcessMultilevelSubCategories()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"ProcessMultilevelSubCategories();\" . \"<HR>\";\n if ($this->listSettings->HasItem(\"MAIN\", \"SUB_CATEGORIES_COUNT\")) {\n $this->sub_categories_count = $this->listSettings->GetItem(\"MAIN\", \"SUB_CATEGORIES_COUNT\");\n for ($i = 0; $i < $this->sub_categories_count; $i ++) {\n $sub_category = array();\n if ($this->listSettings->HasItem(\"SUB_CATEGORY_\" . $i, \"APPLY_LIBRARY\")) {\n $sub_category[\"library\"] = $this->listSettings->GetItem(\"SUB_CATEGORY_\" . $i, \"APPLY_LIBRARY\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_SUB_CATEGORY_LIBRARY\", array(\n $i), true);\n }\n if ($this->listSettings->HasItem(\"SUB_CATEGORY_\" . $i, \"LINK_FIELD\")) {\n $sub_category[\"link_field\"] = $this->listSettings->GetItem(\"SUB_CATEGORY_\" . $i, \"LINK_FIELD\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_SUB_CATEGORY_LINK_FIELD\", array(\n $i), true);\n }\n $this->sub_categories[] = $sub_category;\n }\n\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_SUB_CATEGORIES_COUNT\", array(), true);\n }\n\n }", "function preinit()\r\n {\r\n //Calls children's init recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->preinit();\r\n }\r\n }", "function renderChildrenOf($pa, $root = null, $output = '', $level = 0) {\n if(!$root) $root = wire(\"pages\")->get(1);\n $output = '';\n $level++;\n foreach($pa as $child) {\n $class = '';\n $has_children = ($child->id == \"1018\" || $child->id == \"1263\" || count($child->children('include=all'))) ? true : false;\n\n if($has_children && $child !== $root) {\n if($level == 1){\n $class .= 'parent'; // first level boostrap dropdown li class\n //$atoggle .= ' class=\"dropdown-toggle\" data-toggle=\"dropdown\"'; // first level anchor attributes\n }\n }\n\n // make the current page and only its first level parent have an active class\n if($child === wire(\"page\") && $child !== $root){\n $class .= ' active';\n } else if($level == 1 && $child !== $root){\n if($child === wire(\"page\")->rootParent || wire(\"page\")->parents->has($child)){\n $class .= ' active';\n }\n }\n\n $class = strlen($class) ? \" class='\".trim($class).\"'\" : '';\n if($child->menu_item_url) {$childlink = $child->menu_item_url; } else { $childlink = $child->url; }\n $output .= \"<li$class><a href='$childlink'>$child->title</a>\";\n\n // If this child is itself a parent and not the root page, then render its children in their own menu too...\n \n if($has_children && $child !== $root) {\n \n // check for special menu items\n if ($child->id == \"1263\") { //services main item\n\n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n \n // promo\n $output .= '<div class=\"col3\">';\n $output .= '<h4 class=\"megamenu-col-title\">Promotional Offer:</h4>';\n $output .= '<a href=\"#\"><img src=\"http://placehold.it/270x244\" alt=\"\"></a>';\n $output .= '</div>';\n // end promo\n \n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('General');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Cosmetic Dentistry');\n $output .= megaMenuServicesList('Dental Restorations');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Specialty');\n $output .= '</div>';\n // end third column\n\n $output .= '</div></div>';\n }elseif ($child->id == \"1018\") {// blog main menu item\n \n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n\n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('general-dentistry');\n $output .= megaMenuBlogCatList('sleep-apnea-snoring');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('cosmetic-dentistry');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('childrens-dentistry');\n $output .= '</div>';\n // end third column\n\n // dourth column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('sedation-dentistry'); \n $output .= megaMenuBlogCatList('restorations');\n $output .= '</div>';\n // end dourth column\n\n $output .= '</div></div>';\n \n }else {// default case for all other menu items\n\n $output .= renderChildrenOf($child->children('include=all'), $root, $output, $level);\n\n }\n }\n $output .= '</li>';\n\n\n }\n $outerclass = ($level == 1) ? \"menuzord-menu\" : 'dropdown';\n return \"<ul class='$outerclass'>$output</ul>\";\n}", "private function parseChildNodes(): void\n {\n foreach ($this->node->childNodes as $node)\n {\n /** @var \\DOMNode $node */\n switch ($node->nodeName)\n {\n case 'include':\n $this->parsePatternNodeAttributes($node, $this->includes);\n break;\n\n case 'exclude':\n $this->parsePatternNodeAttributes($node, $this->excludes);\n break;\n\n case '#text';\n break;\n\n default:\n throw new ConfigException(\"Unexpected child node '%s' found at %s:%d\",\n $node->nodeName,\n $this->path,\n $node->getLineNo());\n }\n }\n }", "public function process()\n\t{\n\t\t$this->_init();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->_handle_forms();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->_pre_render();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->render();\n\t}", "function BuildRecursiveTree(&$data, $node_id, &$xmlWriter){\n for ($i=0; $i<count($data);$i++){\n if (is_array($data[$i])) {\n if($data[$i][$this->parent_field_name] == $node_id){\n // drawing node\n $xmlWriter->WriteStartElement(\"node\");\n $xmlWriter->WriteAttributeString(\"id\", $data[$i][$this->key_field_name]);\n $xmlWriter->WriteElementString(\"caption\", addslashes($data[$i][$this->caption_field_name]));\n $xmlWriter->WriteElementString(\"url\", $data[$i][$this->url_name]);\n // drawing sub-nodes\n $xmlWriter->WriteStartElement(\"sub_node_list\");\n $this->BuildRecursiveTree($data, $data[$i][$this->key_field_name], $xmlWriter);\n $xmlWriter->WriteEndElement();\n $xmlWriter->WriteEndElement();\n\n }\n }\n }\n }", "private function process()\n\t{\n\t\tif ( $this->controller && is_null($this->is_controlled) ){\n\t\t\t$this->obj = new \\stdClass();\n\t\t\t$this->control();\n\t\t\tif ( $this->has_data() && isset($this->obj->output) ){\n\t\t\t\t$this->obj->output = $this->render($this->obj->output, $this->data);\n\t\t\t}\n\t\t}\n\t\treturn $this;\n\t}", "public function getChildren() {}", "public function getChildren() {}", "public function getChildren() {}", "public function setup()\n {\n parent::setup();\n \n $formClass = $this->getChildFormClass();\n $collection = $this->getParentObject()->{$this->getRelationAlias()};\n $nbChilds = 0;\n $min = $this->getMinNbChilds();\n $max = $this->getMaxNbChilds();\n \n if ($min > $max && $max > 0)\n throw new RuntimeException('min cannot be greater than max.');\n \n // embed forms for each child element that is already persisted\n foreach ($collection as $childObject)\n {\n $form = new $formClass($childObject);\n $pk = $childObject->identifier();\n \n if ($childObject->exists() === false)\n throw new RuntimeException('Transient child objects are not supported.');\n \n if (count($pk) !== 1)\n throw new RuntimeException('Composite primary keys are not supported.');\n \n $this->embedForm(self::PERSISTENT_PREFIX.reset($pk), $form);\n $nbChilds += 1;\n }\n \n // embed as many additional forms as are needed to reach the minimum\n // number of required child objects\n for (; $nbChilds < $min; $nbChilds += 1)\n {\n $form = new $formClass($collection->get(null));\n $this->embedForm(self::TRANSIENT_PREFIX.$nbChilds, $form);\n }\n \n $this->validatorSchema->setPostValidator(new sfValidatorCallback(array(\n 'callback' => array($this, 'validateLogic'),\n )));\n }", "function InitChildControls() {\n }", "public function process()\n\t{\t\n\t\tif ($iDeleteId = $this->request()->getInt('delete'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->delete($iDeleteId))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', null, Phpfox::getPhrase('admincp.menu_successfully_deleted'));\t\n\t\t\t}\n\t\t}\n\t\t\n\t\tif ($aVals = $this->request()->getArray('val'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->updateOrder($aVals))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', array('parent' => $this->request()->getInt('parent')), Phpfox::getPhrase('admincp.menu_order_successfully_updated'));\t\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t$iParentId = $this->request()->getInt('parent');\t\t\n\t\tif ($iParentId > 0)\n\t\t{\n\t\t\t$aMenu = Phpfox::getService('admincp.menu')->getForEdit($iParentId);\n\t\t\tif (isset($aMenu['menu_id']))\n\t\t\t{\n\t\t\t\t$this->template()->assign('aParentMenu', $aMenu);\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$iParentId = 0;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$aTypes = Phpfox::getService('admincp.menu')->getTypes();\n\t\t$aRows = Phpfox::getService('admincp.menu')->get(($iParentId > 0 ? array('menu.parent_id = ' . (int) $iParentId) : array('menu.parent_id = 0')));\n\t\t$aMenus = array();\n\t\t$aModules = array();\n\t\t\n\t\tforeach ($aRows as $iKey => $aRow)\n\t\t{\n\t\t\tif(Phpfox::isModule($aRow['module_id']))\n\t\t\t{\n\t\t\t\tif (!$iParentId && in_array($aRow['m_connection'], $aTypes))\n\t\t\t\t{\n\t\t\t\t\t$aMenus[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tif ($aRow['m_connection'] == 'mobile' || $aRow['m_connection'] == 'main_right') {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$aModules[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\t\t\t\n\t\t\t}\n\t\t}\n\t\tunset($aRows);\t\t\n\t\n\t\t$this->template()\n\t\t\t->setBreadCrumb('CMS', '#cms')\n\t\t\t->setBreadcrumb('Menus', $this->url()->makeUrl('admincp.menu'), true)\n\t\t\t->setTitle('Menus')\n\t\t\t->assign(array(\n\t\t\t\t'aMenus' => $aMenus,\n\t\t\t\t'aModules' => $aModules,\n\t\t\t\t'iParentId' => $iParentId\n\t\t\t)\n\t\t);\n\t}", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "function Control_Render(&$Owner)\r\n\t{\r\n\t\t$parent = $Owner->OriginalNode->ParentNode();\r\n\t\t\r\n\t\t//insert this node before the parent \r\n\t\t$parent->InsertBefore($this->OriginalNode, $Owner->OriginalNode);\r\n\t\r\n\t\r\n\t\t//call parent render with ourselves as the owner\r\n\t\t$result = parent::Control_Render($this);\r\n\t\t\r\n\t\tif (!$result)\r\n\t\t{\r\n\t\t\treturn false;\t\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t//NOTE: this control allows the use of [= ] inline blocks\r\n\t\tParser::ParseInlineBlocks($this, $this->OriginalNode);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//get all items within the copy\r\n\t\t$holder_items = $this->OriginalNode->GetElementsByTagName(PCNODE_ITEM);\r\n\t\t\r\n\t\t//NOTE:: this relative query doesn't work properly in PHP4\r\n\t\t//$holder_items = $ctx->xpath_eval(\"//\".PCNODE_ITEM.\"[@repeater='\".$this->ID.\"']\", $holder);\r\n\t\t\r\n\t\t\r\n\t\t//replace each item with it's value\r\n\t\tfor ($i = 0; $i < count($holder_items); $i++)\r\n\t\t{\r\n\t\t\t$clone_item = $holder_items[$i];\r\n\t\t\t\r\n\t\t\t//ensure Item has repeater attribute\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") == \"\")\r\n\t\t\t{\r\n\t\t\t\ttrigger_error(\"An item has been found within a repeater (id: \".$Owner->ID.\" ) without a valid repeater attribute.\",E_USER_ERROR);\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//goto next item if this one isn't for this repeater\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") != $Owner->ID)\r\n\t\t\t{\r\n\t\t\t\tcontinue;\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//create a new repeater item\r\n\t\t\t$item = new RepeaterItem($clone_item);\r\n\t\t\t\r\n\t\t\t//get the datafield for this item\r\n\t\t\t$datafield = $item->GetDatafield();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$item->SetData($this->DataRow->Get($datafield));\r\n\t\t\t\r\n\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t}", "public function getChilds();", "public function BuildControls() {\n\n $this->EncType= $this->GetOption('EncType');\n\n // convert array of arrays into array of objects\n foreach($this->Controls as $Name=>&$Control) {\n // skip already builded controls\n if (is_object($Control)) {\n continue;\n }\n // find classname\n if (!isset($Control['Type'])) {\n $Control += array('Type'=>'text', 'Attributes'=>array('UNKNOWNTYPE'=>'YES'));\n }\n if (strpos($Control['Type'], '\\\\') === false) { // short name, ex.: \"select\"\n $Type= ucfirst($Control['Type']);\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\'.$Type.'Control';\n } else { // it is fully qualified class name\n $Class= $Control['Type'];\n }\n if (!class_exists($Class)) {\n $this->Error('Class \"'.$Class.'\" not found.');\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\TextControl'; // fallback to any primitive control\n }\n // copy this array into $Options and append few more items\n // and append common options to allow usage of services\n $Options= $Control + array(\n 'Name'=> $Name,\n 'Form'=> $this,\n 'Book'=> $this->GetOption('Book')\n ) + $this->GetCommonOptions();\n $Control= new $Class($Options);\n // switch to multipart encoding if any control require that\n if ($Control->GetMultipartEncoding()) {\n $this->EncType= 'multipart/form-data';\n }\n }\n $this->Builded= true;\n }", "function perform( $data = FALSE )\r\n {\r\n // get var name defined in the public view to store the result\r\n $this->tree_result = & $this->B->$data['result']; \r\n $this->tree_result = array();\r\n\r\n if(!isset($data['node']))\r\n {\r\n $_node = 0;\r\n }\r\n else\r\n {\r\n $_node = $data['node'];\r\n }\r\n\r\n if(!isset($data['status']))\r\n {\r\n $status = FALSE;\r\n }\r\n else\r\n {\r\n $status = $data['status'];\r\n }\r\n\r\n if(SF_SECTION == 'public')\r\n {\r\n // check if cache ID exists\r\n if ( M( MOD_COMMON, \r\n 'cache_get',\r\n array('result' => $data['result'],\r\n 'cacheID' => SF_SECTION.'tree'.$_node.$status,\r\n 'cacheGroup' => 'navigation-tree'))) \r\n {\r\n return SF_IS_VALID_ACTION;\r\n } \r\n }\r\n\r\n // load navigation nodes\r\n include (SF_BASE_DIR . 'data/navigation/nodes.php'); \r\n \r\n // order the node tree by order\r\n $this->_tmp_array = array();\r\n $s=0;\r\n foreach($node as $n => $x)\r\n {\r\n $x['node'] = $n;\r\n $this->_tmp_array['o'.dechex($x['order']).$s] = $x; \r\n $s++;\r\n }\r\n \r\n ksort($this->_tmp_array);\r\n\r\n $this->_level = 0; \r\n\r\n // get child nodes of a given node id\r\n $this->_getTreeNodes( $_node, $status ); \r\n\r\n if(SF_SECTION == 'public')\r\n {\r\n // save result to cache\r\n M( MOD_COMMON, \r\n 'cache_save',\r\n array('result' => $this->tree_result)); \r\n }\r\n \r\n return SF_IS_VALID_ACTION;\r\n }", "function ajaxProcessCatTree($data) {\n\t\t$content = $this->showMenu($data['cb']);\n\n\t\t$objResponse = new tx_xajax_response($GLOBALS['TSFE']->metaCharset);\n\t\t$objResponse->addAssign('rggooglemap-menu', 'innerHTML', $content);\n\n\t\treturn $objResponse->getXML();\n\t}", "protected function processData($data)\n {\n $this->data = array_replace_recursive($this->data, $data);\n }", "protected function processReceivedData() \n {\n parent::processReceivedData();\n // to do: call processReceivedData() for all members\n }", "private function formTree($data)\n {\n if (!is_array($data)) return false;\n $tree = [];\n foreach ($data as $value) {\n $tree[$value['parent_id']][] = $value;\n }\n\n return $tree;\n }", "public function initializeTreeData() {}", "public function initializeTreeData() {}", "public function actionAjaxFillTree()\n {\n \t$this->allowUser(SUPERADMINISTRATOR);\n // accept only AJAX request (comment this when debugging)\n if (!Yii::app()->request->isAjaxRequest) {\n exit();\n }\n // parse the user input\n $parentId = \"NULL\";\n if (isset($_GET['root']) && $_GET['root'] !== 'source') {\n $parentId = (int) $_GET['root'];\n }\n // read the data (this could be in a model)\n $children = Yii::app()->db->createCommand(\n \"SELECT m1.id, m1.name AS text, m2.id IS NOT NULL AS hasChildren \"\n . \"FROM cms_term AS m1 LEFT JOIN cms_term AS m2 ON m1.id=m2.parent_id \"\n . \"WHERE m1.parent_id <=> $parentId \"\n . \"GROUP BY m1.id ORDER BY m1.order ASC\"\n )->queryAll();\n\t\t\n\t\t$cnt = 0;\n\t\tforeach ($children as $child){\n\t\t//\tif ($child['hasChildren']==0) {\n\t\t//\t\t$children[$cnt]['text'] = '<a href='.Yii::app()->baseUrl.'\"/backend.php/term/update/'.$child['id'].'\">'.$child['text'].'</a>';\n\t\t//\t} else {\n\t\t\t\n\t\t\t\t$children[$cnt]['text'] = $child['text']\n\t\t\t\t.'<a href='.Yii::app()->baseUrl.'\"/backend.php/term/update/'.$child['id'].'\"> '.TbHtml::icon(TbHtml::ICON_PENCIL)\n\t\t\t\t.'</a> <a href='.Yii::app()->baseUrl.'\"/backend.php/TermDescription/update/'.$child['id'].'\"> '.TbHtml::icon(TbHtml::ICON_EDIT).'</a>';\n\t\t\t$cnt++;\t\n\t\t}\n\t\t\n\t\t\n echo str_replace(\n '\"hasChildren\":\"0\"',\n '\"hasChildren\":false',\n CTreeView::saveDataAsJson($children)\n );\n }", "public function compute(): void\n {\n try {\n $this->emit(new Group\\Start($this->parser));\n $this->getLeftNode()->compute();\n $this->emit($this);\n $this->getRightNode()->compute();\n $this->emit(new Group\\End($this->parser));\n } catch (NodeHandledException $e) {\n return;\n }\n }", "public function processData() {\r\r\n if ( is_array($this->data) && isset($this->data['args']) )\r\r\n $this->args = array_merge($this->args, $this->data['args']);\r\r\n\r\r\n if ( is_array($this->data) && isset($this->data['value']) ) {\r\r\n // If called from back-end non-post context\r\r\n $this->data = $this->data['value'];\r\r\n }\r\r\n }", "function Render() {\n $this->RenderChildren();\n }", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "function get_category_tree_control_price($current_category_id, $user_id, $control = false, $params = array())\n {\n //print_r($params);\n //echo '$current_category_id = '.$current_category_id;\n $category_structure = $this->loadCategoryStructure();\n $data_structure = $this->load_data_structure_price($user_id, $params);\n //echo '<pre>';\n //print_r($data_structure);\n //print_r($category_structure);\n\n foreach ($category_structure['catalog'] as $cat_point) {\n $ch = 0;\n $this->getChildsItemsCount($cat_point['id'], $category_structure['childs'], $data_structure['data'][$user_id], $ch);\n\n $data_structure['data'][$user_id][$cat_point['id']] += $ch;\n }\n\n\n $level = 0;\n $rs = '';\n $rs .= '<table border=\"0\">';\n $rs .= '<tr>';\n $rs .= '<td class=\"row_title\">' . Multilanguage::_('L_TEXT_TITLE') . '</td>';\n $rs .= '<td class=\"row_title\"></td>';\n $rs .= '</tr>';\n foreach ($category_structure['childs'][0] as $item_id => $catalog_id) {\n //echo $catalog_id.'<br>';\n $rs .= $this->get_row_control($catalog_id, $category_structure, $level, 'row1', $user_id, $control, $data_structure, $current_category_id, $params);\n $rs .= $this->get_child_nodes_row_control($catalog_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n $rs .= '</table>';\n return $rs;\n }", "public function findChildren()\n {\n return self::where('code_parrent',$this->id)->get();\n }" ]
[ "0.64140695", "0.59088004", "0.57994777", "0.57403564", "0.5670434", "0.5637707", "0.56201553", "0.5600078", "0.5498802", "0.54611886", "0.54364234", "0.5399908", "0.5398974", "0.53924257", "0.5347749", "0.5225833", "0.51961374", "0.51939195", "0.51545787", "0.5148276", "0.5144992", "0.5134325", "0.5094532", "0.5080201", "0.50752634", "0.50685537", "0.5057285", "0.50546026", "0.5041439", "0.50031364", "0.4993722", "0.49794516", "0.4977215", "0.49565205", "0.49391758", "0.49377078", "0.49315593", "0.49283367", "0.49209967", "0.491301", "0.49025425", "0.48953262", "0.4890592", "0.48800716", "0.4879341", "0.48772073", "0.48678452", "0.485079", "0.48447615", "0.484104", "0.4836571", "0.48311383", "0.48294288", "0.48209098", "0.48188412", "0.48080385", "0.48064452", "0.48007986", "0.47974852", "0.47862172", "0.47806668", "0.47785482", "0.4774474", "0.47672707", "0.4758905", "0.4752689", "0.4751062", "0.47493657", "0.4725071", "0.47157505", "0.4713347", "0.47079694", "0.47070456", "0.4704846", "0.47030064", "0.4697903", "0.4697903", "0.4697903", "0.46958312", "0.4692092", "0.4680962", "0.46793953", "0.46793953", "0.46762943", "0.4671897", "0.46679127", "0.4664927", "0.46646398", "0.46579006", "0.46493798", "0.464732", "0.4645053", "0.4645053", "0.46437857", "0.46321148", "0.46242294", "0.46224135", "0.46222886", "0.46127743", "0.4610121" ]
0.6321941
1
Method Processes recursive initialization of control and all of it's children.
function initRecursive() { if ($this->HasControls()) { $keys = array_keys($this->Controls); $count = count($this->Controls); for ($i = 0; $i < $count; $i++) { @$control = &$this->Controls[$keys[$i]]; @$control->Page = &$this->Page; $control->initRecursive(); } } $this->_state = WEB_CONTROL_INITIALIZED; $this->ControlOnInit(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "function init()\r\n {\r\n //Copy components to comps, so you can alter components properties\r\n //on init() methods\r\n $comps=$this->components->items;\r\n //Calls children's init recursively\r\n reset($comps);\r\n while (list($k,$v)=each($comps))\r\n {\r\n $v->init();\r\n }\r\n }", "function preinit()\r\n {\r\n //Calls children's init recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->preinit();\r\n }\r\n }", "public function initRecursion()\n {\n $this->recursiveObjects[0] = $this;\n\n $this->recursiveObjects[1] = new $this();\n $this->recursiveObjects[1]->recursiveObjects[0] = $this;\n\n $this->recursiveObjects[2] = $this->recursiveObjects[1];\n }", "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "function InitChildControls() {\n }", "public function initializeTreeData() {}", "public function initializeTreeData() {}", "public function initializeChildren() {\n\t\tif ($this->initialized === TRUE) {\n\t\t\treturn;\n\t\t}\n\t\t/** @var \\TYPO3\\CMS\\Core\\Resource\\Folder $folder */\n\t\t$subFolders = $this->folder->getSubfolders();\n\t\tforeach ($subFolders as $folder) {\n\t\t\t$f = new Storage($this->mapFolderIdToEntityName($folder->getName()), array());\n\t\t\t$f->setStorage($this->storage);\n\t\t\t$f->setFolder($folder);\n\t\t\t$this->addChild($f);\n\t\t}\n\n\t\t$files = $this->folder->getFiles();\n\t\tforeach ($files as $file) {\n\t\t\t$f = new File();\n\t\t\t$f->setFalFileObject($file);\n\t\t\t$this->addChild($f);\n\t\t}\n\t\t$this->initialized = TRUE;\n\t}", "protected function initialization()\n {\n // Set the parent instance\n $this->parent_instance = DiviRoids_Public();\n $this->name = 'shortcodes';\n $this->hook = $this->parent_instance->hook . '_' . $this->name;\n $this->slug = $this->parent_instance->slug . '-' . $this->name;\n $this->settings_prefix = DiviRoids_Settings()->settings_prefix_name . '-' . $this->name;\n\n // Register all hooks\n $this->register_hooks();\n }", "public function init() {\n\t\tparent::init();\n\t\tlist(, $this->roots) = Ola_Service_Area::getsBy(array('root_id'=>0, 'parent_id'=>0), array('sort'=>'DESC' ,'id'=>'DESC'));\n\t\tlist(, $this->parents) = Ola_Service_Area::getsBy(array('root_id'=>array('!=', 0), 'parent_id'=>0), array('sort'=>'DESC', 'id'=>'DESC'));\n\t}", "public function init()\n {\n $backendUser = $this->getBackendUser();\n\n // Setting GPvars:\n $this->currentSubScript = GeneralUtility::_GP('currentSubScript');\n $this->cMR = GeneralUtility::_GP('cMR');\n $this->setTemporaryDatabaseMount = GeneralUtility::_GP('setTempDBmount');\n\n // Generate Folder if necessary\n \\CommerceTeam\\Commerce\\Utility\\FolderUtility::initFolders();\n\n // Create page tree object:\n $this->pagetree = GeneralUtility::makeInstance('CommerceTeam\\\\Commerce\\\\Tree\\\\OrderTree');\n $this->pagetree->ext_IconMode = $backendUser->getTSConfigVal('options.pageTree.disableIconLinkToContextmenu');\n $this->pagetree->ext_showPageId = $backendUser->getTSConfigVal('options.pageTree.showPageIdWithTitle');\n $this->pagetree->addField('alias');\n $this->pagetree->addField('shortcut');\n $this->pagetree->addField('shortcut_mode');\n $this->pagetree->addField('mount_pid');\n $this->pagetree->addField('mount_pid_ol');\n $this->pagetree->addField('nav_hide');\n $this->pagetree->addField('url');\n\n // Temporary DB mounts:\n $this->pagetree->MOUNTS = array_unique(\n \\CommerceTeam\\Commerce\\Domain\\Repository\\FolderRepository::initFolders('Orders', 'Commerce', 0, 'Commerce')\n );\n $this->initializeTemporaryDatabaseMount();\n\n // Setting highlight mode:\n $this->doHighlight = !$backendUser->getTSConfigVal('options.pageTree.disableTitleHighlight');\n }", "function __construct()\n {\n $this->isEnd = false;\n //$this->children = array_fill(0, 26, null); //这种也可以 感觉有点浪费\n $this->children = [];\n }", "protected function resolveChildren()\n {\n foreach ($this->unresolvedChildren as $name => $info) {\n $this->children[$name] = $this->create($name, $info['type'], $info['init_options'], $info['exec_options']);\n }\n\n $this->unresolvedChildren = array();\n }", "function init(&$node){\n\tif(!$node) return;\n\tforeach($node->getChildNode() as &$childNode){\n\t\t$childNode->addParentNode($node);\n\t\tinit($childNode);\n\t}\n}", "public function initialize() {\n\t\t# Create structure\n\t\t$parentResult =& $this->getParentResult();\n\t\t# Creating array structures!\n\t\t$parentResult[$this->getTagName()] =& $this->getResult();\n\t}", "public function init() {\n $resources = new Model_Resources();\n $resources->form_values['only_childs'] = 1;\n $result2 = $resources->getResources('resource_name', 'ASC');\n $this->_list[\"page_name\"][''] = \"Select\";\n if ($result2) {\n foreach ($result2 as $row2) {\n $resource = $row2->getResourceName();\n $arr_resources = explode(\"/\", $resource);\n $second_name = (!empty($arr_resources[1])) ? ucfirst($arr_resources[1]) . \" - \" : \"\";\n $this->_list[\"page_name\"][$row2->getPkId()] = ucfirst($arr_resources[0]) . \" - \" . $second_name . $row2->getDescription();\n }\n }\n\n //Generate fields \n // for Form_Iadmin_MessagesAdd\n foreach ($this->_fields as $col => $name) {\n if ($col == \"description\") {\n parent::createMultiLineText($col, \"4\");\n }\n\n // Generate combo boxes \n // for Form_Iadmin_MessagesAdd\n if (in_array($col, array_keys($this->_list))) {\n parent::createSelect($col, $this->_list[$col]);\n }\n\n // Generate Radio buttons\n // for Form_Iadmin_MessagesAdd\n if (in_array($col, array_keys($this->_radio))) {\n parent::createRadio($col, $this->_radio[$col]);\n }\n }\n }", "public function __construct()\n {\n $this->rootPages = $this->generatePageHierarchy();\n }", "public function __construct()\n {\n $this->parent = null;\n $this->children = array();\n }", "function InitControl($data=array()){\n $_page_id=$this->Page->Request->globalValue(\"_page_id\");\n $menuFile=&ConfigFile::GetInstance(\"menuIni\",$this->Page->Kernel->Settings->GetItem(\"module\",\"ResourcePath\").$data[\"file\"]);\n $this->parent_field_name=\"parentid\";\n $this->caption_field_name=\"caption\";\n $this->image_field_name=\"image\";\n $this->key_field_name=\"id\";\n\t\t\t$this->url_name=\"url\";\n $this->root=$data[\"root\"];\n $this->onelevel=$data[\"onelevel\"];\n //create menu structure\n $i=1;\n $currentid=0;\n foreach ($menuFile->Sections as $name => $section) {\n $section[\"id\"] = $i;\n $section[\"parentid\"] = 0;\n $section[\"caption\"] = $section[sprintf(\"name_%s\",$this->Page->Kernel->Language)];\n $section[\"image\"] = $section[\"image\"];\n $i++;\n if ($menuFile->HasItem($name,\"parent\")) {\n $parentname=strtolower($menuFile->GetItem($name,\"parent\"));\n $section[\"parentid\"]=$sections[$parentname][\"id\"];\n }\n //search in array current url\n if (!is_array($section[\"url\"]))\n $section[\"url\"]=array($section[\"url\"]);\n if (in_array($this->Page->PageURI,$section[\"url\"]) || $section[\"page_id\"]==$_page_id) $currentid=$section[\"id\"];\n $section[\"url\"]=$section[\"url\"][0];\n $sections[$name]=$section;\n }\n $this->data[\"selected_value\"]=$currentid;\n foreach($sections as $name => $section) $this->_list[]=$section;\n }", "protected function initTreeView() {\n $this->validateSourceData();\n $this->_module = Yii::$app->controller->module;\n if (empty($this->emptyNodeMsg)) {\n $this->emptyNodeMsg = Yii::t(\n 'kvtree', 'No valid tree nodes are available for display. Use toolbar buttons to add tree nodes.'\n );\n }\n $this->_hasBootstrap = $this->showTooltips;\n $this->breadcrumbs += [\n 'depth' => null,\n 'glue' => ' &raquo; ',\n 'activeCss' => 'kv-crumb-active',\n 'untitled' => Yii::t('kvtree', 'Untitled'),\n ];\n }", "protected function init(&$tree)\r\n {\r\n // mark path to parent\r\n $this->markBreadcrumb($tree->getNode($tree->getCurrent()));\r\n\r\n // init templates\r\n if (!$this->settings['template_dir']) {\r\n $this->settings['template_dir'] = __DIR__.'/Formatter/templates';\r\n }\r\n $this->settings['tpldir'] = implode('/', array(\r\n $this->settings['template_dir'],\r\n $this->settings['template_type'],\r\n $this->settings['template_variant']\r\n ));\r\n\r\n // silently \"fix\" wrong maxdepth (> max tree level)\r\n if (!$this->settings['maxdepth'] || $this->settings['maxdepth'] > $tree->getDepth()) {\r\n $this->settings['maxdepth'] = $tree->getDepth();\r\n }\r\n // check if mindepth is greater than 1 and maxdepth\r\n if ($this->settings['mindepth'] > $this->settings['maxdepth']) {\r\n throw new InvalidArgumentException(sprintf(\r\n \"Min depth [%s] > max depth [%s]!\",$this->settings['mindepth'],$this->settings['maxdepth']\r\n ));\r\n }\r\n\r\n // level classes\r\n foreach (array_values(array('ul_classes','li_classes','a_classes')) as $c) {\r\n if (isset($this->settings[$c]) && is_array($this->settings[$c])) {\r\n foreach ($this->settings[$c] as $key => $css) {\r\n // analyze >[=] and <[=]\r\n // may not the most elegant way, but works for now\r\n if (preg_match('/([\\>|\\<])(\\=?)(\\d+)/', $key, $m)) {\r\n switch ($m[1]) {\r\n case '>':\r\n $startlevel = (($m[2]=='=') ? $m[3] : $m[3]+1);\r\n for ($l=$startlevel;$l<$this->tree->getDepth()+1;$l++) {\r\n $this->settings[$c][$l] = $css;\r\n }\r\n unset($this->settings[$c][$key]);\r\n break;\r\n case '<':\r\n $stoplevel = (($m[2]=='=') ? $m[3]-1 : $m[3]);\r\n for ($l=1;$l<$stoplevel;$l++) {\r\n $this->settings[$c][$l] = $css;\r\n }\r\n unset($this->settings[$c][$key]);\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n }", "function CreateChildControls() {\n }", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "public function init()\n {\n $menus = P4Cms_Menu::fetchAll();\n $menuNames = array();\n foreach ($menus as $menu) {\n $menuNames[$menu->getId()] = $menu->getLabel();\n }\n\n // tack on the various dynamic items so they can\n // pick from those as well\n $group = 'Dynamic';\n $menuNames[$group] = array();\n $dynamicTypes = P4Cms_Navigation_DynamicHandler::fetchAll();\n foreach ($dynamicTypes as $dynamicType) {\n $label = $dynamicType->getLabel();\n $value = 'P4Cms_Navigation_DynamicHandler/' . $dynamicType->getId();\n\n $menuNames[$group][$value] = $label;\n }\n natcasesort($menuNames[$group]);\n\n $this->addElement(\n 'select',\n 'menu',\n array(\n 'label' => 'Menu',\n 'value' => P4Cms_Menu::DEFAULT_MENU,\n 'required' => true,\n 'description' => \"Choose a menu to display\",\n 'multiOptions' => $menuNames,\n 'onChange' => \"p4cms.menu.refreshSubForm(this.form);\"\n )\n );\n\n // add option to select the display root\n $this->addElement(\n 'select',\n P4Cms_Menu::MENU_ROOT,\n array(\n 'value' => '',\n 'label' => 'Display Root',\n )\n );\n $this->getElement(P4Cms_Menu::MENU_ROOT)\n ->getDecorator('htmlTag')\n ->setOption('class', 'menu-root');\n $this->_loadRootOptions();\n\n // add option to toggle inclusion of root item, when rooting a menu.\n $this->addElement(\n 'checkbox',\n P4Cms_Menu::MENU_KEEP_ROOT,\n array(\n 'label' => 'Include Root Item',\n 'description' => 'Set the display root (starting point) to display from.<br/>'\n . 'Optionally show the root item in the displayed menu.'\n )\n );\n P4Cms_Form::moveCheckboxLabel($this->getElement(P4Cms_Menu::MENU_KEEP_ROOT));\n $this->getElement(P4Cms_Menu::MENU_KEEP_ROOT)\n ->getDecorator('htmlTag')\n ->setOption('class', 'keep-root');\n $this->getElement(P4Cms_Menu::MENU_KEEP_ROOT)\n ->getDecorator('Description')\n ->setEscape(false);\n\n // add option to limit depth of the displayed menu.\n $options = array('' => 'Unlimited') + range(1, 10);\n $this->addElement(\n 'select',\n P4Cms_Menu::MENU_MAX_DEPTH,\n array(\n 'value' => '',\n 'label' => 'Maximum Depth',\n 'description' => 'Set the maximum depth of items to display.',\n 'multiOptions' => $options\n )\n );\n\n // add option to limit depth of the displayed menu.\n $options = array('' => 'Unlimited')\n + array_combine(range(1, 10), range(1, 10))\n + array_combine(range(15, 50, 5), range(15, 50, 5))\n + array_combine(range(60, 100, 10), range(60, 100, 10));\n $this->addElement(\n 'select',\n P4Cms_Menu::MENU_MAX_ITEMS,\n array(\n 'value' => '',\n 'label' => 'Maximum Items',\n 'description' => 'Set the maximum number of items to display.',\n 'multiOptions' => $options\n )\n );\n }", "public function __construct()\n {\n $this->children = [];\n }", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "public function customize_controls_init()\n {\n }", "protected function _init()\n\t{\n\t\tparent::_init();\n\t}", "protected function _initialize()\n {\n $this->_setupRoles();\n $this->_setupResources();\n $this->_setupPrivileges();\n $this->_saveAcl();\n }", "function loadedChildren()\r\n {\r\n //Calls childrens loaded recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->loaded();\r\n }\r\n }", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\n\t\treturn;\n\t}", "protected function _init()\n\t{\n\t\t// inicializando controladores auxiliares\n\t\t$this->_initControllers();\n\t\t\n\t\treturn;\n\t}", "private function init(): void\n {\n $this->initSuite();\n $cases = $this->getCaseNodes();\n foreach ($cases as $file => $nodeArray) {\n $this->initSuiteFromCases($nodeArray);\n }\n }", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "public function setup()\n {\n parent::setup();\n \n $formClass = $this->getChildFormClass();\n $collection = $this->getParentObject()->{$this->getRelationAlias()};\n $nbChilds = 0;\n $min = $this->getMinNbChilds();\n $max = $this->getMaxNbChilds();\n \n if ($min > $max && $max > 0)\n throw new RuntimeException('min cannot be greater than max.');\n \n // embed forms for each child element that is already persisted\n foreach ($collection as $childObject)\n {\n $form = new $formClass($childObject);\n $pk = $childObject->identifier();\n \n if ($childObject->exists() === false)\n throw new RuntimeException('Transient child objects are not supported.');\n \n if (count($pk) !== 1)\n throw new RuntimeException('Composite primary keys are not supported.');\n \n $this->embedForm(self::PERSISTENT_PREFIX.reset($pk), $form);\n $nbChilds += 1;\n }\n \n // embed as many additional forms as are needed to reach the minimum\n // number of required child objects\n for (; $nbChilds < $min; $nbChilds += 1)\n {\n $form = new $formClass($collection->get(null));\n $this->embedForm(self::TRANSIENT_PREFIX.$nbChilds, $form);\n }\n \n $this->validatorSchema->setPostValidator(new sfValidatorCallback(array(\n 'callback' => array($this, 'validateLogic'),\n )));\n }", "public function init()\n\t{\n\t\tparent::init();\n\t}", "public function init()\n\t{\n\t\tparent::init();\n\t}", "public function init()\n {\n parent::init();\n $this->initClass();\n }", "public function init() {\n\t\tparent::init();\n\t}", "function init() {\n if ($this->_init === false) {\n $this->_init = true;\n $this->doInit();\n }\n }", "function SetTreeData($data){\n $this->InitControl($data);\n\n }", "private function init()\n\t{\n\t\tforeach (isLoadedClass() as $objName)\n\t\t{\n\t\t\t$this->$objName =& loadClass('', '', $objName);\n\t\t}\n\t}", "protected abstract function init();", "public function init() {\r\n parent::init();\r\n }", "private function initDepth()\n {\n if ($this->depth !== null) { // Is de diepte reeds ingesteld?\n return;\n }\n if (isset(self::$current) == false) { // Gaat het om de eerste VirtualFolder (Website)\n if (($this instanceof Website) == false) {\n notice('VirtualFolder outside a Website object?');\n }\n self::$current = &$this; // De globale pointer laten verwijzen naar deze 'virtuele map'\n if (defined('Sledgehammer\\WEBPATH')) {\n $this->depth = preg_match_all('/[^\\/]+\\//', \\Sledgehammer\\WEBPATH, $match);\n } else {\n $this->depth = 0;\n }\n\n return;\n }\n $this->parent = &self::$current;\n self::$current = &$this; // De globale pointer laten verwijzen naar deze 'virtuele map'\n $this->depth = $this->parent->depth + $this->parent->depthIncrement;\n }", "public function set_up() {\n\t\tparent::set_up();\n\n\t\t// Mock page objects.\n\t\t$this->pages = array(\n\t\t\t0 => (object) array(\n\t\t\t\t'ID' => 100,\n\t\t\t\t'post_parent' => 0,\n\t\t\t),\n\t\t\t1 => (object) array(\n\t\t\t\t'ID' => 101,\n\t\t\t\t'post_parent' => 100,\n\t\t\t),\n\t\t\t2 => (object) array(\n\t\t\t\t'ID' => 102,\n\t\t\t\t'post_parent' => 100,\n\t\t\t),\n\t\t\t3 => (object) array(\n\t\t\t\t'ID' => 103,\n\t\t\t\t'post_parent' => 101,\n\t\t\t),\n\n\t\t\t// Not in the tree.\n\t\t\t4 => (object) array(\n\t\t\t\t'ID' => 104,\n\t\t\t\t'post_parent' => 9898989898,\n\t\t\t),\n\n\t\t\t5 => (object) array(\n\t\t\t\t'ID' => 105,\n\t\t\t\t'post_parent' => 100,\n\t\t\t),\n\t\t\t6 => (object) array(\n\t\t\t\t'ID' => 106,\n\t\t\t\t'post_parent' => 102,\n\t\t\t),\n\t\t\t7 => (object) array(\n\t\t\t\t'ID' => 107,\n\t\t\t\t'post_parent' => 106,\n\t\t\t),\n\t\t\t8 => (object) array(\n\t\t\t\t'ID' => 108,\n\t\t\t\t'post_parent' => 107,\n\t\t\t),\n\t\t);\n\t}", "public function init() {\n parent::init();\n }", "public function init() {\n parent::init();\n }", "public function init() {\n parent::init();\n }", "abstract protected function _init();", "abstract protected function _init();", "public function init()\n\t{\n\t\tif (isset($_GET['parent_id'])){\n\t\t\t$this->upButtonUrl='Yii::app()->controller->createUrl(\"priority\",array(\"id\"=>$data->primaryKey, \"move\"=>\"up\", \"parent_id\"=>\"'.$_GET['parent_id'].'\"))';\n\t\t\t$this->downButtonUrl='Yii::app()->controller->createUrl(\"priority\",array(\"id\"=>$data->primaryKey, \"move\"=>\"down\", \"parent_id\"=>\"'.$_GET['parent_id'].'\"))';\n\t\t}\t\t\n\t\t$this->initDefaultButtons();\n\t\t$this->registerClientScript();\n\t}", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "public function prepare_controls()\n {\n }", "abstract protected function init();", "abstract protected function init();", "abstract protected function init();", "abstract protected function init();", "abstract protected function init();", "abstract protected function init();", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "function populate() {\n $this->populateInputElements($this->children);\n }", "public function actionInit()\n {\n $this->initRoles($this->roles);\n $this->initPermissions($this->permissions);\n $this->initDependencies($this->dependencies);\n }", "public function Init() {\n\t\t\n\t\t$this->exceptions = TRUE;\n\t\t$this->SetAccess(self::ACCESS_ANY);\n\t\t$this->access_groups = array('admin','user','any');\n\t\t$this->current_group = 'any';\n\t\t$this->AccessMode(1);\n\t\t$this->SetModel(SYS.M.'menudata');\n\t\t$this->only_registered(FALSE);\n\t\tif(Helper::Get('admin'.S.'menu') == '')\n\t\t//$this->SetView(SYS.V . \"elements:nav\");\n\t\t$this->Inc(SYS.M.'model');\n\t}", "function scaffold_child_init() {\n\tdo_action( 'scaffold_child_init' );\n}", "public function init()\r\n {\r\n parent::init();\r\n }", "private function handle_init() {\n\t\tglobal $sb_enable_manga, $sb_enable_shop;\n\t\t$this->class_init();\n\t\tforeach($this->handles as $key => $handle) {\n\t\t\tif(('class-sb-product' == $key && !$sb_enable_shop) || ('class-sb-manga' == $key && !$sb_enable_manga)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\t$this->add($key);\n\t\t}\n\t}", "public function init()\r\n {\r\n \tparent::init();\r\n }", "private function init(){\r\n\t\t$this->readDescriptionConfig();\r\n\t\t$this->readKeywordsConfig();\r\n\t\t$this->readMetaConfig();\r\n\t\t$this->readLinksConfig();\r\n\t\t$this->readScriptsConfig();\r\n\t}", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init() {\n\n\t\t// Run an action so we can hook in beforehand\n\t\t$this->before( 'ubc_press_before_create_all_cpts' );\n\n\t\t// Determine which CPTs to create\n\t\t$this->determine();\n\n\t\t// Create the CPTs\n\t\t$this->create();\n\n\t\t// Run an action so we can hook in afterwards\n\t\t$this->after( 'ubc_press_after_create_all_cpts' );\n\n\t}", "public function init() {\n foreach ($this->_hidden as $col => $name) {\n if ($col == \"transaction_type_id\") {\n parent::createHidden($col);\n }\n }\n\n // Generating fields \n // for Form_Iadmin_TransactionTypeAdd\n foreach ($this->_fields as $col => $name) {\n switch ($col) {\n case \"transaction_type_name\":\n parent::createText($col);\n break;\n case \"nature\":\n parent::createRadioWithoutMultioptions($col);\n break;\n case \"is_adjustment\":\n parent::createCheckbox1($col);\n break;\n default:\n break;\n }\n\n //Generating radio\n // for Form_Iadmin_TransactionTypeAdd\n if (in_array($col, array_keys($this->_radio))) {\n parent::createRadio($col, $this->_radio[$col]);\n }\n }\n }", "public function init()\n {\n\n $this->addWPConfigs();\n $this->addSPLConfigs();\n $this->addControllerConfigs();\n $this->addFieldGroupConfigs();\n $this->addFieldConfigs();\n $this->addImageSizeConfigs();\n $this->addLayoutConfigs();\n $this->addModelConfigs();\n $this->addPostTypeConfigs();\n $this->addTaxonomyConfigs();\n $this->addTemplateFunctionConfigs();\n $this->addHookableConfigs();\n $this->addSearchConfigs();\n $this->addBaseThemeConfigs();\n\n }", "private function init()\n {\n // ensure the initialize function is called only once\n $k = get_called_class();\n if (!isset(self::$initialized[$k])) {\n $this->initialize();\n self::$initialized[$k] = true;\n }\n }", "public function init()\n {\n $this->_createBoard();\n $this->_createSlots();\n }", "private function init()\n {\n // #41776, dwildt, 1-\n// $this->pObj->objFltr3x->get_tableFields( );\n // #52486, 131005, dwildt, 2+\n // Init radialsearch filter and object\n $this->init_radialsearch();\n\n // RETURN: if there isn't any filter array\n if ( !$this->init_boolIsFilter() )\n {\n return;\n }\n // RETURN: if there isn't any filter array\n // Evaluate TREEVIEW filter\n // #41753, 121012, dwildt, 1+\n $this->eval_treeview();\n\n // #41776, dwildt, 2+\n // Set the array consolidation and the ts property SELECT\n $this->init_consolidationAndSelect();\n\n // Init localisation\n $this->init_localisation();\n\n // Init calendar area\n $this->init_calendarArea();\n\n // Init class var $andWhereFilter\n $this->init_andWhereFilter();\n\n // Set class var markerArray\n $this->set_markerArray();\n\n // Init the data of the cObj\n $this->cObjData_init();\n\n return;\n }", "public static function init() {\n self::$schema->level->options = array_keys(self::$levels);\n // Get all the needed views from the database;\n self::load_from_db();\n\n }", "public function InitAll ();", "public function initialise() {\n global $DB, $SITE;\n\n if ($this->initialised || during_initial_install()) {\n return $this->expandable;\n }\n\n $this->initialised = true;\n\n $this->rootnodes = array();\n $this->rootnodes['site'] = $this->add_course($SITE);\n $myurl = new moodle_url('/my');\n $this->rootnodes['mycourses'] = $this->add(get_string('mycourses'), $myurl, self::TYPE_ROOTNODE, null, 'mycourses');\n $this->rootnodes['courses'] = $this->add(get_string('courses'), null, self::TYPE_ROOTNODE, null, 'courses');\n\n // Branchtype will be one of navigation_node::TYPE_*.\n switch ($this->branchtype) {\n case 0:\n if ($this->instanceid === 'mycourses') {\n $this->load_courses_enrolled();\n } else if ($this->instanceid === 'courses') {\n $this->load_courses_other();\n }\n break;\n\n case self::TYPE_CATEGORY :\n $this->load_category($this->instanceid);\n break;\n\n case self::TYPE_COURSE :\n $course = $DB->get_record('course', array('id' => $this->instanceid), '*', MUST_EXIST);\n require_course_login($course, true, null, false, true);\n $this->page->set_context(context_course::instance($course->id));\n $coursenode = $this->add_course($course);\n $this->add_course_essentials($coursenode, $course);\n $this->load_course_sections($course, $coursenode);\n break;\n\n case self::TYPE_SECTION :\n // Section is shifted to page concept.\n $course = page_get_page_course($this->instanceid);\n $page = course_page::get($this->instanceid);\n $modinfo = get_fast_modinfo($course); // Original info is better to take here.\n require_course_login($course, true, null, false, true);\n $this->page->set_context(context_course::instance($course->id));\n $coursenode = $this->add_course($course);\n $this->add_course_essentials($coursenode, $course);\n if ($activities = $page->get_activities()) {\n foreach ($activities as $key => $cm) {\n $cm = $modinfo->cms[$key];\n if (!$cm->uservisible) {\n continue;\n }\n $activity = new stdClass;\n $activity->id = $cm->id;\n $activity->course = $course->id;\n $activity->section = 0;\n $activity->name = $cm->name;\n $activity->icon = $cm->icon;\n $activity->iconcomponent = $cm->iconcomponent;\n $activity->hidden = (!$cm->visible);\n $activity->modname = $cm->modname;\n $activity->nodetype = navigation_node::NODETYPE_LEAF;\n $activity->onclick = $cm->get_on_click();\n $url = $cm->get_url();\n if (!$url) {\n $activity->url = null;\n $activity->display = false;\n } else {\n $activity->url = $cm->get_url()->out();\n $activity->display = true;\n if (self::module_extends_navigation($cm->modname)) {\n $activity->nodetype = navigation_node::NODETYPE_BRANCH;\n }\n }\n $activities[$key] = $activity;\n }\n\n $this->load_course_sections($course, $coursenode, 0, $activities);\n }\n break;\n\n case self::TYPE_ACTIVITY :\n $course = page_get_cm_course($this->instanceid);\n $modinfo = get_fast_modinfo($course);\n $cm = $modinfo->get_cm($this->instanceid);\n require_course_login($course, true, $cm, false, true);\n $this->page->set_context(context_module::instance($cm->id));\n $coursenode = $this->load_course($course);\n if ($course->id != $SITE->id) {\n $this->load_course_sections($course, $coursenode, null, $cm);\n }\n $modulenode = $this->load_activity($cm, $course, $coursenode->find($cm->id, self::TYPE_ACTIVITY));\n break;\n\n default:\n throw new Exception('Unknown type');\n return $this->expandable;\n }\n\n if ($this->page->context->contextlevel == CONTEXT_COURSE &&\n $this->page->context->instanceid != $SITE->id) {\n $this->load_for_user(null, true);\n }\n\n $this->find_expandable($this->expandable);\n return $this->expandable;\n }", "public function init()\n {\n $this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_PersonalDetails(), 'subform_personaldetails');\n \t$this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_DataProtection(), 'subform_dataprotection');\n $this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_CorrespondenceDetails(), 'subform_correspondencedetails');\n $this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_InsuredAddress(), 'subform_insuredaddress');\n $this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_PolicyDetails(), 'subform_policydetails');\n $this->addSubForm(new LandlordsInsuranceQuote_Form_Subforms_IDD(), 'subform_idd');\n }", "protected function _init()\r\n\t{\r\n\t}", "private function init()\n\t{\n\t\treturn;\n\t}", "function initialize() {\n\t\t$this->number = 1;\n\t\t$this->post_types = array();\n\t\t$this->widget_form_fields = array();\n\n\t\tadd_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\tadd_action( 'save_post', array( $this, 'save_widget_post_meta' ), 10, 3 );\n\t}", "protected function _initInternVariables ()\n {\n parent::_initInternVariables();\n \n $this->levels = array ();\n $this->sep = $this->_element->getSeparator();\n $this->display_tag = $this->_element->getTagdisplay();\n $this->tag_label = $this->_element->getTaglabel();\n }", "protected function init() {return;}", "public function init()\n\t{\n\t\tif(isset($this->htmlOptions['id']))\n\t\t\t$id=$this->htmlOptions['id'];\n\t\telse\n\t\t\t$id=$this->htmlOptions['id']=$this->getId();\n\t\tif($this->url!==null)\n\t\t\t$this->url=CHtml::normalizeUrl($this->url);\n\t\t$cs=Yii::app()->getClientScript();\n\t\t$cs->registerCoreScript('treeview');\n\t\t$options=$this->getClientOptions();\n\t\t$options=$options===array()?'{}' : CJavaScript::encode($options);\n\t\t$cs->registerScript('Yii.CTreeView#'.$id,\"jQuery(\\\"#{$id}\\\").treeview($options);\");\n\t\tif($this->cssFile===null)\n\t\t\t$cs->registerCssFile($cs->getCoreScriptUrl().'/treeview/jquery.treeview.css');\n\t\telseif($this->cssFile!==false)\n\t\t\t$cs->registerCssFile($this->cssFile);\n\n\t\techo CHtml::tag('ul',$this->htmlOptions,false,false).\"\\n\";\n\t\techo self::saveDataAsHtml($this->data);\n\t}", "protected function init()\n\t{\n\t\t\n\t}", "protected function _init()\n {\n }", "public function init()\n {\n $this->ctrlModel = new Admin_Model_Acl_ControllersActions();\n $this->dbCtrl = new Admin_Model_DbTable_Acl_ModuleController();\n }", "function final_init() {\r\n\r\n if ($this->query_only) {\r\n $this->allow_new = False; # bool, True to allow new command\r\n $this->allow_edit = False; # bool, True to allow edit command\r\n $this->allow_delete = False; # bool, True to allow delete command\r\n $this->allow_view = False; # bool, True to allow view command\r\n }\r\n\r\n # give change for fields to init them self after all definitions\r\n\t\tforeach ($this->properties as $key=>$col) {\r\n $this->properties[$key]->colvarname = $key; # notify field of their called-name\r\n $this->properties[$key]->init($this);\r\n }\r\n\r\n # set session for each module's browse-mode default value\r\n if (!$this->browse_mode_forced and $_REQUEST['set_browse_mode'] != '')\r\n $_SESSION['module_browse_mode'][$this->module] = $_REQUEST['set_browse_mode'];\r\n\r\n\r\n if ($this->module == $_REQUEST['m'] and $_SERVER['REQUEST_METHOD'] == 'POST') { # only do this if I'm the currently active module in page\r\n $this->post_handler();\r\n }\r\n if ($this->module == $_REQUEST['m'] and $_SERVER['REQUEST_METHOD'] == 'GET') { # only do this if I'm the currently active module in page\r\n $this->get_handler();\r\n }\r\n\r\n }" ]
[ "0.81341165", "0.73886466", "0.70972496", "0.70422703", "0.6903976", "0.68299353", "0.66472375", "0.60718066", "0.60718066", "0.6004551", "0.59578294", "0.5954055", "0.5934141", "0.5878264", "0.5873288", "0.5860215", "0.58510524", "0.58357114", "0.5807293", "0.5804017", "0.579008", "0.57847124", "0.5767123", "0.5761977", "0.57585454", "0.575577", "0.5742801", "0.57218605", "0.57218605", "0.57218605", "0.571717", "0.5709487", "0.56944317", "0.5691583", "0.56689626", "0.5666169", "0.5628238", "0.5627008", "0.56199634", "0.5619557", "0.5619557", "0.5613971", "0.560616", "0.55856544", "0.5581066", "0.55552256", "0.5547016", "0.5542403", "0.55421066", "0.554045", "0.5520098", "0.5520098", "0.5520098", "0.5511075", "0.5511075", "0.55095154", "0.5506281", "0.5504597", "0.5504555", "0.5504555", "0.5504555", "0.5504555", "0.5504555", "0.5504555", "0.5503485", "0.55020475", "0.55017966", "0.54983026", "0.5490085", "0.5451157", "0.54359215", "0.54351044", "0.543244", "0.5430266", "0.5430266", "0.5430266", "0.5430266", "0.5430266", "0.5430266", "0.5430266", "0.5427484", "0.5424695", "0.5423811", "0.5416296", "0.5412868", "0.5412142", "0.54047567", "0.54041183", "0.53982794", "0.53822577", "0.5371647", "0.53675383", "0.5366324", "0.5364208", "0.53612894", "0.5355479", "0.5347744", "0.5346178", "0.5337612", "0.5329513" ]
0.7962084
1
Method Processes recursive load of control and all of it's children.
function loadRecursive() { $this->ControlOnLoad(); if ($this->HasControls()) { $keys = array_keys($this->Controls); $count = count($this->Controls); for ($i = 0; $i < $count ; $i++) { @$control = &$this->Controls[$keys[$i]]; $control->loadRecursive(); } } $this->_state = WEB_CONTROL_LOADED; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadedChildren()\r\n {\r\n //Calls childrens loaded recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->loaded();\r\n }\r\n }", "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "protected function childLoad() {}", "function initRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n @$control->Page = &$this->Page;\n $control->initRecursive();\n }\n }\n $this->_state = WEB_CONTROL_INITIALIZED;\n $this->ControlOnInit();\n }", "final public function load() {\n $this->childLoad();\n \\add_action('admin_menu', [$this, 'addAdminMenuEntries']);\n }", "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "protected function _load()\r\n {\r\n $page = new Model_Page();\r\n $children = $page->getChildren($this->_parentId);\r\n if ($children != null && $children->count() > 0) {\r\n foreach ($children as $child) {\r\n if ($child->show_on_menu == 1) {\r\n $this->items[] = new Digitalus_Menu_Item($child);\r\n }\r\n }\r\n }\r\n }", "private function load_children() {\n\t\tif (isset($this->_children)) return;\n\t\t$this->_children = array();\n\t\t$this->_testcases = array();\n\t\tif (!$this->exists()) return; // entity doesn't actually exist\n\t\tforeach (new DirectoryIterator($this->data_path()) as $child) {\n\t\t\t$filename = $child->getFilename();\n\t\t\tif ($child->isDot() || $filename[0] == '.') {\n\t\t\t\t// skip hidden files and ..\n\t\t\t} else if ($child->isDir()) {\n\t\t\t\t// subdirectory = child entity\n\t\t\t\t$this->_children[$filename] = new Entity($this, $filename);\n\t\t\t} else if (substr($filename,-3) == '.in') {\n\t\t\t\t// \".in\" file = testcase\n\t\t\t\t$this->_testcases []= substr($filename,0,-3);\n\t\t\t}\n\t\t}\n\t\tsort($this->_testcases);\n\t\t//ksort($this->_children);\n\t\tuasort($this->_children, 'compare_order');\n\t}", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "protected function loadTreeData() {}", "public function load() {\n\t\tforeach ($this->childWidgets as $widget) {\n\t\t\tif ($widget->getElement() == null) {\n\t\t\t\tConsole::error($widget);\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tDOM::appendChild($this->getElement(), $widget->getElement());\n\t\t\t$widget->load();\n\t\t}\n\t\tparent::load();\n\t}", "public function loadProcess() {\n\t\t// register page view\n\t\t$this->pixelPageView();\n\t\t\n\t\t// load next URL string\n\t\t$nextPosition = $this->position + 1;\n\t\t$lastPosition = array_pop(array_keys($this->pathOrderArr));\n\t\t\n\t\tfor ($i = $nextPosition; $i <= $lastPosition + 1; $i++) {\n\t\t\tif (array_key_exists($i, $this->pathOrderArr)) {\n\t\t\t\t$nextPosition = $i;\n\t\t\t\tbreak;\n\t\t\t}\t\n\t\t}\n\t\t\n\t\t// generate next page's URL\n\t\tif ($nextPosition > $lastPosition)\n\t\t\t$this->nextUrl = 'javascript: parent.location.href=\\''. $this->redirectURL .'\\''; // end of path, redirect to affiliate's URL\n\t\telse \n\t\t\t$this->nextUrl = $this->getNextUrl($nextPosition);\n\t\t\n\t\t$this->loadView();\n\t}", "function unloadRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n for ($i = 0; $i < count($this->Controls); $i++) {\n @$control = &$this->Controls[$keys[$i]];\n if(method_exists($control, \"unloadRecursive\")){\n $control->unloadRecursive();\n }\n $control=null;\n }\n }\n $this->ControlOnUnload();\n $this->Controls=array();\n }", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "abstract protected function loadPagetree(DataContainerInterface $objDc);", "private function setAllLoaded()\n {\n $class_reflection = new ReflectionClass(get_class($this));\n do {\n if ($class_reflection->isInstantiable())\n $this->setLoadedFromDb($class_reflection->getName());\n\n } while (($class_reflection = $class_reflection->getParentClass()) && # get the parent\n $class_reflection->getName() != __CLASS__); # check that we're not hitting the top\n }", "function preinit()\r\n {\r\n //Calls children's init recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->preinit();\r\n }\r\n }", "function LoadChildrenIntoTree($id, &$tree, $loadprops = false, $all = false)\n\t{\t\n\t\tglobal $gCms;\n\t\t$db = &$gCms->GetDb();\n\n\t\t// get the content rows\n\t\t$query = \"SELECT * FROM \".cms_db_prefix().\"content WHERE parent_id = ? AND active = 1 ORDER BY hierarchy\";\n\t\tif( $all )\n\t\t $query = \"SELECT * FROM \".cms_db_prefix().\"content WHERE parent_id = ? ORDER BY hierarchy\";\n\t\t$contentrows =& $db->GetArray($query, array($id));\n\t\t$contentprops = '';\n\n\t\t// get the content ids from the returned data\n\t\tif( $loadprops )\n\t\t {\n\t\t $child_ids = array();\n\t\t for( $i = 0; $i < count($contentrows); $i++ )\n\t\t {\n\t\t\t$child_ids[] = $contentrows[$i]['content_id'];\n\t\t }\n\t\t \n\t\t // get all the properties for the child_ids\n\t\t $query = 'SELECT * FROM '.cms_db_prefix().'content_props WHERE content_id IN ('.implode(',',$child_ids).') ORDER BY content_id';\n\t\t $tmp =& $db->GetArray($query);\n\n\t\t // re-organize the tmp data into a hash of arrays of properties for each content id.\n\t\t if( $tmp )\n\t\t {\n\t\t\t$contentprops = array();\n\t\t\tfor( $i = 0; $i < count($contentrows); $i++ )\n\t\t\t {\n\t\t\t $content_id = $contentrows[$i]['content_id'];\n\t\t\t $t2 = array();\n\t\t\t for( $j = 0; $j < count($tmp); $j++ )\n\t\t\t {\n\t\t\t\tif( $tmp[$j]['content_id'] == $content_id )\n\t\t\t\t {\n\t\t\t\t $t2[] = $tmp[$j];\n\t\t\t\t }\n\t\t\t }\n\t\t\t $contentprops[$content_id] = $t2;\n\t\t\t }\n\t\t }\n\t\t }\n\t\t\n\t\t// build the content objects\n\t\tfor( $i = 0; $i < count($contentrows); $i++ )\n\t\t {\n\t\t $row =& $contentrows[$i];\n\t\t $id = $row['content_id'];\n\n\t\t if (!in_array($row['type'], array_keys(ContentOperations::ListContentTypes()))) continue;\n\t\t $contentobj =& ContentOperations::CreateNewContent($row['type']);\n\t\t if ($contentobj)\n\t\t {\n\t\t\t$contentobj->LoadFromData($row, false);\n\t\t\tif( $loadprops && $contentprops && isset($contentprops[$id]) )\n\t\t\t {\n\t\t\t // load the properties from local cache.\n\t\t\t $props =& $contentprops[$id];\n\t\t\t $obj =& $contentobj->mProperties;\n\t\t\t $obj->mPropertyNames = array();\n\t\t\t $obj->mPropertyTypes = array();\n\t\t\t $obj->mPropertyValues = array();\n\t\t\t foreach( $props as $oneprop )\n\t\t\t {\n\t\t\t\t$obj->mPropertyNames[] = $oneprop['prop_name'];\n\t\t\t\t$obj->mPropertyTypes[$oneprop['prop_name']] = $oneprop['type'];\n\t\t\t\t$obj->mPropertyValues[$oneprop['prop_name']] = $oneprop['content'];\n\t\t\t }\n\t\t\t $contentobj->mPropertiesLoaded = true;\n\t\t\t }\n\n\t\t\t// cache the content objects\n\t\t\t$contentcache =& $tree->content;\n\t\t\t$contentcache[$id] =& $contentobj;\n\t\t }\n\t\t }\n\t}", "protected function processFileTree () {\n\t\t$files = $this->populateFileTree();\n\t\tforeach ($files as $file) {\n\t\t\t$this->processFile($file);\n\t\t}\n\t}", "public function loadAll()\n {\n $this->setAll(array());\n $d = dir($this->getPath());\n $this->load($d);\n $d->close();\n }", "abstract protected function loadFiletree(DataContainerInterface $objDc);", "public function __invoke() {\n\t\t// Register hooks for the group if part of group\n\t\tif ( null !== $this->group ) {\n\t\t\t$this->group->load( $this->group, $this->page );\n\t\t}\n\n\t\t$this->page->load( $this->page );\n\t}", "function InitChildControls() {\n }", "function InitControl($data=array()){\n $_page_id=$this->Page->Request->globalValue(\"_page_id\");\n $menuFile=&ConfigFile::GetInstance(\"menuIni\",$this->Page->Kernel->Settings->GetItem(\"module\",\"ResourcePath\").$data[\"file\"]);\n $this->parent_field_name=\"parentid\";\n $this->caption_field_name=\"caption\";\n $this->image_field_name=\"image\";\n $this->key_field_name=\"id\";\n\t\t\t$this->url_name=\"url\";\n $this->root=$data[\"root\"];\n $this->onelevel=$data[\"onelevel\"];\n //create menu structure\n $i=1;\n $currentid=0;\n foreach ($menuFile->Sections as $name => $section) {\n $section[\"id\"] = $i;\n $section[\"parentid\"] = 0;\n $section[\"caption\"] = $section[sprintf(\"name_%s\",$this->Page->Kernel->Language)];\n $section[\"image\"] = $section[\"image\"];\n $i++;\n if ($menuFile->HasItem($name,\"parent\")) {\n $parentname=strtolower($menuFile->GetItem($name,\"parent\"));\n $section[\"parentid\"]=$sections[$parentname][\"id\"];\n }\n //search in array current url\n if (!is_array($section[\"url\"]))\n $section[\"url\"]=array($section[\"url\"]);\n if (in_array($this->Page->PageURI,$section[\"url\"]) || $section[\"page_id\"]==$_page_id) $currentid=$section[\"id\"];\n $section[\"url\"]=$section[\"url\"][0];\n $sections[$name]=$section;\n }\n $this->data[\"selected_value\"]=$currentid;\n foreach($sections as $name => $section) $this->_list[]=$section;\n }", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "public function traverse(): void\n {\n // Register data hooks on the table\n $this->registerHandlerDefinitions($this->definition->tableName, $this->definition->tca);\n \n // Register data hooks on the types and fields\n $this->traverseTypes();\n $this->traverseFields();\n \n // Allow externals\n $this->eventBus->dispatch(new CustomDataHookTraverserEvent($this->definition, function () {\n $this->registerHandlerDefinitions(...func_get_args());\n }));\n }", "public function calc_tree()\n\t{\n\t\t$this->readTree(TRUE);\t\t\t// Make sure we have accurate data\n\t\tforeach ($this->class_parents as $cp)\n\t\t{\n\t\t\t$rights = array();\n\t\t\t$this->rebuild_tree($cp,$rights);\t\t// increasing rights going down the tree\n\t\t}\n\t}", "public function loadChildNodes()\n {\n $ids = $this->_cache->getBackend()->getChildNodeIds($this);\n return $this->setChildNodeIds($ids);\n }", "public function iterateChildren();", "abstract public function loadAll();", "protected function postLoad(){\n\t\t\t\n\t\t}", "function showHierarchy()\n\t{\n\t\tglobal $lng, $ilCtrl;\n\t\t\n\t\t$this->setTabs();\n\t\t\n\t\t$ilCtrl->setParameter($this, \"backcmd\", \"showHierarchy\");\n\t\t\n\t\tinclude_once(\"./Modules/LearningModule/classes/class.ilChapterHierarchyFormGUI.php\");\n\t\t$form_gui = new ilChapterHierarchyFormGUI($this->content_object->getType(), $_GET[\"transl\"]);\n\t\t$form_gui->setFormAction($ilCtrl->getFormAction($this));\n\t\t$form_gui->setTitle($this->obj->getTitle());\n\t\t$form_gui->setIcon(ilUtil::getImagePath(\"icon_st.svg\"));\n\t\t$form_gui->setTree($this->tree);\n\t\t$form_gui->setCurrentTopNodeId($this->obj->getId());\n\t\t$form_gui->addMultiCommand($lng->txt(\"delete\"), \"delete\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"cut\"), \"cutItems\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"copy\"), \"copyItems\");\n\t\t$form_gui->addMultiCommand($lng->txt(\"cont_de_activate\"), \"activatePages\");\n\t\tif ($this->content_object->getLayoutPerPage())\n\t\t{\t\n\t\t\t$form_gui->addMultiCommand($lng->txt(\"cont_set_layout\"), \"setPageLayout\");\n\t\t}\n\t\t$form_gui->setDragIcon(ilUtil::getImagePath(\"icon_pg.svg\"));\n\t\t$form_gui->addCommand($lng->txt(\"cont_save_all_titles\"), \"saveAllTitles\");\n\t\t$form_gui->addHelpItem($lng->txt(\"cont_chapters_after_pages\"));\n\t\t$up_gui = ($this->content_object->getType() == \"dbk\")\n\t\t\t? \"ilobjdlbookgui\"\n\t\t\t: \"ilobjlearningmodulegui\";\n\t\t$ilCtrl->setParameterByClass($up_gui, \"active_node\", $this->obj->getId());\n\t\t$ilCtrl->setParameterByClass($up_gui, \"active_node\", \"\");\n\n\t\t$ctpl = new ilTemplate(\"tpl.chap_and_pages.html\", true, true, \"Modules/LearningModule\");\n\t\t$ctpl->setVariable(\"HIERARCHY_FORM\", $form_gui->getHTML());\n\t\t$ilCtrl->setParameter($this, \"obj_id\", $_GET[\"obj_id\"]);\n\t\t\n\t\tinclude_once(\"./Modules/LearningModule/classes/class.ilObjContentObjectGUI.php\");\n\t\t$ml_head = ilObjContentObjectGUI::getMultiLangHeader($this->content_object->getId(), $this);\n\t\t\n\t\t$this->tpl->setContent($ml_head.$ctpl->get());\n\t}", "protected function _preloadContainerData()\r\n\t{\r\n\t\t$this->preloadTemplate('page_nav');\r\n\t}", "function load ()\n {\n $this->relationships = parent::_load ( $this->basepath ) ;\n }", "protected function buildRenderChildrenClosure() {}", "public function loadTree($par = 1){\r\n\t\t$user = new Table_Users();\r\n\t\t// load the user data\r\n\t\t$userData = $user->getDataById($_SESSION['userId']);\r\n\t\t//get the role id\r\n\t\t$role_id = $userData->role_id;\r\n\t\t// load the tree\r\n\t\techo $this->getChildrens($par, $role_id);\r\n\t}", "function ProcessMultilevel()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::ProcessMultilevel();\" . \"<HR>\";\n if ($this->listSettings->HasItem(\"MAIN\", \"PARENT_FIELD\")) {\n $this->parent_field = $this->listSettings->GetItem(\"MAIN\", \"PARENT_FIELD\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_PARENTFIELD_SETTINGS\", array(), true);\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"USE_SUB_CATEGORIES\")) {\n $this->use_sub_categories = $this->listSettings->GetItem(\"MAIN\", \"USE_SUB_CATEGORIES\");\n }\n else {\n $this->use_sub_categories = 0;\n }\n if ($this->use_sub_categories) {\n $this->ProcessMultilevelSubCategories();\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_MEGA_DELETE\")) {\n $this->mega_delete = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_MEGA_DELETE\");\n }\n else {\n $this->mega_delete = 0;\n }\n if ($this->listSettings->HasItem(\"MAIN\", \"ENABLE_NODE_MOVE\")) {\n $this->node_move = $this->listSettings->GetItem(\"MAIN\", \"ENABLE_NODE_MOVE\");\n }\n else {\n $this->node_move = 0;\n }\n\n }", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "abstract protected function getCurrentChildren(): array ;", "private function loadSubWidgets()\n {\n $subWidgets = [];\n // get widgets for the fields\n foreach ($this->fields as $index => $field) :\n $subWidgets[$index] = $field->widget;\n endforeach;\n\n $this->widget->setSubWidgets($subWidgets);\n }", "protected function loadParentId(){return 0;}", "public function load() {\r\n\t\t$this->includes();\r\n\t\t$this->inits();\r\n\t}", "protected function loadObjects() {\n if (!isset($this->objects)) {\n $this->obj_builder->toggleAutoload('on');\n $this->objects = $this->obj_builder->buildObjects();\n $this->obj_builder->toggleAutoload('off');\n }\n }", "function &GetAllContentAsHierarchy($loadprops, $onlyexpanded=null, $loadcontent = false)\n\t{\n\t\tdebug_buffer('', 'starting tree');\n\n\t\trequire_once(dirname(dirname(__FILE__)).'/Tree/Tree.php');\n\n\t\t$nodes = array();\n\t\tglobal $gCms;\n\t\t$db = &$gCms->GetDb();\n\n\t\t$cachefilename = TMP_CACHE_LOCATION . '/contentcache.php';\n\t\t$usecache = true;\n\t\tif (isset($onlyexpanded) || isset($CMS_ADMIN_PAGE))\n\t\t{\n\t\t\t#$usecache = false;\n\t\t}\n\n\t\t$loadedcache = false;\n\n\t\tif ($usecache)\n\t\t{\n\t\t\tif (isset($gCms->variables['pageinfo']) && file_exists($cachefilename))\n\t\t\t{\n\t\t\t\t$pageinfo =& $gCms->variables['pageinfo'];\n\t\t\t\t//debug_buffer('content cache file exists... file: ' . filemtime($cachefilename) . ' content:' . $pageinfo->content_last_modified_date);\n\t\t\t\tif (isset($pageinfo->content_last_modified_date) && $pageinfo->content_last_modified_date < filemtime($cachefilename))\n\t\t\t\t{\n\t\t\t\t\tdebug_buffer('file needs loading');\n\n\t\t\t\t\t$handle = fopen($cachefilename, \"r\");\n\t\t\t\t\t$data = fread($handle, filesize($cachefilename));\n\t\t\t\t\tfclose($handle);\n\n\t\t\t\t\t$tree = unserialize(substr($data, 16));\n\n\t\t\t\t\t#$variables =& $gCms->variables;\n\t\t\t\t\t#$variables['contentcache'] =& $tree;\n\t\t\t\t\tif (strtolower(get_class($tree)) == 'tree')\n\t\t\t\t\t{\n\t\t\t\t\t\t$loadedcache = true;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$loadedcache = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (!$loadedcache)\n\t\t{\n\t\t\t$query = \"SELECT id_hierarchy FROM \".cms_db_prefix().\"content ORDER BY hierarchy\";\n\t\t\t$dbresult =& $db->Execute($query);\n\n\t\t\tif ($dbresult && $dbresult->RecordCount() > 0)\n\t\t\t{\n\t\t\t\twhile ($row = $dbresult->FetchRow())\n\t\t\t\t{\n\t\t\t\t\t$nodes[] = $row['id_hierarchy'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$tree = new Tree();\n\t\t\tdebug_buffer('', 'Start Loading Children into Tree');\n\t\t\t$tree = Tree::createFromList($nodes, '.');\n\t\t\tdebug_buffer('', 'End Loading Children into Tree');\n\t\t}\n\n\t\tif (!$loadedcache && $usecache)\n\t\t{\n\t\t\tdebug_buffer(\"Serializing...\");\n\t\t\t$handle = fopen($cachefilename, \"w\");\n\t\t\tfwrite($handle, '<?php return; ?>'.serialize($tree));\n\t\t\tfclose($handle);\n\t\t}\n\n\t\tif( $loadcontent )\n\t\t {\n\t\t ContentOperations::LoadChildrenIntoTree(-1, $tree, false, true);\n\t\t }\n\n\t\tdebug_buffer('', 'ending tree');\n\n\t\treturn $tree;\n\t}", "protected function resolveChildren()\n {\n foreach ($this->unresolvedChildren as $name => $info) {\n $this->children[$name] = $this->create($name, $info['type'], $info['init_options'], $info['exec_options']);\n }\n\n $this->unresolvedChildren = array();\n }", "public function all_deps($handles, $recursion = \\false, $group = \\false)\n {\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "public function get_children();", "function populate() {\n $this->populateInputElements($this->children);\n }", "protected function loadFiles() {\n if ($this->loaded === true) {\n return;\n }\n $iter = new RecursiveDirectoryIterator($this->directory);\n $this->iterateFiles($iter);\n $this->loaded = true;\n }", "public function doLoad()\n {\n $this->DataSourceInstance->doLoad();\n }", "public function load() {\n $this->loadModules($this->dir['modules_core'], 'core');\n $this->loadModules($this->dir['modules_custom'], 'custom');\n $this->runModules();\n }", "protected function collectChildren(): void\n {\n $this->collection = new Collection();\n foreach ($this->rawResults as $blockChildContent) {\n $this->collection->add(Block::fromResponse($blockChildContent));\n }\n }", "private function inherit()\n\t{\n\t\t$this->log(1, '...Computing inheritance(s?)');\n\t\tforeach($this->_classes as $class_name => $class_def)\n\t\t{\n\t\t\t$this->log(2,\"For Class $class_name\");\n\t\t\t$parent_name = $class_def->get_parent_class_name();\n\t\t\tif(!empty($parent_name))\n\t\t\t{\n\t\t\t\t$this->log(2, \" parent = \".$parent_name);\n\t\t\t\t$parent_def = &$this->_classes[$parent_name];\n\t\t\t\t$parent_def->_children[] = $class_def;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$this->log(2, \" no parent\");\n\t\t\t\t$_top_classes[] = $class_def;\n\t\t\t}\n\t\t}\n\t\t\n\t\tforeach($_top_classes as $top_class)\n\t\t{\n\t\t\t$this->traverse_class_hierarchy($top_class);\n\t\t}\t\t\n\t}", "function ControlOnLoad(){\n parent::ControlOnLoad();\n }", "private function parse()\n {\n $this->parseChildrenNodes($this->_dom, $this->_rootNode);\n }", "public function getChildren() {}", "public function getChildren() {}", "public function getChildren() {}", "function init()\r\n {\r\n //Copy components to comps, so you can alter components properties\r\n //on init() methods\r\n $comps=$this->components->items;\r\n //Calls children's init recursively\r\n reset($comps);\r\n while (list($k,$v)=each($comps))\r\n {\r\n $v->init();\r\n }\r\n }", "public function load(): void\n {\n if ($this->paths->isEmpty()) {\n return;\n }\n\n foreach ((new Finder)->in($this->paths->toArray())->files() as $file) {\n $this->loadAction(\n $this->getClassnameFromPathname($file->getPathname())\n );\n }\n }", "public function load()\n {\n if( $this->autoload ) {\n $loader = new BasePathClassLoader( $this->paths );\n $loader->useEnvPhpLib();\n $loader->register();\n }\n\n foreach( $this->paths as $path ) {\n $di = new RecursiveDirectoryIterator($path);\n $ita = new RecursiveIteratorIterator($di);\n $regex = new RegexIterator($ita, '/^.+\\.php$/i', \n RecursiveRegexIterator::GET_MATCH);\n\n foreach( $regex as $matches ) foreach( $matches as $match ) {\n try {\n require_once $match;\n } \n catch ( Exception $e ) {\n echo \"$match class load failed.\\n\";\n }\n }\n }\n }", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "public function run()\n {\n \\catcher\\Utils::importTreeData($this->getPermissions(), 'permissions', 'parent_id');\n }", "public function initializeChildren() {\n\t\tif ($this->initialized === TRUE) {\n\t\t\treturn;\n\t\t}\n\t\t/** @var \\TYPO3\\CMS\\Core\\Resource\\Folder $folder */\n\t\t$subFolders = $this->folder->getSubfolders();\n\t\tforeach ($subFolders as $folder) {\n\t\t\t$f = new Storage($this->mapFolderIdToEntityName($folder->getName()), array());\n\t\t\t$f->setStorage($this->storage);\n\t\t\t$f->setFolder($folder);\n\t\t\t$this->addChild($f);\n\t\t}\n\n\t\t$files = $this->folder->getFiles();\n\t\tforeach ($files as $file) {\n\t\t\t$f = new File();\n\t\t\t$f->setFalFileObject($file);\n\t\t\t$this->addChild($f);\n\t\t}\n\t\t$this->initialized = TRUE;\n\t}", "function get_child_nodes_row_control($categoryID, $category_structure, $level, $current_category_id, $user_id, $control = false, $data_structure, $params = array())\n {\n $rs = '';\n if (!isset($category_structure['childs'][$categoryID]) || !is_array($category_structure['childs'][$categoryID])) {\n return '';\n }\n\n\n if (count($params) > 0) {\n $add_url = '&' . implode('&', $params);\n }\n\n foreach ($category_structure['childs'][$categoryID] as $child_id) {\n\n\n if ((0 != $this->getConfigValue('hide_empty_catalog')) and (0 == $data_structure['data'][$user_id][$child_id])) {\n $rs .= '';\n } else {\n\n if ($current_category_id == $child_id) {\n $selected = \" selected \";\n } else {\n $selected = \"\";\n }\n $this->j++;\n if (ceil($this->j / 2) > floor($this->j / 2)) {\n $row_class = \"row1\";\n } else {\n $this->j = 0;\n $row_class = \"row2\";\n }\n\n //print_r($category_structure['catalog'][$child_id]);\n //print_r($data_structure['data'][$user_id]);\n //echo \"category_id = $child_id, count = \".$data_structure['data'][$user_id][$child_id].'<br>';\n $rs .= '<tr>';\n\n if ($child_id == $current_category_id) {\n $row_class = 'active';\n }\n $rs .= '<td class=\"' . $row_class . '\"><a href=\"?topic_id=' . $child_id . '' . $add_url . '\">' . str_repeat('&nbsp;.&nbsp;', $level) . $category_structure['catalog'][$child_id]['name'] . '</a> (' . (int)$data_structure['data'][$user_id][$child_id] . ')' . ' <small>id:' . $child_id . '</small></td>';\n if ($control) {\n $edit_icon = '<a href=\"?action=structure&do=edit&id=' . $child_id . '\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/edit.png\" border=\"0\" alt=\"редактировать\" title=\"редактировать\"></a>';\n $delete_icon = '<a href=\"?action=structure&do=delete&id=' . $child_id . '\" onclick=\"if ( confirm(\\'' . Multilanguage::_('L_MESSAGE_REALLY_WANT_DELETE') . '\\') ) {return true;} else {return false;}\"><img src=\"' . SITEBILL_MAIN_URL . '/apps/admin/admin/template/img/delete.png\" border=\"0\" width=\"16\" height=\"16\" alt=\"удалить\" title=\"удалить\"></a>';\n }\n\n //$rs .= '<td class=\"'.$row_class.'\">'.$this->get_operation_type_name_by_id($category_structure['catalog'][$child_id]['operation_type_id']).'</td>';\n if ($control) {\n $rs .= '<td class=\"' . $row_class . '\">' . $edit_icon . $delete_icon . '</td>';\n }\n\n $rs .= '</tr>';\n //$rs .= '<option value=\"'.$child_id.'\" '.$selected.'>'.str_repeat(' . ', $level).$category_structure['catalog'][$child_id]['name'].'</option>';\n //print_r($category_structure['childs'][$child_id]);\n if (isset($category_structure['childs'][$child_id]) && count($category_structure['childs'][$child_id]) > 0) {\n $rs .= $this->get_child_nodes_row_control($child_id, $category_structure, $level + 1, $current_category_id, $user_id, $control, $data_structure, $params);\n }\n }\n }\n return $rs;\n }", "function AddControl(&$object) {\n if (!is_object($object)) {\n return;\n }\n //if (is_object($object->Parent))\n //$object->Parent->RemoveControl($object);\n $object->Parent = &$this;\n $object->Page = &$this->Page;\n @$this->Controls[$object->Name] = &$object;\n if ($this->_state >= WEB_CONTROL_INITIALIZED) {\n $object->initRecursive();\n if ($this->_state >= WEB_CONTROL_LOADED)\n $object->loadRecursive();\n }\n }", "protected function loadSubQueries()\n {\n foreach ($this->subQueries as $subQuery) {\n $subQuery($this->tableQuery);\n }\n }", "public function process()\n\t{\t\n\t\tif ($iDeleteId = $this->request()->getInt('delete'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->delete($iDeleteId))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', null, Phpfox::getPhrase('admincp.menu_successfully_deleted'));\t\n\t\t\t}\n\t\t}\n\t\t\n\t\tif ($aVals = $this->request()->getArray('val'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->updateOrder($aVals))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', array('parent' => $this->request()->getInt('parent')), Phpfox::getPhrase('admincp.menu_order_successfully_updated'));\t\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t$iParentId = $this->request()->getInt('parent');\t\t\n\t\tif ($iParentId > 0)\n\t\t{\n\t\t\t$aMenu = Phpfox::getService('admincp.menu')->getForEdit($iParentId);\n\t\t\tif (isset($aMenu['menu_id']))\n\t\t\t{\n\t\t\t\t$this->template()->assign('aParentMenu', $aMenu);\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$iParentId = 0;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$aTypes = Phpfox::getService('admincp.menu')->getTypes();\n\t\t$aRows = Phpfox::getService('admincp.menu')->get(($iParentId > 0 ? array('menu.parent_id = ' . (int) $iParentId) : array('menu.parent_id = 0')));\n\t\t$aMenus = array();\n\t\t$aModules = array();\n\t\t\n\t\tforeach ($aRows as $iKey => $aRow)\n\t\t{\n\t\t\tif(Phpfox::isModule($aRow['module_id']))\n\t\t\t{\n\t\t\t\tif (!$iParentId && in_array($aRow['m_connection'], $aTypes))\n\t\t\t\t{\n\t\t\t\t\t$aMenus[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tif ($aRow['m_connection'] == 'mobile' || $aRow['m_connection'] == 'main_right') {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$aModules[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\t\t\t\n\t\t\t}\n\t\t}\n\t\tunset($aRows);\t\t\n\t\n\t\t$this->template()\n\t\t\t->setBreadCrumb('CMS', '#cms')\n\t\t\t->setBreadcrumb('Menus', $this->url()->makeUrl('admincp.menu'), true)\n\t\t\t->setTitle('Menus')\n\t\t\t->assign(array(\n\t\t\t\t'aMenus' => $aMenus,\n\t\t\t\t'aModules' => $aModules,\n\t\t\t\t'iParentId' => $iParentId\n\t\t\t)\n\t\t);\n\t}", "protected function _Load_Pages() {\r\n $dir = untrailingslashit( plugin_dir_path(__FILE__ ) );\r\n // Recurssively load the directory\r\n $this->_Recusive_Load_Dir($dir.'/pages');\r\n // Fire the shortcode init action\r\n do_action('vcff_supports_pages_init',$this);\r\n }", "public function postLoad() { }", "protected function handleLoad()\n\t{\n\n\t\t/*\n\t\t*\tif safe mode or open_basedir is set, skip to using file_get_contents\n\t\t*\t(fixes \"CURLOPT_FOLLOWLOCATION cannot be activated\" curl_setopt error)\n\t\t*/\n\t\tif(ini_get('safe_mode') || ini_get('open_basedir'))\n\t\t{\n\t\t\t// do nothing (will pass on to getPafeFile/get_file_contents as isset($curlHtml) will fail)\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// load the page\n\t\t\t$this->getPageCurl();\n\n\t\t\t// parse the returned html for the data we want\n\t\t\t$curlHtml = $this->parseHtml();\n\t\t}\n\n\t\t// see if curl managed to get data\n\t\t// if not, try with get_file_contents\n\t\tif (isset($curlHtml) && !empty($curlHtml['name']) && !empty($curlHtml['count']) && !empty($curlHtml['img']))\n\t\t{\n\t\t\treturn $curlHtml;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// try loading with file_get_contents instead\n\t\t\t$this->getPageFile();\n\n\t\t\t// parse\n\t\t\t$data = $this->parseHtml();\n\n\t\t\t// return\n\t\t\treturn $data;\n\t\t}\n\n\t}", "protected function process_load($data)\n\t{\n\t\t$parsed_data = array();\n\t\tforeach ($data as $key => $value)\n\t\t{\n\t\t\tif (strpos($key, ':'))\n\t\t\t{\n\t\t\t\tlist($table, $field) = explode(':', $key);\n\t\t\t\tif ($table == $this->_table_name)\n\t\t\t\t{\n\t\t\t\t\t$parsed_data[$field] = $value;\n\t\t\t\t}\n\t\t\t\telseif ($field)\n\t\t\t\t{\n\t\t\t\t\t$this->_lazy[inflector::singular($table)][$field] = $value;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$parsed_data[$key] = $value;\n\t\t\t}\n\t\t}\n\t\t$this->_data = $parsed_data;\n\t}", "function CreateChildControls() {\n }", "public function reorderChildren()\n {\n $sql = \"select ID_PAGE from \" . $this->mode . \"PAGE where PAG_IDPERE=\" . $this->getID() . \" order by PAG_POIDS\";\n $stmt = $this->dbh->prepare(\"update \" . $this->mode . \"PAGE set PAG_POIDS=:PAG_POIDS where ID_PAGE=:ID_PAGE\");\n $PAG_POIDS = 1;\n $stmt->bindParam(':PAG_POIDS', $PAG_POIDS, PDO::PARAM_INT);\n foreach ($this->dbh->query($sql)->fetchAll(PDO::FETCH_COLUMN) as $ID_PAGE) {\n $stmt->bindValue(':ID_PAGE', $ID_PAGE, PDO::PARAM_INT);\n $stmt->execute();\n $PAG_POIDS ++;\n }\n }", "public function postLoad() {}", "function children() {\n\t\t$this->load_children();\n\t\treturn $this->_children;\n\t}", "public function loadAllClassesIncrementally()\n {\n }", "public function _load()\n {\n $query = new Query(\n \"SELECT *\n FROM `\" . Leder::TABLE . \"`\n WHERE `arrangement_fra` = '#fra'\n AND `arrangement_til` = '#til'\",\n [\n 'fra' => $this->getArrangementFraId(),\n 'til' => $this->getArrangementTilId()\n ]\n );\n\n $res = $query->getResults();\n while( $row = Query::fetch($res) ) {\n $this->add(\n Leder::loadFromDatabaseRow( $row )\n );\n }\n }", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public function getChildren();", "public static function loadAll();", "function display_node($parent, $level) {\n global $tam1;\n $tam2=array();\n global $leafnodes; \n global $responce;\n if($parent >0) {\n foreach ($tam1 as $row){\n\t if($row['ID_Parent']==$parent){\n\t\t $tam2[]=$row;\n\t }\n }\n } else {\n \n\t foreach ($tam1 as $row){\n\t if($row['ID_Parent']==''){\n\t\t $tam2[]=$row;\n\t }\n }\n }\n\n foreach ($tam2 as $row) {\n\tif(!$row['ID_Parent']) $valp = 'NULL'; else $valp = $row['ID_Parent'];\t\n\t//kiem tra node co phai lead\n\tif(array_key_exists($row['ID_Control'], $leafnodes)) $leaf='true'; else $leaf = 'false';\t\n\t$responce[] = array('ID_Control' => $row[\"ID_Control\"], 'ID_Parent' => $row[\"ID_Parent\"], 'Caption' => $row[\"Caption\"],'KieuControl' => $row[\"KieuControl\"],'IsBarButton' => $row[\"IsBarButton\"] ,'Icon' =>$row[\"Icon\"],'Active' =>$row[\"Active\"],'STT' =>$row[\"STT\"],'PageOpen' =>$row[\"PageOpen\"],'OpenType' =>$row[\"OpenType\"],'TenControl' =>$row[\"TenControl\"] , 'level' => $level, 'parent' => $valp, 'isLeaf' => $leaf, 'expanded' => \"true\", 'loaded' => \"true\");\n\t\n\t display_node($row['ID_Control'],$level+1);\n\t \n\t} \n \n return $responce;\n \n}", "function dumpChildrenJavascript()\r\n {\r\n //Iterates through components, dumping all javascript\r\n $this->dumpJavascript();\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n if ($v->inheritsFrom('Control'))\r\n {\r\n if ($v->canShow())\r\n {\r\n $v->dumpJavascript();\r\n }\r\n }\r\n else $v->dumpJavascript();\r\n }\r\n }", "protected function loadStructure(DataContainerInterface $objDc)\n\t{\n\t\t// Method ajaxTreeView is in TreeView.php - watch out!\n\t\techo $objDc->ajaxTreeView($this->getAjaxId(), intval(self::getPost('level')));\n\t\texit;\n\t}", "public function afterLoad(){\n $this->getType()->afterLoadProcess($this);\n return parent::afterLoad();\n }", "public function run() {\n $this->load_dependencies();\n $this->load_localization();\n $this->load_admin();\n $this->load_public();\n }", "function renderChildrenOf($pa, $root = null, $output = '', $level = 0) {\n if(!$root) $root = wire(\"pages\")->get(1);\n $output = '';\n $level++;\n foreach($pa as $child) {\n $class = '';\n $has_children = ($child->id == \"1018\" || $child->id == \"1263\" || count($child->children('include=all'))) ? true : false;\n\n if($has_children && $child !== $root) {\n if($level == 1){\n $class .= 'parent'; // first level boostrap dropdown li class\n //$atoggle .= ' class=\"dropdown-toggle\" data-toggle=\"dropdown\"'; // first level anchor attributes\n }\n }\n\n // make the current page and only its first level parent have an active class\n if($child === wire(\"page\") && $child !== $root){\n $class .= ' active';\n } else if($level == 1 && $child !== $root){\n if($child === wire(\"page\")->rootParent || wire(\"page\")->parents->has($child)){\n $class .= ' active';\n }\n }\n\n $class = strlen($class) ? \" class='\".trim($class).\"'\" : '';\n if($child->menu_item_url) {$childlink = $child->menu_item_url; } else { $childlink = $child->url; }\n $output .= \"<li$class><a href='$childlink'>$child->title</a>\";\n\n // If this child is itself a parent and not the root page, then render its children in their own menu too...\n \n if($has_children && $child !== $root) {\n \n // check for special menu items\n if ($child->id == \"1263\") { //services main item\n\n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n \n // promo\n $output .= '<div class=\"col3\">';\n $output .= '<h4 class=\"megamenu-col-title\">Promotional Offer:</h4>';\n $output .= '<a href=\"#\"><img src=\"http://placehold.it/270x244\" alt=\"\"></a>';\n $output .= '</div>';\n // end promo\n \n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('General');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Cosmetic Dentistry');\n $output .= megaMenuServicesList('Dental Restorations');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuServicesList('Specialty');\n $output .= '</div>';\n // end third column\n\n $output .= '</div></div>';\n }elseif ($child->id == \"1018\") {// blog main menu item\n \n $output .= '<div class=\"megamenu\"><div class=\"megamenu-row\">';\n\n // first column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('general-dentistry');\n $output .= megaMenuBlogCatList('sleep-apnea-snoring');\n $output .= '</div>';\n // end first column\n\n // second column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('cosmetic-dentistry');\n $output .= '</div>';\n // end second column\n\n // third column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('childrens-dentistry');\n $output .= '</div>';\n // end third column\n\n // dourth column\n $output .= '<div class=\"col3\">';\n $output .= megaMenuBlogCatList('sedation-dentistry'); \n $output .= megaMenuBlogCatList('restorations');\n $output .= '</div>';\n // end dourth column\n\n $output .= '</div></div>';\n \n }else {// default case for all other menu items\n\n $output .= renderChildrenOf($child->children('include=all'), $root, $output, $level);\n\n }\n }\n $output .= '</li>';\n\n\n }\n $outerclass = ($level == 1) ? \"menuzord-menu\" : 'dropdown';\n return \"<ul class='$outerclass'>$output</ul>\";\n}", "abstract protected function reloadPagetree(DataContainerInterface $objDc);", "function SetTreeData($data){\n $this->InitControl($data);\n\n }", "function loadSubModules()\n{\n $debug_prefix = debug_indent(\"Module->loadSubModules() {$this->ModuleID}:\");\n $submodule_elements = $this->_map->selectChildrenOfFirst('SubModules', null, null, true, true);\n if(count($submodule_elements) > 0){\n foreach($submodule_elements as $submodule_element){\n $submodule = $submodule_element->createObject($this->ModuleID);\n $subModuleID = $submodule_element->getAttr('moduleID', true);\n $this->SubModules[$subModuleID] = $submodule;\n print \"$debug_prefix Submodule $subModuleID parsed.\\n\";\n unset($submodule);\n }\n\n //special for best practices: add the IsBestPractice SummaryField\n if(isset($this->SubModules['bpc'])){\n $this->useBestPractices = true;\n $recordIDField = end($this->PKFields);\n\n $field_object = MakeObject(\n $this->ModuleID,\n 'IsBestPractice',\n 'SummaryField',\n array(\n 'name' => 'IsBestPractice',\n 'type' => 'tinyint',\n 'summaryFunction' => 'count',\n 'summaryField' => 'BestPracticeID',\n 'summaryKey' => 'RelatedRecordID',\n 'summaryModuleID' => 'bpc',\n 'localKey' => $recordIDField,\n 'phrase' => 'Is Best Practice|Whether the associated record is a best practice'\n )\n );\n//print \"best practice auto field\";\n//print_r($field_object);\n//die();\n $this->ModuleFields['IsBestPractice'] = $field_object;\n }\n\n //copies submodule conditions to summary fields\n foreach($this->ModuleFields as $fieldName => $field){\n if('summaryfield' == strtolower(get_class($field))){\n if(!$field->isGlobal){\n\n if(isset($this->SubModules[$field->summaryModuleID])){\n $subModule =& $this->SubModules[$field->summaryModuleID];\n if(count($subModule->conditions) > 0){\n //$field->conditions = $subModule->conditions;\n $field->conditions = array_merge($subModule->conditions, (array)$field->conditions);\n $this->ModuleFields[$fieldName] = $field;\n }\n unset($subModule);\n } else {\n trigger_error(\"The summaryfield '{$field->name}' requires a '{$field->summaryModuleID}' submodule.\", E_USER_ERROR);\n }\n }\n }\n }\n }\n debug_unindent();\n}", "function admin_preload ()\n\t{\n\t\t$this->CI->admin_navigation->child_link('configuration',65,'phpBB3',site_url('admincp/phpbb'));\n\t}", "private function parse_directory_tree()\r\n {\r\n foreach ($this->tc_step_data_list as $tc_index => $testcase_node)\r\n {\r\n $first_level = $testcase_node->get_first_level();\r\n $first_id = null;\r\n $second_level = $testcase_node->get_second_level();\r\n $second_id = null;\r\n $third_level = $testcase_node->get_third_level();\r\n $third_id = null;\r\n $fourth_level = $testcase_node->get_fourth_level();\r\n $fourth_id = null;\r\n $fifth_level = $testcase_node->get_fifth_level();\r\n $fifth_id = null;\r\n \r\n if ($first_level != null && $first_level != \"\" && trim($first_level) != \"\")\r\n {\r\n $first_id = $this->parse_directory_level(1, $first_level, \r\n $tc_index, $testcase_node, null);\r\n }\r\n \r\n if ($second_level != null && $second_level != \"\" && trim($second_level) != \"\")\r\n {\r\n $second_id = $this->parse_directory_level(2, $second_level,\r\n $tc_index, $testcase_node, $first_id);\r\n }\r\n else \r\n {\r\n // no second level dic, means testcase in first dic\r\n $tc_parent = $this->directory_array[1][$first_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($third_level != null && $third_level != \"\" && trim($third_level) != \"\")\r\n {\r\n $third_id = $this->parse_directory_level(3, $third_level,\r\n $tc_index, $testcase_node, $second_id);\r\n }\r\n else\r\n {\r\n // no third level dic, means testcase in second dic\r\n $tc_parent = $this->directory_array[2][$second_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fourth_level != null && $fourth_level != \"\" && trim($fourth_level) != \"\")\r\n {\r\n $fourth_id = $this->parse_directory_level(4, $fourth_level,\r\n $tc_index, $testcase_node, $third_id);\r\n }\r\n else\r\n {\r\n // no fourth level dic, means testcase in third dic\r\n $tc_parent = $this->directory_array[3][$third_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n continue;\r\n }\r\n \r\n if ($fifth_level != null && $fifth_level != \"\" || trim($fifth_level) != \"\")\r\n {\r\n // the last level dic\r\n $fifth_id = $this->parse_directory_level(5, $fifth_level,\r\n $tc_index, $testcase_node, $fourth_id);\r\n $tc_parent = $this->directory_array[5][$fifth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n else\r\n {\r\n // no fifth level dic, means testcase in fourth dic\r\n $tc_parent = $this->directory_array[4][$fourth_id];\r\n $tc_parent->add_tc_step($tc_index);\r\n }\r\n }\r\n }" ]
[ "0.69315404", "0.6532891", "0.64469945", "0.6173224", "0.609219", "0.60787094", "0.60412425", "0.5981586", "0.5907624", "0.5798729", "0.5756233", "0.5732483", "0.5731456", "0.5598184", "0.55416304", "0.55388695", "0.5474632", "0.54571885", "0.5452959", "0.5384407", "0.5330753", "0.5325004", "0.52941084", "0.5279703", "0.52501625", "0.5236911", "0.5227782", "0.5226148", "0.5218778", "0.5196793", "0.51945895", "0.51926374", "0.5187977", "0.5181928", "0.51344144", "0.51284945", "0.51251435", "0.51250315", "0.5111342", "0.5110611", "0.5107316", "0.50997424", "0.50613356", "0.50606704", "0.5045318", "0.5043749", "0.5041727", "0.50374913", "0.5034341", "0.5013158", "0.50124764", "0.5009882", "0.5003589", "0.4995692", "0.49802408", "0.4972346", "0.4964873", "0.4964873", "0.4964873", "0.49605945", "0.4958707", "0.49298397", "0.49256995", "0.49256995", "0.49050274", "0.48995033", "0.48938182", "0.4870811", "0.48690158", "0.48659408", "0.48577318", "0.48506513", "0.48502615", "0.48470256", "0.48417768", "0.48405206", "0.48404476", "0.48300487", "0.48235604", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48224592", "0.48176518", "0.48118934", "0.48083153", "0.47949183", "0.478949", "0.47862807", "0.47858456", "0.47858", "0.4785594", "0.4780469", "0.47799888", "0.4770042" ]
0.78501093
0
Method Processes recursive unload of control and all of it's children.
function unloadRecursive() { if ($this->HasControls()) { $keys = array_keys($this->Controls); for ($i = 0; $i < count($this->Controls); $i++) { @$control = &$this->Controls[$keys[$i]]; if(method_exists($control, "unloadRecursive")){ $control->unloadRecursive(); } $control=null; } } $this->ControlOnUnload(); $this->Controls=array(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "protected function deleteChildren() {}", "protected function childCleanup() {\n }", "function loadedChildren()\r\n {\r\n //Calls childrens loaded recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->loaded();\r\n }\r\n }", "Function __destruct(){\n\t\t$this->unload();\n\t}", "function ControlOnUnload() {\n }", "Function unload(){\n\t\t$this->removeBackup();\n\t\tif($this->info && isset($this->info['im'])){\n\t\t\t@imagedestroy($this->info['im']);\n\t\t}\n\t\t$this->info = false;\n\t}", "function CleanUp () {\n global $zOLDAPPLE;\n\n $criteria = array (\"groupInformation_tID\" => $this->tID,\n \"Body\" => DELETED_GROUP_ENTRY);\n $this->groupContent->SelectByMultiple ($criteria);\n\n // Break out if no deleted posts left. \n if ($this->groupContent->CountResult() == 0) return (TRUE);\n\n while ($this->groupContent->FetchArray ()) {\n $CHILDREN = new cGROUPCONTENT ();\n $childcriteria = array (\"parent_tID\" => $this->groupContent->tID,\n \"groupInformation_tID\" => $this->tID,\n \"Context\" => $zOLDAPPLE->Context);\n $CHILDREN->SelectByMultiple ($childcriteria);\n\n // If no children, delete.\n if ($CHILDREN->CountResult () == 0) {\n $this->groupContent->Delete ();\n $this->CleanUp ();\n } // if\n unset ($CHILDREN);\n } // while\n }", "public function cleanup()\n {\n foreach ($this->processes as $process) {\n $process->cleanup();\n }\n }", "public function unload()\n {\n\n $this->synchronized = true;\n $this->id = null;\n $this->newId = null;\n $this->data = [];\n $this->savedData = [];\n $this->orm = null;\n\n $this->multiRef = [];\n $this->i18n = null;\n\n }", "public function cleanup()\n {\n // Remove old parts without binaries \n $this->removePartsWithoutBinary();\n \n // Remove parts where the binary is missing\n $this->removePartsWithMissingBinary();\n \n // Remove binaries without parts\n $this->removeBinariesWithoutParts();\n }", "public function __destruct()\n\t{\n\t\t$this->tree = false;\n\t\t$this->current_category = false;\n\t\t$this->tree_steped_item = false;\n\t\t$this->tree_items = 0;\n\t\t$this->walk_step = 0;\n\t\t$this->parent_data = false;\n\t}", "public function detachAll() {}", "function cleanup()\n {\n if (is_object( $this->roottag )) {\n $this->roottag->clear_subtags();\n }\n }", "public function __destruct() {\n if (class_exists('\\Sleepy\\Hook')) {\n Hook::addAction($this->clean_class() . '_postprocess');\n }\n }", "protected function parentCleanup() {\n }", "function __destruct()\n {\n unset($this->parent);\n unset($this->sz);\n }", "private function undo_cleanup_actions() {\n global $db;\n $elements_locked = array();\n $undo_nodes = $db->fetch_table(\"SELECT * FROM `\".$this->table.\"_undo` ORDER BY ID_UNDO DESC\");\n for ($i = 0; $i < count($undo_nodes); $i++) {\n $node = $undo_nodes[$i];\n foreach ($elements_locked as $id => $lock) {\n if (($node[\"FK_PARENT\"] == $id) ||\n (!$this->element_read($id)) ||\n ($this->element_is_child($node[\"FK_PARENT\"], $id)) ||\n ($this->element_is_child($node[\"FK_PARENT_PREV\"], $id))) {\n $db->querynow(\"DELETE FROM `\".$this->table.\"_undo` WHERE ID_UNDO=\".$node[\"ID_UNDO\"]);\n }\n }\n if ($node[\"ACTION\"] == \"MOVE\") {\n // Element wurde verschoben\n $elements_locked[$node[\"FK_PARENT\"]] = true;\n $elements_locked[$node[\"FK_PARENT_PREV\"]] = true;\n }\n }\n }", "static function shutdown() {\n\t\tif (self::hasCurrent()) {\n\t\t\tself::$_ctrl->__destruct();\n\t\t\tself::$_ctrl = null;\n\t\t}\n\t}", "public function __destruct()\n {\n\t\t\n $data = $this->data;\n\t\t\n\t\t foreach ($this->template as $key => $value) {\n try {\n include_once($value);\n } catch (Exception $e) {\n include_once($this->error['404']);\n }\n }\n\n $this->renderFooter();\n\n }", "function deleteChilds(){\n\t\t$this->db->query(\"SELECT ID FROM \" . EXPORT_TABLE . ' WHERE ParentID=' . intval($this->ID));\n\t\twhile($this->db->next_record()){\n\t\t\t$child = new we_export_export($this->db->f(\"ID\"));\n\t\t\t$child->delete();\n\t\t}\n\t}", "private function doWorkChild() {\n Log5PHP_MDC::put('Generation', 'child');\n $this->doWorkChildImpl();\n $this->childCleanup();\n exit();\n }", "protected function doCleanup() {\n $base = $this->tempPath();\n $dirs = array($base);\n\n if (is_dir($base)) {\n foreach ($this->recurse($base) as $file) {\n if (is_dir($file)) {\n $dirs[] = $file;\n } else {\n unlink($file);\n }\n }\n\n foreach (array_reverse($dirs) as $path) {\n rmdir($path);\n }\n }\n\n foreach (array(self::LOGFILE_STUB, self::STATEFILE_STUB, self::ZIPTEMP_STUB, self::ZIPCOMP_STUB) as $extra_file) {\n if (is_file($base.$extra_file)) {\n unlink($base.$extra_file);\n }\n }\n }", "protected function unsetHiddenModules() {}", "protected function childLoad() {}", "private function _prune()\n {\n if (empty($this->_files) && empty($this->_subdirectories)) {\n $this->_element->delete();\n if ($this->_parent instanceOf Horde_Pear_Package_Xml_Directory) {\n $this->_parent->_deleteSubdirectory($this->_element->getName());\n }\n }\n }", "protected function childScopeClosed()\n {\n }", "public function tear_down() {\n\t\t$this->registry = null;\n\n\t\tparent::tear_down();\n\t}", "function unserializeChildren()\r\n {\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->unserialize();\r\n }\r\n }", "public function __destruct()\n {\n Bigace_Hooks::remove_filter('admin_menu', array($this, 'getAdminMenu'), 10, 2);\n Bigace_Hooks::remove_filter('credits', array($this, 'getAdminCredits'));\n\n Bigace_Hooks::remove_action('flush_cache', array($this, 'flushAll'));\n Bigace_Hooks::remove_action('expire_page_cache', array($this, 'flushAll'));\n }", "protected function garbageCollect()\n {\n \n }", "function reset_process(){ $this->model->closing(); $this->transmodel->closing(); }", "public function tear_down() {\n\t\tunset( $GLOBALS['link'] );\n\t\tparent::tear_down();\n\t}", "public function after_restore(){\n \tglobal $DB;\n \t\n \t\n \t$pagemenuid = $this->get_activityid();\n\n \tif ($modulelinks = $DB->get_records('pagemenu_links', array('pagemenuid' => $pagemenuid))){\n \t\tforeach($modulelinks as $ml){\n \t\t\t\n \t\t\t$ml->previd = $this->get_mappingid('pagemenu_links', $ml->previd);\n \t\t\t$ml->nextid = $this->get_mappingid('pagemenu_links', $ml->nextid);\n\n\t\t\t\tif ($ml->type == 'module'){\n\t \t\t\tif ($link = $DB->get_record('pagemenu_link_data', array('linkid' => $ml->id))){\n\t \t\t\t\t$link->value = $this->get_mappingid('course_module', $link->value);\n\t \t\t\t\t$DB->update_record('pagemenu_link_data', $link);\n\t \t\t\t} else {\n\t\t\t\t\t\t$this->get_logger()->process(\"Failed to restore dependency for pagemenu link '$ml->name'. \", backup::LOG_ERROR); \t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t$DB->update_record('pagemenu_links', $ml);\n \t\t}\n \t} \t \t\n }", "public function endChildren()\n {\n parent::endChildren();\n\n $this->call($this->ascendCallback);\n }", "protected function _afterLoad()\n {\n foreach ($this->_items as $item) {\n $this->getResource()->unserializeFields($item);\n }\n return parent::_afterLoad();\n }", "public function __destruct()\n\t{\n\t\tunset(self::$handles[spl_object_hash($this)]);\n\t}", "protected function emitPostProcessTreeDataSignal() {}", "public static function cleanupRebuildIndicator()\n {\n \\Includes\\Utils\\FileManager::deleteFile(static::getRebuildIndicatorFileName());\n }", "private function rebuildLevel()\n\t{\n\t\techo \"Rebuilding \" . $this->OutputPath . PHP_EOL;\n\n\t\t$InstanceFiles = $this->orderInstances();\n\t\t$this->WriteFile = fopen( $this->OutputPath, \"w\" );\n\t\tfwrite( $this->WriteFile, $this->getHeader( sizeof( $InstanceFiles ) ) );\n\n\t\tforeach( $InstanceFiles as $InstanceFile )\n\t\t{\n\t\t\t$this->Instance = json_decode( file_get_contents( $InstanceFile ) );\n\n\t\t\tif( ! $this->Instance || empty( $this->Instance ) )\n\t\t\t{\n\t\t\t\tvar_dump( $InstanceFile );\n\t\t\t\tdie( 'failed to decode json!' );\n\t\t\t}\n\t\t\t$this->processInstance();\n\t\t}\n\n\t\tfclose( $this->WriteFile );\n\t}", "public function unloadValue()\n {\n // Clear LOADED state bit\n $this->_state &= ~self::LOADED;\n\n $this->_value = null;\n }", "function reset_process(){ $this->model->closing(); }", "public function __destruct() {\n\t\t\tparent::__destruct();\n\t\t\tunset($this->after);\n\t\t\tunset($this->before);\n\t\t\tunset($this->builder);\n\t\t\tunset($this->data_source);\n\t\t}", "public function shutdownObject()\n {\n if ($this->directoriesChanged === true) {\n $this->cache->set($this->identifier . '_directoriesAndFiles', json_encode($this->directoriesAndFiles));\n }\n $this->changeDetectionStrategy->shutdownObject();\n }", "function RemoveControl(&$object) {\n\n \t//echo 'here';\n\n if (!is_object($object) || !is_object($this->FindControl($object->Name)))\n return;\n unset($object->Parent);\n unset($this->Controls[$object->Name]);\n }", "function __destruct() {\n\t\tparent::__destruct();\n\t}", "public function cleanup() : void\n {\n unset($this->groups);\n }", "private function delSubs($id){\n\t\t$db = Zend_Registry::get('db');\n\t\t$select = $db->select()\n\t\t\t\t\t->from('pages')\n\t\t\t\t\t->where('parent_id = ?',$id);\n\t\t$results = $db->fetchAll($select);\n\t\tif($results){\n\t\t\t$db->delete('pages',array(\n\t\t\t\t'id = ?' => $results[id],\n\t\t\t));\n\t\t\t$db->delete('routes',array(\n\t\t\t\t'type = ?' => 'content',\n\t\t\t\t'seg_id = ?' => $results[id],\n\t\t\t));\n\t\t\t// recurse through possible child items\n\t\t\t$this->delSubs($results[id]);\n\t\t}\n\t}", "abstract protected function reloadFiletree(DataContainerInterface $objDc);", "public function tear_down(): void {\n\t\t$this->dispatcher->execute();\n\t}", "public function __destruct()\n {\n static $depth = 0;\n // destruct can be called several times\n if ($depth < self::$maximumDepthLevelAllowed\n && isset($this->rows)\n ) {\n $depth++;\n foreach ($this->getRows() as $row) {\n destroy($row);\n }\n unset($this->rows);\n Piwik_DataTable_Manager::getInstance()->setTableDeleted($this->getId());\n $depth--;\n }\n }", "abstract protected function reloadPagetree(DataContainerInterface $objDc);", "function import_end() {\n\t\t//wp_import_cleanup( $this->id );\n\n\t\twp_cache_flush();\n\t\tforeach ( get_taxonomies() as $tax ) {\n\t\t\tdelete_option( \"{$tax}_children\" );\n\t\t\t_get_term_hierarchy( $tax );\n\t\t}\n\n\t\twp_defer_term_counting( false );\n\t\twp_defer_comment_counting( false );\n\n\t\techo '<p>导入成功.' . ' <a href=\"' . admin_url() . '\">Have fun!</a>' . '</p>';\n\n\t\tdo_action( 'import_end' );\n\t}", "public function __destruct() {\n\t\t$this->clean();\n\t}", "public function on_root_element_end() {\n\n // drop the ids temp table\n backup_controller_dbops::drop_backup_ids_temp_table($this->converter->get_id());\n }", "private function load_children() {\n\t\tif (isset($this->_children)) return;\n\t\t$this->_children = array();\n\t\t$this->_testcases = array();\n\t\tif (!$this->exists()) return; // entity doesn't actually exist\n\t\tforeach (new DirectoryIterator($this->data_path()) as $child) {\n\t\t\t$filename = $child->getFilename();\n\t\t\tif ($child->isDot() || $filename[0] == '.') {\n\t\t\t\t// skip hidden files and ..\n\t\t\t} else if ($child->isDir()) {\n\t\t\t\t// subdirectory = child entity\n\t\t\t\t$this->_children[$filename] = new Entity($this, $filename);\n\t\t\t} else if (substr($filename,-3) == '.in') {\n\t\t\t\t// \".in\" file = testcase\n\t\t\t\t$this->_testcases []= substr($filename,0,-3);\n\t\t\t}\n\t\t}\n\t\tsort($this->_testcases);\n\t\t//ksort($this->_children);\n\t\tuasort($this->_children, 'compare_order');\n\t}", "function _nested_db_tree()\r\n\t{\r\n\t\t$this->_release_lock(true);\r\n\t}", "public function __destruct()\n {\n if (true === $this->parent) {\n foreach ($this->pid as $pid => $task) {\n posix_kill($pid, SIGTERM);\n Redis::init()->rpush('tasks', json_encode([\n 'class' => $task['class'],\n 'link' => $task['link'],\n ]));\n }\n }\n }", "public function closeChild()\n\t{\n\t\t$this->_lastChild = null;\n\t}", "public function tear_down() {\n\t\t$registry = WP_Block_Type_Registry::get_instance();\n\n\t\tforeach ( array( 'core/test-static', 'core/test-dynamic', 'tests/notice' ) as $block_name ) {\n\t\t\tif ( $registry->is_registered( $block_name ) ) {\n\t\t\t\t$registry->unregister( $block_name );\n\t\t\t}\n\t\t}\n\n\t\tparent::tear_down();\n\t}", "function __destruct(){\n\t\tparent::__destruct();\n\t}", "function __destruct() {\t\n\t\tparent::__destruct(); \n }", "function __destruct() {\t\n\t\tparent::__destruct(); \n }", "function __destruct() {\t\n\t\tparent::__destruct(); \n }", "function __destruct() {\t\n\t\tparent::__destruct(); \n }", "public function tearDown() {\n foreach ($this->registered as $l) {\n \\lang\\ClassLoader::removeLoader($l);\n }\n }", "public function deleteChildren(){\n $this->publicEnvironments()->delete();\n $this->privateEnvironments()->delete();\n $collections = Collection::where('project_id', $this->id)->get();\n\n foreach($collections as $collection){\n $collection->items()->delete();\n $collection->delete();\n }\n }", "protected function resolveChildren()\n {\n foreach ($this->unresolvedChildren as $name => $info) {\n $this->children[$name] = $this->create($name, $info['type'], $info['init_options'], $info['exec_options']);\n }\n\n $this->unresolvedChildren = array();\n }", "public function __destruct()\n {\n if ($this->handle[self::PHP]) {\n $this->_close(self::PHP);\n }\n if (is_resource($this->handle[self::PERL])) {\n $this->_close(self::PERL);\n }\n if (is_resource($this->handle[self::PERL_COMPLETE])) {\n $this->_close(self::PERL_COMPLETE);\n }\n if (is_resource($this->handle[self::ERROR])) {\n $this->_close(self::ERROR);\n }\n }", "public function __destruct()\n {\n imagedestroy($this->layout);\n foreach((array)$this->images as $image) {\n imagedestroy($image);\n }\n }", "public function afterDelete()\n {\n foreach (static::find()->where(['parent_id' => $this->id])->all() as $item) {\n $item->delete();\n }\n }", "public function cleanup()\n {\n $wiff = WIFF::getInstance();\n $xml = new DOMDocument();\n $xml->load($wiff->contexts_filepath);\n $xpath = new DOMXPath($xml);\n $query = sprintf(\"/contexts/context[@name='%s']/modules/module[@status='downloaded']\", $this->name);\n $moduleDom = $xpath->query($query);\n if ($moduleDom->length <= 0) {\n return true;\n }\n for ($i = 0; $i < $moduleDom->length; $i++) {\n $elmt = $moduleDom->item($i);\n $module = new Module($this, null, $elmt);\n $module->cleanupDownload();\n $elmt->parentNode->removeChild($elmt);\n }\n $ret = $xml->save($wiff->contexts_filepath);\n if ($ret === false) {\n $this->errorMessage = sprintf(\"Error saving contexts.xml '%s'.\", $wiff->contexts_filepath);\n return false;\n }\n return true;\n }", "public function self_destruct(){\n foreach($this->donations() as $index => $obj)$obj->self_destruct();\n parent::self_destruct();\n }", "public function clearChildren(): void\n {\n if ($this->children instanceof Collection) {\n $this->children = new Collection;\n return;\n }\n\n $this->children = [];\n }", "protected function _after() {\n\t\t$this->uFileSystem = null;\n\t\tparent::_after ();\n\t}", "public function __destruct() {\n\t\tparent::__destruct();\n\t}", "public function __destruct()\n {\n DirectoryRemover::remove($this->path);\n }", "public function onAfterDeleteCleaning() {\n\t\t$classHierarchyProbe = new DataObjectOnDeleteDecorator_ClassHierarchyProbe($this->owner);\n\t\t$relatedClasses = $classHierarchyProbe->getRelatedClasses();\n\t\t\n\t\t$this->cleanRelatedRelations($relatedClasses);\n\t\t$this->cleanRelatedTables($relatedClasses);\n\t}", "function __destruct() {\r\n parent::__destruct();\r\n }", "function __destruct()\r\n\t{\r\n\t\tparent::__destruct();\r\n\t}", "function __destruct()\r\n\t{\r\n\t\tparent::__destruct();\r\n\t}", "public function removeAllSubGroups() {}", "public function __destruct()\n {\n if ($this->handle[self::PHP]) {\n $this->_close(self::PHP);\n }\n if (is_resource($this->handle[self::PERL])) {\n $this->_close(self::PERL);\n }\n if (is_resource($this->handle[self::PERL_COMPLETE])) {\n $this->_close(self::PERL_COMPLETE);\n }\n if (is_resource($this->handle[self::ERROR])) {\n $this->_close(self::ERROR);\n }\n }", "public function cleanUp()\n\t{\n\t\tif (file_exists(__DIR__ . DIRECTORY_SEPARATOR . 'data' . DIRECTORY_SEPARATOR . 'elements-tree.php')) {\n\t\t\tinclude(__DIR__ . DIRECTORY_SEPARATOR . 'data' . DIRECTORY_SEPARATOR . 'elements-tree.php');\n\t\t\tif (!isset($elements) or !is_array($elements))\n\t\t\t\treturn;\n\n\t\t\t$db = \\Model\\Db\\Db::getConnection();\n\n\t\t\tforeach ($elements as $el => $elData) {\n\t\t\t\tif (!$elData['table'])\n\t\t\t\t\tcontinue;\n\n\t\t\t\tif ($elData['order_by'] and $elData['order_by']['custom']) {\n\t\t\t\t\t$qryOrderBy = [];\n\t\t\t\t\tforeach ($elData['order_by']['depending_on'] as $field)\n\t\t\t\t\t\t$qryOrderBy[] = $field;\n\t\t\t\t\t$qryOrderBy[] = $elData['order_by']['field'];\n\n\t\t\t\t\t$righe = $db->selectAll($elData['table'], [], [\n\t\t\t\t\t\t'order_by' => $qryOrderBy,\n\t\t\t\t\t\t'stream' => true,\n\t\t\t\t\t]);\n\n\t\t\t\t\t$lastParent = null;\n\t\t\t\t\t$currentOrder = 0;\n\t\t\t\t\tforeach ($righe as $r) {\n\t\t\t\t\t\t$parentString = [];\n\t\t\t\t\t\tforeach ($elData['order_by']['depending_on'] as $field)\n\t\t\t\t\t\t\t$parentString[] = $r[$field];\n\t\t\t\t\t\t$parentString = implode(',', $parentString);\n\t\t\t\t\t\tif ($parentString and $parentString !== $lastParent) {\n\t\t\t\t\t\t\t$lastParent = $parentString;\n\t\t\t\t\t\t\t$currentOrder = 0;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$currentOrder++;\n\n\t\t\t\t\t\tif ($r[$elData['order_by']['field']] != $currentOrder) {\n\t\t\t\t\t\t\t$db->update($elData['table'], $r[$elData['primary']], [\n\t\t\t\t\t\t\t\t$elData['order_by']['field'] => $currentOrder,\n\t\t\t\t\t\t\t]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function removeChildNodes() {}", "protected function finalize()\n\t{\n\t\tglobal $ilCtrl, $lng;\n\t\t\n\t\t// to make exercise gui load assignment\n\t\t$_GET[\"ass_id\"] = $_REQUEST[\"ass\"];\n\t\t\t\t\n\t\t// #11173 - ref_id is needed for notifications\n\t\t$exc_ref_id = array_shift(ilObject::_getAllReferences($_REQUEST[\"exc\"]));\n\t\n\t\tinclude_once \"Modules/Exercise/classes/class.ilObjExerciseGUI.php\";\n\t\t$exc_gui = new ilObjExerciseGUI(null, $exc_ref_id, true);\n\t\t$exc_gui->submitBlog($this->node_id);\n\t\t\n\t\tilUtil::sendSuccess($lng->txt(\"blog_finalized\"), true);\n\t\t$ilCtrl->redirect($this, \"render\");\n\t}", "abstract public static function cleanShutDown();", "public function postProcess()\n\t\t{\n\t\t\tforeach ($this->m_activeExtensions as $extension)\n\t\t\t{\n\t\t\t\t$extension->postProcess();\n\t\t\t}\n\t\t}", "public function reorderChildren()\n {\n $sql = \"select ID_PAGE from \" . $this->mode . \"PAGE where PAG_IDPERE=\" . $this->getID() . \" order by PAG_POIDS\";\n $stmt = $this->dbh->prepare(\"update \" . $this->mode . \"PAGE set PAG_POIDS=:PAG_POIDS where ID_PAGE=:ID_PAGE\");\n $PAG_POIDS = 1;\n $stmt->bindParam(':PAG_POIDS', $PAG_POIDS, PDO::PARAM_INT);\n foreach ($this->dbh->query($sql)->fetchAll(PDO::FETCH_COLUMN) as $ID_PAGE) {\n $stmt->bindValue(':ID_PAGE', $ID_PAGE, PDO::PARAM_INT);\n $stmt->execute();\n $PAG_POIDS ++;\n }\n }", "function fuzzloc_unload() {\n\n\tunregister_hook('post_local', 'addon/fuzzloc/fuzzloc.php', 'fuzzloc_post_hook');\n\tunregister_hook('feature_settings', 'addon/fuzzloc/fuzzloc.php', 'fuzzloc_settings');\n\tunregister_hook('feature_settings_post', 'addon/fuzzloc/fuzzloc.php', 'fuzzloc_settings_post');\n\n\n\tlogger(\"removed fuzzloc\");\n}", "public function prune()\n {\n if (!$this->isEmpty()) {\n $this->root->prune();\n $this->root = null;\n }\n }", "function __destruct()\n\t\t{\n\t\t\tparent::__destruct();\n\t\t}", "protected function ReRenderSubForms()\n {\n if (!$this->m_SubForms)\n return;\n\n $this->m_ActiveRecord = $this->GetActiveRecord();\n\n global $g_BizSystem;\n $mode = $this->GetDisplayMode()->GetMode();\n foreach($this->m_SubForms as $subForm) {\n $formObj = $g_BizSystem->GetObjectFactory()->GetObject($subForm);\n $formObj->SetPostActionOff();\n if ($mode == MODE_N) { // parent form on new mode\n $formObj->SetPrtCommitPending(true);\n }\n else {\n $formObj->SetPrtCommitPending(false);\n $dataObj = $this->GetDataObj()->GetRefObject($formObj->m_DataObjName);\n if ($dataObj)\n $formObj->SetDataObj($dataObj);\n }\n // force the active row on the first row\n $formObj->SetActiveRecordId(null);\n $formObj->ReRender();\n }\n return;\n }", "protected function _cleanContexts(){\n\n //remove no more present contexts\n foreach( $this->_destroyContext as $_context ){\n\n self::_TimeStampMsg( \"(parent \" . self::$tHandlerPID . \") : need to delete a context\" );\n $this->_killPids( $_context );\n\n }\n $this->_destroyContext = array();\n\n }", "public function afterLoad(){\n $this->getType()->afterLoadProcess($this);\n return parent::afterLoad();\n }", "public function __destruct() {\n unset($this->_pidManager);\n unset($this->_pidFile);\n unset($this->_ipc);\n unset($this->_tasks);\n }", "protected function _afterLoadCollection()\n {\n $this->getCollection()->walk('afterLoad');\n parent::_afterLoadCollection();\n }", "public function garbage_collect();", "public function __destruct()\n {\n unset($this->stepCount);\n parent::__destruct();\n }", "function remove_from_parent()\n {\n foreach ($this->plugins as $name => $obj) {\n $this->updateServicesVars($name);\n if ($this->plugins[$name]->initially_was_account) {\n if (isset($this->plugins[$name]->krb_host_key) && $this->plugins[$name]->krb_host_key instanceof krbHostKeys) {\n $this->plugins[$name]->krb_host_key->remove_from_parent_by_prefix($this->plugins[$name]->krb_service_prefix);\n }\n $this->plugins[$name]->remove_from_parent();\n }\n }\n }" ]
[ "0.5949833", "0.58542114", "0.5674282", "0.56486", "0.552239", "0.546008", "0.54356617", "0.54264224", "0.53199714", "0.5303473", "0.52730656", "0.5243749", "0.5230473", "0.52192104", "0.52123576", "0.5171038", "0.5169273", "0.51460487", "0.51393014", "0.5067857", "0.5052398", "0.50511", "0.50477123", "0.5038516", "0.50221455", "0.499146", "0.49895826", "0.49860993", "0.49858415", "0.49588174", "0.49509096", "0.49502727", "0.49427155", "0.4929295", "0.49195242", "0.49119362", "0.49097848", "0.48926643", "0.48919427", "0.48670244", "0.48589036", "0.48556954", "0.48530036", "0.48484936", "0.48482046", "0.48436663", "0.48329127", "0.48244864", "0.48211098", "0.48203436", "0.4819995", "0.48128513", "0.47980237", "0.47883007", "0.47821337", "0.4781582", "0.47811863", "0.477931", "0.47773385", "0.47772694", "0.47613502", "0.47611699", "0.47611699", "0.47611699", "0.47611699", "0.4761121", "0.47582385", "0.47546047", "0.4751588", "0.47471356", "0.47447214", "0.47424722", "0.47411615", "0.47373933", "0.4732547", "0.47323564", "0.4732216", "0.47305006", "0.47198135", "0.47181353", "0.47181353", "0.47122836", "0.47097683", "0.470963", "0.47023124", "0.4702098", "0.4699733", "0.46995965", "0.4696773", "0.46953785", "0.46951428", "0.4678965", "0.4666029", "0.46642077", "0.46637943", "0.46620208", "0.46618494", "0.46561235", "0.4644193", "0.46409336" ]
0.797926
0
Method Processes events management of control and all of it's children.
function manageEventsRecursive($Event) { if ($Event) { if (!is_array($Event)) $Event=array($Event); foreach ($Event as $key => $eventName) { $methodName="On".$eventName; if (method_exists($this,$methodName)) { $this->$methodName(); //return true; } if ($this->HasControls()) { $keys = array_keys($this->Controls); $count= count($this->Controls); for ($i = 0; $i < $count; $i++) { @$control = &$this->Controls[$keys[$i]]; if ($control->manageEventsRecursive($eventName)) return true; } } return false; } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function controls()\n {\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "public function attachEvents();", "public function attachEvents();", "public function handles_events()\n\t{\n\t\treturn false;\n\t}", "abstract function HookEvents();", "public function setEventHandlers()\n {\n Event::on(Menu::className(), ActiveRecord::EVENT_AFTER_DELETE, function ($event) {\n \n // Delete the children\n if (!$event->sender->deleteChildren())\n throw new \\yii\\base\\Exception(Yii::t('app', 'There was an error while deleting this item'));\n });\n \n // Set eventhandlers for the 'MenuItem' model\n Event::on(MenuItem::className(), ActiveRecord::EVENT_AFTER_DELETE, function ($event) {\n \n // Delete the children\n if (!$event->sender->deleteChildren())\n throw new \\yii\\base\\Exception(Yii::t('app', 'There was an error while deleting this item'));\n }); \n }", "public static function events();", "protected function setEvents()\n {\n foreach ($this->preloadList as $preload) {\n include_once XOOPS_ROOT_PATH . '/modules/' . $preload['module'] . '/preloads/' . $preload['file']. '.php';\n $class_name = ucfirst($preload['module'])\n . ($preload['file'] == 'preload' ? '' : ucfirst($preload['file']) )\n . 'Preload';\n if (!class_exists($class_name)) {\n continue;\n }\n $class_methods = get_class_methods($class_name);\n foreach ($class_methods as $method) {\n if (strpos($method, 'event') === 0) {\n $event_name = strtolower(str_replace('event', '', $method));\n $event= array($class_name, $method);\n $this->eventListeners[$event_name][] = $event;\n }\n }\n }\n }", "public static function __events () {\n \n }", "function CreateChildControls() {\n }", "protected function _handle_forms()\n\t{\n\t\tif (!strlen($this->_form_posted)) return;\n\t\t$method = 'on_'.$this->_form_posted.'_submit';\n\n\t\tif (method_exists($this, $method))\n\t\t{\n\t\t\tcall_user_func(array($this, $method), $this->_form_action);\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ($this->controls as $k=>$v)\n\t\t{\n\t\t\t$ctl = $this->controls[$k];\n\n\t\t\tif (method_exists($ctl, $method))\n\t\t\t{\n\t\t\t\t$ctl->page = $this;\n\t\t\t\tcall_user_func(array($ctl, $method), $this->_form_action);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\tif (DEBUG) dwrite(\"Method '$method' not defined\");\n\t}", "function controls()\n\t{\n\t}", "function InitChildControls() {\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore \n\n\t\t$this->register_general_content_controls();\n\n\t\t$this->register_count_content_controls();\n\n\t\t$this->register_helpful_information();\n\t}", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "public function getAllControls();", "public function getControls()\n\t{\n\t\t$this->ensureChildControls();\n\t\treturn $this->_container->getControls();\n\t}", "public function commitEvents();", "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "protected function handle($e) {\n if(empty($this->listeners)) {\n return;\n }\n \n foreach($this->listeners as $name => $l) {\n foreach($l as $listener) {\n $this->process($name,$listener,$e);\n }\n }\n }", "public function processEventQueue()\n {\n if (!$this->googleClient)\n {\n try \n {\n $this->googleClient = $this->createGoogleConnection(); \n } \n catch (\\Exception $e) \n {\n $this->syncProblemNotification($e->getMessage());\n die($e->getMessage());\n }\n \n }\n\n $db = \\JFactory::getDbo();\n\n $query = $db->getQuery(true);\n $query->select('*')->from('#__pbbooking_sync')->where('status is null')->order('id ASC');\n $events = $db->setQuery($query)->loadObjectList();\n\n foreach ($events as $event)\n {\n $success = false;\n switch ($event->action)\n {\n case 'create':\n $success = $this->sendEvent($event);\n break;\n case 'delete':\n $success = $this->deleteEvent($event);\n break;\n }\n\n //update the error flag so that it can be reported on in the admin console.\n $event->status = ($success) ? 'success' : 'error';\n if ($success)\n echo '<br/>Event '.$event->action.' success';\n else\n echo '<br/>Event '.$event->action.' failed';\n \n $db->updateObject('#__pbbooking_sync',$event,'id');\n }\n }", "public function customHandle()\n {\n\n $this->makeFolders();\n\n $this->scaffoldEventFiles();\n $this->scaffoldListenerFiles();\n\n }", "public function process()\n\t{\n\t\tPhpfox::isUser(true);\n\t\tPhpfox::getUserParam('event.can_create_event', true);\n\t\t\n\t\t$bIsEdit = false;\n\t\t$bIsSetup = ($this->request()->get('req4') == 'setup' ? true : false);\n\t\t$sAction = $this->request()->get('req3');\n\t\t$aCallback = false;\t\t\n\t\t$sModule = $this->request()->get('module', false);\n\t\t$iItem = $this->request()->getInt('item', false);\n\t\t\n\t\tif ($iEditId = $this->request()->get('id'))\n\t\t{\n\t\t\tif (($aEvent = Phpfox::getService('event')->getForEdit($iEditId)))\n\t\t\t{\n\t\t\t\t$bIsEdit = true;\n\t\t\t\t$this->setParam('aEvent', $aEvent);\n\t\t\t\t$this->setParam(array(\n\t\t\t\t\t\t'country_child_value' => $aEvent['country_iso'],\n\t\t\t\t\t\t'country_child_id' => $aEvent['country_child_id']\n\t\t\t\t\t)\n\t\t\t\t);\t\t\t\t\n\t\t\t\t$this->template()->setHeader(array(\n\t\t\t\t\t\t\t'<script type=\"text/javascript\">$Behavior.eventEditCategory = function(){ var aCategories = explode(\\',\\', \\'' . $aEvent['categories'] . '\\'); for (i in aCategories) { $(\\'#js_mp_holder_\\' + aCategories[i]).show(); $(\\'#js_mp_category_item_\\' + aCategories[i]).attr(\\'selected\\', true); } }</script>'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t\t->assign(array(\n\t\t\t\t\t\t'aForms' => $aEvent,\n\t\t\t\t\t\t'aEvent' => $aEvent\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\tif ($aEvent['module_id'] != 'event')\n\t\t\t\t{\n\t\t\t\t\t$sModule = $aEvent['module_id'];\n\t\t\t\t\t$iItem = $aEvent['item_id'];\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\t\t\n\t\t\n\t\tif ($sModule && $iItem && Phpfox::hasCallback($sModule, 'viewEvent'))\n\t\t{\n\t\t\t$aCallback = Phpfox::callback($sModule . '.viewEvent', $iItem);\t\t\n\t\t\t$this->template()->setBreadcrumb($aCallback['breadcrumb_title'], $aCallback['breadcrumb_home']);\n\t\t\t$this->template()->setBreadcrumb($aCallback['title'], $aCallback['url_home']);\t\t\n\t\t\tif ($sModule == 'pages' && !Phpfox::getService('pages')->hasPerm($iItem, 'event.share_events'))\n\t\t\t{\n\t\t\t\treturn Phpfox_Error::display(Phpfox::getPhrase('event.unable_to_view_this_item_due_to_privacy_settings'));\n\t\t\t}\t\t\t\t\n\t\t}\t\t\n\t\t\n\t\t$aValidation = array(\n\t\t\t'title' => Phpfox::getPhrase('event.provide_a_name_for_this_event'),\n\t\t\t// 'country_iso' => Phpfox::getPhrase('event.provide_a_country_location_for_this_event'),\t\t\t\n\t\t\t'location' => Phpfox::getPhrase('event.provide_a_location_for_this_event')\n\t\t);\n\t\t\n\t\t$oValidator = Phpfox::getLib('validator')->set(array(\n\t\t\t\t'sFormName' => 'js_event_form',\n\t\t\t\t'aParams' => $aValidation\n\t\t\t)\n\t\t);\t\t\n\t\t\n\t\tif ($aVals = $this->request()->get('val'))\n\t\t{\n\t\t\tif ($oValidator->isValid($aVals))\n\t\t\t{\t\t\t\t\n\t\t\t\tif ($bIsEdit)\n\t\t\t\t{\n\t\t\t\t\tif (Phpfox::getService('event.process')->update($aEvent['event_id'], $aVals, $aEvent))\n\t\t\t\t\t{\n\t\t\t\t\t\tswitch ($sAction)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcase 'customize':\n\t\t\t\t\t\t\t\t$this->url()->send('event.add.invite.setup', array('id' => $aEvent['event_id']), Phpfox::getPhrase('event.successfully_added_a_photo_to_your_event'));\t\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tcase 'invite':\n\t\t\t\t\t\t\t\t$this->url()->permalink('event', $aEvent['event_id'], $aEvent['title'], true, Phpfox::getPhrase('event.successfully_invited_guests_to_this_event'));\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\t$this->url()->send('event.add', array('id' => $aEvent['event_id']), Phpfox::getPhrase('event.event_successfully_updated'));\t\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$aVals['event_id'] = $aEvent['event_id'];\n\t\t\t\t\t\t$this->template()->assign(array('aForms' => $aVals, 'aEvent' => $aVals));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tif (($iFlood = Phpfox::getUserParam('event.flood_control_events')) !== 0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$aFlood = array(\n\t\t\t\t\t\t\t'action' => 'last_post', // The SPAM action\n\t\t\t\t\t\t\t'params' => array(\n\t\t\t\t\t\t\t\t'field' => 'time_stamp', // The time stamp field\n\t\t\t\t\t\t\t\t'table' => Phpfox::getT('event'), // Database table we plan to check\n\t\t\t\t\t\t\t\t'condition' => 'user_id = ' . Phpfox::getUserId(), // Database WHERE query\n\t\t\t\t\t\t\t\t'time_stamp' => $iFlood * 60 // Seconds);\t\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t);\n\t\t\t\t\t\t\t \t\t\t\n\t\t\t\t\t\t// actually check if flooding\n\t\t\t\t\t\tif (Phpfox::getLib('spam')->check($aFlood))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tPhpfox_Error::set(Phpfox::getPhrase('event.you_are_creating_an_event_a_little_too_soon') . ' ' . Phpfox::getLib('spam')->getWaitTime());\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\tif (Phpfox_Error::isPassed())\n\t\t\t\t\t{\t\n\t\t\t\t\t\tif ($iId = Phpfox::getService('event.process')->add($aVals, ($aCallback !== false ? $sModule : 'event'), ($aCallback !== false ? $iItem : 0)))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$aEvent = Phpfox::getService('event')->getForEdit($iId);\n\t\t\t\t\t\t\t$this->url()->permalink('event', $aEvent['event_id'], $aEvent['title'], true, Phpfox::getPhrase('event.event_successfully_added'));\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t$sStep = (isset($aVals['step']) ? $aVals['step'] : '');\n\t\t\t$sAction = (isset($aVals['action']) ? $aVals['action'] : '');\t\n\t\t\t$this->template()->assign('aForms', $aVals);\t\t\n\t\t}\t\t\n\t\t\n\t\tif ($bIsEdit)\n\t\t{\n\t\t\t$aMenus = array(\n\t\t\t\t'detail' => Phpfox::getPhrase('event.event_details'),\n\t\t\t\t'customize' => Phpfox::getPhrase('event.photo'),\n\t\t\t\t'invite' => Phpfox::getPhrase('event.invite_guests')\n\t\t\t);\n\t\t\t// Dont show the photo upload for iOS\n\t\t\tif ($this->request()->isIOS())\n\t\t\t{\n\t\t\t\tunset($aMenus['customize']);\n\t\t\t}\n\t\t\tif (!$bIsSetup)\n\t\t\t{\n\t\t\t\t$aMenus['manage'] = Phpfox::getPhrase('event.manage_guest_list');\n\t\t\t\t$aMenus['email'] = Phpfox::getPhrase('event.mass_email');\n\t\t\t}\n\t\t\t\n\t\t\t$this->template()->buildPageMenu('js_event_block', \n\t\t\t\t$aMenus,\n\t\t\t\tarray(\n\t\t\t\t\t'link' => $this->url()->permalink('event', $aEvent['event_id'], $aEvent['title']),\n\t\t\t\t\t'phrase' => Phpfox::getPhrase('event.view_this_event')\n\t\t\t\t)\t\t\t\t\n\t\t\t);\t\t\n\t\t}\n\t\t\n\t\t$this->template()->setTitle(($bIsEdit ? Phpfox::getPhrase('event.managing_event') . ': ' . $aEvent['title'] : Phpfox::getPhrase('event.create_an_event')))\n\t\t\t->setFullSite()\t\t\t\n\t\t\t->setBreadcrumb(Phpfox::getPhrase('event.events'), ($aCallback === false ? $this->url()->makeUrl('event') : $this->url()->makeUrl($aCallback['url_home_pages'])))\n\t\t\t->setBreadcrumb(($bIsEdit ? Phpfox::getPhrase('event.managing_event') . ': ' . $aEvent['title'] : Phpfox::getPhrase('event.create_new_event')), ($bIsEdit ? $this->url()->makeUrl('event.add', array('id' => $aEvent['event_id'])) : $this->url()->makeUrl('event.add')), true)\n\t\t\t->setEditor()\n\t\t\t->setPhrase(array(\n\t\t\t\t\t'core.select_a_file_to_upload'\n\t\t\t\t)\n\t\t\t)\t\t\t\t\n\t\t\t->setHeader('cache', array(\t\n\t\t\t\t\t'add.js' => 'module_event',\n\t\t\t\t\t'pager.css' => 'style_css',\n\t\t\t\t\t'progress.js' => 'static_script',\t\t\t\t\t\n\t\t\t\t\t'country.js' => 'module_core'\t\t\t\t\t\n\t\t\t\t)\n\t\t\t)\t\t\t\n\t\t\t->setHeader(array(\n\t\t\t\t\t'<script type=\"text/javascript\">$Behavior.eventProgressBarSettings = function(){ if ($Core.exists(\\'#js_event_block_customize_holder\\')) { oProgressBar = {holder: \\'#js_event_block_customize_holder\\', progress_id: \\'#js_progress_bar\\', uploader: \\'#js_progress_uploader\\', add_more: false, max_upload: 1, total: 1, frame_id: \\'js_upload_frame\\', file_id: \\'image\\'}; $Core.progressBarInit(); } }</script>'\n\t\t\t\t)\n\t\t\t)\n\t\t\t->assign(array(\n\t\t\t\t\t'sCreateJs' => $oValidator->createJS(),\n\t\t\t\t\t'sGetJsForm' => $oValidator->getJsForm(false),\n\t\t\t\t\t'bIsEdit' => $bIsEdit,\n\t\t\t\t\t'bIsSetup' => $bIsSetup,\n\t\t\t\t\t'sCategories' => Phpfox::getService('event.category')->get(),\n\t\t\t\t\t'sModule' => ($aCallback !== false ? $sModule : ''),\n\t\t\t\t\t'iItem' => ($aCallback !== false ? $iItem : ''),\n\t\t\t\t\t'aCallback' => $aCallback,\n\t\t\t\t\t'iMaxFileSize' => (Phpfox::getUserParam('event.max_upload_size_event') === 0 ? null : Phpfox::getLib('phpfox.file')->filesize((Phpfox::getUserParam('event.max_upload_size_event') / 1024) * 1048576)),\n\t\t\t\t\t'bCanSendEmails' => ($bIsEdit ? Phpfox::getService('event')->canSendEmails($aEvent['event_id']) : false),\n\t\t\t\t\t'iCanSendEmailsTime' => ($bIsEdit ? Phpfox::getService('event')->getTimeLeft($aEvent['event_id']) : false),\n\t\t\t\t\t'sJsEventAddCommand' => (isset($aEvent['event_id']) ? \"if (confirm('\" . Phpfox::getPhrase('event.are_you_sure', array('phpfox_squote' => true)) . \"')) { $('#js_submit_upload_image').show(); $('#js_event_upload_image').show(); $('#js_event_current_image').remove(); $.ajaxCall('event.deleteImage', 'id={$aEvent['event_id']}'); } return false;\" : ''),\n\t\t\t\t\t'sTimeSeparator' => Phpfox::getPhrase('event.time_separator')\n\t\t\t\t)\n\t\t\t);\t\t\n\t}", "public static function getSubscribedEvents()\n {\n return array(\n 'beforeScenario' => array('prepareDrupal', 10),\n 'beforeOutline' => array('prepareDrupal', 10),\n 'afterScenario' => array('teardownDrupal', -10),\n 'afterOutline' => array('teardownDrupal', -10)\n );\n }", "protected function commit()\n {\n $commit = function(Control $ctrl) use(&$commit)\n {\n $this->vs[$ctrl->attr('id')] = $ctrl->getVS();\n $this->controls[$ctrl->attr('id')] = $ctrl;\n if ($ctrl instanceof Panel)\n {\n foreach ($ctrl as $uniqueID => $child)\n {\n $commit($child);\n }\n }\n };\n foreach ($this->controls as $ctrl) $commit($ctrl);\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Number' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Counter Title\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Title' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Box', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_background',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background-Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#f7f7f7',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'background: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Border\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_border',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#eee',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'border: 8px solid {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Number Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h3' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_number_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h3',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h6' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h6',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }", "public function releaseEvents();", "public function releaseEvents();", "public function getControls();", "public function prepare_controls()\n {\n }", "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "static function getSubscribedEvents()\n {\n return array(\n FormEvents::PRE_SET_DATA => 'preSetData',\n );\n }", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "public static function getSubscribedEvents()\n\t{\n\t\treturn [\n\t\t\tFormEvents::PRE_SET_DATA => 'preSetData',\n\t\t];\n\t}", "protected function _handleEvent(Tinebase_Event_Abstract $_eventObject)\n {\n switch (get_class($_eventObject)) {\n case 'Admin_Event_DeleteGroup':\n foreach ($_eventObject->groupIds as $groupId) {\n if (Core::isLogLevel(LogLevel::DEBUG)) Core::getLogger()->debug(__METHOD__ . '::' . __LINE__\n . ' Removing role memberships of group ' .$groupId );\n \n $roleIds = Tinebase_Acl_Roles::getInstance()->getRoleMemberships($groupId, Tinebase_Acl_Rights::ACCOUNT_TYPE_GROUP);\n foreach ($roleIds as $roleId) {\n Tinebase_Acl_Roles::getInstance()->removeRoleMember($roleId, array(\n 'id' => $groupId,\n 'type' => Tinebase_Acl_Rights::ACCOUNT_TYPE_GROUP,\n ));\n }\n }\n break;\n }\n }", "protected function _processEvent(Mage_Index_Model_Event $event)\n {\n $this->callEventHandler($event);\n }", "protected function _processEvent(Mage_Index_Model_Event $event)\n {\n $this->callEventHandler($event);\n }", "public function processAction()\n {\n $env = $this->getEnvironment();\n $this->setProcessTitle('IcingaDB Event Stream: ' . $env->get('name'));\n $handler = new IcingaEventHandler($env);\n $handler->processEvents();\n }", "protected function _register_controls() {\n\n\t\t\t\t$this->start_controls_section(\n\t\t\t\t\t'section_sc_booked',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'ThemeREX Booked Calendar', 'trx_addons' ),\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'style',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Layout', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => [\n\t\t\t\t\t\t\t\t\t'calendar' => esc_html__('Calendar', 'trx_addons'),\n\t\t\t\t\t\t\t\t\t'list' => esc_html__('List', 'trx_addons')\n\t\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t'default' => 'calendar'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'calendar',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Calendar', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Select calendar -', 'trx_addons')), trx_addons_get_list_terms(false, 'booked_custom_calendars')),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'month',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Month', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current month -', 'trx_addons')), trx_addons_get_list_months()),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'year',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Year', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current year -', 'trx_addons')), trx_addons_get_list_range(date('Y'), date('Y')+25)),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\t$this->end_controls_section();\n\t\t\t}", "protected function _register_controls() {\n\t\t$this->query_controls();\n\t\t$this->layout_controls();\n\n $this->start_controls_section(\n 'eael_section_post_block_style',\n [\n 'label' => __( 'Post Block Style', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\n $this->add_control(\n\t\t\t'eael_post_block_bg_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post Background Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\n $this->add_control(\n\t\t\t'eael_thumbnail_overlay_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Thumbnail Overlay Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => 'rgba(0,0,0, .5)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-overlay, {{WRAPPER}} .eael-post-block.post-block-style-overlay .eael-entry-wrapper' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_spacing',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Spacing Between Items', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', '%', 'em' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_border',\n\t\t\t\t'label' => esc_html__( 'Border', 'essential-addons-elementor' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border Radius', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'border-radius: {{TOP}}px {{RIGHT}}px {{BOTTOM}}px {{LEFT}}px;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n $this->start_controls_section(\n 'eael_section_typography',\n [\n 'label' => __( 'Color & Typography', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_title_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#303133',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title, {{WRAPPER}} .eael-entry-title a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_hover_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Hover Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#23527c',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title:hover, {{WRAPPER}} .eael-entry-title a:hover' => 'color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_title_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title' => 'text-align: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_title_typography',\n\t\t\t\t'label' => __( 'Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-title',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_excerpt_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_excerpt_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_excerpt_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_excerpt_typography',\n\t\t\t\t'label' => __( 'Excerpt Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-grid-post-excerpt p',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_meta_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_meta_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta, .eael-entry-meta a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_footer',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'flex-start' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'flex-end' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'stretch' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-footer' => 'justify-content: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-footer',\n ]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_header',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-header',\n ]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_meta_typography',\n\t\t\t\t'label' => __( 'Meta Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-meta > div, {{WRAPPER}} .eael-entry-meta > span',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Load More Button Style Controls!\n\t\t */\n\t\t$this->load_more_button_style();\n\n\t}", "private function composeControlPanel()\n {\n $this->composeControlPanelSideMenu();\n $this->composeControlPanelImagesBrowser();\n }", "public function events()\n\t{\n\t\t// -------------------------------------\n\t\t// Set dynamic=\"off\", lest Weblog get uppity and try\n\t\t// to think that it's in charge here.\n\t\t// -------------------------------------\n\n\t\t//default off.\n\t\tif ( $this->check_yes( ee()->TMPL->fetch_param('dynamic') ) )\n\t\t{\n\t\t\tee()->TMPL->tagparams['dynamic'] \t='yes';\n\t\t}\n\t\telse\n\t\t{\n\t\t\tee()->TMPL->tagparams['dynamic'] \t= 'no';\n\t\t}\n\n\t\t// -------------------------------------\n\t\t//\tcategory url titles?\n\t\t// -------------------------------------\n\n\t\tif (isset(ee()->TMPL->tagparams['category']))\n\t\t{\n\t\t\t$this->convert_category_titles();\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\tdetect special cases\n\t\t//--------------------------------------------\n\n\t\tif ( ! $this->parent_method)\n\t\t{\n\t\t\t$this->parent_method = __FUNCTION__;\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// Load 'em up\n\t\t// -------------------------------------\n\n\t\t$this->load_calendar_datetime();\n\t\t$this->load_calendar_parameters();\n\n\t\t// -------------------------------------\n\t\t// Prep the parameters\n\t\t// -------------------------------------\n\n\t\t$params = array(\n\t\t\tarray(\t'name' => 'category',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'site_id',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer',\n\t\t\t\t\t'min_value' => 1,\n\t\t\t\t\t'multi' => TRUE,\n\t\t\t\t\t'default' => $this->data->get_site_id()\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'calendar_id',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'calendar_name',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'event_id',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'event_name',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'status',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'multi' => TRUE,\n\t\t\t\t\t'default' => 'open'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'date_range_start',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'date'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'date_range_end',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'date'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'show_days',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'show_weeks',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'show_months',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'show_years',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'time_range_start',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'time',\n\t\t\t\t\t'default' => '0000'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'time_range_end',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'time',\n\t\t\t\t\t'default' => '2400'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'prior_occurrences_limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'prior_exceptions_limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'upcoming_occurrences_limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'upcoming_exceptions_limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'event_limit',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'event_offset',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'integer',\n\t\t\t\t\t'default' => 0\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'orderby',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'default' => 'event_start_date'\n\t\t\t\t\t),\n\t\t\tarray(\t'name' => 'sort',\n\t\t\t\t\t'required' => FALSE,\n\t\t\t\t\t'type' => 'string',\n\t\t\t\t\t'default' => 'ASC'\n\t\t\t\t\t)\n\t\t\t);\n\n\t\t//ee()->TMPL->log_item('Calendar: Processing parameters');\n\n\t\t$this->add_parameters($params);\n\n\t\t// -------------------------------------\n\t\t// Do some voodoo on P\n\t\t// -------------------------------------\n\n\t\t$this->process_events_params();\n\n\t\t// -------------------------------------\n\t\t// For the purposes of this method, if an event_id or event_name\n\t\t// has been specified, we want to ignore date range parameters.\n\t\t// -------------------------------------\n\t\t/*\n\t\tif ($this->P->value('event_id') !== FALSE OR $this->P->value('event_name') !== FALSE)\n\t\t{\n\t\t\t$this->P->set('date_range_start', FALSE);\n\t\t\t$this->P->set('date_range_end', FALSE);\n\t\t}\n\t\t*/\n\n\t\t// -------------------------------------\n\t\t// Let's go fetch some events\n\t\t// -------------------------------------\n\n\t\t//ee()->TMPL->log_item('Calendar: Fetching events');\n\n\t\t$ids = $this->data->fetch_event_ids($this->P);\n\n\t\t/*$category = FALSE;\n\n\t\tif (FALSE AND isset(ee()->TMPL) AND\n\t\t\t is_object(ee()->TMPL) AND\n\t\t\t ee()->TMPL->fetch_param('category') !== FALSE AND\n\t\t\t ee()->TMPL->fetch_param('category') != ''\n\t\t)\n\t\t{\n\t\t\t$category = ee()->TMPL->fetch_param('category');\n\n\t\t\tunset(ee()->TMPL->tagparams['category']);\n\t\t}\n\n\t\t$ids = $this->data->fetch_event_ids($this->P, $category);*/\n\n\t\t// -------------------------------------\n\t\t// No events?\n\t\t// -------------------------------------\n\n\t\tif (empty($ids))\n\t\t{\n\t\t\t//ee()->TMPL->log_item('Calendar: No events, bailing');\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// We also need the \"parent\" entry id, if it hasn't been provided\n\t\t// -------------------------------------\n\n\t\tforeach ($ids as $k => $v)\n\t\t{\n\t\t\tif (! isset($ids[$v]))\n\t\t\t{\n\t\t\t\t$ids[$v] = $v;\n\t\t\t}\n\t\t}\n\n\t\t// -------------------------------------------\n\t\t// 'calendar_events_event_ids' hook.\n\t\t// - Do something with the event IDs\n\n\t\tif (ee()->extensions->active_hook('calendar_events_event_ids') === TRUE)\n\t\t{\n\t\t\t$ids = ee()->extensions->call('calendar_events_event_ids', $ids);\n\t\t\tif (ee()->extensions->end_script === TRUE) return;\n\t\t}\n\t\t//\n\t\t// -------------------------------------------\n\n\n\t\t//--------------------------------------------\n\t\t//\tremove pagination before we start\n\t\t//--------------------------------------------\n\n\t\t//has tags?\n\t\tif (preg_match(\n\t\t\t\t\"/\" . LD . \"calendar_paginate\" . RD . \"(.+?)\" .\n\t\t\t\t\t LD . preg_quote(T_SLASH, '/') . \"calendar_paginate\" . RD . \"/s\",\n\t\t\t\tee()->TMPL->tagdata\t,\n\t\t\t\t$match\n\t\t\t))\n\t\t{\n\t\t\t$this->paginate_tagpair_data\t= $match[0];\n\t\t\tee()->TMPL->tagdata\t\t\t\t= str_replace( $match[0], '', ee()->TMPL->tagdata );\n\t\t}\n\t\t//prefix comes first\n\t\telse if (preg_match(\n\t\t\t\t\"/\" . LD . \"paginate\" . RD . \"(.+?)\" . LD . preg_quote(T_SLASH, '/') . \"paginate\" . RD . \"/s\",\n\t\t\t\tee()->TMPL->tagdata\t,\n\t\t\t\t$match\n\t\t\t))\n\t\t{\n\t\t\t$this->paginate_tagpair_data\t= $match[0];\n\t\t\tee()->TMPL->tagdata\t\t\t\t= str_replace( $match[0], '', ee()->TMPL->tagdata );\n\t\t}\n\n\n\t\t// -------------------------------------\n\t\t// Prepare tagdata for Calendar-specific variable pairs, which\n\t\t// we will process later.\n\t\t// -------------------------------------\n\n\t\tee()->TMPL->var_single['entry_id'] = 'entry_id';\n\n\t\t$var_pairs = array(\n\t\t\t'occurrences',\n\t\t\t'exceptions',\n\t\t\t'rules'\n\t\t);\n\n\t\tforeach (ee()->TMPL->var_pair as $name => $params)\n\t\t{\n\t\t\tif (in_array($name, $var_pairs))\n\t\t\t{\n\t\t\t\tee()->TMPL->tagdata = str_replace(\n\t\t\t\t\tLD.$name.RD,\n\t\t\t\t\tLD.$name.' id=\"'.LD.'entry_id'.RD.'\"'.RD,\n\t\t\t\t\tee()->TMPL->tagdata\n\t\t\t\t);\n\n\t\t\t\tee()->TMPL->var_pair[$name]['id'] = '';\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tforeach ($var_pairs as $pair)\n\t\t\t{\n\t\t\t\tif (strpos($name.' ', $pair) !== 0)\n\t\t\t\t{\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t$new_name = $name.' id=\"\"';\n\n\t\t\t\tee()->TMPL->tagdata = str_replace(\n\t\t\t\t\tLD.$name.RD,\n\t\t\t\t\tLD.$name.' id=\"'.LD.'entry_id'.RD.'\"'.RD,\n\t\t\t\t\tee()->TMPL->tagdata\n\t\t\t\t);\n\n\t\t\t\tee()->TMPL->var_pair[] \t\t\t\t\t= ee()->TMPL->var_pair[$name];\n\t\t\t\tee()->TMPL->var_pair[$new_name]['id'] \t= '';\n\t\t\t\t// Leave the old name behind so we can pick it up later and use it\n\t\t\t\tee()->TMPL->var_pair[$pair] \t\t\t= $name;\n\n\t\t\t\tunset(ee()->TMPL->var_pair[$name]);\n\t\t\t}\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// Prepare tagdata for Calendar-specific date variables, which\n\t\t// we will process later.\n\t\t// -------------------------------------\n\n\t\t$var_dates = array(\n\t\t\t'event_start_date'\t=> FALSE,\n\t\t\t'event_start_time'\t=> FALSE,\n\t\t\t'event_end_date'\t=> FALSE,\n\t\t\t'event_end_time'\t=> FALSE,\n\t\t\t'event_first_date'\t=> FALSE,\n\t\t\t'event_last_date'\t=> FALSE,\n\t\t);\n\n\t\tforeach (ee()->TMPL->var_single as $k => $v)\n\t\t{\n\t\t\tif (($pos = strpos($k, ' format')) !== FALSE)\n\t\t\t{\n\t\t\t\t$name = substr($k, 0, $pos);\n\n\t\t\t\tif (array_key_exists($name, $var_dates))\n\t\t\t\t{\n\t\t\t\t\t// -------------------------------------\n\t\t\t\t\t//\thash fix for EE 2.8.2\n\t\t\t\t\t// -------------------------------------\n\t\t\t\t\t//\tDue to the new conditionals parser\n\t\t\t\t\t//\teverything is just whack, so we have\n\t\t\t\t\t//\tto hash and replace formats because\n\t\t\t\t\t//\tEE is just barfing on it now :/.\n\t\t\t\t\t// -------------------------------------\n\n\t\t\t\t\t//EE 2.9+ converting quotes and escaping on its conditional\n\t\t\t\t\t//tokenizer so we now have to match escaped quotes\n\t\t\t\t\t//This should be backward compatible.\n\t\t\t\t\tpreg_match(\"/format=(\\\\\\'|\\'|\\\\\\\"|\\\"])(.*)?\\\\1/i\", $k, $matches);\n\n\t\t\t\t\tif ( ! empty($matches))\n\t\t\t\t\t{\n\t\t\t\t\t\t$old_k = $k;\n\t\t\t\t\t\t$k = str_replace($matches[0], md5($matches[0]), $k);\n\t\t\t\t\t\tee()->TMPL->tagdata = str_replace($old_k, $k, ee()->TMPL->tagdata);\n\n\t\t\t\t\t\t//EE 2.9's new conditional parser also screws with how\n\t\t\t\t\t\t//template variables were pulling out the formats for\n\t\t\t\t\t\t//us due to the quote conversion and escaping\n\t\t\t\t\t\t//so we are fixing it here with this since we are\n\t\t\t\t\t\t//capturing it ourselves and converting to hashes\n\t\t\t\t\t\t//anyway.\n\t\t\t\t\t\tif ($v == false)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$v = $matches[2];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t$var_dates[$name][$k] = $v;\n\t\t\t\t\tee()->TMPL->var_single[$k] = $k;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//\t----------------------------------------\n\t\t//\tInvoke Channel class\n\t\t//\t----------------------------------------\n\n\t\tif ( ! class_exists('Channel') )\n\t\t{\n\t\t\trequire PATH_MOD.'/channel/mod.channel.php';\n\t\t}\n\n\t\t$channel = new Channel;\n\n\n\t\t//need to remove limit here so huge amounts of events work\n\t\t$channel->limit = 1000000;\n\n\t\t// --------------------------------------------\n\t\t// Invoke Pagination for EE 2.4 and Above\n\t\t// --------------------------------------------\n\n\t\t$channel = $this->add_pag_to_channel($channel);\n\n\t\t// -------------------------------------\n\t\t// Prepare parameters\n\t\t// -------------------------------------\n\n\t\tee()->TMPL->tagparams['entry_id'] \t\t\t= implode('|', array_keys($ids));\n\n\t\t//if we have event names, lets set them for the URL title\n\t\tif ( ! in_array(ee()->TMPL->fetch_param('event_name'), array(FALSE, ''), TRUE))\n\t\t{\n\t\t\tee()->TMPL->tagparams['url_title'] = ee()->TMPL->fetch_param('event_name');\n\t\t}\n\n\t\tee()->TMPL->tagparams[$this->sc->channel] \t= CALENDAR_EVENTS_CHANNEL_NAME;\n\n\t\t// -------------------------------------\n\t\t// Pre-process related data\n\t\t// -------------------------------------\n\n\t\tif (version_compare($this->ee_version, '2.6.0', '<'))\n\t\t{\n\t\t\tee()->TMPL->tagdata = ee()->TMPL->assign_relationship_data(\n\t\t\t\tee()->TMPL->tagdata\n\t\t\t);\n\t\t}\n\n\t\tee()->TMPL->var_single \t\t= array_merge( ee()->TMPL->var_single, ee()->TMPL->related_markers );\n\n\t\t// -------------------------------------\n\t\t// Execute needed methods\n\t\t// -------------------------------------\n\n\t\t$channel->fetch_custom_channel_fields();\n\n\t\t$channel->fetch_custom_member_fields();\n\n\t\t// --------------------------------------------\n\t\t// Pagination Tags Parsed Out\n\t\t// --------------------------------------------\n\n\t\t$channel = $this->fetch_pagination_data($channel);\n\n\t\t// -------------------------------------\n\t\t// Querification\n\t\t// -------------------------------------\n\n\t\t$channel->build_sql_query();\n\n\t\tif ($channel->sql == '')\n\t\t{\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\t$channel->query = ee()->db->query($channel->sql);\n\n\t\tif ($channel->query->num_rows() == 0)\n\t\t{\n//ee()->TMPL->log_item('Calendar: Channel module says no results, bailing');\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\t$channel->query->result\t= $channel->query->result_array();\n\n\t\t// -------------------------------------------\n\t\t// 'calendar_events_channel_query' hook.\n\t\t// - Do something with the channel query\n\n\t\tif (ee()->extensions->active_hook('calendar_events_channel_query') === TRUE)\n\t\t{\n\t\t\t$channel->query = ee()->extensions->call('calendar_events_channel_query', $channel->query, $ids);\n\t\t\tif (ee()->extensions->end_script === TRUE) return;\n\t\t}\n\t\t//\n\t\t// -------------------------------------------\n\n\t\t// -------------------------------------\n\t\t// Trim IDs and build events\n\t\t// -------------------------------------\n\n\t\t$new_ids = array();\n\n\t\tforeach ($channel->query->result as $k => $row)\n\t\t{\n\t\t\t$new_ids[$row['entry_id']] = $ids[$row['entry_id']];\n\t\t}\n\n\t\t$event_data = $this->data->fetch_all_event_data($new_ids);\n\n\t\t// -------------------------------------\n\t\t// Turn these IDs into events\n\t\t// -------------------------------------\n\n\t\t$events = array();\n\n\t\t//ee()->TMPL->log_item('Calendar: Fetching Calendar_event class');\n\n\t\tif ( ! class_exists('Calendar_event'))\n\t\t{\n\t\t\trequire_once CALENDAR_PATH.'calendar.event.php';\n\t\t}\n\n\t\t$calendars = array();\n\n\t\t//ee()->TMPL->log_item('Calendar: Creating events');\n\n\t\tforeach ($event_data as $k => $edata)\n\t\t{\n\t\t\t$start_ymd\t= ($this->P->value('date_range_start') !== FALSE) ?\n\t\t\t\t\t\t\t$this->P->value('date_range_start', 'ymd') : '';\n\t\t\t$end_ymd\t= ($this->P->value('date_range_end') !== FALSE) ?\n\t\t\t\t\t\t\t$this->P->value('date_range_end', 'ymd') :\n\t\t\t\t\t\t\t$this->P->value('date_range_start', 'ymd');\n\n\t\t\t$temp\t\t= new Calendar_event($edata, $start_ymd, $end_ymd);\n\n\t\t\tif (! empty($temp->dates))\n\t\t\t{\n\t\t\t\t$temp->prepare_for_output();\n\n\t\t\t\t// -------------------------------------\n\t\t\t\t// Eliminate times we don't care about\n\t\t\t\t// -------------------------------------\n\n\t\t\t\tif ($this->P->value('date_range_start', 'ymd') != '')\n\t\t\t\t{\n\t\t\t\t\tforeach ($temp->dates as $ymd => $times)\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach ($times as $range => $data)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif ($data['end_date']['ymd'].$data['end_date']['time'] <\n\t\t\t\t\t\t\t\t$this->P->value('date_range_start', 'ymd') .\n\t\t\t\t\t\t\t\t$this->P->value('date_range_start', 'time'))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tunset($temp->dates[$ymd][$range]);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\telseif ($data['date']['ymd'].$data['date']['time'] >\n\t\t\t\t\t\t\t\t\t$this->P->value('date_range_end', 'ymd') .\n\t\t\t\t\t\t\t\t\t$this->P->value('date_range_end', 'time'))\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tunset($temp->dates[$ymd][$range]);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (empty($temp->dates[$ymd]))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tunset($temp->dates[$ymd]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t// -------------------------------------\n\t\t\t\t// Recheck to ensure our dates array isn't empty now\n\t\t\t\t// -------------------------------------\n\n\t\t\t\tif ( ! empty($temp->dates))\n\t\t\t\t{\n\t\t\t\t\t$events[$edata['entry_id']] = $temp;\n\t\t\t\t\t$calendars[$events[$edata['entry_id']]->default_data['calendar_id']] = array();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// No point in stressing ourselves out if $calendars is empty\n\t\t// -------------------------------------\n\n\t\tif (empty($calendars))\n\t\t{\n\t\t\t//ee()->TMPL->log_item('Calendar: No calendars, bailing');\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// Fetch information about the calendars\n\t\t// -------------------------------------\n\n\t\t$calendars = $this->data->fetch_calendar_data_by_id(array_keys($calendars));\n\n\t\t// -------------------------------------\n\t\t// Prep variable aliases\n\t\t// -------------------------------------\n\n\t\t$variables = array(\n\t\t\t'title'\t\t\t=> 'event_title',\n\t\t\t'url_title'\t\t=> 'event_url_title',\n\t\t\t'entry_id'\t\t=> 'event_id',\n\t\t\t'author_id'\t\t=> 'event_author_id',\n\t\t\t'author'\t\t=> 'event_author',\n\t\t\t'status'\t\t=> 'event_status'\n\t\t);\n\n\t\t//custom variables with the letters 'url' are borked in\n\t\t//EE 2.6. Bug reported, but this should fix.\n\t\t//https://support.ellislab.com/bugs/detail/19337\n\t\tif (version_compare($this->ee_version, '2.6.0', '>='))\n\t\t{\n\t\t\t$variables['url_title'] = 'event_borked_title';\n\n\t\t\tee()->TMPL->var_single['event_borked_title'] = 'event_borked_title';\n\n\t\t\tunset(ee()->TMPL->var_single['event_url_title']);\n\n\t\t\tee()->TMPL->tagdata = str_replace(\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_url_title' . RD,\n\t\t\t\t\t'\"event_url_title\"',\n\t\t\t\t\t\"'event_url_title'\"\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_borked_title' . RD,\n\t\t\t\t\t'\"event_borked_title\"',\n\t\t\t\t\t\"'event_borked_title'\"\n\n\t\t\t\t),\n\t\t\t\tee()->TMPL->tagdata\n\t\t\t);\n\n\t\t\tee()->TMPL->var_single['event_calendar_borked_title'] = 'event_calendar_borked_title';\n\n\t\t\tunset(ee()->TMPL->var_single['event_calendar_url_title']);\n\n\t\t\tee()->TMPL->tagdata = str_replace(\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_calendar_url_title' . RD,\n\t\t\t\t\t'\"event_calendar_url_title\"',\n\t\t\t\t\t\"'event_calendar_url_title'\"\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_calendar_borked_title' . RD,\n\t\t\t\t\t'\"event_calendar_borked_title\"',\n\t\t\t\t\t\"'event_calendar_borked_title'\"\n\n\t\t\t\t),\n\t\t\t\tee()->TMPL->tagdata\n\t\t\t);\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// Prepare to reorder based on Calendar parameters\n\t\t// -------------------------------------\n\n\t\t$calendar_orderby_params = array(\n\t\t\t'event_title',\n\t\t\t'event_start_date',\n\t\t\t'event_start_hour',\n\t\t\t'event_start_time',\n\t\t\t'occurrence_start_date'\n\t\t);\n\n\t\t$orders \t\t\t\t= explode('|', $this->P->value('orderby'));\n\t\t$sorts \t\t\t\t\t= explode('|', $this->P->value('sort'));\n\t\t$calendar_orders \t\t= array();\n\t\t$calendar_order_data \t= array();\n\n\t\tforeach ($orders as $k => $order)\n\t\t{\n\t\t\tif (in_array($order, $calendar_orderby_params))\n\t\t\t{\n\t\t\t\t$sort = (isset($sorts[$k])) ? $sorts[$k] : 'desc';\n\t\t\t\t$calendar_orders[$order] = $sort;\n\t\t\t\t$calendar_order_data[$order] = array();\n\t\t\t}\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\tremove non-existant entry ids first\n\t\t//--------------------------------------------\n\n\t\tforeach ($channel->query->result as $k => $row)\n\t\t{\n\t\t\tif ( ! isset($events[$row['entry_id']]))\n\t\t\t{\n\t\t\t\tunset($channel->query->result[$k]);\n\t\t\t}\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\tcalculate offset and event timeframe\n\t\t//\ttotal before we parse tags\n\t\t//--------------------------------------------\n\n\t\t$offset = ($this->P->value('event_offset') > 0) ? $this->P->value('event_offset') : 0;\n\n\t\t$this->event_timeframe_total = count($channel->query->result) - $offset;\n\n\t\t// -------------------------------------\n\t\t// Add variables to the query result\n\t\t// -------------------------------------\n\n\t\t//ee()->TMPL->log_item('Calendar: Adding variables to channel query result');\n\n\t\tforeach ($channel->query->result as $k => $row)\n\t\t{\n\n\t\t\t$channel->query->result[$k]['author'] = ($row['screen_name'] != '') ?\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$row['screen_name'] :\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t$row['username'];\n\n\t\t\t$channel->query->result[$k]['event_timeframe_total'] = $this->event_timeframe_total;\n\n\t\t\t$entry_id = $row['entry_id'];\n\n\t\t\t// -------------------------------------\n\t\t\t// Alias\n\t\t\t// -------------------------------------\n\n\t\t\tforeach ($variables as $old => $new)\n\t\t\t{\n\t\t\t\t$channel->query->result[$k][$new] = $channel->query->result[$k][$old];\n\t\t\t}\n\n\t\t\t// -------------------------------------\n\t\t\t// Event variables\n\t\t\t// -------------------------------------\n\n\t\t\tforeach ($events[$entry_id]->default_data as $key => $val)\n\t\t\t{\n\t\t\t\tif (! is_array($val))\n\t\t\t\t{\n\t\t\t\t\tif ($val === 'y' OR $val === 'n')\n\t\t\t\t\t{\n\t\t\t\t\t\t$channel->query->result[$k]['event_'.$key] = ($val == 'y') ? TRUE : FALSE;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$channel->query->result[$k]['event_'.$key] = $val;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tforeach ($val as $vkey => $vval)\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($vval === 'y' OR $vval === 'n')\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$channel->query->result[$k][\n\t\t\t\t\t\t\t\t'event_'.$key.'_'.$vkey\n\t\t\t\t\t\t\t] = ($vval == 'y') ? TRUE : FALSE;\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$channel->query->result[$k]['event_'.$key.'_'.$vkey] = $vval;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// -------------------------------------\n\t\t\t// Prepare to orderby event_start_date\n\t\t\t// -------------------------------------\n\n\t\t\tif (isset($calendar_orders['event_start_date']))\n\t\t\t{\n\t\t\t\t$calendar_order_data['event_start_date'][$k] =\n\t\t\t\t\t$events[$entry_id]->default_data['start_date'] .\n\t\t\t\t\t$events[$entry_id]->default_data['start_time'];\n\t\t\t}\n\n\t\t\t// -------------------------------------\n\t\t\t// Prepare to orderby occurrence_start_date\n\t\t\t// -------------------------------------\n\n\t\t\tif (isset($calendar_orders['occurrence_start_date']))\n\t\t\t{\n\t\t\t\t$date = reset(reset($events[$entry_id]->dates));\n\t\t\t\t$time = (isset($date['start_time'])) ? $date['start_time'] : $date['date']['time'];\n\t\t\t\t$date = $date['date']['ymd'];\n\t\t\t\t$calendar_order_data['occurrence_start_date'][$k] = $date.$time;\n\t\t\t}\n\n\t\t\t//--------------------------------------------\n\t\t\t//\tsort by occurrence start time\n\t\t\t//--------------------------------------------\n\n\t\t\tif (isset($calendar_orders['event_start_time']))\n\t\t\t{\n\t\t\t\tif ($events[$entry_id]->default_data['start_time'] == 0)\n\t\t\t\t{\n\t\t\t\t\t$calendar_order_data['event_start_time'][$k] = '0000';\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$calendar_order_data['event_start_time'][$k] = $events[$entry_id]->default_data['start_time'];\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//--------------------------------------------\n\t\t\t//\tsort by occurrence start hour\n\t\t\t//--------------------------------------------\n\n\t\t\tif (isset($calendar_orders['event_start_hour']))\n\t\t\t{\n\t\t\t\tif ($events[$entry_id]->default_data['start_time'] == 0)\n\t\t\t\t{\n\t\t\t\t\t$calendar_order_data['event_start_hour'][$k] = '00';\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$calendar_order_data['event_start_hour'][$k] \t= substr($events[$entry_id]->default_data['start_time'], 0, 2);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//--------------------------------------------\n\t\t\t//\tsort by event title\n\t\t\t//--------------------------------------------\n\n\t\t\tif (isset($calendar_orders['event_title']))\n\t\t\t{\n\t\t\t\t$calendar_order_data['event_title'][$k] = $channel->query->result[$k]['title'];\n\t\t\t}\n\n\t\t\t// -------------------------------------\n\t\t\t// Occurrence variables\n\t\t\t// -------------------------------------\n\n\t\t\t$channel->query->result[$k]['event_occurrence_total'] \t= count($events[$entry_id]->occurrences);\n\t\t\t$channel->query->result[$k]['event_has_occurrences'] \t= (\n\t\t\t\t$channel->query->result[$k]['event_occurrence_total'] > 0\n\t\t\t) ? TRUE : FALSE;\n\n\t\t\t// -------------------------------------\n\t\t\t// Exception variables\n\t\t\t// -------------------------------------\n\n\t\t\t$channel->query->result[$k]['event_exception_total'] \t= count($events[$entry_id]->exceptions);\n\t\t\t$channel->query->result[$k]['event_has_exceptions'] \t= (\n\t\t\t\t$channel->query->result[$k]['event_exception_total'] > 0\n\t\t\t) ? TRUE : FALSE;\n\n\t\t\t// -------------------------------------\n\t\t\t// Rule variables\n\t\t\t// -------------------------------------\n\n\t\t\t$channel->query->result[$k]['event_rule_total'] \t\t= count($events[$entry_id]->rules);\n\t\t\t$channel->query->result[$k]['event_has_rules'] \t\t\t= (\n\t\t\t\t$channel->query->result[$k]['event_rule_total'] > 0\n\t\t\t) ? TRUE : FALSE;\n\n\t\t\t//-------------------------------------\n\t\t\t// Does the event end?\n\t\t\t// we have to check all rules to make sure\n\t\t\t// in case this is a complex rule\n\t\t\t//-------------------------------------\n\n\t\t\t$never_ending = $channel->query->result[$k]['event_never_ends'] = FALSE;\n\n\t\t\tif ($channel->query->result[$k]['event_recurs'] == 'y')\n\t\t\t{\n\t\t\t\tforeach ($events[$entry_id]->rules as $event_rule)\n\t\t\t\t{\n\t\t\t\t\tif ($event_rule['rule_type'] == '+' AND\n\t\t\t\t\t\t($event_rule['repeat_years'] != 0 OR\n\t\t\t\t\t\t $event_rule['repeat_months'] != 0 OR\n\t\t\t\t\t\t $event_rule['repeat_days'] != 0 OR\n\t\t\t\t\t\t $event_rule['repeat_weeks'] != 0) AND\n\t\t\t\t\t\t$event_rule['last_date'] == 0 \tAND\n\t\t\t\t\t\t$event_rule['stop_after'] == 0\n\t\t\t\t\t )\n\t\t\t\t\t{\n\t\t\t\t\t\t$never_ending = $channel->query->result[$k]['event_never_ends'] = TRUE;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t/*$never_ending = $channel->query->result[$k]['event_never_ends'] = (\n\t\t\t\t$channel->query->result[$k]['event_last_date'] == 0 AND\n\t\t\t\t$channel->query->result[$k]['event_recurs'] == 'y'\n\t\t\t);*/\n\n\t\t\t// -------------------------------------\n\t\t\t// Calendar variables\n\t\t\t// -------------------------------------\n\n\t\t\tif (isset($calendars[$events[$entry_id]->default_data['calendar_id']]))\n\t\t\t{\n\t\t\t\tforeach ($calendars[$events[$entry_id]->default_data['calendar_id']] as $key => $val)\n\t\t\t\t{\n\t\t\t\t\tif (substr($key, 0, 9) != 'calendar_')\n\t\t\t\t\t{\n\t\t\t\t\t\t$key = 'calendar_'.$key;\n\t\t\t\t\t}\n\n\t\t\t\t\t//add in calendar data\n\t\t\t\t\t$channel->query->result[$k][$key] = $val;\n\n\t\t\t\t\tif ($key == 'calendar_url_title' AND\n\t\t\t\t\t\tversion_compare($this->ee_version, '2.6.0', '>='))\n\t\t\t\t\t{\n\t\t\t\t\t\t$channel->query->result[$k]['event_calendar_borked_title'] = $val;\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t//really?\n\t\t\t\t\t\t$channel->query->result[$k]['event_'.$key] = $val;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// -------------------------------------\n\t\t\t// Date variables\n\t\t\t// -------------------------------------\n\n\t\t\tforeach ($var_dates as $name => $vals)\n\t\t\t{\n\t\t\t\t$which = '';\n\n\t\t\t\tif ($vals === FALSE)\n\t\t\t\t{\n\t\t\t\t\t$vals = array();\n\t\t\t\t}\n\n\t\t\t\tif ($name == 'event_last_date')\n\t\t\t\t{\n\t\t\t\t\tif ( ! empty($vals))\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->CDT->change_ymd($channel->query->result[$k]['event_last_date']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telseif ($name == 'event_first_date')\n\t\t\t\t{\n\t\t\t\t\t$channel->query->result[$k]['event_first_date']\t= $channel->query->result[$k]['event_start_ymd'];\n\n\t\t\t\t\tif ( ! empty($vals))\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->CDT->change_ymd($channel->query->result[$k]['event_first_date']);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$which\t= ($name == 'event_first_date' OR strpos($name, '_start_') !== FALSE) ? 'start' : 'end';\n\t\t\t\t$year\t= $events[$entry_id]->default_data[$which.'_year'];\n\t\t\t\t$month\t= $events[$entry_id]->default_data[$which.'_month'];\n\t\t\t\t$day\t= $events[$entry_id]->default_data[$which.'_day'];\n\n\t\t\t\t$time \t= $events[$entry_id]->default_data[$which.'_time'];\n\n\t\t\t\tif ($time == 0)\n\t\t\t\t{\n\t\t\t\t\tif ($which == 'start')\n\t\t\t\t\t{\n\t\t\t\t\t\t$hour \t= '00';\n\t\t\t\t\t\t$minute = '00';\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$hour\t= '23';\n\t\t\t\t\t\t$minute = '59';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$minute = substr($time, -2, 2);\n\t\t\t\t\t$hour \t= substr($time, 0, strlen($time) - 2);\n\t\t\t\t}\n\n\t\t\t\t//year month and day are a tad fubar when\n\t\t\t\t//we are looking at a repeat occurence with an enddate\n\t\t\t\t//because the end time is indeed correct, but end date\n\t\t\t\t//is expected to be the end of all of the occurrences\n\t\t\t\t//however, if this is never ending, thats different\n\n\t\t\t\t$end_time_dta \t= $this->CDT->datetime_array();\n\n\t\t\t\tif ( ! $never_ending AND\n\t\t\t\t\t $name = \"event_last_date\")\n\t\t\t\t{\n\t\t\t\t\t$real_end_date = ($channel->query->result[$k]['event_last_date'] != 0) ?\n\t\t\t\t\t\t\t\t\t\t$channel->query->result[$k]['event_last_date'] :\n\t\t\t\t\t\t\t\t\t\t$events[$entry_id]->default_data['end_date']['ymd'];\n\n\n\t\t\t\t\t$end_time_year \t= substr($real_end_date, 0, 4);\n\t\t\t\t\t$end_time_month = substr($real_end_date, 4, 2);\n\t\t\t\t\t$end_time_day \t= substr($real_end_date, 6, 2);\n\n\t\t\t\t\t$this->CDT->change_datetime(\n\t\t\t\t\t\t$end_time_year,\n\t\t\t\t\t\t$end_time_month,\n\t\t\t\t\t\t$end_time_day,\n\t\t\t\t\t\t$hour,\n\t\t\t\t\t\t$minute\n\t\t\t\t\t);\n\n\t\t\t\t\t$end_time_dta \t= $this->CDT->datetime_array();\n\t\t\t\t}\n\n\t\t\t\t$this->CDT->change_datetime($year, $month, $day, $hour, $minute);\n\n\t\t\t\tforeach ($vals as $key => $format)\n\t\t\t\t{\n\t\t\t\t\t//special treatment on end dates of occurrences if its not infinite\n\t\t\t\t\tif ( ! $never_ending AND stristr($key, 'event_last_date'))\n\t\t\t\t\t{\n\t\t\t\t\t\t$channel->query->result[$k][$key] = $this->cdt_format_date_string(\n\t\t\t\t\t\t\t$end_time_dta,\n\t\t\t\t\t\t\t$format,\n\t\t\t\t\t\t\t'%'\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t\t//else, parse as normal\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$channel->query->result[$k][$key] = $this->cdt_format_date_string(\n\t\t\t\t\t\t\t$this->CDT->datetime_array(),\n\t\t\t\t\t\t\t$format,\n\t\t\t\t\t\t\t'%'\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\n\t\t\t\t/*\n\t\t\t\t$this->CDT->change_datetime($year, $month, $day, $hour, $minute);\n\n\t\t\t\tforeach ($vals as $key => $format)\n\t\t\t\t{\n\n\t\t\t\t\t$channel->query->result[$k][$key] = $this->cdt_format_date_string(\n\t\t\t\t\t\t$this->CDT->datetime_array(),\n\t\t\t\t\t\t$format,\n\t\t\t\t\t\t'%'\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\t*/\n\n\t\t\t\t// -------------------------------------\n\t\t\t\t// Shorthand date/time variables\n\t\t\t\t// -------------------------------------\n\n\t\t\t\tif ($which)\n\t\t\t\t{\n\t\t\t\t\t$channel->query->result[$k]['event_'.$which.'_hour']\t= $this->cdt_format_date_string($this->CDT->datetime_array(), 'H');\n\t\t\t\t\t$channel->query->result[$k]['event_'.$which.'_minute']\t= $this->cdt_format_date_string($this->CDT->datetime_array(), 'i');\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// The foreach may have emptied the query results\n\t\t// -------------------------------------\n\n\t\tif (empty($channel->query->result))\n\t\t{\n//ee()->TMPL->log_item('Calendar: Weblog query is empty, bailing');\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\tunset($CDT);\n\n\t\t// -------------------------------------\n\t\t// Reorder based on Calendar parameters\n\t\t// -------------------------------------\n\n\t\tif ( ! empty($calendar_order_data))\n\t\t{\n\t\t\tee()->TMPL->log_item('Calendar: Reordering');\n\n\t\t\t$args \t= array();\n\t\t\t$temps \t= array();\n\n\t\t\tforeach ($calendar_orders as $k => $v)\n\t\t\t{\n\t\t\t\t//add order array\n\t\t\t\t$args[] =& $calendar_order_data[$k];\n\n\t\t\t\t//constant for order type\n\n\t\t\t\t//contants cannot be passed by ref because its not a variable\n\t\t\t\t$temps[$k] = constant('SORT_'.strtoupper($v));\n\n\t\t\t\t$args[] =& $temps[$k];\n\t\t\t}\n\n\t\t\t//this will order the result\n\t\t\t$args[] =& $channel->query->result;\n\n\t\t\tcall_user_func_array('array_multisort', $args);\n\n\t\t\t//cleanup\n\t\t\tunset($args);\n\t\t\tunset($temps);\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\tpagination for the events tag\n\t\t//--------------------------------------------\n\t\t//\tany tags using this might have different needs\n\t\t//\tso we only want to paginate for original events\n\t\t//\ttag usage\n\t\t//--------------------------------------------\n\n\t\t$this->paginate = FALSE;\n\n\t\t//$this->event_timeframe_total = count($channel->query->result);\n\n\t\tif ($this->parent_method === 'events' AND\n\t\t\t$this->P->value('event_limit') > 0 AND\n\t\t\t$this->event_timeframe_total > $this->P->value('event_limit'))\n\t\t{\n\t\t\t//get pagination info\n\t\t\t$pagination_data = $this->universal_pagination(array(\n\t\t\t\t'total_results'\t\t\t=> $this->event_timeframe_total,\n\t\t\t\t//had to remove this jazz before so it didn't get iterated over\n\t\t\t\t'tagdata'\t\t\t\t=> ee()->TMPL->tagdata . $this->paginate_tagpair_data,\n\t\t\t\t'limit'\t\t\t\t\t=> $this->P->value('event_limit'),\n\t\t\t\t'uri_string'\t\t\t=> ee()->uri->uri_string,\n\t\t\t\t'paginate_prefix'\t\t=> 'calendar_'\n\t\t\t));\n\n\t\t\t// -------------------------------------------\n\t\t\t// 'calendar_events_create_pagination' hook.\n\t\t\t// - Let devs maniuplate the pagination display\n\n\t\t\tif (ee()->extensions->active_hook('calendar_events_create_pagination') === TRUE)\n\t\t\t{\n\t\t\t\t$pagination_data = ee()->extensions->call(\n\t\t\t\t\t'calendar_events_create_pagination',\n\t\t\t\t\t$this,\n\t\t\t\t\t$pagination_data\n\t\t\t\t);\n\t\t\t}\n\t\t\t//\n\t\t\t// -------------------------------------------\n\n\t\t\t//if we paginated, sort the data\n\t\t\tif ($pagination_data['paginate'] === TRUE)\n\t\t\t{\n\t\t\t\t$this->paginate\t\t\t= $pagination_data['paginate'];\n\t\t\t\t$this->page_next\t\t= $pagination_data['page_next'];\n\t\t\t\t$this->page_previous\t= $pagination_data['page_previous'];\n\t\t\t\t$this->p_page\t\t\t= $pagination_data['pagination_page'];\n\t\t\t\t$this->current_page \t= $pagination_data['current_page'];\n\t\t\t\t$this->pager \t\t\t= $pagination_data['pagination_links'];\n\t\t\t\t$this->basepath\t\t\t= $pagination_data['base_url'];\n\t\t\t\t$this->total_pages\t\t= $pagination_data['total_pages'];\n\t\t\t\t$this->paginate_data\t= $pagination_data['paginate_tagpair_data'];\n\t\t\t\t$this->page_count\t\t= $pagination_data['page_count'];\n\t\t\t\t//ee()->TMPL->tagdata\t\t= $pagination_data['tagdata'];\n\t\t\t}\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\tevent limiter\n\t\t//--------------------------------------------\n\n\t\t$page \t= (($this->current_page -1) * $this->P->value('event_limit'));\n\n\t\tif ($page > 0)\n\t\t{\n\t\t\t$offset += $page;\n\t\t}\n\n\n\t\t// -------------------------------------\n\t\t// Apply event_limit=\"\" parameter\n\t\t// -------------------------------------\n\n\t\tif ($this->P->value('event_limit'))\n\t\t{\n\t\t\t$channel->query->result\t= array_slice(\n\t\t\t\t$channel->query->result,\n\t\t\t\t$offset,\n\t\t\t\t$this->P->value('event_limit')\n\t\t\t);\n\t\t}\n\t\telse if ($offset > 0)\n\t\t{\n\t\t\t$channel->query->result\t= array_slice(\n\t\t\t\t$channel->query->result,\n\t\t\t\t$offset\n\t\t\t);\n\t\t}\n\n\t\t//--------------------------------------------\n\t\t//\toffset too much? buh bye\n\t\t//--------------------------------------------\n\n\t\tif (empty($channel->query->result))\n\t\t{\n\t\t\treturn $this->no_results();\n\t\t}\n\n\t\t//\t----------------------------------------\n\t\t//\tRedeclare\n\t\t//\t----------------------------------------\n\t\t// \tWe will reassign the $channel->query->result with our\n\t\t// \treordered array of values.\n\t\t//\t----------------------------------------\n\n\t\t$channel->query->result_array = $channel->query->result;\n\n\t\t// --------------------------------------------\n\t\t// Typography\n\t\t// --------------------------------------------\n\n\t\tee()->load->library('typography');\n\t\tee()->typography->initialize();\n\t\tee()->typography->convert_curly = FALSE;\n\n\t\t$channel->fetch_categories();\n\n\t\t// -------------------------------------\n\t\t// Parse\n\t\t// -------------------------------------\n\n\t\t$occurrence_hash = '9b8b2cde1a14e29a8791ceccdaab6cf9d92b37a4';\n\n\t\t//we have to prevent occurrenct count from being borked\n\t\tee()->TMPL->tagdata = str_replace('occurrence_count', $occurrence_hash, ee()->TMPL->tagdata);\n\n\t\t//ee()->TMPL->log_item('Calendar: Parsing, via channel module');\n\n\t\t$channel->parse_channel_entries();\n\n\t\t$channel->return_data = str_replace($occurrence_hash, 'occurrence_count', $channel->return_data);\n\n\t\t// -------------------------------------\n\t\t// Parse Calendar variable pairs\n\t\t// -------------------------------------\n\n\t\t//ee()->TMPL->log_item('Calendar: Parsing variable pairs');\n\n\t\tforeach ($var_pairs as $var)\n\t\t{\n\t\t\tif (isset(ee()->TMPL->var_pair[$var]))\n\t\t\t{\n\t\t\t\t// -------------------------------------\n\t\t\t\t// Iterate through the events\n\t\t\t\t// -------------------------------------\n\n\t\t\t\tforeach ($events as $k => $data)\n\t\t\t\t{\n\t\t\t\t\t// -------------------------------------\n\t\t\t\t\t// Does this event have this var pair?\n\t\t\t\t\t// -------------------------------------\n\n\t\t\t\t\tif (strpos($channel->return_data, LD.$var.' ') !== FALSE)\n\t\t\t\t\t{\n\t\t\t\t\t\t$var_tag = (! is_array(ee()->TMPL->var_pair[$var])) ? ee()->TMPL->var_pair[$var] : $var;\n\n\t\t\t\t\t\tif (preg_match_all(\"/\".LD.$var_tag.' id=\"'.$k.'\"'.RD.'(.*?)'.LD.preg_quote(T_SLASH, '/').$var.RD.'/s', $channel->return_data, $matches))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// -------------------------------------\n\t\t\t\t\t\t\t// Iterate through the variables associated with this pair\n\t\t\t\t\t\t\t// -------------------------------------\n\n\t\t\t\t\t\t\tforeach ($matches[1] as $key => $match)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t$method = \"prep_{$var}_output\";\n\t\t\t\t\t\t\t\t$match = $this->$method($match, $data, FALSE);\n\t\t\t\t\t\t\t\t$channel->return_data = str_replace($matches[0][$key], $match, $channel->return_data);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\n\t\t// -------------------------------------\n\t\t// Paginate\n\t\t// -------------------------------------\n\n\t\t//$channel->add_pagination_data();\n\n\t\t// -------------------------------------\n\t\t// Related entries\n\t\t// -------------------------------------\n\n\t\t//ee()->TMPL->log_item('Calendar: Parsing related entries, via channel module');\n\n\t\tif (version_compare($this->ee_version, '2.6.0', '<'))\n\t\t{\n\t\t\tif (count(ee()->TMPL->related_data) > 0 AND\n\t\t\t\tcount($channel->related_entries) > 0)\n\t\t\t{\n\t\t\t\t$channel->parse_related_entries();\n\t\t\t}\n\n\t\t\tif (count(ee()->TMPL->reverse_related_data) > 0 AND\n\t\t\t\tcount($channel->reverse_related_entries) > 0)\n\t\t\t{\n\t\t\t\t$channel->parse_reverse_related_entries();\n\t\t\t}\n\t\t}\n\n\t\t// -------------------------------------\n\t\t// Send 'em home\n\t\t// -------------------------------------\n\n\t\t$tagdata = $this->parse_pagination($channel->return_data);\n\n\t\t//ee()->TMPL->log_item('Calendar: Done!');\n\n\t\t// -------------------------------------\n\t\t//\tlets reverse any unparsed items\n\t\t//\tin case someone is actually writing\n\t\t//\tout the phrase 'event_url_title'\n\t\t// -------------------------------------\n\n\t\t//custom variables with the letters 'url' are borked in\n\t\t//EE 2.6. Bug reported, but this should fix.\n\t\t//https://support.ellislab.com/bugs/detail/19337\n\t\tif (version_compare($this->ee_version, '2.6.0', '>='))\n\t\t{\n\t\t\t$tagdata = str_replace(\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_borked_title' . RD,\n\t\t\t\t\t'\"event_borked_title\"',\n\t\t\t\t\t\"'event_borked_title'\"\n\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_url_title' . RD,\n\t\t\t\t\t'\"event_url_title\"',\n\t\t\t\t\t\"'event_url_title'\"\n\t\t\t\t),\n\t\t\t\t$tagdata\n\t\t\t);\n\n\n\t\t\t$tagdata = str_replace(\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_calendar_borked_title' . RD,\n\t\t\t\t\t'\"event_calendar_borked_title\"',\n\t\t\t\t\t\"'event_calendar_borked_title'\"\n\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\tLD . 'event_calendar_url_title' . RD,\n\t\t\t\t\t'\"event_calendar_url_title\"',\n\t\t\t\t\t\"'event_calendar_url_title'\"\n\t\t\t\t),\n\t\t\t\t$tagdata\n\t\t\t);\n\t\t}\n\n\t\treturn $tagdata;\n\t}", "protected function _register_controls()\n {\n\n /**\n * Style tab\n */\n\n $this->start_controls_section(\n 'general',\n [\n 'label' => __('Content', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n\t\t\t'menu_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Style', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'inline',\n\t\t\t\t'options' => [\n\t\t\t\t\t'inline' => __( 'Inline', 'akash-hp' ),\n\t\t\t\t\t'flyout' => __( 'Flyout', 'akash-hp' ),\n\t\t\t\t],\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_label',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Label', 'akash-hp' ),\n 'type' => Controls_Manager::TEXT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_open_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'fa fa-align-justify',\n\t\t\t\t\t'library' => 'solid',\n ],\n \n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_close_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Close Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'far fa-window-close',\n\t\t\t\t\t'library' => 'solid',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'menu_align',\n [\n 'label' => __('Align', 'akash-hp'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'start' => [\n 'title' => __('Left', 'akash-hp'),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __('top', 'akash-hp'),\n 'icon' => 'fa fa-align-center',\n ],\n 'flex-end' => [\n 'title' => __('Right', 'akash-hp'),\n 'icon' => 'fa fa-align-right',\n ],\n ],\n 'default' => 'left',\n\t\t\t\t'toggle' => true,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .akash-main-menu-wrap.navbar' => 'justify-content: {{VALUE}}'\n\t\t\t\t\t] \n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n\t\t\t'header_infos_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Header Info', 'akash-hp' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'show_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'akash-hp' ),\n\t\t\t\t'label_off' => __( 'Hide', 'akash-hp' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'no',\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'info_title', [\n\t\t\t\t'label' => __( 'Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'info Title' , 'akash-hp' ),\n\t\t\t\t'label_block' => true,\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'info_content', [\n\t\t\t\t'label' => __( 'Content', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t'default' => __( 'info Content' , 'akash-hp' ),\n\t\t\t\t'show_label' => false,\n\t\t\t]\n );\n \n $repeater->add_control(\n\t\t\t'info_url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'akash-hp' ),\n\t\t\t\t'show_external' => true,\n\t\t\t]\n );\n \n\t\t$this->add_control(\n\t\t\t'header_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Repeater info', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'info_title' => __( 'Call us:', 'akash-hp' ),\n\t\t\t\t\t\t'info_content' => __( '(234) 567 8901', 'akash-hp' ),\n\t\t\t\t\t],\n\t\t\t\t],\n 'title_field' => '{{{ info_title }}}',\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_menu_style',\n [\n 'label' => __('Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'menu_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'menu_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n \n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n \n $this->add_responsive_control(\n 'item_gap',\n [\n 'label' => __('Menu Gap', 'akash-hp'),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'devices' => ['desktop', 'tablet', 'mobile'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-left: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-right: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_readius',\n [\n 'label' => __('Item Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li:hover>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'dropdown_style',\n [\n 'label' => __('Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'dripdown_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n \n $this->add_control(\n 'dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'ddown_menu_border_color',\n [\n 'label' => __('Menu Border Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_radius',\n [\n 'label' => __('Menu radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_flyout_style',\n [\n 'label' => __('Flyout/Mobile Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_menu_typography',\n 'label' => __('Item Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'flyout_menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n $this->add_responsive_control(\n 'flyout_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_menu_padding',\n [\n 'label' => __('Menu Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n \n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n\n\t\t$this->end_controls_tab();\n\n $this->end_controls_tabs();\n \n $this->end_controls_section();\n\n $this->start_controls_section(\n 'flyout_dropdown_style',\n [\n 'label' => __('Flyout/Mobile Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_dripdown_typography',\n 'label' => __('Dropdown Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n\n $this->start_controls_section(\n 'trigger_style',\n [\n 'label' => __('Trigger Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n $this->start_controls_tabs(\n 'trigger_style_tabs'\n );\n \n $this->start_controls_tab(\n 'trigger_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'trigger_typography',\n 'label' => __('Trigger Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n 'trigger_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'trigger_icon_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'trigger_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_padding',\n [\n 'label' => __('Button Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'trigger_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n\n $this->add_control(\n 'trigger_hover_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_hover_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_hover_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu:hover',\n ]\n );\n\n $this->add_control(\n 'trigger_hover_animation',\n [\n 'label' => __('Hover Animation', 'akash-hp'),\n 'type' => Controls_Manager::HOVER_ANIMATION,\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_hover_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n \n $this->start_controls_section(\n 'infos_style_section',\n [\n 'label' => __('Info Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n ]\n );\n\n $this->start_controls_tabs(\n 'info_style_tabs'\n );\n \n $this->start_controls_tab(\n 'info_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_title_typography',\n 'label' => __('Title Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info span',\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_typography',\n 'label' => __('Info Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info h3 ',\n ]\n );\n\n $this->add_control(\n 'info_title_color',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'info_box_border',\n 'label' => __('Box Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .akash-header-infos',\n ]\n );\n\n $this->add_control(\n\t\t\t'info_title_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Info Title Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .header-info span' => 'margin-bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'ifno_item_padding',\n [\n 'label' => __('Info item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'info_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n $this->add_control(\n 'info_title_color_hover',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color_hover',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n \n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n $this->start_controls_section(\n 'panel_style',\n [\n 'label' => __('Panel Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'panel_label_typography',\n 'label' => __('Label Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler',\n ]\n );\n\n \n $this->add_control(\n 'panel_label_color',\n [\n 'label' => __('Label Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_color',\n [\n 'label' => __('Close Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler i' => 'color: {{VALUE}}',\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'stroke: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_fill_color',\n [\n 'label' => __('Close Trigger Fill Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'fill: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_label_background',\n [\n 'label' => __('Label Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.close-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n \n $this->add_control(\n 'panel_background',\n [\n 'label' => __('Panel Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_cloxe_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Close Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'panel_shadow',\n 'label' => __('Panel Shadow', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-inner',\n ]\n );\n\n $this->add_responsive_control(\n 'close_label_padding',\n [\n 'label' => __('Label Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n \n $this->add_responsive_control(\n 'panel_padding',\n [\n 'label' => __('Panel Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title\n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title \n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_sub_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Sub Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Sub Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#dee3e4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h2' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title h2',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Sub Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Sub Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Sub Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#343a40',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title p' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_sub_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title p',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "private static function event()\n {\n $files = ['Event', 'EventListener'];\n $folder = static::$root.'Event'.'/';\n\n self::call($files, $folder);\n\n $files = ['ManyListenersArgumentsException'];\n $folder = static::$root.'Event/Exceptions'.'/';\n\n self::call($files, $folder);\n }", "protected function manageEvent()\n {\n // Manage the incoming session\n $this->manageSession();\n\n // Get the event data from the incoming request\n $eventData = $this->eventRequest->getEvent();\n\n // Get the entity data from the event\n $entityData = $eventData->get('entity');\n\n if (!is_array($entityData)) $entityData = [];\n\n // Hydrate the event entity\n $this->eventEntity = $this->hydrateEntity($entityData);\n\n // Create the event object\n $this->event = new WebsiteEvent();\n\n // Format the action\n $action = $eventData->get('action');\n $this->setDefaultAction($action);\n\n $this->event->setAction($action);\n $this->event->setEntity($this->eventEntity);\n $this->event->setCreatedAt(time());\n\n if (!is_null($eventData->get('data'))) {\n $this->event->setData($eventData->get('data'));\n }\n\n // Set any related entities to the event\n $relatedEntityData = $eventData->get('relatedEntities');\n if (is_array($relatedEntityData) && !empty($relatedEntityData)) {\n foreach ($relatedEntityData as $relatedEntity) {\n $relEntityObj = $this->hydrateEntity($relatedEntity);\n $this->event->addRelatedEntity($relEntityObj);\n\n }\n }\n // Set the session to the event\n $this->event->setSession($this->session);\n }", "public function traverse(): void\n {\n // Register data hooks on the table\n $this->registerHandlerDefinitions($this->definition->tableName, $this->definition->tca);\n \n // Register data hooks on the types and fields\n $this->traverseTypes();\n $this->traverseFields();\n \n // Allow externals\n $this->eventBus->dispatch(new CustomDataHookTraverserEvent($this->definition, function () {\n $this->registerHandlerDefinitions(...func_get_args());\n }));\n }", "private function manageButtons()\n {\n if (!$this->user->hasPermissionTo(BackpackUser::PERMISSION_EVENTS_CREATE)) {\n $this->crud->denyAccess('create');\n }\n\n if ($this->user->hasPermissionTo(BackpackUser::PERMISSION_EVENTS_ADMIN_VIEW)) {\n $this->crud->allowAccess('show');\n }\n\n if (!$this->user->hasPermissionTo(BackpackUser::PERMISSION_EVENTS_EDIT)) {\n $this->crud->denyAccess('update');\n }\n\n if (!$this->user->hasPermissionTo(BackpackUser::PERMISSION_EVENTS_DELETE)) {\n $this->crud->denyAccess('delete');\n }\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\tarray(\n\t\t\t\t'label' => 'Slider Revolution 6',\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'revslidertitle',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Selected Module:', 'revslider' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'render_type' => 'none',\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'shortcode',\n\t\t\tarray(\n\t\t\t\t//'type' => \\Elementor\\Controls_Manager::HIDDEN,\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label' => __( 'Shortcode', 'revslider' ),\n\t\t\t\t'dynamic' => ['active' => true],\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t// Advanced \t\t\n\t\t$this->add_control(\n\t\t\t'select_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">cached</i> Select Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'edit_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">edit</i> Edit Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.editslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'settings_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">tune</i> Block Settings', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.settingsslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'optimize_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">flash_on</i> Optimize File Sizes', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.optimizeslider',\n\t\t\t)\n\t\t);\n\t\t$this->end_controls_section();\t\n\t}", "public function postEventDel();", "function Doku_Event_Handler() {\n\n // load action plugins\n $plugin = NULL;\n $pluginlist = plugin_list('action');\n\n foreach ($pluginlist as $plugin_name) {\n $plugin =& plugin_load('action',$plugin_name);\n\n if ($plugin !== NULL) $plugin->register($this);\n }\n }", "function dumpChildrenJavascript()\r\n {\r\n //Iterates through components, dumping all javascript\r\n $this->dumpJavascript();\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n if ($v->inheritsFrom('Control'))\r\n {\r\n if ($v->canShow())\r\n {\r\n $v->dumpJavascript();\r\n }\r\n }\r\n else $v->dumpJavascript();\r\n }\r\n }", "protected function postHandle(Event $ev) { return; }", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'electro-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'electro-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'electro-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'electro-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'electro-extensions' ),\n 'return_value' => 'true',\n 'default' => 'false',\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'electro-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'electro-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'electro-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'electro-extensions' ),\n 'random' =>esc_html__( 'Random', 'electro-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'electro-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'electro-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "function ControlOnLoad(){\n if ($this->debug_mode)\n echo $this->ClassName . \"::ControlOnLoad();\" . \"<HR>\";\n parent::ControlOnLoad();\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $this->error = 0;\n $this->library_ID = $this->Request->ToString(\"library\", \"\");\n if (! strlen($this->library_ID)) {\n $this->library_ID = $this->Kernel->Package->Settings->GetItem(\"main\", \"LibraryName\");\n }\n\n //$_library_path = $this->Page->Kernel->Package->Settings->GetItem(\"MAIN\", \"LibrariesRoot\");\n $this->listSettings = Engine::getLibrary($this->Kernel, $this->library_ID, \"ListSettings\");\n $this->listSettings->reParse();\n $this->Package=Engine::GetPackageName();\n $this->item_id = $this->Request->ToString(\"item_id\", \"0\");\n $this->is_context_frame = $this->Request->ToNumber(\"contextframe\", \"0\");\n\n\t\t$this->event = $this->Request->Value(\"event\");\n\t\tif (substr($this->event, 0,4)==\"DoDo\"){\n $this->event=$this->Event=substr($this->event, 2, strlen($this->event)-2);\n $this->Request->SetValue(\"event\", $this->event);\n\t\t}\n\n $this->start = $this->Request->ToNumber($this->library_ID . \"_start\", 0);\n $this->order_by = $this->Request->Value($this->library_ID . \"_order_by\");\n $this->restore = $this->Request->Value(\"restore\");\n\n $this->parent_id = $this->Request->ToNumber($this->library_ID . \"_parent_id\", 0);\n $this->custom_val = $this->Request->Value(\"custom_val\");\n $this->custom_var = $this->Request->Value(\"custom_var\");\n $this->host_library_ID = $this->Request->Value(\"host_library_ID\");\n $this->LibrariesRoot = $this->Kernel->Package->Settings->GetItem(\"main\", \"LibrariesRoot\");\n $this->checkLibraryAccess();\n }", "protected function _register_controls() {\n /*-----------------------------------------------------------------------------------*/\n /* Content TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_section',\n array(\n 'label' => __('APR Heading', 'apr-core' ),\n )\n );\n /* Heading 1*/\n $this->add_control(\n 'title',\n array(\n 'label' => __( 'Title', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' => true\n ),\n 'placeholder' => __( 'Enter your title', 'apr-core' ),\n 'default' => __( 'Enter your title', 'apr-core' ),\n 'label_block' => true,\n )\n );\n $this->add_control(\n 'heading_size',\n array(\n 'label' => __( 'HTML Tag', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => array(\n 'h1' => __( 'H1', 'apr-core' ),\n 'h2' => __( 'H2', 'apr-core' ),\n 'h3' => __( 'H3', 'apr-core' ),\n 'h4' => __( 'H4', 'apr-core' ),\n 'h5' => __( 'H5', 'apr-core' ),\n 'p' => __( 'p', 'apr-core' ),\n ),\n 'default' => 'h3',\n )\n );\n $this->add_control(\n 'link',\n [\n 'label' => __( 'Link', 'elementor' ),\n 'type' => Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => '',\n ],\n 'separator' => 'before',\n ]\n );\n $this->add_responsive_control(\n 'alignment',\n array(\n 'label' => __('Alignment', 'apr-core'),\n 'type' => Controls_Manager::CHOOSE,\n 'default' => 'left',\n 'options' => array(\n 'left' => array(\n 'title' => __( 'Left', 'apr-core' ),\n 'icon' => 'fa fa-align-left',\n ),\n 'center' => array(\n 'title' => __( 'Center', 'apr-core' ),\n 'icon' => 'fa fa-align-center',\n ),\n 'right' => array(\n 'title' => __( 'Right', 'apr-core' ),\n 'icon' => 'fa fa-align-right',\n )\n ),\n )\n );\n $this->add_control(\n 'description',\n array(\n 'label' => __( 'Description', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' \t=> true\n ),\n )\n );\n $this->add_control(\n 'description_position',\n [\n 'label' => __( 'Description Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'bottom',\n 'options' => [\n 'aside' => __( 'Aside', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' ),\n ],\n ]\n );\n $this->add_control(\n 'list_divider',\n [\n 'label' => __( 'Divider', 'apr-core' ),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'no',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'divider_position',\n [\n 'label' => __( 'Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n 'top' => __( 'Top', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' )\n ],\n 'default' => 'bottom',\n 'condition' => [\n 'list_divider' => 'yes',\n ]\n ]\n );\n\n $this->add_control(\n 'divider_color',\n [\n 'label' => __( 'Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'divider_color_hover',\n [\n 'label' => __( 'Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:hover:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_responsive_control(\n 'divider_top',\n [\n 'label' => __( 'Top Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'top: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_left',\n [\n 'label' => __( 'Left Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'left: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_weight',\n [\n 'label' => __( 'Height', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 1,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'height: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_width',\n [\n 'label' => __( 'Width', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'default' => [\n 'size' => 100,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'width: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n \n $this->end_controls_section();\n /*-----------------------------------------------------------------------------------*/\n /* Style TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_style_section',\n array(\n 'label' => __( 'Color', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n $this->add_control(\n 'title_color',\n [\n 'label' => __( 'Title Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title,\n {{WRAPPER}} .heading-modern .heading-title a' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color',\n [\n 'label' \t=> __( 'Description color', 'apr-core' ),\n 'type' \t\t=> Controls_Manager::COLOR,\n 'scheme' \t=> [\n 'type' \t\t=> Scheme_Color::get_type(),\n 'value' \t=> Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n 'desc_style',\n array(\n 'label' => __( 'Typography', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'title_typo',\n 'label' \t=> __( 'Title', 'apr-core' ),\n 'selector' => '{{WRAPPER}} .heading-modern .heading-title',\n ]\n );\n $this->add_responsive_control(\n 'title_width',\n array(\n 'label' => __('Max width Title','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .heading-title' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'desc_typo',\n 'label' \t=> __( 'Description', 'apr-core' ),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' \t=> '{{WRAPPER}} .heading-modern .description',\n ]\n );\n $this->add_responsive_control(\n 'desc_width',\n array(\n 'label' => __('Max width Description','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .description' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_responsive_control(\n 'title_margin',\n array(\n 'label' => __( 'Margin Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n\n $this->add_responsive_control(\n 'title_padding',\n [\n 'label' => __( 'Padding Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_responsive_control(\n 'desc_margin',\n array(\n 'label' => __( 'Margin Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n $this->add_responsive_control(\n 'description_padding',\n [\n 'label' => __( 'Padding Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_control(\n 'title_color_hover',\n [\n 'label' => __( 'Title Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title:hover,\n {{WRAPPER}} .heading-modern .heading-title a:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color_hover',\n [\n 'label' => __( 'Description Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .description:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n }", "public function BuildControls() {\n\n $this->EncType= $this->GetOption('EncType');\n\n // convert array of arrays into array of objects\n foreach($this->Controls as $Name=>&$Control) {\n // skip already builded controls\n if (is_object($Control)) {\n continue;\n }\n // find classname\n if (!isset($Control['Type'])) {\n $Control += array('Type'=>'text', 'Attributes'=>array('UNKNOWNTYPE'=>'YES'));\n }\n if (strpos($Control['Type'], '\\\\') === false) { // short name, ex.: \"select\"\n $Type= ucfirst($Control['Type']);\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\'.$Type.'Control';\n } else { // it is fully qualified class name\n $Class= $Control['Type'];\n }\n if (!class_exists($Class)) {\n $this->Error('Class \"'.$Class.'\" not found.');\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\TextControl'; // fallback to any primitive control\n }\n // copy this array into $Options and append few more items\n // and append common options to allow usage of services\n $Options= $Control + array(\n 'Name'=> $Name,\n 'Form'=> $this,\n 'Book'=> $this->GetOption('Book')\n ) + $this->GetCommonOptions();\n $Control= new $Class($Options);\n // switch to multipart encoding if any control require that\n if ($Control->GetMultipartEncoding()) {\n $this->EncType= 'multipart/form-data';\n }\n }\n $this->Builded= true;\n }", "public function process()\n\t{\n\t\t$this->_init();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->_handle_forms();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->_pre_render();\n\t\tif ($this->_flow != PAGE_FLOW_NORMAL) {$this->process_flow(); return;}\n\n\t\t$this->render();\n\t}", "protected static function boot()\r\n {\r\n parent::boot();\r\n\r\n foreach (static::$handleableEvents as $event) {\r\n static::$event(function($model) use ($event) {\r\n /** @var Model $model */\r\n return $model->handleEvent($event);\r\n });\r\n }\r\n }", "public function getSubscribedEvents();", "function Events()\n\t{\n\t\t/* Calls the WebPage's constructor. This must be done to\n\t\t ensure that WebPage is properly instantiated. The \n\t\t parameter specifies a string to be displayed in the\n\t\t browser's title bar. */\n\t\tparent::WebPage('Demonstrating basic Events');\n\t\t// Calls the CreateButton function, which is defined below\n\t\t$this->CreateButton();\n\t}", "public function process()\n\t{\t\n\t\tif ($iDeleteId = $this->request()->getInt('delete'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->delete($iDeleteId))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', null, Phpfox::getPhrase('admincp.menu_successfully_deleted'));\t\n\t\t\t}\n\t\t}\n\t\t\n\t\tif ($aVals = $this->request()->getArray('val'))\n\t\t{\n\t\t\tif (Phpfox::getService('admincp.menu.process')->updateOrder($aVals))\n\t\t\t{\n\t\t\t\t$this->url()->send('admincp.menu', array('parent' => $this->request()->getInt('parent')), Phpfox::getPhrase('admincp.menu_order_successfully_updated'));\t\n\t\t\t}\t\t\t\n\t\t}\n\t\t\n\t\t$iParentId = $this->request()->getInt('parent');\t\t\n\t\tif ($iParentId > 0)\n\t\t{\n\t\t\t$aMenu = Phpfox::getService('admincp.menu')->getForEdit($iParentId);\n\t\t\tif (isset($aMenu['menu_id']))\n\t\t\t{\n\t\t\t\t$this->template()->assign('aParentMenu', $aMenu);\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$iParentId = 0;\n\t\t\t}\n\t\t}\n\t\t\n\t\t$aTypes = Phpfox::getService('admincp.menu')->getTypes();\n\t\t$aRows = Phpfox::getService('admincp.menu')->get(($iParentId > 0 ? array('menu.parent_id = ' . (int) $iParentId) : array('menu.parent_id = 0')));\n\t\t$aMenus = array();\n\t\t$aModules = array();\n\t\t\n\t\tforeach ($aRows as $iKey => $aRow)\n\t\t{\n\t\t\tif(Phpfox::isModule($aRow['module_id']))\n\t\t\t{\n\t\t\t\tif (!$iParentId && in_array($aRow['m_connection'], $aTypes))\n\t\t\t\t{\n\t\t\t\t\t$aMenus[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\n\t\t\t\telse \n\t\t\t\t{\n\t\t\t\t\tif ($aRow['m_connection'] == 'mobile' || $aRow['m_connection'] == 'main_right') {\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t}\n\n\t\t\t\t\t$aModules[$aRow['m_connection']][] = $aRow;\n\t\t\t\t}\t\t\t\n\t\t\t}\n\t\t}\n\t\tunset($aRows);\t\t\n\t\n\t\t$this->template()\n\t\t\t->setBreadCrumb('CMS', '#cms')\n\t\t\t->setBreadcrumb('Menus', $this->url()->makeUrl('admincp.menu'), true)\n\t\t\t->setTitle('Menus')\n\t\t\t->assign(array(\n\t\t\t\t'aMenus' => $aMenus,\n\t\t\t\t'aModules' => $aModules,\n\t\t\t\t'iParentId' => $iParentId\n\t\t\t)\n\t\t);\n\t}", "public function manage_events()\n {\n if($this->Auth->user('level') != \"Officer\" && $this->Auth->user('level') != \"Admin\")\n $this->redirect(\n array('controller' => 'Users', 'action' => 'profilehub/' . $this->Auth->user('id')));\n \n $allRsvps = $this->Event->EventsUser->find('all');\n $this->set('rsvps', $allRsvps);\n \n $this->EventHelper(); \n \n $this->layout = 'hero-ish';\n $this->Session->write('Page', 'Hub');\n }", "function handleEvent(EventContext $context)\n {\n $event_name = $context->getEventName();\n\n if ($event_name == \"manage_program_items\")\n {\n $this->handleManageProgramItems($context);\n }\n else if ($event_name == \"cancel_program_item_editor\")\n {\n $this->handleCancelProgramItemEditor($context);\n }\n else if ($event_name == \"cancel_program_item_selector\")\n {\n $this->handleCancelProgramItemSelector($context);\n }\n else if ($event_name == \"delete_program_items\")\n {\n $this->handleDeleteProgramItems($context);\n }\n else if ($event_name == \"delete_program_item\")\n {\n $this->handleDeleteProgramItem($context);\n }\n else if ($event_name == \"save_program_item\")\n {\n $this->handleSaveProgramItem($context);\n }\n else if ($event_name == \"refresh_program_item\")\n {\n $this->handleRefreshProgramItem($context);\n }\n else if ($event_name == \"edit_program_item\")\n {\n $this->handleEditProgramItem($context);\n }\n else if ($event_name == \"create_program_item\")\n {\n $this->handleCreateProgramItem($context);\n }\n else if ($event_name == \"cancel_related_person_editor\")\n {\n $this->handleCancelRelatedPersonEditor($context);\n }\n else if ($event_name == \"store_related_person\")\n {\n $this->handleStoreRelatedPerson($context);\n }\n else if ($event_name == \"create_related_person\")\n {\n $this->handleCreateRelatedPerson($context);\n }\n else if ($event_name == \"edit_related_person\")\n {\n $this->handleEditRelatedPerson($context);\n }\n else if ($event_name == \"delete_related_persons\")\n {\n $this->handleDeleteRelatedPersons($context);\n }\n else if ($event_name == \"delete_related_person\")\n {\n $this->handleDeleteRelatedPerson($context);\n }\n }", "protected function _register_controls() {\n\t}", "protected function _register_controls_parent() {\n $this->start_controls_section(\n 'custom_css_section',\n [\n 'label' => __('Custom CSS', 'unifato_addons'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n\n\t\t$this->add_control(\n\t\t\t'custom_css',\n\t\t\t[\n\t\t\t\t'label' => __( 'Custom CSS', 'unifato_addons' ),\n 'description' => __('Use <span style=\"color: red\">[SELECTOR]</span> to target selector. <br/><br/> <i>Example:</i> <br /><pre style=\"font-style: normal\">[SELECTOR] a {<br /> color: red;<br />}</pre>', 'unifato_addons'),\n 'default' => '',\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::CODE,\n\t\t\t\t'language' => 'css',\n\t\t\t\t'rows' => 20,\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'additional_style_section',\n [\n 'label' => __('Additional Style', 'unifato_addons'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'white_skin',\n [\n 'label' => __('White Skin?', 'unifato_addons'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'label_on' => __( 'Yes', 'unifato_addons' ),\n 'label_off' => __( 'No', 'unifato_addons' ),\n 'return_value' => 'text-white',\n 'default' => 'no',\n 'dynamic' => [\n 'active' => true\n ],\n 'prefix_class' => '',\n ]\n );\n\n $this->end_controls_section();\n }", "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "public static function getSubscribedEvents()\n {\n return array(EventInterface::EXECUTE_DEFINITION => array('executeChainedSteps', -50));\n }", "protected function Form_Run() {}", "public function main()\n {\n $workers = $this->getWorkers();\n $deadWorkers = [];\n $aliveWorkers = [];\n\n foreach($workers as $worker) {\n $isAlive = CremillaWorker::isAlive($worker->pid);\n if(!$isAlive) {\n $deadWorkers[] = $worker;\n }else{\n $aliveWorkers[] = $worker->id;\n }\n }\n\n if(!empty($aliveWorkers)) {\n $event = new Event('Cremilla.Worker.alive', $this, [\n 'data' => [\n 'aliveWorkers' => $aliveWorkers\n ]\n ]);\n $this->dispatchEvent($event);\n }\n\n if(!empty($deadWorkers)) {\n if($this->shouldNotifyWorkersDead(count($aliveWorkers))) {\n $event = new Event('Cremilla.Worker.dead', $this, [\n 'data' => [\n 'deadWorkers' => $deadWorkers\n ]\n ]);\n $this->dispatchEvent($event);\n }\n }\n }", "public function manage_resources($event) {\n global $DB;\n switch($event->eventname) {\n case '\\core\\event\\course_category_updated':\n $this->course_category_updated($event);\n break;\n case '\\core\\event\\course_updated':\n $this->course_updated($event);\n break;\n case '\\core\\event\\course_content_deleted':\n $this->course_content_deleted($event);\n break;\n case '\\core\\event\\course_restored':\n $this->course_restored($event);\n break;\n case '\\core\\event\\course_section_updated':\n $this->course_section_updated($event);\n break;\n case '\\core\\event\\course_module_created':\n $this->course_module_created($event);\n break;\n case '\\core\\event\\course_module_updated':\n $this->course_module_updated($event);\n break;\n case '\\core\\event\\course_module_deleted':\n $this->course_module_deleted($event);\n break;\n case '\\tool_recyclebin\\event\\course_bin_item_restored':\n $this->course_bin_item_restored($event);\n break;\n case '\\core\\event\\role_assigned':\n $this->role_assigned($event);\n break;\n case '\\core\\event\\role_unassigned':\n $this->role_unassigned($event);\n break;\n case '\\core\\event\\role_capabilities_updated':\n $this->role_capabilities_updated($event);\n break;\n case '\\core\\event\\group_member_added':\n case '\\core\\event\\group_member_removed':\n $this->group_member_added($event);\n break;\n case '\\core\\event\\grouping_group_assigned':\n case '\\core\\event\\grouping_group_unassigned':\n $this->grouping_group_assigned($event);\n break;\n case '\\core\\event\\user_enrolment_created':\n $this->user_enrolment_created($event);\n break;\n case '\\core\\event\\user_enrolment_updated':\n $this->user_enrolment_updated($event);\n break;\n case '\\core\\event\\user_enrolment_deleted':\n $this->user_enrolment_deleted($event);\n break;\n case '\\core\\event\\user_deleted':\n $this->user_deleted($event);\n break;\n case '\\repository_googledrive\\event\\repository_gdrive_tokens_created':\n break;\n case '\\repository_googledrive\\event\\repository_gdrive_tokens_deleted':\n break;\n default:\n return false;\n }\n return true;\n }", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "public function __deleteEvents() {\n $_deleteEventCodes_ = array(\n 'wk_pa_add_column_menu',\n 'wk_pa_addJs_product',\n 'wk_pa_product_model_delete',\n 'wk_pricealert_account_view',\n 'wk_pricealert_header',\n 'wk_pricealert_addJs_add',\n 'wk_pricealert_addJs_edit',\n 'wk_pa_product_model_update',\n 'wk_pa_product_model_add',\n );\n\n foreach ($_deleteEventCodes_ as $_DE_code) {\n $this->helper_event->deleteEventByCode($_DE_code);\n }\n }", "public static function getSubscribedEvents();", "public static function getSubscribedEvents();", "public function register_controls()\n {\n }", "protected function _register_controls()\r\n {\r\n\r\n\r\n $this->start_controls_section(\r\n 'slider_settings_section',\r\n [\r\n 'label' => esc_html__('Query Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_CONTENT,\r\n ]\r\n );\r\n $this->add_control(\r\n 'column',\r\n [\r\n 'label' => esc_html__('Column', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n '3' => esc_html__('04 Column', 'aapside-master'),\r\n '4' => esc_html__('03 Column', 'aapside-master'),\r\n '2' => esc_html__('06 Column', 'aapside-master')\r\n ),\r\n 'label_block' => true,\r\n 'description' => esc_html__('select grid column', 'aapside-master'),\r\n 'default' => '4'\r\n ]\r\n );\r\n $this->add_control(\r\n 'total',\r\n [\r\n 'label' => esc_html__('Total Post', 'aapside-master'),\r\n 'type' => Controls_Manager::TEXT,\r\n 'description' => esc_html__('enter how many post you want to show, enter -1 for unlimited', 'aapside-master'),\r\n 'default' => '-1'\r\n ]\r\n );\r\n $this->add_control(\r\n 'category',\r\n [\r\n 'label' => esc_html__('Category', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT2,\r\n 'multiple' => true,\r\n 'label_block' => true,\r\n 'description' => esc_html__('select category, for all category leave it blank', 'aapside-master'),\r\n 'options' => appside_master()->get_terms_names('portfolio-cat', 'id', true)\r\n ]\r\n );\r\n $this->add_control(\r\n 'orderby',\r\n [\r\n 'label' => esc_html__('Order By', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ID' => esc_html__('ID', 'aapside-master'),\r\n 'title' => esc_html__('Title', 'aapside-master'),\r\n 'date' => esc_html__('Date', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order by', 'aapside-master'),\r\n 'default' => 'ID'\r\n ]\r\n );\r\n $this->add_control(\r\n 'order',\r\n [\r\n 'label' => esc_html__('Order', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ASC' => esc_html__('Ascending', 'aapside-master'),\r\n 'DESC' => esc_html__('Descending', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order.', 'aapside-master'),\r\n 'default' => 'ASC'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination',\r\n [\r\n 'label' => esc_html__('Pagination', 'aapside-master'),\r\n 'type' => Controls_Manager::SWITCHER,\r\n 'description' => esc_html__('you can set yes to show pagination.', 'aapside-master'),\r\n 'default' => 'yes'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination_alignment',\r\n [\r\n 'label' => esc_html__('Pagination Alignment', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'left' => esc_html__('Left Align', 'aapside-master'),\r\n 'center' => esc_html__('Center Align', 'aapside-master'),\r\n 'right' => esc_html__('Right Align', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('you can set pagination alignment.', 'aapside-master'),\r\n 'default' => 'left',\r\n 'condition' => array('pagination' => 'yes')\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n $this->start_controls_section(\r\n 'thumbnail_settings_section',\r\n [\r\n 'label' => esc_html__('Thumbnail Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_control('thumb_border_radius', [\r\n 'label' => esc_html__('Border Radius', 'aapside-master'),\r\n 'type' => Controls_Manager::DIMENSIONS,\r\n 'size_units' => ['px', '%', 'em'],\r\n 'selectors' => [\r\n \"{{WRAPPER}} .hard-single-item-02 .thumb img\" => \"border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n ]\r\n ]);\r\n $this->add_control(\r\n 'thumbnail_bottom_gap',\r\n [\r\n 'label' => esc_html__('Thumbnail Bottom Gap', 'aapside-master'),\r\n 'type' => Controls_Manager::SLIDER,\r\n 'size_units' => ['px', '%'],\r\n 'range' => [\r\n 'px' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n 'step' => 1,\r\n ],\r\n '%' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n ],\r\n ],\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .thumb' => 'margin-bottom: {{SIZE}}{{UNIT}};',\r\n ],\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n\r\n /* title styling tabs start */\r\n $this->start_controls_section(\r\n 'title_settings_section',\r\n [\r\n 'label' => esc_html__('Title Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->start_controls_tabs(\r\n 'style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('title_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('title_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n\r\n /* title styling tabs end */\r\n\r\n /* readmore styling tabs start */\r\n $this->start_controls_section(\r\n 'readmore_settings_section',\r\n [\r\n 'label' => esc_html__('Category Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'readmore_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* readmore styling tabs end */\r\n\r\n /* pagination styling tabs start */\r\n $this->start_controls_section(\r\n 'pagination_settings_section',\r\n [\r\n 'label' => esc_html__('Pagination Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'pagination_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('pagination_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination` ul li a\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a, {{WRAPPER}} .portfolio-pagination ul li span\"\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('pagination_hover_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_hover_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a:hover, {{WRAPPER}} .Portfolio-pagination ul li span.current\"\r\n ]);\r\n\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* pagination styling tabs end */\r\n\r\n /* Typography tabs start */\r\n $this->start_controls_section(\r\n 'typography_settings_section',\r\n [\r\n 'label' => esc_html__('Typography Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'title_typography',\r\n 'label' => esc_html__('Title Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .title\"\r\n ]);\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'post_meta_typography',\r\n 'label' => esc_html__('Category Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .cats\"\r\n ]);\r\n $this->end_controls_section();\r\n\r\n /* Typography tabs end */\r\n }", "function osa_node_presave_group_class($node) {\r\n // get the master event\r\n civicrm_initialize();\r\n $master_event_id = $node->field_event_master['und'][0]['civicrm_reference_id'];\r\n $results = civicrm_api('event', 'get', array('id' => $master_event_id, 'version' => 3));\r\n $master_event = $results['values'][$master_event_id];\r\n\r\n // make a copy to use as a template\r\n $event = $master_event;\r\n $event['event_type_id'] = OSA_EVENT_GROUP_CLASS_CHILD;\r\n $event['is_public'] = TRUE;\r\n $event['is_online_registration'] = FALSE;\r\n unset($event['created_id']);\r\n unset($event['created_date']);\r\n unset($event['start_date']);\r\n unset($event['event_start_date']);\r\n unset($event['end_date']);\r\n unset($event['event_end_date']);\r\n $event['version'] = 3;\r\n \r\n // get existing child event ids\r\n $child_event_ids = isset($node->field_event_children['und'][0]['value']) ? json_decode($node->field_event_children['und'][0]['value']) : array();\r\n\r\n // loop through all of the session dates and create/update an event\r\n $session_dates = &$node->field_session_dates['und'];\r\n $i = 0;\r\n foreach ($session_dates as $session_date) {\r\n if (isset($child_event_ids[$i])) {\r\n $event['id'] = $child_event_ids[$i];\r\n }\r\n else {\r\n unset($event['id']);\r\n }\r\n \r\n $event['start_date'] = date('Y-m-d H:i:s', strtotime($session_date['value'] . ' ' . $session_date['timezone_db']));\r\n $event['end_date'] = date('Y-m-d H:i:s', strtotime($session_date['value2'] . ' ' . $session_date['timezone_db']));\r\n\r\n $results = civicrm_api('event', 'create', $event);\r\n $child_event_ids[$i++] = $results['id'];\r\n }\r\n\r\n // delete extra events\r\n if (count($child_event_ids) > count($session_dates)) {\r\n $lbound = count($session_dates);\r\n $ubound = count($child_event_ids);\r\n for ($i = $lbound; $i < $ubound; $i++) {\r\n $results = civicrm_api('event', 'delete', array('id' => $child_event_ids[$i], 'version' => 3));\r\n unset($child_event_ids[$i]);\r\n }\r\n }\r\n\r\n // reencode the child event array\r\n $node->field_event_children['und'][0]['value'] = json_encode($child_event_ids);\r\n \r\n // update the master event start and end\r\n if (count($session_dates) > 0) {\r\n $last = count($session_dates) - 1;\r\n $group_start = date('Y-m-d H:i:s', strtotime($session_dates[0]['value'] . ' ' . $session_dates[0]['timezone_db']));\r\n $group_end = date('Y-m-d H:i:s', strtotime($session_dates[$last]['value2'] . ' ' . $session_dates[$last]['timezone_db']));\r\n \r\n $params = array(\r\n 'id' => $master_event_id,\r\n 'version' => 3,\r\n );\r\n \r\n if ($group_start < $master_event['start_date']) {\r\n $params['start_date'] = $group_start;\r\n }\r\n if ($group_end > $master_event['end_date']) {\r\n $params['end_date'] = $group_end;\r\n }\r\n\r\n $results = civicrm_api('event', 'create', $params);\r\n }\r\n}", "protected function registerInputEvents() {\n\t\t$this->getEventLoop()->addEventListener('HANG', function($event) {\n\t\t\t// Update our state\n\t\t\t$this->offHook = (bool)$event['value'];\n\n\t\t\t// Trigger specific events for receiver up and down states\n\t\t\t$eventName = $this->isOffHook() ? 'RECEIVER_UP' : 'RECEIVER_DOWN';\n\t\t\t$this->fireEvents($eventName, $event);\n\t\t});\n\n\t\t$this->getEventLoop()->addEventListener('TRIG', function($event) {\n\t\t\t// Update our state\n\t\t\t$this->dialling = (bool)$event['value'];\n\t\t});\n\n\t\t// Proxy registration for all EventLoop events to pass them back up to our own listeners\n\t\t$this->getEventLoop()->addEventListener(true, function ($event, $type) {\n\t\t\t// Fire event to our own listeners\n\t\t\t$this->fireEvents($type, $event);\n\t\t});\n\t}", "public function preCommandEvent() {\n\t\t\tif (isset($_POST['rolecmd'])) {\n\t\t\t\tif (isset($_POST['roles'])) {\n\t\t\t\t\t$counter = count($_POST['roles']);\n\t\t\n\t\t\t\t} else {\n\t\t\t\t\t$counter = 0;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$pageid = $_POST['pageid'];\n\t\t\t\t$qry = \"DELETE FROM {$_SESSION['DB_PREFIX']}pageroles WHERE pageid = $pageid\";\n\t\t\t\t$result = mysql_query($qry);\n\t\t\t\t\n\t\t\t\tif (! $result) {\n\t\t\t\t\tlogError(mysql_error());\n\t\t\t\t}\n\t\t\n\t\t\t\tfor ($i = 0; $i < $counter; $i++) {\n\t\t\t\t\t$roleid = $_POST['roles'][$i];\n\t\t\t\t\t\n\t\t\t\t\t$qry = \"INSERT INTO {$_SESSION['DB_PREFIX']}pageroles (pageid, roleid, metacreateddate, metacreateduserid, metamodifieddate, metamodifieduserid) VALUES ($pageid, '$roleid', NOW(), \" . getLoggedOnMemberID() . \", NOW(), \" . getLoggedOnMemberID() . \")\";\n\t\t\t\t\t$result = mysql_query($qry);\n\t\t\t\t};\n\t\t\t}\n\t\t}", "public static function getSubscribedEvents()\n {\n return [\n FormEvents::PRE_SET_DATA => 'onPreSetData',\n ];\n }", "public static function getSubscribedEvents()\n {\n return [\n FormEvents::PRE_SET_DATA => 'onPreSetData',\n ];\n }", "function notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params = 0)\n\t{\n\t\tglobal $tree;\n\t\t\n\t\tswitch ($a_event)\n\t\t{\n\t\t\tcase \"link\":\n\t\t\t\t\n\t\t\t\t//var_dump(\"<pre>\",$a_params,\"</pre>\");\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by link event. Objects linked into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase \"cut\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by cut event. Objects are removed from target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase \"copy\":\n\t\t\t\n\t\t\t\t//var_dump(\"<pre>\",$a_params,\"</pre>\");\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by copy event. Objects are copied into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\n\t\t\tcase \"paste\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by paste (cut) event. Objects are pasted into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase \"new\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by paste (new) event. Objects are applied to target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\t// At the beginning of the recursive process it avoids second call of the notify function with the same parameter\n\t\tif ($a_node_id==$_GET[\"ref_id\"])\n\t\t{\t\n\t\t\t$parent_obj =& $this->ilias->obj_factory->getInstanceByRefId($a_node_id);\n\t\t\t$parent_type = $parent_obj->getType();\n\t\t\tif($parent_type == $this->getType())\n\t\t\t{\n\t\t\t\t$a_node_id = (int) $tree->getParentId($a_node_id);\n\t\t\t}\n\t\t}\n\t\t\n\t\tparent::notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params);\n\t}", "function notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params = 0)\n\t{\n\t\tglobal $tree;\n\t\t\n\t\tswitch ($a_event)\n\t\t{\n\t\t\tcase \"link\":\n\t\t\t\t\n\t\t\t\t//var_dump(\"<pre>\",$a_params,\"</pre>\");\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by link event. Objects linked into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase \"cut\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by cut event. Objects are removed from target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase \"copy\":\n\t\t\t\n\t\t\t\t//var_dump(\"<pre>\",$a_params,\"</pre>\");\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by copy event. Objects are copied into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\n\t\t\tcase \"paste\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by paste (cut) event. Objects are pasted into target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase \"new\":\n\t\t\t\t\n\t\t\t\t//echo \"Module name \".$this->getRefId().\" triggered by paste (new) event. Objects are applied to target object ref_id: \".$a_ref_id;\n\t\t\t\t//exit;\n\t\t\t\tbreak;\n\t\t}\n\n\t\t// At the beginning of the recursive process it avoids second call of the notify function with the same parameter\n\t\tif ($a_node_id==$_GET[\"ref_id\"])\n\t\t{\n\t\t\t$parent_obj =& $this->ilias->obj_factory->getInstanceByRefId($a_node_id);\n\t\t\t$parent_type = $parent_obj->getType();\n\t\t\tif($parent_type == $this->getType())\n\t\t\t{\n\t\t\t\t$a_node_id = (int) $tree->getParentId($a_node_id);\n\t\t\t}\n\t\t}\n\t\t\n\t\tparent::notify($a_event,$a_ref_id,$a_parent_non_rbac_id,$a_node_id,$a_params);\n\t}", "public function Process() {\n\t\tforeach($this->modules as $module) {\n\t\t\t$module->Run();\n\t\t}\n\t}", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SUBMIT => 'preSubmitData');\n }", "public static function getSubscribedEvents(): array\n {\n return [\n 'Enlight_Controller_Front_RouteShutdown' => ['handleError', 1000],\n 'Enlight_Controller_Front_PostDispatch' => ['handleError', 1000],\n 'Shopware_Console_Add_Command' => ['handleError', 1000],\n 'Enlight_Controller_Front_DispatchLoopShutdown' => ['handleException', 1000],\n ];\n }", "public function build_controls()\n\t{\n\t\t$this->add_control( 'title', [\n\t\t\t'label' => __( 'Title' )\n\t\t] );\n\t\t$this->add_control( 'content', [\n\t\t\t'label' => __( 'Content' ),\n\t\t\t'type' => 'textarea'\n\t\t] );\n\t\t$this->add_control( 'link_url', [\n\t\t\t'label' => __( 'URL' )\n\t\t] );\n\t\t$this->add_control( 'link_text', [\n\t\t\t'label' => __( 'Link Text' )\n\t\t] );\n\t\t$this->add_control( 'link_target', [\n\t\t\t'label' => __( 'Open link in a new window/tab' ),\n\t\t\t'type' => 'checkbox',\n\t\t\t'value' => '1'\n\t\t] );\n\t}", "public function getSubscribedEvents()\n {\n return array(\n 'command.php' => 'handleCommand',\n 'command.php.help' => 'handleCommandHelp'\n );\n }", "public function getChildActions() {}", "protected function _register_controls() {\n\n\t\t//link\n\t\t//image\n\t\t//featured\n\t\t//term\n\t\t//style alternative-imagebox\n\t\t//\n\t\t//\n\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-listeo' ),\n\t\t\t)\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link','elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'elementor-listeo' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Choose Background Image', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\n\n\t\t// $this->add_control(\n\t\t// \t'featured',\n\t\t// \t[\n\t\t// \t\t'label' => __( 'Featured badge', 'elementor-listeo' ),\n\t\t// \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t// \t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t// \t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t// \t\t'return_value' => 'yes',\n\t\t// \t\t'default' => 'yes',\n\t\t// \t]\n\t\t// );\n\n\t\t$this->add_control(\n\t\t\t'taxonomy',\n\t\t\t[\n\t\t\t\t'label' => __( 'Taxonomy', 'elementor-listeo' ),\n\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [],\n\t\t\t\t'options' => $this->get_taxonomies(),\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$taxonomy_names = get_object_taxonomies( 'listing','object' );\n\t\tforeach ($taxonomy_names as $key => $value) {\n\t\n\t\t\t$this->add_control(\n\t\t\t\t$value->name.'term',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Show term from '.$value->label, 'elementor-listeo' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'default' => [],\n\t\t\t\t\t'options' => $this->get_terms($value->name),\n\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t'taxonomy' => $value->name,\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\n\n\t\t$this->add_control(\n\t\t\t'show_counter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show listings counter', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t\t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style ', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' => 'alternative-imagebox',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'elementor-listeo' ),\n\t\t\t\t\t'alternative-imagebox' => __( 'Alternative', 'elementor-listeo' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "protected function _register_controls() {\n\n $nav_menus = wp_get_nav_menus();\n\n $nav_menus_option = array(\n esc_html__( 'Select a menu', 'Alita-extensions' ) => '',\n );\n\n foreach ( $nav_menus as $key => $nav_menu ) {\n $nav_menus_option[$nav_menu->name] = $nav_menu->name;\n }\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'description' => esc_html__( 'Enter the title of menu.', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => 'Alita Best Selling:',\n ]\n );\n\n $this->add_control(\n 'menu',\n [\n\n 'label' => esc_html__( 'Menu', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'vertical-menu',\n 'options' => $nav_menus_option,\n ]\n );\n \n\n $this->end_controls_section();\n\n }", "public function setup()\n {\n parent::setup();\n \n $formClass = $this->getChildFormClass();\n $collection = $this->getParentObject()->{$this->getRelationAlias()};\n $nbChilds = 0;\n $min = $this->getMinNbChilds();\n $max = $this->getMaxNbChilds();\n \n if ($min > $max && $max > 0)\n throw new RuntimeException('min cannot be greater than max.');\n \n // embed forms for each child element that is already persisted\n foreach ($collection as $childObject)\n {\n $form = new $formClass($childObject);\n $pk = $childObject->identifier();\n \n if ($childObject->exists() === false)\n throw new RuntimeException('Transient child objects are not supported.');\n \n if (count($pk) !== 1)\n throw new RuntimeException('Composite primary keys are not supported.');\n \n $this->embedForm(self::PERSISTENT_PREFIX.reset($pk), $form);\n $nbChilds += 1;\n }\n \n // embed as many additional forms as are needed to reach the minimum\n // number of required child objects\n for (; $nbChilds < $min; $nbChilds += 1)\n {\n $form = new $formClass($collection->get(null));\n $this->embedForm(self::TRANSIENT_PREFIX.$nbChilds, $form);\n }\n \n $this->validatorSchema->setPostValidator(new sfValidatorCallback(array(\n 'callback' => array($this, 'validateLogic'),\n )));\n }" ]
[ "0.56012887", "0.5482056", "0.54510766", "0.54382145", "0.54382145", "0.54213244", "0.5405056", "0.53763425", "0.5334136", "0.5183241", "0.51739675", "0.51544315", "0.5145999", "0.51412684", "0.5098046", "0.5094869", "0.5040122", "0.50085795", "0.5001102", "0.49991113", "0.49932012", "0.49930477", "0.4975836", "0.49558166", "0.49556908", "0.49176058", "0.48979276", "0.4872361", "0.4859083", "0.48580903", "0.48449165", "0.48449165", "0.48438433", "0.48288295", "0.48243177", "0.4815526", "0.4791392", "0.47821748", "0.47739768", "0.47702718", "0.47702718", "0.47468194", "0.4740237", "0.47305503", "0.47106615", "0.46999493", "0.46975946", "0.46958828", "0.46948937", "0.467866", "0.46720633", "0.46715215", "0.4669371", "0.4669371", "0.4669371", "0.4657813", "0.46571442", "0.46460488", "0.4645123", "0.463617", "0.46305794", "0.46297252", "0.46171793", "0.46159512", "0.46065718", "0.4606473", "0.4604257", "0.4603151", "0.46024403", "0.45974427", "0.4597047", "0.45905828", "0.45901912", "0.45855013", "0.45847568", "0.45676008", "0.45665875", "0.45642462", "0.45479026", "0.4546458", "0.45303616", "0.45303616", "0.4523301", "0.4522134", "0.4505533", "0.45027417", "0.4500215", "0.44996655", "0.44996655", "0.44974533", "0.44928762", "0.44917375", "0.44880295", "0.4487597", "0.44865564", "0.44841394", "0.44830802", "0.4481752", "0.44784388", "0.44773337" ]
0.5854552
0
Notifies server controls that use compositionbased implementation to create any child controls they contain in preparation for posting back or rendering.
function CreateChildControls() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function InitChildControls() {\n }", "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "public function createChildControls ()\n\t{\n\t\tif ($this->_container===null)\n\t\t{\n\t\t\t$this->_container=Prado::CreateComponent('System.Web.UI.ActiveControls.TActivePanel');\n\t\t\t$this->_container->setId($this->getId(false).'_content');\n\t\t\tparent::getControls()->add($this->_container);\n\t\t}\n\t}", "public function afterLoadRegisterControlsUI(){\n\t\t\n\t}", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore \n\n\t\t$this->register_general_content_controls();\n\n\t\t$this->register_count_content_controls();\n\n\t\t$this->register_helpful_information();\n\t}", "protected function _register_controls() {\n\t}", "public function customize_controls_init()\n {\n }", "public function prepare_controls()\n {\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "function customize_controls_init()\n {\n }", "public function register_controls()\n {\n }", "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "public function Render()\n\t{\n\t // when in NEW mode or when parent form in NEW mode, do nothing\n\t global $g_BizSystem;\n\t $prtMode = \"\";\n\t if ($this->m_ParentFormName) {\n $prtForm = $g_BizSystem->GetObjectFactory()->GetObject($this->m_ParentFormName);\n $prtMode = $prtForm->GetDisplayMode()->GetMode();\n\t }\n\t if ($this->m_Mode != MODE_N && $prtMode != MODE_N)\n\t {\n \t // get view history\n \t if (!$this->m_NoHistoryInfo)\n\t $this->SetHistoryInfo($g_BizSystem->GetSessionContext()->GetViewHistory($this->m_Name));\n\t }\n\t if ($this->m_Mode == MODE_N)\n $this->UpdateActiveRecord($this->GetDataObj()->NewRecord());\n\n //Moved the renderHTML function infront of declaring subforms\n $renderedHTML = $this->RenderHTML();\n\n\t global $g_BizSystem;\n\t // prepare the subforms' dataobjs, since the subform relates to parent form by dataobj association\n\t if ($this->m_SubForms) {\n \t foreach($this->m_SubForms as $subForm) {\n $formObj = $g_BizSystem->GetObjectFactory()->GetObject($subForm);\n $dataObj = $this->GetDataObj()->GetRefObject($formObj->m_DataObjName);\n if ($dataObj)\n $formObj->SetDataObj($dataObj);\n }\n\t }\n\t $this->SetClientScripts();\n\n return $renderedHTML;\n\t}", "function initRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n @$control->Page = &$this->Page;\n $control->initRecursive();\n }\n }\n $this->_state = WEB_CONTROL_INITIALIZED;\n $this->ControlOnInit();\n }", "function ControlOnLoad(){\n parent::ControlOnLoad();\n }", "private function composeControlPanel()\n {\n $this->composeControlPanelSideMenu();\n $this->composeControlPanelImagesBrowser();\n }", "function CreateChildControls(){\n parent::CreateChildControls();\n $this->AddControl(new SitemapControl(\"cms_sitemap\", \"cms_sitemap\"));\n }", "public function setup()\n {\n parent::setup();\n \n $formClass = $this->getChildFormClass();\n $collection = $this->getParentObject()->{$this->getRelationAlias()};\n $nbChilds = 0;\n $min = $this->getMinNbChilds();\n $max = $this->getMaxNbChilds();\n \n if ($min > $max && $max > 0)\n throw new RuntimeException('min cannot be greater than max.');\n \n // embed forms for each child element that is already persisted\n foreach ($collection as $childObject)\n {\n $form = new $formClass($childObject);\n $pk = $childObject->identifier();\n \n if ($childObject->exists() === false)\n throw new RuntimeException('Transient child objects are not supported.');\n \n if (count($pk) !== 1)\n throw new RuntimeException('Composite primary keys are not supported.');\n \n $this->embedForm(self::PERSISTENT_PREFIX.reset($pk), $form);\n $nbChilds += 1;\n }\n \n // embed as many additional forms as are needed to reach the minimum\n // number of required child objects\n for (; $nbChilds < $min; $nbChilds += 1)\n {\n $form = new $formClass($collection->get(null));\n $this->embedForm(self::TRANSIENT_PREFIX.$nbChilds, $form);\n }\n \n $this->validatorSchema->setPostValidator(new sfValidatorCallback(array(\n 'callback' => array($this, 'validateLogic'),\n )));\n }", "public function preRender() {\n\t\tif ($this->hasOwnBoundObject()) {\n\t\t\t$this->ownBoundObject = $this->getBoundObject();\n\t\t}\n\t\tparent::preRender();\n\t}", "public function output_widget_control_templates()\n {\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'client_logo',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Choose Image', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => Utils::get_placeholder_image_src(),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_name',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Title', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Client Name', 'elementive' ),\n\t\t\t\t'placeholder' => __( 'Type your client name here', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_link',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Link', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-client.com', 'elementive' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'clients',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Clients List', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => array(),\n\t\t\t\t'title_field' => '{{{ client_name }}}',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'max_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Logo max width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 600,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo img' => 'max-width : {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 0.5,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo:hover' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_carousel',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_SETTINGS,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'vertical_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Vertical align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-flex-top',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-flex-top' => __( 'Top', 'elementive' ),\n\t\t\t\t\t'uk-flex-middle' => __( 'Middle', 'elementive' ),\n\t\t\t\t\t'uk-flex-bottom' => __( 'Bottom', 'elementive' ),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'auto_play',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Enable auto play', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t\t'separator' => 'after',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'columns',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Columns', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 6,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 2,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'margins',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Column margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'overflow',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Overflow', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Loop', 'elementive' ),\n\t\t\t\t'description' => __( 'Set to yes to enable continuous loop mode', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'centered',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Centered slider', 'elementive' ),\n\t\t\t\t'description' => __( 'If yes, then active slide will be centered, not always on the left side.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'speed',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Speed', 'elementive' ),\n\t\t\t\t'description' => __( 'Speed of the enter/exit transition.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 10,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 500,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Navigation', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_diameter_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Diameter', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 30,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 40,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation ' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}}; line-height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_icon_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Icon width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 10,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'navigation_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background_hover',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation .navigation-background-hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->add_control(\n\t\t\t'pagination',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Pagination', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_bullet_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-text-center',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-text-center' => __( 'Center', 'elementive' ),\n\t\t\t\t\t'uk-text-left' => __( 'Left', 'elementive' ),\n\t\t\t\t\t'uk-text-right' => __( 'Right', 'elementive' ),\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bottom',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bottom size', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-pagination ' => 'bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_margin',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'margin: 0 {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 3,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_height',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet height', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 10,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'pagination_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Active', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_diameter_width_active',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 40,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 8,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t// End carousel navigation section.\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n\n\t\t//link\n\t\t//image\n\t\t//featured\n\t\t//term\n\t\t//style alternative-imagebox\n\t\t//\n\t\t//\n\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-listeo' ),\n\t\t\t)\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link','elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'elementor-listeo' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Choose Background Image', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\n\n\t\t// $this->add_control(\n\t\t// \t'featured',\n\t\t// \t[\n\t\t// \t\t'label' => __( 'Featured badge', 'elementor-listeo' ),\n\t\t// \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t// \t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t// \t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t// \t\t'return_value' => 'yes',\n\t\t// \t\t'default' => 'yes',\n\t\t// \t]\n\t\t// );\n\n\t\t$this->add_control(\n\t\t\t'taxonomy',\n\t\t\t[\n\t\t\t\t'label' => __( 'Taxonomy', 'elementor-listeo' ),\n\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [],\n\t\t\t\t'options' => $this->get_taxonomies(),\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$taxonomy_names = get_object_taxonomies( 'listing','object' );\n\t\tforeach ($taxonomy_names as $key => $value) {\n\t\n\t\t\t$this->add_control(\n\t\t\t\t$value->name.'term',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Show term from '.$value->label, 'elementor-listeo' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'default' => [],\n\t\t\t\t\t'options' => $this->get_terms($value->name),\n\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t'taxonomy' => $value->name,\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\n\n\t\t$this->add_control(\n\t\t\t'show_counter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show listings counter', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t\t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style ', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' => 'alternative-imagebox',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'elementor-listeo' ),\n\t\t\t\t\t'alternative-imagebox' => __( 'Alternative', 'elementor-listeo' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "public function build_controls()\n {\n $this->add_control( 'id', [\n 'label' => __( 'Post', 'customize-static-layout' ),\n 'type' => 'object_selector',\n 'post_query_vars' => static::get_post_query_vars(),\n 'select2_options' => [\n 'allowClear' => true,\n 'placeholder' => __( '&mdash; Select &mdash;', 'customize-static-layout' ),\n ],\n ], 'CustomizeObjectSelector\\Control' );\n }", "public function build_controls()\n\t{\n\t\t$this->add_control( 'title', [\n\t\t\t'label' => __( 'Title' )\n\t\t] );\n\t\t$this->add_control( 'content', [\n\t\t\t'label' => __( 'Content' ),\n\t\t\t'type' => 'textarea'\n\t\t] );\n\t\t$this->add_control( 'link_url', [\n\t\t\t'label' => __( 'URL' )\n\t\t] );\n\t\t$this->add_control( 'link_text', [\n\t\t\t'label' => __( 'Link Text' )\n\t\t] );\n\t\t$this->add_control( 'link_target', [\n\t\t\t'label' => __( 'Open link in a new window/tab' ),\n\t\t\t'type' => 'checkbox',\n\t\t\t'value' => '1'\n\t\t] );\n\t}", "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Video Testimonials Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'vid_testimonial_view',\n [\n 'label' => __('Style', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'view1',\n 'options' => [\n 'view1' => __('Style 1', 'careerfy-frame'),\n 'view2' => __('Style 2', 'careerfy-frame'),\n 'view3' => __('Style 3', 'careerfy-frame'),\n ],\n ]\n );\n\n $repeater = new \\Elementor\\Repeater();\n $repeater->add_control(\n 'vid_testimonial_img', [\n 'label' => __('Image', 'careerfy-frame'),\n 'type' => Controls_Manager::MEDIA,\n 'label_block' => true,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ]\n );\n\n $repeater->add_control(\n 'vid_url', [\n 'label' => __('Video URL', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n \"description\" => __(\"Put Video URL of Vimeo, Youtube.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_title', [\n 'label' => __('Client Name', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('client Title will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n\n $repeater->add_control(\n 'rank_title', [\n 'label' => __('Client Rank', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('Client Rank will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'company_title', [\n 'label' => __('Client Company', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Company will be applied to style 1 and style 2.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'testimonial_desc', [\n 'label' => __('Description', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXTAREA,\n 'label_block' => true,\n \"description\" => __(\"Testimonial Description will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_location', [\n 'label' => __('Client Location', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Location will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n $this->add_control(\n 'careerfy_video_testimonial_item',\n [\n 'label' => __('Add video testimonial item', 'careerfy-frame'),\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'title_field' => '{{{ company_title }}}',\n ]\n );\n $this->end_controls_section();\n }", "protected function _register_controls_parent() {\n $this->start_controls_section(\n 'custom_css_section',\n [\n 'label' => __('Custom CSS', 'unifato_addons'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n\n\t\t$this->add_control(\n\t\t\t'custom_css',\n\t\t\t[\n\t\t\t\t'label' => __( 'Custom CSS', 'unifato_addons' ),\n 'description' => __('Use <span style=\"color: red\">[SELECTOR]</span> to target selector. <br/><br/> <i>Example:</i> <br /><pre style=\"font-style: normal\">[SELECTOR] a {<br /> color: red;<br />}</pre>', 'unifato_addons'),\n 'default' => '',\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::CODE,\n\t\t\t\t'language' => 'css',\n\t\t\t\t'rows' => 20,\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'additional_style_section',\n [\n 'label' => __('Additional Style', 'unifato_addons'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'white_skin',\n [\n 'label' => __('White Skin?', 'unifato_addons'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'label_on' => __( 'Yes', 'unifato_addons' ),\n 'label_off' => __( 'No', 'unifato_addons' ),\n 'return_value' => 'text-white',\n 'default' => 'no',\n 'dynamic' => [\n 'active' => true\n ],\n 'prefix_class' => '',\n ]\n );\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Clients Settings', 'elementor-main-clients' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t 'clients-columns',\n\t\t \t[\n\t\t \t'label' \t=> esc_html__( 'Column', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> '2',\n\t\t \t'options' \t\t=> [\t\t\t\t\n\t\t\t\t\t'1' => esc_html__('1 Column', 'baldiyaat'),\n\t\t\t\t\t'2' => esc_html__('2 Column', 'baldiyaat'),\n\t\t\t\t\t'3' => esc_html__('3 Column', 'baldiyaat'),\n\t\t\t\t\t'4' => esc_html__('4 Column', 'baldiyaat'),\n\t\t\t\t\t'6' => esc_html__('6 Column', 'baldiyaat')\n\t\t \t],\n\t\t \t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'thumbnail-size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Thumbnail Size', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'label_block' \t=> false,\n\t\t\t\t'default' => esc_html__( 'hide', 'essential-addons-elementor' ),\n\t\t \t'options' => wpha_get_thumbnail_list(),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'num-fetch',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Num Fetch', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => 10,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_config_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Clients Images', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'slider',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide',\n\t\t\t\t\t\t'label' => esc_html__( 'Image', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'url' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png',\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_caption',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Caption', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_enable_slide_link',\n\t\t\t\t\t\t'label' => __( 'Enable Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'default' => 'false',\n\t\t\t\t\t\t'label_on' => esc_html__( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'label_off' => esc_html__( 'No', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'return_value' => 'true',\n\t\t\t\t\t\t\n\t\t\t\t \t],\n\t\t\t\t \t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_link',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => [\n\t\t \t\t\t'url' => '#',\n\t\t \t\t\t'is_external' => '',\n\t\t \t\t\t],\n\t\t \t\t\t'show_external' => true,\n\t\t \t\t\t'condition' => [\n\t\t \t\t\t\t'main_clients_settings_enable_slide_link' => 'true'\n\t\t \t\t\t]\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{main_clients_settings_slide_title}}',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_color_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color & Design', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Sub Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .kode-sub-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_caption_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Caption Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-des' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button BG Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'background-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t\n\t}", "protected function register_controls() {\n\n\t\t$this->render_team_member_content_control();\n\t\t$this->register_content_separator();\n\t\t$this->register_content_social_icons_controls();\n\t\t$this->register_helpful_information();\n\n\t\t/* Style */\n\t\t$this->register_style_team_member_image();\n\t\t$this->register_style_team_member_name();\n\t\t$this->register_style_team_member_designation();\n\t\t$this->register_style_team_member_desc();\n\t\t$this->register_style_team_member_icon();\n\t\t$this->register_content_spacing_control();\n\t}", "protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }", "protected function _register_controls()\n {\n global $post;\n $page = get_post($post->ID);\n $pageTitle = $page->post_title;\n\n // Top post's part starts\n $this->start_controls_section(\n 'section_top',\n [\n 'label' => __('Top part of article', 'elementor'),\n ]\n );\n\n $this->add_control(\n 'page_title',\n [\n 'label' => 'Type page title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => $pageTitle,\n// 'default' => 'TEXT TITLE',\n ]\n );\n\n $this->add_control(\n 'page_subtitle',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'blog_content_top',\n [\n 'label' => __('Top article part', 'elementor'),\n 'default' => __('Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_middle',\n [\n 'label' => __('Middle article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_bottom',\n [\n 'label' => __('Bottom article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->end_controls_section();\n // Top post's part ends\n\n // Middle post's part starts\n $this->start_controls_section(\n 'section_middle',\n [\n 'label' => __('Middle part of article', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'the_quote',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n 'default' => __('“We’re seeing some really bullish bitcoin price action today along with other ...',\n 'plugin-domain'),\n ]\n );\n\n $this->end_controls_section();\n // Midddle post's part ends\n }", "public function render_control_templates()\n {\n }", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'electro-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'electro-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'electro-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'electro-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'electro-extensions' ),\n 'return_value' => 'true',\n 'default' => 'false',\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'electro-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'electro-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'electro-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'electro-extensions' ),\n 'random' =>esc_html__( 'Random', 'electro-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'electro-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'electro-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "public function Populate() {\r\n\t\t$form_instance = $this->form_instance;\r\n\t\t// Retrieve the field data\r\n\t\t$_els = vcff_parse_container_data($form_instance->form_content);\r\n\t\t// If an error has been detected, return out\r\n\t\tif (!$_els || !is_array($_els)) { return; }\r\n\t\t// Retrieve the form instance\r\n\t\t$form_instance = $this->form_instance; \r\n\t\t// Loop through each of the containers\r\n\t\tforeach ($_els as $k => $_el) {\r\n\t\t\t// Retrieve the container instance\r\n\t\t\t$container_instance = $this->_Get_Container_Instance($_el);\r\n\t\t\t// Add the container to the form instance\r\n\t\t\t$form_instance->Add_Container($container_instance);\r\n\t\t}\r\n\t}", "protected function OnCreateElements() {}", "protected function OnCreateElements() {}", "protected function _register_controls()\n {\n\n global $rand_num;\n $rand_num = rand(10000000, 99909999);\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Section Heading Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n $this->add_control(\n 'view',\n [\n 'label' => __('Style', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'view1',\n 'options' => [\n 'view1' => __('Style 1', 'careerfy-frame'),\n 'view2' => __('Style 2', 'careerfy-frame'),\n 'view3' => __('Style 3', 'careerfy-frame'),\n 'view4' => __('Style 4', 'careerfy-frame'),\n 'view5' => __('Style 5', 'careerfy-frame'),\n 'view6' => __('Style 6', 'careerfy-frame'),\n 'view7' => __('Style 7', 'careerfy-frame'),\n 'view8' => __('Style 8', 'careerfy-frame'),\n 'view9' => __('Style 9', 'careerfy-frame'),\n 'view10' => __('Style 10', 'careerfy-frame'),\n 'view11' => __('Style 11', 'careerfy-frame'),\n 'view12' => __('Style 12', 'careerfy-frame'),\n 'view13' => __('Style 13', 'careerfy-frame'),\n 'view14' => __('Style 14', 'careerfy-frame'),\n 'view15' => __('Style 15', 'careerfy-frame'),\n 'view16' => __('Style 16', 'careerfy-frame'),\n 'view17' => __('Style 17', 'careerfy-frame'),\n 'view18' => __('Style 18', 'careerfy-frame'),\n ],\n ]\n );\n $this->add_control(\n 's_title',\n [\n 'label' => __('Small Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => ['view6','view18']\n ],\n ]\n );\n $this->add_control(\n 'heading_img',\n [\n 'label' => __('Image', 'careerfy-frame'),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n 'condition' => [\n 'view' => array('view8', 'view15')\n ],\n ]\n );\n $this->add_control(\n 'h_title',\n [\n 'label' => __('Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n\n ]\n );\n $this->add_control(\n 'num_title',\n [\n 'label' => __('Title Number', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'h_fancy_title',\n [\n 'label' => __('Fancy Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n\n $this->add_control(\n 'hc_icon',\n [\n 'label' => __('Icon', 'careerfy-frame'),\n 'type' => Controls_Manager::ICONS,\n 'description' => __(\"This will apply to heading style 3 only.\", \"careerfy-frame\"),\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n $this->add_control(\n 'h_desc',\n [\n 'label' => __('Description', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXTAREA,\n ]\n );\n\n $this->add_control(\n 'text_align',\n [\n 'label' => __('Text Align', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'center',\n 'options' => [\n 'center' => __('Center', 'careerfy-frame'),\n 'left' => __('Left', 'careerfy-frame'),\n\n ],\n 'condition' => [\n 'view' => array('view7', 'view8', 'view17','view18')\n ],\n ]\n );\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Heading Style', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'hc_title',\n [\n 'label' => __('Color Title', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n $this->add_control(\n 's_title_clr',\n [\n 'label' => __('Choose Small Title Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => ['view6','view18']\n ],\n ]\n );\n $this->add_control(\n 'hc_title_clr',\n [\n 'label' => __('Choose Title Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'description' => __(\"This Color will apply to 'Color Title'.\", \"careerfy-frame\"),\n\n ]\n );\n $this->add_control(\n 'desc_clr',\n [\n 'label' => __('Choose Description Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'proc_num_clr',\n [\n 'label' => __('Choose Process Number Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'hc_dcolor',\n [\n 'label' => __('Description Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'description' => __(\"This will apply to the description only.\", \"careerfy-frame\"),\n\n ]\n );\n\n\n $this->end_controls_section();\n }", "protected function RenderAjax() {\r\n\t\t\t$strToReturn = '<controls>';\r\n\r\n\t\t\t// Include each control (if applicable) that has been changed/modified\r\n\t\t\tforeach ($this->GetAllControls() as $objControl)\r\n\t\t\t\tif (!$objControl->ParentControl)\r\n//\t\t\t\t\t$strToReturn .= $objControl->RenderAjax(false) . \"\\r\\n\";\r\n\t\t\t\t\t$strToReturn .= $this->RenderAjaxHelper($objControl);\r\n\r\n\t\t\t$strCommands = '';\r\n\t\t\t\r\n\t\t\t// Look to the Application object for any commands to run\r\n\t\t\tforeach (QApplication::$AlertMessageArray as $strAlert) {\r\n\t\t\t\t$strAlert = QString::XmlEscape(sprintf('alert(\"%s\");', addslashes($strAlert)));\r\n\t\t\t\t$strCommands .= sprintf('<command>%s</command>', $strAlert);\r\n\t\t\t}\r\n\t\t\tforeach (QApplication::$JavaScriptArrayHighPriority as $strJavaScript) {\r\n\t\t\t\t$strJavaScript = trim($strJavaScript);\r\n\t\t\t\t\r\n\t\t\t\tif (strlen($strJavaScript)) {\r\n\t\t\t\t\tif (QString::LastCharacter($strJavaScript) != ';')\r\n\t\t\t\t\t\t$strJavaScript .= ';';\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strJavaScript));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tforeach (QApplication::$JavaScriptArray as $strJavaScript) {\r\n\t\t\t\t$strJavaScript = trim($strJavaScript);\r\n\t\t\t\tif (strlen($strJavaScript)) {\r\n\t\t\t\t\tif (QString::LastCharacter($strJavaScript) != ';')\r\n\t\t\t\t\t\t$strJavaScript .= ';';\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strJavaScript));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t$strRegCJavaScript = '';\r\n\t\t\tforeach ($this->GetAllControls() as $objControl) {\r\n\t\t\t\tif ($objControl->Rendered) {\r\n\t\t\t\t\t$strRegCJavaScript .= sprintf('qc.regC(\"%s\"); ', $objControl->ControlId);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif ($strRegCJavaScript)\r\n\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strRegCJavaScript));\r\n\r\n\t\t\tforeach ($this->GetAllControls() as $objControl) {\r\n\t\t\t\tif ($objControl->Rendered) {\r\n\t\t\t\t\t$strJavaScript = $objControl->GetEndScript();\r\n\t\t\t\t\tif (strlen($strJavaScript))\r\n\t\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($objControl->GetEndScript()));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tforeach ($this->objGroupingArray as $objGrouping) {\r\n\t\t\t\t$strRender = $objGrouping->Render();\r\n\t\t\t\tif (trim($strRender))\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strRender));\r\n\t\t\t}\r\n\r\n\t\t\t// Add in the form state\r\n\t\t\t// DO SOMETHING DIFFERENT IF FORM IS UseSession\r\n\t\t\t$strFormState = QForm::Serialize($this);\r\n\t\t\t$strToReturn .= sprintf('<control id=\"Qform__FormState\">%s</control>', $strFormState);\r\n\r\n\t\t\t// close Control collection, Open the Command collection\r\n\t\t\t$strToReturn .= '</controls><commands>';\r\n\t\t\t\r\n\t\t\t$strToReturn .= $strCommands;\r\n\r\n\t\t\t// close Command collection\r\n\t\t\t$strToReturn .= '</commands>';\r\n\r\n\t\t\t$strContents = trim(ob_get_contents());\r\n\r\n\t\t\tif (strtolower(substr($strContents, 0, 5)) == 'debug') {\r\n\t\t\t} else {\r\n\t\t\t\tob_clean();\r\n\r\n\t\t\t\t// Response is in XML Format\r\n\t\t\t\theader('Content-Type: text/xml');\r\n\r\n\t\t\t\t// Output it and update render state\r\n\t\t\t\tif (QApplication::$EncodingType)\r\n\t\t\t\t\tprintf(\"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\"?><response>%s</response>\\r\\n\", QApplication::$EncodingType, $strToReturn);\r\n\t\t\t\telse\r\n\t\t\t\t\tprintf(\"<?xml version=\\\"1.0\\\"?><response>%s</response>\\r\\n\", $strToReturn);\r\n\t\t\t}\r\n\r\n\t\t\t// Update Render State\r\n\t\t\t$this->intFormStatus = QFormBase::FormStatusRenderEnded;\r\n\t\t}", "public function controls()\n {\n }", "function ControlOnLoad() {\n }", "public function init()\n {\n // set class to identify as p4cms-ui component\n $this->setAttrib('class', 'p4cms-ui')\n ->setAttrib('dojoType', 'p4cms.ui.grid.Form');\n\n // turn off CSRF protection - its not useful here (form data are\n // used for filtering the data grid and may be exposed in the URL)\n $this->setCsrfProtection(false);\n\n // call parent to publish the form.\n parent::init();\n }", "function OnBeforeCreateEditControl(){\n }", "protected function buildRenderChildrenClosure() {}", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'section_content',\n [\n 'label' => __('Content', 'elementor-super-cat'),\n ]\n );\n\n\n $this->add_control(\n 'taxonomy',\n [\n 'label' => __('Name of taxonomy to filter', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT2,\n 'label_block' => true,\n 'options' => $this->get_taxonomies(),\n 'default' => isset($this->get_taxonomies()[0]) ? $this->get_taxonomies()[0] : []\n ]\n );\n\n $this->add_control(\n 'post_id',\n [\n 'label' => __('CSS ID of the post widget', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'order_by',\n [\n 'label' => __('Order By', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'name',\n 'options' => [\n 'name' => __('Name', 'elementor-super-cat'),\n 'slug' => __('Slug', 'elementor-super-cat'),\n ],\n ]\n );\n\n $this->add_control(\n 'all_text',\n [\n 'label' => __('Text to show for <b>Show All</b>', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => \"all\"\n ]\n );\n\n $this->add_control(\n 'hide_empty',\n [\n 'label' => __('Hide empty', 'elementor'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('If ON empty filters will be hidden.', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'invisible_filter',\n [\n 'label' => __('Remove Filter and display only currenct taxonomy', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('Removes the filter bar and only display related single related taxonomy', 'elementor'),\n ]\n );\n\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Style', 'elementor-super-cat'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'color_filter',\n [\n 'label' => __('Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'color_filter_active',\n [\n 'label' => __('Active Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter.elementor-active' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n 'typography',\n [\n 'name' => 'typography_filter',\n 'selector' => '{{WRAPPER}} .elementor-portfolio__filter',\n ]\n );\n\n $this->add_control(\n 'filter_item_spacing',\n [\n 'label' => __('Space Between', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter:not(:last-child)' => 'margin-right: calc({{SIZE}}{{UNIT}}/2)',\n '{{WRAPPER}} .elementor-portfolio__filter:not(:first-child)' => 'margin-left: calc({{SIZE}}{{UNIT}}/2)',\n ],\n ]\n );\n\n $this->add_control(\n 'filter_spacing',\n [\n 'label' => __('Spacing', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filters' => 'margin-bottom: {{SIZE}}{{UNIT}}',\n ],\n ]\n );\n\n $this->end_controls_section();\n }", "function AddControl(&$object) {\n if (!is_object($object)) {\n return;\n }\n //if (is_object($object->Parent))\n //$object->Parent->RemoveControl($object);\n $object->Parent = &$this;\n $object->Page = &$this->Page;\n @$this->Controls[$object->Name] = &$object;\n if ($this->_state >= WEB_CONTROL_INITIALIZED) {\n $object->initRecursive();\n if ($this->_state >= WEB_CONTROL_LOADED)\n $object->loadRecursive();\n }\n }", "protected function _register_controls() {\n /*-----------------------------------------------------------------------------------*/\n /* Content TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_section',\n array(\n 'label' => __('APR Heading', 'apr-core' ),\n )\n );\n /* Heading 1*/\n $this->add_control(\n 'title',\n array(\n 'label' => __( 'Title', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' => true\n ),\n 'placeholder' => __( 'Enter your title', 'apr-core' ),\n 'default' => __( 'Enter your title', 'apr-core' ),\n 'label_block' => true,\n )\n );\n $this->add_control(\n 'heading_size',\n array(\n 'label' => __( 'HTML Tag', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => array(\n 'h1' => __( 'H1', 'apr-core' ),\n 'h2' => __( 'H2', 'apr-core' ),\n 'h3' => __( 'H3', 'apr-core' ),\n 'h4' => __( 'H4', 'apr-core' ),\n 'h5' => __( 'H5', 'apr-core' ),\n 'p' => __( 'p', 'apr-core' ),\n ),\n 'default' => 'h3',\n )\n );\n $this->add_control(\n 'link',\n [\n 'label' => __( 'Link', 'elementor' ),\n 'type' => Controls_Manager::URL,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => '',\n ],\n 'separator' => 'before',\n ]\n );\n $this->add_responsive_control(\n 'alignment',\n array(\n 'label' => __('Alignment', 'apr-core'),\n 'type' => Controls_Manager::CHOOSE,\n 'default' => 'left',\n 'options' => array(\n 'left' => array(\n 'title' => __( 'Left', 'apr-core' ),\n 'icon' => 'fa fa-align-left',\n ),\n 'center' => array(\n 'title' => __( 'Center', 'apr-core' ),\n 'icon' => 'fa fa-align-center',\n ),\n 'right' => array(\n 'title' => __( 'Right', 'apr-core' ),\n 'icon' => 'fa fa-align-right',\n )\n ),\n )\n );\n $this->add_control(\n 'description',\n array(\n 'label' => __( 'Description', 'apr-core' ),\n 'type' => Controls_Manager::TEXTAREA,\n 'dynamic' => array(\n 'active' \t=> true\n ),\n )\n );\n $this->add_control(\n 'description_position',\n [\n 'label' => __( 'Description Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'bottom',\n 'options' => [\n 'aside' => __( 'Aside', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' ),\n ],\n ]\n );\n $this->add_control(\n 'list_divider',\n [\n 'label' => __( 'Divider', 'apr-core' ),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'no',\n 'separator' => 'before',\n ]\n );\n\n $this->add_control(\n 'divider_position',\n [\n 'label' => __( 'Position', 'apr-core' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n 'top' => __( 'Top', 'apr-core' ),\n 'bottom' => __( 'Bottom', 'apr-core' )\n ],\n 'default' => 'bottom',\n 'condition' => [\n 'list_divider' => 'yes',\n ]\n ]\n );\n\n $this->add_control(\n 'divider_color',\n [\n 'label' => __( 'Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'divider_color_hover',\n [\n 'label' => __( 'Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'default' => '',\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:hover:before' => 'background-color: {{VALUE}};',\n ],\n ]\n );\n $this->add_responsive_control(\n 'divider_top',\n [\n 'label' => __( 'Top Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'top: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_left',\n [\n 'label' => __( 'Left Space', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => '',\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n ],\n 'size_units' => [ 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'left: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_weight',\n [\n 'label' => __( 'Height', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 1,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'height: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'divider_width',\n [\n 'label' => __( 'Width', 'apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'condition' => [\n 'list_divider' => 'yes',\n ],\n 'default' => [\n 'size' => 100,\n 'unit' => 'px',\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 1000,\n ],\n '%' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'size_units' => [ '%', 'px' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-title:before' => 'width: {{SIZE}}{{UNIT}};',\n ],\n ]\n );\n \n $this->end_controls_section();\n /*-----------------------------------------------------------------------------------*/\n /* Style TAB\n /*-----------------------------------------------------------------------------------*/\n $this->start_controls_section(\n 'title_style_section',\n array(\n 'label' => __( 'Color', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n $this->add_control(\n 'title_color',\n [\n 'label' => __( 'Title Color', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title,\n {{WRAPPER}} .heading-modern .heading-title a' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color',\n [\n 'label' \t=> __( 'Description color', 'apr-core' ),\n 'type' \t\t=> Controls_Manager::COLOR,\n 'scheme' \t=> [\n 'type' \t\t=> Scheme_Color::get_type(),\n 'value' \t=> Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n 'desc_style',\n array(\n 'label' => __( 'Typography', 'apr-core' ),\n 'tab' => Controls_Manager::TAB_STYLE,\n )\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'title_typo',\n 'label' \t=> __( 'Title', 'apr-core' ),\n 'selector' => '{{WRAPPER}} .heading-modern .heading-title',\n ]\n );\n $this->add_responsive_control(\n 'title_width',\n array(\n 'label' => __('Max width Title','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .heading-title' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' \t\t=> 'desc_typo',\n 'label' \t=> __( 'Description', 'apr-core' ),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' \t=> '{{WRAPPER}} .heading-modern .description',\n ]\n );\n $this->add_responsive_control(\n 'desc_width',\n array(\n 'label' => __('Max width Description','apr-core' ),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => array('px','%'),\n 'range' => array(\n '%' => array(\n 'min' => 1,\n 'max' => 100,\n ),\n 'px' => array(\n 'min' => 1,\n 'max' => 1600,\n 'step' => 5\n )\n ),\n 'selectors' => array(\n '{{WRAPPER}} .heading-modern .description' => 'max-width:{{SIZE}}{{UNIT}};'\n ),\n )\n );\n $this->add_responsive_control(\n 'title_margin',\n array(\n 'label' => __( 'Margin Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n\n $this->add_responsive_control(\n 'title_padding',\n [\n 'label' => __( 'Padding Title', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .heading-title' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_responsive_control(\n 'desc_margin',\n array(\n 'label' => __( 'Margin Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', '%' ],\n 'allowed_dimensions' => 'vertical',\n 'placeholder' => [\n 'top' => '',\n 'right' => 'auto',\n 'bottom' => '',\n 'left' => 'auto',\n ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'margin-top: {{TOP}}{{UNIT}}; margin-bottom: {{BOTTOM}}{{UNIT}};',\n ],\n )\n );\n $this->add_responsive_control(\n 'description_padding',\n [\n 'label' => __( 'Padding Description', 'apr-core' ),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .heading-modern .description' => 'padding:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};'\n ],\n ]\n );\n $this->add_control(\n 'title_color_hover',\n [\n 'label' => __( 'Title Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .heading-title:hover,\n {{WRAPPER}} .heading-modern .heading-title a:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->add_control(\n 'desc_color_hover',\n [\n 'label' => __( 'Description Color Hover', 'apr-core' ),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n // Stronger selector to avoid section style from overwriting\n '{{WRAPPER}} .heading-modern .description:hover' => 'color: {{VALUE}};',\n ],\n ]\n );\n $this->end_controls_section();\n }", "protected function _register_controls() {\n \n \t$this->start_controls_section(\n \t\t'section_listing_posts',\n \t\t[\n \t\t\t'label' => __( 'Listing Posts', 'listslides' ),\n \t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n \t\t]\n \t); \n\n \t$this->add_control(\n \t\t'item_per_page',\n \t\t[\n \t\t\t'label' => __( 'Number of Listings', 'listslides' ),\n \t\t\t'type' => Controls_Manager::SELECT,\n \t\t\t'default' => 5,\n \t\t\t'options' => [\n \t\t\t\t2 => __( 'Two', 'listslides' ),\n \t\t\t\t3 => __( 'Three', 'listslides' ),\n \t\t\t\t4 => __( 'Four', 'listslides' ),\n \t\t\t\t5 => __( 'Five', 'listslides')\n \t\t\t]\n \t\t]\n \t);\n\n \t$this->end_controls_section();\n\n \t$this->start_controls_section(\n\t\t\t'slide_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Slides Settings', 'listslides' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'nav',\n\t\t\t[\n\t\t\t\t'label' => __( 'Navigation Arrow', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'dots',\n\t\t\t[\n\t\t\t\t'label' => __( 'Dots', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplay',\n\t\t\t[\n\t\t\t\t'label' => __( 'Auto Play', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\t[\n\t\t\t\t'label' => __( 'Loop', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'mouseDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Mouse Drag', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'touchDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Touch Motion', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplayTimeout',\n\t\t\t[\n\t\t\t\t'label' => __( 'Autoplay Timeout', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '3000',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'autoplay' => 'true',\n\t\t\t\t],\n\t\t\t\t'options' => [\n\t\t\t\t\t'2000' => __( '2 Seconds', 'listslides' ),\n\t\t\t\t\t'3000' => __( '3 Seconds', 'listslides' ),\n\t\t\t\t\t'5000' => __( '5 Seconds', 'listslides' ),\n\t\t\t\t\t'10000' => __( '10 Seconds', 'listslides' ),\n\t\t\t\t\t'15000' => __( '15 Seconds', 'listslides' ),\n\t\t\t\t\t'20000' => __( '20 Seconds', 'listslides' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n }", "public function BuildControls() {\n\n $this->EncType= $this->GetOption('EncType');\n\n // convert array of arrays into array of objects\n foreach($this->Controls as $Name=>&$Control) {\n // skip already builded controls\n if (is_object($Control)) {\n continue;\n }\n // find classname\n if (!isset($Control['Type'])) {\n $Control += array('Type'=>'text', 'Attributes'=>array('UNKNOWNTYPE'=>'YES'));\n }\n if (strpos($Control['Type'], '\\\\') === false) { // short name, ex.: \"select\"\n $Type= ucfirst($Control['Type']);\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\'.$Type.'Control';\n } else { // it is fully qualified class name\n $Class= $Control['Type'];\n }\n if (!class_exists($Class)) {\n $this->Error('Class \"'.$Class.'\" not found.');\n $Class= '\\\\Accent\\\\Form\\\\Control\\\\TextControl'; // fallback to any primitive control\n }\n // copy this array into $Options and append few more items\n // and append common options to allow usage of services\n $Options= $Control + array(\n 'Name'=> $Name,\n 'Form'=> $this,\n 'Book'=> $this->GetOption('Book')\n ) + $this->GetCommonOptions();\n $Control= new $Class($Options);\n // switch to multipart encoding if any control require that\n if ($Control->GetMultipartEncoding()) {\n $this->EncType= 'multipart/form-data';\n }\n }\n $this->Builded= true;\n }", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'Alita-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'Alita-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'Alita-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'Alita-extensions' ),\n 'return_value' => true,\n 'default' => false,\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'Alita-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'Alita-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'Alita-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'Alita-extensions' ),\n 'random' =>esc_html__( 'Random', 'Alita-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'Alita-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'Alita-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "public function render_admin_form_children() {\n\t\tforeach ( array_keys( bp_xprofile_get_field_types() ) as $field_type ) {\n\t\t\t$type_obj = bp_xprofile_create_field_type( $field_type );\n\t\t\t$type_obj->admin_new_field_html( $this );\n\t\t}\n\t}", "protected function onLoad()\n\t\t{\n\t\t\tparent::onLoad();\n\n\t\t\tif( $this->items->count > 0 )\n\t\t\t{\n\t\t\t\t$this->defaultHTMLControlId = $this->getHTMLControlId() . \"__0\";\n\t\t\t}\n\t\t}", "private function _createContainerForms() {\n $forms = [\n [\n 'name' => 'inline',\n 'classname' => 'App\\Models\\Backoffice\\ContainerForms\\Inline'\n ],\n [\n 'name' => 'popup',\n 'classname' => 'App\\Models\\Backoffice\\ContainerForms\\Popup'\n ]\n ];\n\n foreach ($forms as $form) {\n $newForm = new ContainerForm;\n $newForm->fill($form);\n $newForm->save();\n }\n }", "protected function regenerateFormControls()\n\t{\n\t\t$form = $this->getForm();\n\n\t\t// regenerate checker's checkbox controls\n\t\tif ($this->hasOperations()) {\n\t\t\t$values = $form->getValues();\n\n\t\t\t$form->removeComponent($form['checker']);\n\t\t\t$sub = $form->addContainer('checker');\n\t\t\tforeach ($this->getRows() as $row) {\n\t\t\t\t$sub->addCheckbox($row[$this->keyName], $row[$this->keyName]);\n\t\t\t}\n\n\t\t\tif (!empty($values['checker'])) {\n\t\t\t\t$form->setDefaults(array('checker' => $values['checker']));\n\t\t\t}\n\t\t}\n\n\t\t// for selectbox filter controls update values if was filtered over column\n\t\tif ($this->hasFilters()) {\n\t\t\tparse_str($this->filters, $list);\n\n\t\t\tforeach ($this->getFilters() as $filter) {\n\t\t\t\tif ($filter instanceof SelectboxFilter) {\n\t\t\t\t\t$filter->generateItems();\n\t\t\t\t}\n\n\t\t\t\tif ($this->filters === $this->defaultFilters && ($filter->value !== NULL || $filter->value !== '')) {\n\t\t\t\t\tif (!in_array($filter->getName(), array_keys($list))) $filter->value = NULL;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// page input & items selectbox\n\t\t$form['page']->setValue($this->paginator->page); // intentionally page from paginator\n\t\t$form['items']->setValue($this->paginator->itemsPerPage);\n\t}", "public function setupControl()\n\t{\n\t\t$this->addText('referenceNumber', 'Reference number:');\n\t\t$this->addSelect('priority', 'Priority:', PriorityEnum::getOptions());\n\t\t$this->addTextArea('symptoms', 'Symptoms:', 40, 8)\n\t\t\t->addRule(Form::FILLED, 'Symptoms are required.');\n\t\t$this->addText('problemOwner', 'Problem owner:');\n\t\t$this->addSelect('status', 'State:', array(\n\t\t\tOperationProblem::STATUS_NEW => 'new',\n\t\t\tOperationProblem::STATUS_INVESTIGATED => 'investigated',\n\t\t\tOperationProblem::STATUS_RESOLVED => 'resolved',\n\t\t\tOperationProblem::STATUS_CLOSED => 'closed'\n\t\t));\n\n\t\t$this->addSelect('category', 'Category:', array('' => $this->noCategoryText) + $this->getCategoriesOptions());\n\n\t\t$this->addTextArea('onEventRaw', 'onEvent:');\n\n\t\t$this->addSubmit('save', 'Save problem');\n\n\t\t$this->onValidate[] = $this->onValidateForm;\n\t}", "protected function _register_controls() { \n /*Testimonials Content Section */\n $this->start_controls_section('premium_testimonial_person_settings',\n [\n 'label' => __('Author', 'premium-addons-for-elementor'),\n ]\n );\n \n /*Person Image*/\n $this->add_control('premium_testimonial_person_image',\n [\n 'label' => __('Image','premium-addons-for-elementor'),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [ 'active' => true ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src()\n ],\n 'description' => __( 'Choose an image for the author', 'premium-addons-for-elementor' ),\n 'show_label' => true,\n ]\n ); \n\n /*Person Image Shape*/\n $this->add_control('premium_testimonial_person_image_shape',\n [\n 'label' => __('Image Style', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Choose image style', 'premium-addons-for-elementor' ),\n 'options' => [\n 'square' => __('Square','premium-addons-for-elementor'),\n 'circle' => __('Circle','premium-addons-for-elementor'),\n 'rounded' => __('Rounded','premium-addons-for-elementor'),\n ],\n 'default' => 'circle',\n ]\n );\n \n /*Person Name*/ \n $this->add_control('premium_testimonial_person_name',\n [\n 'label' => __('Name', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Person Name', 'premium-addons-for-elementor'),\n 'description' => __( 'Enter author name', 'premium-addons-for-elementor' ),\n 'label_block' => true\n ]\n );\n \n /*Name Title Tag*/\n $this->add_control('premium_testimonial_person_name_size',\n [\n 'label' => __('HTML Tag', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select a heading tag for author name', 'premium-addons-for-elementor' ),\n 'options' => [\n 'h1' => 'H1',\n 'h2' => 'H2',\n 'h3' => 'H3',\n 'h4' => 'H4',\n 'h5' => 'H5',\n 'h6' => 'H6',\n ],\n 'default' => 'h3',\n 'label_block' => true,\n ]\n );\n \n /*End Person Content Section*/\n $this->end_controls_section();\n\n /*Start Company Content Section*/ \n $this->start_controls_section('premium_testimonial_company_settings',\n [\n 'label' => __('Company', 'premium-addons-for-elementor')\n ]\n );\n \n /*Company Name*/\n $this->add_control('premium_testimonial_company_name',\n [\n 'label' => __('Name', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Company Name','premium-addons-for-elementor'),\n 'description' => __( 'Enter company name', 'premium-addons-for-elementor' ),\n 'label_block' => true,\n ]\n );\n \n /*Company Name Tag*/\n $this->add_control('premium_testimonial_company_name_size',\n [\n 'label' => __('HTML Tag', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select a heading tag for company name', 'premium-addons-for-elementor' ),\n 'options' => [\n 'h1' => 'H1',\n 'h2' => 'H2',\n 'h3' => 'H3',\n 'h4' => 'H4',\n 'h5' => 'H5',\n 'h6' => 'H6', \n ],\n 'default' => 'h4',\n 'label_block' => true,\n ]\n );\n \n $this->add_control('premium_testimonial_company_link_switcher',\n [\n 'label' => __('Link', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SWITCHER,\n 'default' => 'yes',\n ]\n );\n \n /*Company Link */\n $this->add_control('premium_testimonial_company_link',\n [\n 'label' => __('Link', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::TEXT,\n 'dynamic' => [\n 'active' => true,\n 'categories' => [\n TagsModule::POST_META_CATEGORY,\n TagsModule::URL_CATEGORY\n ]\n ],\n 'description' => __( 'Add company URL', 'premium-addons-for-elementor' ),\n 'label_block' => true,\n 'condition' => [\n 'premium_testimonial_company_link_switcher' => 'yes'\n ]\n ]\n );\n \n /*Link Target*/ \n $this->add_control('premium_testimonial_link_target',\n [\n 'label' => __('Link Target', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SELECT,\n 'description' => __( 'Select link target', 'premium-addons-for-elementor' ),\n 'options' => [\n 'blank' => __('Blank'),\n 'parent' => __('Parent'),\n 'self' => __('Self'),\n 'top' => __('Top'),\n ],\n 'default' => __('blank','premium-addons-for-elementor'),\n 'condition' => [\n 'premium_testimonial_company_link_switcher' => 'yes'\n ]\n ]\n );\n \n /*End Company Content Section*/\n $this->end_controls_section();\n\n /*Start Testimonial Content Section*/\n $this->start_controls_section('premium_testimonial_settings',\n [\n 'label' => __('Content', 'premium-addons-for-elementor'),\n ]\n );\n\n /*Testimonial Content*/\n $this->add_control('premium_testimonial_content',\n [ \n 'label' => __('Testimonial Content', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'dynamic' => [ 'active' => true ],\n 'default' => __('Donec id elit non mi porta gravida at eget metus. Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor. Cras mattis consectetur purus sit amet fermentum. Nullam id dolor id nibh ultricies vehicula ut id elit. Donec id elit non mi porta gravida at eget metus.','premium-addons-for-elementor'),\n 'label_block' => true,\n ]\n );\n \n /*End Testimonial Content Section*/\n $this->end_controls_section();\n \n /*Image Styling*/\n $this->start_controls_section('premium_testimonial_image_style',\n [\n 'label' => __('Image', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n \n /*Image Size*/\n $this->add_control('premium_testimonial_img_size',\n [\n 'label' => __('Size', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', 'em'],\n 'default' => [\n 'unit' => 'px',\n 'size' => 110,\n ],\n 'range' => [\n 'px'=> [\n 'min' => 10,\n 'max' => 150,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-img-wrapper'=> 'width: {{SIZE}}{{UNIT}}; height:{{SIZE}}{{UNIT}};',\n ]\n ]\n );\n\n /*Image Border Width*/\n $this->add_control('premium_testimonial_img_border_width',\n [\n 'label' => __('Border Width (PX)', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'default' => [\n 'unit' => 'px',\n 'size' => 2,\n ],\n 'range' => [\n 'px'=> [\n 'min' => 0,\n 'max' => 15,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-person-image' => 'border-width: {{SIZE}}{{UNIT}};',\n ]\n ]\n );\n \n /*Image Border Color*/\n $this->add_control('premium_testimonial_image_border_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-img-wrapper' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n $this->end_controls_section();\n \n /*Start Person Settings Section*/\n $this->start_controls_section('premium_testimonials_person_style', \n [\n 'label' => __('Author', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n \n /*Person Name Color*/\n $this->add_control('premium_testimonial_person_name_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-person-name' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Authohr Name Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'author_name_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-person-name',\n ]\n );\n \n /*Separator Color*/\n $this->add_control('premium_testimonial_separator_color',\n [\n 'label' => __('Divider Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_1,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-separator' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n $this->end_controls_section();\n \n /*Start Company Settings Section*/\n $this->start_controls_section('premium_testimonial_company_style',\n [\n 'label' => __('Company', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n\n /*Company Name Color*/\n $this->add_control('premium_testimonial_company_name_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_2,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-company-link' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Company Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'company_name_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-company-link',\n ]\n ); \n\n /*End Color Section*/\n $this->end_controls_section();\n \n /*Start Content Settings Section*/\n $this->start_controls_section('premium_testimonial_content_style',\n [\n 'label' => __('Content', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE, \n ]\n );\n\n /*Content Color*/\n $this->add_control('premium_testimonial_content_color',\n [\n 'label' => __('Color', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'scheme' => [\n 'type' => Scheme_Color::get_type(),\n 'value' => Scheme_Color::COLOR_3,\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-text-wrapper' => 'color: {{VALUE}};',\n ]\n ]\n );\n \n /*Content Typography*/\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'content_typography',\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .premium-testimonial-text-wrapper',\n ]\n ); \n \n \n /*Testimonial Text Margin*/\n $this->add_responsive_control('premium_testimonial_margin',\n [\n 'label' => __('Margin', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'top' => 15,\n 'bottom'=> 15,\n 'left' => 0 ,\n 'right' => 0 ,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-text-wrapper' => 'margin: {{top}}{{UNIT}} {{right}}{{UNIT}} {{bottom}}{{UNIT}} {{left}}{{UNIT}};',\n ]\n ]\n );\n\n /*End Content Settings Section*/\n $this->end_controls_section();\n \n /*Start Quotes Style Section*/\n $this->start_controls_section('premium_testimonial_quotes',\n [\n 'label' => __('Quotation Icon', 'premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n \n /*Quotes Color*/ \n $this->add_control('premium_testimonial_quote_icon_color',\n [\n 'label' => __('Color','premium-addons-for-elementor'),\n 'type' => Controls_Manager::COLOR,\n 'default' => 'rgba(110,193,228,0.2)',\n 'selectors' => [\n '{{WRAPPER}} .fa' => 'color: {{VALUE}};',\n ]\n ]\n );\n\n /*Quotes Size*/\n $this->add_control('premium_testimonial_quotes_size',\n [\n 'label' => __('Size', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', '%', 'em'],\n 'default' => [\n 'unit' => 'px',\n 'size' => 120,\n ],\n 'range' => [\n 'px' => [\n 'min' => 5,\n 'max' => 250,\n ]\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-upper-quote, {{WRAPPER}} .premium-testimonial-lower-quote' => 'font-size: {{SIZE}}{{UNIT}};',\n ]\n ]\n );\n \n /*Upper Quote Position*/\n $this->add_responsive_control('premium_testimonial_upper_quote_position',\n [\n 'label' => __('Top Icon Position', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'top' => 70,\n 'left' => 12 ,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-upper-quote' => 'top: {{TOP}}{{UNIT}}; left:{{LEFT}}{{UNIT}};',\n ]\n ]\n );\n \n /*Lower Quote Position*/\n $this->add_responsive_control('premium_testimonial_lower_quote_position',\n [\n 'label' => __('Bottom Icon Position', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'default' =>[\n 'bottom' => 3,\n 'right' => 12,\n 'unit' => 'px',\n ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-lower-quote' => 'right: {{RIGHT}}{{UNIT}}; bottom: {{BOTTOM}}{{UNIT}};',\n ]\n ]\n );\n\n /*End Typography Section*/\n $this->end_controls_section();\n \n $this->start_controls_section('premium_testimonial_container_style',\n [\n 'label' => __('Container','premium-addons-for-elementor'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n \n $this->add_group_control(\n Group_Control_Background::get_type(),\n [\n 'name' => 'premium_testimonial_background',\n 'types' => [ 'classic' , 'gradient' ],\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper'\n ]\n );\n \n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'premium_testimonial_container_border',\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper',\n ]\n );\n\n $this->add_control('premium_testimonial_container_border_radius',\n [\n 'label' => __('Border Radius', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::SLIDER,\n 'size_units' => ['px', '%', 'em'],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-content-wrapper' => 'border-radius: {{SIZE}}{{UNIT}}'\n ]\n ]\n );\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'premium_testimonial_container_box_shadow',\n 'selector' => '{{WRAPPER}} .premium-testimonial-content-wrapper',\n ]\n );\n \n $this->add_responsive_control('premium_testimonial_box_padding',\n [\n 'label' => __('Padding', 'premium-addons-for-elementor'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => [ 'px', 'em', '%' ],\n 'selectors' => [\n '{{WRAPPER}} .premium-testimonial-content-wrapper' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}}',\n ]\n ]\n );\n\n $this->end_controls_section();\n \n }", "public function init()\n {\n // Top-level parent\n parent::init();\n $this->applyOmekaStyles();\n $this->setAutoApplyOmekaStyles(false);\n $this->setAttrib('id', 'new_collection');\n $this->setAttrib('method', 'POST');\n // Target collection\n $this->addElement('text', 'name', array(\n 'label' => __(\"Collection Name\"),\n 'description' => __(\"Name of the new collection to import into.\"),\n 'required' => true,\n ));\n }", "protected function _register_controls()\r\n {\r\n\r\n\r\n $this->start_controls_section(\r\n 'slider_settings_section',\r\n [\r\n 'label' => esc_html__('Query Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_CONTENT,\r\n ]\r\n );\r\n $this->add_control(\r\n 'column',\r\n [\r\n 'label' => esc_html__('Column', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n '3' => esc_html__('04 Column', 'aapside-master'),\r\n '4' => esc_html__('03 Column', 'aapside-master'),\r\n '2' => esc_html__('06 Column', 'aapside-master')\r\n ),\r\n 'label_block' => true,\r\n 'description' => esc_html__('select grid column', 'aapside-master'),\r\n 'default' => '4'\r\n ]\r\n );\r\n $this->add_control(\r\n 'total',\r\n [\r\n 'label' => esc_html__('Total Post', 'aapside-master'),\r\n 'type' => Controls_Manager::TEXT,\r\n 'description' => esc_html__('enter how many post you want to show, enter -1 for unlimited', 'aapside-master'),\r\n 'default' => '-1'\r\n ]\r\n );\r\n $this->add_control(\r\n 'category',\r\n [\r\n 'label' => esc_html__('Category', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT2,\r\n 'multiple' => true,\r\n 'label_block' => true,\r\n 'description' => esc_html__('select category, for all category leave it blank', 'aapside-master'),\r\n 'options' => appside_master()->get_terms_names('portfolio-cat', 'id', true)\r\n ]\r\n );\r\n $this->add_control(\r\n 'orderby',\r\n [\r\n 'label' => esc_html__('Order By', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ID' => esc_html__('ID', 'aapside-master'),\r\n 'title' => esc_html__('Title', 'aapside-master'),\r\n 'date' => esc_html__('Date', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order by', 'aapside-master'),\r\n 'default' => 'ID'\r\n ]\r\n );\r\n $this->add_control(\r\n 'order',\r\n [\r\n 'label' => esc_html__('Order', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ASC' => esc_html__('Ascending', 'aapside-master'),\r\n 'DESC' => esc_html__('Descending', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order.', 'aapside-master'),\r\n 'default' => 'ASC'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination',\r\n [\r\n 'label' => esc_html__('Pagination', 'aapside-master'),\r\n 'type' => Controls_Manager::SWITCHER,\r\n 'description' => esc_html__('you can set yes to show pagination.', 'aapside-master'),\r\n 'default' => 'yes'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination_alignment',\r\n [\r\n 'label' => esc_html__('Pagination Alignment', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'left' => esc_html__('Left Align', 'aapside-master'),\r\n 'center' => esc_html__('Center Align', 'aapside-master'),\r\n 'right' => esc_html__('Right Align', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('you can set pagination alignment.', 'aapside-master'),\r\n 'default' => 'left',\r\n 'condition' => array('pagination' => 'yes')\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n $this->start_controls_section(\r\n 'thumbnail_settings_section',\r\n [\r\n 'label' => esc_html__('Thumbnail Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_control('thumb_border_radius', [\r\n 'label' => esc_html__('Border Radius', 'aapside-master'),\r\n 'type' => Controls_Manager::DIMENSIONS,\r\n 'size_units' => ['px', '%', 'em'],\r\n 'selectors' => [\r\n \"{{WRAPPER}} .hard-single-item-02 .thumb img\" => \"border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n ]\r\n ]);\r\n $this->add_control(\r\n 'thumbnail_bottom_gap',\r\n [\r\n 'label' => esc_html__('Thumbnail Bottom Gap', 'aapside-master'),\r\n 'type' => Controls_Manager::SLIDER,\r\n 'size_units' => ['px', '%'],\r\n 'range' => [\r\n 'px' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n 'step' => 1,\r\n ],\r\n '%' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n ],\r\n ],\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .thumb' => 'margin-bottom: {{SIZE}}{{UNIT}};',\r\n ],\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n\r\n /* title styling tabs start */\r\n $this->start_controls_section(\r\n 'title_settings_section',\r\n [\r\n 'label' => esc_html__('Title Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->start_controls_tabs(\r\n 'style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('title_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('title_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n\r\n /* title styling tabs end */\r\n\r\n /* readmore styling tabs start */\r\n $this->start_controls_section(\r\n 'readmore_settings_section',\r\n [\r\n 'label' => esc_html__('Category Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'readmore_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* readmore styling tabs end */\r\n\r\n /* pagination styling tabs start */\r\n $this->start_controls_section(\r\n 'pagination_settings_section',\r\n [\r\n 'label' => esc_html__('Pagination Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'pagination_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('pagination_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination` ul li a\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a, {{WRAPPER}} .portfolio-pagination ul li span\"\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('pagination_hover_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_hover_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a:hover, {{WRAPPER}} .Portfolio-pagination ul li span.current\"\r\n ]);\r\n\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* pagination styling tabs end */\r\n\r\n /* Typography tabs start */\r\n $this->start_controls_section(\r\n 'typography_settings_section',\r\n [\r\n 'label' => esc_html__('Typography Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'title_typography',\r\n 'label' => esc_html__('Title Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .title\"\r\n ]);\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'post_meta_typography',\r\n 'label' => esc_html__('Category Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .cats\"\r\n ]);\r\n $this->end_controls_section();\r\n\r\n /* Typography tabs end */\r\n }", "function Control_Render(&$Owner)\r\n\t{\r\n\t\t$parent = $Owner->OriginalNode->ParentNode();\r\n\t\t\r\n\t\t//insert this node before the parent \r\n\t\t$parent->InsertBefore($this->OriginalNode, $Owner->OriginalNode);\r\n\t\r\n\t\r\n\t\t//call parent render with ourselves as the owner\r\n\t\t$result = parent::Control_Render($this);\r\n\t\t\r\n\t\tif (!$result)\r\n\t\t{\r\n\t\t\treturn false;\t\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t//NOTE: this control allows the use of [= ] inline blocks\r\n\t\tParser::ParseInlineBlocks($this, $this->OriginalNode);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//get all items within the copy\r\n\t\t$holder_items = $this->OriginalNode->GetElementsByTagName(PCNODE_ITEM);\r\n\t\t\r\n\t\t//NOTE:: this relative query doesn't work properly in PHP4\r\n\t\t//$holder_items = $ctx->xpath_eval(\"//\".PCNODE_ITEM.\"[@repeater='\".$this->ID.\"']\", $holder);\r\n\t\t\r\n\t\t\r\n\t\t//replace each item with it's value\r\n\t\tfor ($i = 0; $i < count($holder_items); $i++)\r\n\t\t{\r\n\t\t\t$clone_item = $holder_items[$i];\r\n\t\t\t\r\n\t\t\t//ensure Item has repeater attribute\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") == \"\")\r\n\t\t\t{\r\n\t\t\t\ttrigger_error(\"An item has been found within a repeater (id: \".$Owner->ID.\" ) without a valid repeater attribute.\",E_USER_ERROR);\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//goto next item if this one isn't for this repeater\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") != $Owner->ID)\r\n\t\t\t{\r\n\t\t\t\tcontinue;\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//create a new repeater item\r\n\t\t\t$item = new RepeaterItem($clone_item);\r\n\t\t\t\r\n\t\t\t//get the datafield for this item\r\n\t\t\t$datafield = $item->GetDatafield();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$item->SetData($this->DataRow->Get($datafield));\r\n\t\t\t\r\n\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t}", "protected function _register_controls()\n {\n\n /**\n * Style tab\n */\n\n $this->start_controls_section(\n 'general',\n [\n 'label' => __('Content', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n\t\t\t'menu_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Border Style', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'inline',\n\t\t\t\t'options' => [\n\t\t\t\t\t'inline' => __( 'Inline', 'akash-hp' ),\n\t\t\t\t\t'flyout' => __( 'Flyout', 'akash-hp' ),\n\t\t\t\t],\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_label',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Label', 'akash-hp' ),\n 'type' => Controls_Manager::TEXT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_open_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'fa fa-align-justify',\n\t\t\t\t\t'library' => 'solid',\n ],\n \n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'trigger_close_icon',\n\t\t\t[\n\t\t\t\t'label' => __( 'Trigger Close Icon', 'text-domain' ),\n\t\t\t\t'type' => Controls_Manager::ICONS,\n\t\t\t\t'default' => [\n\t\t\t\t\t'value' => 'far fa-window-close',\n\t\t\t\t\t'library' => 'solid',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'menu_align',\n [\n 'label' => __('Align', 'akash-hp'),\n 'type' => Controls_Manager::CHOOSE,\n 'options' => [\n 'start' => [\n 'title' => __('Left', 'akash-hp'),\n 'icon' => 'fa fa-align-left',\n ],\n 'center' => [\n 'title' => __('top', 'akash-hp'),\n 'icon' => 'fa fa-align-center',\n ],\n 'flex-end' => [\n 'title' => __('Right', 'akash-hp'),\n 'icon' => 'fa fa-align-right',\n ],\n ],\n 'default' => 'left',\n\t\t\t\t'toggle' => true,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .akash-main-menu-wrap.navbar' => 'justify-content: {{VALUE}}'\n\t\t\t\t\t] \n ]\n );\n $this->end_controls_section();\n $this->start_controls_section(\n\t\t\t'header_infos_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Header Info', 'akash-hp' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n );\n \n $this->add_control(\n\t\t\t'show_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'akash-hp' ),\n\t\t\t\t'label_off' => __( 'Hide', 'akash-hp' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'no',\n\t\t\t]\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'info_title', [\n\t\t\t\t'label' => __( 'Title', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'info Title' , 'akash-hp' ),\n\t\t\t\t'label_block' => true,\n\t\t\t]\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'info_content', [\n\t\t\t\t'label' => __( 'Content', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t'default' => __( 'info Content' , 'akash-hp' ),\n\t\t\t\t'show_label' => false,\n\t\t\t]\n );\n \n $repeater->add_control(\n\t\t\t'info_url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'akash-hp' ),\n\t\t\t\t'show_external' => true,\n\t\t\t]\n );\n \n\t\t$this->add_control(\n\t\t\t'header_infos',\n\t\t\t[\n\t\t\t\t'label' => __( 'Repeater info', 'akash-hp' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'info_title' => __( 'Call us:', 'akash-hp' ),\n\t\t\t\t\t\t'info_content' => __( '(234) 567 8901', 'akash-hp' ),\n\t\t\t\t\t],\n\t\t\t\t],\n 'title_field' => '{{{ info_title }}}',\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n\t\t\t]\n\t\t);\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_menu_style',\n [\n 'label' => __('Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'menu_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'menu_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n \n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n \n $this->add_responsive_control(\n 'item_gap',\n [\n 'label' => __('Menu Gap', 'akash-hp'),\n 'type' => Controls_Manager::SLIDER,\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'devices' => ['desktop', 'tablet', 'mobile'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-left: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'margin-right: {{SIZE}}{{UNIT}};margin-right: {{SIZE}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'item_readius',\n [\n 'label' => __('Item Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li>a' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'menu_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav>li:hover>a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'dropdown_style',\n [\n 'label' => __('Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'menu_style' => 'inline',\n ]\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'dripdown_typography',\n 'label' => __('Menu Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n \n $this->add_control(\n 'dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'ddown_menu_border_color',\n [\n 'label' => __('Menu Border Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_radius',\n [\n 'label' => __('Menu radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-inline.navbar:not(.active) .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-inline .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_flyout_style',\n [\n 'label' => __('Flyout/Mobile Menu Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_items_tabs'\n );\n \n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_menu_typography',\n 'label' => __('Item Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a',\n ]\n );\n\n $this->add_control(\n 'flyout_menu_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a, \n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n $this->add_responsive_control(\n 'flyout_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px) {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n \n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>.menu-item-has-children>a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} calc({{RIGHT}}{{UNIT}} + 20px);',\n ],\n\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_menu_padding',\n [\n 'label' => __('Menu Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n \n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_menu_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_menu_hover_color',\n [\n 'label' => __('Menu Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav>li>a:hover, \n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav > .menu-item-has-children > a:hover .dropdownToggle,\n {{WRAPPER}} .menu-style-flyout .menu-style-flyout .main-navigation ul.navbar-nav li.current-menu-item>a' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n\n\t\t$this->end_controls_tab();\n\n $this->end_controls_tabs();\n \n $this->end_controls_section();\n\n $this->start_controls_section(\n 'flyout_dropdown_style',\n [\n 'label' => __('Flyout/Mobile Dropdown Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\t\t$this->start_controls_tabs(\n\t\t\t'flyout_dropdown_items_tabs'\n\t\t);\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Normal', 'akash-hp' ),\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'flyout_dripdown_typography',\n 'label' => __('Dropdown Typography', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav>li .sub-menu a',\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_color',\n [\n 'label' => __('Item Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children > a .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'flyout_dropdown_item_padding',\n [\n 'label' => __('Item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n 'body:not(.rtl) {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n\n ]\n );\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'flyout_dropdown_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => __( 'Hover', 'akash-hp' ),\n\t\t\t]\n\t\t);\n\n $this->add_control(\n 'flyout_dropdown_item_hover_color',\n [\n 'label' => __('Item Hover Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover,\n {{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .sub-menu .menu-item-has-children > a:hover .dropdownToggle' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'flyout_dropdown_item_bg_hover_color',\n [\n 'label' => __('Item Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .main-navigation ul.navbar-nav .menu-item-has-children .sub-menu a:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n\t\t$this->end_controls_tab();\n $this->end_controls_tabs();\n\n $this->end_controls_section();\n\n\n $this->start_controls_section(\n 'trigger_style',\n [\n 'label' => __('Trigger Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n\n $this->start_controls_tabs(\n 'trigger_style_tabs'\n );\n \n $this->start_controls_tab(\n 'trigger_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n \n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'trigger_typography',\n 'label' => __('Trigger Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n 'trigger_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu',\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'trigger_icon_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Icon Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .navbar-toggler.open-menu .navbar-toggler-icon' => 'margin-right: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'trigger_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_padding',\n [\n 'label' => __('Button Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'trigger_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n\n $this->add_control(\n 'trigger_hover_color',\n [\n 'label' => __('Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'trigger_hover_background',\n [\n 'label' => __('Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'trigger_hover_border',\n 'label' => __('Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-toggler.open-menu:hover',\n ]\n );\n\n $this->add_control(\n 'trigger_hover_animation',\n [\n 'label' => __('Hover Animation', 'akash-hp'),\n 'type' => Controls_Manager::HOVER_ANIMATION,\n ]\n );\n\n $this->add_responsive_control(\n 'trigger_hover_radius',\n [\n 'label' => __('Border Radius', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.open-menu:hover' => 'border-radius: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}}\n ;',\n ],\n ]\n );\n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n \n $this->start_controls_section(\n 'infos_style_section',\n [\n 'label' => __('Info Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n 'condition' => [\n 'show_infos' => 'yes',\n ]\n ]\n );\n\n $this->start_controls_tabs(\n 'info_style_tabs'\n );\n \n $this->start_controls_tab(\n 'info_style_normal_tab',\n [\n 'label' => __('Normal', 'akash-hp'),\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_title_typography',\n 'label' => __('Title Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info span',\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'info_typography',\n 'label' => __('Info Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .header-info h3 ',\n ]\n );\n\n $this->add_control(\n 'info_title_color',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_group_control(\n Group_Control_Border::get_type(),\n [\n 'name' => 'info_box_border',\n 'label' => __('Box Border', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .akash-header-infos',\n ]\n );\n\n $this->add_control(\n\t\t\t'info_title_gap',\n\t\t\t[\n\t\t\t\t'label' => __( 'Info Title Gap', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .header-info span' => 'margin-bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n 'ifno_item_padding',\n [\n 'label' => __('Info item Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\n 'body.rtl {{WRAPPER}} .header-info' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n $this->end_controls_tab();\n\n $this->start_controls_tab(\n 'info_style_hover_tab',\n [\n 'label' => __('Hover', 'akash-hp'),\n ]\n );\n \n $this->add_control(\n 'info_title_color_hover',\n [\n 'label' => __('Info Title Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover span' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'info_color_hover',\n [\n 'label' => __('Info Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .header-info:hover h3' => 'color: {{VALUE}}',\n ],\n ]\n );\n \n \n $this->end_controls_tab();\n \n $this->end_controls_tabs();\n\n $this->end_controls_section();\n $this->start_controls_section(\n 'panel_style',\n [\n 'label' => __('Panel Style', 'akash-hp'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_group_control(\n Group_Control_Typography::get_type(),\n [\n 'name' => 'panel_label_typography',\n 'label' => __('Label Typography', 'akash-hp'),\n 'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler',\n ]\n );\n\n \n $this->add_control(\n 'panel_label_color',\n [\n 'label' => __('Label Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_color',\n [\n 'label' => __('Close Trigger Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler i' => 'color: {{VALUE}}',\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'stroke: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_trigger_fill_color',\n [\n 'label' => __('Close Trigger Fill Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner .navbar-toggler svg path' => 'fill: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'close_label_background',\n [\n 'label' => __('Label Background Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .navbar-toggler.close-menu' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n \n $this->add_control(\n 'panel_background',\n [\n 'label' => __('Panel Color', 'akash-hp'),\n 'type' => Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'background-color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n\t\t\t'trigger_cloxe_icon_size',\n\t\t\t[\n\t\t\t\t'label' => __( 'Close Icon size', 'plugin-domain' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t\t'{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu .navbar-toggler-icon i' => 'font-size: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n \n $this->add_group_control(\n Group_Control_Box_Shadow::get_type(),\n [\n 'name' => 'panel_shadow',\n 'label' => __('Panel Shadow', 'akash-hp'),\n 'selector' => '{{WRAPPER}} .navbar-inner',\n ]\n );\n\n $this->add_responsive_control(\n 'close_label_padding',\n [\n 'label' => __('Label Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .navbar-toggler.close-menu' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n \n $this->add_responsive_control(\n 'panel_padding',\n [\n 'label' => __('Panel Padding', 'akash-hp'),\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units' => ['px', 'em', '%'],\n 'selectors' => [\n '{{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n 'body.rtl {{WRAPPER}} .menu-style-flyout .navbar-inner' => 'padding: {{TOP}}{{UNIT}} {{LEFT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{RIGHT}}{{UNIT}};',\n ],\n ]\n );\n\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Number' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Counter Title\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => esc_html__( 'Enter Counter Title' , 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Box', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Background Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_background',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Background-Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#f7f7f7',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'background: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Box Border\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_box_border',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#eee',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box' => 'border: 8px solid {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Number', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Counter Number Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_number_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Number Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h3' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Number Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_number_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h3',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Counter Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_counter_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#232332',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .counter-box h6' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Counter Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_counter_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .counter-box h6',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "protected function _handle_forms()\n\t{\n\t\tif (!strlen($this->_form_posted)) return;\n\t\t$method = 'on_'.$this->_form_posted.'_submit';\n\n\t\tif (method_exists($this, $method))\n\t\t{\n\t\t\tcall_user_func(array($this, $method), $this->_form_action);\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ($this->controls as $k=>$v)\n\t\t{\n\t\t\t$ctl = $this->controls[$k];\n\n\t\t\tif (method_exists($ctl, $method))\n\t\t\t{\n\t\t\t\t$ctl->page = $this;\n\t\t\t\tcall_user_func(array($ctl, $method), $this->_form_action);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\tif (DEBUG) dwrite(\"Method '$method' not defined\");\n\t}", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title\n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title \n\t\t$this->add_control(\n\t\t 'portfolio_section_heading_sub_title',\n\t\t\t[\n\t\t\t 'label' => esc_html__('Section Heading Sub Title','portfolio-elementor'),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'placeholder' => esc_html__('Enter Section Heading Sub Title','portfolio-elementor'),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t// end of the Content tab section\n\t\t\n\t\t// start of the Style tab section\n\t\t$this->start_controls_section(\n\t\t\t'style_section',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Content Style', 'portfolio-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\t\t\n\t\t// start everything related to Normal state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Normal', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#dee3e4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title h2' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title h2',\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Options\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_options',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Section Heading Sub Title', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n\t\t// Section Heading Sub Title Color\n\t\t$this->add_control(\n\t\t\t'portfolio_section_heading_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Sub Title Color', 'portfolio-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'default' => '#343a40',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .section-title p' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t// Section Heading Sub Title Typography\n\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'portfolio_section_heading_sub_title_typography',\n\t\t\t\t'label' => esc_html__( 'Typography', 'portfolio-elementor' ),\n\t\t\t\t'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .section-title p',\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Normal state here\n\n\t\t// start everything related to Hover state here\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Hover', 'portfolio-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_tab();\n\t\t// end everything related to Hover state here\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\t\t// end of the Style tab section\n\n\t}", "function ControlOnInit() {\n }", "public function beforeRender()\n {\n $controller = $this->_registry->getController();\n\n $this->addToController($controller);\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'Subtitle',\n\t\t\t[\n\t\t\t\t'label' => __( 'SubTitle', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'gallery',\n\t\t\t[\n\t\t\t\t'label' => __( 'Add Images', 'plugin-domain' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::GALLERY,\n\t\t\t\t'default' => [],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style', 'elementor-hello-world' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t]\n\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'content_typography',\n\t\t\t\t'label' => __( 'Typography', 'elementor-hello-world' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .title',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t\n\t\t$this->add_control(\n\t\t\t'width',\n\t\t\t[\n\t\t\t\t'label' => __( 'Width', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => [ 'px', '%' ],\n\t\t\t\t'range' => [\n\t\t\t\t\t'px' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 5,\n\t\t\t\t\t],\n\t\t\t\t\t'%' => [\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'default' => [\n\t\t\t\t\t'unit' => '%',\n\t\t\t\t\t'size' => 50,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .box' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'show_title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'elementor-hello-world' ),\n\t\t\t\t'label_off' => __( 'Hide', 'elementor-hello-world' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t\n\t\n\t\t\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t$this->start_controls_section(\n\t\t\t'section_advanced',\n\t\t\t[\n\t\t\t\t'label' => __( 'Opacity Change', 'elementor-hello-world' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_ADVANCED,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'title_color1', \n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'scheme' => [\n\t\t\t\t\t'type' => \\Elementor\\Scheme_Color::get_type(),\n\t\t\t\t\t'value' => \\Elementor\\Scheme_Color::COLOR_1,\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'transparent',\n\t\t\t[\n\t\t\t\t'label' => __( 'Enable', 'elementor-hello-world' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'On', 'elementor-hello-world' ),\n\t\t\t\t'label_off' => __( 'Off', 'elementor-hello-world' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t\t'frontend_available' => true,\n\t\t\t\t'prefix_class' => 'opacity-siva-border-',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .title2' => 'color: {{VALUE}}',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t\n\t\t$this->end_controls_section();\n\t}", "protected function _register_controls() {\n\n\t\t\t\t$this->start_controls_section(\n\t\t\t\t\t'section_sc_booked',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'ThemeREX Booked Calendar', 'trx_addons' ),\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'style',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Layout', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => [\n\t\t\t\t\t\t\t\t\t'calendar' => esc_html__('Calendar', 'trx_addons'),\n\t\t\t\t\t\t\t\t\t'list' => esc_html__('List', 'trx_addons')\n\t\t\t\t\t\t\t\t\t],\n\t\t\t\t\t\t'default' => 'calendar'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'calendar',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Calendar', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Select calendar -', 'trx_addons')), trx_addons_get_list_terms(false, 'booked_custom_calendars')),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'month',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Month', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current month -', 'trx_addons')), trx_addons_get_list_months()),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\n\t\t\t\t$this->add_control(\n\t\t\t\t\t'year',\n\t\t\t\t\t[\n\t\t\t\t\t\t'label' => __( 'Year', 'trx_addons' ),\n\t\t\t\t\t\t'label_block' => false,\n\t\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t\t\t'options' => trx_addons_array_merge(array(0 => esc_html__('- Current year -', 'trx_addons')), trx_addons_get_list_range(date('Y'), date('Y')+25)),\n\t\t\t\t\t\t'default' => '0'\n\t\t\t\t\t]\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\t$this->end_controls_section();\n\t\t\t}", "public function beginChildren()\n {\n parent::beginChildren();\n\n $this->call($this->descendCallback);\n }", "protected function _register_controls() {\n\t\t$this->query_controls();\n\t\t$this->layout_controls();\n\n $this->start_controls_section(\n 'eael_section_post_block_style',\n [\n 'label' => __( 'Post Block Style', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\n $this->add_control(\n\t\t\t'eael_post_block_bg_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Post Background Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#fff',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\n $this->add_control(\n\t\t\t'eael_thumbnail_overlay_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Thumbnail Overlay Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => 'rgba(0,0,0, .5)',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-overlay, {{WRAPPER}} .eael-post-block.post-block-style-overlay .eael-entry-wrapper' => 'background-color: {{VALUE}}',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_spacing',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Spacing Between Items', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'size_units' => [ 'px', '%', 'em' ],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'margin: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_border',\n\t\t\t\t'label' => esc_html__( 'Border', 'essential-addons-elementor' ),\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_border_radius',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Border Radius', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::DIMENSIONS,\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-post-block-item' => 'border-radius: {{TOP}}px {{RIGHT}}px {{BOTTOM}}px {{LEFT}}px;',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_box_shadow',\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-post-block-item',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n $this->start_controls_section(\n 'eael_section_typography',\n [\n 'label' => __( 'Color & Typography', 'essential-addons-elementor' ),\n 'tab' => Controls_Manager::TAB_STYLE\n ]\n );\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_title_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#303133',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title, {{WRAPPER}} .eael-entry-title a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_title_hover_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Hover Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '#23527c',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title:hover, {{WRAPPER}} .eael-entry-title a:hover' => 'color: {{VALUE}};',\n\t\t\t\t]\n\n\t\t\t]\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'eael_post_block_title_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-title' => 'text-align: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_title_typography',\n\t\t\t\t'label' => __( 'Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_1,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-title',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_excerpt_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_excerpt_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_excerpt_alignment',\n\t\t\t[\n\t\t\t\t'label' => __( 'Excerpt Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-grid-post-excerpt p' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_excerpt_typography',\n\t\t\t\t'label' => __( 'Excerpt Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-grid-post-excerpt p',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'eael_post_block_meta_style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Style', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t]\n\t\t);\n\n $this->add_control(\n\t\t\t'eael_post_block_meta_color',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default'=> '',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta, .eael-entry-meta a' => 'color: {{VALUE}};',\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_footer',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'flex-start' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'flex-end' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'stretch' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-footer' => 'justify-content: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-footer',\n ]\n\t\t\t]\n\t\t);\n\n $this->add_responsive_control(\n\t\t\t'eael_post_block_meta_alignment_header',\n\t\t\t[\n\t\t\t\t'label' => __( 'Meta Alignment', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::CHOOSE,\n\t\t\t\t'options' => [\n\t\t\t\t\t'left' => [\n\t\t\t\t\t\t'title' => __( 'Left', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-left',\n\t\t\t\t\t],\n\t\t\t\t\t'center' => [\n\t\t\t\t\t\t'title' => __( 'Center', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-center',\n\t\t\t\t\t],\n\t\t\t\t\t'right' => [\n\t\t\t\t\t\t'title' => __( 'Right', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-right',\n\t\t\t\t\t],\n\t\t\t\t\t'justify' => [\n\t\t\t\t\t\t'title' => __( 'Justified', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'icon' => 'fa fa-align-justify',\n\t\t\t\t\t],\n\t\t\t\t],\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .eael-entry-meta' => 'text-align: {{VALUE}};',\n\t\t\t\t],\n 'condition' => [\n 'meta_position' => 'meta-entry-header',\n ]\n\t\t\t]\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Typography::get_type(),\n\t\t\t[\n\t\t\t\t'name' => 'eael_post_block_meta_typography',\n\t\t\t\t'label' => __( 'Meta Typography', 'essential-addons-elementor' ),\n\t\t\t\t'scheme' => Scheme_Typography::TYPOGRAPHY_3,\n\t\t\t\t'selector' => '{{WRAPPER}} .eael-entry-meta > div, {{WRAPPER}} .eael-entry-meta > span',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Load More Button Style Controls!\n\t\t */\n\t\t$this->load_more_button_style();\n\n\t}", "protected function _register_controls()\n\t{\n\t\t$this->start_controls_section(\n\t\t\t'section_custom_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice', 'elementor'),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'custom_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice', 'webt'),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t'placeholder' => esc_html('A custom notice to any page on your site'),\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'custom_type_notice',\n\t\t\t[\n\t\t\t\t'label' => esc_html__('Custom Notice Type', 'webt'),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'solid',\n\t\t\t\t'options' => [\n\t\t\t\t\t'success' => __('Success', 'webt'),\n\t\t\t\t\t'error' => __('Error', 'webt'),\n\t\t\t\t\t'notice' => __('Notice', 'webt'),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t$this->add_control(\n\t\t\t'wc_custom_notice_warning',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::RAW_HTML,\n\t\t\t\t'raw' => esc_html__('Add a custom notice to any page on your site', 'webt'),\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',\n\t\t\t]\n\t\t);\n\t\t$this->end_controls_section();\n\t}", "public function buildForm()\n {\n $this\n ->addMeasureList()\n ->addAscendingList()\n ->addTitles(['class' => 'indicator_title_title_narrative', 'narrative_true' => true])\n ->addDescriptions(['class' => 'indicator_description_title_narrative'])\n ->addCollection('reference', 'Activity\\Reference', 'reference', [], trans('elementForm.reference'))\n ->addAddMoreButton('add_reference', 'reference')\n ->addBaselines()\n ->addPeriods()\n ->addAddMoreButton('add_period', 'period')\n ->addRemoveThisButton('remove_indicator');\n }", "public function init(){\n\t\t//Additional information.\n\t\t$this->addElement('textarea', 'additional_information', array(\n\t\t\t\t'label' => 'Additional information',\n\t\t\t\t'required' => false,\n\t\t\t\t'filters' => array('StringTrim'),\n\t\t\t\t'validators' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'NotEmpty', true, array(\n\t\t\t\t\t\t\t\t\t\t'messages' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'isEmpty' => 'Please enter additional information',\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t));\n\n\t\t// Add declaration statement agree element\n\t\t$this->addElement('checkbox', 'confirmation_statement', array(\n\t\t\t\t'label' => '',\n\t\t\t\t'required' => true,\n\t\t\t\t'checkedValue' => '1',\n\t\t\t\t'uncheckedValue' => null, // Must be used to override default of '0' and force an error when left unchecked\n\t\t\t\t'validators' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'NotEmpty', true, array(\n\t\t\t\t\t\t\t\t\t\t'messages' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'isEmpty' => 'You must agree to confirmation statement to continue'\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t));\n\n\t\t// Set custom subform decorator\n\t\t$this->setDecorators(array(\n\t\t\t\tarray('ViewScript', array('viewScript' => 'insurance/subforms/quote-my-additionaldetail.phtml'))\n\t\t));\n\n\t\t// Strip all tags to prevent XSS errors\n\t\t$this->setElementFilters(array('StripTags'));\n\n\n\t\t$this->setElementDecorators(array(\n\t\t\t\tarray('ViewHelper', array('escape' => false)),\n\t\t\t\tarray('Label', array('escape' => false))\n\t\t));\n\t}", "public function createPresenters()\n {\n parent::createPresenters();\n\n $this->addPresenters(\n new TextBox( 'username' ),\n new Password( 'password' )\n );\n\n foreach( $this->presenters as $presenter )\n {\n if( $presenter instanceof TextBox )\n {\n $presenter->addCssClassName( 'form-control' );\n }\n }\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__( 'Style', 'woocommerce-builder-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'wc_style_warning',\n\t\t\t[\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::RAW_HTML,\n\t\t\t\t'raw' => esc_html__( 'This is the preview mode of the builder, this widget may not show properly you should view the result in the Product Page and The style of this widget is often affected by your theme and plugins. If you experience any such issue, try to switch to a basic theme and deactivate related plugins.', 'woocommerce-builder-elementor' ),\n\t\t\t\t'content_classes' => 'elementor-panel-alert elementor-panel-alert-info',\n\t\t\t]\n\t\t);\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "public function onAddField()\n {\n return $this->makePartial('create_field_form');\n }", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "public function render()\n {\n foreach ($this->controls as $uniqueID => $ctrl)\n {\n foreach ($ctrl->getEvents() as $eid => $event)\n {\n if ($event === false) $this->addJS([], '$pom.get(\\'' . $uniqueID . '\\').unbind(\\'' . $eid . '\\')', false);\n else $this->addJS([], '$pom.get(\\'' . $uniqueID . '\\').bind(\\'' . $eid . '\\', \\'' . $event['type'] . '\\', ' . $event['callback'] . (empty($event['options']['check']) ? ', false' : ', ' . $event['options']['check']) . (empty($event['options']['toContainer']) ? ', false' : ', true') . ')', false);\n }\n }\n $sort = function($a, $b){return $a['order'] - $b['order'];};\n uasort($this->css, $sort);\n uasort($this->js['top'], $sort);\n uasort($this->js['bottom'], $sort);\n $head = '<title' . $this->renderAttributes($this->title['attributes']) . '>' . htmlspecialchars($this->title['title']) . '</title>';\n foreach ($this->meta as $meta) $head .= '<meta' . $this->renderAttributes($meta) . ' />';\n foreach ($this->css as $css) \n {\n $conditions = '';\n if (isset($css['attributes']['conditions']))\n {\n $conditions = $css['attributes']['conditions'];\n unset($css['attributes']['conditions']);\n $head .= '<!--[' . $conditions . ']>';\n }\n if (empty($css['attributes']['type'])) $css['attributes']['type'] = 'text/css';\n if (isset($css['attributes']['href']) && empty($css['attributes']['rel'])) $css['attributes']['rel'] = 'stylesheet';\n if (isset($css['attributes']['href'])) $head .= '<link' . $this->renderAttributes($css['attributes']) . ' />';\n else $head .= '<style' . $this->renderAttributes($css['attributes']) . '>' . $css['style'] . '</style>';\n if ($conditions) $head .= '<![endif]-->';\n }\n foreach ($this->js['top'] as $js)\n {\n $conditions = '';\n if (isset($js['attributes']['conditions']))\n {\n $conditions = $js['attributes']['conditions'];\n unset($js['attributes']['conditions']);\n $head .= '<!--[' . $conditions . ']>';\n }\n if (empty($js['attributes']['type'])) $js['attributes']['type'] = 'text/javascript';\n $head .= '<script' . $this->renderAttributes($js['attributes']) . '>' . $js['script'] . '</script>';\n if ($conditions) $head .= '<![endif]-->';\n }\n if (count($this->js['bottom']))\n {\n $bottom = '';\n foreach ($this->js['bottom'] as $js) $bottom .= rtrim($js['script'], ';') . ';';\n if (strlen($bottom)) $head .= '<script type=\"text/javascript\">$(function(){' . $bottom . '});</script>';\n }\n $this->tpl->__head_entities = $head;\n if (false !== $body = $this->get($this->UID)) $this->tpl->{$this->UID} = $body->render();\n $html = $this->tpl->render();\n $this->commit();\n $this->push();\n return $this->dtd . $html;\n }", "public function render_control_template_scripts()\n {\n }", "public function render_control_template_scripts()\n {\n }", "public function render_control_template_scripts()\n {\n }", "public function render_control_template_scripts()\n {\n }", "public function render_control_template_scripts()\n {\n }", "function recursiveRender(){\n\t\tif( $this->folder_id === 0)\n\t\t\treturn parent::recursiveRender();\n\n\t\t// on click on new button open modal popup\n\t\t\t$js = [\n\t\t\t\t$this->js()->_selector('#'.$this->modal_popup->name)->modal(),\n\t\t\t\t$this->js()->_selector(\"#\".$this->modal_popup->name.\" .modal-header h4\")->text($this->js()->_selectorThis()->data('title')),\n\t\t\t\t$this->js()->_selector(\"#\".$this->modal_popup->name.\" #\".$this->field_new_type->name)->val($this->js()->_selectorThis()->data('documenttype'))\n\t\t\t];\n\t\t$this->action->js('click',$js)->_selector('li.xepan-new-document');\n\n\t\t// form submition handle\n\t\tif($this->form->isSubmitted()){\n\n\t\t\ttry{\n\t\t\t\t$this->api->db->beginTransaction();\n\t\t\t\t$document_model = $this->add('xepan\\hr\\Model_'.$this->form['add_new_document_type']);\n\t\t\t\t$document_model->createNew($this->form['name'],$this->form['folder_id']);\n\t\t\t\t$this->api->db->commit();\n\t\t\t}catch(Exception $e){\n\t\t\t\t$this->api->db->rollback();\n\t\t\t\t\n\t\t\t\t$this->form->js()->univ()->errorMessage('error occured '.$e->message())->execute();\n\t\t\t}\n\t\t\t$js = [$this->js()->_selector('#'.$this->modal_popup->name)->modal('toggle')];\n\t\t\t$this->form->js(null,$js)->univ()->successMessage(\"Added Successfully\")->execute();\n\t\t}\n\n\t\tparent::recursiveRender();\n\t}", "protected function _register_controls() {\n // `Testimonial Carousel` Section\n $this->start_controls_section( 'testimonial_carousel', array(\n 'label' => 'Testimonial Carousel',\n 'tab' => Controls_Manager::TAB_CONTENT,\n ) );\n\n $repeater = new \\Elementor\\Repeater();\n\n $repeater->add_control( 'testimonial_image', array(\n 'label' => 'Choose Image',\n 'type' => Controls_Manager::MEDIA,\n 'default' => array(\n 'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n ),\n ) );\n\n $repeater->add_group_control( \\Elementor\\Group_Control_Image_Size::get_type(), array(\n 'name' => 'testimonial_img_size',\n 'exclude' => array(),\n 'include' => array(),\n 'default' => 'thumbnail',\n ) );\n\n $repeater->add_control( 'testimonial_content', array(\n 'label' => 'Content',\n 'type' => Controls_Manager::TEXTAREA,\n 'default' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut elit tellus, luctus nec ullamcorper mattis, pulvinar dapibus leo.',\n ) );\n\n $repeater->add_control( 'testimonial_name', array(\n 'label' => 'Name',\n 'type' => Controls_Manager::TEXT,\n 'default' => 'John Doe',\n ) );\n\n $repeater->add_control( 'testimonial_title', array(\n 'label' => 'Title',\n 'type' => Controls_Manager::TEXT,\n 'default' => 'Web Developer',\n ) );\n\n $this->add_control( 'testimonial_list', array(\n 'label' => 'Testimonials',\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'default' => array(\n array(\n 'testimonial_content' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec pharetra magna eu nisi porttitor, ut auctor felis commodo. Fusce nunc nisl, volutpat vel dolor eget, dapibus congue mauris. Nullam vestibulum eros vitae augue sagittis aliquet. Nulla tempor imperdiet enim eu pulvinar.',\n ),\n array(\n 'testimonial_content' => 'Suspendisse nec imperdiet nisi, eu pulvinar turpis. Maecenas consequat pharetra mi eget volutpat. Vivamus quis pulvinar ante. Mauris vitae bibendum orci. Quisque porta dui mauris, eget facilisis nunc cursus et. Pellentesque condimentum mollis dignissim. Cras vehicula lacinia nulla, blandit luctus lectus ornare quis.',\n ),\n array(\n 'testimonial_content' => 'Etiam ac ligula magna. Nam tempus lorem a leo fermentum, eget iaculis eros vulputate. Fusce sollicitudin nulla ac aliquam scelerisque. Fusce nec dictum magna. Ut maximus ultrices pulvinar. Integer sit amet felis tellus. Phasellus turpis ex, luctus vulputate egestas eget, laoreet et nunc.',\n ),\n ),\n 'title_field' => '{{{ testimonial_name }}}'\n ) );\n\n $this->end_controls_section();\n\n // `Image` Section\n $this->start_controls_section( 'testimonial_image_style', array(\n 'label' => 'Image',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_image_size', array(\n 'label' => 'Image Size',\n 'type' => Controls_Manager::SLIDER,\n 'range' => array(\n 'px' => array(\n 'min' => 50,\n 'max' => 500,\n 'step' => 5,\n ),\n ),\n 'selectors' => array(\n '{{WRAPPER}} .img-box' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Border::get_type(), array(\n 'name' => 'testimonial_image_border',\n 'label' => 'Border Type',\n 'selector' => '{{WRAPPER}} .img-box',\n ) );\n\n $this->add_control( 'testimonial_image_border_radius', array(\n 'label' => 'Border Radius',\n 'type' => Controls_Manager::DIMENSIONS,\n 'size_units'=> array( 'px', '%' ),\n 'selectors' => array(\n '{{WRAPPER}} .img-box' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n '{{WRAPPER}} .img-box img' => 'border-radius: {{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};',\n ), \n ) );\n\n $this->end_controls_section();\n\n // `Content` Section\n $this->start_controls_section( 'testimonial_content_style', array(\n 'label' => 'Content',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_content_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_3,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial-content' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_content_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_3,\n 'selector' => '{{WRAPPER}} .testimonial-content',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_content_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial-content',\n ) );\n\n $this->end_controls_section();\n\n // `Name` Section\n $this->start_controls_section( 'testimonial_name_style', array(\n 'label' => 'Name',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_name_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_1,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial_name' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_name_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_1,\n 'selector' => '{{WRAPPER}} .testimonial_name',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_name_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial_name',\n ) );\n\n $this->end_controls_section();\n\n // `Title` Section\n $this->start_controls_section( 'testimonial_title_style', array(\n 'label' => 'Title',\n 'tab' => Controls_Manager::TAB_STYLE,\n ) );\n\n $this->add_control( 'testimonial_title_text_color', array(\n 'label' => 'Text Color',\n 'type' => Controls_Manager::COLOR,\n 'scheme' => array(\n 'type' => \\Elementor\\Scheme_Color::get_type(),\n 'value' => \\Elementor\\Scheme_Color::COLOR_3,\n ),\n 'selectors' => array(\n '{{WRAPPER}} .testimonial_title' => 'color: {{VALUE}}',\n ),\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Typography::get_type(), array(\n 'name' => 'testimonial_title_typography',\n 'label' => 'Typography',\n 'scheme' => \\Elementor\\Scheme_Typography::TYPOGRAPHY_3,\n 'selector' => '{{WRAPPER}} .testimonial_title',\n ) );\n\n $this->add_group_control( \\Elementor\\Group_Control_Text_Shadow::get_type(),array(\n 'name' => 'testimonial_title_text_shadow',\n 'label' => 'Text Shadow',\n 'selector' => '{{WRAPPER}} .testimonial_title',\n ) );\n\n $this->end_controls_section();\n }", "protected function _register_controls() {\n\n\t\t$this->start_controls_section(\n\t\t\t'content_section',\n\t\t\tarray(\n\t\t\t\t'label' => 'Slider Revolution 6',\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_CONTENT,\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'revslidertitle',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Selected Module:', 'revslider' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'render_type' => 'none',\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'shortcode',\n\t\t\tarray(\n\t\t\t\t//'type' => \\Elementor\\Controls_Manager::HIDDEN,\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::TEXT,\n\t\t\t\t'label' => __( 'Shortcode', 'revslider' ),\n\t\t\t\t'dynamic' => ['active' => true],\n\t\t\t\t'placeholder' => '',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t// Advanced \t\t\n\t\t$this->add_control(\n\t\t\t'select_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">cached</i> Select Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.selectslider',\n\t\t\t)\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'edit_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">edit</i> Edit Module', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.editslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'settings_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">tune</i> Block Settings', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.settingsslider',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'optimize_slider',\n\t\t\tarray(\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::BUTTON,\n\t\t\t\t'button_type' => 'default',\n\t\t\t\t'text' => __( '<i type=\"button\" class=\"material-icons\">flash_on</i> Optimize File Sizes', 'revslider' ),\n\t\t\t\t'event' => 'themepunch.optimizeslider',\n\t\t\t)\n\t\t);\n\t\t$this->end_controls_section();\t\n\t}", "function XmlControlOnRender(&$xmlWriter){\n if ($this->debug_mode) echo $this->ClassName . '::XmlControlOnRender(&$xmlWriter);' . \"<HR>\";\n\n $xmlWriter->WriteElementString(\"_PageTitle\", $this->Kernel->Localization->GetItem(strtoupper($this->library_ID), \"_EDIT_TITLE\"));\n $xmlWriter->WriteElementString(\"list_handler\", $this->listHandler);\n if ($this->disabled_delete)\n \t$xmlWriter->WriteElementString(\"disabled_delete\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_delete\", \"no\");\n\n if ($this->disabled_edit)\n $xmlWriter->WriteElementString(\"disabled_edit\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_edit\", \"no\");\n\n if ($this->disabled_add)\n $xmlWriter->WriteElementString(\"disabled_add\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_add\", \"no\");\n\n if ($this->disabled_copy)\n $xmlWriter->WriteElementString(\"disabled_copy\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_copy\", \"no\");\n\n if (strlen($this->icon_file))\n $xmlWriter->WriteElementString(\"icon_file\", $this->icon_file);\n\n if ((($this->event == \"AddItem\") || ($this->event == \"DoAddItem\")) && $this->disabled_add) {\n $xmlWriter->WriteElementString(\"disabled_button\", \"yes\");\n } else {\n if ((($this->event == \"EditItem\") || ($this->event == \"DoEditItem\")) && $this->disabled_edit)\n $xmlWriter->WriteElementString(\"disabled_button\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_button\", \"no\");\n }\n parent::XmlControlOnRender($xmlWriter);\n }", "function Render() {\n $this->RenderChildren();\n }", "public function registerControlsUI(){\n\t//\techo \"<br/>\".__METHOD__;\n \t$this->registerControlUI(ExjUI::NewTextField('ApplicationName', 'App'));\n \t$this->registerControlUI(ExjUI::NewTextField('type', 'Tipo'));\n \t\n \t$id_persona = ExjRequest::GetParamInt('id_persona', 0);\n \tif ($id_persona === 0) {\n \t\t$this->addBrokenRuler(\"No se ha enviado el parámetro id!\");\n \t\treturn false;\n \t}\n \t\n// \tExjTransferCharacters::decodeUTF8ToISO($id_persona);\n \t \t\n \t\n \tglobal $exj;\n \t\n \t// $exj->includeDataCustom('sys_users');\n \t\n \t$infoPerson = AppSysUsersData::getInfoPerson($id_persona);\n\n \tif (!$this->_sendMail($infoPerson)) {\n \t\treturn false;\n \t}\n\n \t\n \t$this->registerControlUI(ExjUI::NewTextField('source', 'Fuente'));\n \t\n \t\n \t$this->registerControlUI(ExjUI::NewTextArea('desc_sol_comun', 'Descripción', '99%', 210));\n\t}", "protected function renderThenChild() {}", "protected function _register_controls() {\n\t\t$template_type = learndash_elementor_get_template_type();\n\t\t$preview_step_id = $this->learndash_get_preview_post_id( $template_type );\n\n\t\t$this->start_controls_section(\n\t\t\t'preview',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Preview Setting', 'learndash-elementor' ),\n\t\t\t)\n\t\t);\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'course' ) ), true ) ) {\n\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Course.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Course', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'course' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'course' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ) ), true ) ) {\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Lesson.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Lesson', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'lesson' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'lesson' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( in_array( $template_type, array( learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\t\t\t$this->add_control(\n\t\t\t\t'preview_step_id',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => sprintf(\n\t\t\t\t\t\t// translators: placeholder: Topic.\n\t\t\t\t\t\tesc_html_x( '%s', 'placeholder: Topic', 'learndash-elementor' ),\n\t\t\t\t\t\t\\LearnDash_Custom_Label::get_label( 'topic' )\n\t\t\t\t\t),\n\t\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t\t'options' => array(),\n\t\t\t\t\t'default' => $preview_step_id,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_POST,\n\t\t\t\t\t\t'query' => array(\n\t\t\t\t\t\t\t'post_type' => array( learndash_get_post_type_slug( 'topic' ) ),\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'preview_user_id',\n\t\t\tarray(\n\t\t\t\t'label' => esc_html__( 'User ID', 'learndash-elementor' ),\n\t\t\t\t'type' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_CONTROL_ID,\n\t\t\t\t'options' => array(),\n\t\t\t\t'default' => get_current_user_id(),\n\t\t\t\t'label_block' => true,\n\t\t\t\t'autocomplete' => array(\n\t\t\t\t\t'object' => ElementorPro\\Modules\\QueryControl\\Module::QUERY_OBJECT_USER,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t/**\n\t\t * Start of Style tab.\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'section_course_content_header',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Header', 'learndash-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-section-heading h2',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'lesson' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-lesson-topic-list .ld-table-list .ld-table-list-header .ld-table-list-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'topic' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_header_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-table-list .ld-table-list-header .ld-table-list-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_header_text_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading > h2' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list .ld-table-list-header' => 'color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ), learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list.ld-topic-list .ld-table-list-header' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list.ld-topic-list .ld-table-list-header.ld-primary-background' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_expand_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading .ld-expand-button' => 'color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_header_expand_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-section-heading .ld-item-list-actions .ld-expand-button' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_course_content_row_item',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Row Item', 'learndash-elementor' ),\n\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'header_section_course_content_row_item_title',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'TITLE', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-title',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'lesson' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-topic-list.ld-table-list .ld-table-list-items',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t} elseif ( learndash_get_post_type_slug( 'topic' ) === $template_type ) {\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_title_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-topic-list.ld-table-list .ld-table-list-items',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_row_item_title_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Title Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '#495255',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item .ld-item-title' => 'color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list-items .ld-table-list-item a' => 'color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'control_course_content_row_item_background_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t'default' => '#ffffff',\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-list .ld-item-list-item' => 'background-color: {{VALUE}};',\n\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-table-list-items' => 'background-color: {{VALUE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\tif ( learndash_get_post_type_slug( 'course' ) === $template_type ) {\n\t\t\t$this->add_control(\n\t\t\t\t'header_section_course_content_row_item_expand',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'EXPAND', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_expand_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-icon-arrow-down' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-text' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_expand_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Expand Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-item-details .ld-expand-button .ld-icon-arrow-down' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_row_item_lesson_progress',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'LESSON PROGRESS HEADER', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_row_item_lesson_progress_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_lesson_progress_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header.ld-primary-background' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_row_item_lesson_progress_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header.ld-primary-background' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-lesson-list .ld-item-list-items .ld-item-list-item .ld-table-list-header' => 'background-color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t}\n\n\t\t$this->end_controls_section();\n\n\t\tif ( in_array( $template_type, array( learndash_get_post_type_slug( 'lesson' ), learndash_get_post_type_slug( 'topic' ) ), true ) ) {\n\n\t\t\t$this->start_controls_section(\n\t\t\t\t'section_course_content_footer',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Footer', 'learndash-elementor' ),\n\t\t\t\t\t'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_links',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'LINKS (Back to...)', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_links_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-actions a.ld-primary-color',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_links_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-actions a.ld-primary-color' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_navigation',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'NAVIGATION', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_navigation_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_navigation_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_navigation_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'primary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action a.ld-button' => 'background-color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'header_course_content_footer_mark_complete',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'MARK COMPLETE', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::HEADING,\n\t\t\t\t\t'separator' => 'before',\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_group_control(\n\t\t\t\t\\Elementor\\Group_Control_Typography::get_type(),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => 'control_course_content_footer_mark_complete_text',\n\t\t\t\t\t'scheme' => \\Elementor\\Core\\Schemes\\Typography::TYPOGRAPHY_2,\n\t\t\t\t\t'selector' => '{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button',\n\t\t\t\t\t'exclude' => array( 'line_height' ),\n\t\t\t\t)\n\t\t\t);\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_mark_complete_text_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => '#ffffff',\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button' => 'color: {{VALUE}} !important;',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->add_control(\n\t\t\t\t'control_course_content_footer_mark_complete_text_background_color',\n\t\t\t\tarray(\n\t\t\t\t\t'label' => __( 'Background Color', 'learndash-elementor' ),\n\t\t\t\t\t'type' => \\Elementor\\Controls_Manager::COLOR,\n\t\t\t\t\t'default' => $this->learndash_get_template_color( 'secondary' ),\n\t\t\t\t\t'selectors' => array(\n\t\t\t\t\t\t'{{WRAPPER}} .learndash-wrapper .ld-content-action input.learndash_mark_complete_button' => 'background-color: {{VALUE}};',\n\t\t\t\t\t),\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t$this->end_controls_section();\n\t\t}\n\t}", "public function postRender()\n {\n }", "protected function _register_controls() {\n\n $nav_menus = wp_get_nav_menus();\n\n $nav_menus_option = array(\n esc_html__( 'Select a menu', 'Alita-extensions' ) => '',\n );\n\n foreach ( $nav_menus as $key => $nav_menu ) {\n $nav_menus_option[$nav_menu->name] = $nav_menu->name;\n }\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'description' => esc_html__( 'Enter the title of menu.', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => 'Alita Best Selling:',\n ]\n );\n\n $this->add_control(\n 'menu',\n [\n\n 'label' => esc_html__( 'Menu', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'default' => 'vertical-menu',\n 'options' => $nav_menus_option,\n ]\n );\n \n\n $this->end_controls_section();\n\n }", "public function output_setup_form() {\n\t\t$this->output_controls_html( 'klicktipp' );\n\t}", "public function init()\n {\n // Add declaration statement agree element\n $this->addElement('checkbox', 'declaration_statement', array(\n 'required' => true,\n 'checkedValue' => '1',\n 'uncheckedValue' => null, // Must be used to override default of '0' and force an error when left unchecked\n 'validators' => array(\n array(\n 'NotEmpty', true, array(\n 'messages' => array(\n 'isEmpty' => 'You must agree to the declaration statement to continue'\n )\n )\n )\n )\n ));\n\n // Set custom subform decorator\n $this->setDecorators(array(\n array('ViewScript', array('viewScript' => 'portfolio-insurance-quote/subforms/disclosure-and-declaration.phtml'))\n ));\n \n // Strip all tags to prevent XSS errors\n $this->setElementFilters(array('StripTags'));\n \n \n $this->setElementDecorators(array(\n array('ViewHelper', array('escape' => false)),\n array('Label', array('escape' => false))\n ));\n }", "public function preinit()\n\t{\n\t\t//\tCreate our internal name\n\t\tCPSHelperBase::createInternalName( $this );\n\n\t\t//\tAttach our default Behavior\n\t\t$this->attachBehavior( 'psWidget', 'pogostick.behaviors.CPSWidgetBehavior' );\n\t}", "function AddControls($controls)\r\n {\r\n $this->Controls = $controls;\r\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'title',\n\t\t\t[\n\t\t\t\t'label' => __( 'Title', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'description',\n\t\t\t[\n\t\t\t\t'label' => __( 'Description', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::TEXTAREA,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'content',\n\t\t\t[\n\t\t\t\t'label' => __( 'Content', 'elementor-hello-world' ),\n\t\t\t\t'type' => Controls_Manager::WYSIWYG,\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\n\t\t$this->end_controls_section();\n\t}", "public function hooks() {\n\t\tadd_action( 'wp_ajax_wp_sc_form_process_'. $this->button_slug, array( $this, 'process_form' ) );\n\n\t\t// If we have a conditional callback and the return of the callback is false\n\t\tif ( $this->args['conditional_callback'] && is_callable( $this->args['conditional_callback'] ) && ! call_user_func( $this->args['conditional_callback'], $this ) ) {\n\t\t\t// Then that means we should bail\n\t\t\treturn;\n\t\t}\n\n\t\tadd_action( 'admin_init', array( $this, 'button_init' ) );\n\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'register_quicktag_button_script' ) );\n\t\tadd_action( 'admin_footer', array( $this, 'add_quicktag_button_script' ) );\n\t\tadd_action( 'admin_footer', array( $this, 'add_modal_form' ) );\n\t}" ]
[ "0.6940392", "0.68212813", "0.6582931", "0.64314353", "0.63754994", "0.6372557", "0.627751", "0.61483157", "0.6148234", "0.6125975", "0.60619944", "0.59553146", "0.5952499", "0.59170574", "0.5850471", "0.58358806", "0.58178544", "0.5813324", "0.57976645", "0.5747824", "0.57314295", "0.5705961", "0.5657934", "0.56505513", "0.5642044", "0.5607442", "0.5605382", "0.5603048", "0.5554817", "0.5551405", "0.554655", "0.5530534", "0.55223316", "0.55200124", "0.5518137", "0.55092204", "0.54802257", "0.547989", "0.547989", "0.546262", "0.54593146", "0.54549307", "0.5454346", "0.5449757", "0.5430142", "0.5428789", "0.54143625", "0.5412317", "0.54055583", "0.53967375", "0.53960735", "0.53908426", "0.5352314", "0.5339646", "0.5339517", "0.533542", "0.53077644", "0.5302614", "0.5301139", "0.52987045", "0.52849823", "0.52742094", "0.5273556", "0.5256028", "0.5251886", "0.5250117", "0.5249786", "0.52458584", "0.5228114", "0.5221995", "0.52142894", "0.52037555", "0.51869774", "0.5181725", "0.51721525", "0.5159176", "0.51575184", "0.51407915", "0.51327527", "0.5116707", "0.5116707", "0.5116707", "0.5116707", "0.5116707", "0.5116632", "0.5115852", "0.51113886", "0.51102793", "0.5104465", "0.51002413", "0.5093783", "0.5092482", "0.50903106", "0.5089453", "0.50825965", "0.50801826", "0.5075429", "0.5071258", "0.5069968", "0.5068727" ]
0.7211219
0
Notifies server controls that use compositionbased implementation to set data to child controls they contain in preparation for posting back or rendering.
function InitChildControls() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function RenderChildren() {\n if ($this->HasControls()) {\n foreach($this->Controls as $control) {\n $control->Render();\n }\n }\n }", "public function customize_controls_init()\n {\n }", "public function preRender() {\n\t\tif ($this->hasOwnBoundObject()) {\n\t\t\t$this->ownBoundObject = $this->getBoundObject();\n\t\t}\n\t\tparent::preRender();\n\t}", "public function prepare_controls()\n {\n }", "public function afterLoadRegisterControlsUI(){\n\t\t\n\t}", "function CreateChildControls() {\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore \n\n\t\t$this->register_general_content_controls();\n\n\t\t$this->register_count_content_controls();\n\n\t\t$this->register_helpful_information();\n\t}", "function customize_controls_init()\n {\n }", "function ControlOnLoad(){\n parent::ControlOnLoad();\n }", "protected function _register_controls() {\n\t}", "function initRecursive() {\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n @$control->Page = &$this->Page;\n $control->initRecursive();\n }\n }\n $this->_state = WEB_CONTROL_INITIALIZED;\n $this->ControlOnInit();\n }", "function CreateChildControls()\n {\n if ($this->debug_mode)\n echo $this->ClassName . \"::CreateChildControls();\" . \"<HR>\";\n if ($this->listSettings->GetCount()) {\n if ($this->listSettings->HasItem(\"MAIN\", \"TABLE\")) {\n $this->Table = $this->listSettings->GetItem(\"MAIN\", \"TABLE\");\n }\n else {\n $this->AddEditErrorMessage(\"EMPTY_TABLE_SETTINGS\", array(), true);\n }\n if (! $this->error) {\n\n //parse library file\n \t$this->InitLibraryData();\n \t//reinitilize database columns definitions\n $this->ReInitTableColumns();\n //create validator\n $this->validator = new Validate($this, $this->Storage->columns, $this->library_ID);\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $_editControl = new $this->editcontrol(\"ItemsEdit\", \"edit\", $this->Storage);\n $this->AddControl($_editControl);\n }\n } // if\n else {\n $this->AddEditErrorMessage(\"EMPTY_LIBRARY_SETTINGS\", array(), true);\n }\n }", "function initChildrenRecursive() {\n $this->initChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->initChildrenRecursive();\n }\n }\n\n }", "public function init()\n {\n // set class to identify as p4cms-ui component\n $this->setAttrib('class', 'p4cms-ui')\n ->setAttrib('dojoType', 'p4cms.ui.grid.Form');\n\n // turn off CSRF protection - its not useful here (form data are\n // used for filtering the data grid and may be exposed in the URL)\n $this->setCsrfProtection(false);\n\n // call parent to publish the form.\n parent::init();\n }", "protected function _register_controls() { // phpcs:ignore PSR2.Methods.MethodDeclaration.Underscore\n\n\t\t$this->register_controls();\n\t}", "function CreateChildControls(){\n\t for($i=0; $i<sizeof($this->libs); $i++){\n\t\tif(!$this->error[$this->libs[$i]]){\n\t\t\t$this->AddControl(new ItemsListControl(\"ItemsList_\".$this->libs[$i], \"list\", $this->Storage));\n\t\t\t //Add control to controls\n\t\t\t$extra_url=\"\"; // Clearing ExtraUrl\n\t\t\tfor($j=0; $j<sizeof($this->libs); $j++){ // MAking ExtraUrl based on current controls state\n\t\t\t\t $extra_url .= \"&amp;\".$this->libs[$j].\"_start=\".$this->start[$this->libs[$j]].\"&amp;\".$this->libs[$j].\"_order_by=\".$this->order_by[$this->libs[$j]].($this->is_context_frame ? \"&amp;contextframe=1\" : \"\");\n\t\t\t}\n\t\t\t// Adding ItemsList control\n\t\t\t$this->Controls[\"ItemsList_\".$this->libs[$i]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t //\"fields\" => $this->fields,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $this->order_by[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $this->start[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => $this->data[$this->libs[$i]]\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t // Getting list of subcategories\n\t\t $sub_categories = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetSubCategories();\n\t\t $tree_control = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetTreeControl();\n\t\t $nodelevels = $this->Controls[\"ItemsList_\".$this->libs[$i]]->GetNodeLevels();\n\t\t // Geting current level in catalog\n\t\t $nodelevel = (empty($nodelevels) ? 0 : $nodelevels[$this->parent_id[$this->libs[$i]]]+1);\n\t\t if($sub_categories !== false){\n\t\t\t for($k=0; $k<sizeof($sub_categories); $k++){\n\t\t\t\t if((!empty($sub_categories[$k][\"levels\"]) && in_array($nodelevel, $sub_categories[$k][\"levels\"])) ||\n\t\t\t\t\t(empty($sub_categories[$k][\"levels\"]))\n\t\t\t\t ) {\n\t\t\t\t // Preparing data for Sub-categories controls\n\t\t\t\t $sub_start=\"\";\n\t\t\t\t $sub_order_by=\"\";\n\t\t\t\t $append_str=\"\";\n\t\t\t\t // Building parts of url to preserve host-catalog sorting orders and paging\n\t\t\t\t for($l=0; $l<sizeof($sub_categories); $l++){\n\t\t\t\t\t $sub_start[$l] = $this->Request->ToNumber($sub_categories[$l][\"library\"].\"_start\",0);\n\t\t\t\t\t $sub_order_by[$l] = $this->Request->ToString($sub_categories[$l][\"library\"].\"_order_by\",\"\");\n\t\t\t\t\t $append_str .= \"&amp;\".$sub_categories[$l][\"library\"].\"_start=\".$sub_start[$l].\"&amp;\".$sub_categories[$l][\"library\"].\"_order_by=\".$sub_order_by[$l];\n\t\t\t\t }\n\t\t\t\t $host_extra_url = \"&amp;\".$this->libs[$i].\"_parent_id=\".$this->parent_id[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_start=\".$this->start[$this->libs[$i]].\"&amp;\".$this->libs[$i].\"_order_by=\".$this->order_by[$this->libs[$i]];\n\t\t\t\t // Appending built extra url to host-catalog control\n\t\t\t\t $this->Controls[\"ItemsList_\".$this->libs[$i]]->AppendSelfString($append_str);\n\t\t\t\t // Adding Child catalog to current host\n\t\t\t\t $this->AddControl(new ItemsListControl(\"ItemsList_sub_\".$sub_categories[$k][\"library\"], \"list\", $this->Storage));\n\t\t\t\t $this->Controls[\"ItemsList_sub_\".$sub_categories[$k][\"library\"]]->InitControl(array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"library_ID\" => $sub_categories[$k][\"library\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"host_library_ID\" => $this->libs[$i],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"self\" => $this->self.\"\".$extra_url.\"\".$host_extra_url.$append_str,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"handler\" =>$this->handler,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"package\" =>$this->Package,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"order_by\" => $sub_order_by[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"start\" => $sub_start[$k],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data_extractor\" => $this->extractor_method,\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"parent_id\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"data\" => array($sub_categories[$k][\"link_field\"] => $this->parent_id[$this->libs[$i]]),\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_var\" => $sub_categories[$k][\"link_field\"],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"custom_val\" => $this->parent_id[$this->libs[$i]],\n\t\t\t\t\t\t\t\t\t\t\t\t\t \"tree_control\" => $tree_control,\n\t\t\t\t\t\t\t\t\t\t\t\t\t ));\n\t\t\t\t}// if\n\t\t\t } // for k\n\n\t\t } // if sub_categories\n\t\t} // if !error\n\t\t} // for i\n\t}", "public function setup()\n {\n parent::setup();\n \n $formClass = $this->getChildFormClass();\n $collection = $this->getParentObject()->{$this->getRelationAlias()};\n $nbChilds = 0;\n $min = $this->getMinNbChilds();\n $max = $this->getMaxNbChilds();\n \n if ($min > $max && $max > 0)\n throw new RuntimeException('min cannot be greater than max.');\n \n // embed forms for each child element that is already persisted\n foreach ($collection as $childObject)\n {\n $form = new $formClass($childObject);\n $pk = $childObject->identifier();\n \n if ($childObject->exists() === false)\n throw new RuntimeException('Transient child objects are not supported.');\n \n if (count($pk) !== 1)\n throw new RuntimeException('Composite primary keys are not supported.');\n \n $this->embedForm(self::PERSISTENT_PREFIX.reset($pk), $form);\n $nbChilds += 1;\n }\n \n // embed as many additional forms as are needed to reach the minimum\n // number of required child objects\n for (; $nbChilds < $min; $nbChilds += 1)\n {\n $form = new $formClass($collection->get(null));\n $this->embedForm(self::TRANSIENT_PREFIX.$nbChilds, $form);\n }\n \n $this->validatorSchema->setPostValidator(new sfValidatorCallback(array(\n 'callback' => array($this, 'validateLogic'),\n )));\n }", "public function Populate() {\r\n\t\t$form_instance = $this->form_instance;\r\n\t\t// Retrieve the field data\r\n\t\t$_els = vcff_parse_container_data($form_instance->form_content);\r\n\t\t// If an error has been detected, return out\r\n\t\tif (!$_els || !is_array($_els)) { return; }\r\n\t\t// Retrieve the form instance\r\n\t\t$form_instance = $this->form_instance; \r\n\t\t// Loop through each of the containers\r\n\t\tforeach ($_els as $k => $_el) {\r\n\t\t\t// Retrieve the container instance\r\n\t\t\t$container_instance = $this->_Get_Container_Instance($_el);\r\n\t\t\t// Add the container to the form instance\r\n\t\t\t$form_instance->Add_Container($container_instance);\r\n\t\t}\r\n\t}", "function Control_Render(&$Owner)\r\n\t{\r\n\t\t$parent = $Owner->OriginalNode->ParentNode();\r\n\t\t\r\n\t\t//insert this node before the parent \r\n\t\t$parent->InsertBefore($this->OriginalNode, $Owner->OriginalNode);\r\n\t\r\n\t\r\n\t\t//call parent render with ourselves as the owner\r\n\t\t$result = parent::Control_Render($this);\r\n\t\t\r\n\t\tif (!$result)\r\n\t\t{\r\n\t\t\treturn false;\t\r\n\t\t}\r\n\t\t\r\n\t\t\r\n\t\t//NOTE: this control allows the use of [= ] inline blocks\r\n\t\tParser::ParseInlineBlocks($this, $this->OriginalNode);\r\n\t\t\r\n\t\t\r\n\t\t\r\n\t\t//get all items within the copy\r\n\t\t$holder_items = $this->OriginalNode->GetElementsByTagName(PCNODE_ITEM);\r\n\t\t\r\n\t\t//NOTE:: this relative query doesn't work properly in PHP4\r\n\t\t//$holder_items = $ctx->xpath_eval(\"//\".PCNODE_ITEM.\"[@repeater='\".$this->ID.\"']\", $holder);\r\n\t\t\r\n\t\t\r\n\t\t//replace each item with it's value\r\n\t\tfor ($i = 0; $i < count($holder_items); $i++)\r\n\t\t{\r\n\t\t\t$clone_item = $holder_items[$i];\r\n\t\t\t\r\n\t\t\t//ensure Item has repeater attribute\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") == \"\")\r\n\t\t\t{\r\n\t\t\t\ttrigger_error(\"An item has been found within a repeater (id: \".$Owner->ID.\" ) without a valid repeater attribute.\",E_USER_ERROR);\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//goto next item if this one isn't for this repeater\r\n\t\t\tif ($clone_item->GetAttribute(\"repeater\") != $Owner->ID)\r\n\t\t\t{\r\n\t\t\t\tcontinue;\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t//create a new repeater item\r\n\t\t\t$item = new RepeaterItem($clone_item);\r\n\t\t\t\r\n\t\t\t//get the datafield for this item\r\n\t\t\t$datafield = $item->GetDatafield();\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t$item->SetData($this->DataRow->Get($datafield));\r\n\t\t\t\r\n\t\t}\r\n\t\t\t\r\n\t\t\t\r\n\t\t\r\n\t}", "public function register_controls()\n {\n }", "protected function onLoad()\n\t\t{\n\t\t\tparent::onLoad();\n\n\t\t\tif( $this->items->count > 0 )\n\t\t\t{\n\t\t\t\t$this->defaultHTMLControlId = $this->getHTMLControlId() . \"__0\";\n\t\t\t}\n\t\t}", "public function Render()\n\t{\n\t // when in NEW mode or when parent form in NEW mode, do nothing\n\t global $g_BizSystem;\n\t $prtMode = \"\";\n\t if ($this->m_ParentFormName) {\n $prtForm = $g_BizSystem->GetObjectFactory()->GetObject($this->m_ParentFormName);\n $prtMode = $prtForm->GetDisplayMode()->GetMode();\n\t }\n\t if ($this->m_Mode != MODE_N && $prtMode != MODE_N)\n\t {\n \t // get view history\n \t if (!$this->m_NoHistoryInfo)\n\t $this->SetHistoryInfo($g_BizSystem->GetSessionContext()->GetViewHistory($this->m_Name));\n\t }\n\t if ($this->m_Mode == MODE_N)\n $this->UpdateActiveRecord($this->GetDataObj()->NewRecord());\n\n //Moved the renderHTML function infront of declaring subforms\n $renderedHTML = $this->RenderHTML();\n\n\t global $g_BizSystem;\n\t // prepare the subforms' dataobjs, since the subform relates to parent form by dataobj association\n\t if ($this->m_SubForms) {\n \t foreach($this->m_SubForms as $subForm) {\n $formObj = $g_BizSystem->GetObjectFactory()->GetObject($subForm);\n $dataObj = $this->GetDataObj()->GetRefObject($formObj->m_DataObjName);\n if ($dataObj)\n $formObj->SetDataObj($dataObj);\n }\n\t }\n\t $this->SetClientScripts();\n\n return $renderedHTML;\n\t}", "function loadRecursive() {\n $this->ControlOnLoad();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count ; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->loadRecursive();\n }\n }\n $this->_state = WEB_CONTROL_LOADED;\n }", "public function definition_after_data() {\n global $DB;\n\n $mform = $this->_form;\n\n // Check that we are updating a current customcert.\n if ($this->id) {\n // Get the pages for this customcert.\n if ($pages = $DB->get_records('customcert_pages', array('customcertid' => $this->id))) {\n // Loop through the pages.\n foreach ($pages as $p) {\n // Set the width.\n $element = $mform->getElement('pagewidth_' . $p->id);\n $element->setValue($p->width);\n // Set the height.\n $element = $mform->getElement('pageheight_' . $p->id);\n $element->setValue($p->height);\n // Set the margin.\n $element = $mform->getElement('pagemargin_' . $p->id);\n $element->setValue($p->margin);\n }\n }\n }\n }", "function dataBound(&$render, &$params)\n {\n if ($this->onDataBound != null) {\n $dataBoundHandlerName = $this->onDataBound;\n $render->pnFormEventHandler->$dataBoundHandlerName($render, $this, $params);\n }\n }", "public function setupControl()\n\t{\n\t\t$this->addText('referenceNumber', 'Reference number:');\n\t\t$this->addSelect('priority', 'Priority:', PriorityEnum::getOptions());\n\t\t$this->addTextArea('symptoms', 'Symptoms:', 40, 8)\n\t\t\t->addRule(Form::FILLED, 'Symptoms are required.');\n\t\t$this->addText('problemOwner', 'Problem owner:');\n\t\t$this->addSelect('status', 'State:', array(\n\t\t\tOperationProblem::STATUS_NEW => 'new',\n\t\t\tOperationProblem::STATUS_INVESTIGATED => 'investigated',\n\t\t\tOperationProblem::STATUS_RESOLVED => 'resolved',\n\t\t\tOperationProblem::STATUS_CLOSED => 'closed'\n\t\t));\n\n\t\t$this->addSelect('category', 'Category:', array('' => $this->noCategoryText) + $this->getCategoriesOptions());\n\n\t\t$this->addTextArea('onEventRaw', 'onEvent:');\n\n\t\t$this->addSubmit('save', 'Save problem');\n\n\t\t$this->onValidate[] = $this->onValidateForm;\n\t}", "public function controls()\n {\n }", "protected function actionPostLoadingEvent()\n {\n if (self::$child_data === null) {\n self::$child_data = [];\n foreach ($this->getParentModel()->children->child->iterateItems() as $node_uuid => $node) {\n if (empty((string)$node->enabled)) {\n continue;\n }\n $conn_uuid = (string)$node->connection;\n if (!isset(self::$child_data[$conn_uuid])) {\n self::$child_data[$conn_uuid] = [];\n }\n foreach (self::$child_attrs as $key) {\n if (!isset(self::$child_data[$conn_uuid][$key])) {\n self::$child_data[$conn_uuid][$key] = [];\n }\n self::$child_data[$conn_uuid][$key][] = (string)$node->$key;\n }\n }\n }\n foreach ($this->internalChildnodes as $node) {\n if (!$node->getInternalIsVirtual()) {\n $extra_attr = ['local_ts' => '', 'remote_ts' => ''];\n $conn_uuid = (string)$node->getAttribute('uuid');\n foreach (self::$child_attrs as $key) {\n $child_node = new TextField();\n $child_node->setInternalIsVirtual();\n if (isset(self::$child_data[$conn_uuid]) && !empty(self::$child_data[$conn_uuid][$key])) {\n $child_node->setValue(implode(',', array_unique(self::$child_data[$conn_uuid][$key])));\n }\n $node->addChildNode($key, $child_node);\n }\n }\n }\n return parent::actionPostLoadingEvent();\n }", "public function beforerender() {\n parent::beforeRender();\n $this->Meta->data();\n }", "function ControlOnLoad() {\n }", "protected function onChange()\n {\n $this->markAsChanged();\n if ($this->parent !== null) {\n $this->parent->onChange();\n }\n }", "public function init()\n {\n // Top-level parent\n parent::init();\n $this->applyOmekaStyles();\n $this->setAutoApplyOmekaStyles(false);\n $this->setAttrib('id', 'new_collection');\n $this->setAttrib('method', 'POST');\n // Target collection\n $this->addElement('text', 'name', array(\n 'label' => __(\"Collection Name\"),\n 'description' => __(\"Name of the new collection to import into.\"),\n 'required' => true,\n ));\n }", "protected function regenerateFormControls()\n\t{\n\t\t$form = $this->getForm();\n\n\t\t// regenerate checker's checkbox controls\n\t\tif ($this->hasOperations()) {\n\t\t\t$values = $form->getValues();\n\n\t\t\t$form->removeComponent($form['checker']);\n\t\t\t$sub = $form->addContainer('checker');\n\t\t\tforeach ($this->getRows() as $row) {\n\t\t\t\t$sub->addCheckbox($row[$this->keyName], $row[$this->keyName]);\n\t\t\t}\n\n\t\t\tif (!empty($values['checker'])) {\n\t\t\t\t$form->setDefaults(array('checker' => $values['checker']));\n\t\t\t}\n\t\t}\n\n\t\t// for selectbox filter controls update values if was filtered over column\n\t\tif ($this->hasFilters()) {\n\t\t\tparse_str($this->filters, $list);\n\n\t\t\tforeach ($this->getFilters() as $filter) {\n\t\t\t\tif ($filter instanceof SelectboxFilter) {\n\t\t\t\t\t$filter->generateItems();\n\t\t\t\t}\n\n\t\t\t\tif ($this->filters === $this->defaultFilters && ($filter->value !== NULL || $filter->value !== '')) {\n\t\t\t\t\tif (!in_array($filter->getName(), array_keys($list))) $filter->value = NULL;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// page input & items selectbox\n\t\t$form['page']->setValue($this->paginator->page); // intentionally page from paginator\n\t\t$form['items']->setValue($this->paginator->itemsPerPage);\n\t}", "public function render ($writer)\n\t{\n\t\tif($this->getHasPreRendered())\n\t\t{\n\t\t\tparent::render($writer);\n\t\t\tif($this->getActiveControl()->canUpdateClientSide())\n\t\t\t\t$this->getPage()->getCallbackClient()->replaceContent($this->_container,$writer);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->getPage()->getAdapter()->registerControlToRender($this->_container,$writer);\n\t\t}\n\t}", "public function createChildControls ()\n\t{\n\t\tif ($this->_container===null)\n\t\t{\n\t\t\t$this->_container=Prado::CreateComponent('System.Web.UI.ActiveControls.TActivePanel');\n\t\t\t$this->_container->setId($this->getId(false).'_content');\n\t\t\tparent::getControls()->add($this->_container);\n\t\t}\n\t}", "public function beforeSendToClient($cname)\n\t{\n\t\t$form_name = self::form_name($cname, $this->id);\n\n\t\tif (($templated_path = self::templateImagePath($this->attrs['image_path'])) != $this->attrs['image_path'])\n\t\t{\n\t\t\tself::setElementAttribute($form_name, 'image_path', $this->attrs['image_path'] = $templated_path);\n\t\t\t//error_log(__METHOD__.\"() setting templated image-path for $form_name: $templated_path\");\n\t\t}\n\n\t\tif (!is_array(self::$request->sel_options[$form_name])) self::$request->sel_options[$form_name] = array();\n\t\tif ($this->attrs['type'])\n\t\t{\n\t\t\t// += to keep further options set by app code\n\t\t\tself::$request->sel_options[$form_name] += self::typeOptions($this->attrs['type'], $this->attrs['options'],\n\t\t\t\t$no_lang=null, $this->attrs['readonly'], self::get_array(self::$request->content, $form_name));\n\n\t\t\t// if no_lang was modified, forward modification to the client\n\t\t\tif ($no_lang != $this->attr['no_lang'])\n\t\t\t{\n\t\t\t\tself::setElementAttribute($form_name, 'no_lang', $no_lang);\n\t\t\t}\n\t\t}\n\n\t\t// Make sure &nbsp;s, etc. are properly encoded when sent, and not double-encoded\n\t\tforeach(self::$request->sel_options[$form_name] as &$label)\n\t\t{\n\t\t\tif(!is_array($label))\n\t\t\t{\n\t\t\t\t$label = html_entity_decode($label, ENT_NOQUOTES,'utf-8');\n\t\t\t}\n\t\t\telseif($label['label'])\n\t\t\t{\n\t\t\t\t$label['label'] = html_entity_decode($label['label'], ENT_NOQUOTES,'utf-8');\n\t\t\t}\n\t\t}\n\n\t}", "private function composeControlPanel()\n {\n $this->composeControlPanelSideMenu();\n $this->composeControlPanelImagesBrowser();\n }", "public function postRender()\n {\n }", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Video Testimonials Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'vid_testimonial_view',\n [\n 'label' => __('Style', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'view1',\n 'options' => [\n 'view1' => __('Style 1', 'careerfy-frame'),\n 'view2' => __('Style 2', 'careerfy-frame'),\n 'view3' => __('Style 3', 'careerfy-frame'),\n ],\n ]\n );\n\n $repeater = new \\Elementor\\Repeater();\n $repeater->add_control(\n 'vid_testimonial_img', [\n 'label' => __('Image', 'careerfy-frame'),\n 'type' => Controls_Manager::MEDIA,\n 'label_block' => true,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n ]\n );\n\n $repeater->add_control(\n 'vid_url', [\n 'label' => __('Video URL', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n \"description\" => __(\"Put Video URL of Vimeo, Youtube.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_title', [\n 'label' => __('Client Name', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('client Title will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n\n $repeater->add_control(\n 'rank_title', [\n 'label' => __('Client Rank', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __('Client Rank will be applied on style 1 and style 3.', \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'company_title', [\n 'label' => __('Client Company', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Company will be applied to style 1 and style 2.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'testimonial_desc', [\n 'label' => __('Description', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXTAREA,\n 'label_block' => true,\n \"description\" => __(\"Testimonial Description will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n\n $repeater->add_control(\n 'client_location', [\n 'label' => __('Client Location', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'label_block' => true,\n \"description\" => __(\"Client Location will be applied to style 3 only.\", \"careerfy-frame\")\n ]\n );\n $this->add_control(\n 'careerfy_video_testimonial_item',\n [\n 'label' => __('Add video testimonial item', 'careerfy-frame'),\n 'type' => Controls_Manager::REPEATER,\n 'fields' => $repeater->get_controls(),\n 'title_field' => '{{{ company_title }}}',\n ]\n );\n $this->end_controls_section();\n }", "function preinit()\r\n {\r\n //Calls children's init recursively\r\n reset($this->components->items);\r\n while (list($k,$v)=each($this->components->items))\r\n {\r\n $v->preinit();\r\n }\r\n }", "public function beforeRender(){\n\n //render edit form with actual values from database\n $component_iterator = $this->getComponent(\"editForm\")->getComponents();\n $componenty = iterator_to_array($component_iterator);\n\n if ($this->actualListingValues != null){\n \n $optArray = $this->postageOptions;\n $postageCounter = $priceCounter = 0;\n \n foreach ($componenty as $comp){\n switch($comp->name){\n \n case 'product_name':\n $comp->setValue($this->actualListingValues['product_name']);\n break;\n case 'product_desc':\n $comp->setValue($this->actualListingValues['product_desc']);\n break;\n case 'price':\n $comp->setValue($this->actualListingValues['price']);\n break;\n case 'ships_from':\n $comp->setValue($this->actualListingValues['ships_from']);\n break;\n case 'ships_to';\n $comp->setValue($this->actualListingValues['ships_to']);\n break;\n case 'product_type':\n $comp->setValue($this->actualListingValues['ships_to']);\n break;\n case (strpos($comp->name, \"postage\")):\n //render all postage options into correct textboxes\n if (array_key_exists($postageCounter, $optArray)){\n $comp->setValue($optArray[$postageCounter]['option']);\n $postageCounter++;\n }\n break; \n case (strpos($comp->name, \"pprice\")):\n //render postage prices into correct textboxes\n if (array_key_exists($priceCounter, $optArray)){\n $comp->setValue($optArray[$priceCounter]['price']);\n $priceCounter++; \n } \n break; \n }\n }\n }\n \n $urlPath = $this->URL->path;\n \n //template variables shared between templates\n if ( strpos($urlPath, \"edit\" )|| strpos($urlPath, \"view\") \n || strpos($urlPath, \"buy\")){\n \n $lst = $this->hlp->sess(\"listing\");\n $imgs = $this->hlp->sess(\"images\");\n $this->template->listingDetails = $lst->listingDetails;\n $this->template->listingImages = $imgs->listingImages;\n }\n }", "function createChildrenRecursive() {\n $this->CreateChildControls();\n if ($this->HasControls()) {\n $keys = array_keys($this->Controls);\n $count = count($this->Controls);\n for ($i = 0; $i < $count; $i++) {\n @$control = &$this->Controls[$keys[$i]];\n $control->createChildrenRecursive();\n }\n }\n $this->initChildrenRecursive();\n }", "public function _setProps() {\n $dataController = get_called_class();\n $dataController::_getMapper();\n $dataController::_getModel();\n }", "function SetTreeData($data){\n $this->InitControl($data);\n\n }", "protected function _register_controls()\r\n {\r\n\r\n\r\n $this->start_controls_section(\r\n 'slider_settings_section',\r\n [\r\n 'label' => esc_html__('Query Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_CONTENT,\r\n ]\r\n );\r\n $this->add_control(\r\n 'column',\r\n [\r\n 'label' => esc_html__('Column', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n '3' => esc_html__('04 Column', 'aapside-master'),\r\n '4' => esc_html__('03 Column', 'aapside-master'),\r\n '2' => esc_html__('06 Column', 'aapside-master')\r\n ),\r\n 'label_block' => true,\r\n 'description' => esc_html__('select grid column', 'aapside-master'),\r\n 'default' => '4'\r\n ]\r\n );\r\n $this->add_control(\r\n 'total',\r\n [\r\n 'label' => esc_html__('Total Post', 'aapside-master'),\r\n 'type' => Controls_Manager::TEXT,\r\n 'description' => esc_html__('enter how many post you want to show, enter -1 for unlimited', 'aapside-master'),\r\n 'default' => '-1'\r\n ]\r\n );\r\n $this->add_control(\r\n 'category',\r\n [\r\n 'label' => esc_html__('Category', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT2,\r\n 'multiple' => true,\r\n 'label_block' => true,\r\n 'description' => esc_html__('select category, for all category leave it blank', 'aapside-master'),\r\n 'options' => appside_master()->get_terms_names('portfolio-cat', 'id', true)\r\n ]\r\n );\r\n $this->add_control(\r\n 'orderby',\r\n [\r\n 'label' => esc_html__('Order By', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ID' => esc_html__('ID', 'aapside-master'),\r\n 'title' => esc_html__('Title', 'aapside-master'),\r\n 'date' => esc_html__('Date', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order by', 'aapside-master'),\r\n 'default' => 'ID'\r\n ]\r\n );\r\n $this->add_control(\r\n 'order',\r\n [\r\n 'label' => esc_html__('Order', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'ASC' => esc_html__('Ascending', 'aapside-master'),\r\n 'DESC' => esc_html__('Descending', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('select order.', 'aapside-master'),\r\n 'default' => 'ASC'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination',\r\n [\r\n 'label' => esc_html__('Pagination', 'aapside-master'),\r\n 'type' => Controls_Manager::SWITCHER,\r\n 'description' => esc_html__('you can set yes to show pagination.', 'aapside-master'),\r\n 'default' => 'yes'\r\n ]\r\n );\r\n $this->add_control(\r\n 'pagination_alignment',\r\n [\r\n 'label' => esc_html__('Pagination Alignment', 'aapside-master'),\r\n 'type' => Controls_Manager::SELECT,\r\n 'options' => array(\r\n 'left' => esc_html__('Left Align', 'aapside-master'),\r\n 'center' => esc_html__('Center Align', 'aapside-master'),\r\n 'right' => esc_html__('Right Align', 'aapside-master'),\r\n ),\r\n 'description' => esc_html__('you can set pagination alignment.', 'aapside-master'),\r\n 'default' => 'left',\r\n 'condition' => array('pagination' => 'yes')\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n $this->start_controls_section(\r\n 'thumbnail_settings_section',\r\n [\r\n 'label' => esc_html__('Thumbnail Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_control('thumb_border_radius', [\r\n 'label' => esc_html__('Border Radius', 'aapside-master'),\r\n 'type' => Controls_Manager::DIMENSIONS,\r\n 'size_units' => ['px', '%', 'em'],\r\n 'selectors' => [\r\n \"{{WRAPPER}} .hard-single-item-02 .thumb img\" => \"border-radius:{{TOP}}{{UNIT}} {{RIGHT}}{{UNIT}} {{BOTTOM}}{{UNIT}} {{LEFT}}{{UNIT}};\"\r\n ]\r\n ]);\r\n $this->add_control(\r\n 'thumbnail_bottom_gap',\r\n [\r\n 'label' => esc_html__('Thumbnail Bottom Gap', 'aapside-master'),\r\n 'type' => Controls_Manager::SLIDER,\r\n 'size_units' => ['px', '%'],\r\n 'range' => [\r\n 'px' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n 'step' => 1,\r\n ],\r\n '%' => [\r\n 'min' => 0,\r\n 'max' => 100,\r\n ],\r\n ],\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .thumb' => 'margin-bottom: {{SIZE}}{{UNIT}};',\r\n ],\r\n ]\r\n );\r\n $this->end_controls_section();\r\n\r\n\r\n /* title styling tabs start */\r\n $this->start_controls_section(\r\n 'title_settings_section',\r\n [\r\n 'label' => esc_html__('Title Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->start_controls_tabs(\r\n 'style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('title_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('title_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .title:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n\r\n /* title styling tabs end */\r\n\r\n /* readmore styling tabs start */\r\n $this->start_controls_section(\r\n 'readmore_settings_section',\r\n [\r\n 'label' => esc_html__('Category Styling', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'readmore_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'readmore_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('readmore_hover_color', [\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'type' => Controls_Manager::COLOR,\r\n 'selectors' => [\r\n '{{WRAPPER}} .hard-single-item-02 .content .catagory a:hover' => \"color:{{VALUE}}\"\r\n ]\r\n ]);\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* readmore styling tabs end */\r\n\r\n /* pagination styling tabs start */\r\n $this->start_controls_section(\r\n 'pagination_settings_section',\r\n [\r\n 'label' => esc_html__('Pagination Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n\r\n $this->start_controls_tabs(\r\n 'pagination_style_tabs'\r\n );\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_normal_tab',\r\n [\r\n 'label' => __('Normal', 'aapside-master'),\r\n ]\r\n );\r\n\r\n $this->add_control('pagination_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination` ul li a\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a, {{WRAPPER}} .portfolio-pagination ul li span\"\r\n ]);\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->start_controls_tab(\r\n 'pagination_style_hover_tab',\r\n [\r\n 'label' => __('Hover', 'aapside-master'),\r\n ]\r\n );\r\n $this->add_control('pagination_hover_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_border_color', [\r\n 'type' => Controls_Manager::COLOR,\r\n 'label' => esc_html__('Border Color', 'aapside-master'),\r\n 'selectors' => [\r\n \"{{WRAPPER}} .portfolio-pagination ul li a:hover\" => \"border-color: {{VALUE}}\",\r\n \"{{WRAPPER}} .portfolio-pagination ul li span.current\" => \"border-color: {{VALUE}}\",\r\n ]\r\n ]);\r\n $this->add_control('pagination_hover_hr', [\r\n 'type' => Controls_Manager::DIVIDER\r\n ]);\r\n $this->add_group_control(Group_Control_Background::get_type(), [\r\n 'name' => 'pagination_hover_background',\r\n 'label' => esc_html__('Background', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .portfolio-pagination ul li a:hover, {{WRAPPER}} .Portfolio-pagination ul li span.current\"\r\n ]);\r\n\r\n\r\n $this->end_controls_tab();\r\n\r\n $this->end_controls_tabs();\r\n\r\n $this->end_controls_section();\r\n /* pagination styling tabs end */\r\n\r\n /* Typography tabs start */\r\n $this->start_controls_section(\r\n 'typography_settings_section',\r\n [\r\n 'label' => esc_html__('Typography Settings', 'aapside-master'),\r\n 'tab' => Controls_Manager::TAB_STYLE,\r\n ]\r\n );\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'title_typography',\r\n 'label' => esc_html__('Title Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .title\"\r\n ]);\r\n $this->add_group_control(Group_Control_Typography::get_type(), [\r\n 'name' => 'post_meta_typography',\r\n 'label' => esc_html__('Category Typography', 'aapside-master'),\r\n 'selector' => \"{{WRAPPER}} .hard-single-item-02 .content .cats\"\r\n ]);\r\n $this->end_controls_section();\r\n\r\n /* Typography tabs end */\r\n }", "protected function _beforeRender()\r\n {\r\n $this->_element->setAttributes($this->getAttribs());\r\n }", "protected function _register_controls()\n {\n $this->tab_content();\n $this->tab_style();\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater = new Repeater();\n\n\t\t$repeater->add_control(\n\t\t\t'client_logo',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Choose Image', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => Utils::get_placeholder_image_src(),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_name',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Title', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'default' => __( 'Client Name', 'elementive' ),\n\t\t\t\t'placeholder' => __( 'Type your client name here', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$repeater->add_control(\n\t\t\t'client_link',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Link', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-client.com', 'elementive' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => array(\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'clients',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Clients List', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'fields' => $repeater->get_controls(),\n\t\t\t\t'default' => array(),\n\t\t\t\t'title_field' => '{{{ client_name }}}',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_style',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_STYLE,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'max_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Logo max width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 600,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 120,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo img' => 'max-width : {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'style_tabs'\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 0.5,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'style_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'grayscale_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Crayscale', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'opacity_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Opacity', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 1,\n\t\t\t\t\t\t'step' => 0.1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-clients-grid .elementive-client-grid-logo:hover' => 'opacity : {{SIZE}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->end_controls_section();\n\n\t\t$this->start_controls_section(\n\t\t\t'section_carousel',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Carousel', 'elementive' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_SETTINGS,\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'vertical_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Vertical align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-flex-top',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-flex-top' => __( 'Top', 'elementive' ),\n\t\t\t\t\t'uk-flex-middle' => __( 'Middle', 'elementive' ),\n\t\t\t\t\t'uk-flex-bottom' => __( 'Bottom', 'elementive' ),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'auto_play',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Enable auto play', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'elementive' ),\n\t\t\t\t'label_off' => __( 'No', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t\t'separator' => 'after',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'columns',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Columns', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 6,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 2,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 1,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'margins',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Column margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array(),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'tablet_default' => array(\n\t\t\t\t\t'size' => 30,\n\t\t\t\t),\n\t\t\t\t'mobile_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'overflow',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Overflow', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Loop', 'elementive' ),\n\t\t\t\t'description' => __( 'Set to yes to enable continuous loop mode', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'centered',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Centered slider', 'elementive' ),\n\t\t\t\t'description' => __( 'If yes, then active slide will be centered, not always on the left side.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'speed',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Speed', 'elementive' ),\n\t\t\t\t'description' => __( 'Speed of the enter/exit transition.', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 10,\n\t\t\t\t\t\t'max' => 1000,\n\t\t\t\t\t\t'step' => 10,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'default' => array(\n\t\t\t\t\t'size' => 500,\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Navigation', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_diameter_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Diameter', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 30,\n\t\t\t\t\t\t'max' => 200,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 40,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation ' => 'width: {{SIZE}}{{UNIT}}; height: {{SIZE}}{{UNIT}}; line-height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_icon_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Icon width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 10,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'navigation_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'navigation_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'navigation_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Hover', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'navigation_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover svg' => 'color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Background::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_background_hover',\n\t\t\t\t'label' => __( 'Background', 'elementive' ),\n\t\t\t\t'types' => array( 'classic', 'gradient' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation .navigation-background-hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'navigation_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'navigation' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .elementive-carousel-navigation:hover',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t$this->add_control(\n\t\t\t'pagination',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Pagination', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'True', 'elementive' ),\n\t\t\t\t'label_off' => __( 'False', 'elementive' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'separator' => 'before',\n\t\t\t\t'default' => '',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_bullet_align',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet align', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => 'uk-text-center',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'uk-text-center' => __( 'Center', 'elementive' ),\n\t\t\t\t\t'uk-text-left' => __( 'Left', 'elementive' ),\n\t\t\t\t\t'uk-text-right' => __( 'Right', 'elementive' ),\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bottom',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bottom size', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => -100,\n\t\t\t\t\t\t'max' => 100,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 0,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .elementive-carousel-pagination ' => 'bottom: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_margin',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet margin', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 3,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'margin: 0 {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_width',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 3,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_bullet_height',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet height', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 1,\n\t\t\t\t\t\t'max' => 20,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 5,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet ' => 'height: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_radius',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Border radius', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 0,\n\t\t\t\t\t\t'max' => 10,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'border-radius: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tabs(\n\t\t\t'pagination_tabs',\n\t\t\tarray(\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_normal_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Normal', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination_diameter' => 'yes',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->start_controls_tab(\n\t\t\t'pagination_hover_tab',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Active', 'elementive' ),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_responsive_control(\n\t\t\t'pagination_diameter_width_active',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Bullet width', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::SLIDER,\n\t\t\t\t'size_units' => array( 'px' ),\n\t\t\t\t'range' => array(\n\t\t\t\t\t'px' => array(\n\t\t\t\t\t\t'min' => 5,\n\t\t\t\t\t\t'max' => 40,\n\t\t\t\t\t\t'step' => 1,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t'devices' => array( 'desktop', 'tablet', 'mobile' ),\n\t\t\t\t'desktop_default' => array(\n\t\t\t\t\t'size' => 8,\n\t\t\t\t\t'unit' => 'px',\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'width: {{SIZE}}{{UNIT}};',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'pagination_color_hover',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Color', 'elementive' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'scheme' => array(\n\t\t\t\t\t'type' => Scheme_Color::get_type(),\n\t\t\t\t\t'value' => Scheme_Color::COLOR_2,\n\t\t\t\t),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selectors' => array(\n\t\t\t\t\t'{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active' => 'background-color: {{VALUE}}',\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Border::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_border_hover',\n\t\t\t\t'label' => __( 'Border', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t)\n\t\t);\n\n\t\t$this->add_group_control(\n\t\t\tGroup_Control_Box_Shadow::get_type(),\n\t\t\tarray(\n\t\t\t\t'name' => 'pagination_box_shadow_hover',\n\t\t\t\t'label' => __( 'Box Shadow', 'elementive' ),\n\t\t\t\t'condition' => array(\n\t\t\t\t\t'pagination' => 'true',\n\t\t\t\t),\n\t\t\t\t'selector' => '{{WRAPPER}} .elementive-carousel .swiper-pagination-bullet-active',\n\t\t\t\t'separator' => 'before',\n\t\t\t)\n\t\t);\n\n\t\t$this->end_controls_tab();\n\n\t\t$this->end_controls_tabs();\n\n\t\t// End carousel navigation section.\n\t\t$this->end_controls_section();\n\t}", "public function beforeRender()\n {\n $controller = $this->_registry->getController();\n\n $this->addToController($controller);\n }", "function XmlControlOnRender(&$xmlWriter){\n if ($this->debug_mode) echo $this->ClassName . '::XmlControlOnRender(&$xmlWriter);' . \"<HR>\";\n\n $xmlWriter->WriteElementString(\"_PageTitle\", $this->Kernel->Localization->GetItem(strtoupper($this->library_ID), \"_EDIT_TITLE\"));\n $xmlWriter->WriteElementString(\"list_handler\", $this->listHandler);\n if ($this->disabled_delete)\n \t$xmlWriter->WriteElementString(\"disabled_delete\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_delete\", \"no\");\n\n if ($this->disabled_edit)\n $xmlWriter->WriteElementString(\"disabled_edit\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_edit\", \"no\");\n\n if ($this->disabled_add)\n $xmlWriter->WriteElementString(\"disabled_add\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_add\", \"no\");\n\n if ($this->disabled_copy)\n $xmlWriter->WriteElementString(\"disabled_copy\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_copy\", \"no\");\n\n if (strlen($this->icon_file))\n $xmlWriter->WriteElementString(\"icon_file\", $this->icon_file);\n\n if ((($this->event == \"AddItem\") || ($this->event == \"DoAddItem\")) && $this->disabled_add) {\n $xmlWriter->WriteElementString(\"disabled_button\", \"yes\");\n } else {\n if ((($this->event == \"EditItem\") || ($this->event == \"DoEditItem\")) && $this->disabled_edit)\n $xmlWriter->WriteElementString(\"disabled_button\", \"yes\");\n else\n $xmlWriter->WriteElementString(\"disabled_button\", \"no\");\n }\n parent::XmlControlOnRender($xmlWriter);\n }", "function ControlOnLoad(){\n if ($this->debug_mode)\n echo $this->ClassName . \"::ControlOnLoad();\" . \"<HR>\";\n parent::ControlOnLoad();\n $this->Kernel->ImportClass(\"web.controls.\" . $this->editcontrol, $this->editcontrol);\n $this->error = 0;\n $this->library_ID = $this->Request->ToString(\"library\", \"\");\n if (! strlen($this->library_ID)) {\n $this->library_ID = $this->Kernel->Package->Settings->GetItem(\"main\", \"LibraryName\");\n }\n\n //$_library_path = $this->Page->Kernel->Package->Settings->GetItem(\"MAIN\", \"LibrariesRoot\");\n $this->listSettings = Engine::getLibrary($this->Kernel, $this->library_ID, \"ListSettings\");\n $this->listSettings->reParse();\n $this->Package=Engine::GetPackageName();\n $this->item_id = $this->Request->ToString(\"item_id\", \"0\");\n $this->is_context_frame = $this->Request->ToNumber(\"contextframe\", \"0\");\n\n\t\t$this->event = $this->Request->Value(\"event\");\n\t\tif (substr($this->event, 0,4)==\"DoDo\"){\n $this->event=$this->Event=substr($this->event, 2, strlen($this->event)-2);\n $this->Request->SetValue(\"event\", $this->event);\n\t\t}\n\n $this->start = $this->Request->ToNumber($this->library_ID . \"_start\", 0);\n $this->order_by = $this->Request->Value($this->library_ID . \"_order_by\");\n $this->restore = $this->Request->Value(\"restore\");\n\n $this->parent_id = $this->Request->ToNumber($this->library_ID . \"_parent_id\", 0);\n $this->custom_val = $this->Request->Value(\"custom_val\");\n $this->custom_var = $this->Request->Value(\"custom_var\");\n $this->host_library_ID = $this->Request->Value(\"host_library_ID\");\n $this->LibrariesRoot = $this->Kernel->Package->Settings->GetItem(\"main\", \"LibrariesRoot\");\n $this->checkLibraryAccess();\n }", "function updateControl()\r\n {\r\n if (($this->ControlState & csDesigning)!=csDesigning)\r\n {\r\n //Ensure there is a valid datasource\r\n $this->setDataSource($this->_datasource);\r\n\r\n if (is_object($this->_datasource))\r\n {\r\n $ds=$this->_datasource->DataSet;\r\n\r\n if ($ds->Active)\r\n {\r\n $ds->first();\r\n $fields=$ds->Fields;\r\n?>\r\n var <?php echo $this->Name; ?>_tableModel=<?php echo $this->owner->Name.\".\".$this->Name; ?>_tableModel;\r\n <?php echo $this->Name; ?>_tableModel.setColumns([\r\n<?php\r\n if (count($this->_columns)>=1)\r\n {\r\n reset($this->_columns);\r\n $i=0;\r\n while(list($key, $val)=each($this->_columns))\r\n {\r\n $fname=$val['Fieldname'];\r\n if ($fname!=\"\")\r\n {\r\n $props=$this->_datasource->DataSet->readFieldProperties($fname);\r\n }\r\n $dlabel=$val['Caption'];\r\n\r\n if ($props)\r\n {\r\n if (array_key_exists('displaylabel',$props))\r\n {\r\n $dlabel=$props['displaylabel'][0];\r\n }\r\n }\r\n\r\n if ($i>0) echo \",\";\r\n echo '\"'.$dlabel.'\"';\r\n $i++;\r\n\r\n }\r\n }\r\n else if (is_array($fields))\r\n {\r\n reset($fields);\r\n $i=0;\r\n while(list($fname, $value)=each($fields))\r\n {\r\n $props=$this->_datasource->DataSet->readFieldProperties($fname);\r\n $dlabel=$fname;\r\n\r\n if ($props)\r\n {\r\n if (array_key_exists('displaylabel',$props))\r\n {\r\n $dlabel=$props['displaylabel'][0];\r\n }\r\n }\r\n\r\n if ($i>0) echo \",\";\r\n echo '\"'.$dlabel.'\"';\r\n $i++;\r\n }\r\n }\r\n?>\r\n ]);\r\n\r\n\r\n <?php echo $this->Name; ?>_tableModel.ColumnNames=new Array(\r\n<?php\r\n $cnames=$ds->Fields;\r\n if (count($this->_columns))\r\n {\r\n $cnames=array();\r\n reset($this->_columns);\r\n while(list($key, $val)=each($this->_columns))\r\n {\r\n $cnames[$val['Fieldname']]='1';\r\n }\r\n }\r\n\r\n if (is_array($cnames))\r\n {\r\n reset($cnames);\r\n $i=0;\r\n while(list($fname, $value)=each($cnames))\r\n {\r\n if ($i>0) echo \",\";\r\n echo '\"'.$fname.'\"';\r\n $i++;\r\n }\r\n }\r\n?>\r\n);\r\n\r\n\r\n\r\n var rowData = [];\r\n var oData = [];\r\n<?php\r\n $colvalues=array();\r\n\r\n if (count($this->_columns)>=1)\r\n {\r\n reset($this->_columns);\r\n while(list($key, $val)=each($this->_columns))\r\n {\r\n $colvalues[$val['Fieldname']]=1;\r\n }\r\n\r\n }\r\n\r\n $ds->first();\r\n while (!$ds->EOF)\r\n {\r\n $rvalues=$ds->Fields;\r\n\r\n if (count($colvalues)>=1)\r\n {\r\n $avalues=array();\r\n reset($colvalues);\r\n while(list($key, $val)=each($colvalues))\r\n {\r\n $avalues[$key]=$rvalues[$key];\r\n }\r\n $rvalues=$avalues;\r\n }\r\n?>\r\n rowData.push([\r\n <?php\r\n reset($rvalues);\r\n $i=0;\r\n while (list($k,$v)=each($rvalues))\r\n {\r\n\r\n $v=str_replace(\"\\n\\r\",'\\n',$v);\r\n $v=str_replace(\"\\n\",'\\n',$v);\r\n $v=str_replace(\"\\r\",'',$v);\r\n $v=str_replace('\"','\\\"',$v);\r\n $v=str_replace(\"\\\\\",'\\\\',$v);\r\n $v=str_replace('<','\\<',$v);\r\n $v=str_replace('>','\\>',$v);\r\n if ($i>0) echo \",\";\r\n\r\n $numeric=false;\r\n if (count($this->_columns)>=1)\r\n {\r\n $sorttype=$this->_columns[$i]['SortType'];\r\n if ($sorttype=='stNumeric')\r\n {\r\n $numeric=true;\r\n }\r\n }\r\n if (!$numeric) echo '\"'.$v.'\"';\r\n else echo $v;\r\n\r\n $i++;\r\n\r\n }\r\n ?>\r\n ]);\r\n oData.push([\r\n <?php\r\n reset($rvalues);\r\n $i=0;\r\n while (list($k,$v)=each($rvalues))\r\n {\r\n if (count($colvalues)>=1)\r\n {\r\n if (!array_key_exists($k,$colvalues)) continue;\r\n }\r\n\r\n $v=str_replace(\"\\n\\r\",'\\n',$v);\r\n $v=str_replace(\"\\n\",'\\n',$v);\r\n $v=str_replace(\"\\r\",'',$v);\r\n $v=str_replace('\"','\\\"',$v);\r\n $v=str_replace(\"\\\\\",'\\\\',$v);\r\n $v=str_replace('<','\\<',$v);\r\n $v=str_replace('>','\\>',$v);\r\n// $v=htmlentities($v);\r\n if ($i>0) echo \",\";\r\n echo '\"'.$v.'\"';\r\n $i++;\r\n\r\n }\r\n ?>\r\n ]);\r\n <?php\r\n $ds->next();\r\n }\r\n $ds->first();\r\n\r\n?>\r\n <?php echo $this->Name; ?>_tableModel.originalData=oData;\r\n <?php echo $this->Name; ?>_tableModel.setData(rowData);\r\n<?php\r\n $this->_latestheader=$fields;\r\n\r\n if (count($this->_columns)>=1)\r\n {\r\n reset($this->_columns);\r\n $i=0;\r\n while(list($key, $value)=each($this->_columns))\r\n {\r\n $editable='true';\r\n if ($value['ReadOnly']=='true') $editable='false';\r\n\r\n if ($this->_readonly) $editable='false';\r\n?>\r\n <?php echo $this->Name; ?>_tableModel.setColumnEditable(<?php echo $i; ?>, <?php echo $editable; ?>);\r\n<?php\r\n $i++;\r\n }\r\n\r\n }\r\n else if (is_array($fields))\r\n {\r\n reset($fields);\r\n $i=0;\r\n while(list($fname, $value)=each($fields))\r\n {\r\n $editable='true';\r\n if ($this->_readonly) $editable='false';\r\n?>\r\n <?php echo $this->Name; ?>_tableModel.setColumnEditable(<?php echo $i; ?>, <?php echo $editable; ?>);\r\n<?php\r\n $i++;\r\n }\r\n\r\n\r\n }\r\n }\r\n }\r\n }\r\n }", "protected function register_controls() {\n\n\t\t$this->render_team_member_content_control();\n\t\t$this->register_content_separator();\n\t\t$this->register_content_social_icons_controls();\n\t\t$this->register_helpful_information();\n\n\t\t/* Style */\n\t\t$this->register_style_team_member_image();\n\t\t$this->register_style_team_member_name();\n\t\t$this->register_style_team_member_designation();\n\t\t$this->register_style_team_member_desc();\n\t\t$this->register_style_team_member_icon();\n\t\t$this->register_content_spacing_control();\n\t}", "function ControlOnInit() {\n }", "protected function _handle_forms()\n\t{\n\t\tif (!strlen($this->_form_posted)) return;\n\t\t$method = 'on_'.$this->_form_posted.'_submit';\n\n\t\tif (method_exists($this, $method))\n\t\t{\n\t\t\tcall_user_func(array($this, $method), $this->_form_action);\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ($this->controls as $k=>$v)\n\t\t{\n\t\t\t$ctl = $this->controls[$k];\n\n\t\t\tif (method_exists($ctl, $method))\n\t\t\t{\n\t\t\t\t$ctl->page = $this;\n\t\t\t\tcall_user_func(array($ctl, $method), $this->_form_action);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\tif (DEBUG) dwrite(\"Method '$method' not defined\");\n\t}", "function AddControl(&$object) {\n if (!is_object($object)) {\n return;\n }\n //if (is_object($object->Parent))\n //$object->Parent->RemoveControl($object);\n $object->Parent = &$this;\n $object->Page = &$this->Page;\n @$this->Controls[$object->Name] = &$object;\n if ($this->_state >= WEB_CONTROL_INITIALIZED) {\n $object->initRecursive();\n if ($this->_state >= WEB_CONTROL_LOADED)\n $object->loadRecursive();\n }\n }", "public function onRun()\n {\n $this->page['visible'] = $this->property('visible');\n $this->page['button'] = $this->property('button');\n }", "function _setFormElements() {\n\t\t$jobCategories = $this->Job->JobCategory->find('list');\n\t\t$jobLocations = $this->Job->JobLocation->find('list');\n\t\t$this->set(compact('jobCategories', 'jobLocations'));\n\t}", "public function preinit()\n\t{\n\t\t//\tCreate our internal name\n\t\tCPSHelperBase::createInternalName( $this );\n\n\t\t//\tAttach our default Behavior\n\t\t$this->attachBehavior( 'psWidget', 'pogostick.behaviors.CPSWidgetBehavior' );\n\t}", "function OnBeforeCreateEditControl(){\n }", "function setDataControl(Pwg_I_Control_RecordsDisplay $v) {\n \t$res = parent::setDataControl($v);\n \t$this->refreshRecordPrototypeOfDataControl();\n \treturn $res;\r\n }", "public function build_controls()\n {\n $this->add_control( 'id', [\n 'label' => __( 'Post', 'customize-static-layout' ),\n 'type' => 'object_selector',\n 'post_query_vars' => static::get_post_query_vars(),\n 'select2_options' => [\n 'allowClear' => true,\n 'placeholder' => __( '&mdash; Select &mdash;', 'customize-static-layout' ),\n ],\n ], 'CustomizeObjectSelector\\Control' );\n }", "protected function _register_controls() {\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Clients Settings', 'elementor-main-clients' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t 'clients-columns',\n\t\t \t[\n\t\t \t'label' \t=> esc_html__( 'Column', 'essential-addons-elementor' ),\n\t\t \t'type' \t\t\t=> Controls_Manager::SELECT,\n\t\t \t'default' \t\t=> '2',\n\t\t \t'options' \t\t=> [\t\t\t\t\n\t\t\t\t\t'1' => esc_html__('1 Column', 'baldiyaat'),\n\t\t\t\t\t'2' => esc_html__('2 Column', 'baldiyaat'),\n\t\t\t\t\t'3' => esc_html__('3 Column', 'baldiyaat'),\n\t\t\t\t\t'4' => esc_html__('4 Column', 'baldiyaat'),\n\t\t\t\t\t'6' => esc_html__('6 Column', 'baldiyaat')\n\t\t \t],\n\t\t \t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'thumbnail-size',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Thumbnail Size', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'label_block' \t=> false,\n\t\t\t\t'default' => esc_html__( 'hide', 'essential-addons-elementor' ),\n\t\t \t'options' => wpha_get_thumbnail_list(),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'num-fetch',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Num Fetch', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t'label_block' => false,\n\t\t\t\t'default' => 10,\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_config_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Clients Images', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'slider',\n\t\t\t[\n\t\t\t\t'type' => Controls_Manager::REPEATER,\n\t\t\t\t'seperator' => 'before',\n\t\t\t\t'default' => [\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t\t[ 'main_clients_settings_slide' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png' ],\n\t\t\t\t],\n\t\t\t\t'fields' => [\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide',\n\t\t\t\t\t\t'label' => esc_html__( 'Image', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::MEDIA,\n\t\t\t\t\t\t'default' => [\n\t\t\t\t\t\t\t'url' => KODEFOREST_MAIN_URL . 'assets/clients/simple-clients.png',\n\t\t\t\t\t\t],\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_title',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Title', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_caption',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Caption', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::TEXT,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => esc_html__( '', 'essential-addons-elementor' )\n\t\t\t\t\t],\n\t\t\t\t\t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_enable_slide_link',\n\t\t\t\t\t\t'label' => __( 'Enable Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t\t\t'default' => 'false',\n\t\t\t\t\t\t'label_on' => esc_html__( 'Yes', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'label_off' => esc_html__( 'No', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'return_value' => 'true',\n\t\t\t\t\t\t\n\t\t\t\t \t],\n\t\t\t\t \t[\n\t\t\t\t\t\t'name' => 'main_clients_settings_slide_link',\n\t\t\t\t\t\t'label' => esc_html__( 'Image Link', 'essential-addons-elementor' ),\n\t\t\t\t\t\t'type' => Controls_Manager::URL,\n\t\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t\t'default' => [\n\t\t \t\t\t'url' => '#',\n\t\t \t\t\t'is_external' => '',\n\t\t \t\t\t],\n\t\t \t\t\t'show_external' => true,\n\t\t \t\t\t'condition' => [\n\t\t \t\t\t\t'main_clients_settings_enable_slide_link' => 'true'\n\t\t \t\t\t]\n\t\t\t\t\t]\n\t\t\t\t],\n\t\t\t\t'title_field' => '{{main_clients_settings_slide_title}}',\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\t\t\n\t\t/**\n\t\t * Clients Text Settings\n\t\t */\n\t\t$this->start_controls_section(\n\t\t\t'main_clients_color_settings',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Color & Design', 'essential-addons-elementor' ),\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_sub_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Sub Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .kode-sub-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_title_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Title Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-title' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_caption_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Caption Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .slide-caption-des' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->add_control(\n\t\t\t'main_clients_button_bg_color',\n\t\t\t[\n\t\t\t\t'label' => esc_html__( 'Image Button BG Color', 'essential-addons-elementor' ),\n\t\t\t\t'type' => Controls_Manager::COLOR,\n\t\t\t\t'default' => '#f4f4f4',\n\t\t\t\t'selectors' => [\n\t\t\t\t\t'{{WRAPPER}} .slide-item .slide-caption .banner_text_btn .bg-color' => 'background-color: {{VALUE}};',\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\t\t\n\t\t$this->end_controls_section();\n\t\t\n\t\t\n\t}", "public function definition_after_data() {\n parent::definition_after_data();\n $this->_form->freeze(['type']);\n $this->tool->form_definition_after_data($this->_form);\n }", "public function output_widget_control_templates()\n {\n }", "function initControls()\n {\n\n $this->map->getControls()->getMaptype()->setDisplay((boolean) $this->showMapType);\n\n $this->map->getControls()->getMaptype()->setPosition($this->mapTypePosition);\n $this->map->getControls()->getMaptype()->setType($this->mapTypeType);\n\n $this->map->getControls()->getScale()->setDisplay((boolean) $this->showScale);\n $this->map->getControls()->getScale()->setPosition($this->scalePosition);\n\n $this->map->getControls()->getNavigation()->setDisplay((boolean) $this->showNavigation);\n\n $this->map->getControls()->getNavigation()->setPosition($this->navigationPosition);\n\n $this->map->getControls()->getNavigation()->setType($this->navigationType);\n\n\n $this->map->getControls()->getZoom()->setDisplay((boolean) $this->showZoom);\n $this->map->getControls()->getZoom()->setPosition($this->zoomPosition);\n $this->map->getControls()->getZoom()->setType($this->zoomType);\n\n $this->map->getControls()->getPan()->setDisplay((boolean) $this->showPan);\n $this->map->getControls()->getPan()->setPosition($this->panPosition);\n\n if ($this->initialMapType)\n {\n $this->map->setMaptype(new Tx_Listfeusers_Gmap_Maptype($this->initialMapType));\n }\n\n }", "protected function _setForm()\n\t{\t\n\t\t$controller = $this->getActionController();\n\t\t\n\t\t$this->_setViewFormData($controller)\n\t\t\t ->_setViewErrors($controller)\n\t\t\t ->_setViewWarnings($controller);\n\t\t\t\n\t}", "function populate() {\n $this->populateInputElements($this->children);\n }", "function CreateChildControls(){\n parent::CreateChildControls();\n $this->AddControl(new SitemapControl(\"cms_sitemap\", \"cms_sitemap\"));\n }", "protected function RenderAjax() {\r\n\t\t\t$strToReturn = '<controls>';\r\n\r\n\t\t\t// Include each control (if applicable) that has been changed/modified\r\n\t\t\tforeach ($this->GetAllControls() as $objControl)\r\n\t\t\t\tif (!$objControl->ParentControl)\r\n//\t\t\t\t\t$strToReturn .= $objControl->RenderAjax(false) . \"\\r\\n\";\r\n\t\t\t\t\t$strToReturn .= $this->RenderAjaxHelper($objControl);\r\n\r\n\t\t\t$strCommands = '';\r\n\t\t\t\r\n\t\t\t// Look to the Application object for any commands to run\r\n\t\t\tforeach (QApplication::$AlertMessageArray as $strAlert) {\r\n\t\t\t\t$strAlert = QString::XmlEscape(sprintf('alert(\"%s\");', addslashes($strAlert)));\r\n\t\t\t\t$strCommands .= sprintf('<command>%s</command>', $strAlert);\r\n\t\t\t}\r\n\t\t\tforeach (QApplication::$JavaScriptArrayHighPriority as $strJavaScript) {\r\n\t\t\t\t$strJavaScript = trim($strJavaScript);\r\n\t\t\t\t\r\n\t\t\t\tif (strlen($strJavaScript)) {\r\n\t\t\t\t\tif (QString::LastCharacter($strJavaScript) != ';')\r\n\t\t\t\t\t\t$strJavaScript .= ';';\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strJavaScript));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tforeach (QApplication::$JavaScriptArray as $strJavaScript) {\r\n\t\t\t\t$strJavaScript = trim($strJavaScript);\r\n\t\t\t\tif (strlen($strJavaScript)) {\r\n\t\t\t\t\tif (QString::LastCharacter($strJavaScript) != ';')\r\n\t\t\t\t\t\t$strJavaScript .= ';';\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strJavaScript));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t$strRegCJavaScript = '';\r\n\t\t\tforeach ($this->GetAllControls() as $objControl) {\r\n\t\t\t\tif ($objControl->Rendered) {\r\n\t\t\t\t\t$strRegCJavaScript .= sprintf('qc.regC(\"%s\"); ', $objControl->ControlId);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tif ($strRegCJavaScript)\r\n\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strRegCJavaScript));\r\n\r\n\t\t\tforeach ($this->GetAllControls() as $objControl) {\r\n\t\t\t\tif ($objControl->Rendered) {\r\n\t\t\t\t\t$strJavaScript = $objControl->GetEndScript();\r\n\t\t\t\t\tif (strlen($strJavaScript))\r\n\t\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($objControl->GetEndScript()));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\tforeach ($this->objGroupingArray as $objGrouping) {\r\n\t\t\t\t$strRender = $objGrouping->Render();\r\n\t\t\t\tif (trim($strRender))\r\n\t\t\t\t\t$strCommands .= sprintf('<command>%s</command>', QString::XmlEscape($strRender));\r\n\t\t\t}\r\n\r\n\t\t\t// Add in the form state\r\n\t\t\t// DO SOMETHING DIFFERENT IF FORM IS UseSession\r\n\t\t\t$strFormState = QForm::Serialize($this);\r\n\t\t\t$strToReturn .= sprintf('<control id=\"Qform__FormState\">%s</control>', $strFormState);\r\n\r\n\t\t\t// close Control collection, Open the Command collection\r\n\t\t\t$strToReturn .= '</controls><commands>';\r\n\t\t\t\r\n\t\t\t$strToReturn .= $strCommands;\r\n\r\n\t\t\t// close Command collection\r\n\t\t\t$strToReturn .= '</commands>';\r\n\r\n\t\t\t$strContents = trim(ob_get_contents());\r\n\r\n\t\t\tif (strtolower(substr($strContents, 0, 5)) == 'debug') {\r\n\t\t\t} else {\r\n\t\t\t\tob_clean();\r\n\r\n\t\t\t\t// Response is in XML Format\r\n\t\t\t\theader('Content-Type: text/xml');\r\n\r\n\t\t\t\t// Output it and update render state\r\n\t\t\t\tif (QApplication::$EncodingType)\r\n\t\t\t\t\tprintf(\"<?xml version=\\\"1.0\\\" encoding=\\\"%s\\\"?><response>%s</response>\\r\\n\", QApplication::$EncodingType, $strToReturn);\r\n\t\t\t\telse\r\n\t\t\t\t\tprintf(\"<?xml version=\\\"1.0\\\"?><response>%s</response>\\r\\n\", $strToReturn);\r\n\t\t\t}\r\n\r\n\t\t\t// Update Render State\r\n\t\t\t$this->intFormStatus = QFormBase::FormStatusRenderEnded;\r\n\t\t}", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'electro-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'electro-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'electro-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'electro-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'electro-extensions' ),\n 'return_value' => 'true',\n 'default' => 'false',\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'electro-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'electro-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'electro-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'electro-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'electro-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'electro-extensions' ),\n 'random' =>esc_html__( 'Random', 'electro-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'electro-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'electro-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'electro-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "protected function commit()\n {\n $commit = function(Control $ctrl) use(&$commit)\n {\n $this->vs[$ctrl->attr('id')] = $ctrl->getVS();\n $this->controls[$ctrl->attr('id')] = $ctrl;\n if ($ctrl instanceof Panel)\n {\n foreach ($ctrl as $uniqueID => $child)\n {\n $commit($child);\n }\n }\n };\n foreach ($this->controls as $ctrl) $commit($ctrl);\n }", "public function render_control_templates()\n {\n }", "protected function _prepareForm()\n {\n /** @var DataForm $form */\n /** @noinspection PhpUnhandledExceptionInspection */\n $form = $this->_formFactory->create();\n\n // define field set\n $fieldSet = $form->addFieldset('base_fieldset', ['legend' => __('Widget')]);\n\n // retrieve widget key\n $widgetKey = $this->widgetInstance->getWidgetKey();\n\n // add new field\n $fieldSet->addField(\n 'select_widget_type_' . $widgetKey,\n 'select',\n [\n 'label' => __('Widget Type'),\n 'title' => __('Widget Type'),\n 'name' => 'widget_type',\n 'required' => true,\n 'onchange' => \"$widgetKey.validateField()\",\n 'options' => $this->_getWidgetSelectOptions(),\n 'after_element_html' => $this->_getWidgetSelectAfterHtml()\n ]\n );\n\n // set form information\n /** @noinspection PhpUndefinedMethodInspection */\n $form->setUseContainer(true);\n /** @noinspection PhpUndefinedMethodInspection */\n $form->setId('widget_options_form' . '_' . $widgetKey);\n /** @noinspection PhpUndefinedMethodInspection */\n $form->setMethod('post');\n /** @noinspection PhpUndefinedMethodInspection */\n $form->setAction($this->getUrl('adminhtml/*/buildWidget'));\n $this->setForm($form);\n }", "function onLoad($param)\r\n\t{\r\n\t\tif (!$this->IsPostBack){\r\n\t\t\t$this->workerList->DataSource = $this->getWorkers();\r\n\t\t\t$this->workerList->dataBind();\r\n\t\t} \t\r\n\t}", "public function postDispatch()\n {\n if ($this->_shouldRender()) {\n $this->render();\n }\n }", "public function onPostSetData(FormEvent $event)\n {\n $data = $event->getData();\n if (!$this->isApplicable($data)) {\n return;\n }\n\n $propertyAccessor = PropertyAccess::createPropertyAccessor();\n $options = $event->getForm()['connectors']->getConfig()->getOptions();\n $class = $propertyAccessor->getValue($options, self::CLASS_PATH);\n\n $event->getForm()->remove('synchronizationSettings');\n\n FormUtils::replaceField(\n $event->getForm(),\n 'connectors',\n [\n 'attr' => [\n 'class' => implode(' ', [$class, 'hide'])\n ]\n ]\n );\n }", "function init()\r\n {\r\n //Copy components to comps, so you can alter components properties\r\n //on init() methods\r\n $comps=$this->components->items;\r\n //Calls children's init recursively\r\n reset($comps);\r\n while (list($k,$v)=each($comps))\r\n {\r\n $v->init();\r\n }\r\n }", "function populate() {\n // @todo We inject client input directly into the form. What about\n // security issues?\n if (isset($this->form->request['raw_input'][$this->attributes['name']])) {\n // Disabled input elements do not accept new input.\n if (!$this->disabled) {\n $this->value = $this->form->request['raw_input'][$this->attributes['name']];\n }\n }\n }", "protected function _register_controls()\n {\n\n global $rand_num;\n $rand_num = rand(10000000, 99909999);\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => __('Section Heading Settings', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n $this->add_control(\n 'view',\n [\n 'label' => __('Style', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'view1',\n 'options' => [\n 'view1' => __('Style 1', 'careerfy-frame'),\n 'view2' => __('Style 2', 'careerfy-frame'),\n 'view3' => __('Style 3', 'careerfy-frame'),\n 'view4' => __('Style 4', 'careerfy-frame'),\n 'view5' => __('Style 5', 'careerfy-frame'),\n 'view6' => __('Style 6', 'careerfy-frame'),\n 'view7' => __('Style 7', 'careerfy-frame'),\n 'view8' => __('Style 8', 'careerfy-frame'),\n 'view9' => __('Style 9', 'careerfy-frame'),\n 'view10' => __('Style 10', 'careerfy-frame'),\n 'view11' => __('Style 11', 'careerfy-frame'),\n 'view12' => __('Style 12', 'careerfy-frame'),\n 'view13' => __('Style 13', 'careerfy-frame'),\n 'view14' => __('Style 14', 'careerfy-frame'),\n 'view15' => __('Style 15', 'careerfy-frame'),\n 'view16' => __('Style 16', 'careerfy-frame'),\n 'view17' => __('Style 17', 'careerfy-frame'),\n 'view18' => __('Style 18', 'careerfy-frame'),\n ],\n ]\n );\n $this->add_control(\n 's_title',\n [\n 'label' => __('Small Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => ['view6','view18']\n ],\n ]\n );\n $this->add_control(\n 'heading_img',\n [\n 'label' => __('Image', 'careerfy-frame'),\n 'type' => Controls_Manager::MEDIA,\n 'dynamic' => [\n 'active' => true,\n ],\n 'default' => [\n 'url' => Utils::get_placeholder_image_src(),\n ],\n 'condition' => [\n 'view' => array('view8', 'view15')\n ],\n ]\n );\n $this->add_control(\n 'h_title',\n [\n 'label' => __('Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n\n ]\n );\n $this->add_control(\n 'num_title',\n [\n 'label' => __('Title Number', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'h_fancy_title',\n [\n 'label' => __('Fancy Title', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXT,\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n\n $this->add_control(\n 'hc_icon',\n [\n 'label' => __('Icon', 'careerfy-frame'),\n 'type' => Controls_Manager::ICONS,\n 'description' => __(\"This will apply to heading style 3 only.\", \"careerfy-frame\"),\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n $this->add_control(\n 'h_desc',\n [\n 'label' => __('Description', 'careerfy-frame'),\n 'type' => Controls_Manager::TEXTAREA,\n ]\n );\n\n $this->add_control(\n 'text_align',\n [\n 'label' => __('Text Align', 'careerfy-frame'),\n 'type' => Controls_Manager::SELECT2,\n 'default' => 'center',\n 'options' => [\n 'center' => __('Center', 'careerfy-frame'),\n 'left' => __('Left', 'careerfy-frame'),\n\n ],\n 'condition' => [\n 'view' => array('view7', 'view8', 'view17','view18')\n ],\n ]\n );\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Heading Style', 'careerfy-frame'),\n 'tab' => Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'hc_title',\n [\n 'label' => __('Color Title', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => array('view1', 'view2', 'view3', 'view4', 'view5')\n ],\n ]\n );\n $this->add_control(\n 's_title_clr',\n [\n 'label' => __('Choose Small Title Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => ['view6','view18']\n ],\n ]\n );\n $this->add_control(\n 'hc_title_clr',\n [\n 'label' => __('Choose Title Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'description' => __(\"This Color will apply to 'Color Title'.\", \"careerfy-frame\"),\n\n ]\n );\n $this->add_control(\n 'desc_clr',\n [\n 'label' => __('Choose Description Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'proc_num_clr',\n [\n 'label' => __('Choose Process Number Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'condition' => [\n 'view' => 'view6'\n ],\n ]\n );\n $this->add_control(\n 'hc_dcolor',\n [\n 'label' => __('Description Color', 'careerfy-frame'),\n 'type' => Controls_Manager::COLOR,\n 'description' => __(\"This will apply to the description only.\", \"careerfy-frame\"),\n\n ]\n );\n\n\n $this->end_controls_section();\n }", "function modified()\r\n {\r\n if (!$this->isUpdating() && $this->_control!=null && ($this->_control->_controlstate & csLoading) != csLoading && $this->_control->_name != \"\")\r\n {\r\n $f=new Font();\r\n $fstring=$f->readFontString();\r\n\r\n $tstring=$this->readFontString();\r\n\r\n\r\n if ($this->_control->ParentFont)\r\n {\r\n $parent=$this->_control->Parent;\r\n if ($parent!=null) $fstring=$parent->Font->readFontString();\r\n }\r\n\r\n // check if font changed and if the ParentFont can be reset\r\n if ($fstring!=$tstring && $this->_control->DoParentReset)\r\n {\r\n $c=$this->_control;\r\n $c->ParentFont = 0;\r\n }\r\n\r\n if ($this->_control->methodExists(\"updateChildrenFonts\"))\r\n {\r\n $this->_control->updateChildrenFonts();\r\n }\r\n }\r\n }", "protected function setContent() {}", "public function init(){\n\t\t//Additional information.\n\t\t$this->addElement('textarea', 'additional_information', array(\n\t\t\t\t'label' => 'Additional information',\n\t\t\t\t'required' => false,\n\t\t\t\t'filters' => array('StringTrim'),\n\t\t\t\t'validators' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'NotEmpty', true, array(\n\t\t\t\t\t\t\t\t\t\t'messages' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'isEmpty' => 'Please enter additional information',\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t));\n\n\t\t// Add declaration statement agree element\n\t\t$this->addElement('checkbox', 'confirmation_statement', array(\n\t\t\t\t'label' => '',\n\t\t\t\t'required' => true,\n\t\t\t\t'checkedValue' => '1',\n\t\t\t\t'uncheckedValue' => null, // Must be used to override default of '0' and force an error when left unchecked\n\t\t\t\t'validators' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t\t'NotEmpty', true, array(\n\t\t\t\t\t\t\t\t\t\t'messages' => array(\n\t\t\t\t\t\t\t\t\t\t\t\t'isEmpty' => 'You must agree to confirmation statement to continue'\n\t\t\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\t\t)\n\t\t\t\t\t\t)\n\t\t\t\t)\n\t\t));\n\n\t\t// Set custom subform decorator\n\t\t$this->setDecorators(array(\n\t\t\t\tarray('ViewScript', array('viewScript' => 'insurance/subforms/quote-my-additionaldetail.phtml'))\n\t\t));\n\n\t\t// Strip all tags to prevent XSS errors\n\t\t$this->setElementFilters(array('StripTags'));\n\n\n\t\t$this->setElementDecorators(array(\n\t\t\t\tarray('ViewHelper', array('escape' => false)),\n\t\t\t\tarray('Label', array('escape' => false))\n\t\t));\n\t}", "public function renderForeignRecordHeaderControl_postProcess(\n $parentUid,\n $foreignTable,\n array $childRecord,\n array $childConfig,\n $isVirtual,\n array &$controlItems\n ) {\n // registered empty to satisfy interface\n }", "public function setDispFields() {}", "protected function attached($presenter)\n\t{\n\t\tparent::attached($presenter);\n\t\t$this->attachHandlers($presenter);\n\n\t\tif (property_exists($presenter, 'translator')) {\n\t\t\t$this->setTranslator($presenter->translator);\n\t\t}\n\n\t\tif ( ! $this->isBuilt) {\n\t\t\t$this->build();\n\t\t}\n\n\t\t// @todo annotation refactoring\n\t\tif (($presenter->module == 'front' && isset($presenter->paramService->useBootstrapFront)) || isset($this->presenter->paramService->useBootstrap)) {\n\t\t\t$form = $this;\n\t\t\t$this->setupBootstrapRenderer($form);\n\t\t}\n\t}", "protected function onParentSet() : void\n {\n $value = $this->oFG->getData()->getValue($this->strName);\n $this->iValue = $value ? intval($value) : $this->iMin;\n }", "protected function _register_controls() {\n\n $this->start_controls_section(\n 'content_section',\n [\n 'label' => esc_html__( 'Content', 'Alita-extensions' ),\n 'tab' => Controls_Manager::TAB_CONTENT,\n ]\n );\n\n $this->add_control(\n 'title',\n [\n 'label' => esc_html__( 'Title', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'default' => '',\n 'placeholder' => esc_html__( 'Enter title', 'Alita-extensions' ),\n ]\n );\n\n $this->add_control(\n 'show_savings',\n [\n 'label' => esc_html__( 'Show Savings Details', 'Alita-extensions' ),\n 'type' => Controls_Manager::SWITCHER,\n 'label_on' => esc_html__( 'Enable', 'Alita-extensions' ),\n 'label_off' => esc_html__( 'Disable', 'Alita-extensions' ),\n 'return_value' => true,\n 'default' => false,\n ]\n );\n\n $this->add_control(\n 'savings_in',\n [\n 'label' => esc_html__( 'Savings in', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'amount' => esc_html__( 'Amount', 'Alita-extensions' ),\n 'percentage' => esc_html__( 'Percentage', 'Alita-extensions' ),\n ],\n 'default'=> 'amount',\n ]\n );\n\n $this->add_control(\n 'savings_text',\n [\n 'label' => esc_html__('Savings Text', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'limit',\n [\n 'label' => esc_html__( 'Number of Products to display', 'Alita-extensions' ),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the number of products to display', 'Alita-extensions'),\n ]\n );\n\n $this->add_control(\n 'product_choice',\n [\n 'label' => esc_html__( 'Product Choice', 'Alita-extensions' ),\n 'type' => Controls_Manager::SELECT,\n 'options' => [\n\n 'recent' =>esc_html__( 'Recent', 'Alita-extensions' ),\n 'random' =>esc_html__( 'Random', 'Alita-extensions' ),\n 'specific' =>esc_html__( 'Specific', 'Alita-extensions' ),\n ],\n 'default'=> 'recent',\n ]\n );\n\n\n $this->add_control(\n 'product_id',\n [\n 'label' => esc_html__('Product ID', 'Alita-extensions'),\n 'type' => Controls_Manager::TEXT,\n 'description' => esc_html__('Enter the product id seperate by comma(,).', 'Alita-extensions'),\n ]\n );\n\n $this->end_controls_section();\n\n }", "protected function _register_controls()\n {\n global $post;\n $page = get_post($post->ID);\n $pageTitle = $page->post_title;\n\n // Top post's part starts\n $this->start_controls_section(\n 'section_top',\n [\n 'label' => __('Top part of article', 'elementor'),\n ]\n );\n\n $this->add_control(\n 'page_title',\n [\n 'label' => 'Type page title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => $pageTitle,\n// 'default' => 'TEXT TITLE',\n ]\n );\n\n $this->add_control(\n 'page_subtitle',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'blog_content_top',\n [\n 'label' => __('Top article part', 'elementor'),\n 'default' => __('Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_middle',\n [\n 'label' => __('Middle article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->add_control(\n 'blog_content_bottom',\n [\n 'label' => __('Bottom article part', 'elementor'),\n 'default' => __('<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec ac ornare odio, non \n ultricies leo. Mauris turpis erat, tristique eget dui eget, egestas consequat mi. Integer convallis, \n justo ut fermentum fermentum, erat purus pulvinar massa, ac viverra massa libero at nibh. Cras ac mi at\n nulla rutrum accumsan a nec tortor.</p>', 'elementor'),\n 'placeholder' => __('Tab Content', 'elementor'),\n 'type' => Controls_Manager::WYSIWYG,\n 'show_label' => false,\n ]\n );\n\n $this->end_controls_section();\n // Top post's part ends\n\n // Middle post's part starts\n $this->start_controls_section(\n 'section_middle',\n [\n 'label' => __('Middle part of article', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'the_quote',\n [\n 'label' => 'Type page sub title',\n 'type' => \\Elementor\\Controls_Manager::TEXTAREA,\n 'default' => __('“We’re seeing some really bullish bitcoin price action today along with other ...',\n 'plugin-domain'),\n ]\n );\n\n $this->end_controls_section();\n // Midddle post's part ends\n }", "protected function _register_controls()\n {\n\n $this->start_controls_section(\n 'section_content',\n [\n 'label' => __('Content', 'elementor-super-cat'),\n ]\n );\n\n\n $this->add_control(\n 'taxonomy',\n [\n 'label' => __('Name of taxonomy to filter', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT2,\n 'label_block' => true,\n 'options' => $this->get_taxonomies(),\n 'default' => isset($this->get_taxonomies()[0]) ? $this->get_taxonomies()[0] : []\n ]\n );\n\n $this->add_control(\n 'post_id',\n [\n 'label' => __('CSS ID of the post widget', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n ]\n );\n\n $this->add_control(\n 'order_by',\n [\n 'label' => __('Order By', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SELECT,\n 'default' => 'name',\n 'options' => [\n 'name' => __('Name', 'elementor-super-cat'),\n 'slug' => __('Slug', 'elementor-super-cat'),\n ],\n ]\n );\n\n $this->add_control(\n 'all_text',\n [\n 'label' => __('Text to show for <b>Show All</b>', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::TEXT,\n 'default' => \"all\"\n ]\n );\n\n $this->add_control(\n 'hide_empty',\n [\n 'label' => __('Hide empty', 'elementor'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('If ON empty filters will be hidden.', 'elementor'),\n ]\n );\n\n\n $this->add_control(\n 'invisible_filter',\n [\n 'label' => __('Remove Filter and display only currenct taxonomy', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SWITCHER,\n 'description' => __('Removes the filter bar and only display related single related taxonomy', 'elementor'),\n ]\n );\n\n\n $this->end_controls_section();\n\n $this->start_controls_section(\n 'section_style',\n [\n 'label' => __('Style', 'elementor-super-cat'),\n 'tab' => \\Elementor\\Controls_Manager::TAB_STYLE,\n ]\n );\n\n $this->add_control(\n 'color_filter',\n [\n 'label' => __('Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter' => 'color: {{VALUE}}',\n ],\n ]\n );\n\n $this->add_control(\n 'color_filter_active',\n [\n 'label' => __('Active Color', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::COLOR,\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter.elementor-active' => 'color: {{VALUE}};',\n ],\n ]\n );\n\n $this->add_group_control(\n 'typography',\n [\n 'name' => 'typography_filter',\n 'selector' => '{{WRAPPER}} .elementor-portfolio__filter',\n ]\n );\n\n $this->add_control(\n 'filter_item_spacing',\n [\n 'label' => __('Space Between', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filter:not(:last-child)' => 'margin-right: calc({{SIZE}}{{UNIT}}/2)',\n '{{WRAPPER}} .elementor-portfolio__filter:not(:first-child)' => 'margin-left: calc({{SIZE}}{{UNIT}}/2)',\n ],\n ]\n );\n\n $this->add_control(\n 'filter_spacing',\n [\n 'label' => __('Spacing', 'elementor-super-cat'),\n 'type' => \\Elementor\\Controls_Manager::SLIDER,\n 'default' => [\n 'size' => 10,\n ],\n 'range' => [\n 'px' => [\n 'min' => 0,\n 'max' => 100,\n ],\n ],\n 'selectors' => [\n '{{WRAPPER}} .elementor-portfolio__filters' => 'margin-bottom: {{SIZE}}{{UNIT}}',\n ],\n ]\n );\n\n $this->end_controls_section();\n }", "function AddControls($controls)\r\n {\r\n $this->Controls = $controls;\r\n }", "public function setForm() {\n\t\t$translator = Zend_Registry::get('Zend_Translate');\n\t\t$this->setMethod('post');\n\t\t \n\t\t$this->addEnabled();\n\t\t$this->addRentDueDay();\n\t\t$this->addProrationType();\n\t\t$this->addProrationApplyMonth();\n\t\t$this->addSecondMonthDue();\n\t\t$this->addSubmitButton();\n\n\t\t$this->addDisplayGroup( $this->displayGroupArray, 'updateRentProrationSetting',array('legend' => 'rentProrationSettings'));\n\t\t$this->getDisplayGroup('updateRentProrationSetting')->setDecorators(array(\n 'FormElements',\n 'Fieldset', \n\t\t));\n\t}", "protected function prepareRendering() {}", "protected function _register_controls() {\n\n\t\t//link\n\t\t//image\n\t\t//featured\n\t\t//term\n\t\t//style alternative-imagebox\n\t\t//\n\t\t//\n\n\n\t\t$this->start_controls_section(\n\t\t\t'section_content',\n\t\t\tarray(\n\t\t\t\t'label' => __( 'Content', 'elementor-listeo' ),\n\t\t\t)\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'url',\n\t\t\t[\n\t\t\t\t'label' => __( 'Link','elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::URL,\n\t\t\t\t'placeholder' => __( 'https://your-link.com', 'elementor-listeo' ),\n\t\t\t\t'show_external' => true,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => '',\n\t\t\t\t\t'is_external' => true,\n\t\t\t\t\t'nofollow' => true,\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'background',\n\t\t\t[\n\t\t\t\t'label' => __( 'Choose Background Image', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::MEDIA,\n\t\t\t\t'default' => [\n\t\t\t\t\t'url' => \\Elementor\\Utils::get_placeholder_image_src(),\n\t\t\t\t]\n\t\t\t]\n\t\t);\n\n\n\n\t\t// $this->add_control(\n\t\t// \t'featured',\n\t\t// \t[\n\t\t// \t\t'label' => __( 'Featured badge', 'elementor-listeo' ),\n\t\t// \t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t// \t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t// \t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t// \t\t'return_value' => 'yes',\n\t\t// \t\t'default' => 'yes',\n\t\t// \t]\n\t\t// );\n\n\t\t$this->add_control(\n\t\t\t'taxonomy',\n\t\t\t[\n\t\t\t\t'label' => __( 'Taxonomy', 'elementor-listeo' ),\n\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t'label_block' => true,\n\t\t\t\t'default' => [],\n\t\t\t\t'options' => $this->get_taxonomies(),\n\t\t\t\t\n\t\t\t]\n\t\t);\n\n\t\t$taxonomy_names = get_object_taxonomies( 'listing','object' );\n\t\tforeach ($taxonomy_names as $key => $value) {\n\t\n\t\t\t$this->add_control(\n\t\t\t\t$value->name.'term',\n\t\t\t\t[\n\t\t\t\t\t'label' => __( 'Show term from '.$value->label, 'elementor-listeo' ),\n\t\t\t\t\t'type' => Controls_Manager::SELECT2,\n\t\t\t\t\t'label_block' => true,\n\t\t\t\t\t'default' => [],\n\t\t\t\t\t'options' => $this->get_terms($value->name),\n\t\t\t\t\t'condition' => [\n\t\t\t\t\t\t'taxonomy' => $value->name,\n\t\t\t\t\t],\n\t\t\t\t]\n\t\t\t);\n\t\t}\n\n\n\t\t$this->add_control(\n\t\t\t'show_counter',\n\t\t\t[\n\t\t\t\t'label' => __( 'Show listings counter', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'your-plugin' ),\n\t\t\t\t'label_off' => __( 'Hide', 'your-plugin' ),\n\t\t\t\t'return_value' => 'yes',\n\t\t\t\t'default' => 'yes',\n\t\t\t]\n\t\t);\n\n\n\t\t$this->add_control(\n\t\t\t'style',\n\t\t\t[\n\t\t\t\t'label' => __( 'Style ', 'elementor-listeo' ),\n\t\t\t\t'type' => \\Elementor\\Controls_Manager::SELECT,\n\t\t\t\t'default' => 'alternative-imagebox',\n\t\t\t\t'options' => [\n\t\t\t\t\t'standard' => __( 'Standard', 'elementor-listeo' ),\n\t\t\t\t\t'alternative-imagebox' => __( 'Alternative', 'elementor-listeo' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\n\t\t\n\n\t\t$this->end_controls_section();\n\n\t}", "public function hooked()\n {\n $this->setData();\n }", "public function postDispatch()\n {\n parent::postDispatch();\n\n $this->getRequestData();\n }", "function post() {\n\t\t\n\t\t$this->doFormatAction($this->params['format']);\n\t\n\t\t// used to add outer wrapper to widget if it's the first view.\n\t\t$iv = $this->getParam('initial_view');\n\t\tif ($iv == true):\n\t\t\t$this->data['subview'] = $this->data['view'];\n\t\t\t$this->data['view'] = 'base.widget';\n\t\t\t// we dont want to keep passing this.\n\t\t\tunset($this->data['params']['initial_view']);\n\t\tendif;\n\t\t\n\t\t\n\t\t$this->data['wrapper'] = $this->getParam('wrapper');\n\t\t$this->data['widget'] = $this->params['do'];\n\t\t$this->data['do'] = $this->params['do'];\n\t\t\n\t\t// set default dimensions\n\t\t\n\t\tif (array_key_exists('width', $this->params)):\n\t\t\t$this->setWidth($this->params['width']);\n\t\tendif;\n\t\t\n\t\tif (array_key_exists('height', $this->params)):\n\t\t\t$this->setHeight($this->params['height']);\n\t\tendif;\n\n\t}", "function Control_Ajax()\r\n\t{\r\n\t\tif ($this->Datasource == null || count($this->Columns) < 1)\r\n\t\t{\t\r\n\t\t\ttrigger_error(\"The DataTable control requires it's Datasource and columns to be loaded in the Page_Init() event.\", E_USER_ERROR);\t\r\n\t\t}\t\r\n\t\t\r\n\t\t//Here we load get the datasource and output it as XML \r\n\t\t\r\n\t\t$doc = $this->Datasource->GetAsXMLDocument();\r\n\t\t\r\n\t\t$doSelector = strtoupper($this->Selector) != \"NONE\";\r\n\t\r\n\t\t//add columns to datasource\r\n\t\t$root = $doc->DocumentElement();\r\n\t\t\r\n\t\t$columns = $doc->CreateElement(\"columns\");\r\n\t\t\r\n\t\t$root->InsertFirst($columns);\r\n\t\t\r\n\t\tforeach ($this->Columns as $col)\r\n\t\t{\r\n\t\t\t$colNode = $doc->CreateElement(\"column\"); \r\n\t\t\t$colNode->SetAttribute(\"heading\",$col->Heading);\r\n\t\t\t$colNode->SetNodeContent($col->Datafield);\r\n\t\t\t$columns->AppendChild($colNode);\r\n\t\t}\r\n\t\t\r\n\t\t//add selector checkbox/radio selection if required\r\n\t\tif ($doSelector)\r\n\t\t{\r\n\t\t\t//add selector heading column\r\n\t\t\t\r\n\t\t\t$colNode = $doc->CreateElement(\"column\");\r\n\t\t\t\r\n\t\t\t$colNode->SetNodeContent(\"selector\");\r\n\t\t\t\r\n\t\t\t$colNode->SetAttribute(\"heading\",\"\");\r\n\t\t\t\r\n\t\t\t$columns->InsertFirst($colNode);\r\n\t\t\t\r\n\t\t\t\t\r\n\t\t\t//Add selectors to each row\r\n\t\t\t\t\r\n\t\t\t$rowNodes = $doc->XPathQuery(\"//row\");\r\n\t\t\t\r\n\t\t\t$selector =& $this->FindControl(\"selectorGroup\");\r\n\t\t\t\r\n\t\t\tforeach ($rowNodes as $row)\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t\t$selectorNode = $doc->CreateElement(\"selector\");\r\n\t\t\t\t\t\r\n\t\t\t\t\t$selectorNode->SetAttribute(\"element\",\"input\");\r\n\t\t\t\t\t\r\n\t\t\t\t\t$selectorNode->SetAttribute(\"name\",$selector->GetGroupName().\"[]\");\r\n\t\t\t\t\t\r\n\t\t\t\t\t$selectorNode->SetAttribute(\"type\",strtolower($this->Selector));\r\n\t\t\t\t\t\r\n\t\t\t\t\t$inputValueNodes = $row->GetElementsByTagName($this->SelectorDatafield);\r\n\t\t\t\t\t$inputValueNode = $inputValueNodes[0];\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t$selectorNode->SetAttribute(\"value\", $inputValueNode->GetNodeContent());\r\n\t\t\t\t\t\r\n\t\t\t\t\t$row->InsertFirst($selectorNode);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\t//add row code\r\n\t\t\t\t\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t//output the data for this ajax instance\t\r\n\t\theader('Content-type: text/xml');\r\n\t\t\r\n\t\techo $doc->GetXML(false);\r\n\t\t\r\n\t}", "public function setValue($value)\n\t{\n\t\tif (parent::getValue() === $value) {\n\t\t\treturn;\n\t\t}\n\n\t\tparent::setValue($value);\n\t\tif ($this->getActiveControl()->canUpdateClientSide() && $this->getHasLoadedPostData()) {\n\t\t\t$this->getPage()->getCallbackClient()->setValue($this, $value);\n\t\t}\n\t}", "protected function _register_controls() {\n \n \t$this->start_controls_section(\n \t\t'section_listing_posts',\n \t\t[\n \t\t\t'label' => __( 'Listing Posts', 'listslides' ),\n \t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n \t\t]\n \t); \n\n \t$this->add_control(\n \t\t'item_per_page',\n \t\t[\n \t\t\t'label' => __( 'Number of Listings', 'listslides' ),\n \t\t\t'type' => Controls_Manager::SELECT,\n \t\t\t'default' => 5,\n \t\t\t'options' => [\n \t\t\t\t2 => __( 'Two', 'listslides' ),\n \t\t\t\t3 => __( 'Three', 'listslides' ),\n \t\t\t\t4 => __( 'Four', 'listslides' ),\n \t\t\t\t5 => __( 'Five', 'listslides')\n \t\t\t]\n \t\t]\n \t);\n\n \t$this->end_controls_section();\n\n \t$this->start_controls_section(\n\t\t\t'slide_settings',\n\t\t\t[\n\t\t\t\t'label' => __( 'Slides Settings', 'listslides' ),\n\t\t\t\t'tab' => Controls_Manager::TAB_CONTENT,\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'nav',\n\t\t\t[\n\t\t\t\t'label' => __( 'Navigation Arrow', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'dots',\n\t\t\t[\n\t\t\t\t'label' => __( 'Dots', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Show', 'listslides' ),\n\t\t\t\t'label_off' => __( 'Hide', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplay',\n\t\t\t[\n\t\t\t\t'label' => __( 'Auto Play', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'loop',\n\t\t\t[\n\t\t\t\t'label' => __( 'Loop', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'mouseDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Mouse Drag', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'touchDrag',\n\t\t\t[\n\t\t\t\t'label' => __( 'Touch Motion', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SWITCHER,\n\t\t\t\t'label_on' => __( 'Yes', 'listslides' ),\n\t\t\t\t'label_off' => __( 'No', 'listslides' ),\n\t\t\t\t'return_value' => 'true',\n\t\t\t\t'default' => 'true',\n\t\t\t]\n\t\t);\n\n\t\t$this->add_control(\n\t\t\t'autoplayTimeout',\n\t\t\t[\n\t\t\t\t'label' => __( 'Autoplay Timeout', 'listslides' ),\n\t\t\t\t'type' => Controls_Manager::SELECT,\n\t\t\t\t'default' => '3000',\n\t\t\t\t'condition' => [\n\t\t\t\t\t'autoplay' => 'true',\n\t\t\t\t],\n\t\t\t\t'options' => [\n\t\t\t\t\t'2000' => __( '2 Seconds', 'listslides' ),\n\t\t\t\t\t'3000' => __( '3 Seconds', 'listslides' ),\n\t\t\t\t\t'5000' => __( '5 Seconds', 'listslides' ),\n\t\t\t\t\t'10000' => __( '10 Seconds', 'listslides' ),\n\t\t\t\t\t'15000' => __( '15 Seconds', 'listslides' ),\n\t\t\t\t\t'20000' => __( '20 Seconds', 'listslides' ),\n\t\t\t\t],\n\t\t\t]\n\t\t);\n\n\t\t$this->end_controls_section();\n\n }" ]
[ "0.6147969", "0.59550154", "0.5944235", "0.5923315", "0.5883677", "0.58174306", "0.5667998", "0.5666576", "0.56524956", "0.5648305", "0.55834913", "0.55834633", "0.5551934", "0.5529833", "0.5509607", "0.5473536", "0.5472581", "0.5464047", "0.54015446", "0.5391583", "0.5362316", "0.53622633", "0.5344289", "0.5301123", "0.52672285", "0.52433157", "0.52340376", "0.5233424", "0.52067786", "0.51898444", "0.51672035", "0.5157672", "0.5148468", "0.51465756", "0.5142636", "0.50993747", "0.50895137", "0.5088294", "0.508701", "0.5072798", "0.50714296", "0.50594157", "0.5054534", "0.50497824", "0.5044593", "0.50433135", "0.50432414", "0.50374264", "0.5033506", "0.5016564", "0.50133014", "0.50039655", "0.49983802", "0.49974272", "0.4995731", "0.49930465", "0.49916482", "0.4988081", "0.4983115", "0.49787933", "0.49765825", "0.49752071", "0.49728826", "0.49677902", "0.4959859", "0.49547145", "0.49512547", "0.49496627", "0.4948351", "0.49447477", "0.4939791", "0.4932042", "0.49294814", "0.49257773", "0.49202746", "0.49163434", "0.49160546", "0.4910299", "0.49100277", "0.49021178", "0.49014091", "0.48827103", "0.48799184", "0.48722163", "0.48695278", "0.4864542", "0.48619634", "0.48579055", "0.48576835", "0.4849665", "0.4846187", "0.4845597", "0.48421922", "0.48414177", "0.48344773", "0.48236227", "0.48167554", "0.48159465", "0.48155797", "0.4814099" ]
0.6371386
0
Handles the OnInit event
function ControlOnInit() { }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function OnInit() {\r\n }", "protected function onInit() {}", "protected function __onInit()\n\t{\n\t}", "public function onInit($param) {\r\n\t\tPrado::trace(\"onInit\",'System.Web.Services.TPageService');\r\n\t\t$this->raiseEvent('OnInit',$this,$param);\r\n\t}", "public function onInit() {\n }", "public function onInit() {\n\t}", "function init()\n{\n\t$this->_init();\n\t$this->onInit();\n}", "function ControlOnLoad() {\n }", "protected function onLoad()\n\t\t{\n\t\t\tparent::onLoad();\n\n\t\t\tif( $this->items->count > 0 )\n\t\t\t{\n\t\t\t\t$this->defaultHTMLControlId = $this->getHTMLControlId() . \"__0\";\n\t\t\t}\n\t\t}", "public function onLoad() {\n \n }", "function init() {\n\t\t\n\t\tparent::init();\n\t}", "public function init()\n {\n parent::init();\n $this->trigger(self::EVENT_INIT);\n }", "public function init()\n {\n parent::init();\n $this->trigger(self::EVENT_INIT);\n }", "public function init()\n {\n parent::init();\n $this->trigger(self::EVENT_INIT);\n }", "public function init()\n {\n parent::init();\n $this->trigger(self::EVENT_INIT);\n }", "function onLoad($param)\n\t{\n\t\tparent::onLoad($param);\n\n\t\t$this->dataBind();\n\n\t\t//on loading the page for the first time, \n\t\t//initialize the drop down lists\n\t\tif(!$this->Page->IsPostBack)\n\t\t{\n\t\t\t$step1 = $this->Page->RentalWizard->Step1;\n\n\t\t\t//set the default vehicle category and types\n\t\t\t$cat = $step1->VehicleCat->Items[0]->Text;\n\t\t\t$this->setVehicleTypes($cat);\t\n\t\t\t$type = $this->VehicleType->Items[0]->Text;\n\t\t\t$this->setVehicleList($cat, $type);\n\t\t}\n\t}", "function ControlOnLoad(){\n parent::ControlOnLoad();\n }", "public function onLoad() {\n\t}", "function init()\r\n\t\t{\r\n\t\t\t// Should always call parent's init\r\n\t\t\tparent::init();\r\n\t\t}", "public function postInit()\n {\n }", "public function postInit()\n {\n }", "public function postInit()\n {\n }", "function PostInit()\n {\n }", "public function init()\r\n {\r\n \tparent::init();\r\n }", "function init() {\n if ($this->_init === false) {\n $this->_init = true;\n $this->doInit();\n }\n }", "public function init()\n\t{\n\t\tparent::init();\n\t}", "public function init()\n\t{\n\t\tparent::init();\n\t}", "public function init()\n {\n // Initialize widget.\n }", "public function init() {\n\t\tparent::init();\n\t}", "public function init()\n {\n /*\n * service component, data provider\n */\n // parent::init();\n }", "public function init() {\r\n parent::init();\r\n }", "public function init()\r\n {\r\n parent::init();\r\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init()\n {\n parent::init();\n }", "public function init() {\r\n if ( ! $this->_initiated ) {\r\n $this->_init_hooks();\r\n }\r\n }", "public function init() {\n parent::init();\n }", "public function init() {\n parent::init();\n }", "public function init() {\n parent::init();\n }", "protected function onInit()\n {\n //Set up connection\n }", "function onLoad() {\n\t\t$this->enableDedicatedEvents();\n\t\t$this->config = Config::getInstance();\n\t\t\n\n\t\tif ($this->isPluginLoaded('MLEPP\\Admin', '0.3.0')) {\n\t\t\t$this->callPublicMethod('MLEPP\\Admin', 'addAdminCommand', array($this, 'setText'), array(\"set\", \"headsup\", \"text\"), true, false, false);\n\t\t\t$this->callPublicMethod('MLEPP\\Admin', 'addAdminCommand', array($this, 'setUrl'), array(\"set\", \"headsup\", \"url\"), true, false, false);\n\t\t\t$this->callPublicMethod('MLEPP\\Admin', 'addAdminCommand', array($this, 'setWidth'), array(\"set\", \"headsup\", \"width\"), true, false, false);\n\t\t\t$this->callPublicMethod('MLEPP\\Admin', 'addAdminCommand', array($this, 'setPos'), array(\"set\", \"headsup\", \"pos\"), true, false, false);\n\t\t}\n\n\t\tConsole::println('[' . date('H:i:s') . '] [MLEPP] Plugin: HeadsUp r' . $this->getVersion());\n\t}", "public function init()\n {\n parent::init();\n \n $this->_autoId = CMyHtml::genID();\n $this->_idPrefix = self::$autoIdPrefix.'_'.CMyHtml::getIDPrefix();\n \n if (empty($this->logoUrl)) {\n $urlRoot = \\common\\helpers\\Utils::getRootUrl();\n $this->logoUrl = \"{$urlRoot}assets/images/logo/yikazc_black.png\";\n }\n \n if (!isset($this->titleOptions) || empty($this->titleOptions)) {\n $this->titleOptions = ['style'=>\"font-size:14px\"];\n }\n if (!isset($this->subTitleOptions) || empty($this->subTitleOptions)) {\n $this->subTitleOptions = [];\n }\n }", "public function init()\n {\n Yii::app()->clientScript->registerScriptFile(Yii::app()->request->baseUrl . \"/js/search-triple.js\", CClientScript::POS_END);\n\n }", "public function onInit($param){\r\n parent::onInit($param);\r\n \r\n if(!$this->IsPostBack && !$this->isCallback) // if the page is initially requested\r\n {\r\n $sql = \"SELECT idtm_user_role, user_role_name FROM tm_user_role\";\r\n $this->User->isInRole('Administrator')?'':$sql.= \" WHERE user_role_name = 'Benutzer'\";\r\n $data = PFH::convertdbObjectArray(UserRoleRecord::finder()->findAllBySql($sql),array(\"idtm_user_role\",\"user_role_name\"));\r\n $this->Role->DataSource=$data;\r\n $this->Role->dataBind();\r\n\r\n // Retrieves the existing user data. This is equivalent to:\r\n $userRecord=$this->getUserRecord();\r\n //$userRecord=$this->UserRecord;\r\n \r\n // Populates the input controls with the existing user data\r\n $this->Username->Text=$userRecord->user_username;\r\n $this->Email->Text=$userRecord->user_mail;\r\n $this->Role->SelectedValue=$userRecord->idtm_user_role;\r\n $this->FirstName->Text=$userRecord->user_vorname;\r\n $this->LastName->Text=$userRecord->user_name;\r\n\r\n $parteiRecord = ParteiRecord::finder()->findBy_idtm_user($userRecord->idtm_user);\r\n $this->idta_partei->Text=$parteiRecord->idta_partei;\r\n $this->bind_lstAdress();\r\n }\r\n }", "public function preInit()\n {\n $this->_viewEngine = Bigace_Services::get()->getService('view');\n }", "protected function onLoad()\n\t\t{\n\t\t\tparent::onLoad();\n\n//\t\t\t$this->addValidator(new PostalZipCodeValidator($this->label . ' ' . \\System\\Base\\ApplicationBase::getInstance()->translator->get('must_be_a_valid_zip_postal', 'must be a valid zip/postal code')));\n\t\t}", "public function onStart() {\r\n\r\n }", "public function init() {\n\t\t\t$this->register_post_type();\n\t\t\t$this->acf_add_options_pages();\n\t\t\tdo_action('acf_options_page/init');\n\t\t}", "public function init(){\n parent::init();\n $this->registerAssets();\n \n echo CHtml::openTag($this->tag, $this->getTitleOptions());\n echo $this->getTitleText();\n }", "function init()\r\n \t{\r\n \t}", "function Init()\r\n\t{\r\n\r\n\t}", "public function onStart()\n {\n }", "function init(){\r\n\t}", "protected function _init()\n\t{\n\t\tparent::_init();\n\t}", "public function init()\n {\n // Nothing needs to be done initially, huzzah!\n }", "public function init()\n {\n\t\t$this->_temporizador = new Trf1_Admin_Timer ();\n\t\t$this->_temporizador->Inicio ();\n\t\t\n $this->view->titleBrowser = 'e-Sosti';\n }", "public function onLoad()\r\n {\r\n parent::onLoad();\r\n\r\n // Connect to the database\r\n $this->connect($this->server, $this->username, $this->password, $this->database);\r\n }", "public function Init() {\n\t\t\n\t\t$this->exceptions = TRUE;\n\t\t$this->SetAccess(self::ACCESS_ANY);\n\t\t$this->access_groups = array('admin','user','any');\n\t\t$this->current_group = 'any';\n\t\t$this->AccessMode(1);\n\t\t$this->SetModel(SYS.M.'menudata');\n\t\t$this->only_registered(FALSE);\n\t\tif(Helper::Get('admin'.S.'menu') == '')\n\t\t//$this->SetView(SYS.V . \"elements:nav\");\n\t\t$this->Inc(SYS.M.'model');\n\t}", "function _on_initialize()\n {\n }", "public function onLoad() {\n $this->addFileNameHook(array($this, 'parseFileName'));\n }", "function init() {\r\n }", "function InitChildControls() {\n }", "public function init()\n {\n\n $this->_setup_cpt_acf();\n\n }", "public function customize_controls_init()\n {\n }", "public function theInit()\n {\n\n }", "public function theInit()\n {\n\n }", "public function __init()\n\t{\n\t\t// This code will run before your controller's code is called\n\t}", "public function initialize()\n {\n $this->tag->setTitle('Log in/Sign up');\n parent::initialize();\n }", "protected function startup() {\n\t\tif (null != $this->getParam('eid')) {\n\t\t\t$this->eid = $this->getParam('eid');\n\t\t\t$this->cid = EventModel::getCourseIDByEventID($this->eid);\n\t\t}\n\t\tparent::startup();\n\t}", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\t\t\n\t\treturn;\n\t}", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "public function init()\n {\n }", "protected function _postConstruct()\n {\n parent::_postConstruct();\n if ($this->_config['auto_start']) {\n $this->start();\n }\n }", "public function onActivation() {\n\n\t\t$this->options->initDefaultOptions();\n\t}", "public function init()\n {\n \tparent::init();\n \t$this->view->headTitle('Wedding Cakes');\n }", "function init() {\n $this.getAdminOptions();\n }", "protected function _init()\n\t{\n\t\t// chamando inicializacao da classe pai\n\t\tparent::_init();\n\n\t\treturn;\n\t}", "function onLoad($param)\r\n\t{\r\n\t\tif (!$this->IsPostBack){\r\n\t\t\t$this->workerList->DataSource = $this->getWorkers();\r\n\t\t\t$this->workerList->dataBind();\r\n\t\t} \t\r\n\t}", "public function initPage() {}", "public function initPage() {}", "function on_creation() {\n $this->init();\n }", "public function onStart();", "public function init()\n {\n $this->loadMeta();\n }" ]
[ "0.6955779", "0.6572016", "0.6541836", "0.6521009", "0.6491222", "0.6439261", "0.6368316", "0.6361455", "0.6334942", "0.63027835", "0.6288262", "0.62430054", "0.62430054", "0.62430054", "0.62430054", "0.6226903", "0.6212035", "0.61697626", "0.61537635", "0.6150927", "0.6150927", "0.6150927", "0.61403817", "0.6076408", "0.60571516", "0.60275507", "0.60275507", "0.60079604", "0.597724", "0.5955393", "0.59534425", "0.5949317", "0.5921067", "0.5921067", "0.5921067", "0.5921067", "0.5921067", "0.5921067", "0.5921067", "0.5910673", "0.5883956", "0.5883956", "0.5883956", "0.58738023", "0.5853381", "0.5853145", "0.5838438", "0.58358514", "0.58205736", "0.5809968", "0.58096194", "0.58071417", "0.5797673", "0.5788089", "0.57695", "0.572259", "0.5716116", "0.5695399", "0.5685123", "0.56739134", "0.566743", "0.566452", "0.5656232", "0.56548643", "0.5643673", "0.56429327", "0.5635809", "0.56328106", "0.5629658", "0.5629658", "0.5625859", "0.56232363", "0.5615705", "0.56143004", "0.56143004", "0.56133723", "0.56128395", "0.5612763", "0.5612763", "0.5612763", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5612493", "0.5608853", "0.5606212", "0.5605369", "0.5605345", "0.5597275", "0.5591292", "0.55902153", "0.55902153", "0.558959", "0.5588051", "0.55847424" ]
0.68343866
1